| | |
| | | <template> |
| | | <a-card |
| | | :bordered="false" |
| | | title="三级保养工单" |
| | | title="三级保养" |
| | | > |
| | | <!-- 查询区域 --> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | slot-scope="text, record" |
| | | > |
| | | <a-popconfirm |
| | | title="确定下发工单吗?" |
| | | title="确定接收工单吗?" |
| | | @confirm="() => handleOrderIssue(record)" |
| | | v-has="'dailyMaintenanceOrder:issue'" |
| | | > |
| | | <a v-if="record.status == '1'">下发</a> |
| | | <a v-if="record.status == '1'">接收</a> |
| | | </a-popconfirm> |
| | | <a-divider |
| | | v-if="record.status == '1'" |
| | |
| | | dataIndex: 'assignModeName' |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: "center", |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | <template> |
| | | <a-card |
| | | :bordered="false" |
| | | title="日保周保工单" |
| | | title="自主维护点检工单" |
| | | > |
| | | <!-- 查询区域 --> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | slot-scope="text, record" |
| | | > |
| | | <a-popconfirm |
| | | title="确定下发工单吗?" |
| | | title="确定接收工单吗?" |
| | | @confirm="() => handleOrderIssue(record)" |
| | | v-has="'dailyInspectionOrder:issue'" |
| | | > |
| | | <a v-if="record.status == '1'">下发</a> |
| | | <a v-if="record.status == '1'">接收</a> |
| | | </a-popconfirm> |
| | | <a-divider |
| | | v-if="record.status == '1'" |
| | |
| | | return parseInt(index) + 1; |
| | | } |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | dataIndex: 'statusName' |
| | | }, |
| | | |
| | | { |
| | | title: '点检工单号', |
| | | align: "center", |
| | | dataIndex: 'num', |
| | | scopedSlots: { customRender: 'num' } |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | dataIndex: 'statusName' |
| | | }, |
| | | { |
| | | title: '点检日期', |
| | |
| | | dataIndex: 'inspectionDeadline', |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: "center", |
| | | dataIndex: 'equipmentNum' |
| | | }, |
| | |
| | | dataIndex: 'equipmentModel' |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | title: '使用部门', |
| | | align: "center", |
| | | dataIndex: 'useDepartName' |
| | | }, |
| | |
| | | <template> |
| | | <a-card |
| | | title="日保周保标准" |
| | | title="自主维护点检标准" |
| | | :bordered='false' |
| | | > |
| | | <div class='table-page-search-wrapper'> |
| | |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | |
| | | { |
| | | title: '标准编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | title: '使用部门', |
| | | align: 'center', |
| | | dataIndex: 'useDepartName', |
| | | }, |
| | |
| | | align: 'center', |
| | | dataIndex: 'assignModeName', |
| | | }, |
| | | // { |
| | | // title: '生效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'takeEffectTime', |
| | | // }, |
| | | // { |
| | | // title: '失效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'loseEfficacyTime', |
| | | // }, |
| | | { |
| | | title: '生效时间', |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'takeEffectTime', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '失效时间', |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'loseEfficacyTime', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | { |
| | | title: '创建人', |
| | |
| | | <template> |
| | | <a-card |
| | | :bordered="false" |
| | | title="二级保养工单" |
| | | title="二级保养" |
| | | > |
| | | <!-- 查询区域 --> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | slot-scope="text, record" |
| | | > |
| | | <a-popconfirm |
| | | title="确定下发工单吗?" |
| | | title="确定接收工单吗?" |
| | | @confirm="() => handleOrderIssue(record)" |
| | | v-has="'dailyMaintenanceOrder:issue'" |
| | | > |
| | | <a v-if="record.status == '1'">下发</a> |
| | | <a v-if="record.status == '1'">接收</a> |
| | | </a-popconfirm> |
| | | <a-divider |
| | | v-if="record.status == '1'" |
| | |
| | | dataIndex: 'assignModeName' |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: "center", |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | } |
| | | }, |
| | | { |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | { |
| | | title: '标准编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | | |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | dataIndex: 'equipmentModel', |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | title: '使用部门', |
| | | align: 'center', |
| | | dataIndex: 'useDepartName', |
| | | }, |
| | |
| | | align: 'center', |
| | | dataIndex: 'specificEquipment', |
| | | }, |
| | | // { |
| | | // title: '生效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'takeEffectTime', |
| | | // }, |
| | | // { |
| | | // title: '失效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'loseEfficacyTime', |
| | | // }, |
| | | { |
| | | title: '生效时间', |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'takeEffectTime', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '失效时间', |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'loseEfficacyTime', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | { |
| | | title: '创建人', |
| | |
| | | <template> |
| | | <a-card |
| | | :bordered="false" |
| | | title="专业保养工单" |
| | | title="预防性保养工单" |
| | | > |
| | | <!-- 查询区域 --> |
| | | <div class="table-page-search-wrapper"> |
| | |
| | | return parseInt(index) + 1; |
| | | } |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | dataIndex: 'statusName' |
| | | }, |
| | | { |
| | | title: '维保方式', |
| | | align: "center", |
| | | dataIndex: 'maintenanceMode' |
| | | }, |
| | | |
| | | { |
| | | title: '保养工单号', |
| | | align: "center", |
| | |
| | | scopedSlots: { customRender: 'num' } |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | title: '使用部门', |
| | | align: "center", |
| | | dataIndex: 'departName', |
| | | }, |
| | |
| | | align: "center", |
| | | dataIndex: 'teamName', |
| | | }, |
| | | { |
| | | title: '状态', |
| | | align: "center", |
| | | dataIndex: 'statusName' |
| | | }, |
| | | { |
| | | title: '维保方式', |
| | | align: "center", |
| | | dataIndex: 'maintenanceMode' |
| | | }, |
| | | // { |
| | | // title: '工时定额/每小时', |
| | | // align: "center", |
| | |
| | | <template> |
| | | <a-card |
| | | title="专业保养方案" |
| | | title="预防性保养方案" |
| | | :bordered='false' |
| | | > |
| | | <div class='table-page-search-wrapper'> |
| | |
| | | <template> |
| | | <a-card |
| | | title="专业保养标准" |
| | | title="预防性保养标准" |
| | | :bordered='false' |
| | | > |
| | | <div class='table-page-search-wrapper'> |
| | |
| | | :md='8' |
| | | :sm='24' |
| | | > |
| | | <a-form-item label='设备编码'> |
| | | <a-form-item label='统一编码'> |
| | | <a-input |
| | | placeholder='请输入设备编码' |
| | | placeholder='请输入统一编码' |
| | | v-model='queryParam.num' |
| | | ></a-input> |
| | | </a-form-item> |
| | |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'version', |
| | | width: 100, |
| | | }, |
| | | { |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'versionStatusName', |
| | | width: 130, |
| | | }, |
| | | |
| | | { |
| | | title: '标准编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | align: 'center', |
| | | dataIndex: 'useDepartName', |
| | | }, |
| | | |
| | | |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | dataIndex: 'equipmentModel', |
| | | }, |
| | | { |
| | | title: '使用部门', |
| | | align: 'center', |
| | | dataIndex: 'useDepartName', |
| | | }, |
| | | { |
| | | title: '特种设备', |
| | | align: 'center', |
| | | dataIndex: 'specificEquipment', |
| | | }, |
| | | // { |
| | | // title: '生效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'takeEffectTime', |
| | | // }, |
| | | // { |
| | | // title: '失效时间', |
| | | // align: 'center', |
| | | // dataIndex: 'loseEfficacyTime', |
| | | // }, |
| | | { |
| | | title: '生效时间', |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'takeEffectTime', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '失效时间', |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'loseEfficacyTime', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | { |
| | | title: '创建人', |
| | |
| | | getInspectionCycles: "/eam/inspectionOrder/getInspectionCycles", |
| | | getInspectionProjectId: "/eam/inspectionOrder/getInspectionProjectId", |
| | | // getEquipmentIdById: "/eam/equipment/list", |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | |
| | | dataSource: [], |
| | |
| | | methods: { |
| | | add() { |
| | | this.edit({ startWorkCondition: "1", inspectionOrderDetails: [] }) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | }) |
| | | }, |
| | | |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'DailylnspectionOrder', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | // getEquipmentIdById(equipmentId) { |
| | | // if (equipmentId != null && equipmentId != "") { |
| | | // getAction(this.url.getEquipmentIdById, { id: equipmentId }).then((res) => { |
| | |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="对象部门" |
| | | label="使用部门" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | |
| | | style="width: 100%" |
| | | :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" |
| | | :tree-data="treeData" |
| | | placeholder="请选择对象部门" |
| | | placeholder="请选择使用部门" |
| | | tree-default-expand-all |
| | | v-decorator="['useId', validatorRules.useId ]" |
| | | /> |
| | |
| | | align: 'center', |
| | | dataIndex: 'detectionStandard' |
| | | }, |
| | | { |
| | | title: '合格范围', |
| | | align: 'center', |
| | | dataIndex: 'acceptabilityLimit' |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'inspectionMethodName' |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'inspectionTool' |
| | | }, |
| | | // { |
| | | // title: '合格范围', |
| | | // align: 'center', |
| | | // dataIndex: 'acceptabilityLimit' |
| | | // }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'inspectionMethodName' |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'inspectionTool' |
| | | // }, |
| | | { |
| | | title: '周期', |
| | | align: 'center', |
| | |
| | | revise: '/eam/inspectionStandard/revise', |
| | | getReviseVersion: "/eam/inspectionStandard/getReviseVersion", |
| | | loadOptions: '/sys/sysDepart/loadDepartTreeOptions', |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | |
| | | dataSource: [], |
| | |
| | | |
| | | add() { |
| | | this.edit({ dailyInspectionStandardDetaillist: [] }) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | } |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'DailylnspectionStandard', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | initOptions() { |
| | | getAction(this.url.loadOptions).then(res => { |
| | | if (res.success) { |
| | |
| | | :md="6" |
| | | :sm="8" |
| | | > |
| | | <a-form-item label="设备编号"> |
| | | <a-form-item label="统一编码"> |
| | | <j-input |
| | | placeholder="请输入标准编号检索" |
| | | placeholder="请输入统一编码检索" |
| | | v-model="queryParam.num" |
| | | ></j-input> |
| | | </a-form-item> |
| | |
| | | } |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | |
| | | dataIndex: 'num', |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | list(useId) { |
| | | this.visible = true; |
| | | this.useId = useId; |
| | | this.queryParam = { type: "daily", delFlag: '0', useId: useId,versionStatus:'2' }; |
| | | this.queryParam = { type: "daily", delFlag: '0', useId: useId, versionStatus: '2' }; |
| | | this.loadData(1); |
| | | }, |
| | | clickThenCheck(record) { |
| | |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="对象部门" |
| | | label="使用部门" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-select |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请选择对象部门'" |
| | | :placeholder="disableSubmit?'':'请选择使用部门'" |
| | | :options="this.departs" |
| | | style="width: 100%" |
| | | v-decorator="['useId', validatorRules.useId]" |
| | |
| | | |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="设备编码/名称/型号" |
| | | label="统一编码/名称/型号" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="true" |
| | | :placeholder="disableSubmit?'':'请输入设备编码/名称/型号'" |
| | | :placeholder="disableSubmit?'':'请输入统一编码/名称/型号'" |
| | | v-decorator="['equipmentNum', validatorRules.equipmentNum ]" |
| | | /> |
| | | </a-form-item> |
| | |
| | | getMaintenanceProjectList: "/eam/dailyMaintenanceOrder/getMaintenanceProjectId", |
| | | getSysDeparts: "/eam/dailyMaintenanceOrder/getSysDeparts", |
| | | list: "/eam/dailyMaintenanceOrder/getMaintenanceCycleByStandardId", |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | |
| | | } |
| | |
| | | methods: { |
| | | add() { |
| | | this.edit({}) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | }) |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'MaintenanceOrder', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | handle3Change(val) { |
| | | let data = this.form.getFieldsValue(['maintenanceStandardId']); |
| | | getAction(this.url.getMaintenanceProjectList, { maintenanceStandardId: data.maintenanceStandardId, maintenanceCycleId: val }).then((res) => { |
| | |
| | | dataIndex: 'standard', |
| | | |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: "center", |
| | | dataIndex: 'maintenanceMethodName', |
| | | // { |
| | | // title: '方法', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceMethodName', |
| | | |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: "center", |
| | | dataIndex: 'maintenanceTool', |
| | | }, |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceTool', |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: "center", |
| | |
| | | align: "center", |
| | | dataIndex: 'maintenanceCycleName', |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: "center", |
| | | dataIndex: 'maintenanceSpecialtyName', |
| | | }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceSpecialtyName', |
| | | // }, |
| | | { |
| | | title: '维修保养角色', |
| | | align: "center", |
| | |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="对象部门" |
| | | label="使用部门" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | |
| | | align: 'center', |
| | | dataIndex: 'standard' |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceMethodName' |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceTool' |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceSpecialtyName' |
| | | }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceMethodName' |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceTool' |
| | | // }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceSpecialtyName' |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: 'center', |
| | |
| | | revise: '/eam/maintenanceStandard/revise', |
| | | getReviseVersion: "/eam/maintenanceStandard/getReviseVersion", |
| | | loadOptions: '/sys/sysDepart/loadDepartTreeOptions', |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | |
| | | dataSource: [], |
| | |
| | | |
| | | add() { |
| | | this.edit({ maintenanceStandardDetaillist: [] }) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | }) |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'DailyMaintenanceStandard', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | onEquipmentList() { |
| | | let data = this.form.getFieldsValue(['departId']); |
| | |
| | | align: 'center', |
| | | dataIndex: 'standard' |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceMethod_dictText' |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceTool' |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceSpecialtyId_dictText' |
| | | }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceMethod_dictText' |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceTool' |
| | | // }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceSpecialtyId_dictText' |
| | | // }, |
| | | { |
| | | title: '保养部位', |
| | | align: 'center', |
| | |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-row> |
| | | <!-- </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="codeDisable" |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入点检项目编号'" |
| | | v-decorator="['num', validatorRules.num ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-col> --> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="点检项目名称" |
| | |
| | | </a-col> |
| | | </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="计量单位" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <j-dict-select-tag |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请选择计量单位'" |
| | | :triggerChange="true" |
| | | dictCode="mom_base_unit,name,id,status!='0' and del_flag!='1'" |
| | | v-decorator="['unitId', validatorRules.unitId]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="检验值类型" |
| | |
| | | dictCode="test_value_type" |
| | | v-decorator="['testValueType', validatorRules.testValueType]" |
| | | @change="(e)=>handleChange(e)" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col |
| | | v-if="testValueType == '2'" |
| | | :span="12" |
| | | > |
| | | <a-form-item |
| | | label="检测标准" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入检测标准'" |
| | | v-decorator="['detectionStandard', validatorRules.detectionStandard ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | |
| | | /> |
| | | </a-form-item> |
| | | </a-col> --> |
| | | <a-col |
| | | v-if="testValueType == '2'" |
| | | :span="12" |
| | | > |
| | | <a-form-item |
| | | label="检测标准" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入检测标准'" |
| | | v-decorator="['detectionStandard', validatorRules.detectionStandard ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | | <a-col |
| | | v-if="testValueType == '1'" |
| | | :span="12" |
| | |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="计量单位" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <j-dict-select-tag |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请选择计量单位'" |
| | | :triggerChange="true" |
| | | dictCode="mom_base_unit,name,id,status!='0' and del_flag!='1'" |
| | | v-decorator="['unitId', validatorRules.unitId]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <!-- <a-col :span="12"> |
| | | <a-form-item |
| | | label="点检工具" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | |
| | | v-decorator="['inspectionTool', validatorRules.inspectionTool ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-col> --> |
| | | </a-row> |
| | | |
| | | <a-row :gutter="24"> |
| | |
| | | if (record.id) { |
| | | this.codeDisable = true; |
| | | } else { |
| | | debugger |
| | | this.codeDisable = false; |
| | | this.$nextTick(() => { |
| | | this.form.setFieldsValue({ "testValueType": '2' }) |
| | | this.testValueType = '2' |
| | | }); |
| | | } |
| | | }, |
| | | |
| | |
| | | @keyup.enter.native="searchQuery" |
| | | > |
| | | <a-row :gutter="24"> |
| | | <a-col |
| | | <!-- <a-col |
| | | :md="8" |
| | | :sm="8" |
| | | > |
| | |
| | | v-model="queryParam.num" |
| | | ></j-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-col> --> |
| | | <a-col |
| | | :md="8" |
| | | :sm="8" |
| | |
| | | }, |
| | | width: 50, |
| | | }, |
| | | // { |
| | | // title: '项目编码', |
| | | // align: 'center', |
| | | // dataIndex: 'num', |
| | | // scopedSlots: { |
| | | // customRender: 'num' |
| | | // }, |
| | | // }, |
| | | { |
| | | title: '项目编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | scopedSlots: { |
| | | customRender: 'num' |
| | | }, |
| | | }, |
| | | { |
| | | title: '项目名称', |
| | | title: '点检项目', |
| | | align: 'center', |
| | | dataIndex: 'name', |
| | | scopedSlots: { |
| | | customRender: 'name' |
| | | }, |
| | | }, |
| | | { |
| | | title: '计量单位', |
| | | align: 'center', |
| | | dataIndex: 'unitId_dictText', |
| | | }, |
| | | |
| | | // { |
| | | // title: '分析方法', |
| | | // align: 'center', |
| | | // dataIndex: 'analysisMethod_dictText', |
| | | // }, |
| | | { |
| | | title: '检验值类型', |
| | | align: "center", |
| | | dataIndex: 'testValueType_dictText', |
| | | }, |
| | | { |
| | | title: '检测标准', |
| | | align: "center", |
| | |
| | | dataIndex: 'inspectionMethod_dictText', |
| | | }, |
| | | { |
| | | title: '点检工具', |
| | | title: '检验值类型', |
| | | align: "center", |
| | | dataIndex: 'inspectionTool', |
| | | dataIndex: 'testValueType_dictText', |
| | | }, |
| | | { |
| | | title: '计量单位', |
| | | align: 'center', |
| | | dataIndex: 'unitId_dictText', |
| | | }, |
| | | // { |
| | | // title: '点检工具', |
| | | // align: "center", |
| | | // dataIndex: 'inspectionTool', |
| | | // }, |
| | | { |
| | | title: '创建人', |
| | | align: "center", |
| | | dataIndex: 'createBy', |
| | |
| | | <a-spin :spinning="confirmLoading"> |
| | | <j-form-container :disabled="formDisabled"> |
| | | <!-- 主表单区域 --> |
| | | <a-form-model ref="form" :model="model" :rules="validatorRules" slot="detail"> |
| | | <a-form-model |
| | | ref="form" |
| | | :model="model" |
| | | :rules="validatorRules" |
| | | slot="detail" |
| | | > |
| | | <a-row> |
| | | <a-col :span="12" > |
| | | <a-form-model-item label="计划单号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="num"> |
| | | <a-input v-model="model.num" placeholder="请输入计划单号" ></a-input> |
| | | <a-col :span="12"> |
| | | <a-form-model-item |
| | | label="计划单号" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | prop="num" |
| | | > |
| | | <a-input |
| | | v-model="model.num" |
| | | placeholder="请输入计划单号" |
| | | ></a-input> |
| | | </a-form-model-item> |
| | | </a-col> |
| | | <a-col :span="12" > |
| | | <a-form-model-item label="计划单类型" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="type"> |
| | | <a-col :span="12"> |
| | | <a-form-model-item |
| | | label="计划单类型" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | prop="type" |
| | | > |
| | | <j-dict-select-tag |
| | | allow-clear |
| | | placeholder="请选择计划单类型" |
| | | :triggerChange="true" |
| | | dictCode="maintenance_type" |
| | | v-model="model.type" |
| | | v-model="model.type" |
| | | /> |
| | | </a-form-model-item> |
| | | </a-col> |
| | | </a-row> |
| | | </a-form-model> |
| | | </j-form-container> |
| | | <!-- 子表单区域 --> |
| | | <a-tabs v-model="activeKey" @change="handleChangeTabs"> |
| | | <a-tab-pane tab="保养计划明细" :key="refKeys[0]" :forceRender="true"> |
| | | <!-- 子表单区域 --> |
| | | <a-tabs |
| | | v-model="activeKey" |
| | | @change="handleChangeTabs" |
| | | > |
| | | <a-tab-pane |
| | | tab="保养计划明细" |
| | | :key="refKeys[0]" |
| | | :forceRender="true" |
| | | > |
| | | <j-vxe-table |
| | | keep-source |
| | | :ref="refKeys[0]" |
| | |
| | | bordered |
| | | :alwaysEdit="true" |
| | | :toolbarConfig='toolbarConfig' |
| | | > |
| | | > |
| | | <template slot='toolbarPrefix'> |
| | | <a-button type='primary' @click='standardSelect' :disabled="formDisabled" icon="plus">设备-保养标准 |
| | | <a-button |
| | | type='primary' |
| | | @click='standardSelect' |
| | | :disabled="formDisabled" |
| | | icon="plus" |
| | | >设备-保养标准 |
| | | </a-button> |
| | | </template> |
| | | </j-vxe-table> |
| | | </a-tab-pane> |
| | | </a-tabs> |
| | | <standard-select @selectionRows='selectionRows' ref='standardSelectModel' ></standard-select> |
| | | <standard-select |
| | | @selectionRows='selectionRows' |
| | | ref='standardSelectModel' |
| | | ></standard-select> |
| | | </a-spin> |
| | | </template> |
| | | |
| | | <script> |
| | | |
| | | import { getAction } from '@/api/manage' |
| | | import { JVxeTableModelMixin } from '@/mixins/JVxeTableModelMixin.js' |
| | | import { JVXETypes } from '@/components/jeecg/JVxeTable' |
| | | import { getRefPromise,VALIDATE_FAILED} from '@/components/jeecg/JVxeTable/utils/vxeUtils.js' |
| | | import { validateDuplicateValue } from '@/utils/util' |
| | | import JFormContainer from '@/components/jeecg/JFormContainer' |
| | | import StandardSelect from './StandardSelect' |
| | | import { duplicateCheck } from '@/api/api' |
| | | import dayjs from 'dayjs' |
| | | import { getAction } from '@/api/manage' |
| | | import { JVxeTableModelMixin } from '@/mixins/JVxeTableModelMixin.js' |
| | | import { JVXETypes } from '@/components/jeecg/JVxeTable' |
| | | import { getRefPromise, VALIDATE_FAILED } from '@/components/jeecg/JVxeTable/utils/vxeUtils.js' |
| | | import { validateDuplicateValue } from '@/utils/util' |
| | | import JFormContainer from '@/components/jeecg/JFormContainer' |
| | | import StandardSelect from './StandardSelect' |
| | | import { duplicateCheck } from '@/api/api' |
| | | import dayjs from 'dayjs' |
| | | |
| | | export default { |
| | | name: 'EquipmentMaintenancePlanForm', |
| | | mixins: [JVxeTableModelMixin], |
| | | components: { |
| | | JFormContainer, |
| | | StandardSelect, |
| | | dayjs |
| | | }, |
| | | data() { |
| | | return { |
| | | toolbarConfig: { |
| | | export default { |
| | | name: 'EquipmentMaintenancePlanForm', |
| | | mixins: [JVxeTableModelMixin], |
| | | components: { |
| | | JFormContainer, |
| | | StandardSelect, |
| | | dayjs |
| | | }, |
| | | data() { |
| | | return { |
| | | toolbarConfig: { |
| | | // prefix 前缀;suffix 后缀 |
| | | slot: ['prefix', 'suffix'], |
| | | // add 新增按钮;remove 删除按钮;clearSelection 清空选择按钮 |
| | | btn: ['remove', 'clearSelection'] |
| | | }, |
| | | labelCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 5 }, |
| | | }, |
| | | wrapperCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 16 }, |
| | | }, |
| | | model:{ |
| | | }, |
| | | // 新增时子表默认添加几行空数据 |
| | | addDefaultRowNum: 0, |
| | | validatorRules: { |
| | | num: [ |
| | | }, |
| | | labelCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 5 }, |
| | | }, |
| | | wrapperCol: { |
| | | xs: { span: 24 }, |
| | | sm: { span: 16 }, |
| | | }, |
| | | model: { |
| | | }, |
| | | // 新增时子表默认添加几行空数据 |
| | | addDefaultRowNum: 0, |
| | | validatorRules: { |
| | | num: [ |
| | | { required: true, message: '请输入编码!' }, |
| | | { min: 1, max: 30, message: '长度在 2 到 30 个字符', trigger: 'blur' }, |
| | | { validator: this.validateNum }, |
| | | ], |
| | | type: [ |
| | | type: [ |
| | | { required: true, message: '请选择计划单类型!' }, |
| | | ], |
| | | }, |
| | | refKeys: ['equipmentMaintenancePlanDetail', ], |
| | | tableKeys:['equipmentMaintenancePlanDetail', ], |
| | | activeKey: 'equipmentMaintenancePlanDetail', |
| | | // 保养计划明细 |
| | | equipmentMaintenancePlanDetailTable: { |
| | | loading: false, |
| | | dataSource: [ |
| | | ], |
| | | columns: [ |
| | | }, |
| | | refKeys: ['equipmentMaintenancePlanDetail',], |
| | | tableKeys: ['equipmentMaintenancePlanDetail',], |
| | | activeKey: 'equipmentMaintenancePlanDetail', |
| | | // 保养计划明细 |
| | | equipmentMaintenancePlanDetailTable: { |
| | | loading: false, |
| | | dataSource: [ |
| | | ], |
| | | columns: [ |
| | | { |
| | | title: '保养标准id', |
| | | key: 'standardId', |
| | | type: JVXETypes.hidden, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align:'center', |
| | | width:"230px", |
| | | }, |
| | | { |
| | | title: '保养标准', |
| | | key: 'standardNum', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align:'center', |
| | | width:"230px", |
| | | }, |
| | | { |
| | | title: '设备统一编码', |
| | | key: 'equipmentNum', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align:'center', |
| | | width:"230px", |
| | | }, |
| | | { |
| | | title: '设备名称', |
| | | key: 'equipmentName', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align:'center', |
| | | width:"230px", |
| | | }, |
| | | { |
| | | title: '设备型号', |
| | | key: 'model', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align:'center', |
| | | width:"230px", |
| | | }, |
| | | { |
| | | title: '计划开始时间', |
| | | key: 'planStartTime', |
| | | type: JVXETypes.datetime, |
| | | placeholder: '请输入${title}', |
| | | align:'center', |
| | | width:"250px", |
| | | validateRules: [ |
| | | { |
| | | required: true, // 必填 |
| | | message: '请输入${title}' // 显示的文本 |
| | | }, |
| | | { |
| | | handler({ cellValue, row, column }, callback, target) { |
| | | var start = dayjs(cellValue); |
| | | var end = dayjs(row.planEndTime); |
| | | if (!start.isBefore(end)) { |
| | | callback(false, '结束时间需滞后于开始时间') // false = 未通过,可以跟自定义提示 |
| | | } else { |
| | | callback(true) // true = 通过验证 |
| | | } |
| | | }, |
| | | message: '${title}默认提示' |
| | | } |
| | | ] |
| | | }, |
| | | { |
| | | title: '计划结束时间', |
| | | key: 'planEndTime', |
| | | type: JVXETypes.datetime, |
| | | placeholder: '请输入${title}', |
| | | align:'center', |
| | | width:"250px", |
| | | validateRules: [ |
| | | { |
| | | required: true, // 必填 |
| | | message: '请输入${title}' // 显示的文本 |
| | | }, |
| | | { |
| | | handler({ cellValue, row, column }, callback, target) { |
| | | var start = dayjs(row.planStartTime); |
| | | var end = dayjs(cellValue); |
| | | if (!start.isBefore(end)) { |
| | | callback(false, '结束时间需滞后于开始时间') // false = 未通过,可以跟自定义提示 |
| | | } else { |
| | | callback(true) // true = 通过验证 |
| | | } |
| | | }, |
| | | message: '${title}默认提示' |
| | | } |
| | | ] |
| | | }, |
| | | ] |
| | | }, |
| | | url: { |
| | | add: "/eam/equipmentMaintenancePlan/add", |
| | | edit: "/eam/equipmentMaintenancePlan/edit", |
| | | queryById: "/eam/equipmentMaintenancePlan/queryById", |
| | | equipmentMaintenancePlanDetail: { |
| | | list: '/eam/equipmentMaintenancePlan/listEquipmentMaintenancePlanDetailByMainId' |
| | | title: '保养标准id', |
| | | key: 'standardId', |
| | | type: JVXETypes.hidden, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align: 'center', |
| | | width: "230px", |
| | | }, |
| | | } |
| | | } |
| | | }, |
| | | props: { |
| | | //表单禁用 |
| | | disabled: { |
| | | type: Boolean, |
| | | default: false, |
| | | required: false |
| | | } |
| | | }, |
| | | computed: { |
| | | formDisabled(){ |
| | | return this.disabled |
| | | { |
| | | title: '保养标准', |
| | | key: 'standardNum', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align: 'center', |
| | | width: "230px", |
| | | }, |
| | | { |
| | | title: '设备统一编码', |
| | | key: 'equipmentNum', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align: 'center', |
| | | width: "230px", |
| | | }, |
| | | { |
| | | title: '设备名称', |
| | | key: 'equipmentName', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align: 'center', |
| | | width: "230px", |
| | | }, |
| | | { |
| | | title: '设备型号', |
| | | key: 'model', |
| | | type: JVXETypes.normal, |
| | | placeholder: '请输入${title}', |
| | | defaultValue: '', |
| | | align: 'center', |
| | | width: "230px", |
| | | }, |
| | | { |
| | | title: '计划开始时间', |
| | | key: 'planStartTime', |
| | | type: JVXETypes.datetime, |
| | | placeholder: '请输入${title}', |
| | | align: 'center', |
| | | width: "250px", |
| | | validateRules: [ |
| | | { |
| | | required: true, // 必填 |
| | | message: '请输入${title}' // 显示的文本 |
| | | }, |
| | | { |
| | | handler({ cellValue, row, column }, callback, target) { |
| | | var start = dayjs(cellValue); |
| | | var end = dayjs(row.planEndTime); |
| | | if (!start.isBefore(end)) { |
| | | callback(false, '结束时间需滞后于开始时间') // false = 未通过,可以跟自定义提示 |
| | | } else { |
| | | callback(true) // true = 通过验证 |
| | | } |
| | | }, |
| | | message: '${title}默认提示' |
| | | } |
| | | ] |
| | | }, |
| | | { |
| | | title: '计划结束时间', |
| | | key: 'planEndTime', |
| | | type: JVXETypes.datetime, |
| | | placeholder: '请输入${title}', |
| | | align: 'center', |
| | | width: "250px", |
| | | validateRules: [ |
| | | { |
| | | required: true, // 必填 |
| | | message: '请输入${title}' // 显示的文本 |
| | | }, |
| | | { |
| | | handler({ cellValue, row, column }, callback, target) { |
| | | var start = dayjs(row.planStartTime); |
| | | var end = dayjs(cellValue); |
| | | if (!start.isBefore(end)) { |
| | | callback(false, '结束时间需滞后于开始时间') // false = 未通过,可以跟自定义提示 |
| | | } else { |
| | | callback(true) // true = 通过验证 |
| | | } |
| | | }, |
| | | message: '${title}默认提示' |
| | | } |
| | | ] |
| | | }, |
| | | ] |
| | | }, |
| | | }, |
| | | created () { |
| | | }, |
| | | methods: { |
| | | addBefore(){ |
| | | this.equipmentMaintenancePlanDetailTable.dataSource=[] |
| | | }, |
| | | getAllTable() { |
| | | let values = this.tableKeys.map(key => getRefPromise(this, key)) |
| | | return Promise.all(values) |
| | | }, |
| | | /** 调用完edit()方法之后会自动调用此方法 */ |
| | | editAfter() { |
| | | this.$nextTick(() => { |
| | | }) |
| | | // 加载子表数据 |
| | | if (this.model.id) { |
| | | let params = { planId: this.model.id } |
| | | this.requestSubTableData(this.url.equipmentMaintenancePlanDetail.list, params, this.equipmentMaintenancePlanDetailTable) |
| | | } |
| | | }, |
| | | //校验所有一对一子表表单 |
| | | validateSubForm(allValues){ |
| | | return new Promise((resolve,reject)=>{ |
| | | Promise.all([ |
| | | ]).then(() => { |
| | | resolve(allValues) |
| | | }).catch(e => { |
| | | if (e.error === VALIDATE_FAILED) { |
| | | // 如果有未通过表单验证的子表,就自动跳转到它所在的tab |
| | | this.activeKey = e.index == null ? this.activeKey : this.refKeys[e.index] |
| | | } else { |
| | | console.error(e) |
| | | } |
| | | }) |
| | | }) |
| | | url: { |
| | | add: "/eam/equipmentMaintenancePlan/add", |
| | | edit: "/eam/equipmentMaintenancePlan/edit", |
| | | queryById: "/eam/equipmentMaintenancePlan/queryById", |
| | | equipmentMaintenancePlanDetail: { |
| | | list: '/eam/equipmentMaintenancePlan/listEquipmentMaintenancePlanDetailByMainId' |
| | | }, |
| | | /** 整理成formData */ |
| | | classifyIntoFormData(allValues) { |
| | | let main = Object.assign(this.model, allValues.formValue) |
| | | return { |
| | | ...main, // 展开 |
| | | equipmentMaintenancePlanDetailList: allValues.tablesValue[0].tableData, |
| | | } |
| | | }, |
| | | validateError(msg){ |
| | | this.$message.error(msg) |
| | | }, |
| | | standardSelect() { |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | } |
| | | } |
| | | }, |
| | | props: { |
| | | //表单禁用 |
| | | disabled: { |
| | | type: Boolean, |
| | | default: false, |
| | | required: false |
| | | } |
| | | }, |
| | | computed: { |
| | | formDisabled() { |
| | | return this.disabled |
| | | }, |
| | | }, |
| | | created() { |
| | | }, |
| | | methods: { |
| | | addBefore() { |
| | | this.equipmentMaintenancePlanDetailTable.dataSource = [] |
| | | this.getSeq() |
| | | }, |
| | | getAllTable() { |
| | | let values = this.tableKeys.map(key => getRefPromise(this, key)) |
| | | return Promise.all(values) |
| | | }, |
| | | /** 调用完edit()方法之后会自动调用此方法 */ |
| | | editAfter() { |
| | | this.$nextTick(() => { |
| | | }) |
| | | // 加载子表数据 |
| | | if (this.model.id) { |
| | | let params = { planId: this.model.id } |
| | | this.requestSubTableData(this.url.equipmentMaintenancePlanDetail.list, params, this.equipmentMaintenancePlanDetailTable) |
| | | } |
| | | }, |
| | | //校验所有一对一子表表单 |
| | | validateSubForm(allValues) { |
| | | return new Promise((resolve, reject) => { |
| | | Promise.all([ |
| | | ]).then(() => { |
| | | resolve(allValues) |
| | | }).catch(e => { |
| | | if (e.error === VALIDATE_FAILED) { |
| | | // 如果有未通过表单验证的子表,就自动跳转到它所在的tab |
| | | this.activeKey = e.index == null ? this.activeKey : this.refKeys[e.index] |
| | | } else { |
| | | console.error(e) |
| | | } |
| | | }) |
| | | }) |
| | | }, |
| | | /** 整理成formData */ |
| | | classifyIntoFormData(allValues) { |
| | | let main = Object.assign(this.model, allValues.formValue) |
| | | return { |
| | | ...main, // 展开 |
| | | equipmentMaintenancePlanDetailList: allValues.tablesValue[0].tableData, |
| | | } |
| | | }, |
| | | validateError(msg) { |
| | | this.$message.error(msg) |
| | | }, |
| | | standardSelect() { |
| | | let ids = [] |
| | | let tableData = this.$refs.equipmentMaintenancePlanDetail.getTableData() |
| | | for (let i = 0; i < tableData.length; i++) { |
| | |
| | | var equipmentMaintenancePlanDetail = {} |
| | | if (tableStr.indexOf(data[i].id) == -1) { |
| | | equipmentMaintenancePlanDetail = { |
| | | standardId:data[i].id, |
| | | standardId: data[i].id, |
| | | standardNum: data[i].num, |
| | | equipmentNum:data[i].equipmentNum, |
| | | equipmentName:data[i].equipmentName, |
| | | model:data[i].equipmentModel, |
| | | planId:this.model.id, |
| | | equipmentNum: data[i].equipmentNum, |
| | | equipmentName: data[i].equipmentName, |
| | | model: data[i].equipmentModel, |
| | | planId: this.model.id, |
| | | } |
| | | } |
| | | addRows.push(equipmentMaintenancePlanDetail) |
| | |
| | | }) |
| | | }, |
| | | |
| | | |
| | | } |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'MaintenancePlan', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.model.num = res.result |
| | | } |
| | | }) |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'version', |
| | | width: 100, |
| | | }, |
| | | { |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'versionStatusName', |
| | | width: 130, |
| | | }, |
| | | |
| | | { |
| | | title: '标准编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | | { |
| | | title: '对象部门', |
| | | title: '使用部门', |
| | | align: 'center', |
| | | dataIndex: 'useDepartName', |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum', |
| | | }, |
| | |
| | | align: 'center', |
| | | dataIndex: 'equipmentModel', |
| | | }, |
| | | { |
| | | title: '版本', |
| | | align: 'center', |
| | | dataIndex: 'version', |
| | | }, |
| | | { |
| | | title: '版本状态', |
| | | align: 'center', |
| | | dataIndex: 'versionStatusName', |
| | | }, |
| | | ], |
| | | selectedRowKeys: [], |
| | | oldSlelectRows: [], |
| | |
| | | </a-row> |
| | | |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <!-- <a-col :span="12"> |
| | | <a-form-item |
| | | label="保养项目编号" |
| | | :labelCol="labelCol" |
| | |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="codeDisable" |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入保养项目编号'" |
| | | v-decorator="['num', validatorRules.num ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-col> --> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="保养项目名称" |
| | |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入保养项目名称'" |
| | | v-decorator="['name', validatorRules.name ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="保养标准" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入保养标准'" |
| | | v-decorator="['standard', validatorRules.standard ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | |
| | | </a-col> |
| | | </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="保养标准" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入保养标准'" |
| | | v-decorator="['standard', validatorRules.standard ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | |
| | | <!-- <a-col :span="12"> |
| | | <a-form-item |
| | | label="维保专业" |
| | | :labelCol="labelCol" |
| | |
| | | v-decorator="['maintenanceSpecialtyId', validatorRules.maintenanceSpecialtyId]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | </a-col> --> |
| | | </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="保养部位" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input |
| | | allow-clear |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请输入保养部位'" |
| | | v-decorator="['location', validatorRules.location ]" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | | </a-row> |
| | | <a-row :gutter="24"> |
| | | <a-col :span="24"> |
| | |
| | | }, |
| | | width: 50, |
| | | }, |
| | | { |
| | | title: '保养项目编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | scopedSlots: { |
| | | customRender: 'num' |
| | | }, |
| | | }, |
| | | // { |
| | | // title: '保养项目编码', |
| | | // align: 'center', |
| | | // dataIndex: 'num', |
| | | // scopedSlots: { |
| | | // customRender: 'num' |
| | | // }, |
| | | // }, |
| | | { |
| | | title: '保养项目名称', |
| | | align: 'center', |
| | |
| | | // customRender: 'inspectionTypeId_dictText' |
| | | // }, |
| | | // }, |
| | | { |
| | | title: '维保专业', |
| | | align: "center", |
| | | dataIndex: 'maintenanceSpecialtyId_dictText', |
| | | }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceSpecialtyId_dictText', |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: "center", |
| | |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="专业保养方案" |
| | | label="预防性保养方案" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <a-input-search |
| | | :disabled="disableSubmit" |
| | | :placeholder="disableSubmit?'':'请选择专业保养方案'" |
| | | :placeholder="disableSubmit?'':'请选择预防性保养方案'" |
| | | enter-button |
| | | @search="onSpecialtyMaintenancePlanList()" |
| | | :read-only="true" |
| | |
| | | url: { |
| | | add: "/eam/specialtyMaintenanceOrder/add", |
| | | edit: "/eam/specialtyMaintenanceOrder/edit", |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | } |
| | | }, |
| | |
| | | methods: { |
| | | add() { |
| | | this.edit({}) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | }, |
| | | onSpecialtyMaintenancePlanList() { |
| | | this.$refs.SpecialtyMaintenancePlanList.list(); |
| | | this.$refs.SpecialtyMaintenancePlanList.title = "选择专业保养方案"; |
| | | this.$refs.SpecialtyMaintenancePlanList.title = "选择预防性保养方案"; |
| | | }, |
| | | sendSpecialtyMaintenancePlanRecord(data) { |
| | | let record = data.record; |
| | |
| | | } |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'SpecialtyMaintenanceOrder', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | handleOk() { |
| | | const that = this; |
| | | this.form.validateFields((err, values) => { |
| | |
| | | dataIndex: 'versionStatusName' |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum' |
| | | }, |
| | |
| | | </a-col> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="对象部门" |
| | | label="使用部门" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | |
| | | style="width: 100%" |
| | | :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }" |
| | | :tree-data="treeData" |
| | | placeholder="请选择对象部门" |
| | | placeholder="请选择使用部门" |
| | | tree-default-expand-all |
| | | v-decorator="['departId', validatorRules.departId]" |
| | | @change="(e)=>handle2Change(e)" |
| | |
| | | dataIndex: 'versionStatusName' |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'equipmentNum' |
| | | }, |
| | |
| | | getMaintenanceCycles: "/eam/maintenanceStandardDetail/getMaintenanceCycle", |
| | | getSysDeparts: "/eam/equipment/getSysDeparts", |
| | | loadOptions: '/sys/sysDepart/loadDepartTreeOptions', |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | dataSource: [], |
| | | //用于展示文件 |
| | |
| | | selectMaintenanceProjects: function () { |
| | | let dataDepartId = this.form.getFieldsValue(['departId']); |
| | | if (dataDepartId.departId === "" || dataDepartId.departId === null || dataDepartId.departId === undefined) { |
| | | this.$message.warning("请选择对象部门!"); |
| | | this.$message.warning("请选择使用部门!"); |
| | | return |
| | | } |
| | | let data = this.form.getFieldsValue(['maintenanceCycleId']); |
| | |
| | | |
| | | add() { |
| | | this.edit({ specialtyMaintenancePlanDetailList: [] }) |
| | | this.getSeq() |
| | | }, |
| | | |
| | | edit(record) { |
| | |
| | | }) |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'SpecialtyMaintenancePlan', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | handleOk() { |
| | | const that = this; |
| | | // 触发表单验证 |
| | |
| | | :md="6" |
| | | :sm="8" |
| | | > |
| | | <a-form-item label="设备编号"> |
| | | <a-form-item label="统一编码"> |
| | | <j-input |
| | | placeholder="请输入标准编号检索" |
| | | placeholder="请输入统一编码" |
| | | v-model="queryParam.num" |
| | | ></j-input> |
| | | </a-form-item> |
| | |
| | | :sm="8" |
| | | v-if="selectedDeparts" |
| | | > |
| | | <a-form-item label="对象部门"> |
| | | <a-form-item label="使用部门"> |
| | | <a-select |
| | | allow-clear |
| | | :placeholder="'请选择对象部门'" |
| | | :options="departs" |
| | | v-model="queryParam.useId" |
| | | style="width: 100%" |
| | | /> |
| | | allow-clear |
| | | :placeholder="'请选择使用部门'" |
| | | :options="departs" |
| | | v-model="queryParam.useId" |
| | | style="width: 100%" |
| | | /> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col |
| | |
| | | visible: false, |
| | | model: {}, |
| | | departs: [], |
| | | selectedDeparts:false, |
| | | selectedDeparts: false, |
| | | dataSource: [], |
| | | disableSubmit: false, |
| | | type: "radio", |
| | |
| | | } |
| | | }, |
| | | { |
| | | title: '设备编码', |
| | | title: '统一编码', |
| | | align: 'center', |
| | | dataIndex: 'num', |
| | | }, |
| | |
| | | }, |
| | | } |
| | | }, |
| | | created(){ |
| | | created() { |
| | | this.getSysDeparts() |
| | | }, |
| | | |
| | |
| | | align: 'center', |
| | | dataIndex: 'standard' |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceMethod_dictText' |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceTool' |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceSpecialtyId_dictText' |
| | | }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceMethod_dictText' |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceTool' |
| | | // }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceSpecialtyId_dictText' |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: 'center', |
| | |
| | | 预览 |
| | | </a> |
| | | </span> --> |
| | | <template slot="imgSlot" slot-scope="text,record"> |
| | | <span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span> |
| | | <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/> |
| | | <template |
| | | slot="imgSlot" |
| | | slot-scope="text,record" |
| | | > |
| | | <span |
| | | v-if="!text" |
| | | style="font-size: 12px;font-style: italic;" |
| | | >无图片</span> |
| | | <img |
| | | v-else |
| | | :src="getImgView(text)" |
| | | :preview="record.id" |
| | | height="25px" |
| | | alt="" |
| | | style="max-width:80px;font-size: 12px;font-style: italic;" |
| | | /> |
| | | </template> |
| | | </a-table> |
| | | </div> |
| | |
| | | dataIndex: 'standard', |
| | | |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: "center", |
| | | dataIndex: 'maintenanceMethodName', |
| | | // { |
| | | // title: '方法', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceMethodName', |
| | | |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: "center", |
| | | dataIndex: 'maintenanceTool', |
| | | }, |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceTool', |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: "center", |
| | |
| | | align: "center", |
| | | dataIndex: 'maintenanceCycleName', |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: "center", |
| | | dataIndex: 'maintenanceSpecialtyName', |
| | | }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: "center", |
| | | // dataIndex: 'maintenanceSpecialtyName', |
| | | // }, |
| | | { |
| | | title: '维保方式', |
| | | align: "center", |
| | |
| | | created() { |
| | | }, |
| | | computed: { |
| | | importExcelUrl(){ |
| | | return `${window._CONFIG['domianURL']}/${this.url.importUrl}/${this.mainId}`; |
| | | } |
| | | }, |
| | | importExcelUrl() { |
| | | return `${window._CONFIG['domianURL']}/${this.url.importUrl}/${this.mainId}`; |
| | | } |
| | | }, |
| | | methods: { |
| | | clearList() { |
| | | this.dataSource = [] |
| | |
| | | <a-row :gutter="24"> |
| | | <a-col :span="12"> |
| | | <a-form-item |
| | | label="对象部门" |
| | | label="使用部门" |
| | | :labelCol="labelCol" |
| | | :wrapperCol="wrapperCol" |
| | | > |
| | | <j-dict-select-tag |
| | | allow-clear |
| | | :placeholder="disableSubmit?'':'请选择对象部门'" |
| | | :placeholder="disableSubmit?'':'请选择使用部门'" |
| | | :triggerChange="true" |
| | | :disabled="true" |
| | | dictCode="sys_depart,depart_name,id" |
| | |
| | | dataIndex: 'standard', |
| | | width: 100, |
| | | }, |
| | | { |
| | | title: '方法', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceMethodName', |
| | | width: 100, |
| | | }, |
| | | { |
| | | title: '工具', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceTool', |
| | | width: 100, |
| | | }, |
| | | { |
| | | title: '维保专业', |
| | | align: 'center', |
| | | dataIndex: 'maintenanceSpecialtyName', |
| | | width: 100, |
| | | }, |
| | | // { |
| | | // title: '方法', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceMethodName', |
| | | // width: 100, |
| | | // }, |
| | | // { |
| | | // title: '工具', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceTool', |
| | | // width: 100, |
| | | // }, |
| | | // { |
| | | // title: '维保专业', |
| | | // align: 'center', |
| | | // dataIndex: 'maintenanceSpecialtyName', |
| | | // width: 100, |
| | | // }, |
| | | { |
| | | title: '安全要求', |
| | | align: 'center', |
| | |
| | | getMaintenanceMode: "/eam/maintenanceStandardDetail/getMaintenanceMode", |
| | | realDelete: "/eam/maintenanceStandardDetail/realDelete", |
| | | revise: '/eam/maintenanceStandard/revise', |
| | | getReviseVersion: "/eam/maintenanceStandard/getReviseVersion" |
| | | getReviseVersion: "/eam/maintenanceStandard/getReviseVersion", |
| | | getNum: '/eam/sysIdentity/getNumNew' |
| | | }, |
| | | |
| | | dataSource: [], |
| | |
| | | |
| | | add() { |
| | | this.edit({ maintenanceStandardDetaillist: [] }) |
| | | this.getSeq() |
| | | |
| | | }, |
| | | |
| | |
| | | return |
| | | } |
| | | for (var i = 0; i < that.dataSource.length; i++) { |
| | | if (that.dataSource[i].maintenanceRequire == null || that.dataSource[i].maintenanceRequire == undefined || that.dataSource[i].maintenanceRequire == '') { |
| | | this.$message.error("第" + (i + 1) + "行安全要求为空,请填写") |
| | | that.confirmLoading = false |
| | | return false; |
| | | } |
| | | if (that.dataSource[i].photo == null || that.dataSource[i].photo == undefined || that.dataSource[i].photo == '') { |
| | | this.$message.error("第" + (i + 1) + "行示意图为空,请上传") |
| | | that.confirmLoading = false |
| | | return false; |
| | | } |
| | | if (that.dataSource[i].location == null || that.dataSource[i].location == undefined || that.dataSource[i].location == '') { |
| | | this.$message.error("第" + (i + 1) + "行部位为空,请填写") |
| | | that.confirmLoading = false |
| | | return false; |
| | | } |
| | | // if (that.dataSource[i].maintenanceRequire == null || that.dataSource[i].maintenanceRequire == undefined || that.dataSource[i].maintenanceRequire == '') { |
| | | // this.$message.error("第" + (i + 1) + "行安全要求为空,请填写") |
| | | // that.confirmLoading = false |
| | | // return false; |
| | | // } |
| | | // if (that.dataSource[i].photo == null || that.dataSource[i].photo == undefined || that.dataSource[i].photo == '') { |
| | | // this.$message.error("第" + (i + 1) + "行示意图为空,请上传") |
| | | // that.confirmLoading = false |
| | | // return false; |
| | | // } |
| | | // if (that.dataSource[i].location == null || that.dataSource[i].location == undefined || that.dataSource[i].location == '') { |
| | | // this.$message.error("第" + (i + 1) + "行部位为空,请填写") |
| | | // that.confirmLoading = false |
| | | // return false; |
| | | // } |
| | | if (that.dataSource[i].maintenanceCycleId == null || that.dataSource[i].maintenanceCycleId == undefined) { |
| | | this.$message.error("第" + (i + 1) + "行周期为空,请选择") |
| | | that.confirmLoading = false |
| | | return false; |
| | | } |
| | | if (that.dataSource[i].maintenanceMode == null || that.dataSource[i].maintenanceMode == undefined || that.dataSource[i].maintenanceMode == '') { |
| | | this.$message.error("第" + (i + 1) + "行维保方式为空,请选择") |
| | | that.confirmLoading = false |
| | | return false; |
| | | } |
| | | // if (that.dataSource[i].maintenanceMode == null || that.dataSource[i].maintenanceMode == undefined || that.dataSource[i].maintenanceMode == '') { |
| | | // this.$message.error("第" + (i + 1) + "行维保方式为空,请选择") |
| | | // that.confirmLoading = false |
| | | // return false; |
| | | // } |
| | | |
| | | |
| | | |
| | |
| | | }) |
| | | }, |
| | | |
| | | getSeq() { |
| | | getAction(this.url.getNum, { type: 'SpecialtyMaintenanceStandard', length: 4 }).then(res => { |
| | | if (res.success) { |
| | | this.form.setFieldsValue({ "num": res.result }) |
| | | } |
| | | }) |
| | | }, |
| | | |
| | | getMaintenanceCycle() { |
| | | getAction(this.url.getMaintenanceCycle).then((res) => { |
| | | if (res.success) { |