Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
Compass
Overview
Overview
Details
Activity
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
zong
Compass
Commits
46cce7e6
Commit
46cce7e6
authored
Mar 14, 2020
by
shijiuyan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
94ec58eb
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
97 additions
and
21 deletions
+97
-21
ageChange.js
src/wx/pages/ageChange/ageChange.js
+6
-0
classDetails.wxml
src/wx/pages/classDetails/classDetails.wxml
+1
-1
classDetails.wxss
src/wx/pages/classDetails/classDetails.wxss
+1
-1
index.js
src/wx/pages/index/index.js
+18
-5
leaderRegister.js
src/wx/pages/leaderRegister/leaderRegister.js
+12
-2
memberChange.js
src/wx/pages/memberChange/memberChange.js
+25
-2
memberChange.wxml
src/wx/pages/memberChange/memberChange.wxml
+1
-0
register.js
src/wx/pages/register/register.js
+20
-7
socialUserRegister.js
src/wx/pages/socialUserRegister/socialUserRegister.js
+13
-3
No files found.
src/wx/pages/ageChange/ageChange.js
View file @
46cce7e6
...
...
@@ -63,10 +63,16 @@ Page({
icon
:
'success'
,
duration
:
2000
});
if
(
res
.
data
.
status
==
'OK'
&&
res
.
data
.
result
.
recommend
)
{
wx
.
redirectTo
({
url
:
'/pages/memberChange/memberChange'
,
})
}
else
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
},
fail
:
function
(
res
)
{
...
...
src/wx/pages/classDetails/classDetails.wxml
View file @
46cce7e6
...
...
@@ -35,7 +35,7 @@
<view class='fufeilook' wx:if="{{fufeiPage==1}}">
<view class='con_fufeilook'>
<view class='top_con_fufeilook'>付费观看</view>
<view>
<view
style="margin-top:50px;margin-left:33%;"
>
金额:<text>{{money}}</text>
</view>
<view class='fufeiBtn'>
...
...
src/wx/pages/classDetails/classDetails.wxss
View file @
46cce7e6
...
...
@@ -141,7 +141,7 @@ page{
.top_con_fufeilook{
width: 100%;
text-align: center;
font-size: 1
4
px;
font-size: 1
6
px;
}
.fufeiBtn{
position: absolute;
...
...
src/wx/pages/index/index.js
View file @
46cce7e6
...
...
@@ -32,11 +32,24 @@ Page({
var
location
=
wx
.
getStorageSync
(
'location'
);
var
latitude
=
location
.
latitude
;
var
longitude
=
location
.
longitude
;
if
(
config
.
unionId
!==
undefined
){
that
.
getUserRole
(
config
.
unionId
,
latitude
,
longitude
);
}
else
{
setTimeout
(
function
(){
config
=
wx
.
getStorageSync
(
'config'
);
that
.
getUserRole
(
config
.
unionId
,
latitude
,
longitude
);
},
1000
);
}
},
getUserRole
(
unionId
,
latitude
,
longitude
){
var
that
=
this
;
var
location
=
wx
.
getStorageSync
(
'location'
);
var
config
=
wx
.
getStorageSync
(
'config'
);
wx
.
request
({
url
:
app
.
url
+
'ajax_get_user_role.php'
,
data
:
{
unionId
:
config
.
unionId
,
unionId
:
unionId
,
latitude
:
latitude
,
longitude
:
longitude
},
...
...
@@ -45,7 +58,7 @@ Page({
dataType
:
'json'
,
success
:
function
(
res
)
{
console
.
log
(
res
)
if
(
res
.
statusCode
==
200
)
{
if
(
res
.
statusCode
==
200
)
{
//保存用户当前的省市区县信息
location
.
province
=
res
.
data
.
result
.
province
location
.
city
=
res
.
data
.
result
.
city
...
...
@@ -62,7 +75,7 @@ Page({
})
//未注册用户的话。跳转到社会人士注册页面
if
(
res
.
data
.
status
==
"REGIST"
)
{
if
(
res
.
data
.
status
==
"REGIST"
)
{
//页面跳转
wx
.
redirectTo
({
url
:
'../socialUserRegister/socialUserRegister'
,
...
...
@@ -70,11 +83,11 @@ Page({
}
that
.
setData
({
roleTitle
:
res
.
data
.
result
.
name
,
role
:
res
.
data
.
result
.
role
,
role
:
res
.
data
.
result
.
role
,
childAge
:
res
.
data
.
result
.
childAge
})
//菜单控制[亲子活动]
if
(
res
.
data
.
result
.
role
==
1
||
res
.
data
.
result
.
childAge
==
1
)
{
if
(
res
.
data
.
result
.
role
==
1
||
res
.
data
.
result
.
childAge
==
1
)
{
that
.
setData
({
showFamily
:
true
})
...
...
src/wx/pages/leaderRegister/leaderRegister.js
View file @
46cce7e6
...
...
@@ -46,14 +46,24 @@ Page({
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{
//如果用户已经注册则跳转到首页
var
config
=
wx
.
getStorageSync
(
'config'
);
if
(
config
.
registed
==
true
)
{
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
else
{
setTimeout
(
function
()
{
config
=
wx
.
getStorageSync
(
'config'
);
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
},
1000
);
}
},
/**
...
...
src/wx/pages/memberChange/memberChange.js
View file @
46cce7e6
// pages/memberChange/memberChange.js
import
Toast
from
'../../dist/toast/toast'
;
const
app
=
getApp
();
Page
({
...
...
@@ -24,7 +25,7 @@ Page({
},
})
// wx.request({
// url: '',
// url: '',
resp.data.result.unionId
// })
},
getInfo
(
unionId
){
...
...
@@ -104,6 +105,25 @@ Page({
},
success
:
function
(
resp
){
console
.
log
(
resp
)
if
(
resp
.
data
.
status
==
'OK'
){
var
result
=
JSON
.
parse
(
resp
.
data
.
result
);
wx
.
requestPayment
({
timeStamp
:
result
.
timeStamp
,
nonceStr
:
result
.
nonceStr
,
package
:
result
.
package
,
signType
:
'MD5'
,
paySign
:
result
.
paySign
,
success
(
res
)
{
Toast
.
success
(
'支付成功'
);
wx
.
redirectTo
({
url
:
'/pages/index/index'
,
})
},
fail
(
res
)
{
Toast
.
fail
(
'支付失败'
);
}
})
}
}
})
}
...
...
@@ -112,6 +132,8 @@ Page({
},
cancel
(){
console
.
log
(
1111
)
wx
.
navigateBack
({});
wx
.
redirectTo
({
url
:
'/pages/index/index'
,
})
}
})
\ No newline at end of file
src/wx/pages/memberChange/memberChange.wxml
View file @
46cce7e6
...
...
@@ -14,3 +14,4 @@
</view>
</view>
</view>
<van-toast id="van-toast" />
src/wx/pages/register/register.js
View file @
46cce7e6
...
...
@@ -30,21 +30,29 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow
:
function
()
{
},
onReady
:
function
()
{
// 生命周期函数--监听页面初次渲染完成
//如果用户已经注册则跳转到首页
var
config
=
wx
.
getStorageSync
(
'config'
);
setTimeout
(
function
(){
if
(
config
.
registed
==
true
)
{
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
else
{
setTimeout
(
function
()
{
config
=
wx
.
getStorageSync
(
'config'
);
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
},
1000
);
}
},
200
)
},
/**
* 用户点击右上角分享
...
...
@@ -96,11 +104,16 @@ Page({
method
:
'GET'
,
dataType
:
'json'
,
success
:
function
(
res
)
{
if
(
res
.
data
.
status
==
'OK'
&&
res
.
data
.
result
.
recommend
){
wx
.
redirectTo
({
url
:
'/pages/memberChange/memberChange'
,
})
}
else
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
},
fail
:
function
(
res
)
{
wx
.
showToast
({
...
...
src/wx/pages/socialUserRegister/socialUserRegister.js
View file @
46cce7e6
...
...
@@ -41,14 +41,24 @@ Page({
* 生命周期函数--监听页面初次渲染完成
*/
onReady
:
function
()
{
//如果用户已经注册则跳转到首页
var
config
=
wx
.
getStorageSync
(
'config'
);
if
(
config
.
registed
==
true
)
{
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
else
{
setTimeout
(
function
()
{
config
=
wx
.
getStorageSync
(
'config'
);
if
(
config
.
registed
==
true
&&
config
.
unionId
!==
undefined
)
{
//跳转到首页
wx
.
switchTab
({
url
:
'../index/index'
,
});
}
},
1000
);
}
//获取机构注册说明文本
var
x
=
this
;
...
...
@@ -360,7 +370,7 @@ Page({
//机构注册上传各种证明
upload
(){
var
recommend
=
true
;
var
config
=
wx
.
getStorageSync
(
'config'
);
var
that
=
this
;
//循环上传图片
...
...
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