Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1
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
吴迪
gs1
Commits
67a7d6bb
Commit
67a7d6bb
authored
Dec 11, 2021
by
Jianli Ou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
个人资料接口对接
parent
5e74f315
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
94 additions
and
24 deletions
+94
-24
api.js
src/axios/api.js
+2
-0
myManage.js
src/axios/module/myManage.js
+20
-0
parameter.js
src/axios/parameter.js
+1
-1
index.vue
src/views/MyManage/UnVerify/index.vue
+17
-3
personalInfo.vue
src/views/MyManage/UnVerify/personalInfo.vue
+46
-20
login.vue
src/views/User/login.vue
+8
-0
No files found.
src/axios/api.js
View file @
67a7d6bb
...
@@ -22,6 +22,7 @@ import search from "./module/search.js"
...
@@ -22,6 +22,7 @@ import search from "./module/search.js"
import
service
from
"./module/service.js"
import
service
from
"./module/service.js"
import
knowledge
from
"./module/knowledge.js"
import
knowledge
from
"./module/knowledge.js"
import
news
from
"./module/news.js"
import
news
from
"./module/news.js"
import
myManage
from
"./module/myManage"
;
const
api
=
{
const
api
=
{
home
,
home
,
...
@@ -31,6 +32,7 @@ const api = {
...
@@ -31,6 +32,7 @@ const api = {
service
,
service
,
knowledge
,
knowledge
,
news
,
news
,
myManage
,
getCaptcha
,
getCaptcha
,
}
}
...
...
src/axios/module/myManage.js
0 → 100644
View file @
67a7d6bb
import
{
POST
,
POSTFORM
,
UPLOAD
}
from
"../fetch.js"
const
Prefix
=
process
.
env
.
NODE_ENV
===
'development'
?
'/gs1'
:
''
;
// 个人资料
const
memberInfo
=
(
params
=
{})
=>
{
return
POST
(
`
${
Prefix
}
/office/member/api/info`
+
`/
${
params
.
id
}
`
,
params
)
}
// 保存个人资料
const
saveMemberInfo
=
(
params
=
{})
=>
{
return
POST
(
`
${
Prefix
}
/office/member/api/update`
,
params
)
}
export
default
{
memberInfo
,
saveMemberInfo
}
src/axios/parameter.js
View file @
67a7d6bb
...
@@ -69,7 +69,7 @@ export function handleResponseSuccess(res = {}) {
...
@@ -69,7 +69,7 @@ export function handleResponseSuccess(res = {}) {
success
:
true
,
success
:
true
,
returnCode
:
res
.
code
||
ResponseCode
.
success
,
returnCode
:
res
.
code
||
ResponseCode
.
success
,
returnMsg
:
res
.
msg
,
returnMsg
:
res
.
msg
,
data
:
res
.
data
||
res
.
page
||
null
data
:
res
.
data
||
res
.
page
||
res
.
member
||
null
}
}
}
}
...
...
src/views/MyManage/UnVerify/index.vue
View file @
67a7d6bb
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
<p>
请直接登录
<a
href=
"#"
>
网上业务大厅
</a>
办理商品条码在
</p>
<p>
请直接登录
<a
href=
"#"
>
网上业务大厅
</a>
办理商品条码在
</p>
</li>
</li>
<!-- 厂商实名认证已认证 -->
<!-- 厂商实名认证已认证 -->
<li>
<li
v-if=
"loginInfo.isQY === 1"
>
<p
class=
"content-title"
>
<p
class=
"content-title"
>
厂商实名认证(办理“进口商品信息通报、GLN”等业务需先完成此认证)
厂商实名认证(办理“进口商品信息通报、GLN”等业务需先完成此认证)
</p>
</p>
...
@@ -40,7 +40,7 @@
...
@@ -40,7 +40,7 @@
</p>
</p>
</li>
</li>
<!-- 厂商实名认证未认证 -->
<!-- 厂商实名认证未认证 -->
<li>
<li
v-if=
"loginInfo.isQY === 2"
>
<p
class=
"content-title"
>
<p
class=
"content-title"
>
厂商实名认证(办理“进口商品信息通报、GLN”等业务需先完成此认证)
厂商实名认证(办理“进口商品信息通报、GLN”等业务需先完成此认证)
</p>
</p>
...
@@ -142,7 +142,21 @@
...
@@ -142,7 +142,21 @@
<
script
>
<
script
>
export
default
{
export
default
{
name
:
"index"
name
:
"index"
,
data
()
{
return
{
loginInfo
:
{
id
:
16
,
// 用户ID
isQY
:
2
,
// 是否开通企业认证 1.是 2.否
isXT
:
2
,
// 是否是业务大厅系统成员 1.是 2.否
userType
:
3
,
// 用户类型 1、业务大厅(手机号用户);2、业务大厅(条码成员);3、官网用户
levels
:
0
// 用户权限 空.普通用户 0.中心管理员 1.校验管理员 其他4位.分中心管理员
}
}
},
mounted
()
{
this
.
loginInfo
=
JSON
.
parse
(
localStorage
.
getItem
(
'loginInfo'
))
}
}
}
</
script
>
</
script
>
...
...
src/views/MyManage/UnVerify/personalInfo.vue
View file @
67a7d6bb
...
@@ -22,30 +22,30 @@
...
@@ -22,30 +22,30 @@
<el-input
v-model=
'form.email'
autocomplete=
'off'
placeholder=
"请输入E-mail"
></el-input>
<el-input
v-model=
'form.email'
autocomplete=
'off'
placeholder=
"请输入E-mail"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
'手机:'
<el-form-item
label=
'手机:'
prop=
'
mobil
e'
prop=
'
phon
e'
:rules=
"[
{
:rules=
"[
{
required: true,
required: true,
message: '不能为空',
message: '不能为空',
},
},
{ validator:checkMobileReg },
{ validator:checkMobileReg },
{ validator:checkMobile, trigger:'blur' },]">
{ validator:checkMobile, trigger:'blur' },]">
<el-input
v-model=
'form.
mobil
e'
autocomplete=
'off'
placeholder=
"请输入手机"
></el-input>
<el-input
v-model=
'form.
phon
e'
autocomplete=
'off'
placeholder=
"请输入手机"
></el-input>
<p>
请在[用户信息管理]-[修改手机号码]中修改正确的手机号码,便于找回密码
</p>
<p>
请在[用户信息管理]-[修改手机号码]中修改正确的手机号码,便于找回密码
</p>
</el-form-item>
</el-form-item>
<el-form-item
label=
'真实姓名:'
<el-form-item
label=
'真实姓名:'
prop=
'name'
prop=
'
real
name'
>
>
<el-input
v-model=
'form.name'
autocomplete=
'off'
placeholder=
"请输入真实姓名:"
></el-input>
<el-input
v-model=
'form.
real
name'
autocomplete=
'off'
placeholder=
"请输入真实姓名:"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
'证件号码:'
<el-form-item
label=
'证件号码:'
prop=
'
IDNumber
'
prop=
'
idcard
'
:rules=
"[
{
:rules=
"[
{
required: true,
required: true,
message: '不能为空',
message: '不能为空',
}]"
}]"
>
>
<el-input
placeholder=
"请输入证件号码"
v-model=
"form.
IDNumber
"
class=
"input-with-select"
>
<el-input
placeholder=
"请输入证件号码"
v-model=
"form.
idcard
"
class=
"input-with-select"
>
<el-select
v-model=
"form.IDType"
slot=
"prepend"
placeholder=
"请选择"
class=
"smallselect"
>
<el-select
v-model=
"form.IDType"
slot=
"prepend"
placeholder=
"请选择"
class=
"smallselect"
>
<el-option
label=
"身份证"
value=
"1"
></el-option>
<el-option
label=
"身份证"
value=
"1"
></el-option>
</el-select>
</el-select>
...
@@ -55,17 +55,17 @@
...
@@ -55,17 +55,17 @@
<el-form-item
label=
'联系地址:'
<el-form-item
label=
'联系地址:'
prop=
'address'
prop=
'address'
>
>
<el-input
v-model=
'form.
email
'
autocomplete=
'off'
placeholder=
"请输入联系地址"
></el-input>
<el-input
v-model=
'form.
address
'
autocomplete=
'off'
placeholder=
"请输入联系地址"
></el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
'工作单位:'
<el-form-item
label=
'工作单位:'
prop=
'oficeAddr'
prop=
'oficeAddr'
>
>
<el-input
v-model=
'form.
oficeAddr
'
autocomplete=
'off'
placeholder=
"请输入工作单位"
></el-input>
<el-input
v-model=
'form.
sign
'
autocomplete=
'off'
placeholder=
"请输入工作单位"
></el-input>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
</div>
</div>
<div
class=
"btn-div"
>
<div
class=
"btn-div"
>
<el-button
type=
"primary"
style=
"width: 110px"
>
保 存
</el-button>
<el-button
type=
"primary"
@
click=
"save"
style=
"width: 110px"
>
保 存
</el-button>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -81,23 +81,39 @@ export default {
...
@@ -81,23 +81,39 @@ export default {
timer
:
null
,
timer
:
null
,
time
:
60
,
time
:
60
,
form
:
{
form
:
{
id
:
''
,
email
:
''
,
email
:
''
,
mobil
e
:
''
,
phon
e
:
''
,
IDType
:
'1'
,
IDType
:
'1'
,
IDNumber
:
''
,
idcard
:
''
,
name
:
''
,
real
name
:
''
,
address
:
''
,
address
:
''
,
officeAddr
:
''
sign
:
''
},
},
mobilePattern
:
/^
((
13
[
0-9
])
|
(
15
[^
4
])
|
(
18
[
0-9
])
|
(
17
[
0-8
])
|
(
147
))\d{8}
$/
,
mobilePattern
:
/^
((
13
[
0-9
])
|
(
15
[^
4
])
|
(
18
[
0-9
])
|
(
17
[
0-8
])
|
(
147
))\d{8}
$/
,
memberInfo
:
{},
loginInfo
:
{
id
:
16
,
// 用户ID
isQY
:
2
,
// 是否开通企业认证 1.是 2.否
isXT
:
2
,
// 是否是业务大厅系统成员 1.是 2.否
userType
:
3
,
// 用户类型 1、业务大厅(手机号用户);2、业务大厅(条码成员);3、官网用户
levels
:
0
// 用户权限 空.普通用户 0.中心管理员 1.校验管理员 其他4位.分中心管理员
}
}
}
},
},
methods
:
{
methods
:
{
save
()
{
this
.
$refs
[
'ruleForm'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
this
.
saveMemberInfo
()
}
else
{
return
false
;
}
});
},
register
()
{
register
()
{
},
},
checkMobileReg
(
rule
,
value
,
callback
)
{
checkMobileReg
(
rule
,
value
,
callback
)
{
if
(
value
!==
''
)
{
if
(
value
!==
''
)
{
if
(
this
.
mobilePattern
.
test
(
value
))
{
if
(
this
.
mobilePattern
.
test
(
value
))
{
...
@@ -107,16 +123,28 @@ export default {
...
@@ -107,16 +123,28 @@ export default {
}
}
}
}
},
},
checkMobile
()
{
checkMobile
()
{
console
.
log
(
'checkMobile'
);
console
.
log
(
'checkMobile'
);
return
new
Promise
((
resolve
)
=>
{
return
new
Promise
((
resolve
)
=>
{
resolve
(
true
);
resolve
(
true
);
});
});
},
},
async
getMemberInfo
()
{
this
.
memberInfo
=
(
await
this
.
$api
.
myManage
.
memberInfo
({
id
:
this
.
loginInfo
.
id
})).
data
Object
.
keys
(
this
.
form
).
forEach
(
key
=>
{
this
.
form
[
key
]
=
this
.
memberInfo
[
key
]
||
''
})
},
async
saveMemberInfo
()
{
if
((
await
this
.
$api
.
myManage
.
saveMemberInfo
(
this
.
form
)).
success
)
{
this
.
$message
.
success
(
'个人资料保存成功'
)
}
}
},
},
mounted
()
{
this
.
loginInfo
=
JSON
.
parse
(
localStorage
.
getItem
(
'loginInfo'
))
this
.
getMemberInfo
()
}
}
}
</
script
>
</
script
>
...
@@ -246,7 +274,5 @@ export default {
...
@@ -246,7 +274,5 @@ export default {
padding
:
0
10px
;
padding
:
0
10px
;
}
}
}
}
</
style
>
</
style
>
src/views/User/login.vue
View file @
67a7d6bb
...
@@ -110,6 +110,14 @@ export default {
...
@@ -110,6 +110,14 @@ export default {
},
},
methods
:
{
methods
:
{
loginByUser
()
{
loginByUser
()
{
const
loginInfo
=
{
id
:
16
,
isQY
:
2
,
isXT
:
2
,
userType
:
3
,
levels
:
0
}
localStorage
.
setItem
(
'loginInfo'
,
JSON
.
stringify
(
loginInfo
))
this
.
$refs
[
'userLoginFormRef'
].
validate
((
valid
)
=>
{
this
.
$refs
[
'userLoginFormRef'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
valid
)
{
if
(
this
.
userForm
.
validateCode
.
toLowerCase
()
===
'kjjj'
)
{
if
(
this
.
userForm
.
validateCode
.
toLowerCase
()
===
'kjjj'
)
{
...
...
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