Browse Source

Merge branch 'deli_scp' of http://dev.ccwin-in.com:3000/sfms3.0/sfms3.0-ui into deli_scp

deli_scp
赵雪冰 2 weeks ago
parent
commit
b5f5d2dc33
  1. 117
      src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue

117
src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue

@ -55,7 +55,8 @@
</el-button>
</template>
<template #action="{ row, $index }">
<ButtonBaseMore :showMoreLength="wsCache.get('lang')=='en-US'?2:3"
<ButtonBaseMore
:showMoreLength="wsCache.get('lang') == 'en-US' ? 2 : 3"
:Butttondata="butttondata(row, $index)"
@button-base-click="buttonTableClick($event, row)"
/>
@ -99,23 +100,25 @@
<!-- 详情 -->
<Detail
ref="detailRef"
:annexTable="switchCurriculumVitae?[
annexInspectionDetail,
{
label: '履历表',
prop: 'uploadFile',
tableName: 'SupplierdeliverCurriculumVitae',
hasSubDetail: false, //
showPreview: true, //
hiddenUpload:false,
hiddenDelete:false,
fileType: ['pdf'],
limit:999999,
align: 'left',
}
]:[
annexInspectionDetail
]"
:annexTable="
switchCurriculumVitae
? [
annexInspectionDetail,
{
label: '履历表',
prop: 'uploadFile',
tableName: 'SupplierdeliverCurriculumVitae',
hasSubDetail: false, //
showPreview: true, //
hiddenUpload: false,
hiddenDelete: false,
fileType: ['pdf'],
limit: 999999,
align: 'left'
}
]
: [annexInspectionDetail]
"
:isBasic="false"
:allSchemas="SupplierdeliverRequestMain.allSchemas"
:detailAllSchemas="SupplierdeliverRequestDetail.allSchemas"
@ -241,13 +244,13 @@ const annexInspectionDetail = ref({
tableName: 'SupplierdeliverInspectionDetail',
hasSubDetail: true, //
showPreview: true, //
hiddenUpload:false,
hiddenDelete:false,
hiddenUpload: false,
hiddenDelete: false,
fileType: ['pdf'],
limit:999999,
limit: 999999,
align: 'left',
updateUrl: getBaseUrl()+import.meta.env.VITE_API_URL+'/infra/file/uploadFile',
checkUploadUrl:SupplierdeliverRequestMainApi.checkUploadFileData,
updateUrl: getBaseUrl() + import.meta.env.VITE_API_URL + '/infra/file/uploadFile',
checkUploadUrl: SupplierdeliverRequestMainApi.checkUploadFileData,
//
subDetailTableData: {
queryParams: [
@ -263,14 +266,12 @@ const annexInspectionDetail = ref({
pageSize: 10,
currentPage: 1
}
})
const tableColumns = ref([
...SupplierdeliverRequestMain.allSchemas.tableColumns,
...SupplierdeliverRequestDetail.allSchemas.tableMainColumns
])
//
const updataTableColumns = (val) => {
tableColumns.value = val
@ -549,7 +550,7 @@ const butttondata = (row, $index) => {
{
label: t('ts.上传履历表'),
name: 'mainPlanCurriculumVitae',
hide: !switchCurriculumVitae.value||row.status==5,
hide: !switchCurriculumVitae.value || row.status == 5,
type: 'primary',
icon: '',
color: '',
@ -628,9 +629,9 @@ const buttonTableClick = async (val, row) => {
} else if (val == 'mainPlanUploadQualityReport') {
//
handleUploadQualityReport(row)
}else if (val == 'mainPlanCurriculumVitae') {
} else if (val == 'mainPlanCurriculumVitae') {
//
handleUploadCurriculumVitae(row,'发货单号', row.asnNumber)
handleUploadCurriculumVitae(row, '发货单号', row.asnNumber)
} else if (val == 'mainPlanSub') {
//
handleSub(row.masterId)
@ -674,12 +675,14 @@ const buttonTableClick = async (val, row) => {
tableObject.loading = true
ElMessageBox.confirm(
`<div>
<strong style="color:red;font-size:18px">${t(`ts.${'重新生成标签后必须撕毁原标签,打印并粘贴新标签,如标签错误将拒绝收货!!'}`)}</strong>
<strong style="color:red;font-size:18px">${t(
`ts.${'重新生成标签后必须撕毁原标签,打印并粘贴新标签,如标签错误将拒绝收货!!'}`
)}</strong>
<br>
<span>${t(`ts.${'重新生成标签会删除上次生成的标签,是否确认继续?'}`)}</span>
</div>`,
t('ts.提示'),
{
{
confirmButtonText: t('ts.确 认'),
cancelButtonText: t('ts.取 消'),
dangerouslyUseHTMLString: true
@ -829,7 +832,7 @@ const openDetail = (row: any, titleName: any, titleValue: any) => {
.get(CACHE_KEY.DEPT)
.find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
annexInspectionDetail.value.hiddenDelete = row.status==8 //HL-5838-status=8
annexInspectionDetail.value.hiddenDelete = row.status == 8 //HL-5838-status=8
detailRef.value.openDetail(row, titleName, titleValue, 'requestSupplierdeliverMain')
}
/** 上传履历表 */
@ -838,11 +841,11 @@ const handleUploadCurriculumVitae = async (row: any, titleName: any, titleValue:
.get(CACHE_KEY.DEPT)
.find((account) => account.id == row.departmentCode)?.name
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode))
annexInspectionDetail.value.hiddenDelete = row.status==8 //HL-5838-status=8
annexInspectionDetail.value.hiddenDelete = row.status == 8 //HL-5838-status=8
detailRef.value.openDetail(row, titleName, titleValue, 'requestSupplierdeliverMain')
nextTick(()=>{
nextTick(() => {
detailRef.value.changeTabCurrent({
label:'履历表'
label: '履历表'
})
})
}
@ -987,9 +990,6 @@ const handleUploadQualityReport = async (row) => {
//uploadQualityReportTableData.value = [tableFormKeys]
}
const submitFormUploadQualityReport = async (formType, data) => {
delete data.number
data.subList = uploadQualityReportTableData.value //
@ -1191,25 +1191,26 @@ const searchTableSuccess1 = async (formField, searchField, val, formRef, type, r
}
// window.open(src.value + '&asn_number=' + val.map(item1=>item1.number).join(','))
await PackageApi.batchPrintingLablesForDL(val.map((item1) => item1.number).join(','))
.then((res) => {
await PackageApi.batchPrintingLablesForDL(val.map((item1) => item1.number).join(',')).then(
(res) => {
console.log(res)
    if (res.zzLabel) {
        //
        const src = ref(BASE_URL + '/jmreport/view/1037887334228496384?token=' + getAccessToken())
        window.open(src.value + '&asn_number=' + res.zzLabel)
      }
      if (res.cgLabel) {
        //
        const src = ref(BASE_URL + '/jmreport/view/1038243804040212480?token=' + getAccessToken())
        window.open(src.value + '&asn_number=' + res.cgLabel)
      }
      if (res.hsjLabel) {
        //
        const src = ref(BASE_URL + '/jmreport/view/1038602906075467776?token=' + getAccessToken())
        window.open(src.value + '&asn_number=' + res.hsjLabel)
      }
})
if (res.zzLabel) {
//
const src = ref(BASE_URL + '/jmreport/view/1037887334228496384?token=' + getAccessToken())
window.open(src.value + '&asn_number=' + res.zzLabel)
}
if (res.cgLabel) {
//
const src = ref(BASE_URL + '/jmreport/view/1038243804040212480?token=' + getAccessToken())
window.open(src.value + '&asn_number=' + res.cgLabel)
}
if (res.hsjLabel) {
//
const src = ref(BASE_URL + '/jmreport/view/1038602906075467776?token=' + getAccessToken())
window.open(src.value + '&asn_number=' + res.hsjLabel)
}
}
)
}
const print = async () => {
@ -1348,9 +1349,9 @@ const switchCurriculumVitae = ref(false)
/** 初始化 **/
onMounted(async () => {
getDefaultSupplier()
let switch2 = await SwitchApi.getByCode('supplerUploadResumeFlag')
switchCurriculumVitae.value = switch2=='TRUE'
console.log('switchCurriculumVitae',switchCurriculumVitae.value)
let switch2 = await SwitchApi.getByCode('supplerUploadResumeFlag')
switchCurriculumVitae.value = switch2 == 'TRUE'
console.log('switchCurriculumVitae', switchCurriculumVitae.value)
getList()
importTemplateData.templateUrl = await SupplierdeliverRequestMainApi.importTemplate()

Loading…
Cancel
Save