| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158 |
- <template>
- <view class="edition-intro">
- <image src="https://gxsz-bucket-01.obs.cn-south-1.myhuaweicloud.com/ce174971e4874053822c52edb403c685.png" class="logo" />
- <h1> {{config.name}}</h1>
- <view class='version'>
- <!-- #ifdef APP-PLUS -->
- Version {{localVersion.version}}
- <!-- #endif -->
- </view>
- <!-- {{localVersion}} -->
- <u-cell-group class="cell" :border="false">
- <!-- #ifdef APP-PLUS -->
- <u-cell-item v-if="IosWhether" @click="checkStar" title="去评分"></u-cell-item>
- <u-cell-item title="功能介绍" @click="navigateTo('/pages/mine/set/versionFunctionList')"></u-cell-item>
- <u-cell-item title="检查更新" @click="checkUpdate"></u-cell-item>
- <!-- #endif -->
- <u-cell-item title="证照信息" @click="navigateTo('/pages/mine/help/tips?type=message')"></u-cell-item>
- <u-cell-item title="服务协议" @click="navigateTo('/pages/mine/help/tips?type=user')"></u-cell-item>
- <u-cell-item title="隐私协议" @click="navigateTo('/pages/mine/help/tips?type=privacy')"></u-cell-item>
- <u-cell-item title="关于我们" :border-bottom="false" @click="navigateTo('/pages/mine/help/tips?type=about')"></u-cell-item>
- </u-cell-group>
- <view class="intro">
- <view>客服热线:020-34152794</view>
- <view style="margin:20rpx 0 0 0;">客服邮箱:defu@nanyue6688.com</view>
- <view>
- <view style="margin:20rpx 0; color:#003a8c;" @click="navigateTo('/pages/mine/help/tips?type=user')">《南粤商城用户协议》</view>
- <view>CopyRight @{{config.name}} </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import APPUpdate from "@/plugins/APPUpdate";
- import config from "@/config/config";
- import { getAppVersion } from "@/api/message.js";
- export default {
- data() {
- return {
- config,
- IosWhether: false, //是否是ios
- editionHistory: [], //版本历史
- versionData: {}, //版本信息
- localVersion: "", //当前版本信息
- params: {
- pageNumber: 1,
- pageSize: 5,
- },
- };
- },
- onLoad() {
- const platform = uni.getSystemInfoSync().platform;
- /**
- * 获取是否是安卓
- */
- if (platform === "android") {
- this.params.type = 0;
- } else {
- this.IosWhether = true;
- this.params.type = 1;
- }
- this.getVersion(platform);
- plus.runtime.getProperty(plus.runtime.appid, (inf) => {
- this.localVersion = {
- versionCode: inf.version.replace(/\./g, ""),
- version: inf.version,
- };
- });
- },
- methods: {
- async getVersion(platform) {
- let type;
- platform == "android" ? (type = "ANDROID") : (type = "IOS");
- let res = await getAppVersion(type);
- if (res.data.success) {
- this.versionData = res.data.result;
- }
- },
- navigateTo(url) {
- uni.navigateTo({
- url,
- });
- },
- /**
- * ios点击评分
- */
- checkStar() {
- plus.runtime.launchApplication({
- action: `itms-apps://itunes.apple.com/app/${config.iosAppId}?action=write-review`,
- });
- },
- /**
- * 检查更新
- */
- checkUpdate() {
- if (
- this.versionData.version.replace(/\./g, "") <
- this.localVersion.versionCode
- ) {
- APPUpdate();
- } else {
- uni.showToast({
- title: "当前版本已是最新版",
- duration: 2000,
- icon: "none",
- });
- }
- },
- },
- };
- </script>
- <style lang="scss" scoped>
- page {
- background: #fff !important;
- }
- .cell {
- width: 90%;
- margin: 0 auto;
- }
- .edition-intro {
- min-height: 100vh;
- background: #fff;
- display: flex;
- flex-direction: column;
- justify-content: center;
- align-items: center;
- > h1 {
- margin: 20rpx 0 20rpx 0;
- letter-spacing: 2rpx;
- }
- > .version {
- font-size: 30rpx;
- margin-bottom: 100rpx;
- }
- }
- .intro {
- margin-top: 100rpx;
- font-size: 24rpx;
- letter-spacing: 2rpx;
- }
- .logo {
- width: 200rpx;
- height: 200rpx;
- }
- </style>
|