han\hanst 20 hours ago
parent
commit
ca5a20d199
  1. 23
      src/views/modules/ecss/hsCode.vue
  2. 36
      src/views/modules/ecss/partHsCode.vue

23
src/views/modules/ecss/hsCode.vue

@ -123,7 +123,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item :label="'品牌'" > <el-form-item :label="'品牌'" >
<el-input v-model="addModel.brand" :disabled="addModel.addFlag!==0" ></el-input>
<el-input v-model="addModel.brand"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
@ -194,7 +194,8 @@
codeNo:'', codeNo:'',
unit:'', unit:'',
remark:'', remark:'',
brand:'无'
brand:'无',
oldBrand:''
}, },
addDisabledFlag:true, addDisabledFlag:true,
activeName:'attribute', activeName:'attribute',
@ -523,7 +524,8 @@
codeNo:'', codeNo:'',
unit:'', unit:'',
remark:'', remark:'',
brand:''
brand:'',
oldBrand:''
} }
this.addModelFlag=true this.addModelFlag=true
}, },
@ -551,6 +553,7 @@
}, },
updateModelOpen(row){ updateModelOpen(row){
this.addDisabledFlag=false this.addDisabledFlag=false
let currentBrand = row.brand || '无'
this.addModel={ this.addModel={
addFlag:1, addFlag:1,
site:row.site, site:row.site,
@ -561,7 +564,8 @@
codeNo:row.codeNo, codeNo:row.codeNo,
unit:row.unit, unit:row.unit,
remark:row.remark, remark:row.remark,
brand:row.brand || '无'
brand:currentBrand,
oldBrand:currentBrand
} }
this.addModelFlag=true this.addModelFlag=true
}, },
@ -610,12 +614,21 @@
}) })
return false return false
} }
if(this.addModel.brand==null||this.addModel.brand===''){
const brand = this.addModel.brand == null ? '' : String(this.addModel.brand).trim()
if(brand===''){
this.$alert('请输入品牌!', '错误', { this.$alert('请输入品牌!', '错误', {
confirmButtonText: '确定' confirmButtonText: '确定'
}) })
return false return false
} }
this.addModel.brand = brand
if (this.addModel.addFlag === 0) {
this.addModel.oldBrand = ''
} else {
this.addModel.oldBrand = this.addModel.oldBrand
? String(this.addModel.oldBrand).trim()
: this.addModel.brand
}
if(!this.isCodeNoOptionalBu(this.addModel.buNo) && (this.addModel.codeNo==null||this.addModel.codeNo==='')){ if(!this.isCodeNoOptionalBu(this.addModel.buNo) && (this.addModel.codeNo==null||this.addModel.codeNo==='')){
this.$alert('请选择属性模板!', '错误', { this.$alert('请选择属性模板!', '错误', {
confirmButtonText: '确定' confirmButtonText: '确定'

36
src/views/modules/ecss/partHsCode.vue

@ -136,11 +136,16 @@
<el-input v-model="hsCodeModelData.hsCodeDesc" disabled ></el-input> <el-input v-model="hsCodeModelData.hsCodeDesc" disabled ></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12">
<el-col :span="6">
<el-form-item :label="'HS Code'" > <el-form-item :label="'HS Code'" >
<el-input v-model="hsCodeModelData.hsCode" disabled ></el-input> <el-input v-model="hsCodeModelData.hsCode" disabled ></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6">
<el-form-item :label="'品牌'">
<el-input v-model="hsCodeModelData.brand" disabled ></el-input>
</el-form-item>
</el-col>
<!-- <el-col :span="12"> <!-- <el-col :span="12">
<el-form-item > <el-form-item >
<template #label> <template #label>
@ -181,6 +186,15 @@
<el-input v-model="packageVolume" disabled ></el-input> <el-input v-model="packageVolume" disabled ></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="8" v-if="isMhmBu(hsCodeModelData.buNo)">
<el-form-item :label="'单位'">
<el-input
v-model="hsCodeModelData.ecssUmid"
clearable
placeholder="请输入单位">
</el-input>
</el-form-item>
</el-col>
</el-row> </el-row>
</el-form> </el-form>
<el-footer style="height:40px;margin-top: 10px;text-align:center"> <el-footer style="height:40px;margin-top: 10px;text-align:center">
@ -224,6 +238,12 @@
align="center" align="center"
label="HS Code"> label="HS Code">
</el-table-column> </el-table-column>
<el-table-column
prop="brand"
header-align="center"
align="center"
label="品牌">
</el-table-column>
</el-table> </el-table>
<el-footer style="height:40px;margin-top: 10px;text-align:center"> <el-footer style="height:40px;margin-top: 10px;text-align:center">
<el-button @click="hsCodeFlag = false">关闭</el-button> <el-button @click="hsCodeFlag = false">关闭</el-button>
@ -756,10 +776,12 @@
partDesc: '', partDesc: '',
hsCode:'', hsCode:'',
hsCodeDesc:'', hsCodeDesc:'',
brand:'',
packageNo:'', packageNo:'',
length: '', length: '',
width: '', width: '',
height: ''
height: '',
ecssUmid: ''
}, },
currentRow:{ currentRow:{
site:'', site:'',
@ -810,6 +832,7 @@
hsCodeRowDblclick (row) { hsCodeRowDblclick (row) {
this.hsCodeModelData.hsCodeDesc = row.hsCodeDesc this.hsCodeModelData.hsCodeDesc = row.hsCodeDesc
this.hsCodeModelData.hsCode = row.HsCode this.hsCodeModelData.hsCode = row.HsCode
this.hsCodeModelData.brand = row.brand || row.Brand || ''
this.hsCodeFlag = false this.hsCodeFlag = false
}, },
@ -950,8 +973,17 @@
this.hsCodeModelData.length = row.boxLength/100 this.hsCodeModelData.length = row.boxLength/100
this.hsCodeModelData.width = row.boxWidth/100 this.hsCodeModelData.width = row.boxWidth/100
this.hsCodeModelData.height = row.boxHeight/100 this.hsCodeModelData.height = row.boxHeight/100
this.hsCodeModelData.brand = row.brand || row.Brand || ''
this.hsCodeModelData.ecssUmid = row.ecssUmid || ''
this.hsCodeModelFlag=true this.hsCodeModelFlag=true
}, },
/**
* 是否天线BU04-MHM
*/
isMhmBu(buNo) {
const currentBuNo = (buNo || '').toString().toUpperCase()
return currentBuNo === '04-MHM' || currentBuNo === '04'
},
changeData(row){ changeData(row){
this.currentRow = JSON.parse(JSON.stringify(row)); this.currentRow = JSON.parse(JSON.stringify(row));
this.refreshCurrentTabTable (); this.refreshCurrentTabTable ();

Loading…
Cancel
Save