| | |
| | | }) |
| | | |
| | | //工序 |
| | | const value = ref('切割') |
| | | const value = ref(t('machine.edgeGrinding')) |
| | | |
| | | //表尾求和 |
| | | const sumNum = (list, field) => { |
| | |
| | | },//表头参数 |
| | | columns: [ |
| | | {type: 'expand', fixed: "left", slots: {content: 'content'}, width: 50}, |
| | | {type: 'seq', fixed: "left", title: '自序', width: 40}, |
| | | {type: 'seq', fixed: "left", title: t('basicData.Number'), width: 40}, |
| | | { |
| | | field: 'reportingWorkTime', width: 160, title: '报工时间', |
| | | field: 'reportingWorkTime', width: 160, title: t('reportingWorks.reportingWorkTime'), |
| | | }, |
| | | { |
| | | field: 'thisProcess', |
| | | width: 100, |
| | | title: '报工工序', |
| | | title: t('reportingWorks.reportingProcess'), |
| | | showOverflow: "ellipsis", |
| | | filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | }, |
| | | { |
| | | field: 'teamsGroupsName', width: 100, title: '报工班组',filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | field: 'teamsGroupsName', width: 100, title: t('reportingWorks.teamsType'),filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | }, |
| | | { |
| | | field: 'project', width: 120, title: '项目名称',filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | field: 'project', width: 120, title: t('order.project'),filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | }, |
| | | { |
| | | field: 'processId', width: 140, title: '流程卡号',filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | field: 'processId', width: 140, title: t('processCard.processId'),filters:[{ data: '' }],slots: { filter: 'num1_filter' } |
| | | }, |
| | | {field: 'orderNumber', width: 60, title: '序号'}, |
| | | {field: 'width', width: 100, title: '宽'}, |
| | | {field: 'height', width: 100, title: '高'}, |
| | | {field: 'shape', width: 90, title: '形状'}, |
| | | {field: 'thickness', width: 90, title: '厚度',filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'edgingType', width: 110, title: '磨边类型',filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'completedQuantity', width: 90, title: '完工数量'}, |
| | | {field: 'area', width: 100, title: '完工面积'}, |
| | | {field: 'productName', width: 150, title: '产品名称'}, |
| | | {field: 'orderNumber', width: 60, title: t('order.OrderNum')}, |
| | | {field: 'width', width: 100, title: t('order.width')}, |
| | | {field: 'height', width: 100, title: t('order.height')}, |
| | | {field: 'shape', width: 90, title: t('order.shape')}, |
| | | {field: 'thickness', width: 90, title: t('order.totalThickness'),filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'edgingType', width: 110, title: t('order.edgingType'),filters:[{ data: '' }],slots: { filter: 'num1_filter' }}, |
| | | {field: 'completedQuantity', width: 90, title: t('reportingWorks.completedQuantity')}, |
| | | {field: 'area', width: 100, title: t('reportingWorks.completedArea')}, |
| | | {field: 'productName', width: 150, title: t('order.product')}, |
| | | ],//表头按钮 |
| | | |
| | | toolbarConfig: { |
| | |
| | | function exportExcel(url, fileName,date) { |
| | | let processes = value.value |
| | | if(date===null){ |
| | | ElMessage.warning("请先选择日期") |
| | | ElMessage.warning(t('report.pleaseSelectADateFirst')) |
| | | return |
| | | } |
| | | |
| | | if(processes===null){ |
| | | ElMessage.warning("请先选择工序") |
| | | ElMessage.warning(t('report.pleaseSelectAProcessFirst')) |
| | | return |
| | | } |
| | | |
| | |
| | | const timeDiff = Math.abs(date2.getTime() - date1.getTime()); |
| | | const daysDiff = timeDiff / (1000 * 3600 * 24); |
| | | if(Math.floor(daysDiff)>180){ |
| | | ElMessage.warning("导出的筛选时间不能超过180天") |
| | | ElMessage.warning(t('report.theFilteringTimeForExportCannotExceed180Days')) |
| | | return |
| | | } |
| | | let dataMp = ref({ |
| | |
| | | |
| | | <el-date-picker |
| | | v-model="form.date1" |
| | | end-placeholder="结束时间" |
| | | :start-placeholder="$t('basicData.startDate')" |
| | | :end-placeholder="$t('basicData.endDate')" |
| | | format="YYYY/MM/DD" |
| | | start-placeholder="开始时间" |
| | | style="width: 100px" |
| | | type="daterange" |
| | | value-format="YYYY-MM-DD" |
| | |
| | | :value="item.basic_name" |
| | | /> |
| | | </el-select> |
| | | <el-button type="primary" @click="getWorkOrder">查询</el-button> |
| | | <el-button type="primary" @click="getWorkOrder">{{$t('basicData.search')}}</el-button> |
| | | </el-row> |
| | | |
| | | </div> |
| | |
| | | <template #toolbar_buttons> |
| | | <vxe-button style="margin-right: 0.5rem" |
| | | @click="exportExcel('/report/exportTeamOutput', |
| | | '班组产量明细', |
| | | t('report.teamOutput'), |
| | | form.date1)"> |
| | | 导出</vxe-button> |
| | | {{t('basicData.export')}}</vxe-button> |
| | | </template> |
| | | |
| | | </vxe-grid> |