zhengkaixin 1 năm trước cách đây
mục cha
commit
9cc75b9040

+ 1 - 1
.env.dev.js

@@ -30,7 +30,7 @@ const UNI_APP = {
 	//openId:"oK9Wr5zv8lvirni3txbxRkmpg8d0",//sz
 	//小鹏管家appid
 	//VUE_APP_WXAPPID:"wx7e70eb62a8459869",
-	branchParameter:"team51",//team51,youdian
+	branchParameter:"51team",//team51,youdian
 	VUE_APP_WXAPPID:"wx3afdb1b60188c1e5",//51
 	//VUE_APP_WXAPPID:"wxca33ab204e738ca4",//youdian
 	VUE_APP_ALIAPPID:"2021003131641247",

+ 3 - 10
.env.dev.youdian.js

@@ -18,16 +18,9 @@ const UNI_APP = {
 	gzUrl:"https://mp.weixin.qq.com/s/syLTJR69MWZY-D4ewa_1og",
 	
 	wechatUrl:"/youdian",
-	openId:"oK9Wr54VbEh3xvWYmD_zT5NbH4AY",//zkx
-	openId:"oK9Wr59rru-i3bm7dtTtxnkR-i4s",//杨所
-	//openId:"oK9Wr56vX9nP_B56_Pyigg5n5Ce8",//
-	//openId:"oK9Wr5_2USr1yP4MRew9KbJA0-ng",//老板
-	//openId:"oK9Wr5-ViXQMUP2cjiW3bGIABj1Q",
-	//openId:"oK9Wr5wkU3OwWhQ7mRrLZ5MDZNHo",
-	//openId:"oK9Wr53qHzp7kOSiue_PYjwEqivM",
-	//openId:"oK9Wr55J1J1eL6BqI2tW749NTxNU",//zq
-	//openId:"oK9Wr50iQUjEAam1s_RpHpXJS5xg",//月卡用户
-	//openId:"oK9Wr5zv8lvirni3txbxRkmpg8d0",//sz
+	openId:"oSruR6YkhP7QDroLnZGxWis43Kn0",//zkx
+	//openId:"oK9Wr59rru-i3bm7dtTtxnkR-i4s",//杨所
+ 
 	//小鹏管家appid
 	//VUE_APP_WXAPPID:"wx7e70eb62a8459869",
 	branchParameter:"youdian",//team51,youdian

+ 17 - 17
.env.js

@@ -14,29 +14,29 @@
 		
 		
     } else if (process.env.NODE_ENV === "production") {  
-		if(NODE_NAME=="test"){
-			if("youdian"==branchParameter){
-				ENV_VAR = require(`.env.test.youdian.js`); 
-			}else if("team51"==branchParameter){
-				ENV_VAR = require(`.env.test.js`); 
-			}else{
-				ENV_VAR = require(`.env.test.js`); 
+		if(NODE_NAME=="test"){
+			if("youdian"==branchParameter){
+				ENV_VAR = require(`.env.test.youdian.js`); 
+			}else if("51team"==branchParameter){
+				ENV_VAR = require(`.env.test.js`); 
+			}else{
+				ENV_VAR = require(`.env.test.js`); 
 			}
 			
-		}else if(NODE_NAME=="production"){
+		}else if(NODE_NAME=="production"){
 			
-			if("youdian"==branchParameter){
-				ENV_VAR = require(`.env.prod.youdian.js`); 
-			}else if("team51"==branchParameter){
-				ENV_VAR = require(`.env.prod.js`); 
-			}else{
-				ENV_VAR = require(`.env.prod.js`); 
-			}
+			if("youdian"==branchParameter){
+				ENV_VAR = require(`.env.prod.youdian.js`); 
+			}else if("51team"==branchParameter){
+				ENV_VAR = require(`.env.prod.js`); 
+			}else{
+				ENV_VAR = require(`.env.prod.js`); 
+			}
 			
 		} else  {  
 			ENV_VAR = require('.env.prod.js');  
-		} 
-		
+		} 
+		
 		
     }  
 

+ 1 - 1
.env.prod.js

@@ -5,7 +5,7 @@ const UNI_APP = {
 	XPGJ_URL: 'https://xpgjapi.xiaoxinda.com/' ,
 		
 	defaultStation:["3865b3a3-13fd-461a-8145-ee9711df35a2"],
-	branchParameter:"team51",//team51,youdian
+	branchParameter:"51team",//team51,youdian
 	gzUrl:"https://mp.weixin.qq.com/s/mCHz1nNvg0xAICiBeIyKRQ",
 	 wechatUrl:"/wechat",
 	NODE_ENV :"prod",

+ 1 - 1
.env.test.js

@@ -8,7 +8,7 @@ const UNI_APP = {
    defaultStation:["3865b3a3-13fd-461a-8145-ee9711df35a2"],
    gzUrl:"https://mp.weixin.qq.com/s/mCHz1nNvg0xAICiBeIyKRQ",
    wechatUrl:"/wechat",
-	branchParameter:"team51",//team51,youdian
+	branchParameter:"51team",//team51,youdian
 	NODE_ENV :"test",
 	SIMPLE_RUN:false,
 	//openId:"oHjCawigqi8SEAwutwkQ-VEgdp3k",//测试用openId

BIN
assets/img/9-4/联盟会员ud.jpg


BIN
assets/img/commodity1.png


BIN
assets/img/commodity2.png


BIN
assets/img/commodity3.png


BIN
assets/img/commodity4.png


BIN
assets/img/shopimg/1.png


BIN
assets/img/shopimg/2.png


BIN
assets/img/shopimg/3.png


BIN
assets/img/shopimg/4.png


BIN
assets/img/storeBanner1.png


BIN
assets/static/img/aboutusUd.jpg


+ 0 - 10
assets/static/img/logo.svg

@@ -1,10 +0,0 @@
-<svg width="120" height="120" viewBox="0 0 120 120" fill="none" xmlns="http://www.w3.org/2000/svg">
-<path d="M90.29 109.87H20L22.76 93.33H31.92L37.92 63.76C35.49 63.76 34.12 63.81 28.47 63.81L34.29 29.27C35.0376 29.3343 35.7907 29.2769 36.52 29.1C42.4194 27.5758 48 25.0124 53 21.53C57.1536 18.8668 60.618 15.2585 63.11 11L99.11 11L84.4 93.33H93.05L90.29 109.87Z" fill="url(#paint0_linear_1594_783)"/>
-<path d="M94.1598 39.24L94.8598 35.38H74.7798L76.1898 27.64H53.5698L52.1598 35.38L51.4598 39.24L47.4698 61.16L46.5298 66.32H59.8398L53.7298 99.84L87.3898 61.16H70.0898L74.0798 39.24H94.1598Z" fill="white"/>
-<defs>
-<linearGradient id="paint0_linear_1594_783" x1="29.5" y1="55.13" x2="97.82" y2="67.18" gradientUnits="userSpaceOnUse">
-<stop stop-color="#4891F9"/>
-<stop offset="0.73" stop-color="#31C15E"/>
-</linearGradient>
-</defs>
-</svg>

BIN
assets/static/img/logo3Ud.png


BIN
assets/static/img/logoUd.png


+ 8 - 2
main.js

@@ -177,11 +177,17 @@ Vue.mixin({
 		if (option.test == 'test') {
 			let vConsole = new Vconsole()
 		}
-		this.projectName = process.car.ProjectName;
+		this.projectName = process.car.ProjectName;
+		this.branchParameter=process.car.branchParameter;
 	},
 	
 	methods: {
-		
+		branchParameterBl(val){
+			if(val=="ud"||val=="youdian"){
+				return this.branchParameter=="youdian"
+			}
+			return this.branchParameter=="51team"
+		},
 		setValidity(periodOfValidity){
 			if(periodOfValidity<=365){
 				return periodOfValidity+'天';

+ 64 - 64
package.json

@@ -1,66 +1,66 @@
-{
-	"scripts": {
-		"test:h5": "cross-env UNI_PLATFORM=h5 jest -i",
-		"serve": "vue-cli-service serve",
-		"build": "vue-cli-service build",
-		"test": "vue-cli-service build --mode test"
-	},
-	"dependencies": {
-		"compression-webpack-plugin": "^8.0.1",
-
-		"echarts": "^5.3.2",
-		"qrcodejs2": "^0.0.2",
-		"remixicon": "^2.5.0",
-		"sass-mixins-variables": "^1.1.0",
-		"uni-crazy-router": "0.0.31",
-		"uni-simple-router": "^2.0.1",
-		"uview-ui": "^1.8.4",
-		"vconsole": "^3.4.0",
-		"vue-cli": "^2.9.6",
-		"vue-cropper": "^0.5.6",
-		"vuex": "^3.6.2",
-		"weixin-js-sdk": "^1.6.0"
-	},
-	"devDependencies": {
-		"@vue/cli-plugin-babel": "^4.0.0",
-		"@vue/cli-plugin-eslint": "^4.0.0",
-		"@vue/cli-service": "^4.0.0",
-		"babel-eslint": "^10.0.3",
-		"eslint": "^5.16.0",
-		"eslint-plugin-vue": "^5.0.0",
-		"node-sass": "^5.0.0",
-		"sass-loader": "^11.0.1",
-		"vue-template-compiler": "^2.6.10"
-	},
-	"uni-app": {
-		"scripts": {
-			"test-platform": {
-				"title": "test",
-				"BROWSER": "Chrome",
-				"env": {
-					"UNI_PLATFORM": "h5",
+{
+	"scripts": {
+		"test:h5": "cross-env UNI_PLATFORM=h5 jest -i",
+		"serve": "vue-cli-service serve",
+		"build": "vue-cli-service build",
+		"test": "vue-cli-service build --mode test"
+	},
+	"dependencies": {
+		"compression-webpack-plugin": "^8.0.1",
+
+		"echarts": "^5.3.2",
+		"qrcodejs2": "^0.0.2",
+		"remixicon": "^2.5.0",
+		"sass-mixins-variables": "^1.1.0",
+		"uni-crazy-router": "0.0.31",
+		"uni-simple-router": "^2.0.1",
+		"uview-ui": "^1.8.4",
+		"vconsole": "^3.4.0",
+		"vue-cli": "^2.9.6",
+		"vue-cropper": "^0.5.6",
+		"vuex": "^3.6.2",
+		"weixin-js-sdk": "^1.6.0"
+	},
+	"devDependencies": {
+		"@vue/cli-plugin-babel": "^4.0.0",
+		"@vue/cli-plugin-eslint": "^4.0.0",
+		"@vue/cli-service": "^4.0.0",
+		"babel-eslint": "^10.0.3",
+		"eslint": "^5.16.0",
+		"eslint-plugin-vue": "^5.0.0",
+		"node-sass": "^5.0.0",
+		"sass-loader": "^11.0.1",
+		"vue-template-compiler": "^2.6.10"
+	},
+	"uni-app": {
+		"scripts": {
+			"test-platform": {
+				"title": "test",
+				"BROWSER": "Chrome",
+				"env": {
+					"UNI_PLATFORM": "h5",
 					"NODE_NAME": "test",
-					"branchParameter":"team51",
-					"envjs":""
-				},
-				"define": {
-					"CUSTOM-CONST": true,
-					"NODE_NAME_T": "test-TEAM51"
-				}
-			},
-			"production-platform": {
-				"title": "production",
-				"BROWSER": "Chrome",
-				"env": {
-					"UNI_PLATFORM": "h5",
+					"branchParameter":"51team",
+					"envjs":""
+				},
+				"define": {
+					"CUSTOM-CONST": true,
+					"NODE_NAME_T": "test-TEAM51"
+				}
+			},
+			"production-platform": {
+				"title": "production",
+				"BROWSER": "Chrome",
+				"env": {
+					"UNI_PLATFORM": "h5",
 					"NODE_NAME": "production",
-					"branchParameter":"team51",
-					"envjs":""
-				},
-				"define": {
-					"CUSTOM-CONST": true,
-					"NODE_NAME_T": "production-TEAM51"
-				}
+					"branchParameter":"51team",
+					"envjs":""
+				},
+				"define": {
+					"CUSTOM-CONST": true,
+					"NODE_NAME_T": "production-TEAM51"
+				}
 			},
 			"test-platform-youdian": {
 				"title": "test-youdian",
@@ -89,7 +89,7 @@
 					"CUSTOM-CONST": true,
 					"NODE_NAME_T": "production-youdian"
 				}
-			}
-		}
-	}
+			}
+		}
+	}
 }

+ 14 - 2
pages/article/details.vue

@@ -4,7 +4,7 @@
 		<view class="main">
 			
 			
-			<view class="news-content" v-html="newsDetail.value">
+			<view class="news-content" v-html="newsDetailValue">
 				 
 			</view>
 		</view>
@@ -18,7 +18,9 @@
 		data() {
 			return {
 				id: '',
-				newsDetail: '',
+				newsDetail: {
+					
+				},
 			}
 		},
 		onLoad(op) {
@@ -26,6 +28,16 @@
 			
 			this.getNewsInfoDetail();
 		},
+		computed:{
+			newsDetailValue(){
+				if(process.car.branchParameter=="youdian"){
+					return this.newsDetail.valueUd
+				}else{
+					return this.newsDetail.value
+				}
+				
+			}
+		},
 		methods: {
 			getNewsInfoDetail() {
 				uni.showLoading({

+ 6 - 3
pages/index/index.vue

@@ -657,7 +657,7 @@
 		</view>
 		<view class="news-title news-title2" v-if="mallList.length">
 			<view class="news-title-left oldTextjp" oldstyle="font-size:20px;">
-				<view class="line" style="margin-top:4px;"></view>51商城
+				<view class="line" style="margin-top:4px;"></view>{{mallTitle}}
 			</view>
 
 			<view class="more oldTextjp2" oldstyle="font-size:16px;" @click="bhz">
@@ -799,7 +799,8 @@
 				loading: false,
 				showTop: false,
 				showTopImg: '',
-				showTopIndex: 0,
+				showTopIndex: 0,
+				mallTitle:"",
 				getBannerInfoTopBl: true,
 				newsListData: [],
 				show: false,
@@ -856,7 +857,9 @@
 			}
 		},
 		onLoad(op) {
-
+			
+			this.mallTitle=process.car.branchParameter=="youdian"?'优电商城':'51商城'
+			
 			if (op.jpcode) {
 				var k = API.codeOperation(op.jpcode)
 				if (k) {

+ 4 - 2
pages/login/welcome.vue

@@ -19,8 +19,10 @@
 				<view slot="error"></view>
 			</u-image>
 			
- 			<view class="welcome-foot">
-				<u-image width="185px" height="48px" src="@/assets/static/img/logo.png"></u-image>
+ 			<view class="welcome-foot">
+				<u-image  v-if="branchParameterBl('ud')" width="185px" height="48px" src="@/assets/static/img/logoUd.png"></u-image>
+				
+				<u-image v-else width="185px" height="48px" src="@/assets/static/img/logo.png"></u-image>
 			</view>
 		
 		</view>

+ 7 - 5
pages/store/51store.vue

@@ -1,6 +1,6 @@
 <template>
 	<view>
-		<ujp-navbar title="51商城"></ujp-navbar>
+		<ujp-navbar :title="title"></ujp-navbar>
 		<!-- 广告-->
 		<!-- <view class="banner">
 			
@@ -13,14 +13,12 @@
 			:img-mode="'scaleToFill'" :list="bannerList" @click="clickBanner"
 				:name="'picUrl'">
 			</u-swiper>
-			<img src="../../assets/img/storeBanner1.png" alt="" v-else >
-			
-		
+
 		</view>
 		<!-- 标签 -->
 		<!-- <view class="banner2">
 			
-			<img src="../../assets/img/storeBanner1.png" alt="">
+			
 			
 			<u-tabs :list="list"  :is-scroll="false" :current="current" @change="change" >
 				
@@ -73,11 +71,15 @@
 		data() {
 			return {
 				mallList:[],
+				title:"",
 				bannerList: [],
 				pageIndex: 1,
 				recordsTotal: 0,
 			}
 		},
+		onLoad() {
+			this.title=process.car.branchParameter=="youdian"?'优电商城':'51商城'
+		},
 		onReady() {
 			this.getList()
 			this.getBannerInfo("store");

+ 1 - 1
pages/store/orderDetails.vue

@@ -70,7 +70,7 @@
 			<view class="commodity-infos">
 				<!-- 图片 -->
 				<view class="picture">
-					<img src="../../assets/img/commodity1.png" alt="">
+					<img :src="info.mallProductOrder.productPic" alt="">
 				</view>
 				<!-- 信息 -->
 				<view class="infos">

+ 3 - 1
pages/user/InviteFriends.vue

@@ -10,7 +10,9 @@
 			opacityClass:show
 		}">
 			<view class="InviteFriends-head">
-				<u-image width="274rpx" height="60rpx" src="@/assets/static/img/logo3.png"></u-image>
+				<u-image v-if="branchParameterBl('ud')" width="274rpx" height="60rpx" src="@/assets/static/img/logo3Ud.png"></u-image>
+				
+				<u-image v-else width="274rpx" height="60rpx" src="@/assets/static/img/logo3.png"></u-image>
 				<u-image class="textImg" width="662rpx" height="59rpx" src="@/assets/static/img/text-1.png"></u-image>
 				<u-image width="100%" height="320rpx" src="@/assets/static/img/handshake.png"></u-image>
 			</view>

+ 5 - 2
pages/user/about.vue

@@ -1,8 +1,11 @@
 <template>
 	<view class="all">
 		<ujp-navbar title="关于我们"></ujp-navbar>
-		<view class="about">
-			<img src="@/assets/static/img/aboutus.png" alt="">
+		<view class="about">
+			<img  v-if="branchParameterBl('ud')" src="@/assets/static/img/aboutusUd.jpg" alt="">
+			
+			<img v-else src="@/assets/static/img/aboutus.png" alt="">
+			
 			<p class="font-weight2">{{projectName}}</p>
 		</view>
 		<u-cell-group>

+ 3 - 1
pages/user/index.vue

@@ -35,7 +35,9 @@
 				<view class="right"
 				 v-if="personInfo&&personInfo.userType==2">
 					
-					<img src="@/assets/img/9-4/联盟会员.png" v-if="personInfo.memberLevel==1||personInfo.memberLevel==null">
+					<img src="@/assets/img/9-4/联盟会员.png" v-if="branchParameterBl()&&(personInfo.memberLevel==1||personInfo.memberLevel==null)">
+					<img src="@/assets/img/9-4/联盟会员ud.jpg" v-if="branchParameterBl('ud')&&(personInfo.memberLevel==1||personInfo.memberLevel==null)">
+					
 					<img src="@/assets/img/9-4/白银会员.svg" v-if="personInfo.memberLevel==2">
 					<img src="@/assets/img/9-4/黄金会员.svg" v-if="personInfo.memberLevel==3">
 					<img src="@/assets/img/9-4/白金会员.svg" v-if="personInfo.memberLevel==4">

+ 6 - 1
pages/user/member/member.vue

@@ -401,6 +401,11 @@
 				startDate:'',
 				uCurrent:0,
 			}
+		},
+		onLoad(){
+				if(this.branchParameterBl('ud')){
+					this.list[0].image=require('@/assets/img/9-4/联盟会员ud.jpg')
+				}
 		},
 		onReady() {
 			this.personInfo = this.carhelp.getPersonInfo()
@@ -798,7 +803,7 @@
 		.vipTextImg{
 			img{
 				width: 160rpx;
-				height: 220rpx;
+				height: 160rpx;
 			}
 		}
 		.tag {

+ 9 - 1
utils/mixin.js

@@ -59,7 +59,15 @@ var app = {
 		if(config){
 			for(var  i in config){
 				var con=config[i];
-				configure[con.key]=con.value
+				
+				if(process.car.branchParameter=="youdian"){
+					
+					configure[con.key]=con.valueUd
+				}else{
+					configure[con.key]=con.value
+				}
+				
+				
 			}
 		}
 		 return configure;