Merge branch 'master' of http://10.153.19.25:10101/r/ERP_override
| | |
| | | workOrderDate:ref(["",""]), |
| | | searchOrderListFilter:ref([]),//订单首页筛选] |
| | | searchOrderFilter:{ |
| | | list:ref([]), |
| | | list:ref([]), |
| | | data:{} |
| | | |
| | | }, |
| | | //流程卡筛选缓存 |
| | | selectProcessCardFilter:{ |
| | | list:ref([]), |
| | | data:{ |
| | | order: { |
| | | project: '' |
| | | }, |
| | | orderDetail: { |
| | | productId: '', |
| | | productName: '', |
| | | computeGrossArea: '', |
| | | processingNote: '', |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | list:[], |
| | | data:{} |
| | | } |
| | | this.selectProcessCardFilter={ |
| | | list:[], |
| | | data:{} |
| | | } |
| | | } |
| | | }, |
| | | persist: true |
| | |
| | | dataTotal: 0, |
| | | pageSize: 100 |
| | | }) |
| | | |
| | | const getFlowCardList = async () => { |
| | | //第一次加载数据 |
| | | request.post(`/processCard/flowCard/1/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | await request.post(`/processCard/flowCard/1/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | |
| | | if (res.code == 200) { |
| | | total.dataTotal = res.data.total.total * 1 |
| | | total.pageTotal = res.data.total.pageTotal |
| | | pageTotal.value = res.data.total |
| | | produceList = produceList.value.concat(deepClone(res.data.data)) |
| | | xGrid.value.reloadData(produceList) |
| | | gridOptions.loading = false |
| | | } else { |
| | | ElMessage.warning(res.msg) |
| | | } |
| | | if (res.code == 200) { |
| | | total.dataTotal = res.data.total.total * 1 |
| | | total.pageTotal = res.data.total.pageTotal |
| | | pageTotal.value = res.data.total |
| | | produceList.value = produceList.value.concat(deepClone(res.data.data)) |
| | | xGrid.value.loadData(produceList.value) |
| | | } else { |
| | | ElMessage.warning(res.msg) |
| | | } |
| | | }) |
| | | } |
| | | onMounted(async () => { |
| | | filterData.value = orderInfo.selectProcessCardFilter.data |
| | | await getFlowCardList() |
| | | orderInfo.selectProcessCardFilter.list.forEach(item =>{ |
| | | xGrid.value.getColumnByField(item.field).filters = item.column.filters |
| | | }) |
| | | }) |
| | | |
| | | //页脚翻页查询 |
| | | const selectPageList = () => { |
| | | let startTime = orderInfo.workOrderDate[0] |
| | |
| | | request.post(`/processCard/flowCard/${pageNum.value}/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | if (res.code == 200) { |
| | | |
| | | produceList = deepClone(res.data.data) |
| | | xGrid.value.reloadData(produceList) |
| | | produceList.value = deepClone(res.data.data) |
| | | xGrid.value.loadData(produceList.value) |
| | | } else { |
| | | ElMessage.warning(res.msg) |
| | | } |
| | |
| | | total.dataTotal = res.data.total.total*1 |
| | | total.pageTotal=parseInt(res.data.total) |
| | | pageNum.value=1 |
| | | produceList = deepClone(res.data.data) |
| | | xGrid.value.reloadData(produceList) |
| | | produceList.value = deepClone(res.data.data) |
| | | xGrid.value.loadData(produceList.value) |
| | | gridOptions.loading=false |
| | | orderInfo.selectProcessCardFilter.list = xGrid.value.getCheckedFilters() |
| | | orderInfo.selectProcessCardFilter.data = filterData.value |
| | | } else { |
| | | ElMessage.warning(res.msg) |
| | | } |
| | |
| | | //子组件接收参数 |
| | | const xGrid = ref() |
| | | const gridOptions = reactive({ |
| | | loading: true, |
| | | border: "full",//表格加边框 |
| | | keepSource: true,//保持源数据 |
| | | align: 'center',//文字居中 |
| | |
| | | <template #num1_filter="{ column, $panel }"> |
| | | <div> |
| | | <div v-for="(option, index) in column.filters" :key="index"> |
| | | <input v-model="option.data" type="text" |
| | | @keyup.enter.native="$panel.confirmFilter()" |
| | | @input="changeFilterEvent($event, option, $panel)"/> |
| | | <input |
| | | v-model="option.data" |
| | | @keyup.enter.native="$panel.confirmFilter()" |
| | | @input="changeFilterEvent($event, option, $panel)"/> |
| | | </div> |
| | | </div> |
| | | </template> |
| | |
| | | |
| | | <!-- 分架明细查询--> |
| | | <select id="detailsSelectMp"> |
| | | select od.order_id, |
| | | ogd.production_id, |
| | | od.product_id, |
| | | od.product_name, |
| | | ROUND(SUM(DISTINCT od.quantity)-IFNULL(sum(fc.quantity)/fc.layers_number,0)) as quantity, |
| | | SUM(od.compute_gross_area) as compute_gross_area, |
| | | round(sum(od.perimeter), 2) as perimeter |
| | | from sd.order_detail as od |
| | | left join |
| | | (select order_id, order_number,technology_number, production_id, splitting_status |
| | | from sd.order_glass_detail |
| | | GROUP BY order_id, order_number) as ogd |
| | | on od.order_id = ogd.order_id and od.order_number = ogd.order_number |
| | | left join flow_card as fc on fc.order_id = od.order_id and fc.order_number = od.order_number |
| | | and fc.technology_number=ogd.technology_number |
| | | where od.order_id = #{orderId} |
| | | and ogd.splitting_status = 0 |
| | | SELECT |
| | | od.order_id, |
| | | ogd.production_id, |
| | | od.product_id, |
| | | od.product_name, |
| | | ROUND(SUM(od.quantity) - IFNULL(SUM(fc.quantity) / fc.layers_number, 0)) AS quantity, |
| | | SUM(od.compute_gross_area) AS compute_gross_area, |
| | | ROUND(SUM(od.perimeter), 2) AS perimeter |
| | | FROM sd.order_detail AS od |
| | | LEFT JOIN ( |
| | | SELECT order_id, order_number, production_id, splitting_status, |
| | | technology_number |
| | | FROM sd.order_glass_detail |
| | | GROUP BY order_id, order_number, production_id, splitting_status |
| | | ) AS ogd |
| | | ON od.order_id = ogd.order_id |
| | | AND od.order_number = ogd.order_number |
| | | LEFT JOIN ( |
| | | SELECT order_id, order_number, technology_number, SUM(quantity) AS quantity, layers_number |
| | | FROM flow_card |
| | | GROUP BY order_id, order_number, technology_number |
| | | ) AS fc |
| | | ON fc.order_id = od.order_id |
| | | AND fc.order_number = od.order_number |
| | | AND fc.technology_number = ogd.technology_number |
| | | WHERE od.order_id = #{orderId} |
| | | AND ogd.splitting_status = 0 |
| | | GROUP BY od.order_id, ogd.production_id, od.product_id, od.product_name |
| | | ORDER BY od.order_id DESC; |
| | | |
| | | group by od.order_id, ogd.production_id |
| | | order by od.id desc |
| | | </select> |
| | | |
| | | <!-- 更新分架状态--> |