Commit bba50b52 by 前端

Merge branch 'v1.0.3' of http://192.168.3.233:8090/glsx/gl_tape into v1.0.3

2 parents bf7fe202 9d96718a
...@@ -31,9 +31,21 @@ class Request { ...@@ -31,9 +31,21 @@ class Request {
); );
} }
request (RequestMethods, params, returnAll, hostType = "dj") { request (RequestMethods, params, returnAll, hostType = "dj") {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
let header = let _this = this
RequestMethods === "POST" uni.getNetworkType({
success (res) {
if(res.networkType == 'none'){
uni.hideLoading();
uni.showToast({
title:'网络异常',
icon: "error",
});
reject('网络异常');
return
}
let header = RequestMethods === "POST"
? { ? {
"content-type": "application/x-www-form-urlencoded", "content-type": "application/x-www-form-urlencoded",
} }
...@@ -41,9 +53,9 @@ class Request { ...@@ -41,9 +53,9 @@ class Request {
"Cache-Control": "no-cache", "Cache-Control": "no-cache",
}; };
let projectName = params.projectName; let projectName = params.projectName;
if (!projectName) projectName = this.getRopProject(params.method); if (!projectName) projectName = _this.getRopProject(params.method);
const path = pathEnum[projectName]; const path = pathEnum[projectName];
params = this.getData(params, hostType); params = _this.getData(params, hostType);
uni.request({ uni.request({
url: `${HOST[hostType]}${path}router?method=${params.method}`, url: `${HOST[hostType]}${path}router?method=${params.method}`,
data: params, data: params,
...@@ -93,6 +105,8 @@ class Request { ...@@ -93,6 +105,8 @@ class Request {
uni.stopPullDownRefresh(); uni.stopPullDownRefresh();
}, },
}); });
}
})
}); });
} }
getData (params, hostType = "scrm") { getData (params, hostType = "scrm") {
......
.sprite-icon { background-image: url(@/assets/images/sprite.png);background-size: 1338rpx 668rpx;} .sprite-icon { background-image: url(@/assets/images/sprite.png);background-size: 1338rpx 710rpx;}
.icon-back { width: 128rpx; height: 50rpx; background-position: -992rpx -432rpx;} .icon-arrow-right { width: 32rpx; height: 32rpx; background-position: -1114rpx -524rpx;}
.icon-change-account { width: 32rpx; height: 32rpx; background-position: -1300rpx -294rpx;} .icon-back { width: 128rpx; height: 50rpx; background-position: -1114rpx -464rpx;}
.icon-face-error-active { width: 96rpx; height: 96rpx; background-position: -1194rpx -294rpx;} .icon-change-account { width: 32rpx; height: 32rpx; background-position: -1156rpx -524rpx;}
.icon-face-error { width: 96rpx; height: 96rpx; background-position: -674rpx -432rpx;} .icon-face-error-active { width: 96rpx; height: 96rpx; background-position: -1242rpx -294rpx;}
.icon-face-success-active { width: 96rpx; height: 96rpx; background-position: -780rpx -432rpx;} .icon-face-error { width: 96rpx; height: 96rpx; background-position: -796rpx -464rpx;}
.icon-face-success { width: 96rpx; height: 96rpx; background-position: -886rpx -432rpx;} .icon-face-success-active { width: 96rpx; height: 96rpx; background-position: -902rpx -464rpx;}
.icon-feedback { width: 32rpx; height: 32rpx; background-position: -1300rpx -336rpx;} .icon-face-success { width: 96rpx; height: 96rpx; background-position: -1008rpx -464rpx;}
.icon-feedback { width: 32rpx; height: 32rpx; background-position: -1198rpx -524rpx;}
.icon-home-active { width: 80rpx; height: 80rpx; background-position: 0rpx -588rpx;} .icon-home-active { width: 80rpx; height: 80rpx; background-position: 0rpx -588rpx;}
.icon-home { width: 80rpx; height: 80rpx; background-position: -90rpx -588rpx;} .icon-home { width: 80rpx; height: 80rpx; background-position: -90rpx -588rpx;}
.icon-icon-addr { width: 32rpx; height: 32rpx; background-position: -1188rpx -432rpx;} .icon-icon-addr { width: 32rpx; height: 32rpx; background-position: -1240rpx -524rpx;}
.icon-icon-avatar { width: 112rpx; height: 112rpx; background-position: -1072rpx -294rpx;} .icon-icon-avatar { width: 112rpx; height: 112rpx; background-position: -674rpx -464rpx;}
.icon-icon-female { width: 32rpx; height: 32rpx; background-position: -1230rpx -432rpx;} .icon-icon-female { width: 32rpx; height: 32rpx; background-position: -1282rpx -524rpx;}
.icon-icon-handshake { width: 72rpx; height: 72rpx; background-position: -360rpx -588rpx;} .icon-icon-handshake { width: 72rpx; height: 72rpx; background-position: -360rpx -588rpx;}
.icon-icon-logout { width: 32rpx; height: 32rpx; background-position: -1272rpx -432rpx;} .icon-icon-male { width: 32rpx; height: 32rpx; background-position: -1072rpx -588rpx;}
.icon-icon-male { width: 32rpx; height: 32rpx; background-position: -992rpx -492rpx;} .icon-icon-shop { width: 32rpx; height: 32rpx; background-position: -1114rpx -588rpx;}
.icon-icon-shop { width: 32rpx; height: 32rpx; background-position: -1034rpx -492rpx;} .icon-icon-upload { width: 128rpx; height: 128rpx; background-position: -844rpx -294rpx;}
.icon-icon-upload { width: 128rpx; height: 128rpx; background-position: -674rpx -294rpx;} .icon-icon-weixin { width: 32rpx; height: 32rpx; background-position: -1156rpx -588rpx;}
.icon-icon-weixin { width: 32rpx; height: 32rpx; background-position: -1076rpx -492rpx;} .icon-kf-0 { width: 32rpx; height: 32rpx; background-position: -1198rpx -588rpx;}
.icon-kf-0 { width: 32rpx; height: 32rpx; background-position: -1118rpx -492rpx;} .icon-kf-1 { width: 32rpx; height: 32rpx; background-position: -1240rpx -588rpx;}
.icon-kf-1 { width: 32rpx; height: 32rpx; background-position: -1160rpx -492rpx;} .icon-kf-2 { width: 32rpx; height: 32rpx; background-position: -1282rpx -588rpx;}
.icon-kf-2 { width: 32rpx; height: 32rpx; background-position: -1202rpx -492rpx;} .icon-kf-3 { width: 32rpx; height: 32rpx; background-position: 0rpx -678rpx;}
.icon-kf-3 { width: 32rpx; height: 32rpx; background-position: -1244rpx -492rpx;} .icon-logo { width: 160rpx; height: 160rpx; background-position: -674rpx -294rpx;}
.icon-pen-active { width: 120rpx; height: 120rpx; background-position: -812rpx -294rpx;} .icon-pen-active { width: 120rpx; height: 120rpx; background-position: -982rpx -294rpx;}
.icon-pen { width: 120rpx; height: 120rpx; background-position: -942rpx -294rpx;} .icon-pen { width: 120rpx; height: 120rpx; background-position: -1112rpx -294rpx;}
.icon-qw { width: 48rpx; height: 48rpx; background-position: -1130rpx -432rpx;} .icon-qw { width: 48rpx; height: 48rpx; background-position: -1252rpx -464rpx;}
.icon-record-active { width: 80rpx; height: 80rpx; background-position: -180rpx -588rpx;} .icon-record-active { width: 80rpx; height: 80rpx; background-position: -180rpx -588rpx;}
.icon-record-day { width: 664rpx; height: 284rpx; background-position: 0rpx 0rpx;} .icon-record-day { width: 664rpx; height: 284rpx; background-position: 0rpx 0rpx;}
.icon-record-month { width: 664rpx; height: 284rpx; background-position: 0rpx -294rpx;} .icon-record-month { width: 664rpx; height: 284rpx; background-position: 0rpx -294rpx;}
.icon-record-week { width: 664rpx; height: 284rpx; background-position: -674rpx 0rpx;} .icon-record-week { width: 664rpx; height: 284rpx; background-position: -674rpx 0rpx;}
.icon-record { width: 80rpx; height: 80rpx; background-position: -270rpx -588rpx;} .icon-record { width: 80rpx; height: 80rpx; background-position: -270rpx -588rpx;}
.icon-setting { width: 32rpx; height: 32rpx; background-position: -42rpx -678rpx;}
.icon-tool-1 { width: 60rpx; height: 60rpx; background-position: -442rpx -588rpx;} .icon-tool-1 { width: 60rpx; height: 60rpx; background-position: -442rpx -588rpx;}
.icon-tool-2 { width: 60rpx; height: 60rpx; background-position: -512rpx -588rpx;} .icon-tool-2 { width: 60rpx; height: 60rpx; background-position: -512rpx -588rpx;}
.icon-tool-3 { width: 60rpx; height: 60rpx; background-position: -582rpx -588rpx;} .icon-tool-3 { width: 60rpx; height: 60rpx; background-position: -582rpx -588rpx;}
......

978 KB | W: | H:

1020 KB | W: | H:

assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
assets/images/sprite.png
  • 2-up
  • Swipe
  • Onion skin

1.9 KB | W: | H:

1.87 KB | W: | H:

assets/spritesmith/feedback.png
assets/spritesmith/feedback.png
assets/spritesmith/feedback.png
assets/spritesmith/feedback.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -116,7 +116,6 @@ const CONFIG_ENV_MAP = { ...@@ -116,7 +116,6 @@ const CONFIG_ENV_MAP = {
3: "production", 3: "production",
4: "beta", 4: "beta",
}; };
console.log(secretKey, "===");
module.exports = { module.exports = {
index, index,
domain, domain,
......
...@@ -69,6 +69,9 @@ ...@@ -69,6 +69,9 @@
} }
} }
},
{
"path": "pages/common/webview"
} }
], ],
"globalStyle": { "globalStyle": {
......
<template>
<web-view :src="url"></web-view>
</template>
<script type='text/ecmascript-6'>
export default {
name: '',
data () {
return {
url:''
}
},
onLoad(options){
this.url = options.url
},
mounted () {
},
methods: {
}
}
</script>
<style scoped lang='scss'>
</style>
\ No newline at end of file \ No newline at end of file
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
class="content" class="content"
:style="{background:background}" :style="{background:background}"
> >
<view class="title">{{title}}</view> <view class="title" v-if="title">{{title}}</view>
<template v-if="views.length && views.length > 1"> <template v-if="views.length && views.length > 1">
<tabs <tabs
:list="views" :list="views"
......
<template>
<view class="layout">
<view class="bg">
<image src="../../../assets/images/media/bg-2.webp" />
</view>
<view class="content">
<view class="title">{{title||'问界·商城延保价格明细'}}</view>
<template v-if="views.length">
<tabs
:list="views"
@tabclick="changeView"
ref="tabs"
/>
</template>
<view class="canvas-box">
<template v-for="(i,index) in views">
<view
:key="index"
v-show="viewIndex == index"
:class="['canvas-view', `${viewIndex == 0 ? 'left' : 'right'}`]"
>
<wnCanvas
:drawImage="i.detailUrl"
:drawStatus="penSwitch"
:canvasId="`c-2-${index}`"
></wnCanvas>
</view>
</template>
</view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
import Tabs from './Tabs.vue'
export default {
components: { Tabs },
props: {
views: Array,
penSwitch: Boolean,
title: String
},
name: 'Media_2',
data () {
return {
viewIndex: 0
}
},
watch: {
watchStatus: {
immediate: true,
handler (newval) {
this.$refs?.tabs?.tabClick(0)
}
},
},
computed: {
watchStatus () {
return this.$store.state.user.historyStatus
},
},
mounted () {
},
methods: {
changeView (index) {
this.viewIndex = index
},
}
}
</script>
<style scoped lang='scss'>
.layout {
padding-top: 192rpx;
position: relative;
.bg {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 240rpx;
image {
width: 100%;
height: 100%;
}
}
.content {
border-radius: 40rpx 40rpx 0 0;
background: #fcfbf9;
overflow: hidden;
position: relative;
z-index: 1;
.title {
font-size: 40rpx;
line-height: 48rpx;
color: #1a1a1a;
padding: 32rpx 0;
text-align: center;
}
}
.canvas-box {
padding-top: 6rpx;
.left {
animation: show-view-left 0.3s;
}
.right {
animation: show-view-right 0.3s;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="layout">
<view class="bg">
<image src="../../../assets/images/media/bg-3.webp" />
</view>
<view class="content">
<view class="canvas-box">
<template v-for="(i,index) in views">
<view
:key="index"
v-show="viewIndex == index"
>
<wnCanvas
saveImageType="3"
:drawImage="i.detailUrl"
:drawStatus="penSwitch"
:canvasId="`c-3-${index}`"
></wnCanvas>
</view>
</template>
</view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
views: Array,
penSwitch: Boolean
},
name: 'Media_3',
data () {
return {
viewIndex: 0
}
},
mounted () {
},
methods: {
changeView (index) {
this.viewIndex = index
},
}
}
</script>
<style scoped lang='scss'>
.layout {
padding-top: 192rpx;
position: relative;
.bg {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 240rpx;
image{
width: 100%;
height: 100%;
}
}
.content {
border-radius: 40rpx 40rpx 0 0;
background: linear-gradient(180deg, #f7f9fc 0%, #f7f9fc 100%);
overflow: hidden;
position: relative;
z-index: 1;
.title {
font-size: 40rpx;
line-height: 48rpx;
color: #1a1a1a;
padding: 32rpx 0;
text-align: center;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="layout">
<view class="bg">
<image src="../../../assets/images/media/bg-4.webp" />
</view>
<view class="content">
<view class="title">{{title||'问界·汽车产品三包凭证'}}</view>
<template v-if="views.length">
<tabs
:list="views"
@tabclick="changeView"
ref="tabs"
/>
</template>
<view class="canvas-box">
<template v-for="(i,index) in views">
<view
:key="index"
v-show="viewIndex == index"
:class="['canvas-view', `${viewIndex == 0 ? 'left' : 'right'}`]"
>
<wnCanvas
saveImageType="3"
:drawImage="i.detailUrl"
:drawStatus="penSwitch"
:canvasId="`c-4-${index}`"
></wnCanvas>
</view>
</template>
</view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
import Tabs from './Tabs.vue'
export default {
components: { Tabs },
props: {
views: Array,
penSwitch: Boolean,
title:String
},
name: 'Media_4',
data () {
return {
viewIndex: 0
}
},
watch: {
watchStatus: {
immediate: true,
handler (newval) {
this.$refs?.tabs?.tabClick(0)
}
},
},
computed: {
watchStatus () {
return this.$store.state.user.historyStatus
},
},
mounted () {
},
methods: {
changeView (index) {
this.viewIndex = index
},
}
}
</script>
<style scoped lang='scss'>
.layout {
padding-top: 192rpx;
position: relative;
.bg {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 240rpx;
image{
width: 100%;
height: 100%;
}
}
.content {
border-radius: 40rpx 40rpx 0 0;
background: linear-gradient(180deg, #f7f9fc 0%, #f7f9fc 100%);
overflow: hidden;
position: relative;
z-index: 1;
.title {
font-size: 40rpx;
line-height: 48rpx;
color: #1a1a1a;
padding: 32rpx 0;
text-align: center;
}
}
.canvas-box {
margin-top: -4rpx;
.left {
animation: show-view-left 0.3s;
}
.right{
animation: show-view-right 0.3s;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
<template>
<view class="layout">
<view class="bg">
<image src="../../../assets/images/media/bg-5.webp" />
</view>
<view class="content">
<view class="canvas-box">
<template v-for="(i,index) in views">
<view
:key="index"
v-show="viewIndex == index"
>
<wnCanvas
saveImageType="3"
:drawImage="i.detailUrl"
:drawStatus="penSwitch"
:canvasId="`c-5-${index}`"
></wnCanvas>
</view>
</template>
</view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
props: {
views: Array,
penSwitch: Boolean
},
name: 'Media_5',
data () {
return {
viewIndex: 0
}
},
mounted () {
},
methods: {
}
}
</script>
<style scoped lang='scss'>
.layout {
padding-top: 192rpx;
position: relative;
.bg {
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 240rpx;
image{
width: 100%;
height: 100%;
}
}
.content {
border-radius: 40rpx 40rpx 0 0;
background: linear-gradient(180deg, #f7f9fc 0%, #f7f9fc 100%);
overflow: hidden;
position: relative;
z-index: 1;
.title {
font-weight: 500;
font-size: 48rpx;
color: #1a1a1a;
padding: 32rpx 0;
text-align: center;
}
}
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
class="record-box" class="record-box"
scroll-y scroll-y
@scrolltolower="pageonReachBottom" @scrolltolower="pageonReachBottom"
@scroll="scroll"
> >
<view class="record-content"> <view class="record-content">
<view class="data-box"> <view class="data-box">
...@@ -30,6 +31,7 @@ ...@@ -30,6 +31,7 @@
</view> </view>
</template> </template>
</view> </view>
<view :class="['data-tabs-box', {sticky:sticky} ]">
<view class="data-tabs"> <view class="data-tabs">
<template v-for="(i, index) in dateList"> <template v-for="(i, index) in dateList">
<view <view
...@@ -40,6 +42,7 @@ ...@@ -40,6 +42,7 @@
</template> </template>
<view :class="['active-btn', `active-btn-${dateIndex}`]"></view> <view :class="['active-btn', `active-btn-${dateIndex}`]"></view>
</view> </view>
</view>
<view class="list"> <view class="list">
<template v-if="flag"> <template v-if="flag">
<template v-if="list.length && list[0] && list[0].length"> <template v-if="list.length && list[0] && list[0].length">
...@@ -133,13 +136,17 @@ export default { ...@@ -133,13 +136,17 @@ export default {
list: [], list: [],
flag: false, flag: false,
nothing: false, nothing: false,
pageSize: 18 pageSize: 18,
sticky: false
} }
}, },
mounted () { mounted () {
this.init() this.init()
}, },
methods: { methods: {
scroll (e) {
this.sticky = e.detail.scrollTop >= 148
},
init () { init () {
this.dateList.map((e, index) => { this.dateList.map((e, index) => {
const tatget = ['day', 'week', 'month'][index] const tatget = ['day', 'week', 'month'][index]
...@@ -275,7 +282,7 @@ export default { ...@@ -275,7 +282,7 @@ export default {
.record-box { .record-box {
box-sizing: border-box; box-sizing: border-box;
height: 100%; height: 100%;
.record-content{ .record-content {
padding: 96rpx 60rpx; padding: 96rpx 60rpx;
} }
.list { .list {
...@@ -336,7 +343,7 @@ export default { ...@@ -336,7 +343,7 @@ export default {
.data-box { .data-box {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
margin-bottom: 60rpx;
.data-item { .data-item {
width: 580rpx; width: 580rpx;
height: 200rpx; height: 200rpx;
...@@ -392,16 +399,21 @@ export default { ...@@ -392,16 +399,21 @@ export default {
color: #ff8e43; color: #ff8e43;
} }
} }
.data-tabs { .data-tabs-box {
position: relative;
top: 0;
z-index: 3;
width: calc(100% + 120rpx);
transform: translateX(-60rpx);
padding-top: 60rpx;
.data-tabs {
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
width: 784rpx; width: 784rpx;
height: 70rpx; height: 70rpx;
border-radius: 370rpx; border-radius: 370rpx;
margin: 0 auto; margin: 0 auto;
position: sticky; position: relative;
top: 0;
z-index: 3;
&::after { &::after {
position: absolute; position: absolute;
z-index: -2; z-index: -2;
...@@ -443,6 +455,26 @@ export default { ...@@ -443,6 +455,26 @@ export default {
.active-btn-2 { .active-btn-2 {
left: 544rpx; left: 544rpx;
} }
}
}
.sticky {
position: sticky;
top: 0;
background-image: url("../../../assets/images/home/bg.webp");
background-size: 100vw 100vh;
background-position: -220rpx 0;
background-attachment: fixed !important;
&::after {
position: absolute;
left: 60rpx;
bottom: -80rpx;
width: calc(100% - 270rpx);
height: 80rpx;
transform: scaleY(-1);
background-image: linear-gradient(180deg, #e9f1fe00 0%, #f3f7ff 100%);
content: '';
}
} }
.nothing { .nothing {
width: 100%; width: 100%;
......
<template>
<uni-popup
ref="popup"
border-radius="20px"
>
<view class="setting-box">
<view
class="close flex"
@click="close"
>
<uni-icons
type="closeempty"
:size="14"
color="#1A1A1A"
></uni-icons>
</view>
<view class="app-info flex">
<view class="sprite-icon icon-logo"></view>
展业助手
<view class="version">
版本号:V{{version}}
</view>
</view>
<view class="btn-box">
<view
v-if="accountLength > 1"
class="btn flex"
@click="changeAccount"
>
切换账号
</view>
<view
class="btn flex logout"
@click="logout"
>退出</view>
</view>
<view class="a" @click="jump('agreement')">《用户隐私协议》</view>
<view
class="icp flex"
@click="jump('icp')"
>
ICP备案号:苏ICP备18023686号-2A
<view class="sprite-icon icon-arrow-right"></view>
</view>
</view>
</uni-popup>
</template>
<script type='text/ecmascript-6'>
import myClick from "@/mixin/click";
export default {
mixins: [myClick],
name: 'SettingBox',
data () {
return {
accountLength: uni.$storage.get('accountLength'),
version: '',
}
},
mounted () {
this.version = plus?.runtime?.version || '1.0.0'
},
methods: {
open () {
this.$refs.popup.open("center");
},
close () {
this.$refs.popup.close()
},
changeAccount () {
uni.redirectTo({
url: '/pages/common/accountItems'
})
},
// 退出
logout () {
uni.$storage.rm("userInfo");
uni.$storage.rm("sessionId");
uni.$storage.rm("noSignInUuid");
this.stopAudio();
uni.reLaunch({
url: "/pages/common/login",
});
},
jump (type) {
let url = type == 'icp' ? 'https://beian.miit.gov.cn/' : 'https://img01.glsx.com.cn/weapp/resource/saas/app/privacy.html'
uni.navigateTo({
url: `/pages/common/webview?url=${url}`
})
}
}
}
</script>
<style scoped lang='scss'>
.setting-box {
position: relative;
width: 720rpx;
height: 880rpx;
background: #ffffff;
border-radius: 40rpx;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
.close {
position: absolute;
width: 120rpx;
height: 120rpx;
top: 0;
right: 0;
justify-content: center;
}
.app-info {
flex-direction: column;
font-size: 32rpx;
color: #333333;
.sprite-icon {
margin-bottom: 12rpx;
}
.version {
margin-top: 8rpx;
font-size: 24rpx;
color: #999999;
}
}
.btn-box {
margin-top: 120rpx;
.btn {
width: 384rpx;
height: 64rpx;
background: #3b73ff1a;
border: 2rpx solid transparent;
border-radius: 32rpx;
justify-content: center;
font-size: 28rpx;
color: #3b73ff;
margin-bottom: 16rpx;
}
.logout {
background: #ffffff;
color: #333333;
border: 2rpx solid #e8e8e8;
}
}
.a {
font-size: 24rpx;
color: #2c66f7;
margin: 48rpx 0 16rpx;
}
.icp {
font-size: 24rpx;
color: #999999;
}
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -13,14 +13,14 @@ ...@@ -13,14 +13,14 @@
<view :class="['home', { show: !id }]"> <view :class="['home', { show: !id }]">
<view class="bg"> <view class="bg">
<view class="top"> <view class="top">
<view class="top-one"></view> <view class="top-one" :style="randomize"></view>
</view> </view>
<view class="bottom"> <view class="bottom">
<view class="bottom-one"></view> <view class="bottom-one" :style="randomize"></view>
<view class="bottom-two"></view> <view class="bottom-two" :style="randomize"></view>
<view <view
class="bottom-three" class="bottom-three"
:style="{transform: 'translate(' + x + 'px, ' + y + 'px)'}" :style="randomize"
></view> ></view>
</view> </view>
</view> </view>
...@@ -30,17 +30,8 @@ ...@@ -30,17 +30,8 @@
<!-- 左侧内容 --> <!-- 左侧内容 -->
<view class="user-info flex"> <view class="user-info flex">
<view class="user-avatar sprite-icon icon-icon-avatar"></view> <view class="user-avatar sprite-icon icon-icon-avatar"></view>
<view class="user-name">{{ userInfo.name }}</view> <view class="user-name">{{ userInfo.name }}</view>
<!-- <view class="user-position">延保专员</view> --> <!-- <view class="user-position">延保专员</view> -->
<view
v-if="accountLength > 1"
class="account-change flex"
@click="changeAccount"
>
<view class="sprite-icon icon-change-account"></view>
切换账号
</view>
</view> </view>
<view class="left-tabs"> <view class="left-tabs">
<template v-for="(i,index) in tabs"> <template v-for="(i,index) in tabs">
...@@ -58,20 +49,19 @@ ...@@ -58,20 +49,19 @@
</view> </view>
<view class="left-footer"> <view class="left-footer">
<view <view
class="logout" class="btn"
@click="$refs.kfRef.open()" @click="$refs.kfRef.open()"
> >
<view class="icon-logout sprite-icon icon-feedback"></view> <view class="sprite-icon icon-feedback"></view>
<view>反馈</view> <view>反馈</view>
</view> </view>
<view <view
class="logout" class="btn"
@click="logout" @click="$refs.settingRef.open()"
> >
<view class="icon-logout sprite-icon icon-icon-logout"></view> <view class="sprite-icon icon-setting"></view>
<view>退出</view> <view>设置</view>
</view> </view>
<view class="version">版本:V{{version}}</view>
</view> </view>
</view> </view>
<view class="right-side"> <view class="right-side">
...@@ -195,6 +185,7 @@ ...@@ -195,6 +185,7 @@
@nextStep="nextStep" @nextStep="nextStep"
@back="back" @back="back"
/> />
<setting-box ref="settingRef" />
</view> </view>
</template> </template>
<script> <script>
...@@ -204,9 +195,10 @@ import KfBox from "./components/KfBox"; ...@@ -204,9 +195,10 @@ import KfBox from "./components/KfBox";
import { mapMutations } from "vuex"; import { mapMutations } from "vuex";
import NoviceGuide from "@/components/NoviceGuide.vue"; import NoviceGuide from "@/components/NoviceGuide.vue";
import RecordList from './components/RecordList.vue'; import RecordList from './components/RecordList.vue';
import SettingBox from './components/SettingBox'
export default { export default {
mixins: [myClick], mixins: [myClick],
components: { detail, KfBox, NoviceGuide, RecordList }, components: { detail, KfBox, NoviceGuide, RecordList, SettingBox },
data () { data () {
return { return {
moduleList: [], moduleList: [],
...@@ -224,17 +216,25 @@ export default { ...@@ -224,17 +216,25 @@ export default {
icon: 'record' icon: 'record'
}], }],
tabIndex: 0, tabIndex: 0,
version: '',
payInfo: null, payInfo: null,
accountInfo: null, accountInfo: null,
accountLength: uni.$storage.get('accountLength'), dateKey:null
x: 0,
y: 0,
}; };
}, },
mounted () { mounted () {
this.randomize(); setInterval(()=>{
setInterval(this.randomize, 3e3); this.dateKey = Date.now()
},5e3)
},
computed:{
randomize () {
let {dateKey} = this
const maxX = uni.getSystemInfoSync().windowWidth - 300,
maxY = uni.getSystemInfoSync().windowHeight - 100,
x = Math.floor(Math.random() * maxX),
y = Math.floor(Math.random() * maxY)
return `transform:translate(${x}px,${y}px);${dateKey};`
},
}, },
onBackPress (options) { onBackPress (options) {
if (options.from === "backbutton") { if (options.from === "backbutton") {
...@@ -255,16 +255,10 @@ export default { ...@@ -255,16 +255,10 @@ export default {
// else this.$refs.recordRef?.pageonReachBottom() // else this.$refs.recordRef?.pageonReachBottom()
}, },
methods: { methods: {
randomize() {
const maxX = uni.getSystemInfoSync().windowWidth - 300
const maxY = uni.getSystemInfoSync().windowHeight - 100
this.x = Math.floor(Math.random() * maxX);
this.y = Math.floor(Math.random() * maxY);
},
init () { init () {
this.getSoure(); this.getSoure();
this.findPayInfo(); this.findPayInfo();
this.version = plus?.runtime?.version || '1.0.0'
const userInfo = uni.$storage.get("userInfo"), const userInfo = uni.$storage.get("userInfo"),
{ shopMerchantId } = userInfo; { shopMerchantId } = userInfo;
this.userInfo = userInfo; this.userInfo = userInfo;
...@@ -318,16 +312,7 @@ export default { ...@@ -318,16 +312,7 @@ export default {
this.id = this.moduleList[0].id; this.id = this.moduleList[0].id;
this.type = "edit"; this.type = "edit";
}, },
// 退出
logout () {
uni.$storage.rm("userInfo");
uni.$storage.rm("sessionId");
uni.$storage.rm("noSignInUuid");
this.stopAudio();
uni.reLaunch({
url: "/pages/common/login",
});
},
toDetail (item) { toDetail (item) {
this.chooseItem = item; this.chooseItem = item;
this.$refs.previewRef.open(); this.$refs.previewRef.open();
...@@ -370,9 +355,6 @@ export default { ...@@ -370,9 +355,6 @@ export default {
if (this.thumbnailFulfillList.length == this.moduleList.length) if (this.thumbnailFulfillList.length == this.moduleList.length)
this.skeletonStatus = false; this.skeletonStatus = false;
}, },
openKf () {
this.$refs.kfRef.open();
},
nextStep () { nextStep () {
let { id } = this.moduleList[0]; let { id } = this.moduleList[0];
this.type = "preview"; this.type = "preview";
...@@ -386,11 +368,6 @@ export default { ...@@ -386,11 +368,6 @@ export default {
this.$refs.finish.close(); this.$refs.finish.close();
this.$refs.detail.open(); this.$refs.detail.open();
}, },
changeAccount () {
uni.redirectTo({
url: '/pages/common/accountItems'
})
},
// 查询门店支付配置 // 查询门店支付配置
async findPayInfo () { async findPayInfo () {
const { shopMerchantId } = uni.$storage.get("userInfo"); const { shopMerchantId } = uni.$storage.get("userInfo");
...@@ -445,6 +422,7 @@ export default { ...@@ -445,6 +422,7 @@ export default {
background: #fff; background: #fff;
box-shadow: inset 2rpx 2rpx 0 2rpx #ffffff80; box-shadow: inset 2rpx 2rpx 0 2rpx #ffffff80;
border-radius: 50% / 25%; border-radius: 50% / 25%;
transition: all 2s;
z-index: 2; z-index: 2;
&::before { &::before {
position: absolute; position: absolute;
...@@ -519,6 +497,7 @@ export default { ...@@ -519,6 +497,7 @@ export default {
opacity: 0.4; opacity: 0.4;
background: #ebfffd; background: #ebfffd;
filter: blur(36rpx); filter: blur(36rpx);
transition: all 2s;
} }
&-two { &-two {
position: absolute; position: absolute;
...@@ -531,14 +510,14 @@ export default { ...@@ -531,14 +510,14 @@ export default {
left: -225rpx; left: -225rpx;
bottom: -225rpx; bottom: -225rpx;
border-radius: 100%; border-radius: 100%;
transition: all 2s;
} }
&-three { &-three {
width: 762.7rpx; width: 762.7rpx;
height: 210.92rpx; height: 210.92rpx;
opacity: 0.16; opacity: 0.16;
background: #fff;
box-shadow: inset 2rpx 2rpx 0 2rpx #ffffff80; box-shadow: inset 2rpx 2rpx 0 2rpx #ffffff80;
background-color: #fff; background-color: fff;
position: fixed; position: fixed;
left: 0; left: 0;
top: 0; top: 0;
...@@ -669,30 +648,23 @@ export default { ...@@ -669,30 +648,23 @@ export default {
} }
.left-footer { .left-footer {
margin-top: auto; margin-top: auto;
padding-bottom: 32rpx; padding-bottom: 64rpx;
.version {
font-size: 20rpx;
color: #999999;
margin-top: 32rpx;
text-align: center;
}
} }
.logout { .btn {
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
margin: 16rpx auto 0; margin: 32rpx auto 0;
font-size: 28rpx; font-size: 28rpx;
color: #6c6c70; color: #333;
width: 120rpx; width: 108rpx;
height: 56rpx; height: 40rpx;
box-sizing: border-box; box-sizing: border-box;
} .sprite-icon {
.icon-logout {
width: 32rpx; width: 32rpx;
height: 32rpx; height: 32rpx;
margin-right: 8rpx; margin-right: 20rpx;
}
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!