|
@@ -67,6 +67,12 @@
|
|
|
dataType="string" multipleStrings @selectChange="dicChange('airlineCname', $event)"
|
|
dataType="string" multipleStrings @selectChange="dicChange('airlineCname', $event)"
|
|
|
:disabled="editDisabled"></dic-select>
|
|
:disabled="editDisabled"></dic-select>
|
|
|
</tempalte>
|
|
</tempalte>
|
|
|
|
|
+ <tempalte slot="classes">
|
|
|
|
|
+ <dic-select v-model="form.classes" placeholder="二次航线" key="id" label="cnName"
|
|
|
|
|
+ url="/blade-los/blines/listAll" :filterable="true" :multiple="true" :collapseTags="true"
|
|
|
|
|
+ dataType="string" multipleStrings @selectChange="dicChange('classes', $event)"
|
|
|
|
|
+ :disabled="editDisabled"></dic-select>
|
|
|
|
|
+ </tempalte>
|
|
|
<tempalte slot="shippingCompanyCname">
|
|
<tempalte slot="shippingCompanyCname">
|
|
|
<dic-select v-model="form.shippingCompanyCname" placeholder="承运人" key="id" label="shortName"
|
|
<dic-select v-model="form.shippingCompanyCname" placeholder="承运人" key="id" label="shortName"
|
|
|
res="records" url="/blade-los/bcorps/selectList?current=1&size=5&corpTypeName=船公司"
|
|
res="records" url="/blade-los/bcorps/selectList?current=1&size=5&corpTypeName=船公司"
|
|
@@ -227,6 +233,12 @@
|
|
|
style="width: 100%;"></el-input-number>
|
|
style="width: 100%;"></el-input-number>
|
|
|
<span v-else>{{ row.oceanFreight }}</span>
|
|
<span v-else>{{ row.oceanFreight }}</span>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
+ <template slot="additionalFeeForm" slot-scope="{ row }">
|
|
|
|
|
+ <el-input-number v-if="row.$cellEdit" v-model="row.additionalFee"
|
|
|
|
|
+ @change="countChange(row)" :controls="false" placeholder="请输入 附加费" size="small"
|
|
|
|
|
+ style="width: 100%;"></el-input-number>
|
|
|
|
|
+ <span v-else>{{ row.additionalFee }}</span>
|
|
|
|
|
+ </template>
|
|
|
<!-- <template slot="menu" slot-scope="{ row, index }">
|
|
<!-- <template slot="menu" slot-scope="{ row, index }">
|
|
|
<el-button size="small" icon="el-icon-delete" type="text" :disabled="editDisabled"
|
|
<el-button size="small" icon="el-icon-delete" type="text" :disabled="editDisabled"
|
|
|
@click="rowDel(row, index)">删 除</el-button>
|
|
@click="rowDel(row, index)">删 除</el-button>
|
|
@@ -833,6 +845,7 @@ export default {
|
|
|
prop: "airlineCname",
|
|
prop: "airlineCname",
|
|
|
disabled: false,
|
|
disabled: false,
|
|
|
},
|
|
},
|
|
|
|
|
+
|
|
|
{
|
|
{
|
|
|
label: '承运人',
|
|
label: '承运人',
|
|
|
prop: "shippingCompanyCname",
|
|
prop: "shippingCompanyCname",
|
|
@@ -926,8 +939,8 @@ export default {
|
|
|
disabled: false,
|
|
disabled: false,
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- label: '班次',
|
|
|
|
|
- prop: "classes",
|
|
|
|
|
|
|
+ label: '合作伙伴',
|
|
|
|
|
+ prop: "cooperativePartnerName",
|
|
|
disabled: false,
|
|
disabled: false,
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
@@ -984,8 +997,8 @@ export default {
|
|
|
}]
|
|
}]
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- label: '合作伙伴',
|
|
|
|
|
- prop: "cooperativePartnerName",
|
|
|
|
|
|
|
+ label: '二程航线',
|
|
|
|
|
+ prop: "classes",
|
|
|
disabled: false,
|
|
disabled: false,
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
@@ -1197,6 +1210,15 @@ export default {
|
|
|
formslot: true,
|
|
formslot: true,
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
|
|
+ label: "附加费",
|
|
|
|
|
+ prop: "additionalFee",
|
|
|
|
|
+ width: "80",
|
|
|
|
|
+ overHidden: true,
|
|
|
|
|
+ cell: true,
|
|
|
|
|
+ slot: true,
|
|
|
|
|
+ formslot: true,
|
|
|
|
|
+ },
|
|
|
|
|
+ {
|
|
|
label: "箱成本/天",
|
|
label: "箱成本/天",
|
|
|
prop: "boxCost",
|
|
prop: "boxCost",
|
|
|
width: "90",
|
|
width: "90",
|
|
@@ -1907,8 +1929,8 @@ export default {
|
|
|
})
|
|
})
|
|
|
// 用箱成本=(航线天数+在场站天数) *箱成本/天/汇率
|
|
// 用箱成本=(航线天数+在场站天数) *箱成本/天/汇率
|
|
|
item.useBoxCost = _.round(_.multiply(_.add(Number(this.form.navigateDay ? this.form.navigateDay : 0), Number(this.form.existStationDay ? this.form.existStationDay : 0)), item.boxCost ? item.boxCost : 0), 2)
|
|
item.useBoxCost = _.round(_.multiply(_.add(Number(this.form.navigateDay ? this.form.navigateDay : 0), Number(this.form.existStationDay ? this.form.existStationDay : 0)), item.boxCost ? item.boxCost : 0), 2)
|
|
|
- // 成本价=海运费+用箱成本+pol杂费+pod成本
|
|
|
|
|
- item.costPrice = _.round(_.add(_.add(Number(item.oceanFreight ? item.oceanFreight : 0), Number(item.useBoxCost ? item.useBoxCost : 0)), _.add(Number(item.polCost ? item.polCost : 0), Number(item.podCost ? item.podCost : 0))), 2)
|
|
|
|
|
|
|
+ // 成本价=海运费+附加费+用箱成本+pol杂费+pod成本
|
|
|
|
|
+ item.costPrice = _.round(_.add(_.add(_.add(Number(item.oceanFreight ? item.oceanFreight : 0), Number(item.additionalFee ? item.additionalFee : 0)), Number(item.useBoxCost ? item.useBoxCost : 0)), _.add(Number(item.polCost ? item.polCost : 0), Number(item.podCost ? item.podCost : 0))), 2)
|
|
|
// 一程利润=销售价+pol收入+pod收入-成本价
|
|
// 一程利润=销售价+pol收入+pod收入-成本价
|
|
|
item.totalProfit = _.round(_.subtract(_.add(Number(item.salesPrice ? item.salesPrice : 0), _.add(Number(item.polIncome ? item.polIncome : 0), Number(item.podIncome ? item.podIncome : 0))), item.costPrice ? item.costPrice : 0), 2)
|
|
item.totalProfit = _.round(_.subtract(_.add(Number(item.salesPrice ? item.salesPrice : 0), _.add(Number(item.polIncome ? item.polIncome : 0), Number(item.podIncome ? item.podIncome : 0))), item.costPrice ? item.costPrice : 0), 2)
|
|
|
// 成本价=海运费+pol杂费+pod成本
|
|
// 成本价=海运费+pol杂费+pod成本
|
|
@@ -1947,8 +1969,8 @@ export default {
|
|
|
})
|
|
})
|
|
|
// 用箱成本=(航线天数+在场站天数) *箱成本/天/汇率
|
|
// 用箱成本=(航线天数+在场站天数) *箱成本/天/汇率
|
|
|
item.useBoxCost = _.round(_.multiply(_.add(Number(this.form.navigateDay ? this.form.navigateDay : 0), Number(this.form.existStationDay ? this.form.existStationDay : 0)), item.boxCost ? item.boxCost : 0), 2)
|
|
item.useBoxCost = _.round(_.multiply(_.add(Number(this.form.navigateDay ? this.form.navigateDay : 0), Number(this.form.existStationDay ? this.form.existStationDay : 0)), item.boxCost ? item.boxCost : 0), 2)
|
|
|
- // 成本价=海运费+用箱成本+pol杂费+pod成本
|
|
|
|
|
- item.costPrice = _.round(_.add(_.add(Number(item.oceanFreight ? item.oceanFreight : 0), Number(item.useBoxCost ? item.useBoxCost : 0)), _.add(Number(item.polCost ? item.polCost : 0), Number(item.podCost ? item.podCost : 0))), 2)
|
|
|
|
|
|
|
+ // 成本价=海运费+附加费+用箱成本+pol杂费+pod成本
|
|
|
|
|
+ item.costPrice = _.round(_.add(_.add(_.add(Number(item.oceanFreight ? item.oceanFreight : 0), Number(item.additionalFee ? item.additionalFee : 0)), Number(item.useBoxCost ? item.useBoxCost : 0)), _.add(Number(item.polCost ? item.polCost : 0), Number(item.podCost ? item.podCost : 0))), 2)
|
|
|
// 一程利润=销售价+pol收入+pod收入-成本价
|
|
// 一程利润=销售价+pol收入+pod收入-成本价
|
|
|
item.totalProfit = _.round(_.subtract(_.add(Number(item.salesPrice ? item.salesPrice : 0), _.add(Number(item.polIncome ? item.polIncome : 0), Number(item.podIncome ? item.podIncome : 0))), item.costPrice ? item.costPrice : 0), 2)
|
|
item.totalProfit = _.round(_.subtract(_.add(Number(item.salesPrice ? item.salesPrice : 0), _.add(Number(item.polIncome ? item.polIncome : 0), Number(item.podIncome ? item.podIncome : 0))), item.costPrice ? item.costPrice : 0), 2)
|
|
|
//全程利润=一程利润+二程利润
|
|
//全程利润=一程利润+二程利润
|
|
@@ -2106,6 +2128,25 @@ export default {
|
|
|
this.form.shipCnameTwo = null
|
|
this.form.shipCnameTwo = null
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
+ if (name == 'classes') {
|
|
|
|
|
+ const codes = []
|
|
|
|
|
+ const enNames = []
|
|
|
|
|
+ for (let item of row.multipleData) {
|
|
|
|
|
+ codes.push(item.code)
|
|
|
|
|
+ enNames.push(item.enName)
|
|
|
|
|
+ }
|
|
|
|
|
+ if (row) {
|
|
|
|
|
+ this.form.classesId = row.ids
|
|
|
|
|
+ this.form.classes = row.names
|
|
|
|
|
+ this.form.classesCode = codes.join(',')
|
|
|
|
|
+ this.form.classesEname = enNames.join(',')
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.form.classesId = null
|
|
|
|
|
+ this.form.classesCode = null
|
|
|
|
|
+ this.form.classesEname = null
|
|
|
|
|
+ this.form.classes = null
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
if (name == 'cabinType') {
|
|
if (name == 'cabinType') {
|
|
|
if (row) {
|
|
if (row) {
|
|
|
if (row.dictValue == '固定') {
|
|
if (row.dictValue == '固定') {
|
|
@@ -2240,7 +2281,12 @@ export default {
|
|
|
await this.checkRate(null, row, null, 1, this.form.belongingCompanyId)
|
|
await this.checkRate(null, row, null, 1, this.form.belongingCompanyId)
|
|
|
this.exrateDateCount()
|
|
this.exrateDateCount()
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+ if (name == 'navigateDay') {
|
|
|
|
|
+ this.exrateDateCount()
|
|
|
|
|
+ }
|
|
|
|
|
+ if (name == 'existStationDay') {
|
|
|
|
|
+ this.exrateDateCount()
|
|
|
|
|
+ }
|
|
|
},
|
|
},
|
|
|
rowDicChange(name, row, el) {
|
|
rowDicChange(name, row, el) {
|
|
|
if (name == 'curCode') {
|
|
if (name == 'curCode') {
|