补充注释、语言,转工单时添加未勾选数据时的弹窗,修改报工新增查询复合工序不能查询出每一层的问题,修改次破报表响应超时问题
| | |
| | | transferOrder:'تحويل الطلب', |
| | | perimeter:'محيط', |
| | | deleteNo:'فشل الحذف، تحقق مما إذا كان قد تم تقسيمة', |
| | | msg:'请选择所有数据' |
| | | msg:'请选择所有数据', |
| | | msgSelect:'请选择订单号' |
| | | |
| | | }, |
| | | processCard:{ |
| | |
| | | transferOrder:'Transfer Order', |
| | | perimeter:'perimeter', |
| | | deleteNo:'Delete failed Check whether the shelf has been splited', |
| | | msg:'Please select all data' |
| | | msg:'Please select all data', |
| | | msgSelect:'请选择订单号' |
| | | |
| | | }, |
| | | processCard:{ |
| | |
| | | transferOrder:'Трансферный ордер', |
| | | perimeter:'Внешний край', |
| | | deleteNo:'Удаление неудачных проверок, чтобы проверить, разделены ли они', |
| | | msg:'Пожалуйста, выберите все данные' |
| | | msg:'Пожалуйста, выберите все данные', |
| | | msgSelect:'请选择订单号' |
| | | |
| | | }, |
| | | processCard:{ |
| | |
| | | transferOrder:'转工单', |
| | | perimeter:'周长', |
| | | deleteNo:'删除失败,检查是否已分架', |
| | | msg:'请选择所有数据' |
| | | msg:'请选择所有数据', |
| | | msgSelect:'请选择订单号' |
| | | |
| | | }, |
| | | processCard:{ |
| | |
| | | const titleSelectJson = ref({ |
| | | processType: [], |
| | | }) |
| | | let date = new Date(endTime); // 将日期字符串转为 Date 对象 |
| | | |
| | | // 使用 setDate 方法加一天 |
| | | date.setDate(date.getDate() + 1); |
| | | let newEndTime = date.toISOString().split('T')[0]; // 获取 YYYY-MM-DD 格式的字符串 |
| | | //第一次加载数据 |
| | | request.post(`/report/damageReport/1/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | request.post(`/report/damageReport/1/${total.pageSize}/${startTime}/${newEndTime}`, filterData.value).then((res) => { |
| | | |
| | | if (res.code == 200) { |
| | | total.dataTotal = res.data.total.total*1 |
| | |
| | | const selectPageList = () => { |
| | | let startTime = form.date1[0] |
| | | let endTime = form.date1[1] |
| | | let date = new Date(endTime); // 将日期字符串转为 Date 对象 |
| | | |
| | | request.post(`/report/damageReport/${pageNum.value}/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | // 使用 setDate 方法加一天 |
| | | date.setDate(date.getDate() + 1); |
| | | let newEndTime = date.toISOString().split('T')[0]; // 获取 YYYY-MM-DD 格式的字符串 |
| | | request.post(`/report/damageReport/${pageNum.value}/${total.pageSize}/${startTime}/${newEndTime}`, filterData.value).then((res) => { |
| | | if (res.code == 200) { |
| | | |
| | | |
| | |
| | | |
| | | let startTime = form.date1[0] |
| | | let endTime = form.date1[1] |
| | | request.post(`/report/damageReport/${pageNum.value}/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | let date = new Date(endTime); // 将日期字符串转为 Date 对象 |
| | | // 使用 setDate 方法加一天 |
| | | date.setDate(date.getDate() + 1); |
| | | let newEndTime = date.toISOString().split('T')[0]; // 获取 YYYY-MM-DD 格式的字符串 |
| | | request.post(`/report/damageReport/${pageNum.value}/${total.pageSize}/${startTime}/${newEndTime}`, filterData.value).then((res) => { |
| | | |
| | | if (res.code == 200) { |
| | | total.dataTotal = res.data.total.total * 1 |
| | |
| | | |
| | | let startTime = form.date1[0] |
| | | let endTime = form.date1[1] |
| | | request.post(`/report/damageReport/1/${total.pageSize}/${startTime}/${endTime}`, filterData.value).then((res) => { |
| | | let date = new Date(endTime); // 将日期字符串转为 Date 对象 |
| | | |
| | | // 使用 setDate 方法加一天 |
| | | date.setDate(date.getDate() + 1); |
| | | let newEndTime = date.toISOString().split('T')[0]; // 获取 YYYY-MM-DD 格式的字符串 |
| | | request.post(`/report/damageReport/1/${total.pageSize}/${startTime}/${newEndTime}`, filterData.value).then((res) => { |
| | | |
| | | if (res.code == 200) { |
| | | total.dataTotal = res.data.total.total*1 |
| | |
| | | button.name=t('basicData.review') |
| | | titleUploadData.value.qualityInspector=user.user.userName |
| | | } |
| | | |
| | | |
| | | gridOptions.toolbarConfig.buttons.push(button) |
| | | } |
| | | // getQuantity() |
| | |
| | | const $grid = xGrid.value |
| | | if ($grid) { |
| | | switch (code) { |
| | | case 'saveReportingWork': { |
| | | case 'saveReportingWork': {//保存 |
| | | const errMap = await $grid.validate(true) |
| | | if (errMap) { |
| | | ElMessage.error(t('basicData.msg.checkoutLose')) |
| | |
| | | saveReportingWork(1,'save') |
| | | break |
| | | } |
| | | case 'update': { |
| | | case 'update': {//修改 |
| | | //根据补片状态判断是否能修改 |
| | | // request.post(`/reportingWork/getPatchCondition/${route.query.reportingWorkId}`).then(async (res) => { |
| | | // if (res.code == 200) { |
| | |
| | | } |
| | | } |
| | | }, |
| | | menuClick({menu, row, column}) { |
| | | menuClick({menu, row, column}) {//右键菜单 |
| | | const $grid = xGrid.value |
| | | if ($grid) { |
| | | switch (menu.code) { |
| | |
| | | return item.saveFlag === 0 |
| | | }) |
| | | let process = titleUploadData.value.thisProcess |
| | | //暂时取消 |
| | | for(let item of uniqueByOrderNum){ |
| | | if(!checkSameNumForId(notFinishList,item.order_number ) && (process=='夹胶' || process=='中空' || process=='包装' ||process=='打胶和粘框')){ |
| | | ElMessage.error(`${t('reportingWorks.pleaseCheckTheOrderNumber1')}':' |
| | |
| | | const gridEvents = { |
| | | async toolbarButtonClick({code}) { |
| | | const $grid = xGrid.value |
| | | const checkedList = $grid.getCheckboxRecords() |
| | | if ($grid) { |
| | | switch (code) { |
| | | case 'transferOrder': { |
| | | if (checkedList.length !== 1) { |
| | | ElMessage.warning(t('workOrder.msgSelect')) |
| | | return |
| | | } |
| | | const idList = [] |
| | | $grid.getCheckboxRecords().forEach(item => { |
| | | idList.push(item.orderId) |
| | |
| | | public Boolean updateLayoutStatusSv(String processId, Integer state) { |
| | | |
| | | if (!processId.isEmpty()) { |
| | | // Integer Status = flowCardMapper.selectLayoutStatus(processId); |
| | | |
| | | flowCardMapper.updateLayoutStatusMp(processId, state); |
| | | |
| | | |
| | | return true; |
| | | } else { |
| | | return false; |
| | |
| | | if (object.get("userName") != null) { |
| | | userName = object.get("userName").toString(); |
| | | } |
| | | |
| | | String productionId = ""; |
| | | if (object.get("productionId") != null) { |
| | | productionId = object.get("productionId").toString(); |
| | |
| | | orderProcessDetailList.forEach( |
| | | orderGlassDetail -> orderGlassDetail.setProcessId(flowCard.getProcessId())); |
| | | |
| | | |
| | | //赋值订单工艺表 |
| | | orderProcessDetailMapper.insertOrderProcessDetail(orderProcessDetailList); |
| | | } |
| | |
| | | map.put("data", flowCardMapper.selectNoSchedulingMp(selectTime1, selectTime2, orderId, processes, flowCard)); |
| | | |
| | | } |
| | | |
| | | return map; |
| | | } |
| | | |
| | |
| | | //是否包含切割 |
| | | //boolean containsCutting = flowCard.getProcess().contains("切割"); |
| | | String processSub=flowCard.getProcess().substring(0, 2); |
| | | if(processSub.equals("夹胶") || processSub.equals("中空")){ |
| | | if(processSub.equals("夹胶") || processSub.equals("中空")){//工艺是否包含夹胶中空 |
| | | itemmap.put("detail", flowCardMapper.getPrimaryListLimt(flowCard.getProcessId(), String.valueOf(flowCard.getTechnologyNumber()),flowCard.getGlassChild(),flowCard.getProcess(),flowCard.getOrderId())); |
| | | |
| | | List<Map<String, Object>> detailList = flowCardMapper.getDetailList(flowCard.getProcessId(), flowCard.getTechnologyNumber(),flowCard.getProcess()); |
| | |
| | | |
| | | } |
| | | else { |
| | | |
| | | //流程卡明细数据 |
| | | if (printLike.equals("")||printLike.equals("null") ){ |
| | | itemmap.put("detail", flowCardMapper.getPrimaryListMerge(flowCard.getProcessId(), printMerge, flowCard.getOrderId())); |
| | |
| | | |
| | | public Map<String, Object> getSelectPrintLabelSv1(Map<String, Object> object) { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | |
| | | List<Map<String, Object>> list = new ArrayList<Map<String, Object>>();//最终结果 |
| | | List<FlowCard> flowCardList = JSONArray.parseArray(JSONObject.toJSONString(object.get("printList")), FlowCard.class); |
| | | if (!flowCardList.isEmpty()) { |
| | | for (FlowCard flowCard : flowCardList) { |
| | | // Integer count=flowCardMapper.getPrintLabelCount(flowCard.getProcessId(), flowCard.getTechnologyNumber()); |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | // for (int i = 0; i < count; i++) { |
| | | itemmap.put("data", flowCardMapper.getPrintLabel1(flowCard.getProcessId(), flowCard.getTechnologyNumber())); |
| | | list.add(itemmap); |
| | | //} |
| | | |
| | | } |
| | | } |
| | | map.put("data", list); |
| | |
| | | List<FlowCard> flowCardList = JSONArray.parseArray(JSONObject.toJSONString(object.get("printList")), FlowCard.class); |
| | | if (!flowCardList.isEmpty()) { |
| | | for (FlowCard flowCard : flowCardList) { |
| | | // Integer count=flowCardMapper.getPrintLabelCount(flowCard.getProcessId(), flowCard.getTechnologyNumber()); |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | // for (int i = 0; i < count; i++) { |
| | | itemmap.put("data", flowCardMapper.getPrintLabelDetail(flowCard)); |
| | | list.add(itemmap); |
| | | //} |
| | | |
| | | } |
| | | } |
| | | map.put("data", list); |
| | |
| | | List<FlowCard> FlowCardList = JSONArray.parseArray(JSONObject.toJSONString(object.get("flowCard")), FlowCard.class); |
| | | if (!FlowCardList.isEmpty()) { |
| | | for (FlowCard flowCard : FlowCardList) { |
| | | // flowCardMapper.printSortMp(flowCard.getProcessId(),flowCard.getOrderNumber(),flowCard.getTechnologyNumber(),flowCard.getSort()); |
| | | //判断保存的数据是否已存在 |
| | | Integer count = flowCardMapper.printAddSortCountMp(flowCard.getProcessId(),flowCard.getOrderNumber(),flowCard.getTechnologyNumber(),flowCard.getSort(),flowCard.getProcess()); |
| | | if (count >0){ |
| | |
| | | if (!flowCardList.isEmpty()) { |
| | | Set<String> processedProcessIds = new HashSet<>(); // 用来存放已处理过的 processId |
| | | |
| | | if (lableType != 2){ |
| | | if (lableType != 2){//成品标签 |
| | | for (FlowCard flowCard : flowCardList) { |
| | | String processId = flowCard.getProcessId(); |
| | | |
| | |
| | | processedProcessIds.add(processId); |
| | | } |
| | | } |
| | | else{ |
| | | else{//小片标签 |
| | | for (FlowCard flowCard : flowCardList) { |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | itemmap.put("data", flowCardMapper.getPrintCustomDataSemi(flowCard.getProcessId(),flowCard.getTechnologyNumber(),flowCard.getProcess())); |
| | |
| | | if (!flowCardList.isEmpty()) { |
| | | Set<String> processedProcessIds = new HashSet<>(); // 用来存放已处理过的 processId |
| | | |
| | | if (lableType != 2){ |
| | | if (lableType != 2){//成品标签 |
| | | for (FlowCard flowCard : flowCardList) { |
| | | String processId = flowCard.getProcessId(); |
| | | String orderNumber = flowCard.getOrderNumber().toString(); |
| | |
| | | processedProcessIds.add(orderNumber); |
| | | } |
| | | } |
| | | else{ |
| | | else{//小片标签 |
| | | for (FlowCard flowCard : flowCardList) { |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | itemmap.put("data", flowCardMapper.getPrintCustomDataSemi(flowCard.getProcessId(),flowCard.getTechnologyNumber(),flowCard.getProcess())); |
| | |
| | | } |
| | | List<FlowCard> flowCardList = JSONArray.parseArray(JSONObject.toJSONString(object.get("composing")), FlowCard.class); |
| | | for (FlowCard flowCard : flowCardList) { |
| | | //查询是否报工 |
| | | Integer count = flowCardMapper.reportingWorkCount(flowCard.getProcessId()); |
| | | if (count == 0) { |
| | | //修改分架状态 |
| | |
| | | Set<String> processedProcessIds = new HashSet<>(); // 用来存放已处理过的 processId |
| | | for (FlowCard flowCard : flowCardList) { |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | if (detailType==0){ |
| | | //是否是工程明细打印 |
| | | if (detailType==0){//工程打印明细 |
| | | itemmap.put("data", flowCardMapper.getPrintCustomDataProjectDetail(flowCard.getProjectNo(),flowCard.getStockId())); |
| | | |
| | | } |
| | | //非工程打印 |
| | | else if (detailType==1) { |
| | | itemmap.put("data", flowCardMapper.getPrintCustomDataProject(flowCard.getProjectNo())); |
| | | |
| | |
| | | List<ProductionScheduling> schedulinglist = JSONArray.parseArray(JSONObject.toJSONString(object.get("scheduling")), ProductionScheduling.class); |
| | | if (!schedulinglist.isEmpty()) { |
| | | for (ProductionScheduling productionScheduling : schedulinglist) { |
| | | //查询已排产工序数量 |
| | | // Integer num = productionSchedulingMapper.selectNumberMp(productionScheduling.getOrderId(),productionScheduling.getOrderNumber(),processes); |
| | | |
| | | productionSchedulingMapper.insertSelective(schedulingId,productionScheduling.getOrderGlassDetail().getOrderId(),productionScheduling.getOrderNumber(),productionScheduling.getTechnologyNumber(),processes,productionScheduling.getSchedulingQuantity(),productionScheduling.getScheduledStartTime(),productionScheduling.getPlanEndTime(),productionScheduling.getNotes()); |
| | | // System.out.println(productionScheduling.getOrderId()+"***"+productionScheduling.getOrderGlassDetail().getOrderId()+"--"+productionScheduling.getOrderDetail().getOrderId()); |
| | | } |
| | | return true; |
| | | } |
| | |
| | | if (!Scheduling.isEmpty()) { |
| | | for (ProductionScheduling productionScheduling : Scheduling) { |
| | | productionSchedulingMapper.deleteSchedulingMp(productionScheduling.getSchedulingId()); |
| | | // System.out.println(productionScheduling.getOrderNumber()+"***"+productionScheduling.getOrderId()); |
| | | } |
| | | return true; |
| | | } |
| | |
| | | if (!schedulinglist.isEmpty()) { |
| | | for (ProductionScheduling productionScheduling : schedulinglist) { |
| | | productionSchedulingMapper.examineSchedulingMp(productionScheduling.getSchedulingId(),userName,productionScheduling.getSchedulingQuantity(),productionScheduling.getNotes()); |
| | | // System.out.println(productionScheduling.getOrderNumber()+"***"+productionScheduling.getOrderId()); |
| | | } |
| | | return true; |
| | | } |
| | |
| | | if (!schedulinglist.isEmpty()) { |
| | | for (ProductionScheduling productionScheduling : schedulinglist) { |
| | | productionSchedulingMapper.cancelReviewSchedulingMp(productionScheduling.getSchedulingId()); |
| | | // System.out.println(productionScheduling.getOrderNumber()+"***"+productionScheduling.getOrderId()); |
| | | } |
| | | return true; |
| | | } |
| | |
| | | List<FlowCard> flowCardList = JSONArray.parseArray(JSONObject.toJSONString(object.get("printList")), FlowCard.class); |
| | | if (!flowCardList.isEmpty()) { |
| | | for (FlowCard flowCard : flowCardList) { |
| | | if (lableType != 2){ |
| | | if (lableType != 2){//成品标签 |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | itemmap.put("data", flowCardMapper.getRepairPrintCustomData(flowCard.getProcessId(),flowCard.getTechnologyNumber(),flowCard.getReportingWorkId())); |
| | | list.add(itemmap); |
| | | } |
| | | else{ |
| | | else{//小片标签 |
| | | Map<String, Object> itemmap = new HashMap<>(); |
| | | itemmap.put("data", flowCardMapper.getRepairPrintCustomDataSemi(flowCard.getProcessId(),flowCard.getTechnologyNumber(),flowCard.getReportingWorkId())); |
| | | list.add(itemmap); |
| | |
| | | logService.saveLog(log); |
| | | } |
| | | } |
| | | |
| | | // } catch (Exception e) { |
| | | // TransactionAspectSupport.currentTransactionStatus().rollbackToSavepoint(savePoint); |
| | | // //将异常传入数据库 |
| | | // SysError sysError = new SysError(); |
| | | // sysError.setError(e.toString()); |
| | | // sysError.setFunc("updateCancelReviewSv"); |
| | | // sysErrorService.insert(sysError); |
| | | // saveState = false; |
| | | // |
| | | // } |
| | | |
| | | return saveState; |
| | | } |
| | |
| | | list.add(startDate); |
| | | list.add(endDate); |
| | | map.put("selectDate", list); |
| | | // map.put("total",orderMapper.getPageTotal(offset, pageSize, startDate, endDate, orderDetail)); |
| | | return map; |
| | | } |
| | | |
| | |
| | | } else if (optionVal.equals("3")) { |
| | | |
| | | } else { |
| | | |
| | | //没有选择分组 |
| | | map.put("data", reportMapper.workInProgressMp(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | map.put("total", reportMapper.workInProgressTotal(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | |
| | |
| | | } |
| | | |
| | | public List exportDamageReportSv(List<LocalDate> dates) { |
| | | |
| | | return reportMapper.exportDamageReportMp(dates); |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | public List exportWorkInProgressSv(Map<String, Object> dates) { |
| | | //List<LocalDate> date= (List<LocalDate>) dates.get("date"); |
| | | String process= (String) dates.get("processes"); |
| | | String inputVal= (String) dates.get("inputVal"); |
| | | String project= (String) dates.get("project"); |
| | |
| | | /*获取返工管理数据*/ |
| | | public Map<String,Object> reworkMangageData (Integer pageNum, Integer pageSize,String startTime,String endTime) { |
| | | Integer offset = (pageNum-1)*pageSize; |
| | | |
| | | Map<String,Object> map = new HashMap<>(); |
| | | map.put("data",reportingWorkDetailMapper.reworkDataManage(offset,pageSize,startTime,endTime)); |
| | | return map; |
| | |
| | | /*获取返工管理数据*/ |
| | | public Map<String,Object> reworkMangageData2 (Integer pageNum, Integer pageSize,String startTime,String endTime,ReportingWorkDetail reportingWorkDetail ) { |
| | | Integer offset = (pageNum-1)*pageSize; |
| | | |
| | | Map<String,Object> map = new HashMap<>(); |
| | | map.put("data",reportingWorkDetailMapper.reworkDataManage2(offset,pageSize,startTime,endTime, reportingWorkDetail)); |
| | | return map; |
| | |
| | | map.put("device", reportingWorkMapper.SelectWorkBasicDeviceMp(process)); |
| | | //班组下拉框 |
| | | map.put("teams", reportingWorkMapper.SelectWorkBasicTeamsMp(process)); |
| | | |
| | | //次破类型 |
| | | map.put("breakageType", reportingWorkMapper.selectBasicNameByType("breakagetype")); |
| | | //次破原因 |
| | | map.put("breakageReason", reportingWorkMapper.selectBasicNameByType("breakagereason")); |
| | | |
| | | //查询本工序报工需要哪几层,上工序是什么 |
| | |
| | | } |
| | | }); |
| | | } |
| | | |
| | | |
| | | map.put("Detail",details ); |
| | | } |
| | | } |
| | |
| | | //历史工序 |
| | | map.put("historyProcess", reportingWorkMapper.SelectHistoryProcessMp(historyProcess, process)); |
| | | } |
| | | |
| | | |
| | | return map; |
| | | } |
| | | |
| | |
| | | map.put("process", reportingWorkMapper.SelectProcessMp()); |
| | | } |
| | | else { |
| | | //对指定工序单独查询 |
| | | if (process.equals("夹胶")){ |
| | | map.put("process",reportingWorkMapper.getSelectProcessJiajiao() ); |
| | | } |
| | |
| | | reportingWork.setProcessId(processIdStr[0]); |
| | | |
| | | int reviewState = (int) reportingWorkJson.get("type"); |
| | | if (reviewState == 1) { |
| | | if (reviewState == 1) {//审核通过 |
| | | reportingWork.setReviewed(reportingWork.getCreator()); |
| | | reportingWork.setReviewedState(1); |
| | | } else { |
| | |
| | | reportingWorkMapper.insert(reportingWork); |
| | | //副表循环插入,并且插入次破信息表。再根据次破信息修改订单玻璃流程表的完工数量与刺破数量 |
| | | reportingWorkDetails.forEach(reportingWorkDetail -> { |
| | | // reportingWork.setThisProcessQuantity( |
| | | // reportingWork.getThisProcessQuantity() |
| | | // +reportingWorkDetail.getCompletedQuantity() |
| | | // +reportingWorkDetail.getBreakageQuantity()); |
| | | // reportingWork.setThisCompletedQuantity( |
| | | // reportingWork.getThisCompletedQuantity()+reportingWorkDetail.getCompletedQuantity()); |
| | | // reportingWork.setThisWornQuantity( |
| | | // reportingWork.getThisWornQuantity()+reportingWorkDetail.getBreakageQuantity()); |
| | | |
| | | int qualityInsStatus = (int) reportingWorkJson.get("qualityInsStatus"); |
| | | reportingWorkDetail.setReportingWorkId(reportingWorkId); |
| | |
| | | int index = processId.lastIndexOf("/") + 1; |
| | | String result = processId.substring(index); |
| | | String technologyStr = reportingWork.get("technologyStr"); |
| | | |
| | | //合片工序 |
| | | if (thisProcess.equals("夹胶") || thisProcess.equals("中空") || thisProcess.equals("包装")){ |
| | | LambdaUpdateWrapper |
| | | <ReportingWork> updateWrapper = new LambdaUpdateWrapper<>(); |
| | |
| | | }); |
| | | |
| | | Map<String, Object> map = new HashMap<>(); |
| | | //报工主表 |
| | | map.put("reportingWork", reportingWork); |
| | | //报工明细 |
| | | map.put("reportingWorkDetails", reportingWorkDetails); |
| | | //报工下拉框数据 |
| | | map.put("basic", getReportingWorkBase(reportingWork.getProcessId(), reportingWork.getThisProcess())); |
| | | //根据报工编号获取层 |
| | | map.put("layer", reportingWorkMapper.selectLayerByReportingWorkId(reportingWorkId)); |
| | |
| | | map.put("deviceType", reportingWorkMapper.SelectWorkBasicDeviceMp(thisProcess)); |
| | | //班组下拉框 |
| | | map.put("teamsType", reportingWorkMapper.SelectWorkBasicTeamsMp(thisProcess)); |
| | | |
| | | //次破类型 |
| | | map.put("breakageType", reportingWorkMapper.selectBasicNameByType("breakagetype")); |
| | | //次破原因 |
| | | map.put("breakageReason", reportingWorkMapper.selectBasicNameByType("breakagereason")); |
| | | |
| | | //获取该流程卡号历史报工工序 |
| | |
| | | .delete(new LambdaQueryWrapper<ReportingWorkDetail>() |
| | | .eq(ReportingWorkDetail::getReportingWorkId, reportingWork.getReportingWorkId())); |
| | | |
| | | //更细报工主表 |
| | | //更新报工主表 |
| | | int qualityInsStatus = (int) reportingWorkJson.get("qualityInsStatus"); |
| | | reportingWorkMapper.updateById(reportingWork); |
| | | reportingWorkDetails.forEach(reportingWorkDetail -> { |
| | |
| | | damageDetail.setProcessId(reportingWork.getProcessId()); |
| | | damageDetail.setOrderNumber(reportingWorkDetail.getOrderNumber()); |
| | | damageDetail.setTechnologyNumber(reportingWorkDetail.getTechnologyNumber()); |
| | | //是否修改质检状态 |
| | | if (!Objects.equals(reportingWork.getThisProcess(), damageDetail.getResponsibleProcess()) && qualityInsStatus==2) { |
| | | damageDetail.setQualityInsStatus(1); |
| | | } |
| | |
| | | //查询工单 |
| | | public Map<String, Object> defaultDateWork(Date selectTime1, Date selectTime2, Integer state, OrderGlassDetail orderGlassDetail) { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | if (state == 1) { |
| | | if (state == 1) {//已转工单 |
| | | map.put("data", workOrderMapper.selectWordOrder(selectTime1, selectTime2, orderGlassDetail)); |
| | | } else { |
| | | } else {//未转工单 |
| | | map.put("data", workOrderMapper.selectWordOrderNo(selectTime1, selectTime2, orderGlassDetail)); |
| | | } |
| | | |
| | |
| | | Integer noWorkCount = workOrderMapper.selectWorkCount(orderId); |
| | | //查询该订单转生产订单的条数 |
| | | Integer yesWorkCount = workOrderMapper.selectYesWorkCount(orderId); |
| | | if (noWorkCount.equals(yesWorkCount)) { |
| | | workOrderMapper.updateWorkType(orderId, state); |
| | | if (noWorkCount.equals(yesWorkCount)) {//判断订单是否全部转工单 |
| | | workOrderMapper.updateWorkType(orderId, state);//全部 |
| | | } else { |
| | | workOrderMapper.updateWorkType(orderId, states); |
| | | workOrderMapper.updateWorkType(orderId, states);//部分 |
| | | } |
| | | return true; |
| | | } |
| | |
| | | AND dd.technology_number = ogd.technology_number |
| | | left join sd.order_detail as od on o.order_id = od.order_id and od.order_number=ogd.order_number |
| | | WHERE |
| | | DATE_FORMAT((rw.reporting_work_time), '%Y-%m-%d') between #{selectTime1} and #{selectTime2} |
| | | rw.reporting_work_time >= #{selectTime1} |
| | | AND rw.reporting_work_time < #{selectTime2} |
| | | |
| | | AND dd.available = 0 |
| | | AND LENGTH( rw.process_id )= 14 |
| | | <if test="damageReportDTO.orderId != null and damageReportDTO.orderId != ''"> |
| | |
| | | LEFT JOIN sd.order_glass_detail AS ogd |
| | | ON od.order_id = ogd.order_id |
| | | AND od.order_number = ogd.order_number |
| | | <if test="process == '夹胶' or (process == '打胶和粘框' and previousProcess=='夹胶')"> |
| | | <if test="process == '夹胶' or (process == '打胶和粘框')"> |
| | | AND ogd.`group` = (select `group` |
| | | from sd.order_glass_detail |
| | | where order_id = ogd.order_id |
| | |
| | | LEFT JOIN sd.order_glass_detail AS ogd |
| | | ON od.order_id = ogd.order_id |
| | | AND od.order_number = ogd.order_number |
| | | <if test="process == '夹胶' or (process == '打胶和粘框' and previousProcess=='夹胶')"> |
| | | <if test="process == '夹胶' or (process == '打胶和粘框')"> |
| | | AND ogd.`group` = (select `group` |
| | | from sd.order_glass_detail |
| | | where order_id = ogd.order_id |