|
@ -114,7 +114,7 @@ |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column label="商品编码" prop="goodsSkuCode" width="150" align="center" /> |
|
|
<el-table-column label="商品编码" prop="goodsSkuCode" width="150" align="center" /> |
|
|
<el-table-column label="商品名称" prop="goodsName" width="150" align="center" /> |
|
|
<el-table-column label="商品名称" prop="goodsSkuTitle" width="150" align="center" /> |
|
|
<el-table-column label="商品规格" prop="goodsSkuOwnSpec" width="150" align="center" /> |
|
|
<el-table-column label="商品规格" prop="goodsSkuOwnSpec" width="150" align="center" /> |
|
|
<el-table-column label="单位" prop="unit" width="120" align="center" /> |
|
|
<el-table-column label="单位" prop="unit" width="120" align="center" /> |
|
|
<el-table-column label="采购数量" align="center" prop="count" width="150"> |
|
|
<el-table-column label="采购数量" align="center" prop="count" width="150"> |
|
@ -123,9 +123,9 @@ |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" @input="calculation(scope.row,'count',$event)" /> |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" @input="calculation(scope.row,'count',$event)" /> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column label="数量(pcs)" prop="pcsNum" align="center" width="150"> |
|
|
<el-table-column label="数量(pcs)" prop="pcsCount" align="center" width="150"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-input v-model="scope.row.pcsNum" clearable placeholder="" |
|
|
<el-input v-model="scope.row.pcsCount" clearable placeholder="" |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" /> |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" /> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
@ -157,13 +157,13 @@ |
|
|
oninput="value=value.replace(/[^\d.]/g, '').replace(/\.{2,}/g, '.').replace('.', '$#$').replace(/\./g, '').replace('$#$', '.').replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3').replace(/^\./g, '')" /> |
|
|
oninput="value=value.replace(/[^\d.]/g, '').replace(/\.{2,}/g, '.').replace('.', '$#$').replace(/\./g, '').replace('$#$', '.').replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3').replace(/^\./g, '')" /> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column prop="notTaxPprice" label="未含税价" width="120" align="center" /> |
|
|
<el-table-column prop="unTaxPrice" label="未含税价" width="120" align="center" /> |
|
|
<el-table-column prop="totalTax" label="总税额" width="120" align="center" /> |
|
|
<el-table-column prop="taxAmount" label="总税额" width="120" align="center" /> |
|
|
<el-table-column prop="totalNotTaxPprice" label="未含总税价" width="120" align="center" /> |
|
|
<el-table-column prop="unTaxTotalAmount" label="未含总税价" width="120" align="center" /> |
|
|
<!-- <el-table-column prop="purchaseCycle" label="采购周期" width="120" align="center" /> --> |
|
|
<!-- <el-table-column prop="cycle" label="采购周期" width="120" align="center" /> --> |
|
|
<el-table-column label="采购周期" align="center" width="150"> |
|
|
<el-table-column label="采购周期" align="center" width="150"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-input v-model="scope.row.purchaseCycle" clearable placeholder="" @input="computeDate(scope.row)" |
|
|
<el-input v-model="scope.row.cycle" clearable placeholder="" @input="computeDate(scope.row)" |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" /> </template> |
|
|
oninput="value=value.replace(/^(0+)|[^\d]+/g,'')" /> </template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column prop="deliveryDate" label="预计到货日期" width="180" align="center" /> |
|
|
<el-table-column prop="deliveryDate" label="预计到货日期" width="180" align="center" /> |
|
@ -176,13 +176,13 @@ |
|
|
<!-- <el-table-column prop="manufactureDate" label="生产日期" width="120" align="center" /> --> |
|
|
<!-- <el-table-column prop="manufactureDate" label="生产日期" width="120" align="center" /> --> |
|
|
<el-table-column label="生产日期" align="center" min-width="250"> |
|
|
<el-table-column label="生产日期" align="center" min-width="250"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-date-picker v-model="scope.row.manufactureDate" type="date" value-format="yyyy-MM-dd" |
|
|
<el-date-picker v-model="scope.row.madeDate" type="date" value-format="yyyy-MM-dd" placeholder="选择日期" |
|
|
placeholder="选择日期" @change="manufactureDateChange(scope.row)" /> |
|
|
@change="manufactureDateChange(scope.row)" /> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
<el-table-column prop="overdueDate" label="过期日期" width="120" align="center" /> |
|
|
<el-table-column prop="expireDate" label="过期日期" width="120" align="center" /> |
|
|
<el-table-column prop="batchNumber" label="批次号" width="200" align="center" /> |
|
|
<el-table-column prop="batchNumber" label="批次号" width="200" align="center" /> |
|
|
<el-table-column prop="itemNumber" label="货号" width="120" align="center" /> |
|
|
<el-table-column prop="goodsNum" label="货号" width="120" align="center" /> |
|
|
<el-table-column label="备注" align="center" width="150"> |
|
|
<el-table-column label="备注" align="center" width="150"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<el-input v-model="scope.row.remarks" clearable placeholder="" /> |
|
|
<el-input v-model="scope.row.remarks" clearable placeholder="" /> |
|
@ -224,9 +224,8 @@ |
|
|
<el-row> |
|
|
<el-row> |
|
|
<el-col :span="8"> |
|
|
<el-col :span="8"> |
|
|
<div class="span-sty">其他费用</div> |
|
|
<div class="span-sty">其他费用</div> |
|
|
<el-form-item prop="otherAmountName"> <el-input class="addinputw addinputInfo" |
|
|
<el-form-item prop="otherAmount"> <el-input class="addinputw addinputInfo" |
|
|
v-model="formobj.purchaseBillAmount.otherAmountName" clearable placeholder="" |
|
|
v-model="formobj.purchaseBillAmount.otherAmount" clearable placeholder="" @change="computeShareAmount" |
|
|
@change="computeShareAmount" |
|
|
|
|
|
oninput="value=value.replace(/[^\d.]/g, '').replace(/\.{2,}/g, '.').replace('.', '$#$').replace(/\./g, '').replace('$#$', '.').replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3').replace(/^\./g, '')" /> |
|
|
oninput="value=value.replace(/[^\d.]/g, '').replace(/\.{2,}/g, '.').replace('.', '$#$').replace(/\./g, '').replace('$#$', '.').replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3').replace(/^\./g, '')" /> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
|
|
|
|
|
@ -274,7 +273,6 @@ |
|
|
import req from '@/api/purchase/purchaseOrder.js' |
|
|
import req from '@/api/purchase/purchaseOrder.js' |
|
|
import chooseproducts from './relation/chooseproducts' |
|
|
import chooseproducts from './relation/chooseproducts' |
|
|
import { |
|
|
import { |
|
|
getOrgSidByPath, |
|
|
|
|
|
choiceSupplierInfo, |
|
|
choiceSupplierInfo, |
|
|
getWarehouses, |
|
|
getWarehouses, |
|
|
selAllByOrgSidPath, |
|
|
selAllByOrgSidPath, |
|
@ -318,10 +316,10 @@ |
|
|
"deliveryDate": "", |
|
|
"deliveryDate": "", |
|
|
"wareHouseSid": "", |
|
|
"wareHouseSid": "", |
|
|
"wareHouseName": "", |
|
|
"wareHouseName": "", |
|
|
"deptSid": window.sessionStorage.getItem('departmentSid'), |
|
|
"deptSid": window.sessionStorage.getItem('defaultDeptSid'), |
|
|
"deptName": window.sessionStorage.getItem('departmentName'), |
|
|
"deptName": window.sessionStorage.getItem('defaultDeptName'), |
|
|
"useOrgSid": window.sessionStorage.getItem('orgSid'), |
|
|
"useOrgSid": window.sessionStorage.getItem('orgSid'), |
|
|
"createOrgSid": window.sessionStorage.getItem('departmentSid'), |
|
|
"createOrgSid": window.sessionStorage.getItem('defaultDeptSid'), |
|
|
"orgPath": window.sessionStorage.getItem('orgSidPath'), |
|
|
"orgPath": window.sessionStorage.getItem('orgSidPath'), |
|
|
"purchaseBillAmount": { |
|
|
"purchaseBillAmount": { |
|
|
"sid": "", |
|
|
"sid": "", |
|
@ -332,7 +330,7 @@ |
|
|
"freight": "", |
|
|
"freight": "", |
|
|
"freightShareTypeKey": "", |
|
|
"freightShareTypeKey": "", |
|
|
"freightShareTypeValue": "", |
|
|
"freightShareTypeValue": "", |
|
|
"otherAmountName": "", |
|
|
"otherAmount": "", |
|
|
"otherShareTypeKey": "", |
|
|
"otherShareTypeKey": "", |
|
|
"otherShareTypeValue": "", |
|
|
"otherShareTypeValue": "", |
|
|
"settleAccountKey": "", |
|
|
"settleAccountKey": "", |
|
@ -405,19 +403,9 @@ |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
|
|
|
init() { |
|
|
init() { |
|
|
|
|
|
|
|
|
getOrgSidByPath({ |
|
|
|
|
|
orgPath: window.sessionStorage.getItem('defaultOrgPath') |
|
|
|
|
|
}).then((res) => { |
|
|
|
|
|
if (res.success) { |
|
|
|
|
|
this.formobj.createOrgSid = res.data |
|
|
|
|
|
this.formobj.useOrgSid = res.data |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
// 供应商 |
|
|
// 供应商 |
|
|
choiceSupplierInfo({ |
|
|
choiceSupplierInfo({ |
|
|
deptSid: window.sessionStorage.getItem('departmentSid') |
|
|
createOrgSid: window.sessionStorage.getItem('orgSidPath') |
|
|
}).then((resp) => { |
|
|
}).then((resp) => { |
|
|
if (resp.success) { |
|
|
if (resp.success) { |
|
|
this.supplierList = resp.data |
|
|
this.supplierList = resp.data |
|
@ -426,7 +414,7 @@ |
|
|
|
|
|
|
|
|
// 仓库 |
|
|
// 仓库 |
|
|
getWarehouses({ |
|
|
getWarehouses({ |
|
|
orgPath: window.sessionStorage.getItem('defaultOrgPath'), |
|
|
orgPath: window.sessionStorage.getItem('orgSidPath'), |
|
|
}).then((res) => { |
|
|
}).then((res) => { |
|
|
if (res.success) { |
|
|
if (res.success) { |
|
|
this.warehouseList = res.data |
|
|
this.warehouseList = res.data |
|
@ -435,7 +423,7 @@ |
|
|
|
|
|
|
|
|
// 业务员 |
|
|
// 业务员 |
|
|
selAllByOrgSidPath({ |
|
|
selAllByOrgSidPath({ |
|
|
orgSidPath: window.sessionStorage.getItem('defaultOrgPath') |
|
|
orgSidPath: window.sessionStorage.getItem('orgSidPath') |
|
|
}).then((res) => { |
|
|
}).then((res) => { |
|
|
if (res.success) { |
|
|
if (res.success) { |
|
|
this.allOrgperList = res.data |
|
|
this.allOrgperList = res.data |
|
@ -444,7 +432,7 @@ |
|
|
|
|
|
|
|
|
// 货币 |
|
|
// 货币 |
|
|
typeValues({ |
|
|
typeValues({ |
|
|
type: 'wms_busType' |
|
|
type: 'currencyType' |
|
|
}).then((res) => { |
|
|
}).then((res) => { |
|
|
if (res.success) { |
|
|
if (res.success) { |
|
|
this.currencyTypeList = res.data |
|
|
this.currencyTypeList = res.data |
|
@ -453,7 +441,7 @@ |
|
|
|
|
|
|
|
|
// 结算账户 |
|
|
// 结算账户 |
|
|
typeValues({ |
|
|
typeValues({ |
|
|
type: 'wms_busType' |
|
|
type: 'settlementAccount' |
|
|
}).then((res) => { |
|
|
}).then((res) => { |
|
|
if (res.success) { |
|
|
if (res.success) { |
|
|
this.settlementList = res.data |
|
|
this.settlementList = res.data |
|
@ -462,15 +450,13 @@ |
|
|
|
|
|
|
|
|
// 分摊方式 |
|
|
// 分摊方式 |
|
|
typeValues({ |
|
|
typeValues({ |
|
|
type: 'wms_busType' |
|
|
type: 'shareType' |
|
|
}).then((res) => { |
|
|
}).then((res) => { |
|
|
if (res.success) { |
|
|
if (res.success) { |
|
|
this.shareTypeList = res.data |
|
|
this.shareTypeList = res.data |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
// 合计 |
|
|
// 合计 |
|
@ -534,7 +520,7 @@ |
|
|
} |
|
|
} |
|
|
}, 0) |
|
|
}, 0) |
|
|
sums[index] += '' |
|
|
sums[index] += '' |
|
|
} else if (column.property === 'notTaxPprice') { //未含税价 |
|
|
} else if (column.property === 'unTaxPrice') { //未含税价 |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
const value = Number(curr) |
|
|
const value = Number(curr) |
|
|
if (!isNaN(value)) { |
|
|
if (!isNaN(value)) { |
|
@ -546,7 +532,7 @@ |
|
|
} |
|
|
} |
|
|
}, 0) |
|
|
}, 0) |
|
|
sums[index] += '' |
|
|
sums[index] += '' |
|
|
} else if (column.property === 'totalTax') { //总税额 |
|
|
} else if (column.property === 'taxAmount') { //总税额 |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
const value = Number(curr) |
|
|
const value = Number(curr) |
|
|
if (!isNaN(value)) { |
|
|
if (!isNaN(value)) { |
|
@ -558,7 +544,7 @@ |
|
|
} |
|
|
} |
|
|
}, 0) |
|
|
}, 0) |
|
|
sums[index] += '' |
|
|
sums[index] += '' |
|
|
} else if (column.property === 'totalNotTaxPprice') { //未含税总价 |
|
|
} else if (column.property === 'unTaxTotalAmount') { //未含税总价 |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
const value = Number(curr) |
|
|
const value = Number(curr) |
|
|
if (!isNaN(value)) { |
|
|
if (!isNaN(value)) { |
|
@ -579,7 +565,7 @@ |
|
|
calculation(row, updateProp, event) { |
|
|
calculation(row, updateProp, event) { |
|
|
|
|
|
|
|
|
this.formobj.purchaseBillAmount.freight = 0.00 |
|
|
this.formobj.purchaseBillAmount.freight = 0.00 |
|
|
this.formobj.purchaseBillAmount.otherAmountName = 0.00 |
|
|
this.formobj.purchaseBillAmount.otherAmount = 0.00 |
|
|
|
|
|
|
|
|
// 重新计算 |
|
|
// 重新计算 |
|
|
// 除去修改单价时 修改其他字段都先计算出单价 然后其他价格数据在计算一次 |
|
|
// 除去修改单价时 修改其他字段都先计算出单价 然后其他价格数据在计算一次 |
|
@ -647,34 +633,34 @@ |
|
|
// console.log("calculation》》》》", row.amount) |
|
|
// console.log("calculation》》》》", row.amount) |
|
|
|
|
|
|
|
|
// 总税额 = 总价/(1+税率)*税率 |
|
|
// 总税额 = 总价/(1+税率)*税率 |
|
|
row.totalTax = (Number(row.amount) / (1 + Number(row.taxRate) / 100) * Number(row.taxRate) / 100) |
|
|
row.taxAmount = (Number(row.amount) / (1 + Number(row.taxRate) / 100) * Number(row.taxRate) / 100) |
|
|
.toFixed(2) |
|
|
.toFixed(2) |
|
|
// console.log("calculation2》》》》", row.totalTax) |
|
|
// console.log("calculation2》》》》", row.taxAmount) |
|
|
|
|
|
|
|
|
// 未含税价 =(总价-总税额)/数量 |
|
|
// 未含税价 =(总价-总税额)/数量 |
|
|
row.notTaxPprice = ((Number(row.amount) - Number(row.totalTax)) / row.count).toFixed(2) |
|
|
row.unTaxPrice = ((Number(row.amount) - Number(row.taxAmount)) / row.count).toFixed(2) |
|
|
// console.log("calculation2》》》》", row.notTaxPprice) |
|
|
// console.log("calculation2》》》》", row.unTaxPrice) |
|
|
|
|
|
|
|
|
// 未含税总价 = 总价-总税额 |
|
|
// 未含税总价 = 总价-总税额 |
|
|
row.totalNotTaxPprice = (Number(row.amount) - Number(row.totalTax)).toFixed(2) |
|
|
row.unTaxTotalAmount = (Number(row.amount) - Number(row.taxAmount)).toFixed(2) |
|
|
// console.log("calculation2》》》》", row.totalNotTaxPprice) |
|
|
// console.log("calculation2》》》》", row.unTaxTotalAmount) |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
computeDate(row) { |
|
|
computeDate(row) { |
|
|
// 预计到货日期 = 当前日期+采购周期 |
|
|
// 预计到货日期 = 当前日期+采购周期 |
|
|
row.deliveryDate = this.addDate(getCurrentDate(), Number(row.purchaseCycle)) |
|
|
row.deliveryDate = this.addDate(getCurrentDate(), Number(row.cycle)) |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
manufactureDateChange(row) { |
|
|
manufactureDateChange(row) { |
|
|
|
|
|
|
|
|
console.log("manufactureDateChange》》》》", row.manufactureDate) |
|
|
console.log("manufactureDateChange》》》》", row.madeDate) |
|
|
console.log("manufactureDateChange》》》》", row.shelfLife) |
|
|
console.log("manufactureDateChange》》》》", row.shelfLife) |
|
|
row.overdueDate = this.addDate(row.manufactureDate, Number(row.shelfLife)) |
|
|
row.expireDate = this.addDate(row.madeDate, Number(row.shelfLife)) |
|
|
|
|
|
|
|
|
let reg = new RegExp('-', 'g') //g代表全部 |
|
|
let reg = new RegExp('-', 'g') //g代表全部 |
|
|
|
|
|
|
|
|
row.batchNumber = row.manufactureDate.replace(reg, '') + " - " + row.overdueDate.replace(reg, '') |
|
|
row.batchNumber = row.madeDate.replace(reg, '') + " - " + row.expireDate.replace(reg, '') |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
// days 只能是int |
|
|
// days 只能是int |
|
@ -699,7 +685,7 @@ |
|
|
// 分摊金额 = (采购运费+其他费用)*单价*数量/所有商品总价 |
|
|
// 分摊金额 = (采购运费+其他费用)*单价*数量/所有商品总价 |
|
|
|
|
|
|
|
|
var price = Number(this.formobj.purchaseBillAmount.freight) + Number(this.formobj.purchaseBillAmount |
|
|
var price = Number(this.formobj.purchaseBillAmount.freight) + Number(this.formobj.purchaseBillAmount |
|
|
.otherAmountName) |
|
|
.otherAmount) |
|
|
|
|
|
|
|
|
var all = 0 // 除去最后一个的分摊总和 |
|
|
var all = 0 // 除去最后一个的分摊总和 |
|
|
var totalAmount = 0 // 原所有商品总价 |
|
|
var totalAmount = 0 // 原所有商品总价 |
|
@ -709,7 +695,8 @@ |
|
|
totalAmount = (Number(totalAmount) + Number(Number(item.cost1) * Number(item.count1))).toFixed(2) |
|
|
totalAmount = (Number(totalAmount) + Number(Number(item.cost1) * Number(item.count1))).toFixed(2) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
console.log("price》》》》", price) |
|
|
|
|
|
console.log("totalAmount》》》》", totalAmount) |
|
|
// 分摊金额 = (采购运费+其他费用)*单价*数量/ 原所有商品总价 |
|
|
// 分摊金额 = (采购运费+其他费用)*单价*数量/ 原所有商品总价 |
|
|
|
|
|
|
|
|
for (var i = 0; i < this.formobj.purchaseBillDetailList.length; i++) { |
|
|
for (var i = 0; i < this.formobj.purchaseBillDetailList.length; i++) { |
|
@ -778,31 +765,31 @@ |
|
|
this.formobj.purchaseBillDetailList.push({ |
|
|
this.formobj.purchaseBillDetailList.push({ |
|
|
"sid": value[i].sid != null ? value[i].sid : '', |
|
|
"sid": value[i].sid != null ? value[i].sid : '', |
|
|
"goodsSkuCode": value[i].goodsSkuCode != null ? value[i].goodsSkuCode : '', |
|
|
"goodsSkuCode": value[i].goodsSkuCode != null ? value[i].goodsSkuCode : '', |
|
|
"goodsName": value[i].goodsName != null ? value[i].goodsName : '', |
|
|
"goodsSkuTitle": value[i].goodsName != null ? value[i].goodsName : '', |
|
|
"barCode": value[i].barCode != null ? value[i].barCode : '', |
|
|
"goodsSN": value[i].barCode != null ? value[i].barCode : '', |
|
|
"goodsSkuOwnSpec": value[i].goodsSkuOwnSpec != null ? value[i].goodsSkuOwnSpec : '', |
|
|
"goodsSkuOwnSpec": value[i].goodsSkuOwnSpec != null ? value[i].goodsSkuOwnSpec : '', |
|
|
"unit": value[i].unit != null ? value[i].unit : '', |
|
|
"unit": value[i].unit != null ? value[i].unit : '', |
|
|
"count": value[i].count != null ? value[i].count : '0', |
|
|
"count": value[i].count != null ? value[i].count : '0', |
|
|
"count1": value[i].count != null ? value[i].count : '0', |
|
|
"count1": value[i].count != null ? value[i].count1 : '0', |
|
|
"pcsNum": value[i].pcsNum != null ? value[i].pcsNum : '0', |
|
|
"pcsCount": value[i].pcsNum != null ? value[i].pcsNum : '0', |
|
|
"tagPrice": value[i].tagPrice != null ? value[i].tagPrice : '', |
|
|
"tagPrice": value[i].tagPrice != null ? value[i].tagPrice : '', |
|
|
"cost": value[i].cost != null ? value[i].cost : '', |
|
|
"cost": value[i].cost != null ? value[i].cost : '', |
|
|
"cost1": value[i].cost != null ? value[i].cost : '', |
|
|
"cost1": value[i].cost != null ? value[i].cost1 : '', |
|
|
"discountRate": value[i].discountRate != null ? value[i].discountRate : '100', |
|
|
"discountRate": value[i].discountRate != null ? value[i].discountRate : '100', |
|
|
"discountPrice": value[i].discountPrice != null ? value[i].discountPrice : '0.00', |
|
|
"discountPrice": value[i].discountPrice != null ? value[i].discountPrice : '0.00', |
|
|
"shareAmount": value[i].shareAmount != null ? value[i].shareAmount : '0.00', |
|
|
"shareAmount": value[i].shareAmount != null ? value[i].shareAmount : '0.00', |
|
|
"amount": value[i].amount != null ? value[i].amount : '0.00', |
|
|
"amount": value[i].amount != null ? value[i].amount : '0.00', |
|
|
"taxRate": value[i].taxRate != null ? value[i].taxRate : '', |
|
|
"taxRate": value[i].taxRate != null ? value[i].taxRate : '', |
|
|
"notTaxPprice": value[i].notTaxPprice != null ? value[i].notTaxPprice : '', |
|
|
"unTaxPrice": value[i].notTaxPprice != null ? value[i].notTaxPprice : '', |
|
|
"totalTax": value[i].totalTax != null ? value[i].totalTax : '', |
|
|
"taxAmount": value[i].totalTax != null ? value[i].totalTax : '', |
|
|
"totalNotTaxPprice": value[i].totalNotTaxPprice != null ? value[i].totalNotTaxPprice : '', |
|
|
"unTaxTotalAmount": value[i].totalNotTaxPprice != null ? value[i].totalNotTaxPprice : '', |
|
|
"purchaseCycle": value[i].purchaseCycle != null ? value[i].purchaseCycle : '', |
|
|
"cycle": value[i].purchaseCycle != null ? value[i].purchaseCycle : '', |
|
|
"deliveryDate": value[i].deliveryDate != null ? value[i].deliveryDate : '', |
|
|
"deliveryDate": value[i].deliveryDate != null ? value[i].deliveryDate : '', |
|
|
"manufactureDate": value[i].manufactureDate != null ? value[i].manufactureDate : '', |
|
|
"madeDate": value[i].manufactureDate != null ? value[i].manufactureDate : '', |
|
|
"shelfLife": value[i].shelfLife != null ? value[i].shelfLife : '', |
|
|
"shelfLife": value[i].shelfLife != null ? value[i].shelfLife : '', |
|
|
"overdueDate": value[i].overdueDate != null ? value[i].overdueDate : '', |
|
|
"expireDate": value[i].overdueDate != null ? value[i].overdueDate : '', |
|
|
"batchNumber": value[i].batchNumber != null ? value[i].batchNumber : '', |
|
|
"batchNumber": value[i].batchNumber != null ? value[i].batchNumber : '', |
|
|
"itemNumber": value[i].itemNumber != null ? value[i].itemNumber : '', |
|
|
"goodsNum": value[i].itemNumber != null ? value[i].itemNumber : '', |
|
|
"remarks": value[i].remarks != null ? value[i].remarks : '' |
|
|
"remarks": value[i].remarks != null ? value[i].remarks : '' |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -902,10 +889,10 @@ |
|
|
"deliveryDate": "", |
|
|
"deliveryDate": "", |
|
|
"wareHouseSid": "", |
|
|
"wareHouseSid": "", |
|
|
"wareHouseName": "", |
|
|
"wareHouseName": "", |
|
|
"deptSid": window.sessionStorage.getItem('departmentSid'), |
|
|
"deptSid": window.sessionStorage.getItem('defaultDeptSid'), |
|
|
"deptName": window.sessionStorage.getItem('departmentName'), |
|
|
"deptName": window.sessionStorage.getItem('defaultDeptName'), |
|
|
"useOrgSid": window.sessionStorage.getItem('orgSid'), |
|
|
"useOrgSid": window.sessionStorage.getItem('orgSid'), |
|
|
"createOrgSid": window.sessionStorage.getItem('departmentSid'), |
|
|
"createOrgSid": window.sessionStorage.getItem('defaultDeptSid'), |
|
|
"orgPath": window.sessionStorage.getItem('orgSidPath'), |
|
|
"orgPath": window.sessionStorage.getItem('orgSidPath'), |
|
|
"purchaseBillAmount": { |
|
|
"purchaseBillAmount": { |
|
|
"sid": "", |
|
|
"sid": "", |
|
@ -916,7 +903,7 @@ |
|
|
"freight": "", |
|
|
"freight": "", |
|
|
"freightShareTypeKey": "", |
|
|
"freightShareTypeKey": "", |
|
|
"freightShareTypeValue": "", |
|
|
"freightShareTypeValue": "", |
|
|
"otherAmountName": "", |
|
|
"otherAmount": "", |
|
|
"otherShareTypeKey": "", |
|
|
"otherShareTypeKey": "", |
|
|
"otherShareTypeValue": "", |
|
|
"otherShareTypeValue": "", |
|
|
"settleAccountKey": "", |
|
|
"settleAccountKey": "", |
|
@ -1020,16 +1007,29 @@ |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
selectCurrency(val) { |
|
|
selectCurrency(val) { |
|
|
|
|
|
const choose = this.currencyTypeList.filter((item) => item.dictKey == val) |
|
|
|
|
|
console.log('>>>>>>>>>selectCurrency', choose) |
|
|
|
|
|
this.formobj.purchaseBillAmount.currencyValue = choose[0].dictValue |
|
|
|
|
|
this.formobj.purchaseBillAmount.currencyKey = choose[0].dictKey |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
selectFreightShareType(val) { |
|
|
selectFreightShareType(val) { |
|
|
|
|
|
const choose = this.shareTypeList.filter((item) => item.dictKey == val) |
|
|
|
|
|
console.log('>>>>>>>>>selectFreightShareType', choose) |
|
|
|
|
|
this.formobj.purchaseBillAmount.freightShareTypeValue = choose[0].dictValue |
|
|
|
|
|
this.formobj.purchaseBillAmount.freightShareTypeKey = choose[0].dictKey |
|
|
}, |
|
|
}, |
|
|
selectSettleAccount(val) { |
|
|
selectSettleAccount(val) { |
|
|
|
|
|
const choose = this.settlementList.filter((item) => item.dictKey == val) |
|
|
|
|
|
console.log('>>>>>>>>>selectSettleAccount', choose) |
|
|
|
|
|
this.formobj.purchaseBillAmount.settleAccountValue = choose[0].dictValue |
|
|
|
|
|
this.formobj.purchaseBillAmount.settleAccountKey = choose[0].dictKey |
|
|
}, |
|
|
}, |
|
|
selectOtherShareType(val) { |
|
|
selectOtherShareType(val) { |
|
|
|
|
|
const choose = this.shareTypeList.filter((item) => item.dictKey == val) |
|
|
|
|
|
console.log('>>>>>>>>>selectOtherShareType', choose) |
|
|
|
|
|
this.formobj.purchaseBillAmount.otherShareTypeValue = choose[0].dictValue |
|
|
|
|
|
this.formobj.purchaseBillAmount.otherShareTypeKey = choose[0].dictKey |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|