xhj 2 سال پیش
والد
کامیت
414453daa5

+ 16 - 0
.hbuilderx/launch.json

@@ -0,0 +1,16 @@
+{ // launch.json 配置了启动调试时相关设置,configurations下节点名称可为 app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/
+  // launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数
+    "version": "0.0",
+    "configurations": [{
+     	"default" : 
+     	{
+     		"launchtype" : "local"
+     	},
+     	"mp-weixin" : 
+     	{
+     		"launchtype" : "local"
+     	},
+     	"type" : "uniCloud"
+     }
+    ]
+}

+ 2 - 2
App.vue

@@ -13,5 +13,5 @@
 </script>
 
 <style>
-	/*每个页面公共css */
-</style>
+	@import "./app.css";
+</style>

+ 385 - 0
app.css

@@ -0,0 +1,385 @@
+/**app.wxss**/
+/* 济民绿色 00923f */
+/* 通御绿色 008457 */
+/* 佐今明蓝色 0065AC */
+/* 九芝堂 cd0b01 */
+/* 柚荚 fc5c25 */
+/* 焦娇美人 c9136d */
+/* 利省家居 0065AC */
+/* 云助手 00a3ff */
+/* 通御科技 18AAA3 */
+/* 康宁医药 23AC3A */
+/* 四季康来 18AAA3 */
+/* 精戈MALL c30d23 */
+/* 一源有品 00a3ff */
+/* 享团 、仁和 cd0b01  */
+/*清泉云购  cd0b01 */
+/* 乡亲  1796CB*/
+/* 晓琳优品 00923f */
+/* 奥工匠 1582F7 */
+
+@import "./static/iconfont.css";
+@import "./static/stylesheet.css";
+
+page {
+  --mina: #27D699;
+  --main: #27D699;
+  --btn: #27D699;
+  --red: #FE0419;
+  --black: #201d1d;
+  --fff: #fff;
+  --vip:#e6b422;
+  font-size: 28rpx;
+  color: #333;
+  background: #f6f6f6;
+  -webkit-user-select: text; 
+  		user-select: text;
+}
+button::after {
+  border: none;
+}
+
+button {
+  background: none;
+  border: none;
+  padding: 0 !important;
+  margin: 0 !important;
+  line-height: initial !important;
+  width: auto !important;
+  font-weight: normal !important;
+  height: auto !important;
+  border-radius: 0 !important;
+  overflow: initial;
+}
+
+image {
+  display: block;
+}
+
+.mbgcolor {
+  background: #FE0419;
+}
+
+.sbgcolor {
+  background: var(--mina) !important;
+}
+
+.bgfff {
+  background: #fff;
+}
+
+.mbglinear {
+  background: linear-gradient(90deg, rgba(254, 147, 76, 1), rgba(253, 58, 49, 1));
+}
+
+.mbglinear-gray {
+  background: #999;
+}
+
+
+
+.sbglinear {
+  background: linear-gradient(0deg, rgba(255, 198, 164, 1), rgba(255, 239, 232, 1));
+}
+
+.mbggray {
+  background: linear-gradient(0deg, #e0e0e0, #c4c4c4);
+}
+
+.mbggreen {
+  background: linear-gradient(0deg, #2AE075, #0ECA78, #05C379);
+}
+
+.mcolor {
+  color: #FE0419;
+}
+
+.scolor {
+  color: var(--mina) !important;
+}
+
+.r50 {
+  border-radius: 50%;
+}
+
+.r10 {
+  border-radius: 12rpx;
+}
+
+.r20 {
+  border-radius: 20rpx;
+}
+
+
+.pdlr20 {
+  padding-left: 20rpx;
+  padding-right: 20rpx;
+}
+
+.mlr20 {
+  margin-left: 20rpx;
+  margin-right: 20rpx;
+}
+
+.mb20 {
+  margin-bottom: 20rpx;
+}
+
+.mr20 {
+  margin-right: 20rpx;
+}
+
+.mt20 {
+  margin-top: 20rpx;
+}
+.mt30 {
+  margin-top: 30rpx;
+}
+
+
+
+.f26 {
+  font-size: 26rpx;
+}
+
+.f28 {
+  font-size: 28rpx;
+}
+
+.f30 {
+  font-size: 30rpx;
+}
+
+
+
+.dflex {
+  display: flex;
+  display: -webkit-flex;
+}
+
+.flex {
+  flex: 1;
+  -webkit-flex: 1;
+}
+
+
+/* 为空 */
+.nodata {
+  text-align: center;
+  padding: 100rpx 0 40rpx 0;
+  font-size: 30rpx;
+  color: #333;
+}
+
+.nodata image {
+  display: block;
+  width: 352rpx;
+  height: 307rpx;
+  margin: 0 auto 50rpx;
+}
+
+.nodata text {
+  font-size: 28rpx;
+  color: #777;
+}
+
+.nomore {
+  font-size: 24rpx;
+  color: #999;
+  padding: 25rpx 0;
+  align-items: center;
+  justify-content: center;
+}
+
+.nomore::before,
+.nomore::after {
+  display: block;
+  content: '';
+  width: 168rpx;
+  height: 2rpx;
+  background: #e0e0e0;
+}
+
+.nomore::before {
+  margin-right: 50rpx;
+}
+
+.nomore::after {
+  margin-left: 50rpx;
+}
+
+.fixed {
+  position: fixed;
+  left: 0;
+  bottom: 0;
+  right: 0;
+  z-index: 50;
+}
+
+.mask {
+  position: fixed;
+  z-index: 99;
+  top: 0;
+  left: 0;
+  right: 0;
+  bottom: 0;
+  background: rgba(0, 0, 0, .5);
+}
+
+/* 客服 */
+.contact_index {
+  position: fixed;
+  bottom: 300rpx;
+  right: 20rpx;
+  background: var(--mina) !important;
+  border-radius: 50% !important;
+  width: 100rpx !important;
+  height: 100rpx !important;
+  box-shadow: 0 0 10rpx rgba(86, 86, 86, 0.36);
+  font-size: 22rpx;
+  color: #fff;
+  z-index: 20;
+  text-align: center;
+  display: flex;
+  flex-direction: column;
+  justify-content: center;
+  align-items: center;
+}
+
+.contact_index image {
+  width: 40rpx;
+  height: 40rpx;
+  margin: 0 auto 5rpx;
+}
+
+/* 列表购物车 */
+.contact_index1 {
+  position: fixed;
+  bottom: 300rpx;
+  right: 30rpx;
+  background: #fff !important;
+  border-radius: 50% !important;
+  width: 75rpx !important;
+  height: 75rpx !important;
+  /* box-shadow: 0 0 10rpx rgba(86,86,86,0.36); */
+  font-size: 18rpx;
+  color: #555;
+  z-index: 20;
+  align-items: center;
+  text-align: center;
+  border: 1rpx solid #eee;
+}
+
+.contact_index1 image {
+  width: 45rpx;
+  height: 45rpx;
+  margin: 15rpx auto;
+}
+
+/* 购物车为空 */
+.nodata_cart {
+  text-align: center;
+  padding: 85rpx 0;
+}
+
+.nodata_cart image {
+  width: 320rpx;
+  height: 307rpx;
+  margin: 0 auto;
+}
+
+.nodata_cart view {
+  font-size: 30rpx;
+  color: #333;
+  margin: 15rpx 0;
+}
+
+.nodata_cart text {
+  display: block;
+  font-size: 18rpx;
+  color: #999;
+}
+
+.nodata_cart navigator {
+  width: 176rpx;
+  height: 66rpx;
+  line-height: 66rpx;
+  border: 2rpx solid #EA6739;
+  border-radius: 35rpx;
+  font-size: 30rpx;
+  color: #EA6739;
+  margin: 40rpx auto 0;
+}
+
+
+/* 通告 */
+.notification_bar {
+  position: fixed;
+  top: 250rpx;
+  left: 20rpx;
+  width: 100%;
+  z-index: 20;
+  height: 100rpx;
+  overflow: hidden;
+}
+
+.bar_box {
+  height: 100rpx;
+}
+
+.bar_con {
+  align-items: center;
+}
+
+.bar {
+  padding-right: 30rpx;
+  align-items: center;
+  background: rgba(0, 0, 0, 0.49);
+  height: 42rpx;
+  line-height: 42rpx;
+  border-radius: 21rpx;
+}
+
+.bar_left {
+  width: 42rpx;
+  height: 42rpx;
+  border-radius: 50%;
+  margin-right: 12rpx;
+}
+
+.bar_text {
+
+  font-size: 18rpx;
+  color: #fff;
+}
+
+.iconfont {
+  display: flex;
+  display: -webkit-flex;
+  align-items: center;
+  justify-content: center;
+}
+
+.color999 {
+  color: #999;
+}
+
+
+.ddflex{display: flex;display: -webkit-flex;align-items: center;flex-wrap: wrap;}
+.fflex{flex: 1;-webkit-flex: 1;overflow: hidden;}
+.tover{text-overflow: ellipsis;white-space: nowrap;overflow: hidden;}
+.tovers{overflow : hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;}
+
+
+/* ios底部安全距离-padding */
+.savepadding{
+    padding-bottom: constant(safe-area-inset-bottom);  
+    padding-bottom: env(safe-area-inset-bottom); 
+    /* box-sizing: content-box; */
+}
+
+/* ios底部安全距离-bottom */
+.savebottom{
+    bottom: constant(safe-area-inset-bottom);  
+    bottom: env(safe-area-inset-bottom); 
+}

+ 62 - 0
card/create/create.css

@@ -0,0 +1,62 @@
+/* create.css */
+page{background: #f9f9f9;padding-bottom: 130rpx;}
+.form{background: #fff;padding: 0 35rpx 20rpx;margin-bottom: 20rpx;}
+.form .li{padding: 30rpx 0;position: relative;}
+.label{font-size: 30rpx;color: #999;width: 160rpx;}
+.photo{justify-content: space-between;}
+.userimg{width: 90rpx;height: 90rpx;border-radius: 50%;}
+.rico{width: 15rpx;height: 22rpx;}
+.ipt{font-size: 30rpx;color: #333;}
+.textarea{font-size: 30rpx;color: #333;height: 100rpx;}
+.tit{font-size: 30rpx;color: #333;font-weight: bold;padding: 35rpx 0;}
+.alstart{align-items: flex-start;}
+.num{position: absolute;right: 0;bottom: 0;}
+.tong{font-size: 26rpx;color: #DB2A2A;}
+.tong image{width: 32rpx;height: 32rpx;margin-right: 10rpx;}
+.add{font-size: 26rpx;color: #DB2A2A;font-weight: normal;}
+.add image{width: 33rpx;height: 33rpx;margin-right: 10rpx;}
+.picker{position: relative;}
+.picker view{width: 100%;font-size: 30rpx;}
+.picker .rico{position: absolute;right: 0;top: 50%;transform: translateY(-50%);}
+.placeholder{color: #ccc;}
+.bot{position: fixed;left: 0;right: 0;bottom: 0;background: #fff;padding: 25rpx 32rpx;z-index: 50;}
+.btn{height: 80rpx;background: var(--main);border-radius: 40rpx;font-size: 30rpx;color: #fff;text-align: center;line-height: 80rpx;}
+
+
+.upload-box{
+	width: 200rpx;
+	height: 200rpx;
+	background: #F8F8F8;
+	border-radius: 10rpx 10rpx 10rpx 10rpx;
+	justify-content: center;
+	flex-direction: column;
+	font-size: 24rpx;
+	font-family: PingFang SC-Regular, PingFang SC;
+	font-weight: 400;
+	text-align: center;
+	color: #A1A1A1;
+}
+.upload-box image{
+	width: 51rpx;
+	height: 44rpx;
+	margin-bottom: 19rpx;
+}
+.upload-box-image{
+	position: relative;
+}
+.upload-box-image .upload-image{
+	width: 200rpx;
+	height: 200rpx;
+	border-radius: 10rpx 10rpx 10rpx 10rpx;
+}
+.upload-close{
+	position: absolute;
+	width: 28rpx;
+	height: 28rpx;
+	top: -14rpx;
+	right: -14rpx;
+}
+.upload-group .upload-box , .upload-group .upload-box-image {
+	margin-right: 13rpx;
+	margin-bottom: 13rpx;
+}

+ 450 - 0
card/create/create.vue

@@ -0,0 +1,450 @@
+<template>
+	<view>
+		<view class="form">
+			<view class="li ddflex">
+				<view class="label">头像</view>
+				<view class="photo ddflex flex" @tap="uploadImgs()">
+					<image :src="avatar ? avatar : '../../static/images/userimg.png'" mode="aspectFill" class="userimg"></image>
+					<image src="../../static/images/rico.png" class="rico"></image>
+				</view>
+			</view>
+			<view class="li ddflex">
+				<view class="label">姓名</view>
+				<input v-model="realName" :disabled="true" placeholder="请填写你的真实姓名" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+			
+			<view class="li ddflex">
+				<view class="label">工号</view>
+				<input v-model="jobNumber" :disabled="true" placeholder="请输入工号" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+			
+			<view class="li ddflex">
+				<view class="label">个人简介</view>
+				<input v-if="!brief" @tap="jumpUrl('/card/editDesc/editDesc')" :disabled="true"  maxlength="11" type="number" placeholder="请作简单自我介绍" placeholder-class="placeholder" class="ipt flex" />
+				<view class="fflex" v-else style="color: #47C776;" @tap="jumpUrl('/card/editDesc/editDesc')">已完善</view>
+				<image src="../../static/images/rico.png" class="rico"></image>
+			</view>
+			
+			<view class="li ddflex">
+				<view class="label">执业证书</view>
+				<input v-model="certificateNo" :disabled="true" placeholder="请输入执业证书编号" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+		</view>
+		
+		<view class="form">
+			<view class="tit ddflex"><view class="flex">联系信息</view></view>
+			<view class="li ddflex">
+				<view class="label">手机</view>
+				<input v-model="phone" maxlength="11" type="number" placeholder="请填写手机号" placeholder-class="placeholder" class="ipt flex" />
+				<!-- <view class="tong ddflex" @click="intWechatNumber"><image src="../static/images/wxth.png"></image>微信同号</view> -->
+			</view>
+			<view class="li ddflex">
+				<view class="label">微信号</view>
+				<input v-model="wechat" placeholder="请填写微信号" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+			<!-- <view class="li ddflex">
+				<view class="label">邮箱</view>
+				<input v-model="email" placeholder="请填写邮箱地址" placeholder-class="placeholder" class="ipt flex" />
+			</view> -->
+			<view class="li dflex">
+				<view class="label">微信二维码</view>
+				<view v-if="!wechatCode" class="upload-box ddflex" @tap="uploadWechat()">
+					<image src="../static/images/pic.png"></image>
+					<view>点击上传</view>
+				</view>
+				<view v-else class="upload-box-image ddflex" @tap="uploadWechat()">
+					<image class="upload-image" :src="wechatCode"></image>
+					<image class="upload-close" src="../../static/pages/images/close3.png" @click.stop="wechatCode=''"></image>
+				</view>
+			</view>
+		</view>
+		
+		<view class="form">
+			<view class="li dflex">
+				<view class="label">所获荣誉</view>
+				<view class="ddflex upload-group flex">
+					<view class="upload-box-image ddflex" v-for="item,index in honorImgUrls" @click="uploadHonor('change',index)">
+						<image class="upload-image" :src="item"></image>
+						<image class="upload-close" src="../../static/pages/images/close3.png" @click.stop="deleteHonor(index)"></image>
+					</view>
+					<view class="upload-box ddflex" @tap="uploadHonor()" v-if="honorImgUrls.length<9">
+						<image src="../static/images/pic.png"></image>
+						<view>点击上传</view>
+					</view>
+				</view>
+			</view>
+			<view class="li dflex">
+				<view class="label">个人风采</view>
+				<view class="ddflex upload-group flex">
+					<view class="upload-box-image ddflex" v-for="item,index in styleImgUrls" @click="uploadStyle('change',index)">
+						<image class="upload-image" :src="item"></image>
+						<image class="upload-close" src="../../static/pages/images/close3.png" @click.stop="deleteStyle(index)"></image>
+					</view>
+					<view class="upload-box ddflex" @tap="uploadStyle()" v-if="styleImgUrls.length<9">
+						<image src="../static/images/pic.png"></image>
+						<view>点击上传</view>
+					</view>
+				</view>
+			</view>
+		</view>
+
+		<view class="form">
+			<view class="tit ddflex"><view class="flex">公司信息</view></view>
+			<view class="li ddflex">
+				<view class="label">公司</view>
+				<input v-model="companyName" :disabled="true" placeholder="请填写公司名称" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+			<view class="li ddflex">
+				<view class="label">职位</view>
+				<input v-model="job" :disabled="true" placeholder="请填写职位" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+			<!-- <view class="li ddflex" @click="jumpUrl('/card/industry/industry?isPoistion=true')">
+				<view class="label">行业</view>
+				<view :class="'flex' + (industryName ? '' :' placeholder')">{{industryName ? industryName : '请填写行业'}}</view>
+				<image src="../../static/images/rico.png" class="rico"></image>
+			</view> -->
+			<view class="li ddflex">
+				<view class="label">所在地区</view>
+				<view :class="['item flex', city ? 'active' : '']">
+					<pickerAddress class="picker flex" @change="bindAddressChange">
+						<view :class="city?'':'placeholder'">{{ city ? city : '请选择地区' }}</view>
+					</pickerAddress>
+				</view>
+				<image src="../../static/images/rico.png" class="rico"></image>
+				<!-- <picker class="picker flex">
+					<view class="placeholder">请选择省份城市</view>
+					<image src="../../static/images/rico.png" class="rico"></image>
+				</picker> -->
+			</view>
+			<view class="li ddflex">
+				<view class="label">地址</view>
+				<input v-model="address" placeholder="填写街道地址" placeholder-class="placeholder" class="ipt flex" />
+			</view>
+		</view>
+		<view class="bot">
+			<view class="btn" @click="submitCard()">{{ isEdit ? '保存' : '确认创建' }}</view>
+		</view>
+	</view>
+</template>
+
+<script>
+const req = require('../../utils/request.js');
+const util = require('../../utils/util.js');
+var app = getApp();
+import pickerAddress from '../../components/wangding-pickerAddress/wangding-pickerAddress.vue';
+export default {
+	components: { pickerAddress },
+	data() {
+		return {
+			avatar: '',
+			realName: '',
+			phone: '',
+			jobNumber:'',
+			wechat: '',
+			wechatCode:'',
+			email: '',
+			companyName: '',
+			job:'',//职业
+			industryName: '',//行业
+			tradeId: '',//行业id
+			message: '',
+			isEdit: false,
+			id: '' ,//名片id
+			nums: 0,
+			brief:'',//简介
+			address:'',//详细地址
+			
+			honorImgUrls:[],//荣誉
+			
+			styleImgUrls:[],//风采
+			
+			city: '',
+			areaCode: '',
+			morCity: [],
+			
+			userCard:null,//用户IP名片
+			employmentInfo:'',
+			saleNo:null,
+			certificateNo:null
+		};
+	},
+	async onLoad(opt) {
+		this.isEdit = opt.isEdit;
+		this.id = opt.id;
+		this.saleNo = opt.saleNo
+		await req.silenceLogin(opt.saleNo)
+		console.log('getUserCard')
+		this.getUserCard()
+		this.getEmploymentInfo()
+	},
+
+	methods: {
+		getUserInfo(){
+			return new Promise((resolve,reject)=>{
+				req.getRequest('/api/user/info',{},res=>{
+					this.avatar = res.avatar;
+					this.phone = res.mobile;
+					resolve();
+				})
+			})
+		},
+		getEmploymentInfo(){
+			return new Promise((resolve,reject)=>{
+				req.getRequest('/api/visiting/card/employmentInfo',{jobNumber:this.saleNo},res=>{
+					if(res.name){
+						this.employmentInfo = res;
+						this.realName = this.employmentInfo.name;
+						this.certificateNo = this.employmentInfo.professionalCertificateNo
+						this.jobNumber = this.employmentInfo.salesNo
+						this.companyName = this.employmentInfo.branchName
+						this.job = this.employmentInfo.actrankName
+					}
+					else return req.msg("员工信息不存在")
+					resolve();
+				})
+			})
+		},
+		// 用户名片信息
+		getUserCard(){
+			req.getRequest('/api/visiting/card/userInfo', {}, res => {
+				console.log('getUserCard',res)
+				this.userCard = res
+				if(!res){
+					this.getUserInfo()
+				}else{
+					this.id = res.id
+					this.avatar = res.avatar;
+					this.realName = res.realName;
+					this.jobNumber = res.jobNumber;
+					this.brief = res.brief;
+					this.phone = res.phone;
+					this.wechat = res.wechat;
+					this.wechatCode = res.wechatCode;
+					this.email = res.email;
+					this.companyName = res.companyName;
+					this.industryName = res.industryName;
+					this.tradeId = res.tradeId;
+					this.address = res.address;
+					this.job = res.job;
+					res.areaCode = JSON.parse(res.areaCode)
+					this.morCity = [res.areaCode.id.substring(0,2)+'0000',res.areaCode.id.substring(0,4)+'00',res.areaCode.id]
+					this.city = res.areaCode.name
+					this.areaCode = this.morCity[2];
+				}
+			});
+		},
+		jumpUrl(url) {
+			uni.navigateTo({
+				url: url
+			});
+		},
+		uploadImgs() {
+			let that = this;
+			uni.chooseImage({
+				count: 1,
+				sizeType: ['original', 'compressed'],
+				sourceType: ['album', 'camera'],
+				success: function({ tempFilePaths }) {
+					var promise = Promise.all(
+						tempFilePaths.map(tempFilePath => {
+							return new Promise(function(resolve, reject) {
+								req.uploadFile('/api/nocheck/upload', tempFilePath, res => {
+									that.avatar = res.src;
+								});
+							});
+						})
+					);
+					promise
+						.then(function(results) {
+							console.log(results);
+						})
+						.catch(function(err) {
+							console.log(err);
+						});
+				}
+			});
+		},
+		uploadWechat() {
+			let that = this;
+			uni.chooseImage({
+				count: 1,
+				sizeType: ['original', 'compressed'],
+				sourceType: ['album', 'camera'],
+				success: function({ tempFilePaths }) {
+					var promise = Promise.all(
+						tempFilePaths.map(tempFilePath => {
+							return new Promise(function(resolve, reject) {
+								req.uploadFile('/api/nocheck/upload', tempFilePath, res => {
+									that.wechatCode = res.src;
+								});
+							});
+						})
+					);
+					promise
+						.then(function(results) {
+							console.log(results);
+						})
+						.catch(function(err) {
+							console.log(err);
+						});
+				}
+			});
+		},
+		
+		uploadHonor(type,index){
+			let that = this;
+			uni.chooseImage({
+				count: type=='change'?1:(9-that.honorImgUrls.length),
+				sizeType: ['original', 'compressed'],
+				sourceType: ['album', 'camera'],
+				success: function({ tempFilePaths }) {
+					var promise = Promise.all(
+						tempFilePaths.map(tempFilePath => {
+							return new Promise(function(resolve, reject) {
+								req.uploadFile('/api/nocheck/upload', tempFilePath, res => {
+									if(type=='change'){
+										that.honorImgUrls[index] = res.src
+										that.honorImgUrls = JSON.parse(JSON.stringify(that.honorImgUrls))
+									}else{
+										that.honorImgUrls = that.honorImgUrls.concat(res.src)
+									}
+								});
+							});
+						})
+					);
+					promise
+						.then(function(results) {
+							console.log(results);
+						})
+						.catch(function(err) {
+							console.log(err);
+						});
+				}
+			});
+		},
+		deleteHonor(index){
+			this.honorImgUrls.splice(index,1)
+		},
+		
+		// 个人风采
+		uploadStyle(type,index){
+			let that = this;
+			uni.chooseImage({
+				count: type=='change'?1:(9-that.styleImgUrls.length),
+				sizeType: ['original', 'compressed'],
+				sourceType: ['album', 'camera'],
+				success: function({ tempFilePaths }) {
+					var promise = Promise.all(
+						tempFilePaths.map(tempFilePath => {
+							return new Promise(function(resolve, reject) {
+								req.uploadFile('/api/nocheck/upload', tempFilePath, res => {
+									if(type=='change'){
+										that.styleImgUrls[index] = res.src
+										that.styleImgUrls = JSON.parse(JSON.stringify(that.styleImgUrls))
+									}else{
+										that.styleImgUrls = that.styleImgUrls.concat(res.src)
+									}
+								});
+							});
+						})
+					);
+					promise
+						.then(function(results) {
+							console.log(results);
+						})
+						.catch(function(err) {
+							console.log(err);
+						});
+				}
+			});
+		},
+		deleteStyle(index){
+			this.styleImgUrls.splice(index,1)
+		},
+		
+		intMessage(e){
+			this.nums = e.detail.value.length
+		},
+		intWechatNumber(){
+			this.wechat = this.phone
+		},
+		
+		bindCity: function(e) {
+			this.morCity = e.detail.code;
+			this.city = e.detail.value.join().replace(/[,]/g, '');
+			this.areaCode = e.detail.code[2];
+		},
+		
+		bindAddressChange(data) {
+			this.morCity = data.ids;
+			this.city = data.data[0] + data.data[1] + data.data[2];
+			this.areaCode = data.ids[2];
+		},
+
+		/**
+		 * 提交名片
+		 */
+		submitCard() {
+			let that = this;
+			if (!this.avatar) return req.msg('请上传头像');
+			if (!this.realName) return req.msg('请填写你的真实姓名');
+			if (!this.jobNumber) return req.msg('请填写你的工号');
+			if (!this.brief) return req.msg('请填写个人简介');
+			if (!this.phone) return req.msg('请填写手机号');
+			if (!this.wechat) return req.msg('请填写微信号');
+			if (!this.wechatCode) return req.msg('请上传微信二维码');
+			if (!this.companyName) return req.msg('请填写公司名称');
+			if (!this.job) return req.msg('请填写职位')
+			if (!this.areaCode) return req.msg('请选择所在地区');
+			if (!this.address) return req.msg('请填写详细地址');
+			var dataP = {};
+			dataP.avatar = this.avatar;
+			dataP.realName = this.realName;
+			dataP.brief = this.brief;
+			dataP.phone = this.phone;
+			dataP.wechat = this.wechat;
+			dataP.wechatCode = this.wechatCode;
+			dataP.companyName = this.companyName;
+			dataP.job = this.employmentInfo.actrank;
+			dataP.areaCode = {
+				id:this.areaCode,
+				name :this.city
+			};
+			dataP.areaCode = JSON.stringify(dataP.areaCode)
+			dataP.address = this.address;
+			dataP.jobNumber = this.jobNumber;
+			dataP.honorImg = this.honorImgUrls.join(',');
+			dataP.styleImg = this.styleImgUrls.join(',');
+			var url = '';
+			if (this.id) {
+				dataP.id = this.id;
+			} 
+
+			req.postRequest(
+				'/api/visiting/card/saveOrUpdate',
+				dataP,
+				json => {
+					if (that.id) {
+						req.msg('保存成功');
+						setTimeout(function() {
+							uni.navigateBack({
+								delta: 1
+							});
+						}, 1500);
+					} else {
+						req.msg('名片创建成功');
+						setTimeout(function() {
+							that.jumpUrl('/card/index/index');
+						}, 1500);
+					}
+				},
+				true
+			);
+		}
+	}
+};
+</script>
+
+<style>
+@import './create.css';
+</style>

+ 7 - 0
card/editDesc/editDesc.css

@@ -0,0 +1,7 @@
+/* follow.css */
+.content {padding: 0 56rpx 520rpx;border-top: 2rpx solid #fbfbfb;}
+.placeholder {color: #A2A6AF;}
+.textarea {height: 500rpx;padding: 30rpx 0;width: 100%;font-size: 32rpx;color: #666;}
+.brief {font-size: 28rpx;color: #999;margin: 25rpx 0 0;}
+.brief text {color: #FF4211;}
+.btn {width: 638rpx;height: 94rpx;background: var(--main);border-radius: 47rpx;font-size: 36rpx;color: #fff;text-align: center;line-height: 94rpx;margin: 0 auto; margin-top: 30rpx; }

+ 83 - 0
card/editDesc/editDesc.vue

@@ -0,0 +1,83 @@
+<template>
+	<view class="content">
+		<editor
+			@ready="onEditorReady"
+			id="editor"
+			placeholder="输入个人简介内容"
+			placeholder-class="placeholder"
+			class="textarea"
+			@input="descInput"
+			:read-only="isReadOnly"
+		></editor>
+
+		<view class="btn" @click="save()">保存</view>
+	</view>
+</template>
+
+<script>
+const app = getApp();
+const req = require('../../utils/request.js');
+export default {
+	data() {
+		return {
+			id: '',
+			brief: '',
+			isReadOnly: true
+		};
+	},
+
+	onLoad(opt) {
+		this.id = opt.id;
+		let pages = getCurrentPages();
+		let prevPage = pages[pages.length - 2];
+		this.brief = prevPage.$vm.brief;
+	},
+
+	methods: {
+		descInput(event) {
+			this.brief = event.detail.html;
+			// if (this.brief) {
+			// 	this.descLength = event.detail.text.length - 1;
+			// } else {
+			// 	this.descLength = 0;
+			// }
+		},
+		onEditorReady() {
+			if (this.isEndit) {
+				return;
+			}
+			const that = this;
+			uni.createSelectorQuery()
+				.select('#editor')
+				.context(function(res) {
+					that.editorCtx = res.context;
+					that.editorCtx.setContents({
+						html: that.brief //这里就是设置默认值的地方(html 后面给什么就显示什么)
+					});
+					that.isReadOnly = false;
+				})
+				.exec();
+		},
+
+		save() {
+			let pages = getCurrentPages(); //获取所有页面栈实例列表
+			let prevPage = pages[pages.length - 2]; //上一页页面实例
+			prevPage.$vm.brief = this.brief;
+			uni.navigateBack({
+				//uni.navigateTo跳转的返回,默认1为返回上一级
+				delta: 1
+			});
+		}
+	}
+};
+</script>
+
+<style>
+@import './editDesc.css';
+.ql-editor.ql-blank:before {
+	/* 此处设置 placeholder 样式 */
+	color: rgba(204, 204, 204, 1);
+	font-style: normal;
+	min-height: 400px;
+}
+</style>

BIN
card/static/images/pic.png


BIN
card/static/images/wxth.png


+ 140 - 0
components/wangding-pickerAddress/wangding-pickerAddress.vue

@@ -0,0 +1,140 @@
+<template>
+	<view>
+		<picker @change="bindPickerChange" @columnchange="columnchange" :range="array" range-key="name" :value="value" mode="multiSelector"><slot></slot></picker>
+	</view>
+</template>
+
+<script>
+const req = require('../../utils/request.js');
+// import AllAddress from './data.js';
+let selectVal = ['', '', ''];
+
+export default {
+	data() {
+		return {
+			value: [0, 0, 0],
+			ids: [],
+			array: [],
+			index: 0,
+			allAddressData: []
+		};
+	},
+	created() {
+		this.getReqAreaList();
+	},
+	methods: {
+		getReqAreaList() {
+			let areaList = req.getStorage('areaList');
+			if (areaList && areaList.length > 0) {
+				this.allAddressData = areaList;
+				this.initSelect();
+			} else {
+				req.getRequest(
+					'/area/list',
+					{},
+					data => {
+						req.setStorage('areaList', data);
+						this.allAddressData = data;
+						this.initSelect();
+					},
+					true
+				);
+			}
+		},
+		// 初始化地址选项
+		initSelect() {
+			this.updateSourceDate() // 更新源数据
+				.updateAddressDate() // 更新结果数据
+				.updateIdsDate()
+				.$forceUpdate(); // 触发双向绑定
+		},
+		// 地址控件改变控件
+		columnchange(d) {
+			this.updateSelectIndex(d.detail.column, d.detail.value) // 更新选择索引
+				.updateSourceDate() // 更新源数据
+				.updateAddressDate()
+				.updateIdsDate() // 更新结果数据
+				.$forceUpdate(); // 触发双向绑定
+		},
+
+		/**
+		 * 更新源数据
+		 * */
+		updateSourceDate() {
+			this.array = [];
+			this.array[0] = this.allAddressData.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			this.array[1] = this.allAddressData[this.value[0]].nodes.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			this.array[2] = this.allAddressData[this.value[0]].nodes[this.value[1]].nodes.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			return this;
+		},
+
+		/**
+		 * 更新索引
+		 * */
+		updateSelectIndex(column, value) {
+			let arr = JSON.parse(JSON.stringify(this.value));
+			arr[column] = value;
+			if (column === 0) {
+				arr[1] = 0;
+				arr[2] = 0;
+			}
+			if (column === 1) {
+				arr[2] = 0;
+			}
+			this.value = arr;
+			return this;
+		},
+
+		/**
+		 * 更新结果数据
+		 * */
+		updateAddressDate() {
+			selectVal = [];
+			selectVal[0] = this.array[0][this.value[0]].name + ' ';
+			selectVal[1] = this.array[1][this.value[1]].name + ' ';
+			if (this.array[2].length > 0) {
+				selectVal[2] = this.array[2][this.value[2]].name + ' ';
+			}
+			return this;
+		},
+		updateIdsDate() {
+			this.ids = [];
+			this.ids[0] = this.array[0][this.value[0]].id;
+			this.ids[1] = this.array[1][this.value[1]].id;
+			if (this.array[2].length > 0) {
+				this.ids[2] = this.array[2][this.value[2]].id;
+			}
+			return this;
+		},
+
+		/**
+		 * 点击确定
+		 * */
+		bindPickerChange(e) {
+			this.$emit('change', {
+				index: this.value,
+				data: selectVal,
+				ids: this.ids
+			});
+			return this;
+		}
+	}
+};
+</script>
+
+<style></style>

+ 178 - 0
components/wangding-pickerAddress/wangding-pickerAddressSingle.vue

@@ -0,0 +1,178 @@
+<template>
+	<view>
+		<picker @change="bindPickerChange" @columnchange="columnchange" :range="array" range-key="name" :value="value" mode="multiSelector"><slot></slot></picker>
+	</view>
+</template>
+
+<script>
+const req = require('../../utils/request.js');
+// import AllAddress from './data.js';
+let selectVal = ['', '', ''];
+
+export default {
+	data() {
+		return {
+			value: [0, 0, 0],
+			ids: [],
+			array: [],
+			index: 0,
+			allAddressData: []
+		};
+	},
+	created() {
+		this.getReqAreaList();
+	},
+	methods: {
+		getReqAreaList() {
+			let areaList = req.getStorage('areaList');
+			if (areaList && areaList.length > 0) {
+				this.allAddressData = areaList;
+				let obj = {
+					label: '请选择',
+					value: '0',
+					nodes: []
+				}
+				this.allAddressData.map(item=>{
+					item.nodes.unshift(obj);
+					if(item.nodes && item.nodes.length > 0){
+						item.nodes.map(it=>{
+							if(it.nodes && it.nodes.length > 0){
+								it.nodes.unshift(obj);
+							}
+						})
+					}
+					return item;
+				})
+				this.allAddressData.unshift(obj);
+				this.initSelect();
+			} else {
+				req.getRequest(
+					'/area/list',
+					{},
+					data => {
+						req.setStorage('areaList', data);
+						this.allAddressData = data;
+						let obj = {
+							label: '请选择',
+							value: '0',
+							nodes: []
+						}
+						this.allAddressData.map(item=>{
+							item.nodes.unshift(obj);
+							if(item.nodes && item.nodes.length > 0){
+								item.nodes.map(it=>{
+									if(it.nodes && it.nodes.length > 0){
+										it.nodes.unshift(obj);
+									}
+								})
+							}
+							return item;
+						})
+						this.allAddressData.unshift(obj);
+						this.initSelect();
+					},
+					true
+				);
+			}
+		},
+		// 初始化地址选项
+		initSelect() {
+			this.updateSourceDate() // 更新源数据
+				.updateAddressDate() // 更新结果数据
+				.updateIdsDate()
+				.$forceUpdate(); // 触发双向绑定
+		},
+		// 地址控件改变控件
+		columnchange(d) {
+			this.updateSelectIndex(d.detail.column, d.detail.value) // 更新选择索引
+				.updateSourceDate() // 更新源数据
+				.updateAddressDate()
+				.updateIdsDate() // 更新结果数据
+				.$forceUpdate(); // 触发双向绑定
+		},
+
+		/**
+		 * 更新源数据
+		 * */
+		updateSourceDate() {
+			this.array = [];
+			let obj = {
+				name: '请选择',
+				id: '0',
+			}
+			this.array[0] = this.allAddressData.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			this.array[1] = this.allAddressData[this.value[0]].nodes.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			this.array[2] = this.allAddressData[this.value[0]].nodes[this.value[1]].nodes.map(obj => {
+				return {
+					name: obj.label,
+					id: obj.value
+				};
+			});
+			return this;
+		},
+
+		/**
+		 * 更新索引
+		 * */
+		updateSelectIndex(column, value) {
+			let arr = JSON.parse(JSON.stringify(this.value));
+			arr[column] = value;
+			if (column === 0) {
+				arr[1] = 0;
+				arr[2] = 0;
+			}
+			if (column === 1) {
+				arr[2] = 0;
+			}
+			this.value = arr;
+			return this;
+		},
+
+		/**
+		 * 更新结果数据
+		 * */
+		updateAddressDate() {
+			selectVal = [];
+			selectVal[0] = this.array[0][this.value[0]].name;
+			selectVal[1] = this.array[1][this.value[1]].name;
+			if (this.array[2].length > 0) {
+				selectVal[2] = this.array[2][this.value[2]].name;
+			}
+			return this;
+		},
+		updateIdsDate() {
+			this.ids = [];
+			this.ids[0] = this.array[0][this.value[0]].id;
+			this.ids[1] = this.array[1][this.value[1]].id;
+			if (this.array[2].length > 0) {
+				this.ids[2] = this.array[2][this.value[2]].id;
+			}
+			return this;
+		},
+
+		/**
+		 * 点击确定
+		 * */
+		bindPickerChange(e) {
+			this.$emit('change', {
+				index: this.value,
+				data: selectVal,
+				ids: this.ids
+			});
+			return this;
+		}
+	}
+};
+</script>
+
+<style></style>

+ 15 - 38
pages.json

@@ -1,47 +1,24 @@
 {
 	"pages": [{
-			"path": "pages/index/index",
-			"style": {
-				"navigationBarTitleText": ""
-			}
-		},
-		{
-			"path": "pages/privacyAgreement/index",
-			"style": {
-				"navigationBarTitleText": "用户隐私政策"
-			}
-		},
-		{
-			"path": "pages/userAgreement/index",
+		"path": "pages/index/index",
+		"style": {
+			"navigationBarTitleText": ""
+		}
+	}],
+	"subPackages": [{
+		"root": "card",
+		"pages": [{
+			"path": "create/create",
 			"style": {
-				"navigationBarTitleText": "用户服务协议"
+				"navigationBarTitleText": "创建名片"
 			}
 		}, {
-			"path": "pages/register/index",
+			"path": "editDesc/editDesc",
 			"style": {
-				"navigationBarTitleText": "邀请下载",
-				"enablePullDownRefresh": false
+				"navigationBarTitleText": "详情"
 			}
-
-		}, 
-		{
-			"path": "pages/downloadApp/index",
-			"style": {
-				"navigationBarTitleText": "APP下载",
-				"enablePullDownRefresh": false
-			}
-
-		}
-	    ,{
-            "path" : "pages/quickappPrivacy/index",
-            "style" :                                                                                    
-            {
-                "navigationBarTitleText": "用户隐私政策",
-                "enablePullDownRefresh": false
-            }
-            
-        }
-    ],
+		}]
+	}],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
 		"navigationBarTitleText": "uni-app",
@@ -53,4 +30,4 @@
 		}
 
 	}
-}
+}

+ 0 - 68
pages/downloadApp/index.css

@@ -1,68 +0,0 @@
-.ceng {
-	background: #000000;
-	opacity: 0.5;
-	top: 0;
-	position: fixed;
-	width: 100%;
-	height: 100%;
-	z-index: 2;
-}
-
-.guide-image {
-	position: absolute;
-	z-index: 3;
-	top: 20rpx;
-	right: 60rpx;
-	width: 575rpx;
-	height: 358rpx;
-}
-
-.logo-box {
-	padding-top: 40rpx;
-	margin-top: 400rpx;
-}
-
-.logo-image {
-	width: 150rpx;
-	height: 150rpx;
-	margin: auto;
-}
-
-.logo-text {
-	text-align: center;
-	margin-top: 30rpx;
-}
-
-.logo-image image {
-	width: 100%;
-	height: 100%;
-}
-.download-btn{
-	width: 400rpx;
-	height: 80rpx;
-	background: #00A811;
-	border-radius: 10rpx;
-	text-align: center;
-	line-height: 80rpx;
-	color: #fff;
-	font-weight: bold;
-	margin:100rpx auto;
-}
-.footer-bar {
-	/* margin: 50rpx auto; */
-	position: absolute;
-	bottom: 20rpx;
-	width: 100%;
-	text-align: center;
-}
-.footer-bar text {
-	color: #333;
-	text-decoration: underline;
-}
-.footer-bar view {
-	margin: 10rpx auto;
-}
-.gary-text {
-	color: #999;
-	font-size: 24rpx;
-}

+ 0 - 131
pages/downloadApp/index.vue

@@ -1,131 +0,0 @@
-<template>
-	<!-- <view v-if="config"><view @click="goDownload()">去下载</view></view> -->
-	<view v-if="config" style="overflow: hidden;margin-bottom: 20rpx;min-height: 100vh;">
-		<view v-if="isWeixn">
-			<image class="guide-image" src="../../static/openGuide.png"></image>
-			<view class="ceng"></view>
-		</view>
-
-		<view>
-			<view class="logo-box">
-				<view class="logo-image"><image :src="config.CONFIG_PROJECT_LOGO"></image></view>
-				<view class="logo-text">{{ config.CONFIG_PROJECT_TITLE }}</view>
-			</view>
-			<view class="download-btn" @click="goDownload()">下载</view>
-		</view>
-
-		<view class="gary-text footer-bar">
-			<view>
-				<text style="margin-right: 10rpx;" @click="jump('/pages/userAgreement/index?appId=' + appId)">服务协议</text>
-				和
-				<text style="margin-left: 10rpx;" @click="jump('/pages/privacyAgreement/index?appId=' + appId)">隐私政策</text>
-			</view>
-			<view>{{ config.CONFIG_RECORD_NUMBER }}</view>
-		</view>
-	</view>
-</template>
-
-<script>
-const req = require('../../utils/request.js');
-const util = require('../../utils/util.js');
-export default {
-	data() {
-		return {
-			isWeixn: false, //判断是否在微信环境 true不在,false在
-			appId: '', //
-			config: ''
-		};
-	},
-
-	onLoad(opt) {
-		this.appId = opt.appId;
-		this.isWeixn = this.is_weixn();
-		this.getConfig();
-	},
-
-	methods: {
-		jump(url) {
-			uni.navigateTo({
-				url: url
-			});
-		},
-		getConfig() {
-			req.getRequest(
-				'/api/config',
-				this.appId,
-				{},
-				data => {
-					this.config = data;
-				},
-				true
-			);
-		},
-
-		// 去下载
-		goDownload() {
-			if (this.isWeixn) {
-				//在微信环境
-				this.showModal('请点击右上角“...”按钮, 选择在浏览器打开');
-			} else {
-				var u = navigator.userAgent;
-				var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1;
-				var isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
-				// 这里是iOS浏览器
-				if (isIOS) {
-					if (this.config.download_app_ios_url) {
-						window.location.href = this.config.download_app_ios_url; // 跳AppStore下载地址
-					} else {
-						this.showModal('后台暂未开放IOS App版本下载');
-					}
-				} else {
-					if (this.config.download_app_android_url) {
-						window.location.href = this.config.download_app_android_url; // 跳AppStore下载地址
-					} else {
-						this.showModal('后台暂未开放Android App版本下载');
-					}
-				}
-			}
-		},
-
-		// 是微信浏览器
-		is_weixn() {
-			var ua = navigator.userAgent.toLowerCase();
-			if (ua.match(/MicroMessenger/i) == 'micromessenger') {
-				return true;
-			} else {
-				return false;
-			}
-		},
-
-		/**
-		 * 是否为Pc版本
-		 */
-		isPC() {
-			var userAgentInfo = navigator.userAgent;
-			var Agents = ['Android', 'iPhone', 'SymbianOS', 'Windows Phone', 'iPad', 'iPod'];
-			var flag = true;
-			for (var v = 0; v < Agents.length; v++) {
-				if (userAgentInfo.indexOf(Agents[v]) > 0) {
-					flag = false;
-					break;
-				}
-			}
-			return flag;
-		},
-
-		showModal(msg) {
-			uni.showModal({
-				title: '提示',
-				content: msg,
-				confirmText: '关闭',
-				showCancel: false,
-				success(res) {}
-			});
-		}
-	}
-};
-</script>
-
-<style>
-@import './index.css';
-</style>

+ 0 - 2
pages/privacyAgreement/index.css

@@ -1,2 +0,0 @@
-/* index.css */
-.content{padding: 40rpx 30rpx;}

+ 0 - 39
pages/privacyAgreement/index.vue

@@ -1,39 +0,0 @@
-<template>
-	<view>
-		<view class="content"><rich-text :nodes="content"></rich-text></view>
-	</view>
-</template>
-
-<script>
-const req = require('../../utils/request.js');
-
-export default {
-	data() {
-		return {
-			appId: '',
-			content: ''
-		};
-	},
-	onLoad(opt) {
-		this.appId = opt.appId;
-		this.getConfig();
-	},
-	methods: {
-		getConfig() {
-			req.getRequest(
-				'/api/params/value',
-				this.appId,
-				{ type: 'PRIVACY_AGREEMENT' },
-				data => {
-					this.content = data;
-				},
-				true
-			);
-		}
-	}
-};
-</script>
-
-<style>
-@import './index.css';
-</style>

+ 0 - 2
pages/quickappPrivacy/index.css

@@ -1,2 +0,0 @@
-/* index.css */
-.content{padding: 40rpx 30rpx;}

+ 0 - 39
pages/quickappPrivacy/index.vue

@@ -1,39 +0,0 @@
-<template>
-	<view>
-		<view class="content"><rich-text :nodes="content"></rich-text></view>
-	</view>
-</template>
-
-<script>
-const req = require('../../utils/request.js');
-
-export default {
-	data() {
-		return {
-			appId: '',
-			content: ''
-		};
-	},
-	onLoad(opt) {
-		this.appId = opt.appId;
-		this.getConfig();
-	},
-	methods: {
-		getConfig() {
-			req.getRequest(
-				'/api/params/value',
-				this.appId,
-				{ type: 'quickapp_privacy' },
-				data => {
-					this.content = data;
-				},
-				true
-			);
-		}
-	}
-};
-</script>
-
-<style>
-@import './index.css';
-</style>

+ 0 - 391
pages/register/index.vue

@@ -1,391 +0,0 @@
-<template>
-	<view v-if="config" style="overflow: hidden;margin-bottom: 20rpx;min-height: 100vh;position: relative;">
-		<!-- 背景图 -->
-		<image class="wdbg" src="../../static/bg.png" mode="widthFix"></image>
-		<!-- 表单 -->
-		<view class="form-bar">
-			<view class="logo-box">
-				<view class="logo-image"><image :src="config.CONFIG_PROJECT_LOGO"></image></view>
-				<view class="logo-text">{{ config.CONFIG_PROJECT_TITLE }}</view>
-			</view>
-
-			<view v-if="mobileRegister" class="form-box">
-				<view class="form-item">
-					<view class="or-text or-text-b">
-						<view>
-							<text>您已使用</text>
-							{{ mobileRegister }}
-							<text>完成注册</text>
-						</view>
-					</view>
-				</view>
-				<!-- 按钮 -->
-				<view class="submit-btn" @click="downloadApp()">下载APP</view>
-			</view>
-			<view v-else class="form-box">
-				<view class="form-item">
-					<text class="number86">+86</text>
-					<input placeholder="请输入手机号" v-model="mobile" type="number" maxlength="11" placeholder-class="placeholder" class="ipt" />
-				</view>
-				<view class="form-item">
-					<input v-model="code" type="number" maxlength="6" placeholder="请输验证码" placeholder-class="placeholder" class="ipt" />
-					<view class="code-btn gary-text" @click="getCode()" v-text="sendMsg"></view>
-				</view>
-				<view class="form-item noborder" v-if="userInfo">
-					<image class="form-icon" src="../../static/member.png"></image>
-					<text class="gary-text">
-						邀请人
-						<span style="color: #333;margin-left: 10rpx;">{{ userInfo.nickName }}</span>
-					</text>
-				</view>
-				<!-- 按钮 -->
-				<view class="submit-btn" @click="submitRegister()">注册并下载APP</view>
-			</view>
-		</view>
-		<view class="gary-text footer-bar">
-			<view>
-				<text style="margin-right: 10rpx;" @click="jump('/pages/userAgreement/index?appId=' + appId)">服务协议</text>
-				和
-				<text style="margin-left: 10rpx;" @click="jump('/pages/privacyAgreement/index?appId=' + appId)">隐私政策</text>
-			</view>
-			<view>{{ config.CONFIG_RECORD_NUMBER }}</view>
-		</view>
-	</view>
-</template>
-
-<script>
-const req = require('../../utils/request.js');
-const util = require('../../utils/util.js');
-export default {
-	data() {
-		return {
-			appId: '',
-			userId: '', //推荐人用户Id;
-			config: '',
-			mobile: '', //手机号
-			code: '', //code
-			sendMsg: '获取验证码',
-			isGetCodeDisabled: false,
-
-			mobileRegister: '', //用户注册缓存的手机号
-
-			userInfo: '', //被邀请人对象
-			pickleChannel: '', //投放渠道
-			packageChannel: '' //包的渠道
-		};
-	},
-
-	onLoad(opt) {
-		this.mobileRegister = req.getStorage('mobileRegister');
-		this.appId = opt.appId;
-		// this.appId = 'ZQWYx7XoOOhv4Ns';
-		this.userId = opt.userId;
-		this.pickleChannel = opt.pickleChannel;
-		this.packageChannel = opt.packageChannel;
-		req.setStorage('pickleChannel', this.pickleChannel);
-		req.setStorage('packageChannel', this.packageChannel);
-
-		this.getConfig();
-		if (this.userId) {
-			this.getUeserInfo();
-		}
-	},
-
-	methods: {
-		getConfig() {
-			req.getRequest(
-				'/api/config',
-				this.appId,
-				{},
-				data => {
-					req.setStorage('config', data);
-					this.config = data;
-				},
-				true
-			);
-		},
-
-		jump(url) {
-			uni.navigateTo({
-				url: url
-			});
-		},
-
-		getUeserInfo() {
-			req.getRequest(
-				'/api/user/getInfo',
-				this.appId,
-				{ userId: this.userId },
-				data => {
-					this.userInfo = data;
-				},
-				true
-			);
-		},
-
-		getCode() {
-			if (this.isGetCodeDisabled == true) return false;
-			if (!this.mobile) {
-				req.msg('请输入手机号');
-				return;
-			}
-			if (!util.isMobile(this.mobile)) {
-				req.msg('请输入11位有效手机号');
-				return;
-			}
-			req.postRequest(
-				'/api/sms/login',
-				this.appId,
-				{
-					mobile: this.mobile
-				},
-				data => {
-					req.msg('验证码获取成功');
-					let time = 60;
-					let interval = setInterval(() => {
-						time--;
-						if (time == 0) {
-							this.isGetCodeDisabled = false;
-							this.sendMsg = '获取验证码';
-							clearInterval(interval);
-						} else {
-							this.isGetCodeDisabled = true;
-							this.sendMsg = time + '秒后再获取';
-						}
-					}, 1000);
-				},
-				true
-			);
-		},
-		submitRegister() {
-			if (!this.mobile) {
-				req.msg('请输入手机号');
-				return;
-			}
-			if (!this.code) {
-				req.msg('请输入验证码');
-				return;
-			}
-			var dataP = {
-				mobile: this.mobile,
-				code: this.code,
-				parentId: this.userId
-			};
-			req.postRequest(
-				'/api/mobileLogin',
-				this.appId,
-				dataP,
-				data => {
-					if (data.isNewRegister) {
-						req.setStorage('mobileRegister', util.phoneHintText(this.mobile));
-						this.downloadApp();
-					} else {
-						req.msg('当前手机号已经注册过了');
-					}
-				},
-				true
-			);
-		},
-
-		/**
-		 * 下载app
-		 */
-		downloadApp() {
-			this.jump('/pages/downloadApp/index?appId=' + this.appId);
-		},
-
-		// // 去下载
-		// downloadApp() {
-		// 	var u = navigator.userAgent;
-		// 	var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1;
-		// 	var isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/);
-		// 	// 这里是iOS浏览器
-		// 	if (isIOS) {
-		// 		if (this.config.download_app_ios_url) {
-		// 			window.location.href = this.config.download_app_ios_url; // 跳AppStore下载地址
-		// 		} else {
-		// 			this.showModal('后台暂未开放IOS App版本下载');
-		// 		}
-		// 	} else {
-		// 		// 是微信内部webView
-		// 		// if (is_weixn()) {
-		// 		// 	this.showModal('请点击右上角“...”按钮, 选择在浏览器打开');
-		// 		// } else {
-		// 		if (this.config.download_app_android_url) {
-		// 			window.location.href = this.config.download_app_android_url; // 跳AppStore下载地址
-		// 		} else {
-		// 			this.showModal('后台暂未开放Android App版本下载');
-		// 		}
-		// 		// }
-		// 	}
-		// },
-
-		// // 是微信浏览器
-		// is_weixn() {
-		// 	var ua = navigator.userAgent.toLowerCase();
-		// 	if (ua.match(/MicroMessenger/i) == 'micromessenger') {
-		// 		return true;
-		// 	} else {
-		// 		return false;
-		// 	}
-		// },
-
-		// IsPC() {
-		// 	var userAgentInfo = navigator.userAgent;
-		// 	var Agents = ['Android', 'iPhone', 'SymbianOS', 'Windows Phone', 'iPad', 'iPod'];
-		// 	var flag = true;
-		// 	for (var v = 0; v < Agents.length; v++) {
-		// 		if (userAgentInfo.indexOf(Agents[v]) > 0) {
-		// 			flag = false;
-		// 			break;
-		// 		}
-		// 	}
-		// 	return flag;
-		// },
-
-		showModal(msg) {
-			uni.showModal({
-				title: '提示',
-				content: msg,
-				confirmText: '关闭',
-				showCancel: false,
-				success(res) {}
-			});
-		}
-	}
-};
-</script>
-
-<style>
-page {
-	background: transparent;
-}
-.wdbg {
-	display: block;
-	width: 100%;
-	height: auto;
-	position: absolute;
-	top: 0;
-	left: 0;
-	z-index: -1;
-}
-.logo-box {
-	padding-top: 40rpx;
-}
-.logo-image {
-	width: 100rpx;
-	height: 100rpx;
-	margin: auto;
-}
-.logo-text {
-	text-align: center;
-	margin-top: 10rpx;
-}
-.logo-image image {
-	width: 100%;
-	height: 100%;
-}
-.form-bar {
-	background-color: #fff;
-	border-radius: 50rpx;
-	margin: 600rpx 50rpx 50rpx 50rpx;
-	z-index: 2;
-}
-.form-bar::before {
-	content: '';
-	display: block;
-	clear: both;
-}
-.form-ba::after {
-	content: '';
-	display: block;
-	clear: both;
-}
-.form-box {
-	padding: 30rpx 40rpx 100rpx 40rpx;
-}
-.form-box .form-item {
-	display: flex;
-	padding: 20rpx 10rpx;
-	border-bottom: 1rpx solid #ebebeb;
-	align-items: center;
-}
-.form-box .form-item:last-of-type {
-	border-bottom: none;
-}
-.form-box .form-item input {
-	flex: 1;
-}
-.form-box .form-item .form-icon {
-	width: 30rpx;
-	height: 30rpx;
-	margin-right: 10rpx;
-}
-.placeholder {
-	color: #999;
-}
-.ipt {
-	font-size: 30rpx;
-	color: #333;
-	height: 70rpx;
-	line-height: 70rpx;
-}
-
-.number86 {
-	font-size: 30rpx;
-	padding-right: 20rpx;
-	margin-right: 20rpx;
-	border-right: 1rpx solid #ebebeb;
-}
-.code-btn {
-	padding: 10rpx 20rpx;
-	border-radius: 10rpx;
-	border: 2rpx solid #999;
-}
-
-.or-text {
-	color: #ff7116;
-	font-size: 30rpx;
-	padding-left: 10rpx;
-	padding-right: 10rpx;
-}
-.or-text-b {
-	margin: 20rpx auto;
-	text-align: center;
-}
-
-.or-text-b text {
-	color: #333;
-}
-
-.gary-text {
-	color: #999;
-	font-size: 24rpx;
-}
-.noborder {
-	border: none !important;
-}
-.submit-btn {
-	background-color: #ff7116;
-	color: #fff;
-	border-radius: 50rpx;
-	padding: 20rpx 50rpx;
-	text-align: center;
-	font-weight: bold;
-	margin-top: 50rpx;
-}
-.footer-bar {
-	/* margin: 50rpx auto; */
-	position: absolute;
-	bottom: 20rpx;
-	width: 100%;
-	text-align: center;
-}
-.footer-bar text {
-	color: #333;
-	text-decoration: underline;
-}
-.footer-bar view {
-	margin: 10rpx auto;
-}
-</style>

+ 0 - 2
pages/userAgreement/index.css

@@ -1,2 +0,0 @@
-/* index.css */
-.content{padding: 40rpx 30rpx;}

+ 0 - 39
pages/userAgreement/index.vue

@@ -1,39 +0,0 @@
-<template>
-	<view>
-		<view class="content"><rich-text :nodes="content"></rich-text></view>
-	</view>
-</template>
-
-<script>
-const req = require('../../utils/request.js');
-
-export default {
-	data() {
-		return {
-			appId: '',
-			content: ''
-		};
-	},
-	onLoad(opt) {
-		this.appId = opt.appId;
-		this.getConfig();
-	},
-	methods: {
-		getConfig() {
-			req.getRequest(
-				'/api/protocol',
-				this.appId,
-				{},
-				data => {
-					this.content = data;
-				},
-				true
-			);
-		}
-	}
-};
-</script>
-
-<style>
-@import './index.css';
-</style>

BIN
static/bg.png


تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 3 - 0
static/iconfont.css


BIN
static/iconfont.eot


+ 50 - 0
static/iconfont.svg

@@ -0,0 +1,50 @@
+<?xml version="1.0" standalone="no"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
+<!--
+2013-9-30: Created.
+-->
+<svg>
+<metadata>
+Created by iconfont
+</metadata>
+<defs>
+
+<font id="iconfont" horiz-adv-x="1024" >
+  <font-face
+    font-family="iconfont"
+    font-weight="500"
+    font-stretch="normal"
+    units-per-em="1024"
+    ascent="896"
+    descent="-128"
+  />
+    <missing-glyph />
+    
+    <glyph glyph-name="shandian-shi" unicode="&#58972;" d="M749.25056 515.28704a40.96 40.96 0 0 1-35.27168 20.1472h-125.47072l145.41824 233.98912a40.94464 40.94464 0 0 1 1.00864 41.51808 40.93952 40.93952 0 0 1-35.79904 21.05856h-307.2a40.96 40.96 0 0 1-40.25344-33.3824l-81.92-435.04128a40.94976 40.94976 0 0 1 8.72448-33.72032 40.94976 40.94976 0 0 1 31.52896-14.8224h116.61824l-39.13728-333.30176a40.96 40.96 0 0 1 76.53376-24.58112l285.78816 517.51424a40.9344 40.9344 0 0 1-0.56832 40.62208z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="bottom" unicode="&#58883;" d="M931.18286182-52.33764403999999c-2.09936338-1.04968125-3.89881758-2.69918086-6.07315781-3.5989084a106.91756807 106.91756807 0 0 0-118.76397452 19.34413242L90.16297138 671.56777148A91.99709385 91.99709385 0 0 0 94.21174355 807.65149277a108.04222705 108.04222705 0 0 0 145.45587832-3.82384072l642.705046-635.35727461 652.30213447 632.88302519a108.04222705 108.04222705 0 0 0 112.46588614 22.49317706A96.49572979 96.49572979 0 0 0 1711.54615185 734.69862128a92.82184365 92.82184365 0 0 0-28.7912663-66.80473593l-723.15564346-701.71214678c-1.42456816-1.34959043-3.44895381-1.87443106-4.94849883-3.22402236s-1.7994542-2.09936338-2.84913545-3.14904463a97.47043417 97.47043417 0 0 0-20.54376826-12.07133877z"  horiz-adv-x="1877" />
+
+    
+    <glyph glyph-name="right" unicode="&#58882;" d="M749.19598929 383.9853693a45.19583181 45.19583181 0 0 1-1.70028115 9.21314902c-0.59312112 2.01661168-0.59312112 3.9541411-1.30486601 5.97075279a42.50701597 42.50701597 0 0 1-10.28076674 14.66986293L350.97444937 767.02300741A48.08235443 48.08235443 0 0 1 287.31277957 767.85337761a38.94828844 38.94828844 0 0 1 0.94899395-58.28403814l354.80507148-325.50488715L288.26177352 58.480482929999994a38.9087477 38.9087477 0 0 1-0.94899395-58.20495511 47.92418916 47.92418916 0 0 1 63.54304603 0.83036943l384.93562526 353.14433184a43.10013712 43.10013712 0 0 1 10.28076674 14.66986372 43.77234048 43.77234048 0 0 1 1.3444083 5.97075278 42.19068467 42.19068467 0 0 1 1.77936339 9.09452372z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="zhifu" unicode="&#59086;" d="M870.42895508 243.10034180000002H568.85424805c-79.1015625 0-143.37158203 61.7980957-143.37158203 140.8996582s64.27001953 140.8996582 143.37158203 140.8996582h299.1027832v-281.7993164zM568.85424805 497.70849609c-64.27001953 0-118.65234375-51.91040039-118.65234375-113.70849609s51.91040039-113.70849609 118.65234375-113.70849609h274.38354492v229.88891601H568.85424805zM759.19238281-11.5078125H264.80761719c-61.7980957 0-111.23657227 51.91040039-111.23657227 113.70849609V665.79931641C153.57104492 727.59741211 205.48144531 779.5078125 264.80761719 779.5078125h494.38476562c61.7980957 0 111.23657227-51.91040039 111.23657227-113.70849609V606.47314453c0-7.41577148-4.94384766-12.35961914-12.35961914-12.35961914s-14.83154297 4.94384766-14.83154297 12.35961914V665.79931641c0 49.43847656-39.55078125 88.98925781-86.51733399 88.98925781H264.80761719C217.84106445 754.78857422 180.76220703 712.76586914 180.76220703 665.79931641v-561.12670899c0-49.43847656 39.55078125-88.98925781 86.51733399-88.98925781H759.19238281c46.96655273 0 86.51733398 39.55078125 86.51733399 88.98925781v44.49462891c0 7.41577148 4.94384766 12.35961914 12.35961914 12.35961914s12.35961914-4.94384766 12.35961914-12.35961914v-44.49462891c0-64.27001953-51.91040039-116.18041992-111.23657227-116.18041992zM586.15771484 381.52807616999996m-49.43847656 0a49.43847656 49.43847656 0 1 1 98.87695313 0 49.43847656 49.43847656 0 1 1-98.87695313 0Z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="haoyou" unicode="&#58920;" d="M627.362909 272.896c-129.210182 0-234.309818 105.122909-234.309818 234.309818S498.152727 741.538909 627.362909 741.538909s234.309818-105.122909 234.309818-234.333091-105.099636-234.309818-234.309818-234.309818z m0 422.097455c-103.540364 0-187.764364-84.247273-187.764364-187.787637 0-103.540364 84.247273-187.764364 187.764364-187.764363 103.540364 0 187.764364 84.247273 187.764364 187.764363 0 103.540364-84.224 187.787636-187.764364 187.787637zM948.270545-28.904727c-10.821818 168.587636-151.761455 300.660364-320.907636 300.660363-169.099636 0-310.062545-132.026182-320.907636-300.590545l-46.452364 3.002182c12.427636 192.977455 173.777455 344.133818 367.36 344.133818 193.605818 0 354.978909-151.202909 367.36-344.203636l-46.452364-3.002182zM416.302545 302.545455c-129.210182 0-234.309818 105.122909-234.309818 234.309818S287.092364 771.188364 416.302545 771.188364v-46.545455c-103.540364 0-187.764364-84.247273-187.764363-187.787636 0-103.540364 84.247273-187.764364 187.764363-187.764364v-46.545454zM95.394909 0.791273l-46.452364 3.002182c12.427636 192.977455 173.777455 344.157091 367.36 344.15709v-46.545454c-169.099636 0-310.062545-132.049455-320.907636-300.613818z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="dingdan" unicode="&#58935;" d="M362.1 197.89999999999998h-29.2c-16.1 0-29.2 13.2-29.2 29.2 0 16.1 13.1 29.2 29.2 29.2h29.2c16.1 0 29.2-13.2 29.2-29.2s-13.2-29.2-29.2-29.2zM362.1 437.5h-29.2c-16.1 0-29.2 13.2-29.2 29.2 0 16.1 13.1 29.2 29.2 29.2h29.2c16.1 0 29.2-13.2 29.2-29.2s-13.2-29.2-29.2-29.2zM689 197.89999999999998H484.5c-16.1 0-29.2 13.2-29.2 29.2 0 16.1 13.1 29.2 29.2 29.2H689c16.1 0 29.2-13.2 29.2-29.2 0.1-16-13.1-29.2-29.2-29.2zM689.1 437.5H484.5c-16.1 0-29.2 13.2-29.2 29.2 0 16.1 13.1 29.2 29.2 29.2H689c16.1 0 29.2-13.2 29.2-29.2 0.1-16-13.1-29.2-29.1-29.2zM781.3-64H242.8c-49.4 0-89.8 43.4-89.8 96.5V675.6c0 53.1 40.4 96.5 89.8 96.5 16.5 0 29.9-14.5 29.9-32.2 0-17.7-13.5-32.2-29.9-32.2-16.5 0-29.9-14.5-29.9-32.2v-643.2c0-17.7 13.5-32.2 29.9-32.2h538.5c16.5 0 29.9 14.5 29.9 32.2V675.6c0 17.7-13.5 32.2-29.9 32.2-16.5 0-29.9 14.5-29.9 32.2 0 17.7 13.5 32.2 29.9 32.2 49.4 0 89.7-43.4 89.7-96.5v-643.2c0-53.1-40.4-96.5-89.7-96.5zM601.8 773.5c11.2 0 18.6-5.8 22.1-9.3 3.5-3.5 9.3-10.9 9.3-22.1 0-11.2-5.8-18.6-9.3-22.1-3.5-3.5-10.9-9.3-22.1-9.3H422.2c-11.2 0-18.6 5.8-22.1 9.3-3.5 3.5-9.3 10.9-9.3 22.1 0 11.2 5.8 18.6 9.2 22.1 3.5 3.5 10.9 9.3 22.1 9.3h179.7m0 58.5H422.2c-49.4 0-89.7-40.4-89.7-89.8s40.4-89.8 89.7-89.8h179.5c49.4 0 89.8 40.4 89.8 89.8S651.1 832 601.8 832z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="yugao" unicode="&#58881;" d="M698.41473506 394.50068231h-153.44665665v124.0687257a33.49212716 33.49212716 0 1 1-66.98425516-1e-8v-166.23923553a31.88501982 31.88501982 0 0 1 29.66721063-26.4851376h189.63872579a34.00640244 34.00640244 0 0 1 0 68.012804z m121.20807392 267.32631886a425.69072578 425.69072578 0 0 1-306.82903007 124.5830001 447.9973831 447.9973831 0 0 1-306.8290292-124.5830001A428.22995625 428.22995625 0 0 1 78.07110752 360.23714268000003a421.41581894 421.41581894 0 0 1 127.86149972-301.5898585 425.69072578 425.69072578 0 0 1 306.82903007-124.58300012 447.9973831 447.9973831 0 0 1 306.8290292 124.58300012A428.29424033 428.29424033 0 0 1 945.90934385 360.23714268000003a421.48010391 421.48010391 0 0 1-126.31867734 301.58985849z m-48.21323554-558.0521288a372.84902051 372.84902051 0 0 0-520.09224083 0 359.31717158 359.31717158 0 0 0 0 512.89239814 372.84902051 372.84902051 0 0 0 520.09224083 0 358.7064706 358.7064706 0 0 0 107.9012206-256.43012783 352.4387502 352.4387502 0 0 0-107.77265155-256.46227031zM137.40552881 673.23746661l129.88645576 103.81916688A31.46717197 31.46717197 0 0 1 270.85976386 822.21636416a34.42425029 34.42425029 0 0 1-48.21323467 3.63206338L92.88864161 721.96497657a28.92794151 28.92794151 0 0 1-3.56777931-44.99902003 34.42425029 34.42425029 0 0 1 48.08466651-3.72848993z m750.71221699 0a38.57058809 38.57058809 0 0 1 48.21323467 3.63206337 34.64924502 34.64924502 0 0 1-3.5677793 45.15973067L802.87674541 825.84842753a38.57058809 38.57058809 0 0 1-48.21323554-3.63206337 30.92075508 30.92075508 0 0 1 3.56777929-45.15973067z"  horiz-adv-x="1024" />
+
+    
+    <glyph glyph-name="hot" unicode="&#58880;" d="M331.089737-128c-63.414857 142.628571-30.025143 224.768 20.004572 299.885714a506.88 506.88 0 0 1 66.742857 167.68 200.301714 200.301714 0 0 0 26.697143-149.942857 414.098286 414.098286 0 0 1 76.8 285.257143c166.838857-124.891429 240.237714-399.616 143.469714-599.405714 513.865143 313.965714 126.793143 781.385143 60.050286 831.341714 23.369143-53.504 26.697143-142.628571-20.004572-185.526857-76.8 313.965714-266.971429 374.637714-266.971428 374.637714 23.369143-160.548571-80.091429-335.396571-180.187429-467.382857a357.814857 357.814857 0 0 1-40.045714 171.264c-6.656-117.76-90.075429-210.505143-113.371429-328.265143-30.098286-160.475429 23.296-274.651429 226.816-399.542857z"  horiz-adv-x="1024" />
+
+    
+
+
+  </font>
+</defs></svg>

BIN
static/iconfont.ttf


BIN
static/iconfont.woff


BIN
static/images/rico.png


BIN
static/logo-ningmeng.png


BIN
static/logo.png


BIN
static/member.png


BIN
static/openGuide.png


BIN
static/pages/images/close3.png


+ 29 - 0
static/stylesheet.css

@@ -0,0 +1,29 @@
+@font-face {
+  font-family: 'iconfont';
+  src: url('data:application/font-woff2;charset=utf-8;base64,d09GMgABAAAAAAM8AA0AAAAAB+wAAALoAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAP0ZGVE0cGh4GVgCCUhEICoMggwsLDgABNgIkAxQEIAWFCAdXG+EGyJ6HsRuiiAFVXP7y0dGxFQ//P9e/+9xkKPmEpJC5QCSfEQVbBcC6q3J8am3/FvMQdzrmCU9EyydijUq70kldO3/6b/NC5L2RfM+90ybhWPbVAuquMSdP2oPDgKL/AsvmomxTAoFlKYfcgp5BQUz4rJMQ8Pl7Q+vw7bW2561LE7RCF5CETEXIkRC5eEqF9HD6GDwJ749/MSHqJJWMNXbl/j2P1R8zPJLdbN601aB4IQHIkKEXApbKCvSSMw7U1SX+mGGWR5pNaWn37u8+ECQUVYIokZD8PAGeFM2mBKqgFWp4Cu8DcgAkSdYTKLVRJ+LWi10fvRaPvBCYVpaPPs/NzxAqibufe46bz8vKLwk6oi8UxSOcX36muT3X6ZHTkNbnijFhEGDPrhdfHND4yGeOVNc+ygnFl16pcClBKZUbKbjhiy/W94fWfv75ugSKgGKcMCy2/C5dmD+1rPi+8vapz4nvQ09ncbp0F5XvZqXfld3OynwDKU9NpsPbMj4rFg5Hesyf8sWlkRUdzcJY/7fvcx/2Evv/bqeWliQrb4uAZXnC/DezT74ZKt9kQAV/PhAIvmt5bfKO5qz/6mVuw9vvrpFdSP+jLoFgYynJQXZB/ucAeQ7IkfO1rz0sUDVFFiQUCjQBdPAnAJ21ERDq1iIgqTmGgEzdAwFyde8IUFH6SICqup8FKIyM2QgodYwXZCJvYAQwK7SzYSVtbGNl2gmoOTNlVXTxYFW182IV1vufXBoSx1XM4RIw/JCXR7ESooJjMYkkvgrFswDcJ+M/47sbSo/2xcBqAklAx3Dhj2/1Dl6/RlxP4PIohdRAVx+uFfsfdPujUhcMNgnc9TzHE5IM+XwiSuSyGKjDJL4h0OkslM1lUQk4vi48aEj1Qmno++LVJb5Tiyd58r8Pu4GD0wdruKWeHnHKni5unjqc/OvEkfHoqdgx96KQtqoipEiRRd529y5LVZhTOslZQ7dW2TksnpXCpqow') format('woff2'),
+    url('data:application/font-woff;charset=utf-8;base64,d09GRgABAAAAAAU0AA0AAAAAB+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABGRlRNAAAFGAAAABoAAAAcjJ5F9UdERUYAAAT4AAAAHgAAAB4AKQAMT1MvMgAAAaAAAABCAAAAVjyoSHxjbWFwAAAB+AAAAEcAAAFS5lbQmGdhc3AAAATwAAAACAAAAAj//wADZ2x5ZgAAAlAAAAEaAAABoKmS0JVoZWFkAAABMAAAADAAAAA2Ghhi6WhoZWEAAAFgAAAAHQAAACQHVQOFaG10eAAAAeQAAAARAAAAFAzZAWJsb2NhAAACQAAAAA4AAAAOARoAlG1heHAAAAGAAAAAHwAAACABEwBCbmFtZQAAA2wAAAFJAAACiCnmEVVwb3N0AAAEuAAAADcAAABXLky9wXjaY2BkYGAA4jdrZqyN57f5ysDNwgACt2v5y+B0JwMncznTdyCXg4EJJAoAOwsKV3jaY2BkYGBu+N/AEMPCAALM5QyMDKiABQBPywLjAAAAeNpjYGRgYGBjMGNgZgABJiDmAkIGhv9gPgMADncBVgB42mNgZGFgnMDAysDA1Ml0hoGBoR9CM75mMGLkAIoysDIzYAUBaa4pDA7PrJ51MTf8b2CIYW5gaAAKM4LkAOm9DJ8AAHjaY2GAABYIvgmEnQAIBQJIAAAAeNpjYGBgZoBgGQZGBhDwAfIYwXwWBgMgzQGETAwMz6ye2Tzr+v8fwZI8KXlCshqqCwwY2RjgXEagHpA+FMDIMOwBAF2/DpwAAAAAAAAAAAAASgCUANAAAHjafY6/SsNQFIfPuWkSvCFn6h+Q6nAvbRHBQtIktcVMUh10LDr7AA5dBNdAIWN9guKe9+gkgQ7ik7gVz02ogwXh8ON85zecDwR8wbM1EG9wDBFALxrFSZBo1b/CUTzFoH2CTRLMPUJe22GQCq7656gcw1N0xBnJW/teEskPSd3Jw6Wk3cbg+HHSrY4k7+zlk+fjimRpsJwt5kN/ib7H1+F8MSs93/e4WgHAHydsNR1XuWHl4vBj45YKZjtF46IVidoliGu3GD8PnXB84CRe91LV+3+kLMjhyHoR3+BBBzRbhS3d0pGOwii0UkwucEDonmKHF0ZeCIXK82selRWWVWR1rreNxnZdJb6bNt+p3zIrbvYlJ8APGOZTZAAAeNp9kD1OAzEQhZ/zByQSQiCoXVEA2vyUKRMp9Ailo0g23pBo1155nUg5AS0VB6DlGByAGyDRcgpelkmTImvt6PObmeexAZzjGwr/3yXuhBWO8ShcwREy4Sr1F+Ea+V24jhY+hRvUf4SbuFUD4RYu1BsdVO2Eu5vSbcsKZxgIV3CKJ+Eq9ZVwjfwqXMcVPoQb1L+EmxjjV7iFa2WpDOFhMEFgnEFjig3jAjEcLJIyBtahOfRmEsxMTzd6ETubOBso71dilwMeaDnngCntPbdmvkon/mDLgdSYbh4FS7YpjS4idCgbXyyc1d2oc7D9nu22tNi/a4E1x+xRDWzU/D3bM9JIbAyvkJI18jK3pBJTj2hrrPG7ZynW814IiU68y/SIx5o0dTr3bmniwOLn8owcfbS5kj33qBw+Y1kIeb/dTsQgil2GP5PYcRkAAAB42mNgYoAALjDJyIAO2MCiTIxMjMyMLPxJiflZmYmFpfkliSWZ+XkCaHwj9pLMxDygCABS5A/vAAAAAAH//wACAAEAAAAMAAAAFgAAAAIAAQADAAUAAQAEAAAAAgAAAAB42mNgYGBkAIKrS9Q5QPTtWv4yGA0AOiEFZAAA') format('woff'),
+    url('./static/iconfont.ttf') format('truetype');
+  font-weight: normal;
+  font-style: normal;
+  font-display: swap;
+}
+
+.iconfont {
+  font-family: "iconfont" !important;
+  font-size: 16px;
+  font-style: normal;
+  -webkit-font-smoothing: antialiased;
+  -moz-osx-font-smoothing: grayscale;
+}
+
+.icontianjia:before {
+  content: "\e68a";
+}
+
+.iconbaojiaquotation:before {
+  content: "\e63a";
+}
+
+.iconbaojiaquotation2:before {
+  content: "\e63c";
+}

+ 59 - 20
utils/request.js

@@ -1,15 +1,15 @@
 const app = getApp();
 // download.zhiqiyun.com  域名
 const env = {
-	NODE_ENV: 'prd',
+	NODE_ENV: 'pota',
 	dev: {
-		apiUrl: 'https://apitest.tongyu99.com',
+		apiUrl: 'https://rsapi.zhiqiyun.net'
 	},
 	prd: {
 		apiUrl: 'https://apimall.zhiqiyun.com',
 	},
 	pota: {
-		apiUrl: 'http://192.168.110.59:8098' //
+		apiUrl: 'http://192.168.110.180:8098' ,//wjg
 	}
 }
 
@@ -89,18 +89,18 @@ const clearValueEmpty = (data) => {
  * @param {*} success 成功函数
  * @param {*} isLoad 是否显示加载提示
  */
-const baseRequest = (url, appId, data, method, success, isLoad) => {
-	header['appId'] = appId;
+const baseRequest = (url, data, method, success, isLoad) => {
 	getToken(token => {
 		if (isLoad) {
 			load('加载中')
 		}
 		header.authorityToken = token;
-		if (url.indexOf('/v3') != -1 || url.indexOf('/paper/create') != -1) {
-			header['content-type'] = 'application/json;charset=UTF-8'
-		} else {
-			header['content-type'] = 'application/x-www-form-urlencoded'
-		}
+		// if (url.indexOf('/v3') != -1 || url.indexOf('/paper/create') != -1) {
+		// 	header['content-type'] = 'application/json;charset=UTF-8'
+		// } else {
+		// 	header['content-type'] = 'application/x-www-form-urlencoded'
+		// }
+		header['content-type'] = 'application/json;charset=UTF-8'
 		try {
 			var device_info = {};
 			//第三放巨量投放渠道标记
@@ -116,6 +116,8 @@ const baseRequest = (url, appId, data, method, success, isLoad) => {
 					'');
 			header['device-info'] = deviceinfoString;
 		} catch (e) {}
+		console.log('H5请求url===>',env[env.NODE_ENV].apiUrl + url,'请求方式 '+method)
+		console.log('H5请求data===>',clearValueEmpty(data))
 		uni.request({
 			url: env[env.NODE_ENV].apiUrl + url,
 			data: clearValueEmpty(data),
@@ -133,6 +135,7 @@ const baseRequest = (url, appId, data, method, success, isLoad) => {
 				if (typeof data === 'string' && data.indexOf("{") === 0) {
 					data = JSON.parse(data);
 				}
+				console.log('H5请求返回===>',data)
 				success.call(this, data);
 			},
 			fail() {
@@ -152,29 +155,50 @@ const loadIng = (msg) => {
 }
 
 /**POST请求 */
-const postRequest = (url, appId, data, success, isLoad) => {
+const postRequest = (url, data, success, isLoad) => {
 	header['content-type'] = 'application/x-www-form-urlencoded'
-	baseRequest(url, appId, data, 'post', success, isLoad);
+	baseRequest(url, data, 'post', success, isLoad);
 }
 
-const postRequestLoding = (url, appId, data, success, isLoding) => {
+const postRequestLoding = (url, data, success, isLoding) => {
 	header['content-type'] = 'application/x-www-form-urlencoded'
-	baseRequest(url, appId, data, 'post', success, false, isLoding);
+	baseRequest(url, data, 'post', success, false, isLoding);
 }
 
 /**GET请求 */
-const getRequest = (url, appId, data, success, isLoad) => {
+const getRequest = (url, data, success, isLoad) => {
 	header['content-type'] = 'application/x-www-form-urlencoded'
-	baseRequest(url, appId, data, 'get', success, isLoad);
+	baseRequest(url, data, 'get', success, isLoad);
 }
 /**Put请求 */
-const putRequest = (url, appId, data, success, isLoad) => {
+const putRequest = (url, data, success, isLoad) => {
 	header['content-type'] = 'application/x-www-form-urlencoded'
-	baseRequest(url, appId, data, 'put', success, isLoad)
+	baseRequest(url, data, 'put', success, isLoad)
 }
-const putRequestJson = (url, appId, data, success, isLoad) => {
+const putRequestJson = (url, data, success, isLoad) => {
 	header['content-type'] = 'application/json;charset=UTF-8'
-	baseRequest(url, appId, data, 'put', success, isLoad)
+	baseRequest(url, data, 'put', success, isLoad)
+}
+
+const uploadFile = (url, data, success) => {
+	// console.log(env[env.NODE_ENV].apiUrl + url, data)
+	getToken(token => {
+		uni.uploadFile({
+			url: env[env.NODE_ENV].apiUrl + url,
+			filePath: data,
+			name: 'file',
+			header: {
+				'appId': header['appId'],
+				'authorityToken': token
+			},
+			success(res) {
+				if (res.statusCode !== 200) return msg('文件上传失败');
+				let data = JSON.parse(res.data);
+				if (data.code !== 0) return msg(data.msg);
+				success.call(this, data.data);
+			},
+		})
+	})
 }
 
 
@@ -223,6 +247,19 @@ const removeStorage = (key) => {
 	return uni.removeStorageSync(env.NODE_ENV + "_" + key);
 }
 
+const silenceLogin = (saleNo) => {
+	return new Promise((resolve, reject) => {
+		let params = {
+			saleNo: saleNo
+		}
+		postRequest('/api/h5/login', params, data => {
+			if(data) setStorage('userInfo', data);
+			if (data.token) setStorage('AUTH_TOKEN', data.token);
+			resolve();
+		});
+	});
+}
+
 module.exports = {
 	setStorage: setStorage,
 	getStorage: getStorage,
@@ -239,4 +276,6 @@ module.exports = {
 	public: publics,
 	header: header,
 	excludeSpecial: excludeSpecial,
+	silenceLogin:silenceLogin,
+	uploadFile:uploadFile
 }

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است