shish 11 hónapja
szülő
commit
4af14e1d9b

+ 9 - 2
hdApp/src/admin/billing/affirm.vue

@@ -93,7 +93,8 @@
                 <text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 1">支</text>
                 <!-- #endif -->
 
-                <image @click="switchGlobalUnitType" :src="`${constant.imgUrl}/icon/switch/switch128.png`" 
+                <!-- 只有花材 property == 1 才给显示切换功能 -->
+                <image @click="switchGlobalUnitType" :src="`${constant.imgUrl}/icon/switch/switch128.png`" v-if="customData.property == 1"
                 style="width:86upx;height:86upx;position:relative;top:-60upx;right:0upx;" mode="widthFix"></image>
 
               </view>
@@ -700,7 +701,13 @@ export default {
       let reduceStock = this.option.reduceStock?this.option.reduceStock:0
       let orderId = this.option.orderId  ? this.option.orderId : 0
       let book = this.option.book ? this.option.book : 0
-      this.$util.pageTo({url: '/admin/billing/index2?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
+      let fromType = this.option.fromType ? this.option.fromType : 'item'
+      if(fromType == 'item'){
+        this.$util.pageTo({url: '/admin/billing/index2?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
+      }else{
+        this.$util.pageTo({url: '/admin/billing/hs?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
+      }
+      
     }
   }
 };

+ 12 - 7
hdApp/src/admin/billing/hs.vue

@@ -9,6 +9,7 @@
 				<app-search-module ref="globalSearchRef" v-model="globalPy" placeholder="这里搜索" @input="globalSearch" />
 			</view>
 			<view style="float:right;margin-left:15upx;">
+				<button class="admin-button-com middle blue" @click="goItem()" style="margin-right:10upx;">花材</button>
 				<button class="admin-button-com middle blue" @click="removeFromSave(option.customId)">清空购物车</button>
 			</view>
 		</view>
@@ -73,22 +74,18 @@
 
 						<!-- #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>
+						<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 0"></text>
 						<input style="width: 280upx" v-model="customData.smallCount" v-if="globalUnitType == 1" type="number" />
 						<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 1">{{customData.smallUnit}}</text>
 						<!-- #endif -->
 
 						<!-- #ifdef MP-WEIXIN -->
 						<input style="width: 280upx" v-model="customData.bigCount" v-if="globalUnitType == 0" :focus="isAddInputFocus" type="number" />
-						<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 0">{{customData.bigUnit}}</text>
+						<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 0"></text>
 						<input style="width: 280upx" v-model="customData.smallCount" v-if="globalUnitType == 1" :focus="isAddInputFocus" type="number" />
 						<text style="font-size:35upx;font-weight:bold;color:#666666;" v-if="globalUnitType == 1">{{customData.smallUnit}}</text>
 						<!-- #endif -->
 
-						<image @click="switchGlobalUnitType" :src="`${constant.imgUrl}/icon/switch/switch128.png`" 
-						style="width:86upx;height:86upx;position:absolute;top:300upx;right:40upx;" mode="widthFix"></image>
-
-						<button class="admin-button-com mini-btn" @click="customData.userPrice=0.01;customData.bigCount=1" style="position:absolute;top:200upx;right:33upx;">赠送</button>
 					</view>
 					<view class="num_bx">
 						<input style="width: 280upx;height:40upx;font-size:25upx;" v-model="customData.remark" type="text" placeholder="备注" />
@@ -191,7 +188,15 @@ export default {
 			let book = this.option.book ? this.option.book : 0
 			let customId = this.option.customId?this.option.customId:0
 			let reduceStock = this.option.reduceStock?this.option.reduceStock:0
-			this.$util.pageTo({ url: '/admin/billing/affirm?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
+			this.$util.pageTo({ url: '/admin/billing/affirm?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock+'&fromType=hs',type:2})
+		},
+		goItem(){
+			let customName = this.option.customName ? this.option.customName : '';
+			let orderId = this.option.orderId  ? this.option.orderId : 0
+			let book = this.option.book ? this.option.book : 0
+			let customId = this.option.customId?this.option.customId:0
+			let reduceStock = this.option.reduceStock?this.option.reduceStock:0
+			this.$util.pageTo({url:'/admin/billing/index2?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
 		}
 	}
 };

+ 10 - 1
hdApp/src/admin/billing/index2.vue

@@ -9,6 +9,7 @@
 				<app-search-module ref="globalSearchRef" v-model="globalPy" placeholder="这里搜索" @input="globalSearch" />
 			</view>
 			<view style="float:right;margin-left:15upx;">
+				<button class="admin-button-com middle blue" @click="goHs()" style="margin-right:10upx;">花束</button>
 				<button class="admin-button-com middle blue" @click="removeFromSave(option.customId)">清空购物车</button>
 			</view>
 		</view>
@@ -233,7 +234,15 @@ export default {
 			let book = this.option.book ? this.option.book : 0
 			let customId = this.option.customId?this.option.customId:0
 			let reduceStock = this.option.reduceStock?this.option.reduceStock:0
-			this.$util.pageTo({ url: '/admin/billing/affirm?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock,type:2})
+			this.$util.pageTo({ url: '/admin/billing/affirm?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock+'&fromType=item',type:2})
+		},
+		goHs(){
+			let customName = this.option.customName ? this.option.customName : '';
+			let orderId = this.option.orderId  ? this.option.orderId : 0
+			let book = this.option.book ? this.option.book : 0
+			let customId = this.option.customId?this.option.customId:0
+			let reduceStock = this.option.reduceStock?this.option.reduceStock:0
+			this.$util.pageTo({url:'/admin/billing/hs?customId='+customId+'&customName='+customName+'&orderId='+orderId+'&book='+book+'&reduceStock='+reduceStock+'&fromType=hs',type:2})
 		}
 	}
 };