Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
trismegisto-planilla
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
Luis Gangas
trismegisto-planilla
Commits
671dd3e3
Commit
671dd3e3
authored
Nov 12, 2018
by
Luis Gangas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[EDIT] querys fichaAdministrativa .2
parent
8538c83e
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
25 deletions
+12
-25
workspace.xml
.idea/workspace.xml
+3
-14
FichaLaboralMysqlDAO.java
...va/trismegistoplanilla/mysqldao/FichaLaboralMysqlDAO.java
+9
-9
FichaLaboralServlet.java
...ava/trismegistoplanilla/servlets/FichaLaboralServlet.java
+0
-2
No files found.
.idea/workspace.xml
View file @
671dd3e3
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<project
version=
"4"
>
<project
version=
"4"
>
<component
name=
"ChangeListManager"
>
<component
name=
"ChangeListManager"
>
<list
default=
"true"
id=
"f1229581-2498-4c33-b7b4-f715a5fbe428"
name=
"Default Changelist"
comment=
""
>
<list
default=
"true"
id=
"f1229581-2498-4c33-b7b4-f715a5fbe428"
name=
"Default Changelist"
comment=
""
/>
<change
beforePath=
"$PROJECT_DIR$/.gitignore"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/.gitignore"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/.idea/workspace.xml"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/.idea/workspace.xml"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/CargaFamiliarMysqlDAO.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/CargaFamiliarMysqlDAO.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/ExperienciaLaboralMysqlDAO.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/ExperienciaLaboralMysqlDAO.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/FichaMysqlDAO.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/FichaMysqlDAO.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/MysqlDAOFactory.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/mysqldao/MysqlDAOFactory.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/DetalleLoteFichaAdministrativaServlet.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/DetalleLoteFichaAdministrativaServlet.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/DetalleLoteFichaDocenteServlet.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/DetalleLoteFichaDocenteServlet.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/FichaServlet.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/servlets/FichaServlet.java"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/sqlserverdao/FichaSqlserverDAO.java"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/src/java/trismegistoplanilla/sqlserverdao/FichaSqlserverDAO.java"
afterDir=
"false"
/>
</list>
<ignored
path=
"$PROJECT_DIR$/.tmp/"
/>
<ignored
path=
"$PROJECT_DIR$/.tmp/"
/>
<ignored
path=
"$PROJECT_DIR$/temp/"
/>
<ignored
path=
"$PROJECT_DIR$/temp/"
/>
<ignored
path=
"$PROJECT_DIR$/tmp/"
/>
<ignored
path=
"$PROJECT_DIR$/tmp/"
/>
...
@@ -26,7 +15,7 @@
...
@@ -26,7 +15,7 @@
<session
id=
"1890756217"
>
<session
id=
"1890756217"
>
<usages-collector
id=
"statistics.lifecycle.project"
>
<usages-collector
id=
"statistics.lifecycle.project"
>
<counts>
<counts>
<entry
key=
"project.closed"
value=
"
1
"
/>
<entry
key=
"project.closed"
value=
"
2
"
/>
<entry
key=
"project.open.time.0"
value=
"1"
/>
<entry
key=
"project.open.time.0"
value=
"1"
/>
<entry
key=
"project.opened"
value=
"1"
/>
<entry
key=
"project.opened"
value=
"1"
/>
</counts>
</counts>
...
@@ -131,7 +120,7 @@
...
@@ -131,7 +120,7 @@
<servers
/>
<servers
/>
</component>
</component>
<component
name=
"TimeTrackingManager"
>
<component
name=
"TimeTrackingManager"
>
<option
name=
"totallyTimeSpent"
value=
"
2920
000"
/>
<option
name=
"totallyTimeSpent"
value=
"
3222
000"
/>
</component>
</component>
<component
name=
"ToolWindowManager"
>
<component
name=
"ToolWindowManager"
>
<frame
x=
"0"
y=
"0"
width=
"1920"
height=
"1080"
extended-state=
"0"
/>
<frame
x=
"0"
y=
"0"
width=
"1920"
height=
"1080"
extended-state=
"0"
/>
...
...
src/java/trismegistoplanilla/mysqldao/FichaLaboralMysqlDAO.java
View file @
671dd3e3
...
@@ -68,7 +68,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -68,7 +68,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
int
codigoPersona
=
rsObtenerCodigoPersona
.
getInt
(
"codigoPersona"
);
int
codigoPersona
=
rsObtenerCodigoPersona
.
getInt
(
"codigoPersona"
);
// ACTIVIDAD N° 2
// ACTIVIDAD N° 2
sql
=
"update persona set enlace_alfresco = upper(?) where codigo_persona = ? and estado_registro = 1
"
;
sql
=
"update personal set enlace_alfresco = upper(?) where codper = ? and retirado = 0
"
;
psRegistrarEnlace
=
conexion
.
prepareStatement
(
sql
);
psRegistrarEnlace
=
conexion
.
prepareStatement
(
sql
);
psRegistrarEnlace
.
setString
(
1
,
p
.
getEnlaceAlfresco
());
psRegistrarEnlace
.
setString
(
1
,
p
.
getEnlaceAlfresco
());
...
@@ -115,12 +115,12 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -115,12 +115,12 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
+
" ,estado_registro "
+
" ,estado_registro "
+
") values ( "
+
") values ( "
+
" ? "
+
" ? "
+
" ,STR_TO_DATE(?,'%d/%m/%Y') "
+
" ,STR_TO_DATE(?,'%d/%m/%Y') "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,now() "
+
" ,? "
+
" ,getdate() "
+
" ,1 "
+
" ,1 "
+
")"
;
+
")"
;
...
@@ -154,7 +154,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -154,7 +154,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,? "
+
" ,getdate
() "
+
" ,now
() "
+
" ,1 "
+
" ,1 "
+
")"
;
+
")"
;
...
@@ -178,7 +178,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -178,7 +178,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
case
5
:
// horas
case
5
:
// horas
sql
=
""
sql
=
""
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_a, costo_b, costo_c, observacion, fecha_registro, estado_registro) "
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_a, costo_b, costo_c, observacion, fecha_registro, estado_registro) "
+
"values (?, ?, ?, ?, ?, ?, getdate
(), 1)"
;
+
"values (?, ?, ?, ?, ?, ?, now
(), 1)"
;
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
...
@@ -191,7 +191,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -191,7 +191,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
case
6
:
// mensual
case
6
:
// mensual
sql
=
""
sql
=
""
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_mensual, observacion, fecha_registro, estado_registro) "
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_mensual, observacion, fecha_registro, estado_registro) "
+
"values (?, ?, ?, ?, getdate
(), 1)"
;
+
"values (?, ?, ?, ?, now
(), 1)"
;
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
...
@@ -202,7 +202,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -202,7 +202,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
case
19
:
// administrativo
case
19
:
// administrativo
sql
=
""
sql
=
""
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_mensual, costo_a, costo_b, costo_c, observacion, fecha_registro, estado_registro) "
+
"insert into sueldo_docente (codigo_ficha, codigo_area_cargo_tipo_pago, costo_mensual, costo_a, costo_b, costo_c, observacion, fecha_registro, estado_registro) "
+
"values (?, ?, ?, ?, ?, ?, ?, getdate
(), 1)"
;
+
"values (?, ?, ?, ?, ?, ?, ?, now
(), 1)"
;
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
=
conexion
.
prepareStatement
(
sql
);
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
psRegistrarSueldoDocente
.
setInt
(
1
,
sd
.
getCodigoFicha
());
...
@@ -266,7 +266,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
...
@@ -266,7 +266,7 @@ public class FichaLaboralMysqlDAO implements FichaLaboralDAO {
+
") values ( "
+
") values ( "
+
" ? "
+
" ? "
+
" ,? "
+
" ,? "
+
" ,getdate
() "
+
" ,now
() "
+
" ,? "
+
" ,? "
+
" ,1 "
+
" ,1 "
+
")"
;
+
")"
;
...
...
src/java/trismegistoplanilla/servlets/FichaLaboralServlet.java
View file @
671dd3e3
...
@@ -105,9 +105,7 @@ public class FichaLaboralServlet extends HttpServlet {
...
@@ -105,9 +105,7 @@ public class FichaLaboralServlet extends HttpServlet {
}
else
{
}
else
{
out
.
print
(
jsonValid
);
out
.
print
(
jsonValid
);
}
}
}
}
}
}
private
JSONObject
validarJson
(
HttpServletRequest
request
,
HttpServletResponse
response
,
JSONObject
json
)
throws
ServletException
,
IOException
{
private
JSONObject
validarJson
(
HttpServletRequest
request
,
HttpServletResponse
response
,
JSONObject
json
)
throws
ServletException
,
IOException
{
...
...
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