lhl 1 день тому
батько
коміт
2ea11f50a1

+ 8 - 0
api/user.js

@@ -1,5 +1,13 @@
 import request from '@/utils/request'
 
+
+export function getJxsInfo() {
+	return request({
+		url: '/api/dealer/stock_dashboard',
+		method: 'get',
+	});
+}
+
 // 订单统计信息
 export function orderData(data) {
 	return request({

+ 77 - 6
manifest.json

@@ -1,7 +1,7 @@
 {
-    "name" : "侍草堂",
-    "appid" : "__UNI__984C459",
-    "description" : "侍草堂",
+    "name" : "青圃汇鑫选",
+    "appid" : "__UNI__CD7E6F5",
+    "description" : "青圃汇鑫选",
     "versionName" : "1.1.5",
     "versionCode" : 115,
     "transformPx" : false,
@@ -18,7 +18,8 @@
         "modules" : {
             "Barcode" : {},
             "Camera" : {},
-            "VideoPlayer" : {}
+            "VideoPlayer" : {},
+            "Geolocation" : {}
         },
         /* 模块配置 */
         "distribute" : {
@@ -49,7 +50,11 @@
             "sdkConfigs" : {
                 "maps" : {},
                 "oauth" : {},
-                "geolocation" : {},
+                "geolocation" : {
+                    "system" : {
+                        "__platform__" : [ "ios", "android" ]
+                    }
+                },
                 "payment" : {},
                 "push" : {},
                 "share" : {},
@@ -89,6 +94,9 @@
                     }
                 }
             }
+        },
+        "uniStatistics" : {
+            "enable" : true
         }
     },
     /* SDK配置 */
@@ -104,7 +112,7 @@
         }
     },
     "h5" : {
-        "title" : "侍草堂",
+        "title" : "青圃汇鑫选",
         "domain" : "",
         "router" : {
             "base" : "/index/",
@@ -128,6 +136,69 @@
                     "key" : "CDGBZ-4EVCX-IBU4A-ZAKEJ-VWDEE-7BBGT"
                 }
             }
+        },
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "uniStatistics" : {
+        "version" : "2",
+        "type" : "private",
+        "enable" : true
+    },
+    "mp-baidu" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-toutiao" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-qq" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-kuaishou" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-lark" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-xhs" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-jd" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "quickapp-webview-huawei" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "quickapp-webview-union" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "mp-harmony" : {
+        "uniStatistics" : {
+            "enable" : true
+        }
+    },
+    "app-harmony" : {
+        "uniStatistics" : {
+            "enable" : true
         }
     }
 }

+ 8 - 2
pages.json

@@ -2,7 +2,7 @@
 	"pages": [{
 			"path": "pages/index/index",
 			"style": {
-				"navigationBarTitleText": "侍草堂",
+				"navigationBarTitleText": "青圃汇鑫选",
 				"navigationStyle": "custom"
 			}
 		},
@@ -224,6 +224,12 @@
 				"navigationBarTitleText": "个人中心"
 			}
 		},
+		{
+			"path": "pages/user/jxs",
+			"style": {
+				"navigationBarTitleText": "经销商中心"
+			}
+		},
 		// {
 		// 	"path": "pages/user/jf",
 		// 	"style": {
@@ -475,7 +481,7 @@
 	],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
-		"navigationBarTitleText": "侍草堂",
+		"navigationBarTitleText": "青圃汇鑫选",
 		"navigationBarBackgroundColor": "#FFFFFF",
 		"backgroundColor": "#f8f8f8"
 	},

+ 1 - 0
pages/money/pay.vue

@@ -247,6 +247,7 @@ export default {
 			let prepage = obj.$api.prePage();
 
 			let data = {
+				spread_uid: prepage.uid ? prepage.uid: '',
 				is_one: prepage.is_one,
 				is_level: prepage.is_level,
 				is_pack: prepage.is_pack,//是否礼包商品

+ 13 - 1
pages/order/createOrder.vue

@@ -223,6 +223,7 @@
 	export default {
 		data() {
 			return {
+				isjxs: 0,
 				real_name: '',
 				phone:'',
 				is_integral: 0,
@@ -282,12 +283,19 @@
 				is_pick: 0,
 				store_id: 0,
 				yfmodel: 0,
+				uid: ''
 			};
 		},
 		onLoad(option) {
 			if(option.is_pick) {
 				this.is_pick = option.is_pick
 			}
+			if(option.isjxs) {
+				this.isjxs = option.isjxs
+			}
+			if(option.uid) {
+				this.uid = option.uid
+			}
 			// 判断是否为拼团商品
 			if (option.type == 'pink') {
 				this.pinkid = option.pinkId;
@@ -436,7 +444,8 @@
 			loadData() {
 				let obj = this;
 				confirm({
-					cartId: obj.cartId + ''
+					cartId: obj.cartId + '',
+					dealer_pickup: obj.isjxs
 				}).then(({
 					data
 				}) => {
@@ -494,6 +503,9 @@
 				if (this.pinkid) {
 					url += '&pinkid=' + this.pinkid
 				}
+				if(this.uid) {
+					url += "&uid=" + this.uid
+				}
 				uni.navigateTo({
 					url
 				});

+ 51 - 15
pages/product/product.vue

@@ -99,7 +99,7 @@
 					<text>{{ item.attr_name }}</text>
 					<view class="item-list">
 						<text v-for="(childItem, childIndex) in item.attr_value" :key="childIndex" class="tit"
-							:class="{ selected: childItem.check }" @click="selectSpec(childItem, item, index)">
+							:class="{ selected: childItem.check }" @click="suk ? '':selectSpec(childItem, item, index)">
 							{{ childItem.attr }}
 						</text>
 					</view>
@@ -162,6 +162,9 @@
 		},
 		data() {
 			return {
+				suk: '',
+				stock: 0,
+				uid: '',
 				isfg: 0,
 				details: '',
 				reply: '', //评论
@@ -215,6 +218,7 @@
 				is_bk: 0,
 				is_xf: 0,
 				goodIntegral: 0, //需要使用的积分
+				spread: '',
 			};
 		},
 		async onLoad(options) {
@@ -228,13 +232,23 @@
 			if (options.is_xf) {
 				obj.is_xf = options.is_xf
 			}
+			if(options.suk) {
+				this.suk = options.suk
+			}
+			if(options.stock) {
+				this.stock = options.stock
+			}
 			//保存商品id
 			this.goodsid = options.id;
 			// 判断有无人邀请
 			if (options.spread) {
+				this.spread = options.spread
 				// 存储邀请人
 				uni.setStorageSync('spread', options.spread);
 			}
+			if(options.uid) {
+				this.uid = options.uid
+			}
 			// 判断是否为秒杀商品
 			if (options.type == 1) {
 				// 保存商品类型
@@ -323,6 +337,9 @@
 					obj.actionPrice = goods.price;
 					obj.actionImage = goods.image_base; //保存默认选中商品价格
 					obj.goodsNumberMax = goods.stock; //保存默认选中最大可购买商品数量
+					if(obj.suk) {
+						obj.goodsNumberMax = Number(obj.stock); //保存默认选中最大可购买商品数量
+					}
 					obj.shopId = data.mer_id; //保存商店id
 					console.log(obj.goodsObjact.is_pack, 'v');
 					if (obj.goodsObjact.is_pack == 1 || obj.goodsObjact.is_one == 1) {
@@ -333,21 +350,33 @@
 					obj.shareDate();
 					// #endif
 					// 保存默认选中的对象
-					obj.specSelected = []; //初始化默认选择对象
-					for (let i = 0; i < obj.specList.length; i++) {
-						// 设置默认数据
-						let attrValue = obj.specList[i].attr_value[0];
-						attrValue.check = true;
-						obj.specSelected.push(attrValue.attr);
+					
+					if(obj.suk) {
+						let arr = obj.suk.split(',')
+						arr.forEach((item,index) => {
+							obj.selectSpec({attr: item,check: true},obj.specList[index],index)
+						})
+						obj.actionImage = obj.productValue[obj.suk].image;
+						obj.uniqueId = obj.productValue[obj.suk].unique;
+						obj.goodIntegral = obj.productValue[obj.suk].integral
+					}else {
+						obj.specSelected = []; //初始化默认选择对象
+						for (let i = 0; i < obj.specList.length; i++) {
+							// 设置默认数据
+							let attrValue = obj.specList[i].attr_value[0];
+							attrValue.check = true;
+							obj.specSelected.push(attrValue.attr);
+						}
+						
+						//保存默认选中的对象字符串名称
+						let str = obj.specSelected.join(',');
+						
+						// 设置默认值
+						obj.actionImage = obj.productValue[str].image;
+						obj.uniqueId = obj.productValue[str].unique;
+						obj.goodIntegral = obj.productValue[str].integral
 					}
 
-					//保存默认选中的对象字符串名称
-					let str = obj.specSelected.join(',');
-					// 设置默认值
-					obj.actionImage = obj.productValue[str].image;
-					obj.uniqueId = obj.productValue[str].unique;
-					obj.goodIntegral = obj.productValue[str].integral
-
 					
 				});
 			},
@@ -394,9 +423,13 @@
 			},
 			//选择规格
 			selectSpec(item, arr, ind) {
+				console.log(item, arr, ind,'++++++++++');
 				let obj = this
 				arr.attr_value.forEach(function(e) {
 					e.check = false;
+					if(obj.suk && e.attr == obj.suk) {
+						e.check = true;
+					}
 				});
 				item.check = true;
 				this.specSelected[ind] = item.attr;
@@ -419,6 +452,9 @@
 				if (obj.goodsObjact.is_pack == 1 || obj.goodsObjact.is_one == 1) {
 					this.goodsNumberMax = 1;
 				}
+				if(obj.suk) {
+					this.goodsNumberMax = Number(obj.stock);
+				}
 			},
 			//分享
 			share() {
@@ -503,7 +539,7 @@
 									// 跳转到支付页
 									uni.navigateTo({
 										url: '/pages/order/createOrder?id=' + data.cartId + '&goodsType=' + obj
-											.goodsType + '&is_pick=' + obj.goodsObjact.is_pick + '&store_id=' + (obj.storeObjact.id || 0)
+											.goodsType + '&is_pick=' + obj.goodsObjact.is_pick + '&store_id=' + (obj.storeObjact.id || 0) + '&uid=' + (obj.uid || obj.spread) + '&isjxs=' + (obj.suk ? 1: 0)
 									});
 								}
 								if (obj.type == 2) {

+ 1 - 1
pages/user/award.vue

@@ -13,7 +13,7 @@
 			</view>
 			<view class="moneybtn-box" >
 				<!-- 佣金转余额 -->
-				<view class="money-btn" @click="navto('/pages/user/yjzye?type=1')"></view>
+				<view class="money-btn" @click="navto('/pages/user/yjzye?type=1')">佣金转余额</view>
 				<!-- 佣金提现 -->
 				<view class="money-btn"  @click="navto('/pages/user/withdrawal')">佣金提现</view>
 			</view>

+ 197 - 0
pages/user/jxs.vue

@@ -0,0 +1,197 @@
+<template>
+	<view class="jxs-page">
+		<view class="header-info">
+			进货总金额:{{jxsInfo.total_purchase}}
+		</view>
+		<view class="stock-list">
+			<view class="stock-card" v-for="item in jxsInfo.stock_list" @click="goItem(item)">
+				<view class="product-image-wrapper">
+					<image class="product-image" :src="item.product_image" mode="aspectFill"></image>
+				</view>
+				<view class="product-info">
+					<view class="product-name">{{item.product_name}}</view>
+					<view class="product-stock">
+						库存:{{item.remaining_quantity}}
+					</view>
+					<view class="product-spec">
+						规格:{{item.suk}}
+					</view>
+				</view>
+				<view class="promo-btn">
+					<view class="promo-btn-text" @click.stop="showCode(item)">推广码</view>
+				</view>
+			</view>
+		</view>
+		<uni-popup type="center" ref="code">
+			<view class="code-popup">
+				<view class="code-title">推广码</view>
+				<ikun-qrcode width="300" height="300" unit="rpx" :data="code" />
+				<view class="code-close" @click="closeCode">关闭</view>
+			</view>
+		</uni-popup>
+	</view>
+</template>
+
+<script>
+	import {
+		getJxsInfo
+	} from '@/api/user.js'
+	import {
+		mapState
+	} from 'vuex'
+	export default {
+		data() {
+			return {
+				code: '',
+				jxsInfo: {
+					dealer_level_grade: 0,
+					dealer_level_name: '',
+					dealer_name: '',
+					stock_list: [],
+					total_purchase: ''
+				}
+			}
+		},
+		computed: {
+			...mapState(['baseURL']),
+			...mapState('user', ['userInfo'])
+		},
+		methods: {
+			goItem(item) {
+				uni.navigateTo({
+					url:'/pages/product/product?id=' + item.product_id + '&suk=' + item.suk + '&stock=' + item.remaining_quantity + '&attr=' + item.attr_unique
+				})
+			},
+			getJxsInfo() {
+				getJxsInfo().then(res => {
+					this.jxsInfo = res.data
+				})
+			},
+			showCode(item) {
+				this.code = this.baseURL + '/index/#/pages/product/product?id=' + item.product_id + '&uid=' + this.userInfo
+					.uid
+				this.$refs.code.open()
+			},
+			closeCode() {
+				this.$refs.code.close()
+			}
+		},
+		onLoad() {
+			this.getJxsInfo()
+		}
+	}
+</script>
+
+<style scoped>
+	.jxs-page {
+		background-color: #f5f5f5;
+		padding: 20rpx;
+		box-sizing: border-box;
+	}
+
+	.header-info {
+		background-color: #fff;
+		padding: 30rpx;
+		border-radius: 16rpx;
+		font-size: 32rpx;
+		color: #333;
+		margin-bottom: 20rpx;
+	}
+
+	.stock-list {
+		display: flex;
+		flex-wrap: wrap;
+		gap: 20rpx;
+	}
+
+	.stock-card {
+		width: calc(50% - 10rpx);
+		background-color: #fff;
+		border-radius: 16rpx;
+		overflow: hidden;
+		display: flex;
+		flex-direction: column;
+	}
+
+	.product-image-wrapper {
+		position: relative;
+		width: 100%;
+		padding-bottom: 100%;
+	}
+
+	.product-image {
+		position: absolute;
+		top: 0;
+		left: 0;
+		width: 100%;
+		height: 100%;
+	}
+
+	.product-info {
+		padding: 20rpx;
+		flex: 1;
+		display: flex;
+		flex-direction: column;
+		gap: 12rpx;
+	}
+
+	.product-name {
+		font-size: 28rpx;
+		color: #333;
+		font-weight: 500;
+		display: -webkit-box;
+		-webkit-box-orient: vertical;
+		-webkit-line-clamp: 2;
+		overflow: hidden;
+	}
+
+	.product-stock {
+		font-size: 24rpx;
+		color: #999;
+	}
+
+	.product-spec {
+		font-size: 24rpx;
+		color: #999;
+	}
+
+	.promo-btn {
+		background-color: #FF6B6B;
+		padding: 20rpx;
+		text-align: center;
+		margin-top: auto;
+	}
+
+	.promo-btn-text {
+		font-size: 28rpx;
+		color: #fff;
+		font-weight: 500;
+	}
+
+	.code-popup {
+		background-color: #ffffff;
+		border-radius: 24rpx;
+		padding: 50rpx 60rpx;
+		display: flex;
+		flex-direction: column;
+		align-items: center;
+		gap: 40rpx;
+		width: 520rpx;
+		box-shadow: 0 10rpx 40rpx rgba(0, 0, 0, 0.15);
+	}
+
+	.code-title {
+		font-size: 36rpx;
+		color: #333333;
+		font-weight: 600;
+	}
+
+	.code-close {
+		font-size: 28rpx;
+		color: #999999;
+		margin-top: 10rpx;
+		padding: 20rpx 80rpx;
+		border: 1rpx solid #e5e5e5;
+		border-radius: 40rpx;
+	}
+</style>

+ 5 - 1
pages/user/user.vue

@@ -89,7 +89,11 @@
 					<image class="oitem-image" src="../../static/user/s5.png" mode=""></image>
 					<view class="oitem-font">代理入口</view>
 				</view>
-				<view class="oitem" @click="openKf()">
+				<view class="oitem"  @click="navTo('/pages/user/jxs')" v-if="userInfo && userInfo.uid && userInfo.dealer == 1">
+					<image class="oitem-image" src="../../static/user/s7.png" mode=""></image>
+					<view class="oitem-font">经销商入口</view>
+				</view>
+				<view class="oitem" @click="navTo('/pages/set/userinfo')">
 					<image class="oitem-image" src="../../static/user/s6.png" mode=""></image>
 					<view class="oitem-font">设置</view>
 				</view>

+ 1 - 0
pages/user/yjzye.vue

@@ -63,6 +63,7 @@
 			this.weichatBsrowser = uni.getStorageSync('weichatBrowser');
 			// #endif
 			this.dataUp();
+			this.type = options.type
 			if(options.type == 1) {
 				uni.setNavigationBarTitle({
 					title: '佣金转余额'

BIN
static/user/s7.png


+ 40 - 0
uni_modules/ikun-qrcode/changelog.md

@@ -0,0 +1,40 @@
+## 1.0.20(2026-06-26)
+docs: 文档格式修复
+## 1.0.19(2026-06-25)
+docs: 上线组件预览渠道,请查看下方文档
+## 1.0.18(2026-03-20)
+docs:不支持uniapp-x, 近期没有适配计划,已更新到说明文档。
+## 1.0.17(2025-10-23)
+chore: 增加开源地址
+## 1.0.16(2025-07-10)
+doc:整理文档
+## 1.0.15(2025-07-04)
+doc: unit字段 只支持rpx,px,为了兼容nvue。
+## 1.0.14(2025-04-28)
+doc: 文档更新
+## 1.0.13(2025-04-28)
+feat: 添加中间的logo图片
+## 1.0.12(2025-04-22)
+修复微信小程序rpx计算误差,使用vw来代替
+## 1.0.11(2025-04-14)
+docs: 不支持canvas相关的属性,如保存。
+## 1.0.10(2024-10-16)
+优化markdown排版
+## 1.0.9(2024-10-16)
+更新微信小程序在各平台测试结果
+## 1.0.8(2024-10-16)
+ipados 18.0微信小程序发行正式版,测试可以正常出二维码。 (PS: 如果一直转圈动画,排查你的url变量是否为空,是否被微信拦截了接口数据)、 
+## 1.0.7(2024-08-02)
+fix: cssName修复
+## 1.0.6(2024-08-01)
+修复README.md
+## 1.0.5(2024-08-01)
+README新增:vue2,vue3详细用法
+## 1.0.4(2024-08-01)
+更新vue2,vue3详细用法
+## 1.0.3(2024-08-01)
+更新vue2/vue3详细用法
+## 1.0.0版本
+极简的二维码生成组件,vue2 / vue3 可用. 100行搞定。
+### 特点
+- 使用基础的view来生成二维码的点,而不是canvas,避免带来层级问题。

Різницю між файлами не показано, бо вона завелика
+ 6 - 0
uni_modules/ikun-qrcode/components/ikun-qrcode/ikun-qrcode.vue


Різницю між файлами не показано, бо вона завелика
+ 33 - 0
uni_modules/ikun-qrcode/components/ikun-qrcode/uqrcode_latest.js


+ 100 - 0
uni_modules/ikun-qrcode/package.json

@@ -0,0 +1,100 @@
+{
+  "id": "ikun-qrcode",
+  "displayName": "【ikun-qrcode】极简的二维码生成组件,使用view而非canvas避免层级问题",
+  "version": "1.0.20",
+  "description": "ikun-qrcode,极简的二维码生成组件,使用view而非canvas避免层级问题",
+  "keywords": [
+    "ikun-qrcode",
+    "qrcode",
+    "二维码"
+],
+  "repository": "https://github.com/ikun-ui-uniapp/ikun-qrcode.git",
+  "engines": {
+    "HBuilderX": "^3.97",
+    "uni-app": "^3.7.12",
+    "uni-app-x": ""
+  },
+  "dcloudext": {
+    "type": "component-vue",
+    "sale": {
+      "regular": {
+        "price": "0.00"
+      },
+      "sourcecode": {
+        "price": "0.00"
+      }
+    },
+    "contact": {
+      "qq": ""
+    },
+    "declaration": {
+      "ads": "无",
+      "data": "插件不采集任何数据",
+      "permissions": "无"
+    },
+    "npmurl": "",
+    "darkmode": "x",
+    "i18n": "x",
+    "widescreen": "√"
+  },
+  "uni_modules": {
+    "dependencies": [],
+    "encrypt": [],
+    "platforms": {
+      "cloud": {
+        "tcb": "√",
+        "aliyun": "√",
+        "alipay": "√"
+      },
+      "client": {
+        "uni-app": {
+          "vue": {
+            "vue2": "√",
+            "vue3": "√"
+          },
+          "web": {
+            "safari": "√",
+            "chrome": "√"
+          },
+          "app": {
+            "vue": "√",
+            "nvue": "√",
+            "android": "√",
+            "ios": "√",
+            "harmony": "√"
+          },
+          "mp": {
+            "weixin": "√",
+            "alipay": "√",
+            "toutiao": "√",
+            "baidu": "√",
+            "kuaishou": "√",
+            "jd": "√",
+            "harmony": "√",
+            "qq": "√",
+            "lark": "√",
+            "xhs": "-"
+          },
+          "quickapp": {
+            "huawei": "√",
+            "union": "√"
+          }
+        },
+        "uni-app-x": {
+          "web": {
+            "safari": "-",
+            "chrome": "-"
+          },
+          "app": {
+            "android": "-",
+            "ios": "-",
+            "harmony": "-"
+          },
+          "mp": {
+            "weixin": "-"
+          }
+        }
+      }
+    }
+  }
+}

Різницю між файлами не показано, бо вона завелика
+ 43 - 0
uni_modules/ikun-qrcode/readme.md


Деякі файли не було показано, через те що забагато файлів було змінено