Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bms-vue-obear
Project
Project
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
daywrite
bms-vue-obear
Commits
5e8ddbf7
Commit
5e8ddbf7
authored
May 16, 2019
by
daywrite
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
检查员工管理
parent
5c99357b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
32 additions
and
22 deletions
+32
-22
accountForm.vue
src/components/account/accountForm.vue
+4
-4
accountModal.vue
src/components/account/accountModal.vue
+19
-17
accountItem.vue
src/components/account_list/accountItem.vue
+4
-1
settingMixin.js
src/components/common/settingMixin.js
+5
-0
No files found.
src/components/account/accountForm.vue
View file @
5e8ddbf7
...
@@ -17,7 +17,7 @@
...
@@ -17,7 +17,7 @@
</el-form-item>
</el-form-item>
<el-form-item
label=
"性别:"
prop=
"sex"
class=
"ec-clear-left ec-form-item-lg is-required"
>
<el-form-item
label=
"性别:"
prop=
"sex"
class=
"ec-clear-left ec-form-item-lg is-required"
>
<el-select
v-model=
"model.sex"
size=
"small"
placeholder=
"请选择"
>
<el-select
v-model=
"model.sex"
size=
"small"
placeholder=
"请选择"
>
<el-option
v-for=
"(option, optKey) in
caseSpentTime
Array"
<el-option
v-for=
"(option, optKey) in
accountSex
Array"
:key=
"optKey"
:key=
"optKey"
:label=
"option.name"
:label=
"option.name"
:value=
"option.key"
></el-option>
:value=
"option.key"
></el-option>
...
@@ -66,7 +66,7 @@
...
@@ -66,7 +66,7 @@
v-model
.
trim=
"model.mobile"
>
v-model
.
trim=
"model.mobile"
>
</el-input>
</el-input>
</el-form-item>
</el-form-item>
<el-form-item
label=
"座机:"
prop=
"
nam
e"
class=
"ec-clear-left is-required"
>
<el-form-item
label=
"座机:"
prop=
"
telephone_area_cod
e"
class=
"ec-clear-left is-required"
>
<el-input
<el-input
class=
"ec-input-normal"
class=
"ec-input-normal"
size=
"mini"
size=
"mini"
...
@@ -123,7 +123,7 @@
...
@@ -123,7 +123,7 @@
</el-form-item>
</el-form-item>
<el-form-item
label=
"用户角色:"
prop=
"userRoles"
class=
"ec-clear-left is-required"
>
<el-form-item
label=
"用户角色:"
prop=
"userRoles"
class=
"ec-clear-left is-required"
>
<el-checkbox-group
v-model=
"model.userRoles"
>
<el-checkbox-group
v-model=
"model.userRoles"
>
<el-checkbox
v-for=
"sItem in accountUserRoles"
:key=
"sItem.
key"
:label=
"sItem.name
"
>
{{
sItem
.
name
}}
</el-checkbox>
<el-checkbox
v-for=
"sItem in accountUserRoles"
:key=
"sItem.
name"
:label=
"sItem.key
"
>
{{
sItem
.
name
}}
</el-checkbox>
</el-checkbox-group>
</el-checkbox-group>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
...
@@ -136,7 +136,7 @@ import settingMixin from '../common/settingMixin'
...
@@ -136,7 +136,7 @@ import settingMixin from '../common/settingMixin'
// api
// api
// } from '@/lib/commonMixin'
// } from '@/lib/commonMixin'
export
default
{
export
default
{
name
:
'accountFor
i
m'
,
name
:
'accountForm'
,
mixins
:
[
settingMixin
],
mixins
:
[
settingMixin
],
...
...
src/components/account/accountModal.vue
View file @
5e8ddbf7
...
@@ -32,21 +32,22 @@ export default {
...
@@ -32,21 +32,22 @@ export default {
model
:
{
model
:
{
id
:
''
,
id
:
''
,
name
:
''
,
name
:
''
,
main_products
:
''
,
email
:
''
,
company_nature
:
''
,
sex
:
''
,
supplierTags
:
''
,
birth_date
:
''
,
website
:
''
,
entry_date
:
''
,
established_at
:
''
,
department_id
:
''
,
capital
:
''
,
department_position_id
:
''
,
capital_currency
:
''
,
mobile
:
''
,
corp_rep
:
''
,
telephone_area_code
:
''
,
payment_cycle
:
''
,
account_number
:
''
,
address1
:
''
,
zip
:
''
,
telephone
:
''
,
telephone
:
''
,
fax
:
''
,
telephone_extension_number
:
''
,
description
:
''
id_number
:
''
,
native_place
:
''
,
graduate_school
:
''
,
specialty
:
''
,
education
:
''
,
userRoles
:
[]
}
}
}
}
},
},
...
@@ -57,6 +58,7 @@ export default {
...
@@ -57,6 +58,7 @@ export default {
this
.
$refs
.
form
.
getEdit
(
model
.
id
)
this
.
$refs
.
form
.
getEdit
(
model
.
id
)
.
then
((
_model
)
=>
{
.
then
((
_model
)
=>
{
UTIL
.
flatten
(
this
.
model
,
_model
)
UTIL
.
flatten
(
this
.
model
,
_model
)
this
.
model
.
userRoles
=
_model
.
userRoles
.
map
(
item
=>
item
.
name
)
})
})
}
else
{
}
else
{
this
.
$refs
.
form
.
getNew
()
this
.
$refs
.
form
.
getNew
()
...
@@ -75,15 +77,15 @@ export default {
...
@@ -75,15 +77,15 @@ export default {
},
},
save
()
{
save
()
{
let
_params
=
Object
.
assign
({},
setModule
(
this
.
model
,
'
Suppli
ers'
))
let
_params
=
Object
.
assign
({},
setModule
(
this
.
model
,
'
Us
ers'
))
let
_apiUrl
=
!
this
.
model
.
id
?
api
.
saveaccountNew
:
api
.
saveaccountEdit
let
_apiUrl
=
!
this
.
model
.
id
?
api
.
saveaccountNew
:
api
.
saveaccountEdit
!
this
.
model
.
id
&&
delete
_params
[
'
Suppli
ers[id]'
]
!
this
.
model
.
id
&&
delete
_params
[
'
Us
ers[id]'
]
this
.
$refs
[
'form'
].
_validate
(()
=>
{
this
.
$refs
[
'form'
].
_validate
(()
=>
{
requestAPI
(
Object
.
assign
(
_apiUrl
,
{
method
:
'POST'
}),
_params
)
requestAPI
(
Object
.
assign
(
_apiUrl
,
{
method
:
'POST'
}),
_params
)
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
this
.
$refs
.
sidePopup
.
close
()
this
.
$refs
.
sidePopup
.
close
()
this
.
$message
.
success
(
'操作成功'
)
this
.
$message
.
success
(
'操作成功'
)
this
.
$parent
.
reload
()
this
.
$parent
.
_
reload
()
})
// save
})
// save
})
// validate
})
// validate
}
}
...
...
src/components/account_list/accountItem.vue
View file @
5e8ddbf7
...
@@ -5,7 +5,10 @@
...
@@ -5,7 +5,10 @@
<el-row
:gutter=
"10"
>
<el-row
:gutter=
"10"
>
<el-col
:span=
"24"
style=
"padding-left: 3px;"
>
<el-col
:span=
"24"
style=
"padding-left: 3px;"
>
<span>
<span>
<img
class=
"user-avatar rounded-circle"
:src=
"item.avatar.avatar"
>
{{
item
.
name
}}
<img
class=
"user-avatar rounded-circle"
:src=
"item.avatar.avatar"
>
<router-link
:to=
"
{ path: '/app-v/profile/profile' }">
{{
item
.
name
}}
</router-link>
</span>
</span>
</el-col>
</el-col>
<el-col
:span=
"24"
>
<el-col
:span=
"24"
>
...
...
src/components/common/settingMixin.js
View file @
5e8ddbf7
...
@@ -118,6 +118,11 @@ export default {
...
@@ -118,6 +118,11 @@ export default {
servicesTypeIds
()
{
servicesTypeIds
()
{
let
ret
=
this
.
getArrayByKey
(
'Services'
,
'type_id'
)
let
ret
=
this
.
getArrayByKey
(
'Services'
,
'type_id'
)
return
ret
&&
[].
concat
(
ret
.
value
)
return
ret
&&
[].
concat
(
ret
.
value
)
},
accountSexArray
()
{
let
ret
=
this
.
getArrayByKey
(
'Users'
,
'sex'
)
return
ret
&&
[].
concat
(
ret
.
value
)
}
}
// company_nature
// company_nature
},
},
...
...
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