This commit is contained in:
@fawn-nine
2024-08-02 15:08:43 +08:00
parent 3904f02c55
commit 7ee7b52c93
7 changed files with 2277 additions and 2531 deletions

View File

@@ -26,7 +26,7 @@
onLaunch: function(e) {
// 检测自动更新
// #ifdef APP-PLUS
updata();
// updata();
// #endif
uni.getSystemInfo({

View File

@@ -452,6 +452,7 @@
fatherIndex: null,
supportFlag: false,
selectGoodsData: {},
buyOptions: [
// {
// icon: 'chat',
@@ -665,10 +666,6 @@
onHandleClickBuy(e) {
console.log("this.selectGoodsData at line 589:", this.selectGoodsData);
// if (e.index == 0) {
// this.handleClickClose();
// }
// if (e.index == 0) {
var mynavData = JSON.stringify({
goods: [this.selectGoodsData],
typeId: 0,
@@ -710,15 +707,6 @@
this.getCourseDescriptionData();
// this.$commonJS.showToast("");
}
// if (res.productList.length > 0) {
// this.goodsList = res.productList;
// this.selectGoodsData = this.goodsList[0];
// this.$refs.commonSelectGoods.open();
// this.show = true;
// } else {
// this.$commonJS.showToast("此课程暂无购买方式");
// }
this.$forceUpdate();
});
} else {
@@ -745,7 +733,7 @@
}
this.$forceUpdate();
});
})
}
},
getUserInfo() {

View File

@@ -16,17 +16,10 @@
</view> -->
<!-- -->
<view
v-show="isShowAddress"
class="order_top common_radius_box color_shandow goods_box address_box"
@click="goToAddress"
>
<u-icon
name="map-fill"
color="#258feb"
size="23"
style="display: inline-block; margin-right: 10rpx"
></u-icon>
<view v-show="isShowAddress" class="order_top common_radius_box color_shandow goods_box address_box"
@click="goToAddress">
<u-icon name="map-fill" color="#258feb" size="23"
style="display: inline-block; margin-right: 10rpx"></u-icon>
<!-- <view class="curriulum_title_box goods_item"> -->
<view class="normal_box" v-if="addressData.consigneeName">
@@ -44,23 +37,17 @@
</view>
</view>
<view class="right">
<image
src="@/static/icon/icon_right.png"
class="rightArrow"
style=""
></image>
<image src="@/static/icon/icon_right.png" class="rightArrow" style=""></image>
</view>
<!-- </view> -->
</view>
<view class="order_top common_radius_box color_shandow goods_box">
<view
class="curriulum_title_box goods_item"
v-for="(v, i) in goodsDataList"
>
<view class="curriulum_title_box goods_item" v-for="(v, i) in goodsDataList">
<image v-if="v.productImages && v.productImages != ''" class="goods_item_img" :src="v.productImages" mode="aspectFit">
<image v-if="v.productImages && v.productImages != ''" class="goods_item_img" :src="v.productImages"
mode="aspectFit">
</image>
<image v-else src="/static/nobg1.jpg" mode="widthFix" @click="goDetail(item.productId)"></image>
<view class="normal_box">
@@ -93,34 +80,23 @@
</view>
</view>
<view class="pay_box" style="margin-top: 20rpx">
<view
@click="openOrderModal(v)"
class="curriulum_title_box goods_item pay_item"
v-for="(v, i) in orderInfoList"
>
<view @click="openOrderModal(v)" class="curriulum_title_box goods_item pay_item"
v-for="(v, i) in orderInfoList">
<view class="top">
<view class="left">
<text> {{ v.text }}</text>
</view>
<view class="right" style="display: flex; align-items: center">
<text
style="
<text style="
float: left;
text-align: right;
color: #b0b0b0;
font-size: 24rpx;
display: inline-block;
width: 200rpx;
"
:class="remark ? 'hidden1 hasRemark' : 'hidden1'"
>
{{ remark == "" ? v.placeholder : remark }}</text
>
<image
src="@/static/icon/icon_right.png"
class="rightArrow"
style=""
></image>
" :class="remark ? 'hidden1 hasRemark' : 'hidden1'">
{{ remark == "" ? v.placeholder : remark }}</text>
<image src="@/static/icon/icon_right.png" class="rightArrow" style=""></image>
</view>
</view>
@@ -138,33 +114,18 @@
<view class="order_top common_radius_box color_shandow goods_box pay_box">
<view class="title">价格明细</view>
<view
class="curriulum_title_box goods_item pay_item"
v-for="(v, i) in priceBreakdownList"
>
<view class="curriulum_title_box goods_item pay_item" v-for="(v, i) in priceBreakdownList">
<view class="top">
<view class="left">
<image
v-if="v.imgUrl"
class="pay_item_img"
:src="v.imgUrl"
mode="aspectFil"
:style="v.style"
>
<image v-if="v.imgUrl" class="pay_item_img" :src="v.imgUrl" mode="aspectFil"
:style="v.style">
</image>
<u-icon
v-if="v.icon"
name="map-fill"
color="#018F89"
size="23"
style="display: inline-block"
></u-icon>
<u-icon v-if="v.icon" name="map-fill" color="#018F89" size="23"
style="display: inline-block"></u-icon>
<text> {{ v.text }}</text
><template v-if="v.type == 3">
<text> {{ v.text }}</text><template v-if="v.type == 3">
<text style="color: #aaa; margin-left: 10rpx">
(全部积分{{ initData.user.jf }})</text
>
(全部积分{{ initData.user.jf }})</text>
</template>
</view>
<view class="right">
@@ -173,8 +134,7 @@
<text>
{{
isShowAddress ? freightNum.toFixed(2) : Number(0).toFixed(2)
}}</text
>
}}</text>
</template>
<template v-if="v.type == 3">
<text style="color: #fe6035"> -{{ jfNumberShow }}</text>
@@ -184,20 +144,10 @@
<view class="bottom jf_box" v-if="v.type == 3">
<view class="jf_box">
<text style="color: #258feb; font-weight: 600"
>可用积分({{ jfNumberMax }})</text
>
<text style="color: #258feb; font-weight: 600">可用积分({{ jfNumberMax }})</text>
<view class="jf_input">
<u--input
type="number"
@input="handleChangejf"
@clear="jfNumber = 0"
:max="jfNumberMax"
v-model="jfNumber"
placeholder="请输入积分"
border="surround"
clearable
></u--input>
<u--input type="number" @input="handleChangejf" @clear="jfNumber = 0" :max="jfNumberMax"
v-model="jfNumber" placeholder="请输入积分" border="surround" clearable></u--input>
</view>
</view>
</view>
@@ -213,134 +163,76 @@
<view class="order_top common_radius_box color_shandow goods_box pay_box">
<view class="title">支付方式</view>
<template v-if="isAndorid || !isAndorid && !haveCourse">
<view
class="curriulum_title_box goods_item pay_item"
v-for="(v, i) in payList"
>
<view class="curriulum_title_box goods_item pay_item" v-for="(v, i) in payList">
<view :class="isDefaultCurrency && i != 2 ? 'bgGrey top' : 'top'">
<view class="left">
<image
class="pay_item_img"
:src="v.imgUrl"
mode="aspectFil"
:style="v.style"
>
<image class="pay_item_img" :src="v.imgUrl" mode="aspectFil" :style="v.style">
</image>
<template v-if="v.type == 4">
<text> {{ v.text }}</text>
<text
style="color: #258feb; font-weight: 600; margin-left: 10rpx"
>
<text style="color: #258feb; font-weight: 600; margin-left: 10rpx">
(余额{{
initData && initData.user ? initData.user.peanutCoin : 0
}})</text
>
}})</text>
</template>
<text v-else> {{ v.text }}</text>
</view>
<template v-if="isDefaultCurrency">
<radio
v-if="i == 2"
:value="v.value"
color="#258feb"
:checked="selectPayIndex == i ? true : false"
@click="radioChange(i)"
size="10"
/>
<radio v-if="i == 2" :value="v.value" color="#258feb"
:checked="selectPayIndex == i ? true : false" @click="radioChange(i)" size="10" />
</template>
<template v-else>
<radio
:value="v.value"
color="#258feb"
:checked="selectPayIndex == i ? true : false"
@click="radioChange(i)"
size="10"
/>
<radio :value="v.value" color="#258feb" :checked="selectPayIndex == i ? true : false"
@click="radioChange(i)" size="10" />
</template>
</view>
</view>
</template>
<!-- ios 支付列表 -->
<template v-else>
<view
class="curriulum_title_box goods_item pay_item"
v-for="(v, i) in payListIOS"
>
<view class="curriulum_title_box goods_item pay_item" v-for="(v, i) in payListIOS">
<view :class="isDefaultCurrency && i != 2 ? 'bgGrey top' : 'top'">
<view class="left">
<image
class="pay_item_img"
:src="v.imgUrl"
mode="aspectFil"
:style="v.style"
>
<image class="pay_item_img" :src="v.imgUrl" mode="aspectFil" :style="v.style">
</image>
<template v-if="v.type == 4">
<text> {{ v.text }}</text>
<text
style="color: #258feb; font-weight: 600; margin-left: 10rpx"
>
<text style="color: #258feb; font-weight: 600; margin-left: 10rpx">
(余额{{
initData && initData.user ? initData.user.peanutCoin : 0
}})</text
>
}})</text>
</template>
<text v-else> {{ v.text }}</text>
</view>
<template v-if="isDefaultCurrency">
<radio
v-if="i == 2"
:value="v.value"
color="#258feb"
:checked="selectPayIndex == i ? true : false"
@click="radioChange(i)"
size="10"
/>
<radio v-if="i == 2" :value="v.value" color="#258feb"
:checked="selectPayIndex == i ? true : false" @click="radioChange(i)" size="10" />
</template>
<template v-else>
<radio
:value="v.value"
color="#258feb"
:checked="selectPayIndex == i ? true : false"
@click="radioChange(i)"
size="10"
/>
<radio :value="v.value" color="#258feb" :checked="selectPayIndex == i ? true : false"
@click="radioChange(i)" size="10" />
</template>
</view>
</view>
</template>
<template v-if="beizhuShow">
<view
class="goods_detail_list_title bg_box_shandow color_shandow bg_color"
>
<view
class="linlanzhifu"
style="
<view class="goods_detail_list_title bg_box_shandow color_shandow bg_color">
<view class="linlanzhifu" style="
width: 100%;
overflow: hidden;
justify-content: space-between;
"
>
">
<view class="linlanzhifu">
<u-icon
name="error-circle"
color="#018F89"
size="20"
style="display: inline-block; margin-right: 10rpx"
></u-icon>
<u-icon name="error-circle" color="#018F89" size="20"
style="display: inline-block; margin-right: 10rpx"></u-icon>
确保您的天医币足够支付
</view>
<text
class="fdButtonBox aui-text-danger fdButtonBoxRed"
style="float: right"
@click="
<text class="fdButtonBox aui-text-danger fdButtonBoxRed" style="float: right" @click="
onPageJump('/pages/mine/wallet/recharge/index?source=order')
"
>立即充值</text
>
">立即充值</text>
</view>
<view class="other_info" style="margin-top: 12rpx">
@@ -348,9 +240,7 @@
<view class="explain"> 1. 1天医币 = 1元人民币 </view>
<view class="explain">
2.若有疑问或意见请致电客服
<span style="font-size: 15px"
><u @click="gotoPhone">022-24142321</u></span
>
<span style="font-size: 15px"><u @click="gotoPhone">022-24142321</u></span>
</view>
<view class="explain">
<!-- 3.非中国大陆用户可通过paypal账户支付
@@ -363,21 +253,14 @@
3.非中国大陆用户可以信用卡支付简单快捷推荐使用
支付时使用的信用卡需要带有Visa或MasterCard的标识请向邮箱
<text
@click="fnCopy('publisher@tmrjournals.com', '邮箱')"
class="aui-text-success"
style="text-decoration: underline; color: #258feb"
>
<text @click="fnCopy('publisher@tmrjournals.com', '邮箱')" class="aui-text-success"
style="text-decoration: underline; color: #258feb">
publisher@tmrjournals.com
</text>
点击复制发送支付请求内容需包含拟购买的课程名称支付金额APP注册姓名及手机号码或者加一路健康客服微信
<text
class="aui-text-success"
@click="fnCopy('yilujiankangkefu', '微信名')"
style="text-decoration: underline; color: #258feb"
>
yilujiankangkefu </text
>点击复制联系我们我们将在24小时内向您的邮箱或者微信发送支付链接根据提示即可完成信用卡支付无需兑换外币
<text class="aui-text-success" @click="fnCopy('yilujiankangkefu', '微信名')"
style="text-decoration: underline; color: #258feb">
yilujiankangkefu </text>点击复制联系我们我们将在24小时内向您的邮箱或者微信发送支付链接根据提示即可完成信用卡支付无需兑换外币
</view>
</view>
</view>
@@ -385,15 +268,10 @@
</view>
<template>
<common-sticky
label="title"
:itemStyle="`width:${
<common-sticky label="title" :itemStyle="`width:${
cateList.length == 2 ? '50' : '33'
}%;padding-left: 15px; padding-right: 15px; height: 68rpx;`"
:list="cateList"
:currentCateIndex="currentCateIndex"
@handleselectCate="handleselectCate"
>
}%;padding-left: 15px; padding-right: 15px; height: 68rpx;`" :list="cateList"
:currentCateIndex="currentCateIndex" @handleselectCate="handleselectCate">
</common-sticky>
</template>
@@ -422,17 +300,11 @@
-->
</view>
<view class="goods_nav_box">
<common-goods-nav
:iconList="[]"
:customButton="customButton"
@submit="goBuyJie"
>
<common-goods-nav :iconList="[]" :customButton="customButton" @submit="goBuyJie">
<!-- leftSlot -->
<template slot="leftSlot" slot-scope="slotProps">
<view class="price_box order_bottom_box"
><text class="number">{{ number }}</text>
<text class="price"
>合计:
<view class="price_box order_bottom_box"><text class="number">{{ number }}</text>
<text class="price">合计:
<text class="total">{{ actualPayment }}</text>
</text>
@@ -453,49 +325,28 @@
@cancel="hancleModalCancel"
></u-modal> -->
<u-popup :show="show" mode="right">
<common-address
backState="3000"
ref="commonAddress"
@fresh="handleFresh"
@selectAddress="selectAddress"
></common-address
></u-popup>
<common-address backState="3000" ref="commonAddress" @fresh="handleFresh"
@selectAddress="selectAddress"></common-address></u-popup>
<!-- @close="closeOrderModalShow" -->
<u-popup :show="orderModalShow" mode="bottom" :round="20">
<view class="orderModalShow popup_box">
<u-icon
name="close"
color="#333"
size="18"
@click="closeOrderModalShow"
style="
<u-icon name="close" color="#333" size="18" @click="closeOrderModalShow" style="
display: inline-block;
position: absolute;
right: 20rpx;
top: 20rpx;
"
></u-icon>
"></u-icon>
<view v-if="orderModalShowInfo.type == 'remark'">
<view class="order_top common_radius_box goods_box">
<view class="curriulum_title_box goods_item">
<view class="title">订单备注</view>
<u--textarea
v-model="content"
placeholder="选填:给商家留言"
count
class="textarea"
></u--textarea>
<u--textarea v-model="content" placeholder="选填:给商家留言" count class="textarea"></u--textarea>
</view>
</view>
</view>
<view class="goods_nav_box">
<uni-goods-nav
:fill="true"
:options="[]"
:button-group="customButtonGroup1"
@click="onHandleClickBuy"
@buttonClick="onHandleClickBuy"
/>
<uni-goods-nav :fill="true" :options="[]" :button-group="customButtonGroup1"
@click="onHandleClickBuy" @buttonClick="onHandleClickBuy" />
</view>
</view>
</u-popup>
@@ -505,10 +356,18 @@
<script>
import courseDescription from "@/pages/component/commonComponents/list";
import { setPay, setPayAssign, setWXPay } from "@/config/utils";
import {
setPay,
setPayAssign,
setWXPay
} from "@/config/utils";
import $http from "@/config/requestConfig.js";
const { platform } = uni.getSystemInfoSync();
import { mapState } from "vuex";
const {
platform
} = uni.getSystemInfoSync();
import {
mapState
} from "vuex";
export default {
components: {
courseDescription, //课程说明
@@ -571,8 +430,7 @@ export default {
},
selectPayIndex: 1,
farePrice: 0,
payList: [
{
payList: [{
text: "支付宝",
imgUrl: require("@/static/icon/pay_1.png"),
type: 2,
@@ -591,29 +449,25 @@ export default {
value: "2",
},
],
payListIOS: [
{
payListIOS: [{
text: "天医币",
imgUrl: require("@/static/icon/pay_3.png"),
type: 4,
value: "2",
},
],
}, ],
priceBreakdownList: [],
orderInfoList: [
{
orderInfoList: [{
text: "订单备注",
placeholder: "点击填写订单备注",
imgUrl: "",
type: "remark",
},
],
}, ],
number: 1,
detailInfo: {},
content: "",
remark: "",
iconList: [],
buyingFlag: false, // 购买进行中flag
swiperList: [],
options: {},
relatedCoursesList: [], //相关课程
@@ -635,8 +489,7 @@ export default {
initData: {},
taiHuClassInfo: {},
searchValue: "",
teachingList: [
{
teachingList: [{
title: "临床实践",
type: "02",
@@ -686,22 +539,18 @@ export default {
addressList: "common/userAddress/getUserAddress",
freightNum: "book/buyOrder/calculateTransportPrice", //运费
},
customButton: [
{
customButton: [{
width: "340rpx",
text: "立即支付",
backgroundColor: "linear-gradient(90deg, #3C77BE 0%,#258feb 100%)",
color: "#fff",
},
],
customButtonGroup1: [
{
}, ],
customButtonGroup1: [{
with: 200,
text: "确定",
backgroundColor: "linear-gradient(90deg, #3C77BE 0%,#258feb 100%)",
color: "#fff",
},
],
}, ],
haveCourse: false, // 结算队列是否有课程类型的商品
isAndorid: null, //操作系统
beizhuShow: false, // 是否显示天医币说明?
@@ -802,8 +651,7 @@ export default {
value = this.jfNumberMax;
this.$forceUpdate();
} else {
}
} else {}
// value = value.replace(/[^\d]/g, "");
this.jfNumber = Number(value);
this.jfNumberShow = this.jfNumber.toFixed(2);
@@ -841,8 +689,7 @@ export default {
},
// 获取订单初始话
async initPrepareOrder() {
this.priceBreakdownList = [
{
this.priceBreakdownList = [{
text: "商品总价",
imgUrl: "",
type: 1,
@@ -1081,6 +928,14 @@ export default {
}
},
async goBuyJie() {
if (this.buyingFlag) {
uni.showToast({
title: '操作太频繁了,休息下吧',
icon: 'none'
})
return
}
this.buyingFlag = true
var that = this;
// if (this.addressList.length == 0) {
// this.dizhiShow = true // 如果没有地址信息
@@ -1138,8 +993,7 @@ export default {
};
}), //订单列表商品
orderType: "order", //订单类型
addressId:
this.options.goods[0].goodsType != "05" ? this.addressData.id : 0, // 地址ID
addressId: this.options.goods[0].goodsType != "05" ? this.addressData.id : 0, // 地址ID
appName: "wumen",
come: "2",
};
@@ -1174,8 +1028,7 @@ export default {
title: "正在支付",
icon: "loading",
});
await setPay(
{
await setPay({
typePay: "alipay",
subject: "order",
totalAmount: res.money,
@@ -1189,6 +1042,7 @@ export default {
});
console.log(res, "支付支付");
if (res.success) {
this.buyingFlag = false
uni.showToast({
title: "支付成功",
});
@@ -1208,7 +1062,7 @@ export default {
}, 1000);
} else {
console.log("失败失败失败");
this.buyingFlag = false
// that.$commonJS.showToast('支付是失败')
setTimeout(() => {
console.log("延迟调用 失败提示");
@@ -1237,6 +1091,7 @@ export default {
};
setWXPay(data1, (res) => {
if (res.success) {
this.buyingFlag = false
uni.showToast({
title: "支付成功",
});
@@ -1256,6 +1111,7 @@ export default {
}
}, 1000);
} else {
this.buyingFlag = false
console.log(res, "微信支付111111111111111");
if (res.data.errMsg.indexOf("User canceled") != -1) {
uni.showToast({
@@ -1273,6 +1129,7 @@ export default {
}
});
} else if (this.payType == 4) {
this.buyingFlag = false
// 天医币支付
uni.showToast({
title: "购买成功",
@@ -1296,7 +1153,9 @@ export default {
},
radioChange(index) {
if(index == this.selectPayIndex){ return }
if (index == this.selectPayIndex) {
return
}
this.selectPayIndex = index;
this.selectPayIndex == 2 ? this.beizhuShow = true : this.beizhuShow = false
this.payType = this.payList[this.selectPayIndex].type;
@@ -1354,8 +1213,7 @@ export default {
}
this.modalInfo = {
title: "提示信息",
content:
"用户您好,该课程已到期,通过支付" +
content: "用户您好,该课程已到期,通过支付" +
fee +
"元,本门课程可获得" +
days +
@@ -1570,8 +1428,7 @@ export default {
// curriculumInfo
this.detailInfo = {
content:
"<img src='http://oss.taihumed.com/other/null_20210528102528870.jpg' ></img> <img src='http://101.201.146.165:8088/curriculum/detailImg/curriculum_20170420143333621.png' ></img><p><p>没有中医基础想学中医难不难?中医学者治疗出现瓶颈怎么办?中西医究竟有什么不同呢?吴雄志教授将以全新的视角,完美整合中药学和西医学知识,让你领略当代中医生理学魅力。</p><p><br/><p></p><p><br/></p><p>【思考题】</p><p>1、简述中医的发展这些年出现了哪些变化</p><p>2、简述中西医学科的异同</p>",
content: "<img src='http://oss.taihumed.com/other/null_20210528102528870.jpg' ></img> <img src='http://101.201.146.165:8088/curriculum/detailImg/curriculum_20170420143333621.png' ></img><p><p>没有中医基础想学中医难不难?中医学者治疗出现瓶颈怎么办?中西医究竟有什么不同呢?吴雄志教授将以全新的视角,完美整合中药学和西医学知识,让你领略当代中医生理学魅力。</p><p><br/><p></p><p><br/></p><p>【思考题】</p><p>1、简述中医的发展这些年出现了哪些变化</p><p>2、简述中西医学科的异同</p>",
};
// this.$http
@@ -1716,7 +1573,9 @@ export default {
transformData(inputData) {
const result = {};
inputData.forEach((item) => {
const { letter } = item;
const {
letter
} = item;
if (!result[letter]) {
result[letter] = [];
}
@@ -1886,6 +1745,7 @@ export default {
<style lang="scss" scoped>
@import "@/style/mixin.scss";
.order_box {
padding: 20rpx;
@@ -1981,7 +1841,7 @@ export default {
}
.commonDetailPage {
font-size: 24rpx;
font-size: 28rpx;
padding-bottom: 150rpx !important;
}
@@ -2153,8 +2013,7 @@ font-size: 24rpx;
// color: #aaa;
color: #5a5a5a;
.explain {
}
.explain {}
}
.left {

View File

@@ -38,31 +38,6 @@
>退出登录</u-button
>
</view>
<!-- <view class="set_box" style="margin-top:20rpx">
<list :dataList="otherList" @hancleClick="handleClickRightContent" label="title">
<template slot="rightSlot" slot-scope="slotProps">
<text class="fdButtonBox aui-text-success">{{ slotProps.row.content }}</text>
<view>
</view>
</template>
</list>
</view> -->
</view>
<u-modal
@@ -73,10 +48,19 @@
@confirm="signOut"
>
</u-modal>
<u-popup key="1" v-if="showCodeImg" :show="showCodeImg" :round="10" @close="closePup">
<view class="box6">
<text style="color: #999; margin-bottom: 20rpx;">点击图片后长按图片保存到手机或使用微信扫描二维码添加客服企业微信</text>
<image @click="previewImage('/static/qiyeWx.jpg')" src="/static/qiyeWx.jpg" mode="widthFix" style="width: 100px; height: 100px; margin: 0 auto;"></image>
</view>
</u-popup>
</view>
</template>
<script>
// #ifdef APP-PLUS
import updata from "@/uni_modules/uni-upgrade-center-app/utils/check-update";
// #endif
import list from "@/pages/component/commonComponents/list";
import $http from "@/config/requestConfig.js";
@@ -92,7 +76,7 @@ export default {
playData: {},
options: {},
searchValue: "",
showCodeImg:false,
twoCateList: [], // 二级分类标题
titleList: [], // 方剂标题
curOneCateIndex: 0, // 当前选中的一级分类
@@ -117,11 +101,15 @@ export default {
type: "email",
},
{
title: "微信",
content: "yilujiankangkefu",
title: "企业微信",
content: "",
type: "wxNumber",
},
{
title: "版本检测",
content: "",
type: "checkVersion",
},
// {
// "title": "清楚缓存",
@@ -161,6 +149,9 @@ export default {
},
methods: {
...mapMutations(["setUserInfo"]),
closePup(){
this.showCodeImg = false
},
signOut() {
this.signShow = false;
this.setUserInfo({ token: null });
@@ -217,7 +208,11 @@ export default {
this.$commonJS.handleCopy(row.content, row.title);
break;
case "wxNumber":
this.$commonJS.handleCopy(row.content, row.title);
this.showCodeImg = true
// this.$commonJS.handleCopy(row.content, row.title);
break;
case "checkVersion":
this.getNewVersion()
break;
case "pageJump":
uni.navigateTo({
@@ -228,25 +223,7 @@ export default {
//
}
},
// 检查是有权限使用搜索功能
checkDisable() {
console.log("点击了");
},
// 显示无权限弹窗
// showNoRights() {
// let that = this
// uni.showModal({
// content: "",
// confirmText: '好的',
// showCancel: false,
// success: function(res) {
// if (res.confirm) {
// // console.log('用户点击确定');
// that.clear()
// }
// }
// })
// },
// 获取用户详情
getUserInfo() {
// 用户详情
@@ -258,6 +235,19 @@ export default {
});
}
},
// 版本检测
async getNewVersion(){
// #ifdef APP-PLUS
var info = await updata();
console.log('info',JSON.stringify(info))
if(info.result.code == 0){
uni.showToast({
title:info.result.message,
icon:'none'
})
}
// #endif
},
// 详情
gotoDetail(v) {
console.log(v);
@@ -402,27 +392,6 @@ export default {
async setOneCateIndex(item, index) {
console.log(index, 99999);
var that = this;
// if(this.userMes.tgdzPower == 0){
// let that = this
// uni.showModal({
// content: "购买 针灸六经法要上册和下册 后方可使用此功能",
// confirmText: '好的',
// showCancel: false,
// success: function(res) {
// if (res.confirm) {
// // console.log('用户点击确定');
// }
// }
// })
// return
// }
// if(item.title == "时辰取穴"){
// uni.navigateTo({
// url: "../timeAcupoint/timeAcupoint"
// })
// return
// }
let type = item.type;
this.curOneCateIndex = index;
this.curTwoCateIndex = 0;
@@ -432,15 +401,6 @@ export default {
// if (index != 2) {
await this.getTowCateList(type);
// uni.createSelectorQuery().select('.oneCateList').boundingClientRect(function (rect) {
// var height = rect.height
// console.log('元素高度:',);
// }).exec();
// } else {
// this.getJFList(dictType)
// }
},
async getTowCateList(type) {
var that = this;
@@ -450,11 +410,8 @@ export default {
method: "POST", // POST、GET、PUT、DELETE具体说明查看官方文档
data: {
loadAnimate: "none", // 请求加载动画
// 'categoryId': id
},
// header: { //默认 无 说明:请求头
// 'Content-Type': 'application/json'
// },
})
.then((res) => {
console.log(res, "二级分类获取成功");
@@ -511,15 +468,6 @@ export default {
this.getTitles(this.twoCateList[0].dictType);
this.$nextTick(async () => {
// await uni.createSelectorQuery().select('.uni-tabbar').boundingClientRect(function (rect) {
// console.log(rect.height, '3333')
// // var height = 42 + rect.height + 10;
// // that.scrollViewHeight = height;
// // console.log(that.scrollViewHeight, '111111')
// // that.$forceUpdate()
// // console.log('元素高度2', height);
// }).exec();
await uni
.createSelectorQuery()
.select(".cateList")
@@ -557,156 +505,31 @@ export default {
// const finalResult = Object.keys(result).map(key => ({ [key]: result[key] }));
return result;
},
// getJFList(id) {
// $http.request({
// url: "book/prescript/prescriptListForJF",
// method: "POST", // POST、GET、PUT、DELETE具体说明查看官方文档
// data: {
// loadAnimate: 'none', // 请求加载动画
// 'categoryId': id
// },
// header: { //默认 无 说明:请求头
// 'Content-Type': 'application/json'
// },
// }).then(res => {
// if (res.code == 0 && res.list.length > 0) {
// this.twoCateList = []
// this.titleList = this.transformData(res.list)
// console.log('JF经方', this.titleList)
// } else {
// this.twoCateList = []
// this.titleList = []
// }
// }).catch(e => {
// this.twoCateList = []
// this.titleList = []
// console.log(e)
// })
// },
getCateList(id) {
id ? "" : (id = 0);
this.twoCateList = [];
this.curTwoCateIndex = 0;
// 0为获取顶级分类其他为搜索下级分类目前的逻辑顶级是写死的所以可能只会涉及到搜索第二级
// $http.request({
// url: "book/prescript/prescriptCategoryList",
// method: "POST", // POST、GET、PUT、DELETE具体说明查看官方文档
// data: {
// loadAnimate: 'none', // 请求加载动画
// 'categoryId': id
// },
// header: { //默认 无 说明:请求头
// 'Content-Type': 'application/json'
// },
// }).then(res => {
// console.log(res, '脉穴分类获取成功')
// if (res.code == 0 && res.list.length > 0) {
// this.oneCateList = res.list
this.getTowCateList(this.oneCateList[0].type);
// } else {
// this.oneCateList = []
// }
// }).catch(e => {
// this.oneCateList = []
// console.log(e)
// })
},
// 放大图片
previewImage(url) {
console.log(url);
this.showCodeImg = false
uni.previewImage({
urls: [url],
longPressActions: {
itemList: ["很抱歉,暂不支持保存图片到本地"],
success: function (res) {
// console.log(res,'+++++')
},
},
// longPressActions: {
// itemList: ["很抱歉,暂不支持保存图片到本地"],
// success: function (res) {
// // console.log(res,'+++++')
// },
// },
});
},
// getSearch() {
// $http.request({
// url: "book/prescript/searchPrescript",
// method: "POST", // POST、GET、PUT、DELETE具体说明查看官方文档
// data: {
// loadAnimate: 'none', // 请求加载动画
// 'keywords': this.searchValue,
// type: this.curOneCateIndex + 1
// },
// header: { //默认 无 说明:请求头
// 'Content-Type': 'application/json'
// },
// }).then(res => {
// console.log(res, '搜索结果')
// if (res.code == 0 && res.list.length >= 0) {
// this.showSearchList = true
// this.searchList = res.list
// } else {
// this.searchList = []
// }
// }).catch(e => {
// // this.titleList = []
// this.searchList = []
// console.log(e)
// })
// },
// search(res) {
// console.log(res, 'res')
// // uni.showToast({
// // title: '搜索:' + res,
// // icon: 'none'
// // })
// if (res == '') {
// this.showSearchList = false
// this.searchList = []
// } else {
// this.getSearch()
// }
// },
// input(res) {
// console.log('----input:', res)
// if (res == '') {
// this.searchList = []
// } else {
// this.getSearch()
// }
// },
// clear(res) {
// console.log('----clear:', res)
// // uni.showToast({
// // title: 'clear事件清除值为',
// // icon: 'none'
// // })
// this.searchValue = ''
// this.showSearchList = false
// },
// blur(res) {
// // console.log('----blur:', res)
// // if (res == '') {
// // this.showSearchList = false
// // this.searchList = []
// // } else {
// // this.getSearch()
// // }
// },
// focus(e) {
// console.log('----focus:')
// // uni.showToast({
// // title: 'focus事件输出值为' + e.value,
// // icon: 'none'
// // })
// // 等于1 就是有权限
// // this.showSearchList = true
// },
// cancel(res) {
// uni.showToast({
// title: '点击取消,输入值为:' + res.value,
// icon: 'none'
// })
// }
},
onBackPress() {
// #ifdef APP-PLUS
@@ -719,6 +542,79 @@ export default {
<style lang="scss" scoped>
@import "@/style/common.scss";
.box6 {
padding: 20rpx;
text-align: center;
.title {
font-size: 28rpx;
margin: 10px 0;
}
.list {
padding: 0 10px;
padding-bottom: 20rpx;
.item {
font-size: 26rpx;
color: #333;
margin-bottom: 10rpx;
padding-top:20rpx ;
padding-bottom:20rpx ;
line-height:40rpx;
border-radius: 50rpx;
border: 1px solid #eee;
}
.item.active {
color: $themeColor;
border: 1px solid $themeColor;
}
.item:last-child {
// border-bottom: none
}
}
.tbn {
justify-content: center;
}
.buybtn { padding: 0 20rpx;
background-color: #00d8df;
margin: 0;
margin-right: 20rpx;
text {
color: #fff;
}
}
.saveBtnss {
align-items: center;
justify-content: center;
height: 80rpx;
// width: 46%;
overflow: hidden;
border-radius: 50rpx;
text {
padding-left: 10rpx;
font-size: 28rpx;
}
}
.gouwuche {
border: 1px solid #666;
padding-right: 20rpx;
text {
// color: #fff;
}
}
}
.u-grid-list {
// height: 40rpx;
}

View File

@@ -6,6 +6,9 @@
<view class="icon_hua">
<image src="../../static/homeLogo.png" mode="aspectFit" class="icon_hua_1"></image>
</view>
<view class="hehan">
<image src="../../static/icon/hehan.png" mode="aspectFit" class="icon_hua_1"></image>
</view>
<view class="topSearch_box">
<image src="../../static/search.png" mode="aspectFit"
@click="onPageJump('/pages/peanut/searchFor')"></image>
@@ -1058,11 +1061,11 @@
}
.childrenBox {
// background-color: #e4eefa !important;
border:1px solid #e4eefa;
background-color: #e4eefa !important;
// border:1px solid #e4eefa;
border-radius: 6rpx !important;
// @include mshadow(10px, 1);
background-color: #fff;
@include mshadow(10px, 1);
// background-color: #fff;
justify-content: center;
box-shadow: none !important;
// border-radius: 0 !important;

BIN
static/icon/hehan.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

BIN
static/qiyeWx.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB