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
5b5a059d
Commit
5b5a059d
authored
May 12, 2019
by
daywrite
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复考勤记录说明
parent
44730865
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
196 additions
and
2 deletions
+196
-2
punch-app.scss
src/assets/css/punch-app.scss
+7
-0
settingMixin.js
src/components/common/settingMixin.js
+8
-0
editForm.vue
src/components/punch/editForm.vue
+85
-0
editModal.vue
src/components/punch/editModal.vue
+86
-0
punchHome.vue
src/components/punch_list/punchHome.vue
+10
-2
No files found.
src/assets/css/punch-app.scss
View file @
5b5a059d
...
...
@@ -7,4 +7,11 @@
border-color
:
#dc3545
;
color
:
#dc3545
;
}
.el-dialog__title
{
color
:white
;
}
.ec-page-wrapper
.el-form-item__label
{
color
:
white
;
}
}
src/components/common/settingMixin.js
View file @
5b5a059d
...
...
@@ -146,6 +146,14 @@ export default {
return
methods
[
params
].
call
(
this
,
id
)
},
getPunchEdit
(
id
)
{
return
requestAPI
(
api
.
getpunchEdit
,
{
id
})
.
then
((
res
)
=>
{
this
.
retNewArray
=
res
.
options
return
res
.
model
})
},
getServiceEdit
(
id
)
{
return
requestAPI
(
api
.
getserviceEdit
,
{
id
})
.
then
((
res
)
=>
{
...
...
src/components/punch/editForm.vue
0 → 100644
View file @
5b5a059d
<
template
>
<section
class=
"ec-page-wrapper"
style=
"overflow: hidden; padding-bottom: 0px;"
>
<el-form
label-width=
"120px"
ref=
"form"
:rules=
"rules"
:model=
"model"
class=
"ec-create-form"
>
<el-form-item
label=
"日期:"
class=
"ec-form-item ec-clear-left is-required"
>
{{
model
.
day_at
}}
</el-form-item>
<el-form-item
label=
"签到时间:"
class=
"ec-clear-left ec-form-item-lg"
>
{{
model
.
in_at
?
model
.
in_at
:
model
.
in_status_display
}}
</el-form-item>
<el-form-item
label=
"签到说明:"
prop=
"in_description"
class=
"ec-clear-left is-required"
>
<el-input
class=
"ec-input-normal"
type=
"textarea"
:rows=
"3"
v-model
.
trim=
"model.in_description"
>
</el-input>
</el-form-item>
<el-form-item
label=
"签退时间:"
class=
"ec-clear-left is-required"
>
{{
model
.
out_at
?
model
.
out_at
:
model
.
out_status_display
}}
</el-form-item>
<el-form-item
label=
"签退说明:"
prop=
"out_description"
class=
"ec-clear-left is-required"
>
<el-input
class=
"ec-input-normal"
type=
"textarea"
:rows=
"3"
v-model
.
trim=
"model.out_description"
>
</el-input>
</el-form-item>
</el-form>
</section>
</
template
>
<
script
>
import
settingMixin
from
'../common/settingMixin'
export
default
{
name
:
'punchEditForm'
,
mixins
:
[
settingMixin
],
props
:
{
model
:
Object
},
data
()
{
return
{
rules
:
{},
query
:
{}
}
},
created
()
{
},
mounted
()
{
},
computed
:
{
},
methods
:
{
getEdit
(
id
)
{
return
this
.
initEditSetting
(
'getPunchEdit'
,
id
)
},
_validate
(
cb
)
{
this
.
$refs
[
'form'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
cb
&&
cb
()
}
})
},
_resetFields
()
{
this
.
$refs
[
'form'
].
resetFields
()
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
.ec-create-form
.el-form-item
{
width
:
70%
;
}
// .ec-create-form .el-form-item {
// width: 100%;
// }
</
style
>
src/components/punch/editModal.vue
0 → 100644
View file @
5b5a059d
<
template
>
<section>
<sidePopup
ref=
"sidePopup"
title=
"修改考勤"
:width=
"50"
@
update:close=
"() => btnClose()"
>
<EditForm
ref=
"docForm"
:model=
"model"
>
</EditForm>
<div
class=
"mt20"
style=
"margin-left: 150px;"
>
<el-button
type=
"confirm"
@
click
.
stop
.
prevent=
"save"
size=
"mini"
>
保存修改
</el-button>
</div>
</sidePopup>
</section>
</
template
>
<
script
>
import
{
requestAPI
,
api
,
UTIL
}
from
'@/lib/commonMixin'
import
EditForm
from
'./editForm'
import
{
setModule
}
from
'@/lib/viewHelper'
export
default
{
components
:
{
EditForm
},
data
()
{
return
{
diaVis
:
false
,
model
:
{
id
:
''
,
day_at
:
''
,
in_at
:
''
,
in_status_display
:
''
,
out_at
:
''
,
out_status_display
:
''
,
in_description
:
''
,
out_description
:
''
}
}
},
methods
:
{
show
(
model
)
{
if
(
model
)
{
this
.
$refs
.
docForm
.
getEdit
(
model
.
id
)
.
then
((
_model
)
=>
{
UTIL
.
flatten
(
this
.
model
,
_model
)
})
}
this
.
$refs
.
sidePopup
.
show
()
},
handleClose
()
{
this
.
$refs
.
sidePopup
.
close
(()
=>
{
this
.
$refs
.
docForm
.
_resetFields
()
})
},
btnClose
()
{
this
.
$refs
.
docForm
.
_resetFields
()
},
save
()
{
let
_model
=
Object
.
assign
({},
this
.
model
)
let
_params
=
Object
.
assign
({},
setModule
({
id
:
_model
.
id
,
in_description
:
_model
.
in_description
,
out_description
:
_model
.
out_description
},
'Punch'
))
let
_apiUrl
=
api
.
savepunchEdit
this
.
$refs
[
'docForm'
].
_validate
(()
=>
{
requestAPI
(
Object
.
assign
(
_apiUrl
,
{
method
:
'POST'
}),
_params
)
.
then
((
res
)
=>
{
this
.
$refs
.
sidePopup
.
close
()
this
.
$message
.
success
(
'操作成功'
)
this
.
$parent
.
_reload
()
})
// save
})
// validate
}
}
}
</
script
>
<
style
lang=
"scss"
scoped
>
</
style
>
src/components/punch_list/punchHome.vue
View file @
5b5a059d
...
...
@@ -54,6 +54,7 @@
:total="result.pagenation.totalcount">
</Pagenation>
</div>
<editModal
ref=
"editModal"
></editModal>
</div>
</section>
</
template
>
...
...
@@ -63,10 +64,11 @@ import SearchHeader from '../common/searchHeader'
import
SearchForm
from
'../common/SearchForm'
import
Item
from
'./punchItem'
import
Pagenation
from
'./punchPagenation'
import
clickOutside
from
'@/lib/bind'
import
SetParams
from
'../common/setParams'
import
singleRadioTool
from
'../common/singleRadioTool'
import
countArr
from
'./countArr'
import
editModal
from
'../punch/editModal'
import
clickOutside
from
'@/lib/bind'
import
{
requestAPI
,
api
...
...
@@ -82,7 +84,8 @@ export default {
Item
,
Pagenation
,
singleRadioTool
,
countArr
countArr
,
editModal
},
directives
:
{
...
...
@@ -225,6 +228,11 @@ export default {
this
.
getList
(
ret
)
},
// 6.2编辑
editSch
(
item
)
{
this
.
$refs
.
editModal
.
show
(
item
)
},
// 7.操作
// 修改密码
changePasswordEvent
()
{},
...
...
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