Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
Asistencia
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
Billy Larru
Asistencia
Commits
adbed1f0
Commit
adbed1f0
authored
6 years ago
by
Billy Larru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[EDIT registro justificacion, enviando datos a registrar]
parent
74717651
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
56 additions
and
8 deletions
+56
-8
general.js
src/main/webapp/js/general.js
+1
-1
registroJustificacion.js
src/main/webapp/js/pages/registroJustificacion.js
+46
-0
registroJustificacion.jsp
src/main/webapp/vistas/registroJustificacion.jsp
+9
-7
No files found.
src/main/webapp/js/general.js
View file @
adbed1f0
...
@@ -48,7 +48,7 @@ const URI_ADMINISTRATIVOS_DESCUENTO_MENSUAL_DETALLADO = "descuentoAsistenciaAdmi
...
@@ -48,7 +48,7 @@ const URI_ADMINISTRATIVOS_DESCUENTO_MENSUAL_DETALLADO = "descuentoAsistenciaAdmi
const
URI_SEDES
=
"sedes"
;
const
URI_SEDES
=
"sedes"
;
const
URI_JUSTIFICACION_TIPO
=
"tipoJustificacion"
const
URI_JUSTIFICACION_TIPO
=
"tipoJustificacion"
const
URI_JUSTIFICACION
=
"justificaciones"
//</editor-fold>
//</editor-fold>
swal
.
mixin
({
swal
.
mixin
({
...
...
This diff is collapsed.
Click to expand it.
src/main/webapp/js/pages/registroJustificacion.js
View file @
adbed1f0
...
@@ -30,10 +30,55 @@ const formControls = {
...
@@ -30,10 +30,55 @@ const formControls = {
}
}
}
}
const
registrarJustificacion
=
()
=>
{
let
personal
=
$
(
"#cboPersonal"
).
select2
(
'data'
)[
0
];
let
{
id
:
trabajador_id
,
nombres
:
trabajador_nombres
,
apellidos
:
trabajador_apellidos
,
documentoidentidad
:
trabajador_documentoidentidad
}
=
personal
let
daterangepicker
=
$
(
"#dpRangoFechas"
).
data
(
'daterangepicker'
)
let
fecha_inicio
=
daterangepicker
.
startDate
.
format
(
'DD/MM/YYYY'
)
let
fecha_fin
=
daterangepicker
.
endDate
.
format
(
'DD/MM/YYYY'
)
let
tipojustificacion_id
=
$
(
"#cboTipoJustificacion"
).
val
()
let
tipojustificacion_descripcion
=
$
(
"#cboTipoJustificacion option:selected"
).
text
()
let
hora_ingreso
=
$
(
"#txtHora"
).
val
()
let
motivo
=
$
(
"#txtMotivo"
).
val
();
let
observacion
=
$
(
"#txtObservacion"
).
val
()
let
numero_documentos_adjuntos
=
$
(
"#txtNumeroDocumentosAdjuntos"
).
val
()
let
documentos_adjuntados
=
""
let
estado
=
1
let
params
=
{
trabajador_id
,
trabajador_nombres
,
trabajador_apellidos
,
trabajador_documentoidentidad
,
fecha_inicio
,
fecha_fin
,
hora_ingreso
,
tipojustificacion_id
,
tipojustificacion_descripcion
,
motivo
,
observacion
,
numero_documentos_adjuntos
,
estado
}
ajaxWebService
.
post
(
URI_JUSTIFICACION
,
params
)
.
then
((
response
)
=>
{
if
(
response
.
status
)
{
console
.
log
(
response
.
message
)
console
.
log
(
response
.
data
)
}
})
}
$
(
document
).
ready
(
function
()
{
$
(
document
).
ready
(
function
()
{
formControls
.
init
()
formControls
.
init
()
listarTipoJustificacion
(
"#cboTipoJustificacion"
)
listarTipoJustificacion
(
"#cboTipoJustificacion"
)
listarPersonal
(
"#cboPersonal"
)
listarPersonal
(
"#cboPersonal"
)
$
(
"#btnRegistrar"
).
click
(
registrarJustificacion
)
});
});
\ No newline at end of file
This diff is collapsed.
Click to expand it.
src/main/webapp/vistas/registroJustificacion.jsp
View file @
adbed1f0
...
@@ -33,12 +33,14 @@
...
@@ -33,12 +33,14 @@
</div>
</div>
</div>
</div>
<div
class=
"col-md-2 form-group"
>
<div
class=
"col-md-4 form-group"
>
<label>
Justificacion por
</label>
<label>
Justificacion por
</label>
<select
id=
"cboTipoJustificacion"
class=
"form-control"
></select>
<select
id=
"cboTipoJustificacion"
class=
"form-control"
></select>
</div>
</div>
<div
class=
"col-md-2 form-group hidden"
id=
"divHora"
>
<label>
Hora
</label>
<input
type=
"time"
id=
"txtHora"
class=
"form-control"
></select>
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-12 form-group"
>
<div
class=
"col-md-12 form-group"
>
...
@@ -49,18 +51,18 @@
...
@@ -49,18 +51,18 @@
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-12 form-group"
>
<div
class=
"col-md-12 form-group"
>
<label>
Observación/Fundamento
</label>
<label>
Observación/Fundamento
</label>
<textarea
name=
""
id=
""
cols=
"30"
rows=
"5"
class=
"form-control"
id=
"txtObservacion
"
></textarea>
<textarea
id=
"txtObservacion"
cols=
"30"
rows=
"5"
class=
"form-control
"
></textarea>
</div>
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-
6
form-group"
>
<div
class=
"col-md-
2
form-group"
>
<label>
Nro documentos adjuntos
</label>
<label>
Nro documentos adjuntos
</label>
<input
type=
"text"
class=
"form-control"
id=
"txtNumeroDocumentosAdjuntos"
>
<input
type=
"text"
class=
"form-control"
id=
"txtNumeroDocumentosAdjuntos"
>
</div>
</div>
<div
class=
"form-group col-md-
6
"
>
<div
class=
"form-group col-md-
10
"
>
<label
class=
"control-label"
>
Adjuntar documentos
</label>
<label
class=
"control-label"
>
Adjuntar documentos
</label>
<input
type=
"file"
class=
"file-styled-primary form-control"
>
<input
type=
"file"
class=
"file-styled-primary form-control"
multiple
>
</div>
</div>
</div>
</div>
...
...
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