|
|
@@ -61,16 +61,18 @@
|
|
|
<template slot="customContent">
|
|
|
<view class="select-cmd_bx" v-if="customData">
|
|
|
<view class="kc">
|
|
|
- <text class="unit_price">库存 {{ parseFloat(customData.stock) }}</text>
|
|
|
- <text class="unit_price"> ¥{{ parseFloat(customData.price) }}</text>
|
|
|
- <text>{{customData.ratio}}{{customData.smallUnit}}/{{customData.bigUnit}}</text>
|
|
|
+ <text>库存 {{ customData.stock?parseFloat(customData.stock):0 }}</text>
|
|
|
+ <text style="margin-left:14upx;">¥{{ parseFloat(customData.price) }}</text>
|
|
|
+ <text style="margin-left:14upx;">{{customData.ratio}}{{customData.smallUnit}}/{{customData.bigUnit}}</text>
|
|
|
+ <text style="margin-left:14upx;">成本 {{customData.cost?parseFloat(customData.cost):0}}</text>
|
|
|
</view>
|
|
|
<view class="num_bx">
|
|
|
- <input style="width: 280upx" v-model="customData.userPrice" @focus="customData.userPrice = null"
|
|
|
+ <input style="width:280upx" v-model="customData.userPrice" @focus="customData.userPrice = null" :class="[Number(customData.cost) > Number(customData.userPrice) ? 'warning-price' : '']"
|
|
|
:disabled="false" type="digit" placeholder="单价" />
|
|
|
<text style="font-size:35upx;font-weight:bold;color:#666666;">元</text>
|
|
|
</view>
|
|
|
<view class="num_bx">
|
|
|
+
|
|
|
<!-- #ifdef APP-PLUS -->
|
|
|
<input style="width: 280upx" v-model="customData.bigCount" v-if="globalUnitType == 0" type="number" />
|
|
|
<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 0">{{customData.bigUnit}}</text>
|
|
|
@@ -352,4 +354,8 @@ export default {
|
|
|
.class-popup-style{
|
|
|
z-index:999999;
|
|
|
}
|
|
|
+.warning-price{
|
|
|
+ color:red;
|
|
|
+ font-weight:bold;
|
|
|
+}
|
|
|
</style>
|