|
@@ -95,7 +95,7 @@
|
|
|
<span v-if="$hasPermissions('B_salesDispatch_salesPrice')">已取消金额:<strong>{{ detailData&&(detailData.totalCancelAmount || detailData.totalCancelAmount==0) ? toThousands(detailData.totalCancelAmount) : '--' }}</strong>;</span>
|
|
|
<span v-if="$hasPermissions('B_salesDispatch_salesPrice')">已下推金额:<strong>{{ detailData&&(detailData.totalPushedAmount || detailData.totalPushedAmount==0) ? toThousands(detailData.totalPushedAmount) :'--' }}</strong>;</span>
|
|
|
<span v-if="$hasPermissions('B_salesDispatch_salesPrice')">待下推金额:<strong>{{ detailData&&(detailData.totalUnpushedAmount || detailData.totalUnpushedAmount==0) ? toThousands(detailData.totalUnpushedAmount) : '--' }}</strong>;</span>
|
|
|
- <span v-if="$hasPermissions('B_salesDispatch_salesPrice')&&detailData&&detailData.totalConvertPromoGiftsAmount">促销产品转采购额金额:<strong>{{ toThousands(detailData.totalConvertPromoGiftsAmount) }}</strong>;</span>
|
|
|
+ <span v-if="$hasPermissions('B_salesDispatch_salesPrice')&&detailData&&detailData.totalConvertPromoGiftsAmount" style="color:red;">促销产品转采购额金额:<strong>{{ toThousands(detailData.totalConvertPromoGiftsAmount) }}</strong>;</span>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -263,7 +263,7 @@ export default {
|
|
|
<div>
|
|
|
<span style="padding-right: 15px;">{data}</span>
|
|
|
{ftext?(<a-badge count={ftext} number-style={{ backgroundColor: fcolor, zoom:'80%' }}></a-badge>):''}
|
|
|
- {record.convertPromoGiftsQty?(<a-badge count="转" number-style={{ backgroundColor: '#ffaa00', zoom:'80%' }}></a-badge>):''}
|
|
|
+ {record.bakConvertPromoGiftsQty?(<a-badge count="转" number-style={{ backgroundColor: '#ffaa00', zoom:'80%' }}></a-badge>):''}
|
|
|
{Number(record.stockQty||0) < Number(record.unpushedQty||0)?(<a-badge count="缺" number-style={{ zoom:'80%' }}></a-badge>):''}
|
|
|
</div>
|
|
|
)
|
|
@@ -289,7 +289,7 @@ export default {
|
|
|
}
|
|
|
// 转采购额数量输入框
|
|
|
const inputFormat1 = function(record,data,h) {
|
|
|
- if(record.unpushedQty>=0){
|
|
|
+ if(record.unpushedQty>=0 && record.convertPromoGiftsFlag){
|
|
|
// 已选
|
|
|
if(_this.selectedRowKeys.includes(record.id)){
|
|
|
return (
|
|
@@ -329,6 +329,7 @@ export default {
|
|
|
}
|
|
|
// 编号,并且格式化活动分类行
|
|
|
const noFormat = function(record,data,h){
|
|
|
+ const isBuyPSendP = record.promo && record.promo.promotionRule.convertExpenseFlag==1&&record.promo.promotionRule.promotionRuleType=='BUY_PROD_GIVE_PROD'
|
|
|
return (
|
|
|
<div>
|
|
|
{record.id.indexOf('promo-')>=0 ? (
|
|
@@ -347,9 +348,9 @@ export default {
|
|
|
数量:<strong>{record.total&&record.total.totalQty||'--'}</strong>;
|
|
|
{_this.$hasPermissions('B_salesEdit_salesPrice') ? (<span>总金额:<strong>{record.total&&record.total.totalAmount||'--'}</strong>;</span>):('')}
|
|
|
{_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.lossAmount ? (<span>优惠金额:<strong>{record.total.lossAmount}</strong>;</span>):('')}
|
|
|
- {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.cgejyAmount>0 ? (<span>采购额结余:<strong>{_this.toThousands(record.total.cgejyAmount)}</strong>;</span>):('')}
|
|
|
- {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.cgejyAmount<0 ? (<span>采购额超出:<strong>{_this.toThousands(record.total.cgeccAmount)}</strong>;</span>):('')}
|
|
|
- {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.totalPromoGiftsAmount ? (<span>促销产品转采购额金额:<strong>{record.total&&record.total.totalPromoGiftsAmount||'--'}</strong>;</span>):('')}
|
|
|
+ {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.cgejyAmount>0&&!isBuyPSendP ? (<span>采购额结余:<strong>{_this.toThousands(record.total.cgejyAmount)}</strong>;</span>):('')}
|
|
|
+ {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.cgejyAmount<0&&!isBuyPSendP ? (<span>采购额超出:<strong>{_this.toThousands(record.total.cgeccAmount)}</strong>;</span>):('')}
|
|
|
+ {_this.$hasPermissions('B_salesEdit_salesPrice')&&record.promo&&record.total&&record.total.totalPromoGiftsAmount&&isBuyPSendP ? (<span>促销产品转采购额金额:<strong>{record.total&&record.total.totalPromoGiftsAmount||'--'}</strong>;</span>):('')}
|
|
|
{record.expenseAccountFlag!='WAIT' ? record.expenseAccountFlagDictValue : ''}
|
|
|
</div>
|
|
|
</div>
|
|
@@ -541,8 +542,10 @@ export default {
|
|
|
item.maxConvertNums = 0
|
|
|
}
|
|
|
|
|
|
+ item.bakConvertPromoGiftsQty = item.convertPromoGiftsQty
|
|
|
+
|
|
|
// 库存为0或待下推数为0,不可添加
|
|
|
- if(!item.unpushedQty || item.unpushedQty<0 || isTjRow){
|
|
|
+ if(!item.convertPromoGiftsQty && (!item.unpushedQty || item.unpushedQty<0) || isTjRow){
|
|
|
this.disableSelectedRowKeys.push(item.id)
|
|
|
}
|
|
|
})
|