Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
account-book
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
刘文虎
account-book
Commits
8836f8d5
Commit
8836f8d5
authored
Aug 18, 2022
by
刘文虎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
安卓登录/支付
parent
12f90e11
Pipeline
#3283
canceled with stages
Changes
21
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
281 additions
and
171 deletions
+281
-171
.env.js
.env.js
+1
-1
launch.json
.hbuilderx/launch.json
+4
-0
App.vue
App.vue
+5
-0
index.js
api/login/index.js
+11
-1
billing-daily.vue
components/billing-daily/billing-daily.vue
+13
-3
index.vue
components/bottom-pay/index.vue
+17
-5
mid-popup.vue
components/mid-popup/mid-popup.vue
+17
-20
main.js
main.js
+3
-1
manifest.json
manifest.json
+70
-15
index.vue
pages/index/index.vue
+24
-18
binding-phone.vue
pages/login/binding-phone/binding-phone.vue
+53
-35
login.vue
pages/login/login.vue
+38
-53
quick-login.vue
pages/login/quick-login/quick-login.vue
+1
-1
pay.vue
pages/mine/pay/pay.vue
+7
-7
weixinzhifu@3x.png
static/image/mine/weixinzhifu@3x.png
+0
-0
login.js
store/modules/login.js
+7
-5
config.js
utils/config.js
+2
-0
index.js
utils/options/index/index.js
+3
-3
platform.js
utils/platform.js
+1
-0
request.js
utils/request.js
+3
-2
vue.config.js
vue.config.js
+1
-1
No files found.
.env.js
View file @
8836f8d5
;(
function
()
{
;(
function
()
{
let
NODE_ENV
=
'
prod
'
// dev:开发环境 | test:测试环境 | prod:生产环境
let
NODE_ENV
=
'
test
'
// dev:开发环境 | test:测试环境 | prod:生产环境
let
ENV_VAR
=
null
let
ENV_VAR
=
null
let
VERSION
=
'v1.0.11'
let
VERSION
=
'v1.0.11'
if
(
process
.
env
.
NODE_ENV
===
'development'
)
{
if
(
process
.
env
.
NODE_ENV
===
'development'
)
{
...
...
.hbuilderx/launch.json
View file @
8836f8d5
...
@@ -2,6 +2,10 @@
...
@@ -2,6 +2,10 @@
//
launchtype项可配置值为local或remote
,
local代表前端连本地云函数,remote代表前端连云端云函数
//
launchtype项可配置值为local或remote
,
local代表前端连本地云函数,remote代表前端连云端云函数
"version"
:
"0.0"
,
"version"
:
"0.0"
,
"configurations"
:
[{
"configurations"
:
[{
"app-plus"
:
{
"launchtype"
:
"local"
},
"default"
:
"default"
:
{
{
"launchtype"
:
"local"
"launchtype"
:
"local"
...
...
App.vue
View file @
8836f8d5
<
script
>
<
script
>
// import{setToken,setRefreshToken} from "@/utils/common.js"
export
default
{
export
default
{
onLaunch
:
function
()
{
onLaunch
:
function
()
{
// setToken("eyJ0eXAiOiJKc29uV2ViVG9rZW4iLCJhbGciOiJIUzI1NiJ9.eyJ1bmlvbklkIjoib1gtVEs2VmVTWmNVbUx0cWhodk15NU1mYk9IMCIsIm9wZW5JZCI6Im9aZk5VNUVhSEF3bGdrbm8yQno3Y1Q0X0JRVUUiLCJuYW1lIjoi6Ze7562gIiwibW9iaWxlIjoiMTM0MjM4MzExOTEiLCJ0b2tlbl90eXBlIjoidG9rZW4iLCJ1c2VyaWQiOiIxNTUyNDg2NzEyMzY4NjkzMjQ4IiwiYWNjb3VudCI6IjEzNDIzODMxMTkxIiwiaWF0IjoxNjYwNzA4MzYyLCJuYmYiOjE2NjA3MDgzNjIsImV4cCI6MTY2MjAwNDM2Mn0.9hBVwqmYDxL4Q0S05JXQqteOWI9kda_UXxX5-eNO1LY")
// setRefreshToken("eyJ0eXAiOiJKc29uV2ViVG9rZW4iLCJhbGciOiJIUzI1NiJ9.eyJ1bmlvbklkIjoib1gtVEs2VmVTWmNVbUx0cWhodk15NU1mYk9IMCIsIm9wZW5JZCI6Im9aZk5VNUVhSEF3bGdrbm8yQno3Y1Q0X0JRVUUiLCJ0b2tlbl90eXBlIjoicmVmcmVzaF90b2tlbiIsInVzZXJpZCI6IjE1NTI0ODY3MTIzNjg2OTMyNDgiLCJpYXQiOjE2NjA3MDgzNjIsIm5iZiI6MTY2MDcwODM2MiwiZXhwIjoxNzE5MDI4MzYyfQ.rKsc9uKkNwKMFXxZ--MxHAvXdtH6iWlR_gWD_vdQHT4")
// 版本更新
// 版本更新
this
.
updateApp
();
this
.
updateApp
();
console
.
log
(
'App Launch'
)
console
.
log
(
'App Launch'
)
...
...
api/login/index.js
View file @
8836f8d5
...
@@ -11,8 +11,18 @@ export function userAuthLogin(data) {
...
@@ -11,8 +11,18 @@ export function userAuthLogin(data) {
export
function
sendCode
(
data
)
{
export
function
sendCode
(
data
)
{
return
request
({
return
request
({
url
:
`/anno/mob
li
e/sendCode`
,
url
:
`/anno/mob
il
e/sendCode`
,
method
:
'GET'
,
method
:
'GET'
,
data
data
})
})
}
}
export
function
mobileLogin
(
data
)
{
return
request
({
url
:
`/anno/mobileLogin`
,
method
:
'GET'
,
data
,
noLoading
:
true
})
}
\ No newline at end of file
components/billing-daily/billing-daily.vue
View file @
8836f8d5
...
@@ -131,7 +131,9 @@ export default {
...
@@ -131,7 +131,9 @@ export default {
...
mapGetters
([
'billType'
]),
...
mapGetters
([
'billType'
]),
},
},
mounted
()
{
mounted
()
{
this
.
init
();
this
.
$nextTick
(()
=>
{
this
.
init
();
})
},
},
onUnload
()
{
onUnload
()
{
uni
.
$off
(
this
.
notification
);
uni
.
$off
(
this
.
notification
);
...
@@ -144,7 +146,10 @@ export default {
...
@@ -144,7 +146,10 @@ export default {
this
.
getBillTypeOptions
();
this
.
getBillTypeOptions
();
this
.
getQiniuToken
();
this
.
getQiniuToken
();
}
}
this
.
$refs
[
'ab-calculator'
].
clearAll
()
// this.$nextTick(()=>{
// this.$refs['calendar-popup'].open();
// this.$refs['ab-calculator'].clearAll()
// })
},
},
async
getBillTypeOptions
()
{
async
getBillTypeOptions
()
{
...
@@ -192,7 +197,6 @@ export default {
...
@@ -192,7 +197,6 @@ export default {
open
(
id
)
{
open
(
id
)
{
this
.
getQiniuToken
();
this
.
getQiniuToken
();
// this.getBillTypeOptions();
// this.getBillTypeOptions();
this
.
$refs
[
'ab-calculator'
].
clearAll
()
if
(
id
)
{
if
(
id
)
{
this
.
id
=
id
;
this
.
id
=
id
;
this
.
getDetail
();
this
.
getDetail
();
...
@@ -214,6 +218,9 @@ export default {
...
@@ -214,6 +218,9 @@ export default {
this
.
form
.
classificationId
=
this
.
billingCategoryList
[
0
]
&&
this
.
billingCategoryList
[
0
][
0
].
id
||
''
;
this
.
form
.
classificationId
=
this
.
billingCategoryList
[
0
]
&&
this
.
billingCategoryList
[
0
][
0
].
id
||
''
;
}
}
this
.
show
=
true
;
this
.
show
=
true
;
this
.
$nextTick
(()
=>
{
this
.
$refs
[
'ab-calculator'
].
clearAll
()
})
}
}
},
},
async
getDetail
()
{
async
getDetail
()
{
...
@@ -225,6 +232,9 @@ export default {
...
@@ -225,6 +232,9 @@ export default {
this
.
form
=
data
;
this
.
form
=
data
;
await
this
.
getBillTypeOptions
();
await
this
.
getBillTypeOptions
();
this
.
show
=
true
;
this
.
show
=
true
;
this
.
$nextTick
(()
=>
{
this
.
$refs
[
'ab-calculator'
].
clearAll
()
})
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
e
);
console
.
log
(
e
);
//TODO handle the exception
//TODO handle the exception
...
...
components/bottom-pay/index.vue
View file @
8836f8d5
...
@@ -9,7 +9,10 @@
...
@@ -9,7 +9,10 @@
<view
class=
"item-title"
>
{{
item
.
title
}}
</view>
<view
class=
"item-title"
>
{{
item
.
title
}}
</view>
</view>
</view>
<view
class=
"right-view"
>
<view
class=
"right-view"
>
<image
v-if=
"item.select"
class=
"select-image"
:src=
"selectImage"
></image>
<!--
<image
v-if=
"item.select"
class=
"select-image"
:src=
"selectImage"
></image>
-->
<view
v-if=
"item.select"
class=
"selected select-view"
>
<u-icon
name=
"checkbox-mark"
></u-icon>
</view>
<view
v-else
class=
"select-view"
></view>
<view
v-else
class=
"select-view"
></view>
</view>
</view>
</view>
</view>
...
@@ -32,9 +35,8 @@
...
@@ -32,9 +35,8 @@
data
()
{
data
()
{
return
{
return
{
show
:
false
,
show
:
false
,
selectImage
:
'/static/images/mine/xuanze1@3x.png'
,
list
:
[{
list
:
[{
image
:
'/static/image
s
/mine/weixinzhifu@3x.png'
,
image
:
'/static/image/mine/weixinzhifu@3x.png'
,
title
:
'微信支付'
,
title
:
'微信支付'
,
select
:
true
,
select
:
true
,
provider
:
'wxpay'
provider
:
'wxpay'
...
@@ -132,6 +134,16 @@
...
@@ -132,6 +134,16 @@
border-radius
:
50%
;
border-radius
:
50%
;
border
:
2rpx
solid
#8D8D8D
;
border
:
2rpx
solid
#8D8D8D
;
}
}
.selected
{
border-color
:
$default-color
;
background-color
:
$default-color
;
color
:
#FFFFFF
;
display
:
flex
;
align-items
:
center
;
justify-content
:
center
;
font-size
:
28rpx
;
font-weight
:
bold
;
}
}
}
}
}
}
}
...
@@ -140,8 +152,8 @@
...
@@ -140,8 +152,8 @@
margin-top
:
220rpx
;
margin-top
:
220rpx
;
.buy-button
{
.buy-button
{
background-color
:
#3383fe
;
background-color
:
$default-color
;
border-radius
:
52
rpx
;
border-radius
:
16
rpx
;
color
:
#fff
;
color
:
#fff
;
text-align
:
center
;
text-align
:
center
;
height
:
104rpx
;
height
:
104rpx
;
...
...
components/mid-popup/mid-popup.vue
View file @
8836f8d5
<
template
>
<
template
>
<view
class=
""
>
<view
class=
""
>
<u-popup
v-model=
"show"
border-radius=
"24"
safe-area-inset-bottom
mode=
"bottom"
:duration=
'100'
>
<u-popup
v-model=
"show"
border-radius=
"24"
safe-area-inset-bottom
mode=
"bottom"
:duration=
"100"
>
<view
class=
"mid-popup"
>
<view
class=
"mid-popup"
>
<u-row
gutter=
"16"
>
<u-row
gutter=
"16"
>
<u-col
span=
"4"
v-for=
"(item, index) in list"
:key=
"index"
>
<u-col
span=
"4"
v-for=
"(item, index) in list"
:key=
"index"
>
<view
class=
"button-view"
@
click=
"clickItem(item)"
>
<view
class=
"button-view"
@
click=
"clickItem(item)"
>
<view
class=
"button-view-icon"
><image
:src=
"i
tem.icon"
mode=
"
"
></image></view>
<view
class=
"button-view-icon"
><image
:src=
"i
ndexBaseUrl+item.icon"
mode=
""
v-if=
"item.icon
"
></image></view>
<view
class=
"button-view-content"
>
{{
item
.
label
}}
</view>
<view
class=
"button-view-content"
>
{{
item
.
label
}}
</view>
</view>
</view>
</u-col>
</u-col>
...
@@ -14,20 +14,16 @@
...
@@ -14,20 +14,16 @@
</view>
</view>
</u-popup>
</u-popup>
<billing-daily
ref=
"billing-daily"
:type=
"type"
@
afterSave=
"afterSave"
></billing-daily>
<billing-daily
ref=
"billing-daily"
:type=
"type"
@
afterSave=
"afterSave"
></billing-daily>
<PopNormal
<PopNormal
:visible
.
sync=
"visible"
type=
"renew"
confirmText=
"续费会员"
cancelText=
"取消"
/>
:visible
.
sync=
"visible"
type=
"renew"
confirmText=
"续费会员"
cancelText=
"取消"
/>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
BillingDetails
from
'@/components/billing-daily/billing-daily.vue'
;
import
BillingDetails
from
'@/components/billing-daily/billing-daily.vue'
;
import
{
minPopupOptions
}
from
'@/utils/options/index/index.js'
;
import
{
minPopupOptions
}
from
'@/utils/options/index/index.js'
;
import
{
checkLoginAndVip
}
from
'@/utils/common.js'
;
import
{
checkLoginAndVip
}
from
'@/utils/common.js'
;
import
PopNormal
from
'@/components/pop-normal'
import
{
indexBaseUrl
}
from
'@/utils/config.js'
;
import
PopNormal
from
'@/components/pop-normal'
;
export
default
{
export
default
{
name
:
'mid-popup'
,
name
:
'mid-popup'
,
...
@@ -37,6 +33,7 @@ export default {
...
@@ -37,6 +33,7 @@ export default {
},
},
data
()
{
data
()
{
return
{
return
{
indexBaseUrl
,
show
:
false
,
show
:
false
,
type
:
''
,
type
:
''
,
list
:
minPopupOptions
,
list
:
minPopupOptions
,
...
@@ -50,20 +47,20 @@ export default {
...
@@ -50,20 +47,20 @@ export default {
close
()
{
close
()
{
this
.
show
=
false
;
this
.
show
=
false
;
},
},
clickItem
(
item
){
clickItem
(
item
)
{
checkLoginAndVip
(
(
res
)
=>
{
checkLoginAndVip
(
res
=>
{
if
(
res
)
{
if
(
res
)
{
this
.
visible
=
true
this
.
visible
=
true
;
}
else
{
}
else
{
this
.
openBill
(
item
)
this
.
openBill
(
item
)
;
}
}
})
})
;
},
},
openBill
(
item
)
{
openBill
(
item
)
{
this
.
type
=
item
.
type
;
this
.
type
=
item
.
type
;
this
.
close
();
this
.
close
();
if
(
this
.
type
===
'3'
)
{
if
(
this
.
type
===
'3'
)
{
this
.
openBillingDaily
()
this
.
openBillingDaily
()
;
}
else
{
}
else
{
if
(
item
.
path
)
{
if
(
item
.
path
)
{
uni
.
navigateTo
({
uni
.
navigateTo
({
...
@@ -72,11 +69,11 @@ export default {
...
@@ -72,11 +69,11 @@ export default {
}
}
}
}
},
},
openBillingDaily
(){
openBillingDaily
()
{
this
.
$refs
[
'billing-daily'
].
open
();
this
.
$refs
[
'billing-daily'
].
open
();
},
},
afterSave
(){
afterSave
()
{
this
.
$emit
(
"afterSave"
)
this
.
$emit
(
'afterSave'
);
}
}
}
}
};
};
...
@@ -100,7 +97,7 @@ export default {
...
@@ -100,7 +97,7 @@ export default {
&
-icon
{
&
-icon
{
width
:
144upx
;
width
:
144upx
;
height
:
144upx
;
height
:
144upx
;
display
:
flex
;
//
display: flex;
}
}
&
-content
{
&
-content
{
margin-top
:
32upx
;
margin-top
:
32upx
;
...
...
main.js
View file @
8836f8d5
...
@@ -5,9 +5,11 @@ import '.env.js'
...
@@ -5,9 +5,11 @@ import '.env.js'
// #ifndef VUE3
// #ifndef VUE3
import
Vue
from
'vue'
import
Vue
from
'vue'
Vue
.
config
.
productionTip
=
false
Vue
.
config
.
productionTip
=
false
//// #ifndef APP-PLUS
import
{
router
,
RouterMount
}
from
'./router'
//路径换成自己的
import
{
router
,
RouterMount
}
from
'./router'
//路径换成自己的
Vue
.
use
(
router
)
Vue
.
use
(
router
)
//// #endif
import
uView
from
"uview-ui"
;
import
uView
from
"uview-ui"
;
Vue
.
use
(
uView
);
Vue
.
use
(
uView
);
...
...
manifest.json
View file @
8836f8d5
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
"name"
:
"account-book"
,
"name"
:
"account-book"
,
"appid"
:
"__UNI__C731E8B"
,
"appid"
:
"__UNI__C731E8B"
,
"description"
:
""
,
"description"
:
""
,
"versionName"
:
"1.0.
0
"
,
"versionName"
:
"1.0.
1
"
,
"versionCode"
:
"100"
,
"versionCode"
:
101
,
"transformPx"
:
false
,
"transformPx"
:
false
,
/*
5
+App特有相关
*/
/*
5
+App特有相关
*/
"app-plus"
:
{
"app-plus"
:
{
...
@@ -19,37 +19,92 @@
...
@@ -19,37 +19,92 @@
/*
模块配置
*/
/*
模块配置
*/
"modules"
:
{
"modules"
:
{
"OAuth"
:
{},
"OAuth"
:
{},
"Payment"
:
{}
"Payment"
:
{},
"Share"
:
{}
},
},
/*
应用发布信息
*/
/*
应用发布信息
*/
"distribute"
:
{
"distribute"
:
{
/*
android打包配置
*/
/*
android打包配置
*/
"android"
:
{
"android"
:
{
"permissions"
:
[
"permissions"
:
[
"<uses-permission android:name=
\"
android.permission.CHANGE_NETWORK_STATE
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MOUNT_UNMOUNT_FILESYSTEMS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.VIBRATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_LOGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_WIFI_STATE
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera.autofocus
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera.autofocus
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.ACCESS_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CAMERA
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CAMERA
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_NETWORK_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.CHANGE_WIFI_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.FLASHLIGHT
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.GET_ACCOUNTS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.GET_ACCOUNTS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MODIFY_AUDIO_SETTINGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.MOUNT_UNMOUNT_FILESYSTEMS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_LOGS
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_PHONE_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.READ_PHONE_STATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.
CHANGE_WIFI_ST
ATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.
VIBR
ATE
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WAKE_LOCK
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WAKE_LOCK
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.FLASHLIGHT
\"
/>"
,
"<uses-feature android:name=
\"
android.hardware.camera
\"
/>"
,
"<uses-permission android:name=
\"
android.permission.WRITE_SETTINGS
\"
/>"
"<uses-permission android:name=
\"
android.permission.WRITE_SETTINGS
\"
/>"
]
],
"abiFilters"
:
[
"armeabi-v7a"
,
"arm64-v8a"
,
"x86"
],
"autoSdkPermissions"
:
false
},
},
/*
ios打包配置
*/
/*
ios打包配置
*/
"ios"
:
{},
"ios"
:
{
"dSYMs"
:
false
},
/*
SDK配置
*/
/*
SDK配置
*/
"sdkConfigs"
:
{
"sdkConfigs"
:
{
"ad"
:
{},
"ad"
:
{},
"oauth"
:
{},
"oauth"
:
{
"payment"
:
{}
"weixin"
:
{
"appid"
:
"wxe12043817d088b68"
,
"UniversalLinks"
:
""
}
},
"payment"
:
{
"weixin"
:
{
"__platform__"
:
[
"ios"
,
"android"
],
"appid"
:
"wxe12043817d088b68"
,
"UniversalLinks"
:
""
}
},
"share"
:
{
"weixin"
:
{
"appid"
:
"wxe12043817d088b68"
,
"UniversalLinks"
:
""
}
}
},
"icons"
:
{
"android"
:
{
"hdpi"
:
"unpackage/res/icons/72x72.png"
,
"xhdpi"
:
"unpackage/res/icons/96x96.png"
,
"xxhdpi"
:
"unpackage/res/icons/144x144.png"
,
"xxxhdpi"
:
"unpackage/res/icons/192x192.png"
},
"ios"
:
{
"appstore"
:
"unpackage/res/icons/1024x1024.png"
,
"ipad"
:
{
"app"
:
"unpackage/res/icons/76x76.png"
,
"app@2x"
:
"unpackage/res/icons/152x152.png"
,
"notification"
:
"unpackage/res/icons/20x20.png"
,
"notification@2x"
:
"unpackage/res/icons/40x40.png"
,
"proapp@2x"
:
"unpackage/res/icons/167x167.png"
,
"settings"
:
"unpackage/res/icons/29x29.png"
,
"settings@2x"
:
"unpackage/res/icons/58x58.png"
,
"spotlight"
:
"unpackage/res/icons/40x40.png"
,
"spotlight@2x"
:
"unpackage/res/icons/80x80.png"
},
"iphone"
:
{
"app@2x"
:
"unpackage/res/icons/120x120.png"
,
"app@3x"
:
"unpackage/res/icons/180x180.png"
,
"notification@2x"
:
"unpackage/res/icons/40x40.png"
,
"notification@3x"
:
"unpackage/res/icons/60x60.png"
,
"settings@2x"
:
"unpackage/res/icons/58x58.png"
,
"settings@3x"
:
"unpackage/res/icons/87x87.png"
,
"spotlight@2x"
:
"unpackage/res/icons/80x80.png"
,
"spotlight@3x"
:
"unpackage/res/icons/120x120.png"
}
}
}
}
}
}
},
},
...
...
pages/index/index.vue
View file @
8836f8d5
...
@@ -116,7 +116,7 @@ import MidPopup from '@/components/mid-popup/mid-popup.vue';
...
@@ -116,7 +116,7 @@ import MidPopup from '@/components/mid-popup/mid-popup.vue';
import
BillList
from
'@/components/bill-list'
;
import
BillList
from
'@/components/bill-list'
;
import
PopNormal
from
'@/components/pop-normal'
;
import
PopNormal
from
'@/components/pop-normal'
;
import
{
tabbar
}
from
'@/utils/settings.js'
;
import
{
tabbar
}
from
'@/utils/settings.js'
;
import
{
indexBaseUrl
,
baseUrl
}
from
'@/utils/config.js'
;
import
{
indexBaseUrl
,
mineBaseUrl
,
baseUrl
}
from
'@/utils/config.js'
;
import
{
getWeather
,
bookRecord
,
monthRecord
}
from
'@/api/maintain/index.js'
;
import
{
getWeather
,
bookRecord
,
monthRecord
}
from
'@/api/maintain/index.js'
;
import
{
checkVip
,
checkToken
,
getSetting
,
formatCount
}
from
'@/utils/common.js'
;
import
{
checkVip
,
checkToken
,
getSetting
,
formatCount
}
from
'@/utils/common.js'
;
import
{
mapGetters
}
from
'vuex'
;
import
{
mapGetters
}
from
'vuex'
;
...
@@ -155,7 +155,7 @@ export default {
...
@@ -155,7 +155,7 @@ export default {
};
};
},
},
computed
:
{
computed
:
{
...
mapGetters
([
'userInfo'
,
'eyeClose'
]),
...
mapGetters
([
'userInfo'
,
'eyeClose'
,
'platform'
]),
baseUrl
()
{
baseUrl
()
{
return
process
.
uniEnv
.
qn_base_url
;
return
process
.
uniEnv
.
qn_base_url
;
},
},
...
@@ -278,7 +278,11 @@ export default {
...
@@ -278,7 +278,11 @@ export default {
}
}
this
.
shareSuccessTip
();
this
.
shareSuccessTip
();
},
},
onReady
()
{},
onReady
()
{
console
.
log
(
this
.
eyeFillImage
)
console
.
log
(
baseUrl
,
indexBaseUrl
,
mineBaseUrl
)
},
onUnload
()
{
onUnload
()
{
uni
.
$off
(
'bill-list-reload'
);
uni
.
$off
(
'bill-list-reload'
);
},
},
...
@@ -311,22 +315,24 @@ export default {
...
@@ -311,22 +315,24 @@ export default {
}
}
},
},
getWeather
()
{
getWeather
()
{
getSetting
(
'scope.userLocation'
,
'检测到您没打开获取位置权限,该信息将用于小程序获取所在城市和天气状况,是否去设置打开?'
,
res
=>
{
if
(
this
.
platform
!==
'4'
){
uni
.
getLocation
({
getSetting
(
'scope.userLocation'
,
'检测到您没打开获取位置权限,该信息将用于小程序获取所在城市和天气状况,是否去设置打开?'
,
res
=>
{
type
:
'wgs84'
,
uni
.
getLocation
({
success
:
res
=>
{
type
:
'wgs84'
,
console
.
log
(
res
);
success
:
res
=>
{
getWeather
({
console
.
log
(
res
);
latitude
:
res
.
latitude
,
getWeather
({
longitude
:
res
.
longitude
latitude
:
res
.
latitude
,
}).
then
(
res
=>
{
longitude
:
res
.
longitude
if
(
res
.
data
)
{
}).
then
(
res
=>
{
this
.
weather
=
res
.
data
;
if
(
res
.
data
)
{
}
this
.
weather
=
res
.
data
;
});
}
}
});
}
});
});
});
}
);
}
},
},
beforeSwitch
(
index
)
{
beforeSwitch
(
index
)
{
if
(
index
===
2
)
{
if
(
index
===
2
)
{
...
...
pages/login/binding-phone/binding-phone.vue
View file @
8836f8d5
...
@@ -16,16 +16,14 @@
...
@@ -16,16 +16,14 @@
<text
:class=
"
{ active: canGetCode }" @tap="$u.throttle(handleClick, 500)">
{{
tips
}}
</text>
<text
:class=
"
{ active: canGetCode }" @tap="$u.throttle(handleClick, 500)">
{{
tips
}}
</text>
</view>
</view>
</view>
</view>
<view
class=
"bottom-vew"
>
<view
class=
"bottom-vew"
hover-class=
"u-hover-class"
>
<u-button
:disabled=
"disabled"
type=
"primary"
:customStyle=
"buttonStyle"
:loading=
"loading"
@
click=
"handleClickSave"
>
<u-button
:disabled=
"disabled"
:customStyle=
"buttonStyle"
:loading=
"loading"
@
click=
"handleClickSave"
><view
class=
"button-text"
>
立即绑定
</view></u-button>
<view
class=
"button-text"
>
立即绑定
</view>
</u-button>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
sendCode
}
from
"@/api/login/index.js"
import
{
sendCode
}
from
'@/api/login/index.js'
;
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
...
@@ -40,11 +38,11 @@ export default {
...
@@ -40,11 +38,11 @@ export default {
weixinAuthService
:
null
,
weixinAuthService
:
null
,
params
:
{},
params
:
{},
tips
:
''
,
tips
:
''
,
buttonStyle
:{
buttonStyle
:
{
height
:
'104rpx'
,
height
:
'104rpx'
,
backgroundColor
:
'#
3383FE
'
,
backgroundColor
:
'#
02A074
'
,
color
:
'transparent'
color
:
'transparent'
}
,
}
};
};
},
},
computed
:
{
computed
:
{
...
@@ -57,10 +55,10 @@ export default {
...
@@ -57,10 +55,10 @@ export default {
},
},
onLoad
(
options
)
{
onLoad
(
options
)
{
console
.
log
(
'-----options----'
,
options
);
console
.
log
(
'-----options----'
,
options
);
if
(
options
)
{
if
(
options
)
{
let
{
union
i
d
}
=
options
;
let
{
union
I
d
}
=
options
;
if
(
union
i
d
)
{
if
(
union
I
d
)
{
this
.
params
=
options
;
this
.
params
=
options
;
}
}
}
}
...
@@ -114,12 +112,12 @@ export default {
...
@@ -114,12 +112,12 @@ export default {
}
}
},
},
async
getCode
()
{
async
getCode
()
{
try
{
try
{
let
res
=
await
sendCode
({
moblie
:
this
.
phone
})
let
res
=
await
sendCode
({
mobile
:
this
.
phone
});
if
(
uni
.
$u
.
platform
!==
'3'
)
{
if
(
uni
.
$u
.
platform
!==
'3'
)
{
uni
.
hideLoading
();
uni
.
hideLoading
();
}
}
if
(
res
.
status
&&
res
.
data
)
{
if
(
res
.
data
)
{
this
.
$u
.
toast
(
'验证码已发送'
);
this
.
$u
.
toast
(
'验证码已发送'
);
this
.
$refs
.
uCode
.
start
();
this
.
$refs
.
uCode
.
start
();
console
.
log
(
'--------发送成功----------'
);
console
.
log
(
'--------发送成功----------'
);
...
@@ -129,11 +127,18 @@ export default {
...
@@ -129,11 +127,18 @@ export default {
icon
:
'none'
icon
:
'none'
});
});
}
}
}
catch
(
e
){
}
catch
(
e
)
{
console
.
log
(
e
);
if
(
e
.
msg
)
{
uni
.
showToast
({
title
:
e
.
msg
,
icon
:
'none'
});
}
//TODO handle the exception
//TODO handle the exception
if
(
uni
.
$u
.
platform
!==
'3'
)
{
if
(
uni
.
$u
.
platform
!==
'3'
)
{
uni
.
hideLoading
();
uni
.
hideLoading
();
}
}
}
}
},
},
handleClickSave
()
{
handleClickSave
()
{
...
@@ -150,18 +155,14 @@ export default {
...
@@ -150,18 +155,14 @@ export default {
this
.
loading
=
false
;
this
.
loading
=
false
;
return
false
;
return
false
;
}
}
const
app
=
getApp
();
this
.
onAppLogin
();
let
userInfo
=
(
app
.
globalData
.
tmp
&&
app
.
globalData
.
tmp
.
wxUserInfo
)
||
{
// if (uni.$u.platform === '4') {
nickName
:
''
,
// this.onAppLogin();
avatarUrl
:
''
// } else {
};
// this.onWxLogin();
if
(
uni
.
$u
.
platform
===
'4'
)
{
// }
this
.
onAppLogin
();
}
else
{
this
.
onWxLogin
(
userInfo
);
}
},
},
async
onWxLogin
(
userInfo
)
{
async
onWxLogin
()
{
try
{
try
{
let
res
=
await
login
.
wxLogin
();
let
res
=
await
login
.
wxLogin
();
let
params
=
{
let
params
=
{
...
@@ -186,16 +187,33 @@ export default {
...
@@ -186,16 +187,33 @@ export default {
async
onAppLogin
()
{
async
onAppLogin
()
{
let
params
=
{
let
params
=
{
...
this
.
params
,
...
this
.
params
,
verify
:
this
.
code
,
password
:
this
.
code
,
mobile
:
this
.
phone
account
:
this
.
phone
,
authType
:
this
.
params
.
authType
?
this
.
params
.
authType
:
'AC'
};
};
console
.
log
(
params
);
try
{
await
this
.
$store
.
dispatch
(
'On_signup'
,
{
let
res
=
await
this
.
$store
.
dispatch
(
'Auto_login'
,
params
);
params
,
if
(
res
.
code
===
0
)
{
callback
:
()
=>
{
this
.
showToast
(
'登录成功'
,
true
);
this
.
toPhoneLogin
();
setTimeout
(()
=>
{
if
(
this
.
returnUrl
)
{
// 需要跳转到特定页面
var
isSwitchTab
=
this
.
returnUrl
.
indexOf
(
'pages/index/'
)
!=
-
1
;
this
.
$u
.
route
({
url
:
this
.
returnUrl
,
type
:
isSwitchTab
?
'switchTab'
:
'redirectTo'
});
}
else
{
uni
.
switchTab
({
url
:
'/pages/index/index'
});
}
},
1000
);
}
}
});
}
catch
(
e
)
{
console
.
log
(
'onAppLogin'
,
e
);
//TODO handle the exception
}
this
.
loading
=
false
;
this
.
loading
=
false
;
},
},
async
onSignup
(
params
)
{
async
onSignup
(
params
)
{
...
...
pages/login/login.vue
View file @
8836f8d5
...
@@ -20,7 +20,7 @@
...
@@ -20,7 +20,7 @@
<text>
{{
platform
==
'2'
||
platform
==
'3'
?
'授权登录'
:
'微信登录'
}}
</text>
<text>
{{
platform
==
'2'
||
platform
==
'3'
?
'授权登录'
:
'微信登录'
}}
</text>
</view>
</view>
</view>
</view>
<
!--
<view
class=
"cancel-button"
><text
@
click
.
stop=
"toPhoneLogin"
>
手机验证码登录
</text></view>
--
>
<
view
class=
"cancel-button"
><text
@
click
.
stop=
"toPhoneLogin"
>
手机验证码登录
</text></view
>
<!--
<view
class=
"other-login"
>
<!--
<view
class=
"other-login"
>
<u-divider>
其他登录方式
</u-divider>
<u-divider>
其他登录方式
</u-divider>
<view
class=
"other-login-item"
>
<view
class=
"other-login-item"
>
...
@@ -42,13 +42,13 @@
...
@@ -42,13 +42,13 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
baseUrl
}
from
'@/utils/config.js'
;
import
{
baseUrl
}
from
'@/utils/config.js'
;
import
{
mapGetters
}
from
'vuex'
;
import
{
mapGetters
}
from
'vuex'
;
export
default
{
export
default
{
components
:
{},
components
:
{},
data
()
{
data
()
{
return
{
return
{
logoImage
:
baseUrl
+
'login-logo@3x.png'
,
logoImage
:
baseUrl
+
'login-logo@3x.png'
,
agree
:
false
,
agree
:
false
,
statusBarHeight
:
20
,
statusBarHeight
:
20
,
loading
:
false
,
loading
:
false
,
...
@@ -65,14 +65,14 @@ export default {
...
@@ -65,14 +65,14 @@ export default {
this
.
statusBarHeight
=
statusBarHeight
;
this
.
statusBarHeight
=
statusBarHeight
;
if
(
options
&&
options
.
path
)
{
if
(
options
&&
options
.
path
)
{
this
.
returnUrl
=
decodeURIComponent
(
decodeURIComponent
(
options
.
path
))
this
.
returnUrl
=
decodeURIComponent
(
decodeURIComponent
(
options
.
path
));
}
}
},
},
onShow
()
{
onShow
()
{
if
(
this
.
loading
)
{
if
(
this
.
loading
)
{
this
.
loading
=
false
;
this
.
loading
=
false
;
}
}
uni
.
hideLoading
();
},
},
methods
:
{
methods
:
{
handleClick
(
type
)
{
handleClick
(
type
)
{
...
@@ -106,65 +106,50 @@ export default {
...
@@ -106,65 +106,50 @@ export default {
}
}
}
}
},
},
appWxLogin
()
{
a
sync
a
ppWxLogin
()
{
uni
.
showLoading
({
uni
.
showLoading
({
title
:
'授权中'
title
:
'授权中'
});
});
uni
.
getProvider
({
try
{
service
:
'oauth'
,
await
this
.
$store
.
dispatch
(
'App_get_provider'
);
success
:
async
res
=>
{
let
res
=
await
this
.
$store
.
dispatch
(
'Auto_login'
,
{});
console
.
log
(
'getProvider'
,
res
);
this
.
showToast
(
'登录成功'
,
true
);
//支持微信、qq和微博等
setTimeout
(()
=>
{
if
(
res
.
provider
.
findIndex
(
e
=>
e
===
'weixin'
)
!==
-
1
)
{
if
(
this
.
returnUrl
)
{
this
.
loading
=
true
;
// 需要跳转到特定页面
try
{
var
isSwitchTab
=
this
.
returnUrl
.
indexOf
(
'pages/index/'
)
!=
-
1
;
let
res
=
await
this
.
$store
.
dispatch
(
'Wx_login'
);
this
.
$u
.
route
({
let
params
=
{
url
:
this
.
returnUrl
,
code
:
res
.
code
,
type
:
isSwitchTab
?
'switchTab'
:
'redirectTo'
type
:
uni
.
$u
.
platform
,
});
grantType
:
'1'
// APP微信登录
};
this
.
loading
=
false
;
// uni.hideLoading();
await
this
.
$store
.
dispatch
(
'On_signup'
,
{
params
,
callback
:
back
=>
{
this
.
toPhoneLogin
(
back
);
}
});
}
catch
(
e
)
{
this
.
loading
=
false
;
console
.
log
(
'Wx_login:||On_signup:'
,
e
);
uni
.
hideLoading
();
}
}
else
{
}
else
{
uni
.
hideLoading
();
uni
.
switchTab
({
uni
.
showToast
({
url
:
'/pages/index/index'
icon
:
'none'
,
title
:
'不支持微信登录'
});
});
}
}
},
},
1000
);
fail
()
{
}
catch
(
e
)
{
uni
.
hideLoading
();
let
{
code
}
=
e
;
if
(
code
===
40011
)
{
this
.
toPhoneLogin
(
e
);
}
}
});
//TODO handle the exception
}
uni
.
hideLoading
();
},
},
toPhoneLogin
(
res
)
{
toPhoneLogin
(
res
)
{
if
(
!
this
.
checkAgree
())
{
if
(
!
this
.
checkAgree
())
{
return
;
return
;
}
}
console
.
log
(
'toPhoneLogin'
);
console
.
log
(
'toPhoneLogin'
,
res
);
let
{
open
id
,
unionid
,
session_key
,
nickname
,
avatar
}
=
res
;
let
{
open
Id
,
unionId
,
loginChannel
,
authType
}
=
res
.
data
;
let
params
=
{};
let
params
=
{};
if
(
union
i
d
)
{
if
(
union
I
d
)
{
params
=
{
params
=
{
openid
,
openId
,
unionid
,
unionId
,
session_key
,
loginChannel
:
loginChannel
.
code
,
nickname
,
authType
:
authType
.
code
avatar
,
grantType
:
'1'
// APP微信登录
};
};
}
}
this
.
$u
.
route
({
url
:
'pages/login/binding-phone/binding-phone'
,
params
});
this
.
$u
.
route
({
url
:
'pages/login/binding-phone/binding-phone'
,
params
});
...
@@ -179,7 +164,7 @@ export default {
...
@@ -179,7 +164,7 @@ export default {
return
false
;
return
false
;
}
}
return
true
;
return
true
;
}
,
}
}
}
};
};
</
script
>
</
script
>
...
@@ -193,7 +178,7 @@ export default {
...
@@ -193,7 +178,7 @@ export default {
&
-color
{
&
-color
{
width
:
100%
;
width
:
100%
;
height
:
30%
;
height
:
30%
;
background
:
linear-gradient
(
180deg
,
#
F4FFFC
0%
,
#ffffff
100%
);
background
:
linear-gradient
(
180deg
,
#
f4fffc
0%
,
#ffffff
100%
);
overflow
:
hidden
;
overflow
:
hidden
;
&
-cancel
{
&
-cancel
{
width
:
60upx
;
width
:
60upx
;
...
...
pages/login/quick-login/quick-login.vue
View file @
8836f8d5
...
@@ -272,7 +272,7 @@ export default {
...
@@ -272,7 +272,7 @@ export default {
this
.
$store
this
.
$store
.
dispatch
(
'Get_UserInfo'
)
.
dispatch
(
'Get_UserInfo'
)
.
then
(()
=>
{
.
then
(()
=>
{
showToast
(
'登录成功'
);
this
.
showToast
(
'登录成功'
,
true
);
setTimeout
(()
=>
{
setTimeout
(()
=>
{
if
(
this
.
returnUrl
)
{
// 需要跳转到特定页面
if
(
this
.
returnUrl
)
{
// 需要跳转到特定页面
var
isSwitchTab
=
this
.
returnUrl
.
indexOf
(
'pages/index/'
)
!=
-
1
var
isSwitchTab
=
this
.
returnUrl
.
indexOf
(
'pages/index/'
)
!=
-
1
...
...
pages/mine/pay/pay.vue
View file @
8836f8d5
...
@@ -88,7 +88,7 @@
...
@@ -88,7 +88,7 @@
</view>
</view>
</view>
</view>
<view
v-if=
"!hidePay"
class=
"bottom-view"
><button
class=
"buy-button"
@
tap=
"$u.throttle(handleClickBuy, 500)"
>
立即购买
</button></view>
<view
v-if=
"!hidePay"
class=
"bottom-view"
><button
class=
"buy-button"
@
tap=
"$u.throttle(handleClickBuy, 500)"
>
立即购买
</button></view>
<
!--
<BottomPay
:visible
.
sync=
"showPayBottom"
@
click=
"$u.throttle(getPaymentInfo, 500)"
/>
--
>
<
BottomPay
:visible
.
sync=
"showPayBottom"
@
click=
"$u.throttle(getPaymentInfo, 500)"
/
>
</view>
</view>
</
template
>
</
template
>
...
@@ -197,12 +197,10 @@ export default {
...
@@ -197,12 +197,10 @@ export default {
item
.
text
=
parseInt
((
Number
(
item
.
price
)
/
moths
[
index
])
*
10
)
/
10
+
'元/月'
;
item
.
text
=
parseInt
((
Number
(
item
.
price
)
/
moths
[
index
])
*
10
)
/
10
+
'元/月'
;
item
.
price
=
parseInt
(
Number
(
item
.
price
)
*
10
)
/
10
;
item
.
price
=
parseInt
(
Number
(
item
.
price
)
*
10
)
/
10
;
});
});
for
(
var
i
=
0
;
i
<
data
.
length
;
i
++
)
{
if
(
i
>
0
)
{
}
}
this
.
priceList
=
data
;
this
.
priceList
=
data
;
}
catch
(
e
)
{
}
catch
(
e
)
{
console
.
log
(
e
)
//TODO handle the exception
//TODO handle the exception
}
}
},
},
...
@@ -243,6 +241,7 @@ export default {
...
@@ -243,6 +241,7 @@ export default {
uni
.
showLoading
({
uni
.
showLoading
({
title
:
'支付中'
title
:
'支付中'
});
});
console
.
log
(
"charge=========="
,
charge
)
uni
.
requestPayment
({
uni
.
requestPayment
({
// #ifdef MP-WEIXIN
// #ifdef MP-WEIXIN
timeStamp
:
''
+
charge
.
timeStamp
,
timeStamp
:
''
+
charge
.
timeStamp
,
...
@@ -256,12 +255,12 @@ export default {
...
@@ -256,12 +255,12 @@ export default {
// #ifdef MP-TOUTIAO
// #ifdef MP-TOUTIAO
service
:
5
,
service
:
5
,
// _debug: 1,
// _debug: 1,
orderInfo
:
charge
,
orderInfo
:
charge
.
orderInfo
,
// #endif
// #endif
// #ifdef APP-PLUS
// #ifdef APP-PLUS
provider
:
this
.
isIOS
?
'appleiap'
:
'wxpay'
,
provider
:
this
.
isIOS
?
'appleiap'
:
'wxpay'
,
manualFinishTransaction
:
this
.
isIOS
?
true
:
false
,
manualFinishTransaction
:
this
.
isIOS
?
true
:
false
,
orderInfo
:
charge
,
orderInfo
:
charge
.
orderInfo
,
// #endif
// #endif
success
:
res
=>
{
success
:
res
=>
{
...
@@ -453,6 +452,7 @@ export default {
...
@@ -453,6 +452,7 @@ export default {
try
{
try
{
//拉取新用户信息,更新到storage
//拉取新用户信息,更新到storage
let
res
=
await
this
.
$store
.
dispatch
(
'Get_UserInfo'
);
let
res
=
await
this
.
$store
.
dispatch
(
'Get_UserInfo'
);
this
.
showToast
(
"支付成功"
,
true
)
setTimeout
(()
=>
{
setTimeout
(()
=>
{
uni
.
navigateBack
({
uni
.
navigateBack
({
delta
:
1
delta
:
1
...
...
static/image/mine/weixinzhifu@3x.png
0 → 100644
View file @
8836f8d5
1.49 KB
store/modules/login.js
View file @
8836f8d5
...
@@ -19,6 +19,7 @@ import {
...
@@ -19,6 +19,7 @@ import {
}
from
"@/utils/config.js"
}
from
"@/utils/config.js"
import
{
import
{
userAuthLogin
,
userAuthLogin
,
mobileLogin
}
from
"@/api/login/index.js"
;
}
from
"@/api/login/index.js"
;
import
{
import
{
getUserInfo
,
getUserInfo
,
...
@@ -111,15 +112,12 @@ const actions = {
...
@@ -111,15 +112,12 @@ const actions = {
},
data
)
{
},
data
)
{
commit
(
"SET_AUTO_LOGIN"
,
data
)
commit
(
"SET_AUTO_LOGIN"
,
data
)
},
},
App_
WX_login
({
App_
get_provider
({
state
,
state
,
commit
,
commit
,
dispatch
dispatch
})
{
})
{
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
uni
.
showLoading
({
title
:
'授权中'
});
uni
.
getProvider
({
uni
.
getProvider
({
service
:
'oauth'
,
service
:
'oauth'
,
success
:
res
=>
{
success
:
res
=>
{
...
@@ -166,7 +164,10 @@ const actions = {
...
@@ -166,7 +164,10 @@ const actions = {
break
;
break
;
}
}
try
{
try
{
let
code
=
await
wxLogin
()
let
code
=
""
if
(
!
params
.
account
){
code
=
await
wxLogin
()
}
let
info
=
{
let
info
=
{
...
loginInfo
,
...
loginInfo
,
authType
:
authType
,
authType
:
authType
,
...
@@ -180,6 +181,7 @@ const actions = {
...
@@ -180,6 +181,7 @@ const actions = {
...
params
,
...
params
,
}
}
}
}
console
.
log
(
"info"
,
info
)
let
res
=
await
userAuthLogin
(
info
)
let
res
=
await
userAuthLogin
(
info
)
commit
(
"SET_CHANNEL"
,
{
commit
(
"SET_CHANNEL"
,
{
loginChannel
:
info
.
loginChannel
,
loginChannel
:
info
.
loginChannel
,
...
...
utils/config.js
View file @
8836f8d5
...
@@ -10,6 +10,7 @@ export const temperature = 'TEMPERATURE';
...
@@ -10,6 +10,7 @@ export const temperature = 'TEMPERATURE';
export
const
appid
=
"wx55e75ad85611191f"
export
const
appid
=
"wx55e75ad85611191f"
// export const API_HOST = ''; // 正式服
// export const API_HOST = ''; // 正式服
export
const
API_HOST
=
''
;
// 测试服
export
const
API_HOST
=
''
;
// 测试服
export
const
baseUrl
=
process
.
uniEnv
.
qn_base_url
;
// 七牛云对象存储图片地址
export
const
baseUrl
=
process
.
uniEnv
.
qn_base_url
;
// 七牛云对象存储图片地址
export
const
indexBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'index/'
;
// 七牛云对象存储图片地址-首页
export
const
indexBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'index/'
;
// 七牛云对象存储图片地址-首页
export
const
mineBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'mine/'
;
// 七牛云对象存储图片地址-我的
export
const
mineBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'mine/'
;
// 七牛云对象存储图片地址-我的
...
@@ -17,6 +18,7 @@ export const billBaseUrl = process.uniEnv.qn_base_url + 'bill/'; // 七牛云对
...
@@ -17,6 +18,7 @@ export const billBaseUrl = process.uniEnv.qn_base_url + 'bill/'; // 七牛云对
export
const
planBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'plan/'
;
// 七牛云对象存储图片地址-行程
export
const
planBaseUrl
=
process
.
uniEnv
.
qn_base_url
+
'plan/'
;
// 七牛云对象存储图片地址-行程
export
const
UPLOAD_FILE_HOST
=
process
.
uniEnv
.
qn_asset_url
;
// 服务器用户上传文件地址
export
const
UPLOAD_FILE_HOST
=
process
.
uniEnv
.
qn_asset_url
;
// 服务器用户上传文件地址
export
const
billStaticBaseUrl
=
'/static/image/bill/'
;
// 七牛云对象存储图片地址-账单
export
const
billStaticBaseUrl
=
'/static/image/bill/'
;
// 七牛云对象存储图片地址-账单
export
const
maintain_share_url
=
'https://system.banshouhui.com/maintainqrcode'
// pages/maintain-bill/show二维码地址
export
const
maintain_share_url
=
'https://system.banshouhui.com/maintainqrcode'
// pages/maintain-bill/show二维码地址
...
...
utils/options/index/index.js
View file @
8836f8d5
...
@@ -4,19 +4,19 @@ import {
...
@@ -4,19 +4,19 @@ import {
export
const
minPopupOptions
=
[{
export
const
minPopupOptions
=
[{
label
:
'记行程'
,
label
:
'记行程'
,
path
:
'/pages/schedule/create-schedule/create-schedule'
,
path
:
'/pages/schedule/create-schedule/create-schedule'
,
icon
:
indexBaseUrl
+
'jixingcheng@3x.png'
,
icon
:
'jixingcheng@3x.png'
,
type
:
'1'
,
type
:
'1'
,
},
},
{
{
label
:
'维修帐'
,
label
:
'维修帐'
,
path
:
'/pages/maintain-bill/create'
,
path
:
'/pages/maintain-bill/create'
,
icon
:
indexBaseUrl
+
'weixiuzhangfapiao@3x.png'
,
icon
:
'weixiuzhangfapiao@3x.png'
,
type
:
'2'
,
type
:
'2'
,
},
},
{
{
label
:
'日常帐'
,
label
:
'日常帐'
,
path
:
''
,
path
:
''
,
icon
:
indexBaseUrl
+
'richangzhang@3x.png'
,
icon
:
'richangzhang@3x.png'
,
type
:
'3'
,
type
:
'3'
,
}
}
]
]
...
...
utils/platform.js
View file @
8836f8d5
...
@@ -37,6 +37,7 @@ platform = 'h5'
...
@@ -37,6 +37,7 @@ platform = 'h5'
// #ifdef MP-WEIXIN
// #ifdef MP-WEIXIN
platform
=
'1'
platform
=
'1'
channel
=
'WX'
channel
=
'WX'
// channel = isIOS ? 'IOS' : 'ANDROID'
// #endif
// #endif
// #ifdef MP-ALIPAY
// #ifdef MP-ALIPAY
...
...
utils/request.js
View file @
8836f8d5
...
@@ -127,8 +127,8 @@ function request({
...
@@ -127,8 +127,8 @@ function request({
requestUrl
=
apiUrl
+
url
requestUrl
=
apiUrl
+
url
// #endif
// #endif
console
.
log
(
"requestUrl="
+
requestUrl
)
console
.
log
(
"requestUrl="
+
requestUrl
)
//
console.log("请求参数===")
console
.
log
(
"请求参数==="
)
//
console.log(data)
console
.
log
(
data
)
// header["Authorization"] ='Basic '+ token
// header["Authorization"] ='Basic '+ token
header
[
"token"
]
=
'Bearer '
+
token
header
[
"token"
]
=
'Bearer '
+
token
if
(
!
noLoading
)
{
if
(
!
noLoading
)
{
...
@@ -158,6 +158,7 @@ function request({
...
@@ -158,6 +158,7 @@ function request({
header
,
header
,
responseType
,
responseType
,
success
:
res
=>
{
success
:
res
=>
{
console
.
log
(
res
)
if
(
res
.
data
.
code
===
0
)
{
if
(
res
.
data
.
code
===
0
)
{
if
(
!
noLoading
)
{
if
(
!
noLoading
)
{
uni
.
hideLoading
()
uni
.
hideLoading
()
...
...
vue.config.js
View file @
8836f8d5
...
@@ -14,4 +14,4 @@ module.exports = {
...
@@ -14,4 +14,4 @@ module.exports = {
})
})
]
]
}
}
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment