兼容列表用户头像与昵称

master
chen 2022-01-24 13:53:00 +08:00
parent dea606c274
commit 3f00d3c0ac
66 changed files with 295 additions and 268 deletions

View File

@ -24,6 +24,7 @@
uni.removeStorageSync('quanImg');
uni.removeStorageSync('quanId');
uni.removeStorageSync('isQuan');
uni.removeStorageSync('firstTime');
}
};
</script>

View File

@ -165,7 +165,8 @@
city: userInfo.city,//
gender: userInfo.gender,//
language:userInfo.language,//
is_active:1
is_active:1,
channel:uni.getStorageSync('channel')
}
this.$requst.post('user/login',params).then(res => {
if(res.data.token!=''){
@ -178,6 +179,7 @@
ya.successAfterEv(userInfo);
ya.isAnimation++;
ya.userInfo_mobile = false;
ya.$emit('onload');
}
},error => {})
},
@ -199,6 +201,9 @@
if(res.code==0){
this.$toolAll.tools.showToast('手机号绑定成功','success');
this.visible = false;
uni.reLaunch({
url:'/pages/tabbar/my/staffDuan'
})
}
},error=>{})
} else {

View File

@ -2,7 +2,7 @@
<view>
<scroll-view scroll-x >
<view class="" :class="isCenter?'disac':'disjb'">
<view @tap="choosecate(index)" v-if="item.title!='' && item.title!=''"
<view @tap="choosecate(index)" v-if="item.title!='仿'"
:style="{
background : newCurrent==index ? activeb:newbmo,
fontSize:newfmo+'px',

View File

@ -117,7 +117,6 @@
}
this.$requst.post('user/login',params).then(res => {
if(res.data.token!=''){
console.log('第一次登录');
uni.setStorageSync('params',params)
uni.setStorageSync('userId',res.data.account_id)
uni.setStorageSync('token',res.data.token)//token

View File

@ -63,7 +63,11 @@
},
methods:{
backEvent(){//
if(this.whereCome==1){
if(this.whereCome==0 && uni.getStorageSync('firstTime')==''){
uni.reLaunch({
url:'/pages/tabbar/pagehome/pagehome'
})
} else if(this.whereCome==1){
uni.reLaunch({
url:'/pages/tabbar/pagehome/pagehome'
})

View File

@ -979,10 +979,11 @@ var QRCode;
// QRCode object
QRCode = function(canvasId, vOption) {
console.log(123);
this._htOption = {
width: 256,
height: 256,
typeNumber: 4,
width: 162,
height: 162,
typeNumber: 2,
colorDark: "#000000",
colorLight: "#ffffff",
correctLevel: QRErrorCorrectLevel.H

View File

@ -38,7 +38,7 @@
created() {
setTimeout(() => {
this.couponQrCode()
}, 50)
}, 0)
},
methods: {
//

View File

@ -4,8 +4,8 @@ console.log('当前环境', process.env.NODE_ENV)
const apiHub = {
//开发环境
development: {
BASE_URL: `https://hengmei.scdxtc.cn/api/`,
// BASE_URL: "https://hm.hmzfyy.cn/api/",
// BASE_URL: `https://hengmei.scdxtc.cn/api/`,
BASE_URL: "https://hm.hmzfyy.cn/api/",
IMG_URL: "https://xx",
BASE_UPLOAD_URL: "",
},

View File

@ -1,5 +1,5 @@
const domainName = 'https://hengmei.scdxtc.cn/api/'//域名配置
// const domainName = 'https://hm.hmzfyy.cn/api/'//域名配置
// const domainName = 'https://hengmei.scdxtc.cn/api/'//域名配置
const domainName = 'https://hm.hmzfyy.cn/api/'//域名配置
// 统一给参数
const dataObj = (url, params) => {
let options = params

8
jsFile/share.js Normal file
View File

@ -0,0 +1,8 @@
export default {
onShareAppMessage(res) { //发送给朋友
return {}
},
onShareTimeline(res) {//分享到朋友圈
return {}
},
}

View File

@ -291,7 +291,7 @@ const tools = {
language:obj.language
}
uni.request({
url: `https://hengmei.scdxtc.cn/api/user/login`,
url: `https://hm.hmzfyy.cn/api/user/login`,
method: 'post',
data: params,
header: {
@ -383,7 +383,7 @@ const tools = {
},
isVedio(){//是否显示视频内容
uni.request({
url: `https://hengmei.scdxtc.cn/api/index/base-config`,
url: `https://hm.hmzfyy.cn/api/index/base-config`,
method: 'get',
header: {
'Content-Type': 'application/json; charset=UTF-8',
@ -397,7 +397,7 @@ const tools = {
} else {
uni.setStorageSync('isVedio',true);
}
// console.log(uni.getStorageSync('isVedio/'));
console.log(uni.getStorageSync('isVedio'));
}
}
})

View File

@ -22,7 +22,9 @@ import empower from './components/empower.vue'//引入用户授权组件
Vue.component('empower',empower)//全局注册用户授权组件
import authUserInfoMobile from './components/auth-userInfo-mobile.vue'//引入授权用户信息,授权手机号组件
Vue.component('auth-userInfo-mobile',authUserInfoMobile)//全局注册授权用户信息,授权手机号组件
// 全局注册分享事件
import share from './jsFile/share.js'
Vue.mixin(share)
// 常用工具
import tools from '@/jsFile/tools.js'

View File

@ -412,7 +412,7 @@
is_hot:1
}
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/list`,
url:`https://hm.hmzfyy.cn/api/spu/list`,
data:params,
method:'post',
header:{

View File

@ -9,11 +9,11 @@
<view class="disjbac">
<view class="disac colf">
<!-- 头像 -->
<image class="mar-sx30" :src="userInfo.headimgurl || ''" mode="aspectFill"></image>
<image @tap="openXiao" class="mar-sx30" :src="userInfo.headimgurl || ''" mode="aspectFill"></image>
<view class="mar-z30">
<!-- 昵称 -->
<view class="disac">
<view class="fon36 bold">{{userInfo.nickname || ''}}</view>
<view class="fon36 bold clips1" style="max-width: 260rpx;">{{userInfo.nickname || ''}}</view>
<view class="gao-name">{{userInfo.level.name}}</view>
</view>
<view class="disac mar-s10" v-if="userPhone!==''">
@ -283,10 +283,12 @@
},error=>{})
},
onUnload() {
//
this.closeqr();
},
onLoad(options) {
this.optionObj = options;
uni.setStorageSync('channel',options.channel);
if(uni.getStorageSync('gao')==''){
const query = wx.createSelectorQuery()
query.select('.gao').boundingClientRect((rect) => {
@ -393,6 +395,7 @@
clearInterval(this.timer);
},60000)
},
//
closeqr(){
this.isQrcode = false;
clearInterval(this.timer);
@ -571,7 +574,7 @@
onlyFromCamera: false, //,
scanType: ['qrCode'], // scanType :
success: (rt) => { //
let narr = rt.result.split(',');
let narr = rt.result.split('H');
if(narr[1]=='true'){//
this.$requst.post('staff/coupon/write-off-experience-coupon',{coupon_id:narr[0],secret:narr[2],account_id:narr[3]}).then(res=>{
this.isQian = true

View File

@ -156,6 +156,7 @@
this.isAutoPlay = false;
},
onShow() {
uni.setStorageSync('firstTime',1);
log('输出的解构')
this.checkNet()
this.$toolAll.tools.isLogin()
@ -185,6 +186,7 @@
  return shareObj;
},
onLoad(options) {
this.$toolAll.tools.isVedio();
if(options.source_code!='' && options.source_code!=undefined){
this.loginEv(options);
} else if(options.q!=undefined){

View File

@ -34,7 +34,7 @@
<view v-if="showDoctor" class="posia" style="top: 52px;left: 0;right: 0;border: 1rpx solid #E6E6E6;padding: 20rpx;background: #FFFFFF;">
<view @tap="chooseDoctor(index)" class="disjbac fon28 col9" v-for="(item,index) in doctorList" :key="index">
<span>姓名{{item.doctor_extra.name}}</span>
<span>部门{{item.doctor_extra.skill}}</span>
<!-- <span>部门{{item.doctor_extra.skill}}</span> -->
</view>
</view>
</view>
@ -221,8 +221,8 @@
if(res.code==0){
this.doctor_name = '';
if(res.data.list.length!=0){
this.doctorList = res.data.list;
this.showDoctor = true;
this.doctorList = res.data.list;
} else this.$toolAll.tools.showToast('暂无医生可选');
} else this.$toolAll.tools.showToast(res.msg);
})
@ -311,7 +311,7 @@
disease_id:this.disease_id//ID
}
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/list`,
url:`https://hm.hmzfyy.cn/api/spu/list`,
data:params,
method:'post',
header:{

View File

@ -158,19 +158,19 @@
this.$requst.post('user/exhibition-experience-coupon',{coupon_id:this.dataList[index].id}).then(res=>{
if(res.code==0){
this.isTY = true;
this.text = `${this.dataList[index].id},true,${res.data.secret},${uni.getStorageSync('userId')}`;
this.text = `${this.dataList[index].id}HtrueH${res.data.secret}H${uni.getStorageSync('userId')}`;
this.secret = res.data.secret;
} else this.$toolAll.tools.showToast(res.msg);
},error=>{})
this.timer = setInterval(()=>{
this.$requst.post('staff/coupon/write-off-experience-couponQuery',{coupon_id:this.dataList[index].id,secret:this.secret}).then(res=>{
if(res.code==0){
if(res.data.result==0){
// if(res.data.result==0){
this.$toolAll.tools.showToast('使用成功');
this.isTY = false;
clearInterval(this.timer);
this.checkAllList(0);
}
// }
}
})
},3000)

View File

@ -90,7 +90,7 @@
<!-- 快递费用 -->
<view v-if="isExpress" class="bacf radius20 mar-s20 disjbac pad-sx27-zy20">
<view class="bold">快递费用</view>
<view class="fon28 colf8 bold">{{expressInfo.default_price}}.00</view>
<view class="fon28 colf8 bold">{{expressInfo.default_price}}</view>
</view>
<view class="disjbac posixzy bacf pad-zy32" style="height: 124rpx;line-height: 124rpx;">
<!-- 去支付 -->
@ -264,7 +264,7 @@
this.loginEv('',options.source_code,options.channel);
}
this.checkexpress();//
this.checkeList();//
this.checkeList(options.isNei);//
this.checkOrderDetail();//
this.isNei = options.isNei;
if(this.isNei==3) {
@ -342,7 +342,7 @@
this.payFS[index].isActive = !this.payFS[index].isActive;
if(this.isNei==3){//
if(!this.payFS[0].isActive && !this.payFS[2].isActive){
this.$toolAll.tools.showToast('请选择支付方式')
this.$toolAll.tools.showToast('请选择支付方式');
this.allPrice = this.zanAllPrice;
this.isKq = false;
return;
@ -383,6 +383,11 @@
this.zf_kqPrice = 0;
return;
}
} else {
if(this.expressInfo.default_price==0){
this.$toolAll.tools.showToast('暂不可微信支付');
this.payFS[index].isActive = false;
}
}
}
if(this.payFS[index].title=='孔雀币') {
@ -511,7 +516,7 @@
this.$toolAll.tools.showToast('正在调起支付','loading',1500);
}
uni.request({
url:`https://hengmei.scdxtc.cn/api/order/create`,
url:`https://hm.hmzfyy.cn/api/order/create`,
data:parmas,
method:'post',
header:{
@ -673,12 +678,16 @@
} else this.$toolAll.tools.showToast(res.msg);
})
},
checkeList(){
checkeList(isJfen){
this.orderList.forEach(item=>{
this.allPrice += item.price*item.num;
this.allNum += item.num;
})
if(isJfen==3){
this.zanAllPrice = this.allPrice;
} else {
this.zanAllPrice = this.$toolAll.tools.addXiaoShu(this.allPrice);
}
this.quanEv(0);//
},
quanEv(index){//

View File

@ -71,7 +71,7 @@
<view class="bacf width100 radius20 pad30 posir" style="margin: 0 128rpx;" @tap.stop="isHeyan=true">
<view class="fon28 col3">订单二维码</view>
<view class="mar-sx30">
<yz-qr ref="qrPath" :text="text" :size="size" :colorDark="colorDark" :colorLight="colorLight"></yz-qr>
<yz-qr ref="qrPath" :text="text" :size="qsize" :colorDark="colorDark" :colorLight="colorLight"></yz-qr>
<!-- <image src="/static/public/member-head.png" class="order-hx-img" mode="aspectFill"></image> -->
</view>
<view class="fon24 col3">
@ -140,8 +140,8 @@
remarks:'',//
times:0,//
canvasQrPath: '',
text: 'hello',
size: 162,
text: '',
qsize: 162,
colorDark: '#000000',
colorLight: '#ffffff',
timer:null,
@ -205,7 +205,7 @@
},
make(index,index2){
this.isHeyan = true;
this.text = `${this.orderList[index].orderNum},${this.orderList[index].childrenList[index2].id}`;
this.text = `${this.orderList[index].orderNum}H${this.orderList[index].childrenList[index2].id}`;
let params = {
order_coding:this.orderList[index].orderNum,
id:this.orderList[index].childrenList[index2].id,

View File

@ -90,7 +90,6 @@
}
},
onShow() {
this.$toolAll.tools.isLogin();
this.isAutoPlay = true;
},
onUnload() {
@ -100,7 +99,7 @@
this.isAutoPlay = false;
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;this.whereCome = 2;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;this.whereCome = 2;} else {this.$toolAll.tools.isLogin();}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){

View File

@ -109,20 +109,18 @@
  };
  return shareObj;
},
onShow() {
this.$toolAll.tools.isLogin()
},
onLoad(options) {
this.checkDetail(options.id)
this.detailId = options.id
this.category_id = options.category_id
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
console.log(options,'参数');
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
this.loginEv('',options.source_code,options.channel);
}
ckAbout(this.category_id)
this.checkAbout(this.category_id)
},
onReachBottom() {//
if(this.total!=this.dataList.length){

View File

@ -24,18 +24,20 @@
<!-- 列表 -->
<view v-if="dataList.length!=0" class="dis bacf radius10 pad20 mar-x20 posir" v-for="(item,index) in dataList" :key="index">
<image class="mar-y20 flexs" :src="item.imgSrc" style="width: 98rpx;height: 98rpx;" mode="aspectFill"></image>
<view class="fon24 col3 width100 mar-x40" style="margin-bottom: 80rpx;">
<view class="fon24 col3 width100 mar-x40" style="margin-bottom: 120rpx;">
<view class="bold disjbac">
<view class="fon28 clips1">{{item.name}}</view>
<view class="flexs">来源{{item.come}}</view>
</view>
<view style="margin: 15rpx 0;">联系方式{{item.phone || '暂无'}}</view>
<view style="margin: 15rpx 0;" @tap="copyPhone(item.phone)">{{item.phone || ''}}</view>
<view>客服{{item.service || '暂无'}}</view>
<view class="col80 disjbac" style="margin: 15rpx 0 0 0;">
<view>{{item.time}}</view>
<view class="col3">{{item.qudao}}</view>
</view>
</view>
<!-- 真实姓名 -->
<view class="posia col3 fon24 radius10 tc" style="left: 20rpx;bottom: 100rpx;">姓名{{item.real_name || '暂无'}}</view>
<!-- 分配客服 -->
<view @tap="fenCustomer(index)" class="posia colf fon24 radius10 tc customer-btn" style="right: 20rpx;top: 80rpx;z-index: 1;" v-if="item.customer=='' || item.customer==null" :style="{background:publicColor}"></view>
<!-- 设置标签 -->
@ -152,6 +154,15 @@
this.obtainTag();//
},
methods: {
//
copyPhone(e){
uni.setClipboardData({
data: e,//
success:(res) => {
uni.showToast({title:'复制成功' })
}
});
},
//
closeXial(){
// this.isShowTag = false;
@ -286,7 +297,8 @@
service:item.service,
source_detail:item.source_detail,
tags:item.tag,
isTag:!item.tag.includes('员工')
isTag:!item.tag.includes('员工'),
real_name:item.real_name
}
this.dataList.push(cuObj);
})

View File

@ -78,10 +78,10 @@
}
},
onShow() {
this.$toolAll.tools.isLogin()
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){

View File

@ -110,12 +110,11 @@
}
},
onShow() {
this.$toolAll.tools.isLogin()
this.checkConList(this.category_id)
},
onLoad(options) {
this.checkDoD(options.doctor_id)
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){

View File

@ -185,12 +185,11 @@
clearInterval(this.collectionTime);
},
onShow() {
this.$toolAll.tools.isLogin()
this.checkConList(this.category_id);
this.shopCollection();
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
@ -238,7 +237,7 @@
if(index==1){
this.isWen = false;
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/collection`,
url:`https://hm.hmzfyy.cn/api/spu/collection`,
data:{page:this.page,size:this.size},
method:'post',
header:{

View File

@ -83,11 +83,8 @@
this.isZanw = false
}
},
onShow() {
this.$toolAll.tools.isLogin()
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
@ -108,7 +105,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -123,7 +119,6 @@
}
}
},error => {})
}
},
});
},

View File

@ -166,11 +166,8 @@
onUnload() {
this.closeEv();
},
onShow() {
this.$toolAll.tools.isLogin();
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin();}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
@ -183,7 +180,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -198,7 +194,6 @@
}
}
},error => {})
}
},
});
},
@ -227,7 +222,7 @@
},
make(index){
this.isHeyan = true;
this.text = `${this.orderInfo.coding},${this.orderInfo.skus[index].id}`;
this.text = `${this.orderInfo.coding}H${this.orderInfo.skus[index].id}`;
let params = {
order_coding:this.orderInfo.coding,
id:this.orderInfo.skus[index].id,

View File

@ -55,12 +55,8 @@
isShowP:false,
}
},
onShow() {
this.$toolAll.tools.isLogin()
this.haved = true;
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin() ;this.haved = true;}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
@ -77,7 +73,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -92,7 +87,6 @@
}
}
},error => {})
}
},
});
},

View File

@ -247,8 +247,6 @@
this.isAutoPlay = false;
},
onLoad(options) {
//token
this.$toolAll.tools.overdue();
if (options.category_id != undefined) {
this.category_id = options.category_id
if(options.invite_code!=undefined){this.invite_code = options.invite_code;}
@ -263,6 +261,9 @@
if(uni.getStorageSync('phone_active')!=1){
this.vision = true;
this.loginEv(options);
} else {
//token
this.$toolAll.tools.overdue();
}
}
},
@ -271,7 +272,6 @@
uni.login({
provider: 'weixin',
success: (res) => {
if (res.code) {
var params = {
code: res.code,
invite_code: options.invite_code || '', //
@ -285,7 +285,6 @@
}
}
}, error => {})
}
},
});
},
@ -454,8 +453,9 @@
if (res.data.diary.length != 0) {
res.data.diary.forEach(item => {
let fabImg = '';
if (item.published_headimgurl != '' && item.published_headimgurl != null)
if (item.published_headimgurl != '' && item.published_headimgurl != null) {
fabImg = this.$http + item.published_headimgurl
}
let tObj = {
category_id: item.category_id, //ID
id: item.id,
@ -560,6 +560,9 @@
let num = item.video.search(".mp4")
let isVideo = false
if (num != '-1') isVideo = true
let fabImg = '';
if (item.published_headimgurl != '' && item.published_headimgurl != null)
fabImg = this.$http + item.published_headimgurl
let arrObj = {
category_id: item.category_id, //ID
id: item.id,
@ -570,8 +573,8 @@
video: this.$http + item.video, //
title: item.title, //
content: item.subtitle, //
head_img: '/static/public/logo.png', //
name: '恒美植发', //
head_img: fabImg || '/static/public/logo.png', //
name: item.published_by || '恒美植发', //
isVideo: isVideo //
}
if (item.cover != '') {

View File

@ -127,7 +127,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -142,7 +141,6 @@
}
}
},error => {})
}
},
});
},

View File

@ -80,11 +80,8 @@
  };
  return shareObj;
},
onShow() {
this.$toolAll.tools.isLogin()
},
onLoad(options) {
if(uni.getStorageSync('is_active')!=1){this.vision = true;}
if(uni.getStorageSync('is_active')!=1){this.vision = true;} else {this.$toolAll.tools.isLogin()}
if(options.invite_code!='' && options.invite_code!=undefined){
this.loginEv(options.invite_code);
} else if(options.source_code!='' && options.source_code!=undefined){
@ -97,7 +94,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -112,7 +108,6 @@
}
}
},error => {})
}
},
});
},

View File

@ -343,7 +343,9 @@
size:20,
total:0,
isZanw:true,
allList:[]
allList:[],
isactivity:0,//01
orderId:''//id
}
},
onReachBottom() { //
@ -372,7 +374,7 @@
if(ya.detailObj.share_img==null) ya.detailObj.share_img = ya.detailObj.cover;
var shareObj = {
     title: `${ya.detailObj.name}`, // (slogan)
     path: `/pagesB/shopDetail/shopDetail?id=${this.detailObj.spu_id}&category_id=${this.category_id}&share_id=${uni.getStorageSync('userId')}&invite_code=${uni.getStorageSync('invite_code')}`, // /
     path: `/pagesB/shopDetail/shopDetail?id=${this.detailObj.is_activity==1?this.detailObj.activity_id:this.detailObj.id}&category_id=${this.category_id}&is_activity=${this.detailObj.is_activity==0 ? 0 : 1}&share_id=${uni.getStorageSync('userId')}&invite_code=${uni.getStorageSync('invite_code')}`, // /
     imageUrl: ya.$http + ya.detailObj.share_img//PNGJPG imageUrl 使 5:4
  };
  return shareObj;
@ -391,11 +393,14 @@
this.isAutoPlay = false;
},
onLoad(options) {
//token
this.$toolAll.tools.overdue();
if(uni.getStorageSync('is_active')!=1){
this.vision = true;
this.loginEv(options);
} else {
this.checkDetail(options.id,options.is_activity);
this.cartNumEv();
//token
this.$toolAll.tools.overdue();
}
if(options.category_id!=undefined) {
this.category_id = options.category_id
@ -403,8 +408,8 @@
}
if(options.share_id!=undefined) this.share_id = options.share_id
if(options.isIntegral=="true"){this.isScore = 3;}
this.checkDetail(options.id,options.is_activity);
this.cartNumEv();
this.isactivity = options.is_activity;
this.orderId = options.id;
//
if(options.shareCate==1) {
// options.checkGrounpIid
@ -439,7 +444,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:options.invite_code || '',//
@ -453,15 +457,15 @@
}
}
},error => {})
}
},
});
},
buttonH(e){//
this.haveImg = e
if(e) {
this.vision = false
this.isShowP = true
this.vision = false;
this.isShowP = true;
this.checkDetail(this.orderId,this.isactivity);
}
},
cartNumEv(){//
@ -475,7 +479,7 @@
},
checkPTList(id){//
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/group-list`,
url:`https://hm.hmzfyy.cn/api/spu/group-list`,
data:{id:id},
method:'post',
header:{
@ -520,7 +524,7 @@
// {id:1,imgSrc:'/static/tabbar/mya.png',title:'99线',price:3888,num:1,isActive:false},
let nprice = '';
if(this.isNei==3) {
nprice = this.detailObj.score;
nprice = this.skuDetail.score;
} else nprice = this.skuDetail.price/100;
this.ispt = index;
if(index==2){nprice = this.skuDetail.original_price/100;}
@ -599,7 +603,7 @@
this.daoTime = '';
},
chooselei(index){//
this.leiIndex = index
this.leiIndex = index;
this.skuDetail = this.allRes.sku[index];
},
lianK(){//
@ -652,8 +656,9 @@
}
},
checkDetail(newId,is_activity){
console.log(newId,is_activity,'参数');
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/detail`,
url:`https://hm.hmzfyy.cn/api/spu/detail`,
data:{id:newId,is_activity:is_activity},
method:'post',
header:{
@ -661,6 +666,7 @@
'Authorization': 'Bearer '+uni.getStorageSync('token') || ''
},
success: (res) => {
console.log(res,'结果');
if(res.data.code==0){
this.allRes = res.data.data;
this.zhuImg = this.$http + res.data.data.detail.cover;
@ -744,7 +750,6 @@
//
this.bannerList.push(newImgObj)
})
console.log(this.bannerList);
//
if(this.detailObj.video!=''){
this.bannerList[0] = {
@ -776,6 +781,8 @@
this.checkPTList(this.detailObj.id);//
}
this.checkShopList();
} else {
this.$toolAll.tools.showToast(res.data.msg);
}
}
})
@ -791,7 +798,7 @@
disease_id:''//ID
}
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/list`,
url:`https://hm.hmzfyy.cn/api/spu/list`,
data:params,
method:'post',
header:{
@ -874,6 +881,9 @@
let num = item.video.search(".mp4")
let isVideo = false
if (num != '-1') isVideo = true
let fabImg = '';
if (item.published_headimgurl != '' && item.published_headimgurl != null)
fabImg = this.$http + item.published_headimgurl
let arrObj = {
category_id: item.category_id, //ID
id: item.id,
@ -884,8 +894,8 @@
video: this.$http + item.video, //
title: item.title, //
content: item.subtitle, //
head_img: '/static/public/logo.png', //
name: '恒美植发', //
head_img: fabImg || '/static/public/logo.png', //
name: item.published_by || '恒美植发', //
isVideo: isVideo //
}
if (item.cover != '') {

View File

@ -233,7 +233,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -248,7 +247,6 @@
}
}
},error => {})
}
},
});
},
@ -274,7 +272,7 @@
size:this.size,
}
uni.request({
url:`https://hengmei.scdxtc.cn/api/spu/list`,
url:`https://hm.hmzfyy.cn/api/spu/list`,
data:params,
method:'post',
header:{

View File

@ -86,7 +86,6 @@
uni.login({
provider: 'weixin',
success: (res)=> {
if (res.code) {
var params = {
code:res.code,
invite_code:invite_code,//
@ -101,7 +100,6 @@
}
}
},error => {})
}
},
});
},

View File

@ -1,13 +1,13 @@
<template>
<div class="">
<div style="width:100%;overflow-x:hidden;">
<image class="" @tap="backEv" :style="{top:statusHNH/2+'px'}" src="/static/public/videoBack.png" style="width: 33rpx;height: 33rpx;position: fixed;z-index: 10;left: 20rpx;" mode="aspectFill"></image>
<video id="myVideo" style="width: 100%;" :style="{height:newHeight+'px'}" autoplay="true"
:src="videoSrc" :enable-play-gesture="dans" :poster="posterSrc"
:controls="isControls" :show-center-play-btn="isCenterImg" :show-play-btn="isBottomImg" :show-fullscreen-btn="isFull"
@play="comePlay" @pause="comePause"></video>
<!-- 封面图 -->
<!-- <image v-if="isPlayImg" @tap="playEv" src="/static/public/video.png" style="position: fixed;top: 50%;left: 50%;
width: 126rpx;height: 126rpx;transform: translate(-50%, -50%);" mode="aspectFill"></image> -->
<image v-if="isPlayImg" @tap="playEv" src="/static/public/video.png" style="position: fixed;top: 50%;left: 50%;
width: 126rpx;height: 126rpx;transform: translate(-50%, -50%);" mode="aspectFill"></image>
</div>
</template>
@ -18,13 +18,13 @@
statusHNH:uni.getStorageSync('statusHNH'),
newHeight:uni.getSystemInfoSync().windowHeight,
videoSrc:'',
isPlayImg:true,
isPlayImg:false,
autoplay:true,
videoContext:'',
title:'',//视频的标题,全屏时在顶部展示
posterSrc:'',//视频封面的图片网络资源地址,如果 controls 属性值为 false 则设置 poster 无效
isControls: false,//是否显示默认播放控件(播放/暂停按钮、播放进度、时间)
dans:false,//是否开启播放手势,即双击切换播放/暂停
dans:true,//是否开启播放手势,即双击切换播放/暂停
isCenterImg:false,//是否显示视频中间的播放按钮
isBottomImg:true,//是否显示视频底部控制栏的播放按钮
isFull:true//是否显示全屏按钮
@ -44,16 +44,16 @@
})
},
playEv(){
this.isPlayImg = false
this.autoplay = false
this.videoContext.play()
this.isPlayImg = false;
this.autoplay = false;
this.videoContext.play();
},
comePlay(){//当开始/继续播放时触发play事件
this.isControls = true
this.isControls = true;
},
comePause(){
this.isPlayImg = true
this.isControls = false
this.isPlayImg = true;
this.isControls = false;
}
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long