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
e1d2e2ea
Commit
e1d2e2ea
authored
Aug 24, 2018
by
Billy Larru
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mostrando filtros en montos de policias
parent
6159a3be
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
110 additions
and
348 deletions
+110
-348
monto_policias.js
src/main/webapp/js/pages/monto_policias.js
+73
-0
montoPolicias.jsp
src/main/webapp/vistas/montoPolicias.jsp
+37
-348
No files found.
src/main/webapp/js/pages/monto_policias.js
0 → 100644
View file @
e1d2e2ea
function
listarPolicias
(
selectorName
)
{
axios
.
get
(
URI_POLICIAS
).
then
((
result
)
=>
{
let
policias
=
result
.
data
;
policias
=
_
.
orderBy
(
policias
,
p
=>
p
.
nombres
);
let
html
=
`<option value="">[TODOS]</option>`
;
policias
.
forEach
(
p
=>
html
+=
`<option documento_identidad="
${
p
.
dni
}
" value="
${
p
.
id
}
">
${
p
.
nombres
}
</option>`
);
$
(
`
${
selectorName
}
`
).
html
(
html
);
$
(
'.select-search'
).
select2
();
});
}
function
listarSedes
(
selectorName
)
{
axios
.
get
(
URI_SEDES
).
then
((
result
)
=>
{
let
sedes
=
result
.
data
;
sedes
=
_
.
orderBy
(
sedes
,
s
=>
s
.
descripcion
);
let
html
=
`<option value="">[TODOS]</option>`
;
sedes
.
forEach
(
sede
=>
html
+=
`<option value="
${
sede
.
codigo
}
">
${
sede
.
descripcion
}
</option>`
);
$
(
`
${
selectorName
}
`
).
html
(
html
);
});
}
function
defaultConfigDateRangePicker
(
selectorName
)
{
$
(
selectorName
).
daterangepicker
({
"autoApply"
:
true
,
"locale"
:
{
"format"
:
"DD/MM/YYYY"
,
"separator"
:
" - "
,
"applyLabel"
:
"Apply"
,
"cancelLabel"
:
"Cancel"
,
"fromLabel"
:
"From"
,
"toLabel"
:
"To"
,
"customRangeLabel"
:
"Custom"
,
"weekLabel"
:
"W"
,
"daysOfWeek"
:
[
"Do"
,
"Lu"
,
"Ma"
,
"Mi"
,
"Ju"
,
"Vi"
,
"Sa"
],
"monthNames"
:
[
"Enero"
,
"Febrero"
,
"Marzo"
,
"Abril"
,
"Mayo"
,
"Junio"
,
"Julio"
,
"Agosto"
,
"Setiembre"
,
"Octubre"
,
"Noviembre"
,
"Diciembre"
],
"firstDay"
:
1
},
"startDate"
:
"17/08/2018"
,
"endDate"
:
"23/08/2018"
},
function
(
start
,
end
,
label
)
{
// console.log('New date range selected: ' + start.format('YYYY-MM-DD') + ' to ' + end.format('YYYY-MM-DD') + ' (predefined range: ' + label + ')');
});
$
(
selectorName
).
datepicker
(
'setDate'
,
'now'
);
}
$
().
ready
(
function
()
{
defaultConfigDataTable
();
listarPolicias
(
"#cboPoliciasFiltro"
);
listarSedes
(
"#cboSedesFiltro"
);
defaultConfigDateRangePicker
(
"#dpRangoFechas"
)
});
\ No newline at end of file
src/main/webapp/vistas/montoPolicias.jsp
View file @
e1d2e2ea
...
@@ -6,378 +6,67 @@
...
@@ -6,378 +6,67 @@
<
%@
include
file=
"templates/header.jsp"
%
>
<
%@
include
file=
"templates/header.jsp"
%
>
<!--template-core-->
<!--template-core-->
<!--css de la pagina-->
<!--css de la pagina-->
<link
href=
"../css/lib/sweetalert2.min.css"
rel=
"stylesheet"
type=
"text/css"
/>
<!--css-->
<!--css-->
</head>
</head>
<body>
<body>
<
%@
include
file=
"templates/header-body.jsp"
%
>
<
%@
include
file=
"templates/header-body.jsp"
%
>
<!-- content -->
<!-- content -->
<div
class=
"col-md-
4 col-md-offset-4
"
>
<div
class=
"col-md-
6 col-md-offset-3
"
>
<div
class=
"panel panel-primary"
>
<div
class=
"panel panel-primary"
>
<div
class=
"panel-heading"
>
<div
class=
"panel-heading"
>
<h5
class=
"panel-title"
>
Reporte de montos
</h5>
<h5
class=
"panel-title"
>
Reporte de montos
</h5>
</div>
</div>
<form
id=
"frmMontos"
onsubmit=
"return false;"
autocomplete=
"off"
>
<div
class=
"panel-body"
>
<div
class=
"panel-body"
>
<div
class=
"row"
>
<div
class=
"col-md-12 form-group"
>
<div
class=
"row"
>
<label>
Rango de fechas:
</label>
<div
class=
"col-md-6 form-group"
>
<div
class=
"input-group"
>
<label>
Rango de fechas:
</label>
<span
class=
"input-group-addon"
><i
class=
"icon-calendar22"
></i></span>
<div
class=
"input-group"
>
<input
type=
"text"
class=
"form-control"
value=
"24/08/2018 - 30/08/2018"
id=
"dpRangoFechas"
>
<span
class=
"input-group-addon"
><i
class=
"icon-calendar22"
></i></span>
<input
type=
"text"
class=
"form-control daterange-basic"
value=
"01/06/2018 - 30/06/2018"
>
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"row"
>
<div
class=
"row"
>
<div
class=
"col-md-5 form-group"
>
<div
class=
"col-md-6 form-group"
>
<label>
Busqueda por
</label>
<label>
Policia
</label>
<select
class=
"form-control"
id=
"cboCriterio"
>
<select
class=
"select-search form-control"
id=
"cboPoliciasFiltro"
>
<option>
[TODOS]
</option>
</select>
<option>
SEDE
</option>
<option>
APELLIDOS Y NOMBRES
</option>
<option>
DNI
</option>
</select>
</div>
<div
class=
"form-group col-md-7"
>
<label
for=
""
>
Sede
</label>
<input
type=
"text"
class=
"form-control"
></input>
</div>
</div>
</div>
</div>
<div
class=
"col-md-6 form-group"
>
<div
class=
"panel-footer"
>
<label>
Sede
</label>
<div
class=
"text-center"
>
<select
id=
"cboSedesFiltro"
class=
"select-search form-control"
>
<button
class=
"btn btn-primary"
id=
"btnBuscar"
><i
class=
"fa fa-search"
></i>
Buscar
</button>
<button
class=
"btn btn-warning"
id=
"btnLimpiar"
><i
class=
"fa fa-eraser"
></i>
Limpiar
</button>
</select>
<button
class=
"btn btn-success"
id=
"btnLimpiar"
><i
class=
"icon-file-excel"
></i>
Exportar
</button>
</div>
</div>
</div>
</div>
</form>
</div>
</div>
<div
class=
"col-md-12"
>
<div
class=
"panel panel-primary card-3"
>
<div
class=
"panel-heading"
>
<h6
class=
"panel-title"
style=
"font-size: 15px; font-family: inherit"
><i
class=
"icon icon-user"
></i>
ABANTO INOCENTE, MIGUEL RICARDO
</h6>
</div>
</div>
<div>
<div
class=
"panel-footer"
>
<table
class=
"table table-responsive dataTable table-striped table-hover table-sm table-bordered display"
id=
"tblAsistenciaPolicias"
>
<div
class=
"text-center"
>
<thead>
<button
class=
"btn btn-primary"
id=
"btnVerRoles"
><i
class=
"icon-eye4"
></i>
Ver reporte
</button>
<tr>
<button
class=
"btn btn-primary"
id=
"btnVerTodos"
><i
class=
"icon-eye4"
></i>
Ver Todos
</button>
<th
class=
"text-center"
>
N°
</th>
</div>
<th
class=
"text-center"
>
Sede
</th>
<th
class=
"text-center"
>
Horario
</th>
<th
class=
"text-center"
>
Fecha de entrada
</th>
<th
class=
"text-center"
>
Marcación de entrada
</th>
<th
class=
"text-center"
>
Marcación de salida
</th>
<th
class=
"text-center"
>
Fecha de salida
</th>
<th
class=
"text-center"
>
Tipo de horario
</th>
<th
class=
"text-center"
>
Costo hora
</th>
<th
class=
"text-center"
>
Tiempo laborado
</th>
<th
class=
"text-center"
>
Monto
</th>
<th
class=
"text-center"
>
Dcto por no marcar
</th>
<th
class=
"text-center"
>
Tiempo extra
</th>
<th
class=
"text-center"
>
Monto extras
</th>
<th
class=
"text-center"
>
Estado extras
</th>
<th
class=
"text-center"
>
<input
type=
"checkbox"
id=
"extras-select-all"
class=
"checker border-primary-600 text-primary-800"
>
</th>
<th
class=
"text-center"
>
Monto total
</th>
</tr>
</thead>
<tbody>
<tr>
<td
class=
"text-center"
>
1
</td>
<td
class=
"text-center"
>
VILLA EL SALVADOR
</td>
<td
class=
"text-center"
>
07:00 - 17:00
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
style=
"color: #999999;"
><strong>
07:21
</strong></td>
<td
class=
"text-center"
>
17:38
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
<span
class=
"label bg-slate border-slate-700"
title=
"REGULAR"
>
REGULAR
</span>
</td>
<td
class=
"text-center"
>
8.50
</td>
<td
class=
"text-center"
>
10:00
</td>
<td
class=
"text-center text-blue"
>
85.00
</td>
<td
class=
"text-center text-danger"
>
17.00
</td>
<td
class=
"text-center"
>
00:38
</td>
<td
class=
"text-center text-blue"
>
0.00
</td>
<td
class=
"text-center"
>
<span
class=
"label label-danger border-danger-700"
title=
"ANULADO"
>
DESAPROBADO
</span>
</td>
<td
class=
"text-center"
>
<!--<input type="checkbox" class="checker border-primary-600 text-primary-800">-->
<input
type=
"checkbox"
class=
"styled"
>
</td>
<td
class=
"text-center"
>
85.00
</td>
</tr>
<tr>
<td
class=
"text-center"
>
2
</td>
<td
class=
"text-center"
>
LINCE
</td>
<td
class=
"text-center"
>
07:00 - 07:00
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
06:59
</td>
<td
class=
"text-center"
>
07:13
</td>
<td
class=
"text-center"
>
13/07/2018
</td>
<td
class=
"text-center"
>
<span
class=
"label bg-teal border-teal-700"
title=
"REGULAR"
>
AMANECIDA 24H
</span>
</td>
<td
class=
"text-center"
>
8.50
</td>
<td
class=
"text-center"
>
24:00
</td>
<td
class=
"text-center text-blue"
>
200.00
</td>
<td
class=
"text-center text-danger"
>
0.00
</td>
<td
class=
"text-center"
>
00:00
</td>
<td
class=
"text-center text-blue"
>
0.00
</td>
<td
class=
"text-center"
>
<span
class=
"label label-success border-success-700"
>
APROBADO
</span>
</td>
<td
class=
"text-center"
>
<input
type=
"checkbox"
class=
"checker border-primary-600 text-primary-800"
>
</td>
<td
class=
"text-center"
>
85.00
</td>
</tr>
<tr>
<td
class=
"text-center"
>
3
</td>
<td
class=
"text-center"
>
MONTESORI
</td>
<td
class=
"text-center"
>
19:00 - 07:00
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
07:00
</td>
<td
class=
"text-center"
>
07:00
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
<span
class=
"label bg-brown border-brown-700"
title=
"AMANECIDA 24H"
>
AMANECIDA 12H
</span>
</td>
<td
class=
"text-center"
>
8.50
</td>
<td
class=
"text-center"
>
10:00
</td>
<td
class=
"text-center text-blue"
>
85.00
</td>
<td
class=
"text-center text-danger"
>
0.00
</td>
<td
class=
"text-center"
>
00:00
</td>
<td
class=
"text-center text-blue"
>
0.00
</td>
<td
class=
"text-center"
>
<span
class=
"label label-success border-success-700"
title=
"APROBADO"
>
APROBADO
</span>
</td>
<td
class=
"text-center"
>
<input
type=
"checkbox"
class=
"styled"
checked=
"checked"
>
</td>
<td
class=
"text-center"
>
85.00
</td>
</tr>
<tr>
<td
class=
"text-center"
>
4
</td>
<td
class=
"text-center"
>
AREQUIPA
</td>
<td
class=
"text-center"
>
07:00 - 17:00
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
06:52
</td>
<td
class=
"text-center"
>
17:23
</td>
<td
class=
"text-center"
>
12/07/2018
</td>
<td
class=
"text-center"
>
<span
class=
"label bg-slate border-slate-700"
title=
"REGULAR"
>
REGULAR
</span>
</td>
<td
class=
"text-center"
>
8.50
</td>
<td
class=
"text-center"
>
10:00
</td>
<td
class=
"text-center text-blue"
>
85.00
</td>
<td
class=
"text-center text-danger"
>
0.00
</td>
<td
class=
"text-center"
>
00:23
</td>
<td
class=
"text-center text-blue"
>
0.00
</td>
<td
class=
"text-center"
>
<span
class=
"label label-danger border-danger-700"
title=
"APROBADO"
>
DESAPROBADO
</span>
</td>
<td
class=
"text-center"
>
<input
type=
"checkbox"
class=
"styled"
disabled=
"disabled"
>
</td>
<td
class=
"text-center"
>
85.00
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- <div class="col-md-12">
<div class="panel panel-primary card-3" style="margin-top: 30px">
<div class="panel-heading" style="padding: 8px 15px">
<h6 class="panel-title" style="font-size: 15px; font-family: inherit"><i class="icon icon-user"></i> DELGADO ACEVEDO, JUAN JOSE</h6>
</div>
<div>
<table class="table dataTable table-striped table-hover table-sm table-bordered display" id="tblAsistenciaPolicias">
<thead>
<tr>
<th class="text-center">N°</th>
<th class="text-center">Sede</th>
<th class="text-center">Fecha de entrada base</th>
<th class="text-center">Fecha de salida base</th>
<th class="text-center">Marcación de entrada</th>
<th class="text-center">Marcación de salida</th>
<th class="text-center">Tipo de horario</th>
<th class="text-center">Costo hora(S/.)</th>
<th class="text-center">Tiempo laborado</th>
<th class="text-center">Monto(S/.)</th>
<th class="text-center">Tiempo extra</th>
<th class="text-center">Monto extras(S/.)</th>
<th class="text-center">Estado extras</th>
<th class="text-center">Monto total(S/.)</th>
</tr>
</thead>
<tbody>
<tr>
<td class="text-center">1</td>
<td class="text-center">VILLA EL SALVADOR</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">
<span class="label bg-slate border-slate-700" title="REGULAR">REGULAR</span>
</td>
<td class="text-center">8.50</td>
<td class="text-center">10:00</td>
<td class="text-center">85.00</td>
<td class="text-center">00:00</td>
<td class="text-center">0.00</td>
<td class="text-center">
<span class="label label-danger border-danger-700" title="ANULADO">DESAPROBADO</span>
</td>
<td class="text-center">85.00</td>
</tr>
<tr>
<td class="text-center">2</td>
<td class="text-center">LINCE</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">
<span class="label bg-teal border-teal-700" title="REGULAR">AMANECIDA 24H</span>
</td>
<td class="text-center">8.50</td>
<td class="text-center">24:00</td>
<td class="text-center">200.00</td>
<td class="text-center">00:00</td>
<td class="text-center">0.00</td>
<td class="text-center">
<span class="label label-success border-success-700" title="ANULADO">APROBADO</span>
</td>
<td class="text-center">85.00</td>
</tr>
<tr>
<td class="text-center">3</td>
<td class="text-center">MONTESORI</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">12/07/2018 07:00</td>
<td class="text-center">12/07/2018 17:00</td>
<td class="text-center">
<span class="label bg-brown border-brown-700" title="AMANECIDA 24H">AMANECIDA 12H</span>
</td>
<td class="text-center">8.50</td>
<td class="text-center">10:00</td>
<td class="text-center">85.00</td>
<td class="text-center">00:00</td>
<td class="text-center">0.00</td>
<td class="text-center">
<span class="label label-success border-success-700" title="APROBADO">APROBADO</span>
</td>
<td class="text-center">85.00</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
-->
<!-- / content -->
<!-- / content -->
<
%@
include
file=
"templates/footer-body.jsp"
%
>
<
%@
include
file=
"templates/footer-body.jsp"
%
>
<!--js de la pagina-->
<!--js de la pagina-->
<script
src=
"../plantilla/assets/js/plugins/tables/datatables/datatables.min.js"
type=
"text/javascript"
></script>
<script
src=
"../plantilla/assets/js/plugins/tables/datatables/datatables.min.js"
type=
"text/javascript"
></script>
<script
type=
"text/javascript"
src=
"../plantilla/assets/js/plugins/forms/styling/switch.min.js"
></script>
<script
src=
"../plantilla/assets/js/core/libraries/jquery_ui/interactions.min.js"
></script>
<script>
<script
src=
"../plantilla/assets/js/core/libraries/jquery_ui/widgets.min.js"
></script>
$
(
".styled, .multiselect-container input"
).
uniform
({
<script
src=
"../js/lib/sweetalert2.min.js"
type=
"text/javascript"
></script>
radioClass
:
'choice'
<script
src=
"../js/lib/lodash.js"
type=
"text/javascript"
></script>
});
<script
src=
"../js/lib/axios.min.js"
type=
"text/javascript"
></script>
let
table
=
$
(
'#tblAsistenciaPolicias'
).
DataTable
({
<script
src=
"../plantilla/assets/js/plugins/forms/inputs/formatter.min.js"
></script>
"language"
:
{
<script
src=
"../plantilla/assets/js/plugins/forms/selects/select2.min.js"
></script>
"lengthMenu"
:
"Mostrar: _MENU_"
,
<script
src=
"../plantilla/assets/js/plugins/ui/moment/moment.min.js"
></script>
"zeroRecords"
:
" No se encontraron resultados"
,
<script
src=
"../plantilla/assets/js/plugins/pickers/daterangepicker.js"
></script>
"info"
:
" Mostrando del _START_ al _END_ de un total de _TOTAL_ registros"
,
<script
src=
"../js/lib/jquery-ui.multidatespicker.js"
></script>
"infoEmpty"
:
" Mostrando 0 de 0 registros"
,
<script
src=
"../js/pages/monto_policias.js"
type=
"text/javascript"
></script>
"search"
:
"Filtrar:"
,
"loadingRecords"
:
"Cargando..."
,
"processing"
:
'<span style="width:100%;"><img src="http://www.snacklocal.com/images/ajaxload.gif"></span>'
,
"paginate"
:
{
"first"
:
"First"
,
"last"
:
"Last"
,
"next"
:
"Siguiente"
,
"previous"
:
"Anterior"
}
},
// dom: '
<
"datatable-scroll"
t
>
r
<
"datatable-footers"
ip
>
',
// "ajax": {
// type: '
POST
',
// url: "../UsuarioServlet?accion=listarUsuarios",
// data: {
// json: JSON.stringify(json)
// }
// },
// "bSort": false,
"bFilter": false,
// "serverSide": true,
// "processing": true,
// "aaSorting": [],
"ordering": false,
"bLengthChange": false,
"bInfo": false,
"paging": false,
// "iDisplayLength": 20,
"columnDefs": [
{targets: 0, orderable: false, width: "1%", className: "text-center"},
{targets: 1, orderable: false, width: "15%", className: "text-center"},
{targets: 2, orderable: false, width: "12%", className: "text-center"},
{targets: 3, orderable: false, width: "8%", className: "text-center"},
{targets: 4, orderable: false, width: "8%", className: "text-center"},
{targets: 5, orderable: false, width: "10%", className: "text-center"},
{targets: 6, orderable: false, width: "5%", className: "text-center"},
{targets: 7, orderable: false, width: "5%", className: "text-center"},
{targets: 8, orderable: false, width: "5%", className: "text-center"},
{targets: 9, orderable: false, width: "5%", className: "text-center"},
{targets: 10, orderable: false, width: "5%", className: "text-center"},
{targets: 11, orderable: false, width: "5%", className: "text-center"},
{targets: 12, orderable: false, width: "10%", className: "text-center"},
{targets: 13, orderable: false, width: "10%", className: "text-center"},
{targets: 14, orderable: false, width: "5%", className: "text-center"}
]
});
$('
#
extras
-
select
-
all
').on('
click
', function () {
// Check/uncheck all checkboxes in the table
var rows = table.rows({'
search
': '
applied
'}).nodes();
$('
input
[
type
=
"checkbox"
]
', rows).parent().addClass('
checked
')
// debugger
});
</script>
<!--js-->
<!--js-->
</body>
</body>
...
...
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