Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-app-customer-new-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
lanbaoming
jiedao-app-customer-new-master
Commits
e68a29bc
Commit
e68a29bc
authored
Aug 12, 2024
by
lizhan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
📝
【TASK-20240812-01】TASK:登录跳转判断
parent
e6bdbe88
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
742 additions
and
584 deletions
+742
-584
index.vue
src/components/dHeader/index.vue
+10
-1
login.vue
src/pages/login/login.vue
+441
-357
my_info.vue
src/pages/my_info/my_info.vue
+42
-14
register.vue
src/pages/register/register.vue
+249
-212
No files found.
src/components/dHeader/index.vue
View file @
e68a29bc
...
@@ -3,7 +3,12 @@
...
@@ -3,7 +3,12 @@
<view
class=
"header-toper"
>
<view
class=
"header-toper"
>
<!--
<view
class=
"start-bar"
></view>
-->
<!--
<view
class=
"start-bar"
></view>
-->
<view
class=
"header-toper-title"
>
<view
class=
"header-toper-title"
>
<image
src=
"../../static/img/back.png"
mode=
""
@
click=
"$request.backGo"
></image>
<image
v-if=
"leftIcon"
src=
"../../static/img/back.png"
mode=
""
@
click=
"$request.backGo"
></image>
<text>
{{
title
}}
</text>
<text>
{{
title
}}
</text>
<image
<image
v-if=
"rightBtn"
v-if=
"rightBtn"
...
@@ -22,6 +27,10 @@ export default {
...
@@ -22,6 +27,10 @@ export default {
rightBtn
:
{
rightBtn
:
{
type
:
Boolean
,
type
:
Boolean
,
default
:
false
default
:
false
},
leftIcon
:
{
type
:
Boolean
,
default
:
true
}
}
},
},
data
()
{
data
()
{
...
...
src/pages/login/login.vue
View file @
e68a29bc
This diff is collapsed.
Click to expand it.
src/pages/my_info/my_info.vue
View file @
e68a29bc
<
template
>
<
template
>
<view>
<view>
<dHeader
:
title=
"
$lang.lang.myInfo.info"
></dHeader>
<dHeader
:
left-icon=
"!first"
:title=
"first ? '个人信息填写' :
$lang.lang.myInfo.info"
></dHeader>
<view
class=
"start-bar"
></view>
<view
class=
"start-bar"
></view>
<view
class=
"consultAdd"
>
<view
class=
"consultAdd"
>
<view
class=
"consult-item"
>
<view
class=
"consult-item"
>
...
@@ -89,7 +89,7 @@
...
@@ -89,7 +89,7 @@
@
change=
"bindCountyChange"
@
change=
"bindCountyChange"
>
>
<view
:class=
"
{ placeholder: !params.country }">
{{
<view
:class=
"
{ placeholder: !params.country }">
{{
params
.
country
?
params
.
country
:
$lang
.
lang
.
notices
.
country
params
.
country
Value
?
params
.
countryValue
:
$lang
.
lang
.
notices
.
country
}}
</view>
}}
</view>
</picker>
</picker>
<image
class=
"rgt"
src=
"../../static/img/rgt.png"
mode=
""
></image>
<image
class=
"rgt"
src=
"../../static/img/rgt.png"
mode=
""
></image>
...
@@ -107,7 +107,7 @@
...
@@ -107,7 +107,7 @@
@
change=
"bindCityChange"
@
change=
"bindCityChange"
>
>
<view
:class=
"
{ placeholder: !params.city }">
{{
<view
:class=
"
{ placeholder: !params.city }">
{{
params
.
city
?
params
.
city
:
$lang
.
lang
.
notices
.
city
params
.
city
Value
?
params
.
cityValue
:
$lang
.
lang
.
notices
.
city
}}
</view>
}}
</view>
</picker>
</picker>
<image
class=
"rgt"
src=
"../../static/img/rgt.png"
mode=
""
></image>
<image
class=
"rgt"
src=
"../../static/img/rgt.png"
mode=
""
></image>
...
@@ -143,7 +143,7 @@
...
@@ -143,7 +143,7 @@
</view>
</view>
</view>
</view>
<view
class=
"consult-btn"
>
<view
class=
"consult-btn"
>
<view
class=
""
@
click=
"submitForm"
>
{{
$lang
.
lang
.
myInfo
.
edit
}}
</view>
<view
class=
""
@
click=
"submitForm"
>
{{
first
?
'
完成
'
:
$lang
.
lang
.
myInfo
.
edit
}}
</view>
</view>
</view>
</view>
</view>
</
template
>
</
template
>
...
@@ -175,10 +175,16 @@ export default {
...
@@ -175,10 +175,16 @@ export default {
countryArray
:
[],
countryArray
:
[],
countryId
:
0
,
countryId
:
0
,
// 城市列表
// 城市列表
cityArray
:
[]
cityArray
:
[],
// 是否为首次进入 没有国家城市信息
first
:
false
}
}
},
},
onLoad
()
{
onLoad
(
route
)
{
const
{
type
}
=
route
if
(
type
==
'
first
'
)
{
this
.
first
=
true
}
this
.
getUserInfo
()
this
.
getUserInfo
()
},
},
computed
:
{
computed
:
{
...
@@ -196,6 +202,16 @@ export default {
...
@@ -196,6 +202,16 @@ export default {
submitForm
()
{
submitForm
()
{
this
.
$request
.
put
(
'
/app-api/member/user/update
'
,
this
.
params
).
then
((
res
)
=>
{
this
.
$request
.
put
(
'
/app-api/member/user/update
'
,
this
.
params
).
then
((
res
)
=>
{
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
if
(
this
.
first
)
{
uni
.
showToast
({
title
:
'
成功
'
,
icon
:
'
none
'
})
uni
.
reLaunch
({
url
:
'
/pages/index/index
'
})
return
}
uni
.
showToast
({
uni
.
showToast
({
title
:
this
.
$lang
.
lang
.
notices
.
edited
,
title
:
this
.
$lang
.
lang
.
notices
.
edited
,
icon
:
'
none
'
icon
:
'
none
'
...
@@ -218,9 +234,17 @@ export default {
...
@@ -218,9 +234,17 @@ export default {
if
(
res
.
data
.
birthday
)
{
if
(
res
.
data
.
birthday
)
{
this
.
date
=
res
.
data
.
birthday
this
.
date
=
res
.
data
.
birthday
}
}
const
{
city
,
country
,
countryTitleZh
,
countryTitleEn
,
cityTitleZh
,
cityTitleEn
}
=
res
.
data
this
.
params
.
city
=
city
this
.
params
.
country
=
country
this
.
params
.
cityValue
=
this
.
rangeKey
==
'
zh
'
?
cityTitleZh
:
cityTitleEn
this
.
params
.
countryValue
=
this
.
rangeKey
==
'
zh
'
?
countryTitleZh
:
countryTitleEn
this
.
getCountryList
()
this
.
getCityList
()
this
.
Country
()
if
(
country
)
this
.
getCityList
(
country
)
}
}
this
.
Country
()
this
.
getCountryList
()
})
})
},
},
// 获取国家区号
// 获取国家区号
...
@@ -274,7 +298,6 @@ export default {
...
@@ -274,7 +298,6 @@ export default {
// 获取国家列表
// 获取国家列表
getCountryList
()
{
getCountryList
()
{
this
.
$request
.
get
(
'
/admin-api/ecw/region/getTradeCountryList
'
).
then
((
res
)
=>
{
this
.
$request
.
get
(
'
/admin-api/ecw/region/getTradeCountryList
'
).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
this
.
countryArray
=
res
.
data
this
.
countryArray
=
res
.
data
}
}
...
@@ -285,13 +308,17 @@ export default {
...
@@ -285,13 +308,17 @@ export default {
const
index
=
e
.
detail
.
value
const
index
=
e
.
detail
.
value
const
{
titleZh
,
titleEn
,
id
}
=
this
.
countryArray
[
index
]
const
{
titleZh
,
titleEn
,
id
}
=
this
.
countryArray
[
index
]
const
value
=
this
.
rangeKey
==
'
zh
'
?
titleZh
:
titleEn
const
value
=
this
.
rangeKey
==
'
zh
'
?
titleZh
:
titleEn
this
.
$set
(
this
.
params
,
'
country
'
,
value
)
if
(
this
.
params
.
country
!=
id
)
{
this
.
getCityList
(
id
)
this
.
$set
(
this
.
params
,
'
cityValue
'
,
''
)
this
.
$set
(
this
.
params
,
'
city
'
,
''
)
this
.
getCityList
(
id
)
}
this
.
$set
(
this
.
params
,
'
countryValue
'
,
value
)
this
.
$set
(
this
.
params
,
'
country
'
,
id
)
},
},
// 获取城市列表
// 获取城市列表
getCityList
(
id
)
{
getCityList
(
id
)
{
this
.
$request
.
get
(
'
/admin-api/ecw/region/getCityListByParent
'
,
{
id
}).
then
((
res
)
=>
{
this
.
$request
.
get
(
'
/admin-api/ecw/region/getCityListByParent
'
,
{
id
}).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
.
code
==
0
)
{
if
(
res
.
code
==
0
)
{
this
.
cityArray
=
res
.
data
this
.
cityArray
=
res
.
data
}
}
...
@@ -300,9 +327,10 @@ export default {
...
@@ -300,9 +327,10 @@ export default {
// 城市选择 change
// 城市选择 change
bindCityChange
(
e
)
{
bindCityChange
(
e
)
{
const
index
=
e
.
detail
.
value
const
index
=
e
.
detail
.
value
const
{
titleZh
,
titleEn
}
=
this
.
cityArray
[
index
]
const
{
titleZh
,
titleEn
,
id
}
=
this
.
cityArray
[
index
]
const
value
=
this
.
rangeKey
==
'
zh
'
?
titleZh
:
titleEn
const
value
=
this
.
rangeKey
==
'
zh
'
?
titleZh
:
titleEn
this
.
$set
(
this
.
params
,
'
city
'
,
value
)
this
.
$set
(
this
.
params
,
'
cityValue
'
,
value
)
this
.
$set
(
this
.
params
,
'
city
'
,
id
)
}
}
}
}
}
}
...
...
src/pages/register/register.vue
View file @
e68a29bc
This diff is collapsed.
Click to expand it.
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