hmp hace 4 años
padre
commit
928c04c999

+ 11 - 8
assets/colorui/app.scss

@@ -224,16 +224,19 @@
 }
 }
 
 
 /* ==========text-cut=========== */
 /* ==========text-cut=========== */
+/* start--去除button的所有默认样式--start */
 .btnCss {
 .btnCss {
-		border: none;
-		border-radius: 0rpx;
-		outline: none;
-	}
+	padding: 0;
+	font-size: inherit;
+	line-height: inherit;
+	background-color: transparent;
+	color: inherit;
+}
 
 
-	.btnCss::after {
-		border: none;
-		outline: none;
-	}
+.btnCss {
+   border: none;
+}
+/* end--去除button的所有默认样式--end */
 
 
 
 
 .text-cut-1 {
 .text-cut-1 {

+ 12 - 0
assets/http/config.js

@@ -0,0 +1,12 @@
+let config = {}
+
+config.baseURL='https://ldt.guosen-fumao.cn/api/'
+config.webSocketUrl='wss://ldt.guosen-fumao.cn/websocket/'
+
+// config.baseURL='http://localhost:2366/'
+// config.webSocketUrl='ws://localhost:2366/websocket/'
+
+
+export default config
+
+

+ 2 - 2
assets/http/service.js

@@ -1,7 +1,7 @@
 import Request from 'luch-request'
 import Request from 'luch-request'
+import config from './config.js'
 
 
-// let baseURL = 'https://ldt.guosen-fumao.cn/api/'
-let baseURL = 'http://192.168.1.168:2366/'
+let baseURL = config.baseURL
 
 
 let refreshTokenUrl = baseURL + "blade-auth/oauth/token"
 let refreshTokenUrl = baseURL + "blade-auth/oauth/token"
 
 

+ 19 - 1
pages.json

@@ -351,7 +351,25 @@
 					"navigationBarTitleText": "商品属性"
 					"navigationBarTitleText": "商品属性"
 				}
 				}
 			}
 			}
-		]
+		    ,{
+                    "path" : "pages/order/order",
+                    "style" :                                                                                    
+                {
+                    "navigationBarTitleText": "订单中心",
+                    "enablePullDownRefresh": false
+                }
+                
+                }
+                ,{
+                    "path" : "pages/config/config",
+                    "style" :                                                                                    
+                {
+                    "navigationBarTitleText": "店铺设置",
+                    "enablePullDownRefresh": false
+                }
+                
+                }
+            ]
 	}],
 	}],
 	"preloadRule": {
 	"preloadRule": {
 		"pages/index/index": {
 		"pages/index/index": {

+ 1 - 1
pages/checkstand/pay-qrcode.vue

@@ -61,7 +61,7 @@
 			let res=await this.$api.shop.detail({id:this.vuex_shopId})
 			let res=await this.$api.shop.detail({id:this.vuex_shopId})
 			this.shopDetail=res.data
 			this.shopDetail=res.data
 			let avatar=res.data.cover
 			let avatar=res.data.cover
-			// this.avatar =(await  this.initAvatat(avatar)).tempFilePath;
+			this.avatar =(await  this.initAvatat(avatar)).tempFilePath;
 			//获取用户ID
 			//获取用户ID
 			this.id = this.$global.QR_PATH+this.vuex_shopId
 			this.id = this.$global.QR_PATH+this.vuex_shopId
 			//生成动态密码
 			//生成动态密码

+ 3 - 2
pages/index/index.vue

@@ -16,8 +16,6 @@
 					</view>
 					</view>
 				</view>
 				</view>
 			</view>
 			</view>
-
-
 			<view class="cu-list grid col-3 no-border top-menu" style="padding: 20rpx 10rpx;">
 			<view class="cu-list grid col-3 no-border top-menu" style="padding: 20rpx 10rpx;">
 				<view class="cu-item" @click="operate(index)" v-for="(item,index) in menuList" :key="index">
 				<view class="cu-item" @click="operate(index)" v-for="(item,index) in menuList" :key="index">
 					<view class="grid-icon margin-top-20">
 					<view class="grid-icon margin-top-20">
@@ -408,6 +406,9 @@
 				let audit = (await this.$api.audit.detail({
 				let audit = (await this.$api.audit.detail({
 					entityId: this.vuex_shopId
 					entityId: this.vuex_shopId
 				})).data
 				})).data
+				if (this.$isEmpty(audit)) {
+					return
+				}
 				let params = {
 				let params = {
 					assignee: '$INITIATOR',
 					assignee: '$INITIATOR',
 					processInstanceId: audit.processInstanceId
 					processInstanceId: audit.processInstanceId

+ 2 - 2
pages/material-download/createOrderPoster.vue

@@ -81,9 +81,9 @@
 					shopId:this.vuex_shopId,
 					shopId:this.vuex_shopId,
 					seatNum:`${number}号座`
 					seatNum:`${number}号座`
 				}
 				}
-				let qrCodeText = this.$global.QR_PATH + this.$u.queryParams(params)
+				let qrCodeText = this.$global.ORDER_QR_PATH + this.$u.queryParams(params)
 				let titleParams={
 				let titleParams={
-					x:w / 2 - (text.length * 10 + 6),
+					x:w / 2 - (text.length/2 * 34 - 10),
 					y:h / 2 - 240,
 					y:h / 2 - 240,
 					color:"#000",
 					color:"#000",
 					text:text			}
 					text:text			}

+ 2 - 1
pages/material-download/createPoster.vue

@@ -51,8 +51,9 @@
 			let text=shopDetail.name
 			let text=shopDetail.name
 			
 			
 			let qrCodeText = this.$global.QR_PATH + this.vuex_shopId
 			let qrCodeText = this.$global.QR_PATH + this.vuex_shopId
+			console.log(text.length,"/************");
 			let titleParams={
 			let titleParams={
-				x:w / 2 - (text.length * 8 + 6),
+				x:w / 2 - (text.length/2 * 34),
 				y:h / 2 - 240,
 				y:h / 2 - 240,
 				color:"#000",
 				color:"#000",
 				text:text			}
 				text:text			}

+ 3 - 2
pages/my-bills/bills-detail.vue

@@ -128,11 +128,12 @@
 				</view>
 				</view>
 			</view>
 			</view>
 		</block>
 		</block>
+	
 		
 		
-		<view class="question">
+		<button class="question u-reset-button" open-type="contact">
 			<text>对订单有疑问</text>
 			<text>对订单有疑问</text>
 			<text class="cuIcon-right" style="margin-top: 5rpx;"></text>
 			<text class="cuIcon-right" style="margin-top: 5rpx;"></text>
-		</view>
+		</button>
 	</view>
 	</view>
 </template>
 </template>
 
 

+ 0 - 1
pages/pay/pay.vue

@@ -44,7 +44,6 @@
 				const _this = this;
 				const _this = this;
 				uni.scanCode({
 				uni.scanCode({
 					onlyFromCamera:true,
 					onlyFromCamera:true,
-					scanType: ['barCode'],
 				    success: function (res) {
 				    success: function (res) {
 						//用户id
 						//用户id
 						let result=res.result.split(';')
 						let result=res.result.split(';')

+ 31 - 0
pagesGoods/assert/js/tarbar.js

@@ -0,0 +1,31 @@
+export  const tabbar = {
+		inactiveColor:"#8a8a8a",
+		activeColor:"#EF9944",
+		bgColor:"#ffffff",
+		midButton:true,
+		iconSize:44,
+		MinButtonSize:70,
+		borderTop:true,
+		list:[{
+				iconPath: "/pagesGoods/static/tarbar/menu.png",
+				selectedIconPath: "/pagesGoods/static/tarbar/menu1.png",
+				text: '菜单管理',
+				isDot: true,
+				pagePath: "/pagesGoods/pages/menu/menu"
+			},
+			{
+				iconPath: "/pagesGoods/static/tarbar/order.png",
+				selectedIconPath: "/pagesGoods/static/tarbar/order1.png",
+				text: '订单中心',
+				midButton: true,
+				pagePath: "/pagesGoods/pages/order/order"
+			},
+			{
+				iconPath: "/pagesGoods/static/tarbar/setting.png",
+				selectedIconPath: "/pagesGoods/static/tarbar/setting1.png",
+				text: '店铺设置',
+				pagePath: "/pagesGoods/pages/order/order"
+			},
+		]
+}
+

+ 45 - 0
pagesGoods/pages/config/config.vue

@@ -0,0 +1,45 @@
+<template>
+	<view>
+		
+		<u-tabbar
+		 @change="tabChange"
+		 v-model="tabbarCurr"
+		 :icon-size="tabbar.iconSize" 
+		 :active-color="tabbar.activeColor" 
+		 :mid-button-size="tabbar.MinButtonSize" 
+		 :list="tabbar.list" :mid-button="true">
+		 </u-tabbar>
+	</view>
+</template>
+
+<script>
+	import {
+		tabbar
+	} from "../../assert/js/tarbar.js"
+	export default {
+		data() {
+			return {
+				//tabbar
+				tabbarCurr: 2,
+				tabbar: tabbar,
+			}
+		},
+		methods: {
+			tabChange(index){
+				if (index==0) {
+					uni.redirectTo({
+						url: "/pagesGoods/pages/menu/menu"
+					})
+				}else if (index==1) {
+					uni.redirectTo({
+						url:"/pagesGoods/pages/order/order"
+					})
+				}
+			},
+		}
+	}
+</script>
+
+<style>
+
+</style>

+ 39 - 13
pagesGoods/pages/menu/menu.vue

@@ -9,9 +9,15 @@
 				</u-button>
 				</u-button>
 			</view>
 			</view>
 
 
-			<view @click="operateGoods(null)" class="center bg-white" style="width: 80%;color: #007AFF;">
+			<view v-if="$isNotEmpty(goodsList[current])" @click="operateGoods(null)" class="center bg-white flex"
+				style="width: 80%;color: #007AFF;">
 				<text class="cuIcon-roundadd margin-right-10"></text>
 				<text class="cuIcon-roundadd margin-right-10"></text>
-				<text>添加【{{goodsList[current].goodsCategory.name}}】分类下商品</text>
+				<view class="">
+					<text>添加</text>
+					<text
+						v-if="goodsList[current].goodsCategory.name">【{{goodsList[current].goodsCategory.name}}】</text>
+					<text>分类下商品</text>
+				</view>
 			</view>
 			</view>
 		</view>
 		</view>
 		<view class="u-menu-wrap">
 		<view class="u-menu-wrap">
@@ -83,7 +89,7 @@
 							<u-input :clearable="false" v-model="categoryForm.name" />
 							<u-input :clearable="false" v-model="categoryForm.name" />
 						</u-form-item>
 						</u-form-item>
 						<u-form-item label="显示顺序">
 						<u-form-item label="显示顺序">
-							<u-number-box v-model="categoryForm.displayOrder" ::min="1" :max="100"></u-number-box>
+							<u-number-box v-model="categoryForm.displayOrder" :min="1" :max="100"></u-number-box>
 						</u-form-item>
 						</u-form-item>
 						<u-form-item label="是否显示">
 						<u-form-item label="是否显示">
 							<view class="center" style="justify-content: flex-start;">
 							<view class="center" style="justify-content: flex-start;">
@@ -93,7 +99,6 @@
 						</u-form-item>
 						</u-form-item>
 					</u-form>
 					</u-form>
 				</view>
 				</view>
-
 				<view class="center " style="margin-top: 60rpx;width: 100%;justify-content: space-around;">
 				<view class="center " style="margin-top: 60rpx;width: 100%;justify-content: space-around;">
 					<block v-if="categoryEdit">
 					<block v-if="categoryEdit">
 						<view @click="deleteCategory" class="cu-btn  flex  text-lg line-red radius"
 						<view @click="deleteCategory" class="cu-btn  flex  text-lg line-red radius"
@@ -171,10 +176,17 @@
 		</u-popup>
 		</u-popup>
 
 
 		<toast ref="toast"></toast>
 		<toast ref="toast"></toast>
+
+		<u-tabbar @change="tabChange" v-model="tabbarCurr" :icon-size="tabbar.iconSize"
+			:active-color="tabbar.activeColor" :mid-button="true" :mid-button-size="tabbar.MinButtonSize" :list="tabbar.list">
+		</u-tabbar>
 	</view>
 	</view>
 </template>
 </template>
 
 
 <script>
 <script>
+	import {
+		tabbar
+	} from "../../assert/js/tarbar.js"
 	import mpUploadImg from "@/components/mp-uploadImg/mp-uploadImg.vue"
 	import mpUploadImg from "@/components/mp-uploadImg/mp-uploadImg.vue"
 	export default {
 	export default {
 		components: {
 		components: {
@@ -182,6 +194,10 @@
 		},
 		},
 		data() {
 		data() {
 			return {
 			return {
+				//tabbar
+				tabbarCurr: 0,
+				tabbar: tabbar,
+
 				goodsList: [],
 				goodsList: [],
 
 
 				//分类
 				//分类
@@ -192,11 +208,10 @@
 					id: '',
 					id: '',
 					shopId: '',
 					shopId: '',
 					name: '',
 					name: '',
-					displayOrder: 1,
+					displayOrder: 10,
 					//是否显示
 					//是否显示
 					showStatus: 1,
 					showStatus: 1,
 				},
 				},
-
 				//商品 begin
 				//商品 begin
 				imgList: [],
 				imgList: [],
 				price: 0,
 				price: 0,
@@ -208,7 +223,7 @@
 					shopId: '',
 					shopId: '',
 					goodsCategoryName: '',
 					goodsCategoryName: '',
 					name: '',
 					name: '',
-					displayOrder: 1,
+					displayOrder: 10,
 					defaultPrice: 0,
 					defaultPrice: 0,
 					isSell: 1,
 					isSell: 1,
 					image: '',
 					image: '',
@@ -243,6 +258,17 @@
 			this.$refs.uGoodsForm.setRules(this.goodsRules);
 			this.$refs.uGoodsForm.setRules(this.goodsRules);
 		},
 		},
 		methods: {
 		methods: {
+			tabChange(index){
+				if (index==1) {
+					uni.redirectTo({
+						url:"/pagesGoods/pages/order/order"
+					})
+				}else if (index==2) {
+					uni.redirectTo({
+						url:"/pagesGoods/pages/config/config"
+					})
+				}
+			},
 			getGoodsList() {
 			getGoodsList() {
 				let params = {
 				let params = {
 					shopId: this.vuex_shopId
 					shopId: this.vuex_shopId
@@ -391,15 +417,15 @@
 				})
 				})
 			},
 			},
 			//商品end
 			//商品end
-			
+
 			//商品属性begin
 			//商品属性begin
-			operateSku(goods){
-				let params={
-					goodsName:goods.name,
-					goodsId:goods.id
+			operateSku(goods) {
+				let params = {
+					goodsName: goods.name,
+					goodsId: goods.id
 				}
 				}
 				uni.navigateTo({
 				uni.navigateTo({
-					url:"/pagesGoods/pages/menu/sku"+this.$u.queryParams(params),
+					url: "/pagesGoods/pages/menu/sku" + this.$u.queryParams(params),
 				})
 				})
 			},
 			},
 
 

+ 15 - 11
pagesGoods/pages/menu/sku.vue

@@ -9,26 +9,26 @@
 					<u-form-item label="商品属性">
 					<u-form-item label="商品属性">
 						<u-input v-model="form.category" :select-open="goodsPropertyShow" type="select" @click="goodsPropertyShow=true"/>
 						<u-input v-model="form.category" :select-open="goodsPropertyShow" type="select" @click="goodsPropertyShow=true"/>
 					</u-form-item>
 					</u-form-item>
-					<u-form-item label="重置价格" v-if="form.category == '大小'">
-						<view class="flex justify-between" >
-							<u-input v-model="form.rebasePrice" />
-							<text>元</text>
-						</view>
-					</u-form-item>
 				</u-form>
 				</u-form>
 				<view @click="addInput" class="text-right text-blue " style="padding: 30rpx 10rpx;">
 				<view @click="addInput" class="text-right text-blue " style="padding: 30rpx 10rpx;">
 					<text class="cuIcon-roundadd u-m-r-4"></text>
 					<text class="cuIcon-roundadd u-m-r-4"></text>
 					<text>添加可选项</text>
 					<text>添加可选项</text>
 				</view>
 				</view>
 				
 				
-				<view style="position: relative;" class="u-border flex"
+				<view style="position: relative;" class="u-border flex padding-20"
 					v-for="(item,index) in inputList" :key="index">
 					v-for="(item,index) in inputList" :key="index">
-					<view class="" style="width: 70%;">
+					<view class="" style="width: 100%;">
 						<u-form :model="form" ref="uForm" label-width="140">
 						<u-form :model="form" ref="uForm" label-width="140">
 							<u-form-item label="可选项">
 							<u-form-item label="可选项">
 								<u-input v-model="item.propertyOption" />
 								<u-input v-model="item.propertyOption" />
 							</u-form-item>
 							</u-form-item>
-							<u-form-item :border-bottom="false" label="额外价格">
+							<u-form-item  v-if="form.category == '大小'" :border-bottom="false" label="重置价格">
+								<view class="flex">
+									<u-input v-model="item.rebasePrice" />
+									<text>元</text>
+								</view>
+							</u-form-item>
+							<u-form-item v-else :border-bottom="false" label="额外价格">
 								<view class="flex">
 								<view class="flex">
 									<u-input v-model="item.extraPrice" />
 									<u-input v-model="item.extraPrice" />
 									<text>元</text>
 									<text>元</text>
@@ -76,6 +76,7 @@
 					goodsId:'',
 					goodsId:'',
 					category:'',
 					category:'',
 					propertyOption:'',
 					propertyOption:'',
+					
 					isDefault:false,
 					isDefault:false,
 					rebasePrice:'',
 					rebasePrice:'',
 					extraPrice:''
 					extraPrice:''
@@ -84,7 +85,8 @@
 				activeIndex: 0,
 				activeIndex: 0,
 				inputList: [{
 				inputList: [{
 					propertyOption: '',
 					propertyOption: '',
-					extraPrice: ''
+					extraPrice: '',
+					rebasePrice:'',
 				}]
 				}]
 			};
 			};
 		},
 		},
@@ -92,6 +94,7 @@
 			this.goodsPropertyList=this.$global.goodsPropertyList
 			this.goodsPropertyList=this.$global.goodsPropertyList
 			this.form.goodsName=options.goodsName
 			this.form.goodsName=options.goodsName
 			this.form.goodsId=options.goodsId
 			this.form.goodsId=options.goodsId
+			this.form.shopId=this.vuex_shopId
 		},
 		},
 		methods: {
 		methods: {
 			propertyConfirm(e){
 			propertyConfirm(e){
@@ -113,7 +116,8 @@
 				this.inputList.forEach((item,index)=>{
 				this.inputList.forEach((item,index)=>{
 					let obj=this.$u.deepClone(this.form)
 					let obj=this.$u.deepClone(this.form)
 					obj.propertyOption=item.propertyOption
 					obj.propertyOption=item.propertyOption
-					obj.extraPrice=item.extraPrice
+					this.$isNotEmpty(item.extraPrice)?obj.extraPrice=item.extraPrice:''
+					this.$isNotEmpty(item.rebasePrice)?obj.rebasePrice=item.rebasePrice:''
 					obj.isDefault=this.activeIndex==index
 					obj.isDefault=this.activeIndex==index
 					formList.push(obj)
 					formList.push(obj)
 				})
 				})

+ 41 - 0
pagesGoods/pages/order/order.vue

@@ -0,0 +1,41 @@
+<template>
+	<view>
+
+		<u-tabbar @change="tabChange" v-model="tabbarCurr" :icon-size="tabbar.iconSize"
+			:active-color="tabbar.activeColor" :mid-button-size="tabbar.MinButtonSize" :list="tabbar.list"
+			:mid-button="true">
+		</u-tabbar>
+	</view>
+</template>
+
+<script>
+	import {
+		tabbar
+	} from "../../assert/js/tarbar.js"
+	export default {
+		data() {
+			return {
+				//tabbar
+				tabbarCurr: 1,
+				tabbar: tabbar,
+			}
+		},
+		methods: {
+			tabChange(index) {
+				if (index == 0) {
+					uni.redirectTo({
+						url: "/pagesGoods/pages/menu/menu"
+					})
+				} else if (index == 2) {
+					uni.redirectTo({
+						url: "/pagesGoods/pages/config/config"
+					})
+				}
+			},
+		}
+	}
+</script>
+
+<style>
+
+</style>

BIN
pagesGoods/static/tarbar/menu.png


BIN
pagesGoods/static/tarbar/menu1.png


BIN
pagesGoods/static/tarbar/order.png


BIN
pagesGoods/static/tarbar/order1.png


BIN
pagesGoods/static/tarbar/setting.png


BIN
pagesGoods/static/tarbar/setting1.png


+ 2 - 2
utils/global.js

@@ -5,8 +5,8 @@ let global = {
 	//活动发布协议
 	//活动发布协议
 	publishActivity:'https://ldt.guosen-fumao.cn/publish_activity.html',
 	publishActivity:'https://ldt.guosen-fumao.cn/publish_activity.html',
 	
 	
-	// WebSocketUrl:'ws://localhost:2366/websocket/',
-	WebSocketUrl:'wss://ldt.guosen-fumao.cn/websocket/',
+	WebSocketUrl:'ws://localhost:2366/websocket/',
+	// WebSocketUrl:'wss://ldt.guosen-fumao.cn/websocket/',
 	SOCKET_PRE:'SHOP:',
 	SOCKET_PRE:'SHOP:',
 	
 	
 	//webSocket message
 	//webSocket message

+ 2 - 2
utils/socket.js

@@ -1,5 +1,5 @@
-import  global from '@/utils/global.js'
-const baseSocketUrl=global.WebSocketUrl
+import  config from '@/assets/http/config.js'
+const baseSocketUrl=config.webSocketUrl
 class socket {
 class socket {
 	constructor(options) {
 	constructor(options) {
 		//用户id
 		//用户id