问题修改

This commit is contained in:
z 2025-07-10 21:12:33 +08:00
parent 552e787fbf
commit e2ceafc29d
25 changed files with 381 additions and 109 deletions

View File

@ -10,6 +10,7 @@ import lombok.Getter;
@Getter
public enum TaskDispatchStatusEnum {
Unedited(0, "未编辑"),
SAVE(1, "已保存"),
SUBMIT(2, "已提交"),
CANCEL_SUBMIT(1, "取消提交"),

View File

@ -161,7 +161,7 @@ public class bdgzsomthingController {
public void init() {
selectHasPrice();
selectSafeStorageAndDeliverOneYear();
bdgzsomthingService.selectds();
// bdgzsomthingService.selectds();
}
@Scheduled(cron = "0 0 2 * * ?")
public void selectHasPrice(){

View File

@ -247,8 +247,6 @@ public class ProcessBomController {
PageResult<ProcessBomDetailDO> pageResult = processBomService.getStandardPage(pageReqVO);
return success(pageResult);
}
@PostMapping("/submit")
@Operation(summary = "提交")
@PreAuthorize("@ss.hasPermission('heli:process-bom:create')")

View File

@ -10,6 +10,7 @@ import com.chanko.yunxi.mes.framework.operatelog.core.annotations.OperateLog;
import com.chanko.yunxi.mes.framework.operatelog.core.enums.OperateTypeEnum;
import com.chanko.yunxi.mes.module.heli.config.HeliWebConfiguration;
import com.chanko.yunxi.mes.module.heli.controller.admin.taskdispatch.vo.TaskDispatchSaveReqVO;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.QualityStatistics;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationPageReqVO;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationRespVO;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationSaveReqVO;
@ -176,9 +177,19 @@ public class UnqualifiedNotificationController {
@GetMapping("/statisticPage")
@Operation(summary = "获得品质异常单统计分页")
@PreAuthorize("@ss.hasPermission('heli:unqualified-notification:query')")
public CommonResult<PageResult<UnqualifiedNotificationRespVO>> getUnqualifiedNotificationStatisticPage(@Valid UnqualifiedNotificationPageReqVO pageReqVO) {
PageResult<UnqualifiedNotificationDO> pageResult = unqualifiedNotificationService.getUnqualifiedNotificationStatisticPage(pageReqVO);
return success(BeanUtils.toBean(pageResult, UnqualifiedNotificationRespVO.class));
public CommonResult<PageResult<QualityStatistics>> getUnqualifiedNotificationStatisticPage(@Valid UnqualifiedNotificationPageReqVO pageReqVO) {
PageResult<QualityStatistics> pageResult = unqualifiedNotificationService.getUnqualifiedNotificationStatisticPage(pageReqVO);
return success(pageResult);
}
@GetMapping("/exportStatisticPage")
@Operation(summary = "导出质量异常统计 Excel")
@OperateLog(type = EXPORT)
public void exportStatisticPage(@Valid UnqualifiedNotificationPageReqVO pageReqVO,
HttpServletResponse response) throws IOException {
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
List<QualityStatistics> list = unqualifiedNotificationService.getUnqualifiedNotificationStatisticPage(pageReqVO).getList();
// 导出 Excel
ExcelUtils.write(response, "质量异常统计.xls", "数据", QualityStatistics.class,
BeanUtils.toBean(list, QualityStatistics.class));
}
}

View File

@ -0,0 +1,60 @@
package com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import com.chanko.yunxi.mes.framework.common.pojo.PageParam;
import com.chanko.yunxi.mes.framework.excel.core.annotations.DictFormat;
import com.chanko.yunxi.mes.framework.excel.core.convert.DictConvert;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import static com.chanko.yunxi.mes.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Data
@ToString(callSuper = true)
public class QualityStatistics {
@ExcelProperty("项目名称")
private String projectName;
@ExcelProperty("客户名称")
private String customerName;
@ExcelProperty("子项目名称")
private String projectSubName;
@ExcelProperty("零件名称")
private String bomName;
@ExcelProperty(value = "质检类型", converter = DictConvert.class)
@DictFormat("heli_inspection_type")
private Integer type;
@ExcelProperty("是否合格")
private String isQua;
@ExcelProperty("数量")
private BigDecimal amount;
@ExcelProperty("检验人")
private String userName;
@ExcelProperty("检验时间")
private String testingTime;
@ExcelProperty("工序")
private String procedureName;
@ExcelProperty("审核人")
private String auditorName;
@ExcelProperty("审核时间")
private String auditTime;
@ExcelProperty(value = "审核意见", converter = DictConvert.class)
@DictFormat("heli_unqualified_notification_opinion")
private Integer auditOpinion;
@ExcelProperty("项目编码")
private String projectCode;
@ExcelProperty("子项目编码")
private String projectSubNumber;
}

View File

@ -175,7 +175,8 @@ public class TaskDispatchDO extends BaseDO {
public boolean canOperate(OperateTypeEnum operateTypeEnum) {
switch (operateTypeEnum){
case SAVE:
return canSave();
return true;
// return canSave();
case SUBMIT:
return canSubmit();
case CANCEL_SUBMIT:

View File

@ -1,7 +1,9 @@
package com.chanko.yunxi.mes.module.heli.dal.mysql.unqualifiednotification;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.chanko.yunxi.mes.framework.common.pojo.PageResult;
import com.chanko.yunxi.mes.framework.mybatis.core.mapper.BaseMapperX;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.QualityStatistics;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationPageReqVO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.composition.CompositionDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.customer.CustomerDO;
@ -15,8 +17,11 @@ import com.chanko.yunxi.mes.module.heli.dal.dataobject.unqualifiednotification.U
import com.chanko.yunxi.mes.module.system.dal.dataobject.user.AdminUserDO;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.util.StringUtils;
import java.util.List;
/**
* 品质异常通知单审核 Mapper
*
@ -119,4 +124,6 @@ public interface UnqualifiedNotificationMapper extends BaseMapperX<UnqualifiedNo
return selectPage(reqVO, query);
}
List<QualityStatistics> QualityStatistics(@Param("page") Page<QualityStatistics> page, @Param("pageReqVO") UnqualifiedNotificationPageReqVO pageReqVO);
}

View File

@ -584,7 +584,7 @@ public class CrossOrderManager {
.setBomDetailId(planTaskBomDO.getBomDetailId())
.setBomBlueprintNo(planTaskBomDO.getBomBlueprintNo() == null ?"":planTaskBomDO.getBomBlueprintNo())
.setActive(OperateTypeEnum.SAVE.name())
.setDispatchStatus(TaskDispatchStatusEnum.SAVE.getCode())
.setDispatchStatus(TaskDispatchStatusEnum.Unedited.getCode())
.setStatus(ValidStatusEnum.VALID.getCode());
taskDispatchService.createTaskDispatch(taskDispatchSaveReqVO);
}
@ -617,7 +617,7 @@ public class CrossOrderManager {
.setBomBlueprintNo(planTaskBomDO.getBomBlueprintNo() == null ?"":planTaskBomDO.getBomBlueprintNo())
.setBomDetailId(planTaskBomDO.getBomDetailId())
.setActive(OperateTypeEnum.SAVE.name())
.setDispatchStatus(TaskDispatchStatusEnum.SAVE.getCode())
.setDispatchStatus(TaskDispatchStatusEnum.Unedited.getCode())
.setStatus(ValidStatusEnum.VALID.getCode());
taskDispatchService.createTaskDispatch(taskDispatchSaveReqVO);
});

View File

@ -334,6 +334,7 @@ public class MaterialPlanServiceImpl implements MaterialPlanService {
BdgzsomthingDO.setThings("物料需求计划单号:" + planDO.getProjectMaterialPlanNo() + "已提交");//事件名称
BdgzsomthingDO.setAttr2(planDO.getProjectMaterialPlanNo());//跳转携带参数
BdgzsomthingDO.setAttr3(planDO.getProjectMaterialPlanNo());//独特标识
BdgzsomthingDO.setAttr14("1");//独特标识
// BdgzsomthingDO.setClicktime(attentiontodoRespVO.getRemindtime());//提醒周期
// BdgzsomthingDO.setShowname(new Date());比较创建时间,不用单独填写
if (attentiontodoRespVO.getAttr5().equals("1")) {//提醒状态

View File

@ -1136,6 +1136,7 @@ public class ProcessBomServiceImpl implements ProcessBomService {
BdgzsomthingDO.setThings("物料需求计划单号:"+planDO.getProjectMaterialPlanNo()+"已提交");//事件名称
BdgzsomthingDO.setAttr2(planDO.getProjectMaterialPlanNo());//跳转携带参数
BdgzsomthingDO.setAttr3(planDO.getProjectMaterialPlanNo());//独特标识
BdgzsomthingDO.setAttr14("0");
// BdgzsomthingDO.setClicktime(attentiontodoRespVO.getRemindtime());//提醒周期
// BdgzsomthingDO.setShowname(new Date());比较创建时间,不用单独填写
if(attentiontodoRespVO.getAttr5().equals("1")){//提醒状态

View File

@ -115,7 +115,7 @@ public class TaskDispatchServiceImpl implements TaskDispatchService {
SerialNumberDO serialNumberDO = serialNumberService.getSerialNumber(taskDispatchTypeEnum.getBusinesTypeEnum().name(), new SimpleDateFormat("yyyyMMdd").format(new Date()));
serialNumberDO.setSerialNumber(serialNumberDO.getSerialNumber()+1);
taskDispatch.setCode(taskDispatchTypeEnum.getCodeEnum().getCode(serialNumberDO.getSerialNumber().toString()));
taskDispatch.setDispatchStatus(TaskDispatchStatusEnum.valueOf(createReqVO.getActive()).getCode());
// taskDispatch.setDispatchStatus(TaskDispatchStatusEnum.valueOf(createReqVO.getActive()).getCode());
taskDispatch.setCreator(getLoginUser().getId().toString());
taskDispatchMapper.insert(taskDispatch);
@ -147,8 +147,6 @@ public class TaskDispatchServiceImpl implements TaskDispatchService {
}
}
if (!ObjectUtil.equal(v1, v2)) {
System.out.println(v1);
System.out.println(v2);
return true;
}
}
@ -195,7 +193,9 @@ public class TaskDispatchServiceImpl implements TaskDispatchService {
}
}
}
if (operateTypeEnum == OperateTypeEnum.SAVE){
updateObj.setDispatchStatus(1);
}
// 明细工序状态更新
if(operateTypeEnum == OperateTypeEnum.SUBMIT){
if (updateReqVO.getDispatchType() != null && updateReqVO.getDispatchType().equals("ASSEMBLE")){

View File

@ -1,11 +1,9 @@
package com.chanko.yunxi.mes.module.heli.service.unqualifiednotification;
import java.util.*;
import javax.validation.*;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.*;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.unqualifiednotification.UnqualifiedNotificationDO;
import com.chanko.yunxi.mes.framework.common.pojo.PageResult;
import com.chanko.yunxi.mes.framework.common.pojo.PageParam;
/**
* 品质异常通知单审核 Service 接口
@ -54,5 +52,5 @@ public interface UnqualifiedNotificationService {
void operate(UnqualifiedNotificationSaveReqVO operateReqVO);
PageResult<UnqualifiedNotificationDO> getUnqualifiedNotificationStatisticPage(UnqualifiedNotificationPageReqVO pageReqVO);
PageResult<QualityStatistics> getUnqualifiedNotificationStatisticPage(UnqualifiedNotificationPageReqVO pageReqVO);
}

View File

@ -1,15 +1,16 @@
package com.chanko.yunxi.mes.module.heli.service.unqualifiednotification;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.chanko.yunxi.mes.framework.common.pojo.PageResult;
import com.chanko.yunxi.mes.framework.common.util.object.BeanUtils;
import com.chanko.yunxi.mes.framework.operatelog.core.enums.OperateTypeEnum;
import com.chanko.yunxi.mes.framework.security.core.util.SecurityFrameworkUtils;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.QualityStatistics;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationPageReqVO;
import com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.UnqualifiedNotificationSaveReqVO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.attentiontodo.AttentiontodoDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.bdgzsomthing.bdgzsomthingDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.serialnumber.SerialNumberDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.taskdispatch.TaskDispatchDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.unqualifiednotification.UnqualifiedNotificationDO;
import com.chanko.yunxi.mes.module.heli.dal.dataobject.unqualifiednotificationfile.UnqualifiedNotificationFileDO;
import com.chanko.yunxi.mes.module.heli.dal.mysql.attentiontodo.AttentiontodoMapper;
@ -225,8 +226,11 @@ try {
}
@Override
public PageResult<UnqualifiedNotificationDO> getUnqualifiedNotificationStatisticPage(UnqualifiedNotificationPageReqVO pageReqVO) {
return unqualifiedNotificationMapper.getStatisticPage(pageReqVO);
public PageResult<QualityStatistics> getUnqualifiedNotificationStatisticPage(UnqualifiedNotificationPageReqVO pageReqVO) {
Page<QualityStatistics> page = new Page<>(pageReqVO.getPageNo(), pageReqVO.getPageSize());
List<QualityStatistics> qualityStatistics = unqualifiedNotificationMapper.QualityStatistics(page, pageReqVO);
// return new PageResult<>(qualityStatistics, page.getTotal());
return null;
}
}

View File

@ -9,4 +9,103 @@
文档可见https://www.iocoder.cn/MyBatis/x-plugins/
-->
<select id="QualityStatistics"
resultType="com.chanko.yunxi.mes.module.heli.controller.admin.unqualifiednotification.vo.QualityStatistics">
SELECT
t.*
FROM
(
SELECT
t.create_time as createTime,
t.project_name AS projectName,
c.NAME AS customerName,
t.project_sub_name AS projectSubName,
t.bom_name AS bomName,
0 AS type,
CASE
WHEN t.is_qua = 1 THEN
'是'
WHEN t.is_qua = 0 THEN
'否' ELSE '未知'
END AS isQua,
t.amount AS amount,
u1.nickname AS userName,
DATE_FORMAT(t.create_time, '%Y-%m-%d') AS testingTime,
pro.NAME AS procedureName,
u2.nickname AS auditorName,
DATE_FORMAT(t.audit_time, '%Y-%m-%d') AS auditTime,
t.audit_opinion AS auditOpinion,
p.CODE AS projectCode,
t.project_sub_number AS projectSubNumber
FROM
quality_pg_master_line t
LEFT JOIN project_sale_order p ON t.project_id = p.id
LEFT JOIN base_customer c ON p.customer_id = c.id
LEFT JOIN system_users u1 ON t.detil_user = u1.id
LEFT JOIN system_users u2 ON t.auditor = u2.id
LEFT JOIN base_procedure pro ON t.procedure_id = pro.id
WHERE
t.is_qua = 1
AND t.deleted = 0
UNION ALL
SELECT
t.create_time as createTime,
t.project_name AS projectName,
c.NAME AS customerName,
t.project_sub_name AS projectSubName,
'' AS bomName,
1 AS type,
CASE
WHEN t.is_qua = 1 THEN
'是'
WHEN t.is_qua = 0 THEN
'否' ELSE '未知'
END AS isQua,
t.amount AS amount,
u1.nickname AS userName,
DATE_FORMAT(t.create_time, '%Y-%m-%d') AS testingTime,
'' AS procedureName,
u2.nickname AS auditorName,
DATE_FORMAT(t.audit_time, '%Y-%m-%d') AS auditTime,
t.audit_opinion AS auditOpinion,
p.CODE AS projectCode,
t.project_sub_number AS projectSubNumber
FROM
quality_zj_pg_master_line t
LEFT JOIN project_sale_order p ON t.project_id = p.id
LEFT JOIN base_customer c ON p.customer_id = c.id
LEFT JOIN system_users u1 ON t.detil_user = u1.id
LEFT JOIN system_users u2 ON t.auditor = u2.id
WHERE
t.is_qua = 1
AND t.deleted = 0
) t
where 1=1
<if test="pageReqVO.projectCode!=null and pageReqVO.projectCode!=''">
and t.projectCode =#{pageReqVO.projectCode}
</if>
<if test="pageReqVO.projectName!=null and pageReqVO.projectName!=''">
and t.projectName =#{pageReqVO.projectName}
</if>
<if test="pageReqVO.projectSubCode!=null and pageReqVO.projectSubCode!=''">
and t.projectSubNumber =#{pageReqVO.projectSubCode}
</if>
<if test="pageReqVO.projectCode!=null and pageReqVO.projectCode!=''">
and t.projectCode =#{pageReqVO.projectCode}
</if>
<if test="pageReqVO.projectSubName!=null and pageReqVO.projectSubName!=''">
and t.projectSubName =#{pageReqVO.projectSubName}
</if>
<if test="pageReqVO.type!=null and pageReqVO.type!=''">
and t.type =#{pageReqVO.type}
</if>
<if test="pageReqVO.auditOpinion!=null and pageReqVO.auditOpinion!=''">
and t.auditOpinion =#{pageReqVO.auditOpinion}
</if>
order by t.createTime desc
</select>
</mapper>

View File

@ -53,3 +53,7 @@ export async function operateUnqualifiedNotification(data: UnqualifiedNotificati
export const getUnqualifiedNotificationStatisticPage = async (params) => {
return await request.get({ url: `/heli/unqualified-notification/statisticPage`, params })
}
// 导出品质异常通知单审核 Excel
export const exportStatisticPage = async (params) => {
return await request.download({ url: `/heli/unqualified-notification/exportStatisticPage`, params })
}

View File

@ -295,5 +295,6 @@ export enum DICT_TYPE {
HELI_STORAGEIN_STATUS='heli_storagein_status',
MATERIAL_PLAN_BOOM_MPLAN_STATUS='material_plan_boom_mplan_status',
HELI_PROJECT_PURCHASE_ORDER_NO_TYPE = 'heli_project_purchase_order_no_type',//采购单类型
HELI_DISPATCH_PRODUCTION_STATUS = 'heli_dispatch_production_status', // 派工单状态
}

View File

@ -546,7 +546,8 @@ const getList = async () => {
jibie: item.level,
dbsx: '',
yesorno:item.yesorno,
sctime: formatTime(item.createTime, 'yyyy-MM-dd HH:mm:ss')
sctime: formatTime(item.createTime, 'yyyy-MM-dd HH:mm:ss'),
attr14:item.attr14
};
switch (item.thingname) {
@ -662,8 +663,16 @@ const handlePay =async (row: any) => {
// router.push({ path: '/order/project', state: { idid: row.idid } });
}
if (row.type == '《物料需求计划》提交后') {
await bdgzsomthingApi.deleteByIdNew(row.id);
router.push({ path: '/purchase/MaterialPlanAudit', state: { idid: row.idid } });
// await bdgzsomthingApi.deleteByIdNew(row.id);
if (row.attr14=='0'){
router.push({ path: '/purchase/buy', state: { idid: row.idid } });
}else {
router.push({ path: '/purchase/PartPurchase', state: { idid: row.idid } });
}
// router.push({ path: '/purchase/MaterialPlanAudit', state: { idid: row.idid } });
// router.push({ path: '/purchase/MaterialPlanAudit', query: { idid: row.idid } });
}
if (row.type == 'BOM变更审核') {
@ -763,6 +772,11 @@ const handlePaysee =async (row: any) => {
// router.push({ path: '/processDesign/heli/processdesign/bomShenhe', state: { idid: row.idid } });
await bdgzsomthingApi.updatebdgzsomthingbyidoneandok(row.id) //
}
if (row.type == '《采购订单》到货时通知检验') {
// router.push({ path: '/processDesign/heli/processdesign/bomShenhe', state: { idid: row.idid } });
// router.push({ path: '/processDesign/heli/processdesign/bomShenhe', state: { idid: row.idid } });
await bdgzsomthingApi.updatebdgzsomthingbyidoneandok(row.id) //
}
if (row.type == '装配任务到期'){
await bdgzsomthingApi.updatebdgzsomthingbyidoneandok(row.id) //
}

View File

@ -1,7 +1,7 @@
<template>
<el-card class="hl-card">
<template #header>
<span>物料需求计划管理</span>
<span>标准件需求计划管理</span>
</template>
<ContentWrap class="borderxx">
<!-- 搜索工作栏 -->
@ -36,13 +36,7 @@
<ContentWrap>
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true" class="hl-table">
<el-table-column label="序号" type="index" align="center" fixed min-width="70px" />
<el-table-column label="物料需求计划单号" align="center" prop="projectMaterialPlanNo" min-width="180" fixed>
<template #default="scope">
<el-button text type="primary" @click="openForm('detail', scope.row.id)">
{{ scope.row.projectMaterialPlanNo }}
</el-button>
</template>
</el-table-column>
<el-table-column label="项目名称" align="center" prop="projectName" min-width="180px" />
<el-table-column label="子项目名称" align="center" prop="name" min-width="180px" />
<el-table-column label="客户简称" align="center" prop="brief" min-width="180px" />
@ -52,6 +46,13 @@
<dict-tag :type="DICT_TYPE.HELI_MAT_TYPE" :value="scope.row.matType" />
</template>
</el-table-column>
<el-table-column label="物料需求计划单号" align="center" prop="projectMaterialPlanNo" min-width="180" fixed>
<template #default="scope">
<el-button text type="primary" @click="openForm('detail', scope.row.id)">
{{ scope.row.projectMaterialPlanNo }}
</el-button>
</template>
</el-table-column>
<el-table-column label="操作" align="center" fixed="right" min-width="180">
<template #default="scope">
<el-button

View File

@ -1,7 +1,7 @@
<template>
<el-card class="hl-card">
<template #header>
<span>物料需求计划管理</span>
<span>零件需求计划管理</span>
</template>
<ContentWrap class="borderxx">
<!-- 搜索工作栏 -->
@ -36,13 +36,7 @@
<ContentWrap>
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true" class="hl-table">
<el-table-column label="序号" type="index" align="center" fixed min-width="70px" />
<el-table-column label="物料需求计划单号" align="center" prop="projectMaterialPlanNo" min-width="180" fixed>
<template #default="scope">
<el-button text type="primary" @click="openForm('detail', scope.row.id)">
{{ scope.row.projectMaterialPlanNo }}
</el-button>
</template>
</el-table-column>
<el-table-column label="项目名称" align="center" prop="projectName" min-width="180px" />
<el-table-column label="子项目名称" align="center" prop="name" min-width="180px" />
<el-table-column label="客户简称" align="center" prop="brief" min-width="180px" />
@ -52,6 +46,13 @@
<dict-tag :type="DICT_TYPE.HELI_MAT_TYPE" :value="scope.row.matType" />
</template>
</el-table-column>
<el-table-column label="物料需求计划单号" align="center" prop="projectMaterialPlanNo" min-width="180" fixed>
<template #default="scope">
<el-button text type="primary" @click="openForm('detail', scope.row.id)">
{{ scope.row.projectMaterialPlanNo }}
</el-button>
</template>
</el-table-column>
<el-table-column label="操作" align="center" fixed="right" min-width="180">
<template #default="scope">
<el-button

View File

@ -221,7 +221,14 @@ const getList = async () => {
loading.value = true
try {
multipleTable.value.clearSelection();
const idid = history.state.idid;
if(idid){
queryParams.projectMaterialPlanNo=idid
}
const data = await materialPlanBoomApi.getStandardBuyPage(queryParams)
history.state.idid=undefined
list.value = data.list
total.value = data.total
} finally {

View File

@ -220,7 +220,14 @@ const getList = async () => {
loading.value = true
try {
list.value=[]
const idid = history.state.idid;
if(idid){
queryParams.projectMaterialPlanNo=idid
}
const data = await MaterialPlanApi.getPartPurchasePages(queryParams)
history.state.idid=undefined
list.value = data.list
list.value.forEach(item=> {
if(item.isFoams == 'Y'){

View File

@ -407,40 +407,7 @@ v-for="dict in userInit" :key="dict.id"
<el-table-column min-width="180px" align="center">
<template #header>2D开始日期</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.startTwoDimDate`" class="mb-0px!">
<el-date-picker
class="!w-265px" v-model="row.startTwoDimDate" type="date" value-format="x"
placeholder="2D开始日期" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)"/>
</el-form-item>
</template>
</el-table-column>
<el-table-column min-width="180px" align="center">
<template #header>2D结束日期</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.twoDimDate`" class="mb-0px!">
<el-date-picker
class="!w-265px" v-model="row.twoDimDate" type="date" value-format="x"
placeholder="2D结束日期" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)"/>
</el-form-item>
</template>
</el-table-column>
<el-table-column prop="twoDimNum" label="2D工时" min-width="90px" align="center" />
<el-table-column min-width="150" align="center">
<template #header>2D负责人</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.twoDimOwner`" class="mb-0px!">
<el-select class="!w-265px" v-model="row.twoDimOwner" clearable @update:new-value="handleSelectedUser7($index,$event)" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)" filterable>
<el-option
v-for="dict in userInit" :key="dict.id"
:label="dict.username+' '+dict.nickname" :value="dict.id" />
</el-select>
<!-- <UserSelect v-model="row.twoDimOwner" @update:new-value="handleSelectedUser7($index,$event)" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)" class="!w-265px"/>-->
</el-form-item>
</template>
</el-table-column>
<el-table-column min-width="180px" align="center">
<template #header>3D开始日期</template>
<template #default="{ row, $index }">
@ -475,6 +442,40 @@ v-for="dict in userInit" :key="dict.id"
</el-form-item>
</template>
</el-table-column>
<el-table-column min-width="180px" align="center">
<template #header>2D开始日期</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.startTwoDimDate`" class="mb-0px!">
<el-date-picker
class="!w-265px" v-model="row.startTwoDimDate" type="date" value-format="x"
placeholder="2D开始日期" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)"/>
</el-form-item>
</template>
</el-table-column>
<el-table-column min-width="180px" align="center">
<template #header>2D结束日期</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.twoDimDate`" class="mb-0px!">
<el-date-picker
class="!w-265px" v-model="row.twoDimDate" type="date" value-format="x"
placeholder="2D结束日期" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)"/>
</el-form-item>
</template>
</el-table-column>
<el-table-column prop="twoDimNum" label="2D工时" min-width="90px" align="center" />
<el-table-column min-width="150" align="center">
<template #header>2D负责人</template>
<template #default="{ row, $index }">
<el-form-item :prop="`${$index}.twoDimOwner`" class="mb-0px!">
<el-select class="!w-265px" v-model="row.twoDimOwner" clearable @update:new-value="handleSelectedUser7($index,$event)" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)" filterable>
<el-option
v-for="dict in userInit" :key="dict.id"
:label="dict.username+' '+dict.nickname" :value="dict.id" />
</el-select>
<!-- <UserSelect v-model="row.twoDimOwner" @update:new-value="handleSelectedUser7($index,$event)" @change="handleDateChange($index, row.startTwoDimDate,row.twoDimDate,'2',row.twoDimOwner,row.id)" class="!w-265px"/>-->
</el-form-item>
</template>
</el-table-column>
<el-table-column prop="compositionName" label="主要材质" min-width="100px" align="center" />
<el-table-column prop="projectSubCode" label="子项目编号" min-width="180px" align="center" />
<el-table-column prop="unit" label="单位" min-width="90px" align="center">

View File

@ -178,7 +178,7 @@ class="!w-260px" v-model="formData.requiredCompletedDate" type="date" value-form
</template>
<el-row>
<el-col>
<el-checkbox-group v-if="active != 'detail' && formData.dispatchStatus == 1 " v-model="checkList" @change="onAddItem()">
<el-checkbox-group v-if="active != 'detail' && (formData.dispatchStatus == 1||formData.dispatchStatus == 0) " v-model="checkList" @change="onAddItem()">
<el-checkbox label="下料" size="large" border />
<el-checkbox label="电焊" size="large" border />
<el-checkbox label="编程" size="large" border />
@ -425,6 +425,21 @@ v-model="row.deviceModel"
<el-card class="hl-card-info">
<template #header>
<div class="hl-card-info-icona"></div><span class="hl-card-info-text">操作日志</span>
<el-button @click="handleClose" size="large" style="margin-left: 50px"> </el-button>
<el-button v-if="showBefore == 0" @click="nextItem(1)" size="large" type="info">上一页</el-button>
<el-button
v-if="active != 'detail' && (formData.dispatchStatus == 1||formData.dispatchStatus == 0)" @click="submitForm('SAVE')" type="primary"
:disabled="formLoading" size="large"> </el-button>
<el-button
v-if="active != 'detail' && (formData.dispatchStatus == 1||formData.dispatchStatus == 0)" @click="submitForm('SUBMIT')" type="success"
:disabled="formLoading" size="large"> </el-button>
<el-button
v-if="active != 'detail' && formData.dispatchStatus == 2" @click="submitForm('CANCEL_SUBMIT')"
type="danger" :disabled="formLoading" size="large">取消提交</el-button>
<el-button
v-if="formData.dispatchStatus == 2" @click="printHandle(formData.id)" :disabled="formLoading"
size="large" type="primary">打印流程卡</el-button>
<el-button v-if="showNext == 0" @click="nextItem(2)" size="large" type="info">下一页</el-button>
</template>
<el-row>
<el-col>
@ -445,24 +460,24 @@ v-model="row.deviceModel"
</el-row>
</el-card>
</el-form>
<div class="hl-footer text-center">
<!-- <div class="hl-footer text-center">-->
<el-button @click="handleClose" size="large"> </el-button>
<el-button v-if="showBefore == 0" @click="nextItem(1)" size="large" type="info">上一页</el-button>
<el-button
v-if="active != 'detail' && formData.dispatchStatus == 1" @click="submitForm('SAVE')" type="primary"
:disabled="formLoading" size="large"> </el-button>
<el-button
v-if="active != 'detail' && formData.dispatchStatus == 1" @click="submitForm('SUBMIT')" type="success"
:disabled="formLoading" size="large"> </el-button>
<el-button
v-if="active != 'detail' && formData.dispatchStatus == 2" @click="submitForm('CANCEL_SUBMIT')"
type="danger" :disabled="formLoading" size="large">取消提交</el-button>
<el-button
v-if="formData.dispatchStatus == 2" @click="printHandle(formData.id)" :disabled="formLoading"
size="large" type="primary">打印流程卡</el-button>
<el-button v-if="showNext == 0" @click="nextItem(2)" size="large" type="info">下一页</el-button>
</div>
<!-- <el-button @click="handleClose" size="large"> </el-button>-->
<!-- <el-button v-if="showBefore == 0" @click="nextItem(1)" size="large" type="info">上一页</el-button>-->
<!-- <el-button-->
<!--v-if="active != 'detail' && formData.dispatchStatus == 1" @click="submitForm('SAVE')" type="primary"-->
<!-- :disabled="formLoading" size="large"> </el-button>-->
<!-- <el-button-->
<!--v-if="active != 'detail' && formData.dispatchStatus == 1" @click="submitForm('SUBMIT')" type="success"-->
<!-- :disabled="formLoading" size="large"> </el-button>-->
<!-- <el-button-->
<!--v-if="active != 'detail' && formData.dispatchStatus == 2" @click="submitForm('CANCEL_SUBMIT')"-->
<!-- type="danger" :disabled="formLoading" size="large">取消提交</el-button>-->
<!-- <el-button-->
<!--v-if="formData.dispatchStatus == 2" @click="printHandle(formData.id)" :disabled="formLoading"-->
<!-- size="large" type="primary">打印流程卡</el-button>-->
<!-- <el-button v-if="showNext == 0" @click="nextItem(2)" size="large" type="info">下一页</el-button>-->
<!-- </div>-->
<div>
<!-- 排产弹框 -->
<el-dialog v-model="dialogTableVisible" title="dialogTitle" width="1000">

View File

@ -29,7 +29,7 @@
</el-form-item>
<el-form-item label="单据状态" prop="dispatchStatus">
<el-select v-model="queryParams.dispatchStatus" placeholder="请选择单据状态" clearable class="!w-240px">
<el-option v-for="dict in getIntDictOptions(DICT_TYPE.HELI_DISPATCH_STATUS)" :key="dict.value" :label="dict.label" :value="dict.value" />
<el-option v-for="dict in getIntDictOptions(DICT_TYPE.HELI_DISPATCH_PRODUCTION_STATUS)" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="任务负责人" prop="ownerName">
@ -78,7 +78,7 @@
<el-table-column fixed="right" label="要求完成时间" align="center" prop="requiredCompletedDate" :formatter="dateFormatter2" width="160" />
<el-table-column fixed="right" label="单据状态" align="center" prop="dispatchStatus" width="140">
<template #default="scope">
<dict-tag :type="DICT_TYPE.HELI_DISPATCH_STATUS" :value="scope.row.dispatchStatus" />
<dict-tag :type="DICT_TYPE.HELI_DISPATCH_PRODUCTION_STATUS" :value="scope.row.dispatchStatus" />
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" align="center" width="200">
@ -175,7 +175,7 @@ const openForm = (type: string, id?: number) => {
formRef.value.open(type, id)
}
const openDispatching = (type,id,ownerId,taskCode) => {
Dispatchingref.value.open(id,type,queryParams,ownerId,taskCode)
Dispatchingref.value.open(id,type,queryParams,ownerId,taskCode)
}
/** 删除按钮操作 */

View File

@ -41,6 +41,14 @@
<el-button @click="resetQuery">
<Icon icon="ep:refresh" class="mr-5px" /> 重置
</el-button>
<el-button
type="success"
plain
@click="handleExportDetail"
:loading="exportLoading"
>
<Icon icon="ep:download" class="mr-5px" /> 导出
</el-button>
</el-form-item>
</el-form>
</ContentWrap>
@ -49,23 +57,32 @@
<ContentWrap>
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true" class="hl-table">
<el-table-column fixed type="index" width="100" label="序号" align="center" />
<el-table-column fixed label="项目编号" align="center" prop="projectCode" width="220" />
<el-table-column fixed label="项目名称" align="center" prop="projectName" width="180" />
<el-table-column label="项目名称" align="center" prop="projectName" width="180" />
<el-table-column label="客户名称" align="center" prop="customerName" width="160" />
<el-table-column label="子项目名称" align="center" prop="projectSubName" width="180" />
<el-table-column label="零件名称" align="center" prop="bomName" width="160" />
<el-table-column label="质检类型" align="center" prop="type" width="140">
<template #default="scope">
<!-- <dict-tag :type="DICT_TYPE.HELI_INSPECTION_TYPE" :value="scope.row.type" />-->
{{ getDictLabel(DICT_TYPE.HELI_INSPECTION_TYPE,scope.row.type) }}
</template>
</el-table-column>
<el-table-column label="是否合格" align="center" prop="isQua" width="100" />
<el-table-column label="数量" align="center" prop="amount" width="100" />
<el-table-column label="检验人" align="center" prop="userName" width="100" />
<el-table-column label="检验时间" align="center" prop="testingTime" width="140" />
<el-table-column label="工序" align="center" prop="procedureName" width="140" />
<el-table-column label="审核人" align="center" prop="auditorName" width="100" />
<el-table-column label="审核时间" align="center" prop="auditTime" width="140" />
<el-table-column label="审核意见" align="center" prop="auditOpinion" width="120">
<template #default="scope">
<!-- <dict-tag :type="DICT_TYPE.HELI_UNQUALIFIED_NOTIFICATION_OPINION" :value="scope.row.auditOpinion" />-->
{{ getDictLabel(DICT_TYPE.HELI_UNQUALIFIED_NOTIFICATION_OPINION,scope.row.auditOpinion) }}
</template>
</el-table-column>
<el-table-column label="项目编号" align="center" prop="projectCode" width="220" />
<el-table-column label="子项目编号" align="center" prop="projectSubCode" width="260" />
<el-table-column label="零件名称" align="center" prop="materialName" width="160" />
<el-table-column fixed="right" label="质检类型" align="center" prop="type" width="140">
<template #default="scope">
<dict-tag :type="DICT_TYPE.HELI_INSPECTION_TYPE" :value="scope.row.type" />
</template>
</el-table-column>
<el-table-column fixed="right" label="异常数量" align="center" prop="statisticAmount" width="140" />
<el-table-column fixed="right" label="审核意见" align="center" prop="auditOpinion" width="120">
<template #default="scope">
<dict-tag :type="DICT_TYPE.HELI_UNQUALIFIED_NOTIFICATION_OPINION" :value="scope.row.auditOpinion" />
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<Pagination :total="total" v-model:page="queryParams.pageNo" v-model:limit="queryParams.pageSize"
@ -78,7 +95,11 @@
import { getIntDictOptions, getStrDictOptions, DICT_TYPE } from '@/utils/dict'
import * as UnqualifiedNotificationApi from '@/api/heli/unqualifiednotification'
import { useCommonStore } from "@/store/modules/common";
import { getUnqualifiedNotificationStatisticPage } from "@/api/heli/unqualifiednotification";
import {
exportStatisticPage,
getUnqualifiedNotificationStatisticPage
} from "@/api/heli/unqualifiednotification";
import download from "@/utils/download";
defineOptions({ name: 'UnqualifiedNotificationStatistic' })
@ -129,7 +150,26 @@ const handleQuery = () => {
queryParams.pageNo = 1
getList()
}
const getDictLabel = (dictType, value) => {
var intDictOptions = getIntDictOptions(dictType);
const dict = intDictOptions.find(item => item.value == value)
return dict?.label || value //
}
/** 导出按钮操作 */
const handleExportDetail = async () => {
try {
//
await message.exportConfirm()
//
exportLoading.value = true
const data = await UnqualifiedNotificationApi.exportStatisticPage(queryParams)
download.excel(data, '质量异常统计.xlsx')
} catch {
} finally {
exportLoading.value = false
}
}
/** 重置按钮操作 */
const resetQuery = () => {
queryFormRef.value.resetFields()