liujd 6 ani în urmă
părinte
comite
3aa0f9fc4a

+ 1 - 0
mobile-code/src/components/plugin/tabs.vue

@@ -2,6 +2,7 @@
 	<view class="tui-tabs-view" :class="[isFixed?'tui-tabs-fixed':'tui-tabs-relative',unlined?'tui-unlined':'']" :style="{height:height+'rpx',padding:`0 ${padding}rpx`,background:bgColor,top:isFixed?top+'px':'auto'}">
 		<view v-for="(item,index) in tabs" :key="index" class="tui-tabs-item" :class="{'border-left': borderLeft}" :style="{width:itemWidth}" @tap.stop="swichTabs(index)">
 			<view class="tui-tabs-title" :class="{'tui-tabs-active':currentTab==index,'tui-tabs-disabled':item.disabled}" :style="{color:currentTab==index?selectedColor:color,fontSize:size+'rpx',lineHeight:size+'rpx',fontWeight:bold && currentTab==index?'bold':'normal'}">{{item.name}}</view>
+			<div v-if="item.value">{{ item.value }}</div>
 		</view>
 		<view class="tui-tabs-slider" :style="{transform:'translateX('+scrollLeft+'px)',width:sliderWidth+'rpx',height:
 	sliderHeight+'rpx',borderRadius:sliderRadius,bottom:bottom,background:sliderBgColor,marginBottom:bottom=='50%'?('-'+sliderHeight/2+'rpx'):0}"></view>

+ 61 - 0
mobile-code/src/manifest-b.json

@@ -0,0 +1,61 @@
+{
+    "name" : "花卉宝",
+    "appid" : "",
+    "description" : "应用描述",
+    "versionName" : "1.0.0",
+    "versionCode" : "100",
+    "transformPx" : true,
+    "debug": false,
+    "networkTimeout": {
+        "request":200000
+    },
+    "mp-weixin" : {
+        "appid" : "wx3a163add860e0a86",
+        "setting" : {
+            "urlCheck" : false
+        },
+        "usingComponents" : true,
+        "permission" : {
+            "scope.userLocation" : {
+                "desc" : "请点击确定"
+            }
+        }
+    },
+    "mp-alipay" : {
+        "usingComponents" : true
+    },
+    "mp-baidu" : {
+        "usingComponents" : true
+    },
+    "mp-toutiao" : {
+        "usingComponents" : true
+    },
+    "h5" : {
+        "template" : "template.h5.html",
+        "router" : {
+            // "mode" : "history",
+            "base" : "/",
+            "publicPath" : "/"
+        },
+        "devServer": {
+            "port": 81,
+            "proxy": {
+                "/api": {
+                    "target": "http://api.m.huaml.com",
+                    "secure": false,
+                    "changeOrigin": true,
+                    "pathRewrite": {
+                        "^/api": ""
+                    }
+                }
+            }
+        },
+        "sdkConfigs" : {
+            "maps" : {
+                "qqmap" : {
+                    "key" : ""
+                }
+            }
+        }
+    }
+}

+ 2 - 2
mobile-code/src/manifest.json

@@ -1,5 +1,5 @@
 {
-    "name" : "花卉宝",
+    "name" : "花卉宝商家后台",
     "appid" : "",
     "description" : "应用描述",
     "versionName" : "1.0.0",
@@ -41,7 +41,7 @@
             "port": 81,
             "proxy": {
                 "/api": {
-                    "target": "http://api.m.huaml.com",
+                    "target": "http://api.b.huaml.com",
                     "secure": false,
                     "changeOrigin": true,
                     "pathRewrite": {

+ 198 - 0
mobile-code/src/pages-b.json

@@ -0,0 +1,198 @@
+{
+	"pages": [
+		{
+			"path": "pages/home/index",
+			"style": {
+				"navigationBarTitleText": "加载中..."
+			}
+		},
+		{
+			"path": "pages/home/category",
+			"style": {
+				"navigationBarTitleText": "分类"
+			}
+		},
+		{
+			"path": "pages/home/shop",
+			"style": {
+				"navigationBarTitleText": "门店"
+			}
+		},
+		{
+			"path": "pages/home/user",
+			"style": {
+				"navigationBarTitleText": "我的"
+			}
+		},
+		{
+			"path": "pages/common/redirect",
+			"style": {
+				"navigationBarTitleText": "加载中..."
+			}
+		},
+		{
+			"path": "pages/common/webview",
+			"style": {
+				"navigationBarBackgroundColor": "#ffffff",
+				"navigationBarTextStyle": "black"
+			}
+		}
+	],
+	"subPackages": [
+		{
+			"root": "pages/user",
+			"pages": [
+				{
+					"path": "register",
+					"style": {
+						"navigationBarTitleText": "注册"
+					}
+				},
+				{
+					"path": "password",
+					"style": {
+						"navigationBarTitleText": "修改密码"
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/goods",
+			"pages": [
+				{
+					"path": "detail",
+					"style": {
+						"navigationBarTitleText": "详情"
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/pay",
+			"pages": [
+				{
+					"path": "index",
+					"style": {
+						"navigationBarTitleText": "支付"
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/callback",
+			"pages": [
+				{
+					"path": "index"
+				}
+			]
+		},
+		{
+			"root": "pages/coupon",
+			"pages": [
+				{
+					"path": "list",
+					"style": {
+						"navigationBarTitleText": "优惠券",
+						"enablePullDownRefresh": true
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/order",
+			"pages": [
+				{
+					"path": "list",
+					"style": {
+						"navigationBarTitleText": "订单列表",
+						"enablePullDownRefresh": true
+					}
+				},
+				{
+					"path": "detail",
+					"style": {
+						"navigationBarTitleText": "订单列表",
+						"enablePullDownRefresh": true
+					}
+				},
+				{
+					"path": "buy",
+					"style": {
+						"navigationBarTitleText": "订单确认"
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/interest",
+			"pages": [
+				{
+					"path": "invite",
+					"style": {
+						"navigationBarTitleText": "邀请排行",
+						"enablePullDownRefresh": true
+					}
+				},
+				{
+					"path": "level",
+					"style": {
+						"navigationBarTitleText": "会员等级",
+						"enablePullDownRefresh": true
+					}
+				}
+			]
+		},
+		{
+			"root": "pages/chat",
+			"pages": [
+				{
+					"path": "index",
+					"style": {
+						"navigationBarTitleText": "客服",
+						"enablePullDownRefresh": true
+					}
+				}
+			]
+		}
+	],
+	"globalStyle": {
+		// #ifdef H5
+		"navigationStyle": "custom",
+		// #endif
+		"navigationBarBackgroundColor": "#fff",
+		"navigationBarTitleText": "花卉宝",
+		"navigationBarTextStyle": "black"
+	},
+	"tabBar": {
+		"color": "#C0C4CC",
+		"selectedColor": "#fa436a",
+		"borderStyle": "black",
+		"backgroundColor": "#ffffff",
+		"list": [{
+				"pagePath": "pages/home/index",
+				"iconPath": "static/images/common/home-no.png",
+				"selectedIconPath": "static/images/common/home-is.png",
+				"text": "首页"
+			},
+			{
+				"pagePath": "pages/home/category",
+				"iconPath": "static/images/common/category-no.png",
+				"selectedIconPath": "static/images/common/category-is.png",
+				"text": "分类"
+			},
+			{
+				"pagePath": "pages/home/shop",
+				"iconPath": "static/images/common/shop-no.png",
+				"selectedIconPath": "static/images/common/shop-is.png",
+				"text": "门店"
+			},
+			{
+				"pagePath": "pages/home/user",
+				"iconPath": "static/images/common/user-no.png",
+				"selectedIconPath": "static/images/common/user-is.png",
+				"text": "我的"
+			}
+		]
+	}
+}
+

+ 12 - 128
mobile-code/src/pages.json

@@ -1,27 +1,21 @@
 {
 	"pages": [
 		{
-			"path": "pages/home/index",
+			"path": "pages/admin/workbench",
 			"style": {
-				"navigationBarTitleText": "加载中..."
-			}
-		},
-		{
-			"path": "pages/home/category",
-			"style": {
-				"navigationBarTitleText": "分类"
+				"navigationBarTitleText": "工作台"
 			}
 		},
 		{
-			"path": "pages/home/shop",
+			"path": "pages/admin/order",
 			"style": {
-				"navigationBarTitleText": "门店"
+				"navigationBarTitleText": "订单"
 			}
 		},
 		{
-			"path": "pages/home/user",
+			"path": "pages/admin/member",
 			"style": {
-				"navigationBarTitleText": "我的"
+				"navigationBarTitleText": "客户"
 			}
 		},
 		{
@@ -47,110 +41,6 @@
 					"style": {
 						"navigationBarTitleText": "注册"
 					}
-				},
-				{
-					"path": "password",
-					"style": {
-						"navigationBarTitleText": "修改密码"
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/goods",
-			"pages": [
-				{
-					"path": "detail",
-					"style": {
-						"navigationBarTitleText": "详情"
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/pay",
-			"pages": [
-				{
-					"path": "index",
-					"style": {
-						"navigationBarTitleText": "支付"
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/callback",
-			"pages": [
-				{
-					"path": "index"
-				}
-			]
-		},
-		{
-			"root": "pages/coupon",
-			"pages": [
-				{
-					"path": "list",
-					"style": {
-						"navigationBarTitleText": "优惠券",
-						"enablePullDownRefresh": true
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/order",
-			"pages": [
-				{
-					"path": "list",
-					"style": {
-						"navigationBarTitleText": "订单列表",
-						"enablePullDownRefresh": true
-					}
-				},
-				{
-					"path": "detail",
-					"style": {
-						"navigationBarTitleText": "订单列表",
-						"enablePullDownRefresh": true
-					}
-				},
-				{
-					"path": "buy",
-					"style": {
-						"navigationBarTitleText": "订单确认"
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/interest",
-			"pages": [
-				{
-					"path": "invite",
-					"style": {
-						"navigationBarTitleText": "邀请排行",
-						"enablePullDownRefresh": true
-					}
-				},
-				{
-					"path": "level",
-					"style": {
-						"navigationBarTitleText": "会员等级",
-						"enablePullDownRefresh": true
-					}
-				}
-			]
-		},
-		{
-			"root": "pages/chat",
-			"pages": [
-				{
-					"path": "index",
-					"style": {
-						"navigationBarTitleText": "客服",
-						"enablePullDownRefresh": true
-					}
 				}
 			]
 		}
@@ -169,28 +59,22 @@
 		"borderStyle": "black",
 		"backgroundColor": "#ffffff",
 		"list": [{
-				"pagePath": "pages/home/index",
+				"pagePath": "pages/admin/workbench",
 				"iconPath": "static/images/common/home-no.png",
 				"selectedIconPath": "static/images/common/home-is.png",
-				"text": "首页"
+				"text": "工作台"
 			},
 			{
-				"pagePath": "pages/home/category",
+				"pagePath": "pages/admin/order",
 				"iconPath": "static/images/common/category-no.png",
 				"selectedIconPath": "static/images/common/category-is.png",
-				"text": "分类"
+				"text": "订单"
 			},
 			{
-				"pagePath": "pages/home/shop",
+				"pagePath": "pages/admin/member",
 				"iconPath": "static/images/common/shop-no.png",
 				"selectedIconPath": "static/images/common/shop-is.png",
-				"text": "门店"
-			},
-			{
-				"pagePath": "pages/home/user",
-				"iconPath": "static/images/common/user-no.png",
-				"selectedIconPath": "static/images/common/user-is.png",
-				"text": "我的"
+				"text": "客户"
 			}
 		]
 	}

+ 12 - 0
mobile-code/src/pages/admin/member.vue

@@ -0,0 +1,12 @@
+<template>
+	<div class="app-main app-content"></div>
+</template>
+
+<script>
+export default {
+	name: 'admin-memebr'
+}
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 96 - 0
mobile-code/src/pages/admin/order.vue

@@ -0,0 +1,96 @@
+<template>
+	<div class="app-main app-content">
+		<app-tabs :tabs="tabs" :isFixed="true" :currentTab="tabIndex" @change="change" itemWidth="20%" />
+		<!-- <div class="list-wrap" v-for="(item, index) in 4" :key="index" @click="$util.pageTo('/pages/order/detail')">
+			<div class="list-top flex-center-between">
+				<div class="app-color-3">订单编号:3261515151</div>
+				<div class="app-price">等待支付</div>
+			</div>
+			<div class="list-blo">
+				<list-module v-for="(item, subIndex) in 2" :key="subIndex" />
+			</div>
+			<div class="list-bottom flex-center-between">
+				<div>
+					<span>应付金额:</span>
+					<span class="app-size-30 app-bold">¥580.00</span>
+				</div>
+				<button class="button-com red">立即付款</button>
+			</div>
+		</div> -->
+	</div>
+</template>
+
+<script>
+import appTabs from '@/components/plugin/tabs'
+import listModule from '@/components/module/app-order-list'
+export default {
+	name: 'order-list',
+	components: {
+		listModule,
+		appTabs
+	},
+	data() {
+		return {
+			tabIndex: 0,
+			tabs: [
+				{
+					name: '全部',
+					value: 212
+				},
+				{
+					name: '待付款',
+					value: 213
+				},
+				{
+					name: '待配送',
+					value: 214
+				},
+				{
+					name: '配送中',
+					value: 215
+				},
+				{
+					name: '已完结',
+					value: 216
+				}
+			]
+		}
+	},
+	onPullDownRefresh() {
+		console.log('fasdfasdf')
+	},
+	// 加载更多
+	onReachBottom() {
+		console.log('5151')
+	},
+	methods: {
+		change(e) {
+			this.tabIndex = e.index
+		}
+	}
+}
+</script>
+
+<style lang="scss" scoped>
+</style>
+
+<style lang="scss" scoped>
+	.app-content {
+		padding-top: 20px;
+		padding-bottom: 1px;
+		.list-wrap {
+			padding: 0 30px;
+			background-color: #fff;
+			margin-bottom: 20px;
+			.list-top,
+			.list-bottom {
+				padding: 20px 0;
+				border-bottom: 1px solid $borderColor;
+				.button-com {
+					padding-top: 15px;
+					padding-bottom: 15px;
+				}
+			}
+		}
+	}
+</style>

+ 12 - 0
mobile-code/src/pages/admin/workbench.vue

@@ -0,0 +1,12 @@
+<template>
+	<div class="app-main app-content"></div>
+</template>
+
+<script>
+export default {
+	name: 'admin-workbench'
+}
+</script>
+
+<style lang="scss" scoped>
+</style>

+ 105 - 0
mobile-code/src/uni-b.scss

@@ -0,0 +1,105 @@
+/***
+全局scss 变量和方法 存放处
+ */
+//  uniapp upx换算函数
+//  uni.upx2px(val) + 'px'
+/* 引入minxin */
+@import '~@/static/css/minxin.scss';
+
+/* 颜色变量 */
+/*图片地址*/
+$imgUrl: 'https://wximg.meijiabang.com/hkds/miniapp/images/';
+
+// 所有样式为公共样式,已在全局引用可直接使用
+// 主色
+$mainColor: #FF2842;
+$mainColor1: #3A8840;
+$auxiliaryColor2: #ff6900;
+
+$blueColor: #2965fe;
+$greenColor: #3A8840;
+$redColor: #ff3841;
+// 字体色
+$fontColorMain: #333333;
+$fontColor2: #666666;
+$fontColor3: #999999;
+$fontColor4: #bbbbbb;
+$fontColor5: #cccccc;
+// 边框
+$borderColor: #eee;
+$borderColor1: #46963E;
+// 背景色
+$backColor: #f5f5f5;
+
+// minxin
+@mixin disFlexCen(){
+    display:flex;
+    display: -webkit-flex;
+    display: -moz-flex;
+    display: -ms-flex;
+    align-items: center;
+}
+
+// =============================================== 下方为uniapp原生样式变量 ======================================
+
+/* 行为相关颜色 */
+$uni-color-primary: #007aff;
+$uni-color-success: #4cd964;
+$uni-color-warning: #f0ad4e;
+$uni-color-error: #dd524d;
+
+/* 文字基本颜色 */
+$uni-text-color:#333;//基本色
+$uni-text-color-inverse:#fff;//反色
+$uni-text-color-grey:#999;//辅助灰色,如加载更多的提示信息
+$uni-text-color-placeholder: #808080;
+$uni-text-color-disable:#c0c0c0;
+
+/* 背景颜色 */
+$uni-bg-color:#ffffff;
+$uni-bg-color-grey:#f8f8f8;
+$uni-bg-color-hover:#f1f1f1;//点击状态颜色
+$uni-bg-color-mask:rgba(0, 0, 0, 0.4);//遮罩颜色
+
+/* 边框颜色 */
+$uni-border-color:#c8c7cc;
+
+/* 尺寸变量 */
+
+/* 文字尺寸 */
+$uni-font-size-sm:24upx;
+$uni-font-size-base:28upx;
+$uni-font-size-lg:32upx;
+
+/* 图片尺寸 */
+$uni-img-size-sm:40upx;
+$uni-img-size-base:52upx;
+$uni-img-size-lg:80upx;
+
+/* Border Radius */
+$uni-border-radius-sm: 4upx;
+$uni-border-radius-base: 6upx;
+$uni-border-radius-lg: 12upx;
+$uni-border-radius-circle: 50%;
+
+/* 水平间距 */
+$uni-spacing-row-sm: 10px;
+$uni-spacing-row-base: 20upx;
+$uni-spacing-row-lg: 30upx;
+
+/* 垂直间距 */
+$uni-spacing-col-sm: 8upx;
+$uni-spacing-col-base: 16upx;
+$uni-spacing-col-lg: 24upx;
+
+/* 透明度 */
+$uni-opacity-disabled: 0.3; // 组件禁用态的透明度
+
+/* 文章场景相关 */
+$uni-color-title: #2C405A; // 文章标题颜色
+$uni-font-size-title:40upx;
+$uni-color-subtitle: #555555; // 二级标题颜色
+$uni-font-size-subtitle:36upx;
+$uni-color-paragraph: #3F536E; // 文章段落颜色
+$uni-font-size-paragraph:30upx;
+

+ 1 - 1
mobile-code/src/uni.scss

@@ -12,7 +12,7 @@ $imgUrl: 'https://wximg.meijiabang.com/hkds/miniapp/images/';
 
 // 所有样式为公共样式,已在全局引用可直接使用
 // 主色
-$mainColor: #FF2842;
+$mainColor: #3385FF;
 $mainColor1: #3A8840;
 $auxiliaryColor2: #ff6900;