1
This commit is contained in:
@@ -424,6 +424,7 @@
|
||||
controls-position="right"
|
||||
class="mobile-pricing-input"
|
||||
@change="onOrderPaymentOrRebateChange(row)"
|
||||
@blur="onOrderPaymentOrRebateChange(row)"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -439,6 +440,7 @@
|
||||
controls-position="right"
|
||||
class="mobile-pricing-input"
|
||||
@change="onOrderPaymentOrRebateChange(row)"
|
||||
@blur="onOrderPaymentOrRebateChange(row)"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -454,6 +456,7 @@
|
||||
controls-position="right"
|
||||
class="mobile-pricing-input"
|
||||
@change="onOrderExtraCostChange(row)"
|
||||
@blur="onOrderExtraCostChange(row)"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -470,7 +473,7 @@
|
||||
<span class="field-label">售价</span>
|
||||
<span class="field-value field-value--pricing-control">
|
||||
<div class="mobile-pricing-num-wrap">
|
||||
<el-input-number v-model="row.sellingPrice" :min="0" :step="1" :precision="2" size="small" controls-position="right" class="mobile-pricing-input" @change="onOrderSellingPriceChange(row)" />
|
||||
<el-input-number v-model="row.sellingPrice" :min="0" :step="1" :precision="2" size="small" controls-position="right" class="mobile-pricing-input" @change="onOrderSellingPriceChange(row)" @blur="onOrderSellingPriceChange(row)" />
|
||||
<el-tag v-if="row.sellingPriceManual === 1" type="info" size="mini" class="mobile-pricing-tag">手填</el-tag>
|
||||
</div>
|
||||
</span>
|
||||
@@ -479,7 +482,7 @@
|
||||
<span class="field-label">利润</span>
|
||||
<span class="field-value field-value--pricing-control">
|
||||
<div class="mobile-pricing-num-wrap">
|
||||
<el-input-number v-model="row.profit" :step="0.01" :precision="2" size="small" controls-position="right" class="mobile-pricing-input" @change="onOrderProfitChange(row)" />
|
||||
<el-input-number v-model="row.profit" :step="0.01" :precision="2" size="small" controls-position="right" class="mobile-pricing-input" @change="onOrderProfitChange(row)" @blur="onOrderProfitChange(row)" />
|
||||
<el-tag v-if="row.profitManual === 1" type="warning" size="mini" class="mobile-pricing-tag">手填</el-tag>
|
||||
</div>
|
||||
</span>
|
||||
@@ -668,6 +671,7 @@
|
||||
controls-position="right"
|
||||
class="jd-order-input-money jd-order-input-money--payment"
|
||||
@change="onOrderPaymentOrRebateChange(scope.row)"
|
||||
@blur="onOrderPaymentOrRebateChange(scope.row)"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
@@ -684,6 +688,7 @@
|
||||
controls-position="right"
|
||||
class="jd-order-input-money jd-order-input-money--rebate"
|
||||
@change="onOrderPaymentOrRebateChange(scope.row)"
|
||||
@blur="onOrderPaymentOrRebateChange(scope.row)"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
@@ -701,21 +706,21 @@
|
||||
<el-table-column label="售价" prop="sellingPrice" min-width="150" align="right" class-name="jd-col-money jd-col-money--selling">
|
||||
<template slot-scope="scope">
|
||||
<div class="jd-cell-stretch jd-cell-stretch--num">
|
||||
<el-input-number v-model="scope.row.sellingPrice" :min="0" :step="1" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--selling" @change="onOrderSellingPriceChange(scope.row)" />
|
||||
<el-input-number v-model="scope.row.sellingPrice" :min="0" :step="1" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--selling" @change="onOrderSellingPriceChange(scope.row)" @blur="onOrderSellingPriceChange(scope.row)" />
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="额外成本" prop="extraCost" min-width="112" align="right" class-name="jd-col-money jd-col-money--extra-cost">
|
||||
<template slot-scope="scope">
|
||||
<div class="jd-cell-stretch jd-cell-stretch--num">
|
||||
<el-input-number v-model="scope.row.extraCost" :min="0" :step="1" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--rebate" @change="onOrderExtraCostChange(scope.row)" />
|
||||
<el-input-number v-model="scope.row.extraCost" :min="0" :step="1" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--rebate" @change="onOrderExtraCostChange(scope.row)" @blur="onOrderExtraCostChange(scope.row)" />
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="利润" prop="profit" min-width="118" align="right" class-name="jd-col-money jd-col-money--profit">
|
||||
<template slot-scope="scope">
|
||||
<div class="jd-cell-stretch jd-cell-stretch--num">
|
||||
<el-input-number v-model="scope.row.profit" :step="0.01" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--profit" @change="onOrderProfitChange(scope.row)" />
|
||||
<el-input-number v-model="scope.row.profit" :step="0.01" :precision="2" size="mini" controls-position="right" class="jd-order-input-money jd-order-input-money--profit" @change="onOrderProfitChange(scope.row)" @blur="onOrderProfitChange(scope.row)" />
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
@@ -2027,6 +2032,10 @@ export default {
|
||||
.catch(() => {})
|
||||
},
|
||||
persistOrderRow(row, successMsg) {
|
||||
if (!row || row.id == null) {
|
||||
return Promise.resolve()
|
||||
}
|
||||
this.ensureMoneyFieldsForPersist(row)
|
||||
return updateJDOrder(row)
|
||||
.then(() => {
|
||||
if (successMsg) this.$message.success(successMsg)
|
||||
@@ -2037,7 +2046,13 @@ export default {
|
||||
this.getList()
|
||||
})
|
||||
},
|
||||
/** 第三方单号为空时粘贴补录:去空白后写入 */
|
||||
/** 上传前兜底:避免出现 undefined/null 不入 JSON,后端跳过更新列 */
|
||||
ensureMoneyFieldsForPersist(row) {
|
||||
if (!row) return
|
||||
if (row.extraCost == null || row.extraCost === '') {
|
||||
row.extraCost = 0
|
||||
}
|
||||
},
|
||||
saveThirdPartyOrderNoIfFilled(row, successMsg) {
|
||||
const v = row.thirdPartyOrderNo == null ? '' : String(row.thirdPartyOrderNo).trim().replace(/\s+/g, '')
|
||||
if (!v) {
|
||||
|
||||
Reference in New Issue
Block a user