Browse Source

YT-378制品子件报废,1.没有QMS,应去掉Q3通知单号字段(新增、导出、导入、申请记录页面)

intex_online20241111
zhang_li 1 month ago
parent
commit
6c348a8829
  1. 22
      src/views/wms/inventoryjobManage/scrap/scrapJobMain/index.vue
  2. 22
      src/views/wms/inventoryjobManage/scrap/scrapRecordMain/index.vue
  3. 24
      src/views/wms/inventoryjobManage/scrap/scrapRequestMain/index.vue
  4. 23
      src/views/wms/issueManage/productionscrap/productionscrapRecordMain/index.vue
  5. 24
      src/views/wms/issueManage/productionscrap/productionscrapRequestMain/index.vue
  6. 22
      src/views/wms/productionManage/productscrap/productscrapRecordMain/index.vue
  7. 23
      src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue
  8. 22
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnJobMain/index.vue
  9. 23
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/index.vue
  10. 10
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMainNew/index.vue
  11. 2
      src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMainNew/purchasereturnRequestMainNew.data.ts

22
src/views/wms/inventoryjobManage/scrap/scrapJobMain/index.vue

@ -75,6 +75,7 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
defineOptions({ name: 'ScrapJobMain' }) defineOptions({ name: 'ScrapJobMain' })
@ -87,6 +88,27 @@ const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ScrapJobMain.allSchemas.tableColumns,...ScrapJobDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ScrapJobMain.allSchemas.tableColumns,...ScrapJobDetail.allSchemas.tableMainColumns])
const ScrapJobMainAllSchema =ref(JSON.parse(JSON.stringify(ScrapJobMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ScrapJobMain.allSchemas = ScrapJobMainAllSchema.value.allSchemas
} else {
ScrapJobMain.allSchemas.formSchema = ScrapJobMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapJobMain.allSchemas.tableColumns = ScrapJobMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapJobMain.allSchemas.tableFormColumns = ScrapJobMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapJobMain.allSchemas.tableMainColumns = ScrapJobMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapJobMain.allSchemas.detailSchema = ScrapJobMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapJobMain.allSchemas.searchSchema = ScrapJobMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val

22
src/views/wms/inventoryjobManage/scrap/scrapRecordMain/index.vue

@ -70,6 +70,7 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
defineOptions({ name: 'ScrapRecordMain' }) defineOptions({ name: 'ScrapRecordMain' })
@ -82,6 +83,27 @@ const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ScrapRecordMain.allSchemas.tableColumns,...ScrapRecordDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ScrapRecordMain.allSchemas.tableColumns,...ScrapRecordDetail.allSchemas.tableMainColumns])
const ScrapRecordMainAllSchema =ref(JSON.parse(JSON.stringify(ScrapRecordMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ScrapRecordMain.allSchemas = ScrapRecordMainAllSchema .value.allSchemas
} else {
ScrapRecordMain.allSchemas.formSchema = ScrapRecordMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRecordMain.allSchemas.tableColumns = ScrapRecordMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRecordMain.allSchemas.tableFormColumns = ScrapRecordMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRecordMain.allSchemas.tableMainColumns = ScrapRecordMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRecordMain.allSchemas.detailSchema = ScrapRecordMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRecordMain.allSchemas.searchSchema = ScrapRecordMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val

24
src/views/wms/inventoryjobManage/scrap/scrapRequestMain/index.vue

@ -73,6 +73,7 @@
@submitForm="submitForm" @submitForm="submitForm"
@tableFormSelectOnBlur="tableFormSelectOnBlur" @tableFormSelectOnBlur="tableFormSelectOnBlur"
@clearSearchInput="clearSearchInput" @clearSearchInput="clearSearchInput"
:key="updateKey"
/> />
<!-- 详情 --> <!-- 详情 -->
@ -118,6 +119,7 @@ import * as ScrapRequestMainApi from '@/api/wms/scrapRequestMain'
import * as ScrapRequestDetailApi from '@/api/wms/scrapRequestDetail' import * as ScrapRequestDetailApi from '@/api/wms/scrapRequestDetail'
import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as defaultButtons from '@/utils/disposition/defaultButtons'
import * as StdcostpriceApi from '@/api/wms/stdcostprice' import * as StdcostpriceApi from '@/api/wms/stdcostprice'
import { getSwitchByCode } from '@/api/wms/switch'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
@ -134,7 +136,27 @@ const tableColumns = ref([
...ScrapRequestMain.allSchemas.tableColumns, ...ScrapRequestMain.allSchemas.tableColumns,
...ScrapRequestDetail.allSchemas.tableMainColumns ...ScrapRequestDetail.allSchemas.tableMainColumns
]) ])
const ScrapRequestMainAllSchema =ref(JSON.parse(JSON.stringify(ScrapRequestMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ScrapRequestMain.allSchemas = ScrapRequestMainAllSchema.value.allSchemas
} else {
ScrapRequestMain.allSchemas.formSchema = ScrapRequestMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRequestMain.allSchemas.tableColumns = ScrapRequestMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRequestMain.allSchemas.tableFormColumns = ScrapRequestMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRequestMain.allSchemas.tableMainColumns = ScrapRequestMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRequestMain.allSchemas.detailSchema = ScrapRequestMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
ScrapRequestMain.allSchemas.searchSchema = ScrapRequestMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q1Number'&&item.field != 'q2Number'&&item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val

23
src/views/wms/issueManage/productionscrap/productionscrapRecordMain/index.vue

@ -77,6 +77,7 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// 退 // 退
defineOptions({ name: 'ProductionscrapRecordMain' }) defineOptions({ name: 'ProductionscrapRecordMain' })
@ -88,7 +89,27 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ProductionscrapRecordMain.allSchemas.tableColumns,...ProductionscrapRecordDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ProductionscrapRecordMain.allSchemas.tableColumns,...ProductionscrapRecordDetail.allSchemas.tableMainColumns])
const ProductionscrapRecordMainAllSchema =ref(JSON.parse(JSON.stringify(ProductionscrapRecordMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ProductionscrapRecordMain.allSchemas = ProductionscrapRecordMainAllSchema.value.allSchemas
} else {
ProductionscrapRecordMain.allSchemas.formSchema = ProductionscrapRecordMainAllSchema.value.allSchemas.formSchema.filter(item =>item.field != 'q3Number')
ProductionscrapRecordMain.allSchemas.tableColumns = ProductionscrapRecordMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q3Number')
ProductionscrapRecordMain.allSchemas.tableFormColumns = ProductionscrapRecordMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q3Number')
ProductionscrapRecordMain.allSchemas.tableMainColumns = ProductionscrapRecordMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q3Number')
ProductionscrapRecordMain.allSchemas.detailSchema = ProductionscrapRecordMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q3Number')
ProductionscrapRecordMain.allSchemas.searchSchema = ProductionscrapRecordMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val

24
src/views/wms/issueManage/productionscrap/productionscrapRequestMain/index.vue

@ -64,6 +64,7 @@
@submitForm="submitForm" @submitForm="submitForm"
@inputNumberChange="inputNumberChange" @inputNumberChange="inputNumberChange"
@clearSearchInput="clearSearchInput" @clearSearchInput="clearSearchInput"
:key="updateKey"
/> />
<!-- 详情 --> <!-- 详情 -->
@ -125,6 +126,7 @@ import { getAccessToken } from '@/utils/auth'
import { getJmreportBaseUrl } from '@/utils/systemParam' import { getJmreportBaseUrl } from '@/utils/systemParam'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// 线 // 线
defineOptions({ name: 'ProductionscrapRequestMain' }) defineOptions({ name: 'ProductionscrapRequestMain' })
@ -136,6 +138,28 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ProductionscrapRequestMain.allSchemas.tableColumns,...ProductionscrapRequestDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ProductionscrapRequestMain.allSchemas.tableColumns,...ProductionscrapRequestDetail.allSchemas.tableMainColumns])
const ProductionscrapRequestMainAllSchema =ref(JSON.parse(JSON.stringify(ProductionscrapRequestMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ProductionscrapRequestMain.allSchemas = ProductionscrapRequestMainAllSchema.value.allSchemas
} else {
ProductionscrapRequestMain.allSchemas.formSchema = ProductionscrapRequestMainAllSchema.value.allSchemas.formSchema.filter(item =>item.field != 'q3Number')
ProductionscrapRequestMain.allSchemas.tableColumns = ProductionscrapRequestMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q3Number')
ProductionscrapRequestMain.allSchemas.tableFormColumns = ProductionscrapRequestMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q3Number')
ProductionscrapRequestMain.allSchemas.tableMainColumns = ProductionscrapRequestMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q3Number')
ProductionscrapRequestMain.allSchemas.detailSchema = ProductionscrapRequestMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q3Number')
ProductionscrapRequestMain.allSchemas.searchSchema = ProductionscrapRequestMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const detailListTableColumns = ProductionscrapRequestDetailLabel.allSchemas const detailListTableColumns = ProductionscrapRequestDetailLabel.allSchemas

22
src/views/wms/productionManage/productscrap/productscrapRecordMain/index.vue

@ -97,6 +97,7 @@ import {getProductscrapBomDismantleRecordPage} from "@/api/wms/bomDismantle";
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
defineOptions({ name: 'ProductscrapRecordMain' }) defineOptions({ name: 'ProductscrapRecordMain' })
@ -108,6 +109,27 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ProductscrapRecordMain.allSchemas.tableColumns,...ProductscrapRecordDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ProductscrapRecordMain.allSchemas.tableColumns,...ProductscrapRecordDetail.allSchemas.tableMainColumns])
const ProductscrapRecordMainAllSchema =ref(JSON.parse(JSON.stringify(ProductscrapRecordMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ProductscrapRecordMain.allSchemas = ProductscrapRecordMainAllSchema.value.allSchemas
} else {
ProductscrapRecordMain.allSchemas.formSchema = ProductscrapRecordMainAllSchema.value.allSchemas.formSchema.filter(item =>item.field != 'q3Number')
ProductscrapRecordMain.allSchemas.tableColumns = ProductscrapRecordMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q3Number')
ProductscrapRecordMain.allSchemas.tableFormColumns = ProductscrapRecordMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q3Number')
ProductscrapRecordMain.allSchemas.tableMainColumns = ProductscrapRecordMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q3Number')
ProductscrapRecordMain.allSchemas.detailSchema = ProductscrapRecordMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q3Number')
ProductscrapRecordMain.allSchemas.searchSchema = ProductscrapRecordMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// table // table
const buttondataTable = ref([{ const buttondataTable = ref([{

23
src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue

@ -63,6 +63,7 @@
@submitForm="submitForm" @submitForm="submitForm"
@buttonOperationClick="buttonOperationClick" @buttonOperationClick="buttonOperationClick"
@clearSearchInput="clearSearchInput" @clearSearchInput="clearSearchInput"
:key='updateKey'
/> />
<!-- 详情 --> <!-- 详情 -->
@ -143,6 +144,7 @@ import * as BomApi from "@/api/wms/bom";
import * as BalanceApi from "@/api/wms/balance"; import * as BalanceApi from "@/api/wms/balance";
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// //
defineOptions({ name: 'ProductscrapRequestMain' }) defineOptions({ name: 'ProductscrapRequestMain' })
@ -154,6 +156,27 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...ProductscrapRequestMain.allSchemas.tableColumns,...ProductscrapRequestDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...ProductscrapRequestMain.allSchemas.tableColumns,...ProductscrapRequestDetail.allSchemas.tableMainColumns])
const ProductscrapRequestMainAllSchema =ref(JSON.parse(JSON.stringify(ProductscrapRequestMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
ProductscrapRequestMain.allSchemas = ProductscrapRequestMainAllSchema.value.allSchemas
} else {
ProductscrapRequestMain.allSchemas.formSchema = ProductscrapRequestMainAllSchema.value.allSchemas.formSchema.filter(item =>item.field != 'q3Number')
ProductscrapRequestMain.allSchemas.tableColumns = ProductscrapRequestMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q3Number')
ProductscrapRequestMain.allSchemas.tableFormColumns = ProductscrapRequestMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q3Number')
ProductscrapRequestMain.allSchemas.tableMainColumns = ProductscrapRequestMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q3Number')
ProductscrapRequestMain.allSchemas.detailSchema = ProductscrapRequestMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q3Number')
ProductscrapRequestMain.allSchemas.searchSchema = ProductscrapRequestMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q3Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// table // table
const buttondataTable = ref([{ const buttondataTable = ref([{

22
src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnJobMain/index.vue

@ -75,6 +75,7 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { CACHE_KEY, useCache } from '@/hooks/web/useCache' import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// 退 // 退
defineOptions({ name: 'PurchasereturnJobMain' }) defineOptions({ name: 'PurchasereturnJobMain' })
@ -86,7 +87,28 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...PurchasereturnJobMain.allSchemas.tableColumns,...PurchasereturnJobDetail.allSchemas.tableColumns]) const tableColumns = ref([...PurchasereturnJobMain.allSchemas.tableColumns,...PurchasereturnJobDetail.allSchemas.tableColumns])
const PurchasereturnJobMainAllSchema =ref(JSON.parse(JSON.stringify(PurchasereturnJobMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
PurchasereturnJobMain.allSchemas = PurchasereturnJobMainAllSchema.value.allSchemas
} else {
PurchasereturnJobMain.allSchemas.formSchema = PurchasereturnJobMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q2Number')
PurchasereturnJobMain.allSchemas.tableColumns = PurchasereturnJobMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q2Number')
PurchasereturnJobMain.allSchemas.tableFormColumns = PurchasereturnJobMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q2Number')
PurchasereturnJobMain.allSchemas.tableMainColumns = PurchasereturnJobMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q2Number')
PurchasereturnJobMain.allSchemas.detailSchema = PurchasereturnJobMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q2Number')
PurchasereturnJobMain.allSchemas.searchSchema = PurchasereturnJobMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q2Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {
tableColumns.value = val tableColumns.value = val

23
src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRecordMain/index.vue

@ -72,6 +72,7 @@ import { CACHE_KEY, useCache } from '@/hooks/web/useCache'
import { getJmreportBaseUrl } from '@/utils/systemParam' import { getJmreportBaseUrl } from '@/utils/systemParam'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading' import { usePageLoading } from '@/hooks/web/usePageLoading'
import { getSwitchByCode } from '@/api/wms/switch'
const { loadStart, loadDone } = usePageLoading() const { loadStart, loadDone } = usePageLoading()
// 退 // 退
defineOptions({ name: 'PurchasereturnRecordMain' }) defineOptions({ name: 'PurchasereturnRecordMain' })
@ -83,6 +84,28 @@ const route = useRoute() // 路由信息
const routeName = ref() const routeName = ref()
routeName.value = route.name routeName.value = route.name
const tableColumns = ref([...PurchasereturnRecordMain.allSchemas.tableColumns,...PurchasereturnRecordDetail.allSchemas.tableMainColumns]) const tableColumns = ref([...PurchasereturnRecordMain.allSchemas.tableColumns,...PurchasereturnRecordDetail.allSchemas.tableMainColumns])
const PurchasereturnRecordMainAllSchema =ref(JSON.parse(JSON.stringify(PurchasereturnRecordMain)))
// QMSq1q2q3
const EnableQms = ref(true)
const updateKey = ref(0)
const getSwitchByCode1 =async () => {
await getSwitchByCode("EnableQms").then((res) => {
EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) {
PurchasereturnRecordMain.allSchemas = PurchasereturnRecordMainAllSchema.value.allSchemas
} else {
PurchasereturnRecordMain.allSchemas.formSchema = PurchasereturnRecordMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q2Number')
PurchasereturnRecordMain.allSchemas.tableColumns = PurchasereturnRecordMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q2Number')
PurchasereturnRecordMain.allSchemas.tableFormColumns = PurchasereturnRecordMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q2Number')
PurchasereturnRecordMain.allSchemas.tableMainColumns = PurchasereturnRecordMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q2Number')
PurchasereturnRecordMain.allSchemas.detailSchema = PurchasereturnRecordMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q2Number')
PurchasereturnRecordMain.allSchemas.searchSchema = PurchasereturnRecordMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q2Number')
}
updateKey.value++
})
}
getSwitchByCode1()
// //
const updataTableColumns = (val) => { const updataTableColumns = (val) => {

10
src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMainNew/index.vue

@ -206,6 +206,7 @@ const isShowButton = ref(true)
const PurchasereturnRequestMainNewAllSchema =ref(JSON.parse(JSON.stringify(PurchasereturnRequestMainNew))) const PurchasereturnRequestMainNewAllSchema =ref(JSON.parse(JSON.stringify(PurchasereturnRequestMainNew)))
const PurchasereturnRequestMainAllSchema =ref(JSON.parse(JSON.stringify(PurchasereturnRequestMain)))
// QMSq1q2q3 // QMSq1q2q3
const EnableQms = ref(true) const EnableQms = ref(true)
const updateKey = ref(0) const updateKey = ref(0)
@ -214,6 +215,7 @@ const getSwitchByCode1 =async () => {
EnableQms.value = res == 'TRUE' ? true : false EnableQms.value = res == 'TRUE' ? true : false
if (EnableQms.value) { if (EnableQms.value) {
PurchasereturnRequestMainNew.allSchemas = PurchasereturnRequestMainNewAllSchema.value.allSchemas PurchasereturnRequestMainNew.allSchemas = PurchasereturnRequestMainNewAllSchema.value.allSchemas
PurchasereturnRequestMain.allSchemas = PurchasereturnRequestMainAllSchema.value.allSchemas
} else { } else {
PurchasereturnRequestMainNew.allSchemas.formSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q2Number') PurchasereturnRequestMainNew.allSchemas.formSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q2Number')
PurchasereturnRequestMainNew.allSchemas.tableColumns = PurchasereturnRequestMainNewAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q2Number') PurchasereturnRequestMainNew.allSchemas.tableColumns = PurchasereturnRequestMainNewAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q2Number')
@ -221,8 +223,14 @@ const getSwitchByCode1 =async () => {
PurchasereturnRequestMainNew.allSchemas.tableMainColumns = PurchasereturnRequestMainNewAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q2Number') PurchasereturnRequestMainNew.allSchemas.tableMainColumns = PurchasereturnRequestMainNewAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q2Number')
PurchasereturnRequestMainNew.allSchemas.detailSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q2Number') PurchasereturnRequestMainNew.allSchemas.detailSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q2Number')
PurchasereturnRequestMainNew.allSchemas.searchSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q2Number') PurchasereturnRequestMainNew.allSchemas.searchSchema = PurchasereturnRequestMainNewAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.formSchema = PurchasereturnRequestMainAllSchema.value.allSchemas.formSchema.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.tableColumns = PurchasereturnRequestMainAllSchema.value.allSchemas.tableColumns.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.tableFormColumns = PurchasereturnRequestMainAllSchema.value.allSchemas.tableFormColumns.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.tableMainColumns = PurchasereturnRequestMainAllSchema.value.allSchemas.tableMainColumns.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.detailSchema = PurchasereturnRequestMainAllSchema.value.allSchemas.detailSchema.filter(item => item.field != 'q2Number')
PurchasereturnRequestMain.allSchemas.searchSchema = PurchasereturnRequestMainAllSchema.value.allSchemas.searchSchema.filter(item => item.field != 'q2Number')
} }
console.log(999,PurchasereturnRequestMainNew.allSchemas)
updateKey.value++ updateKey.value++
}) })
} }

2
src/views/wms/purchasereceiptManage/purchasereturn/purchasereturnRequestMainNew/purchasereturnRequestMainNew.data.ts

@ -261,7 +261,7 @@ export const PurchasereturnRequestMainNew = useCrudSchemas(
} }
}, },
{ {
label: 'Q2通知单号11', label: 'Q2通知单号',
field: 'q2Number', field: 'q2Number',
sort: 'custom', sort: 'custom',
isSearch: false, isSearch: false,

Loading…
Cancel
Save