diff --git a/src/api/qc/qc.js b/src/api/qc/qc.js
index 1606e4a..d686c79 100644
--- a/src/api/qc/qc.js
+++ b/src/api/qc/qc.js
@@ -274,6 +274,7 @@ export const fqasRecordOverLoad = data => createAPI(`/pms/qc/fqasRecordOverLoad`
export const actionFQASInspection = data => createAPI(`/pms/qc/actionFQASInspection`,'post',data)
export const changeInspectionWay = data => createAPI(`/pms/qc/changeInspectionWay`,'post',data)
export const getFileContentList2 = data => createAPI('sys/file/getFileContentList2','post',data)
+export const getPartAttributeFileList = data => createAPI('sys/file/getPartAttributeFileList','post',data)
export const downLoadObjectFile = data => createAPI(`pms/eamObject/downLoadObjectFile?id=`+data.id,'post',777)
export const deleteObjectFile = data => createAPI(`/pms/qc/deleteObjectFile`,'post',data)
export const getUserRoleList = data => createAPI(`/pms/qc/getUserRoleList`,'post',data)
diff --git a/src/views/modules/qc/FQCResultEntry.vue b/src/views/modules/qc/FQCResultEntry.vue
index 89453ba..273cc6e 100644
--- a/src/views/modules/qc/FQCResultEntry.vue
+++ b/src/views/modules/qc/FQCResultEntry.vue
@@ -512,9 +512,9 @@
- 应用
+ 分批保存
关闭
- 保存
+ 最终检验完成
diff --git a/src/views/modules/qc/IPQCResultEntry.vue b/src/views/modules/qc/IPQCResultEntry.vue
index 5d4e56c..9ed4de4 100644
--- a/src/views/modules/qc/IPQCResultEntry.vue
+++ b/src/views/modules/qc/IPQCResultEntry.vue
@@ -524,9 +524,9 @@
- 应用
+ 分批保存
关闭
- 保存
+ 最终检验完成
diff --git a/src/views/modules/qc/IQCResultEntry.vue b/src/views/modules/qc/IQCResultEntry.vue
index a55a6fd..4d2438d 100644
--- a/src/views/modules/qc/IQCResultEntry.vue
+++ b/src/views/modules/qc/IQCResultEntry.vue
@@ -427,9 +427,9 @@
- 应用
+ 分批保存
关闭
- 保存
+ 最终检验完成
diff --git a/src/views/modules/qc/OQCResultEntry.vue b/src/views/modules/qc/OQCResultEntry.vue
index 5003933..9371d7a 100644
--- a/src/views/modules/qc/OQCResultEntry.vue
+++ b/src/views/modules/qc/OQCResultEntry.vue
@@ -376,9 +376,9 @@
- 应用
+ 分批保存
关闭
- 保存
+ 最终检验完成
diff --git a/src/views/modules/qc/SQCResultEntry.vue b/src/views/modules/qc/SQCResultEntry.vue
index c2a9e8b..5023553 100644
--- a/src/views/modules/qc/SQCResultEntry.vue
+++ b/src/views/modules/qc/SQCResultEntry.vue
@@ -389,9 +389,9 @@
- 应用
+ 分批保存
关闭
- 保存
+ 最终检验完成
diff --git a/src/views/modules/qc/qcPartAttribute.vue b/src/views/modules/qc/qcPartAttribute.vue
index 41648b6..32ad081 100644
--- a/src/views/modules/qc/qcPartAttribute.vue
+++ b/src/views/modules/qc/qcPartAttribute.vue
@@ -30,6 +30,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
查询
新增
@@ -71,7 +96,10 @@
:label="item.columnLabel">
- {{ scope.row[`${item.columnProp}Desc`] }}
+
+ {{ scope.row[item.columnProp] }}
+
+ {{ scope.row[`${item.columnProp}Desc`] }}
{{ scope.row[item.columnProp] }}
@@ -520,7 +548,7 @@
-
+
- 新增
+
+ 同步检验项目
@@ -874,7 +903,7 @@
label="操作">
下载
- 删除
+ 删除
@@ -1036,17 +1065,19 @@
addPartAttrItemDetails,
delPartAttrItemDetails,
savePartAttrDetailed,
+ syncPartAttrDetailedFromTemplate,
goUpPartAttrItem,
goDownPartAttrItem,
getPatrolConfigList as fetchPatrolConfigListApi,
savePatrolConfig as savePatrolConfigApi,
updatePatrolConfig as updatePatrolConfigApi,
deletePatrolConfig as deletePatrolConfigApi,
- getPatrolOperationDescList as getPatrolOperationDescListApi
+ getPatrolOperationDescList as getPatrolOperationDescListApi,
+ getPartAttributeFileList
} from "@/api/qc/qc.js"
import {getTableDefaultListLanguage, getTableUserListLanguage} from "@/api/table.js"
import Chooselist from '@/views/modules/common/Chooselist_eam'
- import {getFileContentList, downLoadObjectFile} from '@/api/eam/eam_object_list.js'
+ import {downLoadObjectFile} from '@/api/eam/eam_object_list.js'
import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js'
import {deleteObjectFile} from '@/api/eam/eam.js'
import qcUpload from "./qc_upload"
@@ -1062,6 +1093,7 @@
data () {
return {
columnsProp:['createBy', 'updateBy'],
+ maintainFlagProps: ['iqcFlag', 'ipqcFlag', 'fqcFlag', 'oqcFlag', 'sqcFlag'],
// 是否收藏
favorite: false,
// 导出 start
@@ -1093,6 +1125,11 @@
familyID: '',
familyName: '',
buDesc: '',
+ iqcFlag: '',
+ ipqcFlag: '',
+ fqcFlag: '',
+ oqcFlag: '',
+ sqcFlag: '',
attributeType: 'A',
page: 1,
limit: 10,
@@ -1397,6 +1434,96 @@
fixed: '',
columnWidth: 100,
},
+ {
+ userId: this.$store.state.user.name,
+ functionId: 301003,
+ serialNumber: '301003Table1IqcFlag',
+ tableId: "301003Table1",
+ tableName: "物料属性设置表",
+ columnProp: 'iqcFlag',
+ headerAlign: "center",
+ align: "center",
+ columnLabel: 'IQC',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 90,
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 301003,
+ serialNumber: '301003Table1IpqcFlag',
+ tableId: "301003Table1",
+ tableName: "物料属性设置表",
+ columnProp: 'ipqcFlag',
+ headerAlign: "center",
+ align: "center",
+ columnLabel: 'IPQC',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 90,
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 301003,
+ serialNumber: '301003Table1FqcFlag',
+ tableId: "301003Table1",
+ tableName: "物料属性设置表",
+ columnProp: 'fqcFlag',
+ headerAlign: "center",
+ align: "center",
+ columnLabel: 'FQC',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 90,
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 301003,
+ serialNumber: '301003Table1OqcFlag',
+ tableId: "301003Table1",
+ tableName: "物料属性设置表",
+ columnProp: 'oqcFlag',
+ headerAlign: "center",
+ align: "center",
+ columnLabel: 'OQC',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 90,
+ },
+ {
+ userId: this.$store.state.user.name,
+ functionId: 301003,
+ serialNumber: '301003Table1SqcFlag',
+ tableId: "301003Table1",
+ tableName: "物料属性设置表",
+ columnProp: 'sqcFlag',
+ headerAlign: "center",
+ align: "center",
+ columnLabel: 'SQC',
+ columnHidden: false,
+ columnImage: false,
+ columnSortable: false,
+ sortLv: 0,
+ status: true,
+ fixed: '',
+ columnWidth: 90,
+ },
// {
// userId: this.$store.state.user.name,
// functionId: 301003,
@@ -1939,6 +2066,12 @@
},
computed: {
+ maintainStatusOptions () {
+ return [
+ { label: '已维护', value: '已维护' },
+ { label: '未维护', value: '未维护' }
+ ]
+ },
detailColumnsBeforeIpqc () {
const list = Array.isArray(this.columnDetailList) ? this.columnDetailList : []
const idx = list.findIndex(i => i.columnProp === 'inspectionTypeName')
@@ -1978,6 +2111,9 @@
},
methods: {
+ isMaintained (val) {
+ return val === '已维护'
+ },
// 获取用户的bu
getSiteAndBuByUserName () {
let tempData = {
@@ -2788,6 +2924,52 @@
this.standardFastAddFlag = true
},
+ standardSyncFromTemplate () {
+ const queryData = {
+ site: this.standardDetailData.site,
+ buNo: this.standardDetailData.buNo,
+ attributeNo: this.standardDetailData.attributeNo,
+ attributeType: 'A'
+ }
+ searchPartAttributeDetails(queryData).then(({data}) => {
+ const templates = (data.rows || []).filter(t => t.templateId)
+ if (templates.length === 0) {
+ this.$message.warning('没有已维护的检验模板,请先在检验模板清单中维护!')
+ return
+ }
+ const seen = new Set()
+ const uniqueTemplates = templates.filter(t => {
+ if (seen.has(t.templateId)) return false
+ seen.add(t.templateId)
+ return true
+ })
+ this.$confirm(`将根据全部检验类型下 ${uniqueTemplates.length} 个检验模板同步检验项目,已存在的项目将跳过,是否继续?`, '提示', {
+ confirmButtonText: '确定',
+ cancelButtonText: '取消',
+ type: 'warning'
+ }).then(() => {
+ const syncPromises = uniqueTemplates.map(t => syncPartAttrDetailedFromTemplate({
+ site: this.standardDetailData.site,
+ buNo: this.standardDetailData.buNo,
+ attributeNo: this.standardDetailData.attributeNo,
+ attributeType: 'A',
+ templateId: t.templateId,
+ inspectionTypeNo: t.inspectionTypeNo,
+ updateBy: this.$store.state.user.name
+ }))
+ return Promise.all(syncPromises)
+ }).then((results) => {
+ const failed = (results || []).filter(r => r && r.data && r.data.code !== 0)
+ if (failed.length > 0) {
+ this.$alert((failed[0].data && failed[0].data.msg) || '部分模板同步失败', '错误', { confirmButtonText: '确定' })
+ } else {
+ this.$message.success('同步成功')
+ }
+ this.standardRefreshDetailList()
+ }).catch(() => {})
+ })
+ },
+
standardGetItem () {
this.syncStandardInspectionTypeName()
getPartAttrItem(this.standardDetailData).then(({data}) => {
@@ -3312,7 +3494,7 @@
orderRef3:this.sopData.inspectionTypeNo,
orderRef4: this.sopData.buNo,
}
- getFileContentList(tempData).then(({data}) => {
+ getPartAttributeFileList(tempData).then(({data}) => {
if (data && data.code === 200) {
this.sopList = data.rows
} else {
@@ -3341,6 +3523,17 @@
// 文件下载
downloadFile (row) {
+ if (row.orderReftype === 'AttachmentList') {
+ const linkNode = document.createElement('a')
+ linkNode.href = this.$store.state.user.padSopUrl + row.url
+ linkNode.download = row.fileName
+ linkNode.target = '_blank'
+ linkNode.style.display = 'none'
+ document.body.appendChild(linkNode)
+ linkNode.click()
+ document.body.removeChild(linkNode)
+ return
+ }
downLoadObjectFile(row).then(({data}) => {
// 不限制文件下载类型
const blob = new Blob([data], {type: "application/octet-stream"})
diff --git a/src/views/modules/qc/qcTemplate.vue b/src/views/modules/qc/qcTemplate.vue
index 0caf55b..dc37d60 100644
--- a/src/views/modules/qc/qcTemplate.vue
+++ b/src/views/modules/qc/qcTemplate.vue
@@ -162,7 +162,7 @@
-
+