Browse Source

备品备件

java8
ruanqi 11 months ago
parent
commit
8d6480a55c
  1. 1
      src/api/ecss/ecss.js
  2. 1
      src/views/modules/ecss/codelnotify.vue
  3. 3
      src/views/modules/ecss/codelnotifyConfirm.vue
  4. 138
      src/views/modules/ecss/createDeclaration.vue

1
src/api/ecss/ecss.js

@ -54,3 +54,4 @@ export const getDeclarationDefaultData= data => createAPI(`/ecss/coDel/getDeclar
export const partInformationHsCode= data => createAPI(`/ecss/coDel/partInformationHsCode`,'post',data)
export const savePartHSCode= data => createAPI(`/ecss/coDel/savePartHSCode`,'post',data)
export const saveDeclaration= data => createAPI(`/ecss/coDel/saveDeclaration`,'post',data)

1
src/views/modules/ecss/codelnotify.vue

@ -24,6 +24,7 @@
<el-option label="已计划" value="已计划"></el-option>
<el-option label="已下达" value="已下达"></el-option>
<el-option label="仓库已确认" value="仓库已确认"></el-option>
<el-option label="已报关" value="已报关"></el-option>
</el-select>
</el-form-item>
<el-form-item :label="'ReadyDate'" >

3
src/views/modules/ecss/codelnotifyConfirm.vue

@ -23,6 +23,7 @@
<el-option label="全部" value=""></el-option>
<el-option label="已下达" value="已下达"></el-option>
<el-option label="仓库已确认" value="仓库已确认"></el-option>
<el-option label="已报关" value="已报关"></el-option>
</el-select>
</el-form-item>
<el-form-item :label="'ReadyDate'" >
@ -185,7 +186,7 @@
label="操作">
<template slot-scope="scope">
<a type="text" size="small" v-if="currentRow.notifyStatus==='仓库已确认'" @click="boxDetailModel(scope.row)">箱明细</a>
<a type="text" size="small" @click="boxDetailModel(scope.row)">箱明细</a>
<a type="text" size="small" v-if="currentRow.notifyStatus==='仓库已确认'" @click="updatePalletModel(scope.row)">修改</a>
<a type="text" size="small" v-if="currentRow.notifyStatus==='仓库已确认'" @click="deletePallet(scope.row)">删除</a>
</template>

138
src/views/modules/ecss/createDeclaration.vue

@ -354,6 +354,110 @@
</el-col>
</el-row>
</el-form>
<div class="rq ">
<el-table
height="250"
:data="detailList"
border
v-loading="dataListLoading"
style="width: 100%;">
<el-table-column
prop="hsCode"
header-align="center"
align="left"
label="HSCODE"
min-width="80">
</el-table-column>
<el-table-column
prop="hsCodeDesc"
header-align="center"
align="left"
label="品名"
min-width="120">
</el-table-column>
<el-table-column
prop="qty"
header-align="center"
align="right"
label="数量"
min-width="60">
</el-table-column>
<el-table-column
prop="netWeight"
header-align="center"
align="right"
label="净重"
min-width="60">
</el-table-column>
<el-table-column
prop="unitPrice"
header-align="center"
align="right"
label="单价"
min-width="60">
<template slot-scope="scope">
<el-input v-model="scope.row.unitPrice" @change="changeToalPrice(scope.row)" type="number" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
<el-table-column
prop="totalPrice"
header-align="center"
align="right"
label="总价"
min-width="60">
</el-table-column>
<el-table-column
prop="currency"
header-align="center"
align="left"
label="币制"
min-width="60">
<template slot-scope="scope">
<el-input v-model="scope.row.currency" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
<el-table-column
prop="madeArea"
header-align="center"
align="left"
label="原产国(地区)"
min-width="80">
<template slot-scope="scope">
<el-input v-model="scope.row.madeArea" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
<el-table-column
prop="destination"
header-align="center"
align="left"
label="最终目的国(地区)"
min-width="100">
<template slot-scope="scope">
<el-input v-model="scope.row.destination" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
<el-table-column
prop="sourceArea"
header-align="center"
align="left"
label="境内货源地"
min-width="100">
<template slot-scope="scope">
<el-input v-model="scope.row.sourceArea" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
<el-table-column
prop="levy"
header-align="center"
align="left"
label="征免"
min-width="60">
<template slot-scope="scope">
<el-input v-model="scope.row.levy" style="height: 11px;width:98%"></el-input>
</template>
</el-table-column>
</el-table>
</div>
<el-footer style="height:40px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="saveDeclaration()">保存</el-button>
<el-button type="primary" @click="declarationFlag=false">关闭</el-button>
@ -373,6 +477,7 @@
searchEcssCoDelNotifyDetail,
searchCoDelPalletData,
getDeclarationDefaultData,
saveDeclaration,
}from "@/api/ecss/ecss.js"
import {getAllBuList}from '@/api/factory/site.js'
export default {
@ -390,6 +495,7 @@
dataList:[],
dataList2:[],
dataList3:[],
detailList:[],
dataListLoading: false,
searchData: {
page: 1,
@ -1480,11 +1586,15 @@
}
})
},
changeToalPrice(row){
row.totalPrice=row.unitPrice*row.qty
},
declarationModel(row){
getDeclarationDefaultData(row).then(({data}) => {
//
if (data && data.code === 0) {
this.declarationData=data.row
this.detailList=data.rows
this.declarationFlag=true
} else {
this.$alert(data.msg, '错误', {
@ -1493,6 +1603,34 @@
}
});
},
saveDeclaration(){
if(this.detailList==null|| this.detailList.length<1){
this.$alert('不存在明细记录!', '错误', {
confirmButtonText: '确定'
})
return false
}
for (let i = 0; i <this.detailList.length ; i++) {
if(this.detailList[i].unitPrice==null||this.detailList[i].unitPrice==""||this.detailList[i].unitPrice<=0){
this.$alert('请输入正确的单价!', '错误', {
confirmButtonText: '确定'
})
return false
}
}
this.declarationData.detailList=this.detailList
saveDeclaration(this.declarationData).then(({data}) => {
//
if (data && data.code === 0) {
this.declarationFlag=false
this.searchTable()
} else {
this.$alert(data.msg, '错误', {
confirmButtonText: '确定'
})
}
});
},
//excel
async createExportData() {
this.searchData.limit = -1

Loading…
Cancel
Save