XSLu08042 il y a 6 jours
Parent
commit
c8f2f8ea9e

+ 3 - 3
api/storeProductPackage.js

@@ -13,7 +13,7 @@ let request = new Request().http
  	 return request('/app/storeProductPackage/sendPackage',data,'POST','application/json;charset=UTF-8');
  } 
  
-  
  
- 
- 
+ export function getPackagCateList(data) {
+ 	 return request('/app/storeProductPackage/getPackagCateList',data,'GET');
+ }

+ 14 - 323
package-lock.json

@@ -1,344 +1,35 @@
 {
   "name": "zhongkmall_user_app",
   "version": "1.0.0",
-  "lockfileVersion": 3,
+  "lockfileVersion": 1,
   "requires": true,
-  "packages": {
-    "": {
-      "name": "zhongkmall_user_app",
-      "version": "1.0.0",
-      "license": "ISC",
-      "dependencies": {
-        "crypto-js": "^4.2.0",
-        "dayjs": "^1.11.19",
-        "uview-ui": "^2.0.38",
-        "vuex": "^4.1.0"
-      }
-    },
-    "node_modules/@babel/helper-string-parser": {
-      "version": "7.27.1",
-      "resolved": "https://registry.npmmirror.com/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz",
-      "integrity": "sha512-qMlSxKbpRlAridDExk92nSobyDdpPijUq2DW6oDnUqd0iOGxmQjyqhMIihI9+zv4LPyZdRje2cavWPbCbWm3eA==",
-      "license": "MIT",
-      "peer": true,
-      "engines": {
-        "node": ">=6.9.0"
-      }
-    },
-    "node_modules/@babel/helper-validator-identifier": {
-      "version": "7.27.1",
-      "resolved": "https://registry.npmmirror.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.27.1.tgz",
-      "integrity": "sha512-D2hP9eA+Sqx1kBZgzxZh0y1trbuU+JoDkiEwqhQ36nodYqJwyEIhPSdMNd7lOm/4io72luTPWH20Yda0xOuUow==",
-      "license": "MIT",
-      "peer": true,
-      "engines": {
-        "node": ">=6.9.0"
-      }
-    },
-    "node_modules/@babel/parser": {
-      "version": "7.28.0",
-      "resolved": "https://registry.npmmirror.com/@babel/parser/-/parser-7.28.0.tgz",
-      "integrity": "sha512-jVZGvOxOuNSsuQuLRTh13nU0AogFlw32w/MT+LV6D3sP5WdbW61E77RnkbaO2dUvmPAYrBDJXGn5gGS6tH4j8g==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@babel/types": "^7.28.0"
-      },
-      "bin": {
-        "parser": "bin/babel-parser.js"
-      },
-      "engines": {
-        "node": ">=6.0.0"
-      }
-    },
-    "node_modules/@babel/types": {
-      "version": "7.28.2",
-      "resolved": "https://registry.npmmirror.com/@babel/types/-/types-7.28.2.tgz",
-      "integrity": "sha512-ruv7Ae4J5dUYULmeXw1gmb7rYRz57OWCPM57pHojnLq/3Z1CK2lNSLTCVjxVk1F/TZHwOZZrOWi0ur95BbLxNQ==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@babel/helper-string-parser": "^7.27.1",
-        "@babel/helper-validator-identifier": "^7.27.1"
-      },
-      "engines": {
-        "node": ">=6.9.0"
-      }
-    },
-    "node_modules/@jridgewell/sourcemap-codec": {
-      "version": "1.5.4",
-      "resolved": "https://registry.npmmirror.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.4.tgz",
-      "integrity": "sha512-VT2+G1VQs/9oz078bLrYbecdZKs912zQlkelYpuf+SXF+QvZDYJlbx/LSx+meSAwdDFnF8FVXW92AVjjkVmgFw==",
-      "license": "MIT",
-      "peer": true
-    },
-    "node_modules/@vue/compiler-core": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/compiler-core/-/compiler-core-3.5.18.tgz",
-      "integrity": "sha512-3slwjQrrV1TO8MoXgy3aynDQ7lslj5UqDxuHnrzHtpON5CBinhWjJETciPngpin/T3OuW3tXUf86tEurusnztw==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@babel/parser": "^7.28.0",
-        "@vue/shared": "3.5.18",
-        "entities": "^4.5.0",
-        "estree-walker": "^2.0.2",
-        "source-map-js": "^1.2.1"
-      }
-    },
-    "node_modules/@vue/compiler-dom": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/compiler-dom/-/compiler-dom-3.5.18.tgz",
-      "integrity": "sha512-RMbU6NTU70++B1JyVJbNbeFkK+A+Q7y9XKE2EM4NLGm2WFR8x9MbAtWxPPLdm0wUkuZv9trpwfSlL6tjdIa1+A==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/compiler-core": "3.5.18",
-        "@vue/shared": "3.5.18"
-      }
-    },
-    "node_modules/@vue/compiler-sfc": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/compiler-sfc/-/compiler-sfc-3.5.18.tgz",
-      "integrity": "sha512-5aBjvGqsWs+MoxswZPoTB9nSDb3dhd1x30xrrltKujlCxo48j8HGDNj3QPhF4VIS0VQDUrA1xUfp2hEa+FNyXA==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@babel/parser": "^7.28.0",
-        "@vue/compiler-core": "3.5.18",
-        "@vue/compiler-dom": "3.5.18",
-        "@vue/compiler-ssr": "3.5.18",
-        "@vue/shared": "3.5.18",
-        "estree-walker": "^2.0.2",
-        "magic-string": "^0.30.17",
-        "postcss": "^8.5.6",
-        "source-map-js": "^1.2.1"
-      }
-    },
-    "node_modules/@vue/compiler-ssr": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/compiler-ssr/-/compiler-ssr-3.5.18.tgz",
-      "integrity": "sha512-xM16Ak7rSWHkM3m22NlmcdIM+K4BMyFARAfV9hYFl+SFuRzrZ3uGMNW05kA5pmeMa0X9X963Kgou7ufdbpOP9g==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/compiler-dom": "3.5.18",
-        "@vue/shared": "3.5.18"
-      }
-    },
-    "node_modules/@vue/devtools-api": {
+  "dependencies": {
+    "@vue/devtools-api": {
       "version": "6.6.4",
-      "resolved": "https://registry.npmjs.org/@vue/devtools-api/-/devtools-api-6.6.4.tgz",
+      "resolved": "https://registry.npmmirror.com/@vue/devtools-api/-/devtools-api-6.6.4.tgz",
       "integrity": "sha512-sGhTPMuXqZ1rVOk32RylztWkfXTRhuS7vgAKv0zjqk8gbsHkJ7xfFf+jbySxt7tWObEJwyKaHMikV/WGDiQm8g=="
     },
-    "node_modules/@vue/reactivity": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/reactivity/-/reactivity-3.5.18.tgz",
-      "integrity": "sha512-x0vPO5Imw+3sChLM5Y+B6G1zPjwdOri9e8V21NnTnlEvkxatHEH5B5KEAJcjuzQ7BsjGrKtfzuQ5eQwXh8HXBg==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/shared": "3.5.18"
-      }
-    },
-    "node_modules/@vue/runtime-core": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/runtime-core/-/runtime-core-3.5.18.tgz",
-      "integrity": "sha512-DUpHa1HpeOQEt6+3nheUfqVXRog2kivkXHUhoqJiKR33SO4x+a5uNOMkV487WPerQkL0vUuRvq/7JhRgLW3S+w==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/reactivity": "3.5.18",
-        "@vue/shared": "3.5.18"
-      }
-    },
-    "node_modules/@vue/runtime-dom": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/runtime-dom/-/runtime-dom-3.5.18.tgz",
-      "integrity": "sha512-YwDj71iV05j4RnzZnZtGaXwPoUWeRsqinblgVJwR8XTXYZ9D5PbahHQgsbmzUvCWNF6x7siQ89HgnX5eWkr3mw==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/reactivity": "3.5.18",
-        "@vue/runtime-core": "3.5.18",
-        "@vue/shared": "3.5.18",
-        "csstype": "^3.1.3"
-      }
-    },
-    "node_modules/@vue/server-renderer": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/server-renderer/-/server-renderer-3.5.18.tgz",
-      "integrity": "sha512-PvIHLUoWgSbDG7zLHqSqaCoZvHi6NNmfVFOqO+OnwvqMz/tqQr3FuGWS8ufluNddk7ZLBJYMrjcw1c6XzR12mA==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/compiler-ssr": "3.5.18",
-        "@vue/shared": "3.5.18"
-      },
-      "peerDependencies": {
-        "vue": "3.5.18"
-      }
-    },
-    "node_modules/@vue/shared": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/@vue/shared/-/shared-3.5.18.tgz",
-      "integrity": "sha512-cZy8Dq+uuIXbxCZpuLd2GJdeSO/lIzIspC2WtkqIpje5QyFbvLaI5wZtdUjLHjGZrlVX6GilejatWwVYYRc8tA==",
-      "license": "MIT",
-      "peer": true
-    },
-    "node_modules/crypto-js": {
+    "crypto-js": {
       "version": "4.2.0",
       "resolved": "https://registry.npmmirror.com/crypto-js/-/crypto-js-4.2.0.tgz",
-      "integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==",
-      "license": "MIT"
+      "integrity": "sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q=="
     },
-    "node_modules/csstype": {
-      "version": "3.1.3",
-      "resolved": "https://registry.npmmirror.com/csstype/-/csstype-3.1.3.tgz",
-      "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==",
-      "license": "MIT",
-      "peer": true
-    },
-    "node_modules/dayjs": {
+    "dayjs": {
       "version": "1.11.19",
       "resolved": "https://registry.npmmirror.com/dayjs/-/dayjs-1.11.19.tgz",
-      "integrity": "sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw==",
-      "license": "MIT"
-    },
-    "node_modules/entities": {
-      "version": "4.5.0",
-      "resolved": "https://registry.npmmirror.com/entities/-/entities-4.5.0.tgz",
-      "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==",
-      "license": "BSD-2-Clause",
-      "peer": true,
-      "engines": {
-        "node": ">=0.12"
-      },
-      "funding": {
-        "url": "https://github.com/fb55/entities?sponsor=1"
-      }
-    },
-    "node_modules/estree-walker": {
-      "version": "2.0.2",
-      "resolved": "https://registry.npmmirror.com/estree-walker/-/estree-walker-2.0.2.tgz",
-      "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==",
-      "license": "MIT",
-      "peer": true
-    },
-    "node_modules/magic-string": {
-      "version": "0.30.17",
-      "resolved": "https://registry.npmmirror.com/magic-string/-/magic-string-0.30.17.tgz",
-      "integrity": "sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@jridgewell/sourcemap-codec": "^1.5.0"
-      }
-    },
-    "node_modules/nanoid": {
-      "version": "3.3.11",
-      "resolved": "https://registry.npmmirror.com/nanoid/-/nanoid-3.3.11.tgz",
-      "integrity": "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==",
-      "funding": [
-        {
-          "type": "github",
-          "url": "https://github.com/sponsors/ai"
-        }
-      ],
-      "license": "MIT",
-      "peer": true,
-      "bin": {
-        "nanoid": "bin/nanoid.cjs"
-      },
-      "engines": {
-        "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1"
-      }
-    },
-    "node_modules/picocolors": {
-      "version": "1.1.1",
-      "resolved": "https://registry.npmmirror.com/picocolors/-/picocolors-1.1.1.tgz",
-      "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==",
-      "license": "ISC",
-      "peer": true
-    },
-    "node_modules/postcss": {
-      "version": "8.5.6",
-      "resolved": "https://registry.npmmirror.com/postcss/-/postcss-8.5.6.tgz",
-      "integrity": "sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==",
-      "funding": [
-        {
-          "type": "opencollective",
-          "url": "https://opencollective.com/postcss/"
-        },
-        {
-          "type": "tidelift",
-          "url": "https://tidelift.com/funding/github/npm/postcss"
-        },
-        {
-          "type": "github",
-          "url": "https://github.com/sponsors/ai"
-        }
-      ],
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "nanoid": "^3.3.11",
-        "picocolors": "^1.1.1",
-        "source-map-js": "^1.2.1"
-      },
-      "engines": {
-        "node": "^10 || ^12 || >=14"
-      }
+      "integrity": "sha512-t5EcLVS6QPBNqM2z8fakk/NKel+Xzshgt8FFKAn+qwlD1pzZWxh0nVCrvFK7ZDb6XucZeF9z8C7CBWTRIVApAw=="
     },
-    "node_modules/source-map-js": {
-      "version": "1.2.1",
-      "resolved": "https://registry.npmmirror.com/source-map-js/-/source-map-js-1.2.1.tgz",
-      "integrity": "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==",
-      "license": "BSD-3-Clause",
-      "peer": true,
-      "engines": {
-        "node": ">=0.10.0"
-      }
-    },
-    "node_modules/uview-ui": {
+    "uview-ui": {
       "version": "2.0.38",
-      "resolved": "https://registry.npmjs.org/uview-ui/-/uview-ui-2.0.38.tgz",
-      "integrity": "sha512-6egHDf9lXHKpG3hEjRE0vMx4+VWwKk/ReTf5x18KrIKqdvdPRqO3+B8Unh7vYYwrIxzAWIlmhZ9RJpKI/4UqPQ==",
-      "engines": {
-        "HBuilderX": "^3.1.0"
-      }
-    },
-    "node_modules/vue": {
-      "version": "3.5.18",
-      "resolved": "https://registry.npmmirror.com/vue/-/vue-3.5.18.tgz",
-      "integrity": "sha512-7W4Y4ZbMiQ3SEo+m9lnoNpV9xG7QVMLa+/0RFwwiAVkeYoyGXqWE85jabU4pllJNUzqfLShJ5YLptewhCWUgNA==",
-      "license": "MIT",
-      "peer": true,
-      "dependencies": {
-        "@vue/compiler-dom": "3.5.18",
-        "@vue/compiler-sfc": "3.5.18",
-        "@vue/runtime-dom": "3.5.18",
-        "@vue/server-renderer": "3.5.18",
-        "@vue/shared": "3.5.18"
-      },
-      "peerDependencies": {
-        "typescript": "*"
-      },
-      "peerDependenciesMeta": {
-        "typescript": {
-          "optional": true
-        }
-      }
+      "resolved": "https://registry.npmmirror.com/uview-ui/-/uview-ui-2.0.38.tgz",
+      "integrity": "sha512-6egHDf9lXHKpG3hEjRE0vMx4+VWwKk/ReTf5x18KrIKqdvdPRqO3+B8Unh7vYYwrIxzAWIlmhZ9RJpKI/4UqPQ=="
     },
-    "node_modules/vuex": {
+    "vuex": {
       "version": "4.1.0",
-      "resolved": "https://registry.npmjs.org/vuex/-/vuex-4.1.0.tgz",
+      "resolved": "https://registry.npmmirror.com/vuex/-/vuex-4.1.0.tgz",
       "integrity": "sha512-hmV6UerDrPcgbSy9ORAtNXDr9M4wlNP4pEFKye4ujJF8oqgFFuxDCdOLS3eNoRTtq5O3hoBDh9Doj1bQMYHRbQ==",
-      "dependencies": {
+      "requires": {
         "@vue/devtools-api": "^6.0.0-beta.11"
-      },
-      "peerDependencies": {
-        "vue": "^3.2.0"
       }
     }
   }

+ 3 - 0
pages/shopping/confirmOrder.vue

@@ -195,6 +195,9 @@
 			})
 			this.getWeixinOrderTemps();
 		},
+		onUnload() {
+			uni.$off('updateAddress')
+		},
 		methods: {
 			getWeixinOrderTemps:function(){
 				getWeixinOrderTemps().then(

+ 24 - 29
pages/shopping/productDetails.vue

@@ -37,11 +37,11 @@
 					<text class="label" >零售价</text>
 					<text class="old" >¥{{product.otPrice}}</text>
 				</view>
-				<view class="share-box" v-if="userinfo.isShow==1&&isuser==false">
+				<!-- <view class="share-box" v-if="userinfo.isShow==1&&isuser==false">
 					<text class="text">分享</text>
 					<image src="https://kntobs.jnmyunl.com/shop/images/share1.png" mode=""></image>
 					<button  class="share" data-name="shareBtn" open-type="share">分享</button>
-				</view>
+				</view> -->
 			</view>
 			<view class="name-box">
 				<view class="tag">{{utils.getDictLabelName("storeProductType",product.productType)}}</view>{{product.productName}}
@@ -267,11 +267,6 @@
 				const obj = this.utils.urlToObj(url)
 				uni.setStorageSync('tuiUserId',obj.userId);
 			}
-			uni.showShareMenu({
-				withShareTicket:true,
-				//小程序的原生菜单中显示分享按钮,才能够让发送给朋友与分享到朋友圈两个按钮可以点击
-				menus:["shareAppMessage","shareTimeline"] //不设置默认发送给朋友
-			})
 			this.getDicts();
 			this.productId = options.productId;
 			if(this.utils.checkToken()){
@@ -286,29 +281,29 @@
 				this.isuser=true
 			}
 		},
-		//发送给朋友
-		onShareAppMessage(res) {
-			if(this.utils.isLogin()){
-				var user=JSON.parse( uni.getStorageSync('userInfo'))
-				return {
-					title: this.product.productName,
-					path: '/pages/shopping/productDetails?productId='+this.product.productId+"&userId="+user.userId,
-					imageUrl: this.logoimg //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
-				}
-			}
-		},
-		//分享到朋友圈
-		onShareTimeline(res) {
-			if(this.utils.isLogin()){
-				var user=JSON.parse( uni.getStorageSync('userInfo'))
-				return {
-					title: this.product.productName,
-					query:'productId='+this.product.productId+"&userId="+user.userId,//页面参数
-					imageUrl: this.logoimg //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
-				}
-			}
+		// //发送给朋友
+		// onShareAppMessage(res) {
+		// 	if(this.utils.isLogin()){
+		// 		var user=JSON.parse( uni.getStorageSync('userInfo'))
+		// 		return {
+		// 			title: this.product.productName,
+		// 			path: '/pages/shopping/productDetails?productId='+this.product.productId+"&userId="+user.userId,
+		// 			imageUrl: this.logoimg //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
+		// 		}
+		// 	}
+		// },
+		// //分享到朋友圈
+		// onShareTimeline(res) {
+		// 	if(this.utils.isLogin()){
+		// 		var user=JSON.parse( uni.getStorageSync('userInfo'))
+		// 		return {
+		// 			title: this.product.productName,
+		// 			query:'productId='+this.product.productId+"&userId="+user.userId,//页面参数
+		// 			imageUrl: this.logoimg //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
+		// 		}
+		// 	}
 			
-		},
+		// },
 		methods: {
 			getuser(){
 				getUserInfo().then(

+ 2 - 2
pages/user/index.vue

@@ -124,7 +124,7 @@
 								<image src="https://kntobs.jnmyunl.com/shop/images/qualification.png" mode=""></image>
 								<text class="text">资质证书</text>
 							</view>
-							<view class="item no-marin-bottom align-top" @click="navgetTo('/pages_course/livingList')">
+						<!-- 	<view class="item no-marin-bottom align-top" @click="navgetTo('/pages_course/livingList')">
 								<image
 									src="https://bjzmky-1323137866.cos.ap-chongqing.myqcloud.com/shop/images/integral.png"
 									mode=""></image>
@@ -135,7 +135,7 @@
 									src="https://bjzmky-1323137866.cos.ap-chongqing.myqcloud.com/shop/images/live.png"
 									mode=""></image>
 								<text class="text">直播订单</text>
-							</view>
+							</view> -->
 							<view class="item no-marin-bottom" @click="toManager()">
 								<image src="https://kntobs.jnmyunl.com/shop/images/products_icon.png" mode=""></image>
 								<text class="text">制单管理</text>

+ 40 - 16
pages_company/coupon.vue

@@ -83,6 +83,7 @@
   </view>
 </template>
 <script>
+import {getPackagCateList} from '@/api/storeProductPackage.js'	
 import { getCompanyCouponIssueList, receive,sendCoupon,searchUser} from '@/api/coupon'
 import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
 import Loading from '@/components/Loading'
@@ -108,9 +109,14 @@ export default {
 		CompanyUserInfo:{},
 		user:{},
 		phoneUser:{},
+		downOption: {   //下拉刷新
+		 	use:true,
+			auto: false // 不自动加载 (mixin已处理第一个tab触发downCallback)
+		},
 		upOption: {
 			onScroll:true,
 			use: true, // 是否启用上拉加载; 默认true
+			auto: false,
 			page: {
 				num:0, // 当前页码,默认0,回调之前会加1,即callback(page)会从1开始
 				size: 7 // 每页数据的数量,默认10
@@ -130,23 +136,41 @@ export default {
     }
   },
   onLoad(options) {
-		var cate={dictLabel:"全部",dictValue:0};
-		this.cates.push(cate);
-		this.cates=this.cates.concat(this.utils.getDict("storeProductPackageCate"));
-  },
-  mounted: function() {
-    
+		// var cate={dictLabel:"全部",dictValue:0};
+		// this.cates.push(cate);
+		// this.cates=this.cates.concat(this.utils.getDict("storeProductPackageCate"));
+		this.getPackagCateList()
   },
-  
   onShow() {
-  	// this.upCallback()
 	this.CompanyUserInfo=uni.getStorageSync('CompanyUserInfo');
 	this.user=uni.getStorageSync('userInfo');
   },
-  // onReachBottom() {
-  //   !this.loading && this.upCallback()
-  // },
   methods: {
+	  getPackagCateList(type){
+	  	var data={
+	  		companyUserToken:uni.getStorageSync('CompanyUserToken'),
+	  		appId:wx.getAccountInfoSync().miniProgram.appId
+	  	}
+	  	var that=this;
+		this.cates = []
+	  	getPackagCateList(data).then(
+	  		res => {
+	  			if(res.code==200&&res.data&&res.data.length>0){
+	  				var cate={dictLabel:"全部",dictValue:0};
+	  				this.cates.push(cate);
+	  				this.cates=this.cates.concat(res.data);
+					this.cateId = 0
+					this.mescroll&&this.mescroll.resetUpScroll()
+	  			} else {
+					this.cateId = 0
+					this.dataList = []
+				}
+	  		},
+	  		err => {
+	  		}
+	  	);
+	  	
+	  },
 	  doSearch(){
 	  	console.log(this.searchValue)
 	  	this.mescroll.resetUpScroll()
@@ -310,8 +334,8 @@ export default {
 					text-align: center;
 					border-radius: 32upx;
 					margin-left: 15upx;
-					border: 1px solid red;
-					color: red;
+					border: 1px solid #2BC7B9;
+					color: #2BC7B9;
 				}
 			}
 		}
@@ -570,12 +594,12 @@ page {
   	margin-left: 15upx;
 
   	&.cancel{
-  		border: 1px solid red;
-  		color: red;
+  		border: 1px solid #2BC7B9;
+  		color: #2BC7B9;
 		margin-bottom: 12rpx;
   	}
   	&.receive{
-  		background: red;
+  		background: #2BC7B9;
   		color: #FFFFFF;
   	}
   }

+ 6 - 5
pages_company/couponDetails.vue

@@ -91,6 +91,7 @@ export default {
 		uni.showShareMenu()
 	}else{
 		uni.hideShareMenu()
+		if(!this.utils.isLogin()) return
 	}
 	this.getCouponIssueById();
   },
@@ -240,8 +241,8 @@ export default {
 					text-align: center;
 					border-radius: 32upx;
 					margin-left: 15upx;
-					border: 1px solid red;
-					color: red;
+					border: 1px solid #2BC7B9;
+					color: #2BC7B9;
 				}
 			}
 		}
@@ -467,12 +468,12 @@ page {
   	margin-left: 15upx;
 
   	&.cancel{
-  		border: 1px solid red;
-  		color: red;
+  		border: 1px solid #2BC7B9;
+  		color: #2BC7B9;
 		margin-bottom: 8rpx;
   	}
   	&.receive{
-  		background: red;
+  		background: #2BC7B9;
   		color: #FFFFFF;
   	}
   }

+ 3 - 2
pages_company/index.vue

@@ -48,10 +48,10 @@
 					 	<image src="https://kuanyitang-1317640934.cos.ap-shanghai.myqcloud.com/app/image/wechat.png" mode=""></image>
 					 	<text class="text">微信收款码</text>
 					 </view>
-					 <view class="item" @click="toShareLive()">
+					<!-- <view class="item" @click="toShareLive()">
 					 	<image src="https://kntobs.jnmyunl.com/userapp/images/live_icon.png" mode=""></image>
 					 	<text class="text">分享直播间</text>
-					 </view>
+					 </view> -->
 				</view>
 			</view>
 			<!-- 退出登录按钮 -->
@@ -177,6 +177,7 @@
 			 		success:res=>{
 			 			if(res.confirm){
 			 				uni.setStorageSync('CompanyUserToken',null);
+							uni.removeStorageSync('CompanyUserInfo');
 			 				uni.navigateBack({
 			 					delta:-1
 			 				})							

+ 6 - 2
pages_company/order/confirmCompanyOrder.vue

@@ -54,8 +54,12 @@
 			</view>
 		</view>
 		<modal v-if="inputShow" title="实收金额" confirm-text="保存" cancel-text="取消" @cancel="cancelUpdateMoney" @confirm="confirmUpdateMoney">
-			<input type="text" v-model="inputTxt" placeholder="请输入实收金额" class="intxt" maxlength="8" />
-			<input type="text" v-model="payAmount" placeholder="请输入货到付款金额" class="intxt pay_type" maxlength="8" />
+			<view style="color: black;">
+				<text>实收金额:</text>
+				<input type="text" v-model="inputTxt" placeholder="请输入实收金额" class="intxt" maxlength="8" /></view>
+			<view class="pay_type" style="color: black;">
+				<text>货到付款金额:</text>
+				<input type="text" v-model="payAmount" placeholder="请输入货到付款金额" class="intxt" maxlength="8" /></view>
 		</modal>
 	</view>
 </template>

+ 4 - 5
pages_company/order/confirmOrder.vue

@@ -82,15 +82,14 @@
 			}
 		},
 		onLoad(option) {
-			if(this.utils.isLogin()){
-				this.getOrderCount();
-			}
 			console.log("qxj option:"+JSON.stringify(option));
 			this.orderKey=option.orderKey;
-			this.getSalesOrder();
-			 
 		},
 		onShow() {
+			if(this.utils.isLogin()){
+				this.getOrderCount();
+			}
+			this.getSalesOrder();
 			this.getDicts()
 		},
 		methods: {

+ 5 - 5
pages_company/order/coupon.vue

@@ -280,8 +280,8 @@ export default {
 					text-align: center;
 					border-radius: 32upx;
 					margin-left: 15upx;
-					border: 1px solid red;
-					color: red;
+					border: 1px solid #2BC7B9;
+					color: #2BC7B9;
 				}
 			}
 		}
@@ -511,12 +511,12 @@ page {
   	margin-left: 15upx;
 
   	&.cancel{
-  		border: 1px solid red;
-  		color: red;
+  		border: 1px solid #2BC7B9;
+  		color: #2BC7B9;
 		margin-bottom: 8rpx;
   	}
   	&.receive{
-  		background: red;
+  		background: #2BC7B9;
   		color: #FFFFFF;
   	}
   }

+ 31 - 18
pages_company/order/productDetails.vue

@@ -99,8 +99,8 @@
 				</view>
 			</view>
 			<view class="btn-box">
+				<view class="btn buy" @click="addCart('cart',1)">立即制单</view>
 				<view class="btn cart" @click="addCart('cart')">加入购物车</view>
-				<!-- <view class="btn buy" @click="submitgoods()">立即制单</view> -->
 				<!-- <view class="btn buy" @click="addCart('buy')">{{buyText}}</view> -->
 			</view>
 		</view>
@@ -204,6 +204,7 @@
 				  // 字符串的形式
 				  img: "display: block;",
 				},
+				voucherPreparation:0
 			};
 		},
 		onLoad(options) {
@@ -228,17 +229,15 @@
 		     },
 		 },
 		methods: {
-			submitgoods(){
+			submitgoods(cateIds){
 				//选择后提交制单
-				var data={
+				let data={
 					token:uni.getStorageSync('CompanyUserToken'),
-					// isPackage:1,
-					cateIds:this.product.cateId,
-					// orderType:this.cardid,
-					// orderMedium:this.videoid
-					}
+					cateIds:cateIds,
+				}
 				createSalesOrder(data).then(
 					res => {
+						uni.hideLoading()
 						if(res.code==200){
 							uni.navigateTo({
 								url: '/pages_company/order/confirmCompanyOrder?orderKey='+res.orderKey
@@ -251,7 +250,9 @@
 						}
 					},
 					rej => {}
-				);
+				).catch(()=>{
+					uni.hideLoading()
+				});
 			},
 			getDicts:function(){
 				getDicts().then(
@@ -281,6 +282,11 @@
 				}
 				var isBuy=type=="buy"?1:0;
 				let data = {isBuy:isBuy,cartNum:this.specNum,productId:this.productValueSelect.productId,attrValueId:this.productValueSelect.id};
+				if(this.voucherPreparation==1){
+					uni.showLoading({
+						title: '提交中'
+					})
+				}
 				addCart(data).then(
 					res => {
 						if(res.code==200){
@@ -288,16 +294,20 @@
 								uni.navigateTo({
 									url: '/pages/shopping/confirmOrder?type='+this.type+"&cartIds="+res.id
 								})
-							}
-							else
-							{
+							}else{
 								this.getCartCount()
-								uni.showToast({
-									icon:'success',
-									title: "添加成功",
-								});
+								if(this.voucherPreparation==1) {
+									this.submitgoods(res.id)
+								}else {
+									uni.hideLoading()
+									uni.showToast({
+										icon:'success',
+										title: "添加成功",
+									});
+								}
 							}
 						}else{
+							uni.hideLoading()
 							uni.showToast({
 								icon:'none',
 								title: res.msg,
@@ -306,7 +316,9 @@
 						}
 					},
 					rej => {}
-				);
+				).catch(()=>{
+					uni.hideLoading()
+				});
 			},
 			getProductDetails(){
 				let data = {productId:this.productId};
@@ -386,7 +398,8 @@
 				})
 			},
 			// 加入购物车
-			addCart(type) {
+			addCart(type,voucherPreparation) {
+				this.voucherPreparation = voucherPreparation==1?1:0
 				this.utils.isLogin().then(res => {
 					if(res){
 						this.type=type;

+ 37 - 6
pages_company/storeProductPackage.vue

@@ -58,9 +58,9 @@
 								</view>
 							</view>
 							<view class="btn-box">
-								<view  class="btn pays" @click.stop="showpop(item)">
+							<!-- 	<view  class="btn pays" @click.stop="showpop(item)">
 									绑定用户
-								</view>
+								</view> -->
 								<view  class="btn pay" @click.stop="showDetail(item)">
 									查看详情
 								</view>
@@ -94,7 +94,7 @@
 </template>
 
 <script>
-	import {getStoreProductPackage,sendPackage} from '@/api/storeProductPackage.js'
+	import {getStoreProductPackage,sendPackage,getPackagCateList} from '@/api/storeProductPackage.js'
 	import {sendCoupon,searchUser} from '@/api/coupon'
 	import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
 	export default {
@@ -107,10 +107,15 @@
 				cateId:0,
 				searchKey:"",
 				mescroll:null,
+				downOption: {   //下拉刷新
+				 	use:true,
+					auto: false // 不自动加载 (mixin已处理第一个tab触发downCallback)
+				},
 				// 上拉加载的配置
 				upOption: {
 					onScroll:true,
 					use: true, // 是否启用上拉加载; 默认true
+					auto: false,
 					page: {
 						num: 0, // 当前页码,默认0,回调之前会加1,即callback(page)会从1开始
 						size: 10 // 每页数据的数量,默认10
@@ -138,11 +143,37 @@
 			})
 			this.companyId=options.companyId;
 			this.companyUserId=options.companyUserId;
-			this.cates=this.utils.getDict("storeProductPackageCate");
+			// this.cates=this.utils.getDict("storeProductPackageCate");
 			this.CompanyUserInfo=uni.getStorageSync('CompanyUserInfo');
 			this.user=uni.getStorageSync('userInfo');
+			this.getPackagCateList()
 		},	
+		onUnload() {
+			uni.$off('refreshOrder')
+		},
 		methods: {
+			getPackagCateList(type){
+				var data={
+					companyUserToken:uni.getStorageSync('CompanyUserToken'),
+					appId:wx.getAccountInfoSync().miniProgram.appId
+				}
+				var that=this;
+				getPackagCateList(data).then(
+					res => {
+						if(res.code==200&&res.data&&res.data.length>0){
+							this.cates=res.data;
+							this.cateId = res.data[0].dictValue;
+							this.mescroll&&this.mescroll.resetUpScroll()
+						}else {
+							this.cateId = 0
+							this.dataList = []
+						}
+					},
+					err => {
+					}
+				);
+				
+			},
 			searchkey(value){
 				  console.log(this.keyword);
 				  searchUser({value:this.keyword}).then(res=>{
@@ -295,8 +326,8 @@
 					text-align: center;
 					border-radius: 32upx;
 					margin-left: 15upx;
-					border: 1px solid red;
-					color: red;
+					border: 1px solid #2BC7B9;
+					color: #2BC7B9;
 				}
 			}
 		}

+ 1 - 1
pages_shopping/live/confirmCreateOrder.vue

@@ -234,7 +234,7 @@
 			// });
 		},
 		onUnload() {
-			uni.$off('updateAddress', this.handleAddressUpdate);
+			uni.$off('updateAddress');
 		},
 		beforeDestroy() {
 			uni.$off('updateAddress');

+ 3 - 0
pages_shopping/shopping/confirmCreateOrder.vue

@@ -193,6 +193,9 @@
 			})
 			this.getWeixinOrderTemps();
 		},
+		onUnload() {
+			uni.$off('updateAddress')
+		},
 		methods: {
 			getWeixinOrderTemps:function(){
 				getWeixinOrderTemps().then(

+ 2 - 2
pages_shopping/shopping/confirmPackageOrder.vue

@@ -165,8 +165,8 @@
 			})
 			this.getWeixinTemps();
 		},
-		onShow() {
-			
+		onUnload() {
+			uni.$off('updateAddress')
 		},
 		methods: {
 			getWeixinTemps:function(){

+ 3 - 3
pages_shopping/shopping/coupon.vue

@@ -325,11 +325,11 @@ page {
   	margin-left: 15upx;
 
   	&.cancel{
-  		border: 1px solid red;
-  		color: red;
+  		border: 1px solid #2BC7B9;
+  		color: #2BC7B9;
   	}
   	&.receive{
-  		background: red;
+  		background: #2BC7B9;
   		color: #FFFFFF;
   	}
   }