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
Show 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 @@
</el-form-item>
<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-option
v-for=
"(option, optKey) in
caseSpentTime
Array"
<el-option
v-for=
"(option, optKey) in
accountSex
Array"
:key=
"optKey"
:label=
"option.name"
:value=
"option.key"
></el-option>
...
...
@@ -66,7 +66,7 @@
v-model
.
trim=
"model.mobile"
>
</el-input>
</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
class=
"ec-input-normal"
size=
"mini"
...
...
@@ -123,7 +123,7 @@
</el-form-item>
<el-form-item
label=
"用户角色:"
prop=
"userRoles"
class=
"ec-clear-left is-required"
>
<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-form-item>
</el-form>
...
...
@@ -136,7 +136,7 @@ import settingMixin from '../common/settingMixin'
// api
// } from '@/lib/commonMixin'
export
default
{
name
:
'accountFor
i
m'
,
name
:
'accountForm'
,
mixins
:
[
settingMixin
],
...
...
src/components/account/accountModal.vue
View file @
5e8ddbf7
...
...
@@ -32,21 +32,22 @@ export default {
model
:
{
id
:
''
,
name
:
''
,
main_products
:
''
,
company_nature
:
''
,
supplierTags
:
''
,
website
:
''
,
established_at
:
''
,
capital
:
''
,
capital_currency
:
''
,
corp_rep
:
''
,
payment_cycle
:
''
,
account_number
:
''
,
address1
:
''
,
zip
:
''
,
email
:
''
,
sex
:
''
,
birth_date
:
''
,
entry_date
:
''
,
department_id
:
''
,
department_position_id
:
''
,
mobile
:
''
,
telephone_area_code
:
''
,
telephone
:
''
,
fax
:
''
,
description
:
''
telephone_extension_number
:
''
,
id_number
:
''
,
native_place
:
''
,
graduate_school
:
''
,
specialty
:
''
,
education
:
''
,
userRoles
:
[]
}
}
},
...
...
@@ -57,6 +58,7 @@ export default {
this
.
$refs
.
form
.
getEdit
(
model
.
id
)
.
then
((
_model
)
=>
{
UTIL
.
flatten
(
this
.
model
,
_model
)
this
.
model
.
userRoles
=
_model
.
userRoles
.
map
(
item
=>
item
.
name
)
})
}
else
{
this
.
$refs
.
form
.
getNew
()
...
...
@@ -75,15 +77,15 @@ export default {
},
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
!
this
.
model
.
id
&&
delete
_params
[
'
Suppli
ers[id]'
]
!
this
.
model
.
id
&&
delete
_params
[
'
Us
ers[id]'
]
this
.
$refs
[
'form'
].
_validate
(()
=>
{
requestAPI
(
Object
.
assign
(
_apiUrl
,
{
method
:
'POST'
}),
_params
)
.
then
((
res
)
=>
{
this
.
$refs
.
sidePopup
.
close
()
this
.
$message
.
success
(
'操作成功'
)
this
.
$parent
.
reload
()
this
.
$parent
.
_
reload
()
})
// save
})
// validate
}
...
...
src/components/account_list/accountItem.vue
View file @
5e8ddbf7
...
...
@@ -5,7 +5,10 @@
<el-row
:gutter=
"10"
>
<el-col
:span=
"24"
style=
"padding-left: 3px;"
>
<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>
</el-col>
<el-col
:span=
"24"
>
...
...
src/components/common/settingMixin.js
View file @
5e8ddbf7
...
...
@@ -118,6 +118,11 @@ export default {
servicesTypeIds
()
{
let
ret
=
this
.
getArrayByKey
(
'Services'
,
'type_id'
)
return
ret
&&
[].
concat
(
ret
.
value
)
},
accountSexArray
()
{
let
ret
=
this
.
getArrayByKey
(
'Users'
,
'sex'
)
return
ret
&&
[].
concat
(
ret
.
value
)
}
// 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