Commit 2cb8c632 by 胡悦

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

2 parents dba4cbce 4e69ec3b
...@@ -38,7 +38,7 @@ module.exports = { ...@@ -38,7 +38,7 @@ module.exports = {
return http.fetch('dj.api.smartcarlife.workWechat.selectAccountLogin', data) return http.fetch('dj.api.smartcarlife.workWechat.selectAccountLogin', data)
}, },
// 获取园区店开通的场景入口 // 获取园区店开通的场景入口
getYqMerchantSceneConfigAPI(data) { getYqMerchantSceneConfigAPI (data) {
data.projectName = 'boutique' data.projectName = 'boutique'
return http.post({ return http.post({
method: 'dj.api.smartcarlife.select.openScene.info', method: 'dj.api.smartcarlife.select.openScene.info',
......
...@@ -72,6 +72,12 @@ export default { ...@@ -72,6 +72,12 @@ export default {
}; };
}, },
onLoad (options) { onLoad (options) {
let userInfo = uni.$storage.get('userInfo')
uni.$api.userApi.getListSelectAccount().then(res => {
if (res.code == 0 && userInfo) uni.reLaunch({
url: '/pages/home/home'
})
})
}, },
methods: { methods: {
/**获取验证码 */ /**获取验证码 */
...@@ -80,7 +86,7 @@ export default { ...@@ -80,7 +86,7 @@ export default {
try { try {
if (!mobile) throw '请输入手机号'; if (!mobile) throw '请输入手机号';
if (!phoneRex.test(mobile)) throw '请输入正确的手机号'; if (!phoneRex.test(mobile)) throw '请输入正确的手机号';
if (count) throw '验证码发送过于频繁,请稍后在试'; if (count) throw '验证码发送过于频繁,请稍后再试';
this.countDown(60); this.countDown(60);
uni.showLoading(); uni.showLoading();
const { code, message } = await uni.$api.userApi.getSmsCode({ mobile }); const { code, message } = await uni.$api.userApi.getSmsCode({ mobile });
...@@ -155,7 +161,7 @@ export default { ...@@ -155,7 +161,7 @@ export default {
url: '/pages/common/accountItems' url: '/pages/common/accountItems'
}) })
}, },
}, },
}; };
</script> </script>
......
<template>
<view class="tool-box">
<view
:class="['btn', {hideIcon:!show}]"
@click="show = false"
>
<glsx-image
src="tool/file.png"
class="icon"
/>
文件夹
</view>
<view :class="['list',{showList:!show}]">
<view
class="title"
@click="show = true"
>文件夹</view>
<template v-for="(i,index) in toolList">
<view
class="item"
:key="index"
@click="jump(i)"
>
<view class="icon">
<glsx-image
:src="i.icon"
class="icon"
/>
</view>
{{i.label}}
</view>
</template>
<view class="item">
<view class="icon">
<glsx-image
src="tool/finish.png"
class="icon"
/>
</view>
完成接待
</view>
</view>
</view>
</template>
<script type='text/ecmascript-6'>
export default {
name: 'ToolBox',
data () {
return {
show: true,
toolList: [
{
id: 1,
label: '交车告知书',
icon: 'tool/1.png'
},
{
id: 2,
label: '延保明细',
icon: 'tool/2.png'
},
{
id: 3,
label: '保修告知书',
icon: 'tool/3.png'
},
{
id: 4,
label: '三包政策',
icon: 'tool/4.png'
},
{
id: 5,
label: '历史成交',
icon: 'tool/5.png'
},
{
id: 6,
label: '质保升级',
icon: 'tool/6.png'
}
]
}
},
methods: {
jump (item) {
console.log(item)
this.$emit('choose', item)
}
}
}
</script>
<style scoped lang='scss'>
.tool-box {
position: fixed;
right: 40rpx;
top: 50%;
transform: translateY(-50%);
z-index: 998;
width: 128rpx;
.btn {
width: 100%;
height: 128rpx;
background-image: linear-gradient(180deg, #ffffff 0%, #f8f9fb 100%);
border: 2.08rpx solid #ffffff;
box-shadow: 0 8rpx 24rpx 0 #00000033;
border-radius: 16rpx;
font-size: 24rpx;
color: #292d33;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
.icon {
width: 60rpx;
height: 60rpx;
margin-bottom: 8rpx;
transition: all .15s;
}
}
.hideIcon{
height: 0;
overflow: hidden;
.icon{
height: 0;
margin-bottom: 0;
}
}
.list {
width: 100%;
height: 0;
background: #ffffff;
box-shadow: 0 8rpx 22rpx 0 #00000029;
border-radius: 16rpx;
flex-direction: column;
align-items: center;
transition: all .15s;
overflow: hidden;
.title {
width: 128rpx;
height: 56rpx;
background: #f4f4f5;
border: 2rpx solid #ffffff;
border-radius: 16rpx 16rpx 0 0;
display: flex;
align-items: center;
justify-content: center;
}
.item {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-size: 20rpx;
color: #666666;
height: 120rpx;
width: 100%;
.icon {
width: 60rpx;
height: 60rpx;
margin-bottom: 8rpx;
}
}
}
.showList{
display: flex;
height: 896rpx;
}
}
</style>
\ No newline at end of file \ No newline at end of file
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
--> -->
<template> <template>
<view> <view>
<tool-box />
详情页 详情页
<button @click="open">完成接待</button> <button @click="open">完成接待</button>
<uni-popup <uni-popup
...@@ -75,6 +76,7 @@ ...@@ -75,6 +76,7 @@
</view> </view>
</template> </template>
<script> <script>
import ToolBox from './components/ToolBox.vue'
const PAYMENT_TYPE = [ const PAYMENT_TYPE = [
{ {
name: "扫码支付", name: "扫码支付",
...@@ -109,7 +111,11 @@ const ACCOUT_LIST = [ ...@@ -109,7 +111,11 @@ const ACCOUT_LIST = [
]; ];
import myClick from "@/mixin/click"; import myClick from "@/mixin/click";
export default { export default {
components: { ToolBox },
mixins: [myClick], mixins: [myClick],
component:{
ToolBox
},
data() { data() {
return { return {
payInfo: {}, payInfo: {},
......
...@@ -122,6 +122,8 @@ export default { ...@@ -122,6 +122,8 @@ export default {
}, },
// 退出 // 退出
logout() { logout() {
uni.$storage.rm('userInfo')
uni.$storage.rm('sessionId')
this.stopAudio(); this.stopAudio();
uni.reLaunch({ uni.reLaunch({
url: "/pages/common/login", url: "/pages/common/login",
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!