Compare commits
1 Commits
deletingRe
...
implementi
| Author | SHA1 | Date | |
|---|---|---|---|
| 11626e6efb |
@@ -1,5 +0,0 @@
|
||||
Dockerfile
|
||||
README.md
|
||||
buildspec.yml
|
||||
CONTRIBUTING.md
|
||||
docker-compose.yml
|
||||
@@ -1,2 +0,0 @@
|
||||
Options -Indexes
|
||||
Deny from all
|
||||
@@ -1,52 +0,0 @@
|
||||
# Stage 1 - the build process
|
||||
FROM composer:1.7.1 as build-deps
|
||||
ENV COMPOSER_ALLOW_SUPERUSER 1
|
||||
|
||||
WORKDIR /root
|
||||
|
||||
COPY . .
|
||||
RUN composer install
|
||||
RUN composer test
|
||||
|
||||
# Stage 2 - the production environment
|
||||
FROM ubuntu:16.04
|
||||
|
||||
RUN apt-get -y update && apt-get -y upgrade
|
||||
|
||||
RUN apt-get -y install apache2 \
|
||||
php7.0 \
|
||||
libapache2-mod-php7.0 \
|
||||
php7.0-cli \
|
||||
php7.0-common \
|
||||
php7.0-mbstring \
|
||||
php7.0-gd \
|
||||
php7.0-intl \
|
||||
php7.0-xml \
|
||||
php7.0-mysql \
|
||||
php7.0-mcrypt
|
||||
|
||||
# Enable apache mods
|
||||
RUN a2enmod php7.0
|
||||
RUN a2enmod rewrite
|
||||
|
||||
# Update the PHP.ini file, enable <? ?> tags and quieten logging
|
||||
RUN sed -i "s/short_open_tag = Off/short_open_tag = On/" /etc/php/7.0/apache2/php.ini
|
||||
RUN sed -i "s/error_reporting = .*$/error_reporting = E_ERROR | E_WARNING | E_PARSE/" /etc/php/7.0/apache2/php.ini
|
||||
|
||||
# Manually set up the apache environment variables
|
||||
ENV APACHE_RUN_USER www-data
|
||||
ENV APACHE_RUN_GROUP www-data
|
||||
ENV APACHE_LOG_DIR /var/log/apache2
|
||||
ENV APACHE_LOCK_DIR /var/lock/apache2
|
||||
|
||||
WORKDIR /var/www/site
|
||||
COPY --from=build-deps /root .
|
||||
|
||||
RUN touch logs/app.log
|
||||
RUN chmod 777 logs/app.log
|
||||
|
||||
# Update the default apache site
|
||||
ADD docker/apache-config.conf /etc/apache2/sites-enabled/000-default.conf
|
||||
|
||||
# By default start up apache in the foreground
|
||||
CMD /usr/sbin/apache2ctl -D FOREGROUND
|
||||
@@ -14,9 +14,8 @@ phases:
|
||||
- echo Entered the build phase...
|
||||
- echo Build started on `date`
|
||||
- composer test
|
||||
- sudo docker-compose up --build -d
|
||||
post_build:
|
||||
commands:
|
||||
- echo Entered the post_build phase...
|
||||
- sudo docker-compose down --rmi all -v
|
||||
- echo Build completed on `date`
|
||||
|
||||
|
||||
@@ -1,15 +0,0 @@
|
||||
<VirtualHost *:80>
|
||||
ServerAdmin me@mydomain.com
|
||||
DocumentRoot /var/www/site
|
||||
|
||||
<Directory /var/www/site/>
|
||||
Options Indexes FollowSymLinks MultiViews
|
||||
AllowOverride All
|
||||
Order deny,allow
|
||||
Allow from all
|
||||
</Directory>
|
||||
|
||||
ErrorLog ${APACHE_LOG_DIR}/error.log
|
||||
CustomLog ${APACHE_LOG_DIR}/access.log combined
|
||||
|
||||
</VirtualHost>
|
||||
@@ -1,5 +1,3 @@
|
||||
allow from all
|
||||
|
||||
<IfModule mod_rewrite.c>
|
||||
RewriteEngine On
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
6
api-payroll/public/css/bootstrap.min.css
vendored
6
api-payroll/public/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
@@ -1,243 +0,0 @@
|
||||
body {
|
||||
background-color: #e3e3e3;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.datepicker{
|
||||
color: black;
|
||||
}
|
||||
|
||||
#newViewBody{
|
||||
top:17%;
|
||||
left:1%;
|
||||
width:98%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
#navigation_spot{
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#footer {
|
||||
|
||||
}
|
||||
|
||||
#newViewBody .modal-body{
|
||||
color: #000;
|
||||
border:none;
|
||||
}
|
||||
|
||||
#newViewBody .panel-default{
|
||||
border: 3px solid #4A89A5;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
||||
#newViewBody .panel > .panel-heading {
|
||||
background-image: none;
|
||||
background-color: #4A89A5;
|
||||
color: white;
|
||||
border-radius: 0;
|
||||
}
|
||||
|
||||
#newViewBody .btn-default{
|
||||
border: 2px solid #62655F;
|
||||
background: #F9DFAF;
|
||||
}
|
||||
|
||||
#newViewBody .btn-default:hover{
|
||||
border: 2px solid #62655F;
|
||||
background: #F9DFAF;
|
||||
}
|
||||
|
||||
#newViewBody .alert-success{
|
||||
background: #C6E97C;
|
||||
}
|
||||
|
||||
.modalHeaderError{
|
||||
background-color: #d9534f;
|
||||
}
|
||||
|
||||
|
||||
.modalHeaderSuccess{
|
||||
background-color: #5bc0de;
|
||||
}
|
||||
|
||||
|
||||
.metro{
|
||||
width:auto;
|
||||
height:auto;
|
||||
}
|
||||
.metroBox{
|
||||
margin: 0 auto;
|
||||
width:100%;
|
||||
padding: 0;
|
||||
height:auto;
|
||||
display:table;
|
||||
overflow: hidden;
|
||||
}
|
||||
.metroBox h3{
|
||||
margin-bottom: 0;
|
||||
padding-bottom: 0;
|
||||
}
|
||||
.metroBox a{
|
||||
text-decoration: none;
|
||||
color: #fff;
|
||||
}
|
||||
.boxElement{
|
||||
color: #fff;
|
||||
height:210px;
|
||||
width: 318px;
|
||||
float:left;
|
||||
margin:0 5px 5px 0;
|
||||
padding:0 1% 0 1%;
|
||||
}
|
||||
.boxElement:hover{
|
||||
color: #fff;
|
||||
background: #483D8B;
|
||||
text-decoration: none;
|
||||
}
|
||||
.amarelo{
|
||||
background:#f4c20d;
|
||||
}
|
||||
.vermelho{
|
||||
background:#da542d;
|
||||
}
|
||||
.azul{
|
||||
background:#009bad;
|
||||
}
|
||||
.azulFuerte{
|
||||
background:#5636b0;
|
||||
}
|
||||
.verde{
|
||||
background-color: #009f00;
|
||||
}
|
||||
.violet{
|
||||
background-color: #a400ab;
|
||||
}
|
||||
.iconPanel{
|
||||
font-size: 130px;
|
||||
}
|
||||
@media (max-width: 310px){
|
||||
.boxElement{
|
||||
width: 245px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 311px) and (max-width: 353px){
|
||||
.boxElement{
|
||||
width: 265px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 354px) and (max-width: 365px){
|
||||
.boxElement{
|
||||
width: 320px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 366px) and (max-width: 520px){
|
||||
.boxElement{
|
||||
width: 320px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 521px) and (max-width: 549px){
|
||||
.boxElement{
|
||||
width: 235px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 550px) and (max-width: 590px){
|
||||
.boxElement{
|
||||
width: 250px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 591px) and (max-width: 610px){
|
||||
.boxElement{
|
||||
width: 265px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 611px) and (max-width: 630px){
|
||||
.boxElement{
|
||||
width: 275px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 631px) and (max-width: 655px){
|
||||
.boxElement{
|
||||
width: 280px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 656px) and (max-width: 699px){
|
||||
.boxElement{
|
||||
width: 300px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 700px) and (max-width: 739px){
|
||||
.boxElement{
|
||||
width: 320px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 740px) and (max-width: 769px){
|
||||
.boxElement{
|
||||
width: 340px;
|
||||
}
|
||||
}
|
||||
@media (min-width: 770px) and (max-width: 1230px){
|
||||
.boxElement{
|
||||
width: 280px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.formato_texto_custom{
|
||||
width: 97%;
|
||||
float: left;
|
||||
border: 1px solid #222;
|
||||
padding: 1%;
|
||||
margin: .5%;
|
||||
}
|
||||
|
||||
.cliente_muestra_producto{
|
||||
width: 96%;
|
||||
padding: 1%;
|
||||
margin: 0 1% 2% 1%;
|
||||
}
|
||||
|
||||
textarea{
|
||||
resize: none;
|
||||
}
|
||||
|
||||
#custom-bootstrap-menu.navbar-default .navbar-brand {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default {
|
||||
font-size: 14px;
|
||||
background-color: rgba(27, 35, 78, 1);
|
||||
border-width: 1px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>li>a {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
background-color: rgba(27, 35, 78, 1);
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>li>a:hover,
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>li>a:focus {
|
||||
color: rgba(106, 171, 232, 1);
|
||||
background-color: rgba(27, 35, 78, 1);
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>.active>a,
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>.active>a:hover,
|
||||
#custom-bootstrap-menu.navbar-default .navbar-nav>.active>a:focus {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
background-color: rgba(27, 35, 78, 1);
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle {
|
||||
border-color: #1b234e;
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle:hover,
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle:focus {
|
||||
background-color: #1b234e;
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle .icon-bar {
|
||||
background-color: #1b234e;
|
||||
}
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle:hover .icon-bar,
|
||||
#custom-bootstrap-menu.navbar-default .navbar-toggle:focus .icon-bar {
|
||||
background-color: #1b234e;
|
||||
}
|
||||
@@ -1,81 +0,0 @@
|
||||
body {
|
||||
background: url(../imagenes/grey_background.jpg);
|
||||
background-size: cover;
|
||||
font-family: Montserrat;
|
||||
}
|
||||
@media only screen and (min-device-width: 480px) {
|
||||
body {
|
||||
background: url('../imagenes/grey_background.jpg') no-repeat fixed center center;
|
||||
}
|
||||
}
|
||||
.logo {
|
||||
width: 213px;
|
||||
height: 60px;
|
||||
margin: 30px auto;
|
||||
}
|
||||
.login-block {
|
||||
width: 320px;
|
||||
padding: 20px;
|
||||
background: #fff;
|
||||
border-radius: 5px;
|
||||
border-top: 5px solid #5bc0de;
|
||||
margin: 0 auto;
|
||||
}
|
||||
.login-block h1 {
|
||||
text-align: center;
|
||||
color: #000;
|
||||
font-size: 18px;
|
||||
text-transform: uppercase;
|
||||
margin-top: 0;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.login-block input {
|
||||
width: 100%;
|
||||
height: 42px;
|
||||
box-sizing: border-box;
|
||||
border-radius: 5px;
|
||||
border: 1px solid #ccc;
|
||||
margin-bottom: 20px;
|
||||
font-size: 14px;
|
||||
font-family: Montserrat;
|
||||
padding: 0 20px 0 50px;
|
||||
outline: none;
|
||||
}
|
||||
.login-block input#user {
|
||||
background: #fff url('../imagenes/login_username.png') 20px top no-repeat;
|
||||
background-size: 16px 80px;
|
||||
}
|
||||
.login-block input#user:focus {
|
||||
background: #fff url('../imagenes/login_username.png') 20px bottom no-repeat;
|
||||
background-size: 16px 80px;
|
||||
}
|
||||
.login-block input#password {
|
||||
background: #fff url('../imagenes/login_password.png') 20px top no-repeat;
|
||||
background-size: 16px 80px;
|
||||
}
|
||||
.login-block input#password:focus {
|
||||
background: #fff url('../imagenes/login_password.png') 20px bottom no-repeat;
|
||||
background-size: 16px 80px;
|
||||
}
|
||||
.login-block input:active, .login-block input:focus {
|
||||
border: 1px solid #5bc0de;
|
||||
}
|
||||
.login-block #loginButon {
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
background: #009bad;
|
||||
box-sizing: border-box;
|
||||
border-radius: 5px;
|
||||
border: 1px solid #000;
|
||||
color: #fff;
|
||||
font-weight: bold;
|
||||
text-transform: uppercase;
|
||||
font-size: 14px;
|
||||
font-family: Montserrat;
|
||||
outline: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
#modalLoginErrorHeader{
|
||||
background-color: #d9534f;
|
||||
}
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1,111 +0,0 @@
|
||||
<script src="../js/getBaseUrl.js"></script>
|
||||
<script src="../js/editEmployee.js"></script>
|
||||
|
||||
<form class="form-horizontal" id="editEmployee">
|
||||
<div class="col-md-12">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Edit employee</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmploySearch">Employee</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmploySearch" name="editEmploySearch" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeFirstName">First name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeFirstName" name="editEmployeeFirstName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeMiddleName">Middle name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeMiddleName" name="editEmployeeMiddleName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeLastName">Last name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeLastName" name="editEmployeeLastName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeBirthDate">Birth date</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeBirthDate" name="editEmployeeBirthDate" type="text" class="form-control input-md datepicker">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" id="hidenEmployeeCode">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeCode">Code</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeCode" name="editEmployeeCode" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeEmail">Email</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeeEmail" name="editEmployeeEmail" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeePhone">Phone</label>
|
||||
<div class="col-md-5">
|
||||
<input id="editEmployeePhone" name="editEmployeePhone" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeType">Rol</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="editEmployeeType" id="editEmployeeType">
|
||||
<option>Employee type</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="editEmployeeContractType">Contract type</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="editEmployeeContractType" id="editEmployeeContractType">
|
||||
<option>Contract type</option>
|
||||
<option value="INTERNO">interno</option>
|
||||
<option value="EXTERNO">Externo</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row col-md-offset-6">
|
||||
<div class="form-group">
|
||||
<a href="#" class="btn btn-lg btn-success " onclick="updateEmployee();">Update</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
@@ -1,232 +0,0 @@
|
||||
<?php
|
||||
session_start();
|
||||
|
||||
if(!isset($_SESSION['userName'])){
|
||||
header("Location: ./login.php");
|
||||
exit();
|
||||
}
|
||||
?>
|
||||
|
||||
<!-- Latest compiled and minified CSS -->
|
||||
<link rel="stylesheet" href="../css/bootstrap.min.css">
|
||||
|
||||
<!-- jQuery library -->
|
||||
<script src="../js/jquery.min.js"></script>
|
||||
|
||||
<!-- Latest compiled JavaScript -->
|
||||
<script src="../js/bootstrap.min.js"></script>
|
||||
|
||||
<body>
|
||||
<div class="col-md-12" id="navigation_spot">
|
||||
<!-- NavBar-->
|
||||
<div id="custom-bootstrap-menu" class="navbar navbar-default " role="navigation">
|
||||
<div class="container-fluid">
|
||||
<div class="navbar-header"><a class="navbar-brand" href="#"></a>
|
||||
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-menubuilder"><span class="sr-only">Toggle navigation</span><span class="icon-bar"></span><span class="icon-bar"></span><span class="icon-bar"></span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="collapse navbar-collapse navbar-menubuilder">
|
||||
<ul class="nav navbar-nav navbar-left" id="nevatation-options">
|
||||
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><span class="glyphicon glyphicon-user"></span> Employees<span class="caret"></span></a>
|
||||
<ul class="dropdown-menu">
|
||||
<li><a href="#" data-nav_accion="newEmployee.php"> New employee</a></li>
|
||||
<li><a href="#" data-nav_accion="editEmployee.php"> Modify employee</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
|
||||
<li>
|
||||
<a href="#" data-nav_accion="registerWorkDays.php" ><span class="glyphicon glyphicon-tasks"></span> Management</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#" onclick="loadView();"><span class="glyphicon glyphicon-wrench"></span> Change password</a>
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li>
|
||||
<a href="#" onclick="logout();"><span class="fa fa-fw fa-power-off"></span> logout</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-12" id="newViewBody"></div>
|
||||
|
||||
<!--
|
||||
=================================================================================
|
||||
Modals for errors encountered by ajax
|
||||
=================================================================================
|
||||
-->
|
||||
|
||||
<div id="modalErrorInternetConnection" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>Please verify your internet connection and try again.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalError404" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>Unable to find the requested url in the sever.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalError500" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>The server has encountered an internal error, please try again later.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalErrorParsererror" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>The response from the sever wasn't a proper JSON format</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalErrorTimeout" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>The request timeout, please try again or verify your connection.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalErrorOther" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>An unknown error occurred.</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--
|
||||
=================================================================================
|
||||
Generic response modals
|
||||
=================================================================================
|
||||
-->
|
||||
|
||||
<div id="modalServerResponseError" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderError">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">An error has occurred</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p id="modalResponseError"></p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalServerResponseSuccess" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<div class="modal-content">
|
||||
<div class="modal-header modalHeaderSuccess" id="modalHeaderServerResponseSuccess">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title">Success</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p id="serverResponseSuccess"></p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
<script src="../js/getBaseUrl.js"></script>
|
||||
<script src="../js/landing.js"></script>
|
||||
<script src="../js/bootstrap-datepicker.min.js"></script>
|
||||
<script src="../js/typeahead.bundle.js"></script>
|
||||
|
||||
<link href="../css/bootstrap-datepicker.min.css" rel="stylesheet">
|
||||
<link href="../css/landing.css" rel="stylesheet">
|
||||
@@ -1,54 +0,0 @@
|
||||
<?php
|
||||
session_start();
|
||||
|
||||
if(isset($_SESSION['userName'])){
|
||||
header("Location: ./landing.php");
|
||||
exit();
|
||||
}
|
||||
?>
|
||||
|
||||
<!-- Latest compiled and minified CSS -->
|
||||
<link rel="stylesheet" href="../css/bootstrap.min.css">
|
||||
|
||||
<!-- jQuery library -->
|
||||
<script src="../js/jquery.min.js"></script>
|
||||
|
||||
<!-- Latest compiled JavaScript -->
|
||||
<script src="../js/bootstrap.min.js"></script>
|
||||
|
||||
<link href='http://fonts.googleapis.com/css?family=Montserrat:400,700' rel='stylesheet' type='text/css'>
|
||||
<div class="container">
|
||||
<div class="logo"></div>
|
||||
<div class="login-block">
|
||||
<form action="" method="post" name="Login_Form" class="login">
|
||||
<h1>Login</h1>
|
||||
<input type="text" value="" placeholder="User" id="userName" name="user" required="" autofocus=""/>
|
||||
<input type="password" value="" placeholder="Password" id="password" name="password" required=""/>
|
||||
<a href="#" class="btn btn-lg btn-warning btn-default" id="loginButon" name="login" value="Login" onclick="processLogin();">Login</a>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="modalLoginError" class="modal fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
|
||||
<!-- Modal content-->
|
||||
<div class="modal-content">
|
||||
<div class="modal-header" id="modalLoginErrorHeader">
|
||||
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||
<h4 class="modal-title"><center>Ha ocurrido un error</center></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p id="modalLoginErrorBody"></p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="../js/login.js"></script>
|
||||
<script src="../js/getBaseUrl.js"></script>
|
||||
<link href="../css/login.css" rel="stylesheet">
|
||||
@@ -1,93 +0,0 @@
|
||||
<script src="../js/newEmployee.js"></script>
|
||||
<script src="../js/getBaseUrl.js"></script>
|
||||
|
||||
<form class="form-horizontal" id="newEmployeeForm">
|
||||
<div class="col-md-12">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">New employee</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeFirstName">First name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeeFirstName" name="newEmployeeFirstName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeMiddleName">Middle name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeeMiddleName" name="newEmployeeMiddleName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeLastName">Last name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeeLastName" name="newEmployeeLastName" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeBirthDate">Birth date</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeeBirthDate" name="newEmployeeBirthDate" type="text" class="form-control input-md datepicker">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeEmail">Email</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeeEmail" name="newEmployeeEmail" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeePhone">Phone</label>
|
||||
<div class="col-md-5">
|
||||
<input id="newEmployeePhone" name="newEmployeePhone" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="newEmployeeType">Rol</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="newEmployeeType" id="newEmployeeType">
|
||||
<option>Employee type</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="NewEmpployyContractType">Contract type</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="NewEmpployyContractType" id="NewEmpployyContractType">
|
||||
<option>Contract type</option>
|
||||
<option value="INTERNO">interno</option>
|
||||
<option value="EXTERNO">Externo</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row col-md-offset-6">
|
||||
<div class="form-group">
|
||||
<a href="#" class="btn btn-lg btn-success " onclick="saveNewEmployee();">Create</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
@@ -1,142 +0,0 @@
|
||||
<script src="../js/getBaseUrl.js"></script>
|
||||
<script src="../js/registerWorkDays.js"></script>
|
||||
|
||||
<form class="form-horizontal" id="workDaysForm">
|
||||
<div class="col-md-12">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Managing work days</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysSearchEmployee">Search employee</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysSearchEmployee" name="workDaysSearchEmployee" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysSearchByDate">Search by date</label>
|
||||
<div class="col-md-2">
|
||||
<input id="workDaysSearchByDate" name="workDaysSearchByDate" type="text" class="form-control input-md datepicker">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="registerWorkDaysEmployeeInfo" class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeName">Name</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeName" name="workDaysEmployeeName" type="text" class="form-control input-md" disabled>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeRol">Rol</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="workDaysEmployeeRol" id="workDaysEmployeeRol" disabled>
|
||||
<option></option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeContractType">Contract type</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="workDaysEmployeeContractType" id="workDaysEmployeeContractType" disabled>
|
||||
<option>Contract type</option>
|
||||
<option value="INTERNO">interno</option>
|
||||
<option value="EXTERNO">Externo</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeWorkedDay">Date</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeWorkedDay" name="workDaysEmployeeWorkedDay" type="text" class="form-control input-md datepicker">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeDeliveries">Deliveries</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeDeliveries" name="workDaysEmployeeDeliveries" type="number" value="0" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeePerformedRol">Performed rol</label>
|
||||
<div class="col-md-5">
|
||||
<select class="form-control input-md" name="workDaysEmployeePerformedRol" id="workDaysEmployeePerformedRol" disabled>
|
||||
<option>Employee type</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="registerWorkDaysEmployeeSalary" class="col-md-6">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeSalaryRaw">Raw</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeSalaryRaw" name="workDaysEmployeeSalaryRaw" type="text" class="form-control input-md" disabled>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeSalaryTaxes">Taxes</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeSalaryTaxes" name="workDaysEmployeeSalaryTaxes" type="text" class="form-control input-md" disabled>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeSalaryFinal">Final</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeSalaryFinal" name="workDaysEmployeeSalaryFinal" type="text" class="form-control input-md" disabled>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="workDaysEmployeeSalaryVouchers">Vouchers</label>
|
||||
<div class="col-md-5">
|
||||
<input id="workDaysEmployeeSalaryVouchers" name="workDaysEmployeeSalaryVouchers" type="text" class="form-control input-md" disabled>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row" id="hidenEmployeeCodeForWorkDays">
|
||||
<div class="form-group">
|
||||
<label class="col-md-4 control-label" for="hidenEmployeeCodeForWorkDaysCode">Code</label>
|
||||
<div class="col-md-5">
|
||||
<input id="hidenEmployeeCodeForWorkDaysCode" name="hidenEmployeeCodeForWorkDaysCode" type="text" class="form-control input-md">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row col-md-offset-6">
|
||||
<div class="form-group">
|
||||
<a href="#" class="btn btn-lg btn-success " onclick="processSaveActionWorkDay();">Save</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.6 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.8 KiB |
File diff suppressed because one or more lines are too long
7
api-payroll/public/js/bootstrap.min.js
vendored
7
api-payroll/public/js/bootstrap.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -1,180 +0,0 @@
|
||||
/**
|
||||
* Bootstrapping the starting actions for the module
|
||||
*/
|
||||
$(document).ready(function(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
loadEmployeeTypes();
|
||||
|
||||
$('.datepicker').datepicker({
|
||||
format: "yyyy/mm/dd",
|
||||
autoclose: true
|
||||
});
|
||||
|
||||
// Not to be edited
|
||||
$("#hidenEmployeeCode").hide();
|
||||
|
||||
// Setting up bloodhound typeahead
|
||||
let employeesList = new Bloodhound({
|
||||
datumTokenizer: Bloodhound.tokenizers.obj.whitespace("name"),
|
||||
queryTokenizer: Bloodhound.tokenizers.whitespace,
|
||||
remote: {
|
||||
'cache': false,
|
||||
url: baseUrl + '/api/employee/find',
|
||||
|
||||
replace: function(url, uriEncodedQuery) {
|
||||
|
||||
return url + '/' + uriEncodedQuery
|
||||
|
||||
},
|
||||
wildcard: '%QUERY',
|
||||
filter: function (data) {
|
||||
return data;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
employeesList.initialize();
|
||||
|
||||
$("#editEmploySearch").typeahead({
|
||||
hint: true,
|
||||
highlight: true,
|
||||
minLength: 3
|
||||
},
|
||||
{
|
||||
name: "result",
|
||||
displayKey: "fullName",
|
||||
source: employeesList.ttAdapter()
|
||||
}).bind("typeahead:selected", function(obj, datum, name) {
|
||||
$(this).data("id", datum.code);
|
||||
loadEmployeeData(datum.code);
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* Loads the the employee types into their select option
|
||||
*/
|
||||
function loadEmployeeTypes(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/types',
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$(data).each(function(i,v){
|
||||
$('#editEmployeeType').append(
|
||||
'<option value="' + v.id + '">'+ v.name + '</option>'
|
||||
);
|
||||
});
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Searches the employee data by its employee code and loads it
|
||||
* into the form to be edited and updated
|
||||
*
|
||||
* @param code string
|
||||
*/
|
||||
function loadEmployeeData(code){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/code/' + code,
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$('#editEmployeeFirstName').val(data['firstName']);
|
||||
$('#editEmployeeMiddleName').val(data['middleName']);
|
||||
$('#editEmployeeLastName').val(data['lastName']);
|
||||
$('#editEmployeeBirthDate').val(data['birthDate']);
|
||||
$('#editEmployeeCode').val(data['code']);
|
||||
$('#editEmployeeEmail').val(data['email']);
|
||||
$('#editEmployeePhone').val(data['phone']);
|
||||
$('#editEmployeeType').val(data['idEmployeeType']);
|
||||
$('#editEmployeeContractType').val(data['contractType']);
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function updateEmployee(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
let parameters = {
|
||||
"firstName":$('#editEmployeeFirstName').val(),
|
||||
"middleName":$('#editEmployeeMiddleName').val(),
|
||||
"lastName":$('#editEmployeeLastName').val(),
|
||||
"birthDate":$('#editEmployeeBirthDate').val(),
|
||||
"code":$('#editEmployeeCode').val(),
|
||||
"email":$('#editEmployeeEmail').val(),
|
||||
"phone":$('#editEmployeePhone').val(),
|
||||
"idEmployeeType":$('#editEmployeeType').val(),
|
||||
"contractType":$('#editEmployeeContractType').val()
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee',
|
||||
type: 'PUT',
|
||||
dataType: 'json',
|
||||
data: parameters,
|
||||
success:function(data){
|
||||
$('#modalServerResponseSuccess').modal('show');
|
||||
document.getElementById('serverResponseSuccess').innerHTML = 'The employee ' + data['fullName'] + ' has been updated.';
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
/**
|
||||
* Returns the entry point url for the system, this url will be used
|
||||
* to access both the api and the static resources
|
||||
*
|
||||
* @returns {string}
|
||||
*/
|
||||
function getbaseUrl(){
|
||||
var url = window.location.href;
|
||||
return url.substring(0, url.indexOf('/html/'));
|
||||
}
|
||||
2
api-payroll/public/js/jquery.min.js
vendored
2
api-payroll/public/js/jquery.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -1,77 +0,0 @@
|
||||
/**
|
||||
* Destorys the session for the current user and redirects
|
||||
* back to the login form
|
||||
*/
|
||||
function logout() {
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/session/logout',
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
window.location.replace(baseUrl + '/html/login.php');
|
||||
},
|
||||
error:function(x,e) {
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalError500').modal('show');
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modal_error_otro').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Entry point for loading elements from the navatation var, this functuion
|
||||
* will filter the junk clicks that have landed in a dropdown menu and pass
|
||||
* only the ones containing an action to the actual view loader
|
||||
*/
|
||||
$('#nevatation-options li a').click(function(){
|
||||
|
||||
let view = $(this).data('nav_accion');
|
||||
|
||||
if (view != "#" && view != undefined) {
|
||||
loadView(view);
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* Will fetch the html of the desired view and load it into the landing page
|
||||
*
|
||||
* @param requestedView string
|
||||
*/
|
||||
function loadView(requestedView){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/html/' + requestedView,
|
||||
type: 'get',
|
||||
success:function(data){
|
||||
$("#newViewBody").hide().html(data).show('slow');
|
||||
},
|
||||
error:function(x,e) {
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalError500').modal('show');
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modal_error_otro').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
@@ -1,47 +0,0 @@
|
||||
/**
|
||||
* Maps the enter key to the login action
|
||||
*/
|
||||
$(document).keypress(function(e) {
|
||||
if(e.which == 13) {
|
||||
processLogin();
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* Takes the input from the username and password fields and send theem to the backend
|
||||
* to be validated
|
||||
*
|
||||
* The response from the api will contain a status that will determine if the login was
|
||||
* successful or not and a message that will contain feedback which can be used to
|
||||
* display errors to the user
|
||||
*/
|
||||
function processLogin() {
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
let parameters = {
|
||||
"userName":$('#userName').val(),
|
||||
"password":$('#password').val()
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/session/login',
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
data: parameters,
|
||||
success:function(data){
|
||||
if(data["status"] == "success"){
|
||||
window.location.replace(baseUrl + '/html/landing.php');
|
||||
|
||||
}else if(data["status"] == "success" || (data["status"] === undefined)){
|
||||
$('#modalLoginError').modal('show');
|
||||
document.getElementById('modalLoginErrorBody').innerHTML = "The server didn't respond in time, please try again or refresh this page.";
|
||||
}
|
||||
},
|
||||
error:function(x) {
|
||||
if (x.status==500){
|
||||
$('#modalLoginError').modal('show');
|
||||
document.getElementById('modalLoginErrorBody').innerHTML = "The user or password didnt match, please try again";
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
@@ -1,94 +0,0 @@
|
||||
/**
|
||||
* Bootstrapping the starting actions for the module
|
||||
*/
|
||||
$(document).ready(function(){
|
||||
loadEmployeeTypes();
|
||||
|
||||
$('.datepicker').datepicker({
|
||||
format: "yyyy/mm/dd",
|
||||
autoclose: true
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
* Loads the the enmployee types into their select option
|
||||
*/
|
||||
function loadEmployeeTypes(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/types',
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$(data).each(function(i,v){
|
||||
$('#newEmployeeType').append(
|
||||
'<option value="' + v.id + '">'+ v.name + '</option>'
|
||||
);
|
||||
});
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function saveNewEmployee(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
let parameters = {
|
||||
"firstName":$('#newEmployeeFirstName').val(),
|
||||
"middleName":$('#newEmployeeMiddleName').val(),
|
||||
"lastName":$('#newEmployeeLastName').val(),
|
||||
"birthDate":$('#newEmployeeBirthDate').val(),
|
||||
"email":$('#newEmployeeEmail').val(),
|
||||
"phone":$('#newEmployeePhone').val(),
|
||||
"idEmployeeType":$('#newEmployeeType').val(),
|
||||
"contractType":$('#NewEmpployyContractType').val()
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee',
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
data: parameters,
|
||||
success:function(data){
|
||||
$('#modalServerResponseSuccess').modal('show');
|
||||
document.getElementById('serverResponseSuccess').innerHTML = 'The employee ' + data['fullName'] + ' has been created with the code ' + data['employeeCode'];
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
@@ -1,359 +0,0 @@
|
||||
/**
|
||||
* Bootstrapping the starting actions for the module
|
||||
*/
|
||||
$(document).ready(function(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
loadEmployeeTypesForWorkDays();
|
||||
|
||||
$('.datepicker').datepicker({
|
||||
format: "yyyy-mm-dd",
|
||||
autoclose: true
|
||||
});
|
||||
|
||||
// Not to be edited
|
||||
$("#hidenEmployeeCodeForWorkDays").hide();
|
||||
|
||||
// Setting up bloodhound typeahead
|
||||
let employeesList = new Bloodhound({
|
||||
datumTokenizer: Bloodhound.tokenizers.obj.whitespace("name"),
|
||||
queryTokenizer: Bloodhound.tokenizers.whitespace,
|
||||
remote: {
|
||||
'cache': false,
|
||||
url: baseUrl + '/api/employee/find',
|
||||
|
||||
replace: function(url, uriEncodedQuery) {
|
||||
|
||||
return url + '/' + uriEncodedQuery
|
||||
|
||||
},
|
||||
wildcard: '%QUERY',
|
||||
filter: function (data) {
|
||||
return data;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
employeesList.initialize();
|
||||
|
||||
$("#workDaysSearchEmployee").typeahead({
|
||||
hint: true,
|
||||
highlight: true,
|
||||
minLength: 3
|
||||
},
|
||||
{
|
||||
name: "result",
|
||||
displayKey: "fullName",
|
||||
source: employeesList.ttAdapter()
|
||||
}).bind("typeahead:selected", function(obj, datum, name) {
|
||||
$(this).data("id", datum.code);
|
||||
|
||||
loadEmployeeDataForWorkDays(datum.code);
|
||||
validateEmployeeCanDoOtherRoles(datum.code);
|
||||
loadSalaryDetails(datum.code);
|
||||
$('#hidenEmployeeCodeForWorkDaysCode').val(datum.code); // For future reference
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
/**
|
||||
* Loads the the employee types into their select option
|
||||
*/
|
||||
function loadEmployeeTypesForWorkDays(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/types',
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$(data).each(function(i,v){
|
||||
$('#workDaysEmployeeRol').append(
|
||||
'<option value="' + v.id + '">'+ v.name + '</option>'
|
||||
);
|
||||
|
||||
$('#workDaysEmployeePerformedRol').append(
|
||||
'<option value="' + v.id + '">'+ v.name + '</option>'
|
||||
);
|
||||
});
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Searches the employee data by its employee code and loads it
|
||||
* into the form to be edited and saved
|
||||
*
|
||||
* @param code string
|
||||
*/
|
||||
function loadEmployeeDataForWorkDays(code){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/code/' + code,
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
let fullName = data['firstName'] + ' ' + data['middleName'] + ' ' + data['lastName'];
|
||||
|
||||
$('#workDaysEmployeeName').val(fullName);
|
||||
$('#workDaysEmployeeRol').val(data['idEmployeeType']);
|
||||
$('#workDaysEmployeePerformedRol').val(data['idEmployeeType']);
|
||||
$('#workDaysEmployeeContractType').val(data['contractType']);
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Based on the employee code determines their type to decide if
|
||||
* they should be able to cover for other roles or not
|
||||
*
|
||||
* @param code string
|
||||
*/
|
||||
function validateEmployeeCanDoOtherRoles(code){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/type/' + code,
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
if(data == 3){
|
||||
$("#workDaysEmployeePerformedRol").prop('disabled', false);
|
||||
}
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function loadSalaryDetails(code){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/salary/' + code,
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$('#workDaysEmployeeSalaryRaw').val(data['raw']);
|
||||
$('#workDaysEmployeeSalaryTaxes').val(data['taxes']);
|
||||
$('#workDaysEmployeeSalaryFinal').val(data['real']);
|
||||
$('#workDaysEmployeeSalaryVouchers').val(data['vouchers']);
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Bootstraper for the save action
|
||||
*
|
||||
* If the search by date function has been used it's then assumed that the
|
||||
* desired action is to update else the function will attempt to create a new
|
||||
* record for the worked day
|
||||
*/
|
||||
function processSaveActionWorkDay(){
|
||||
if($('#workDaysSearchByDate').val() === ''){
|
||||
saveNewWorkDay();
|
||||
}else {
|
||||
updateNewWorkDay();
|
||||
}
|
||||
}
|
||||
|
||||
function saveNewWorkDay(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
let parameters = {
|
||||
"code":$('#hidenEmployeeCodeForWorkDaysCode').val(),
|
||||
"idEmployeeTypePerformed":$('#workDaysEmployeePerformedRol').val(),
|
||||
"deliveries":$('#workDaysEmployeeDeliveries').val(),
|
||||
"date":$('#workDaysEmployeeWorkedDay').val(),
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/workday',
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
data: parameters,
|
||||
success:function(data){
|
||||
$('#modalServerResponseSuccess').modal('show');
|
||||
document.getElementById('serverResponseSuccess').innerHTML = data['message'];
|
||||
loadSalaryDetails($('#hidenEmployeeCodeForWorkDaysCode').val());
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function updateNewWorkDay(){
|
||||
let baseUrl = getbaseUrl();
|
||||
|
||||
let parameters = {
|
||||
"code":$('#hidenEmployeeCodeForWorkDaysCode').val(),
|
||||
"idEmployeeTypePerformed":$('#workDaysEmployeePerformedRol').val(),
|
||||
"deliveries":$('#workDaysEmployeeDeliveries').val(),
|
||||
"date":$('#workDaysEmployeeWorkedDay').val(),
|
||||
};
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/workday',
|
||||
type: 'PUT',
|
||||
dataType: 'json',
|
||||
data: parameters,
|
||||
success:function(data){
|
||||
$('#modalServerResponseSuccess').modal('show');
|
||||
document.getElementById('serverResponseSuccess').innerHTML = data['message'];
|
||||
loadSalaryDetails($('#hidenEmployeeCodeForWorkDaysCode').val());
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* If the search by date field is changed from its default empty status it'll
|
||||
* load the data of the given work day and enable the update mode
|
||||
*/
|
||||
$('#workDaysSearchByDate').on("change", function(data){
|
||||
let baseUrl = getbaseUrl();
|
||||
let date = $(this).val();
|
||||
let code = $('#hidenEmployeeCodeForWorkDaysCode').val();
|
||||
|
||||
// The employee hasn't been picked
|
||||
if (code === ''){
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = 'Please select an employee in the search form first.';
|
||||
return false; // Exits the function
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
url: baseUrl + '/api/employee/salary/date/' + date + '/code/' + code,
|
||||
type: 'GET',
|
||||
dataType: 'json',
|
||||
success:function(data){
|
||||
$('#workDaysEmployeeRol').val(data['idEmployeeType']);
|
||||
$('#workDaysEmployeeContractType').val(data['contractType']);
|
||||
$('#workDaysEmployeeWorkedDay').val(date);
|
||||
$('#workDaysEmployeeDeliveries').val(data['deliveries']);
|
||||
$('#workDaysEmployeePerformedRol').val(data['idEmployeeTypePerformed']);
|
||||
},
|
||||
error:function(x,e) {
|
||||
let responseText = $.parseJSON(x["responseText"]);
|
||||
|
||||
if (x.status==0) {
|
||||
$('#modalErrorInternetConnection').modal('show');
|
||||
} else if(x.status==404) {
|
||||
$('#modalError404').modal('show');
|
||||
} else if(x.status==500) {
|
||||
$('#modalServerResponseError').modal('show');
|
||||
document.getElementById('modalResponseError').innerHTML = responseText['message'];
|
||||
} else if(e=='parsererror') {
|
||||
$('#modalErrorParsererror').modal('show');
|
||||
} else if(e=='timeout'){
|
||||
$('#modalErrorTimeout').modal('show');
|
||||
} else {
|
||||
$('#modalErrorOther').modal('show');
|
||||
}
|
||||
},
|
||||
});
|
||||
});
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,6 @@
|
||||
<?php
|
||||
namespace App\Application;
|
||||
|
||||
use Exception;
|
||||
use phpDocumentor\Reflection\Types\Integer;
|
||||
|
||||
class EmployeeApplication{
|
||||
@@ -16,13 +15,12 @@ class EmployeeApplication{
|
||||
$this->cryptographyService = $cryptographyService;
|
||||
$this->pdo = $mysql;
|
||||
$this->asserts = $asserts;
|
||||
|
||||
$this->databaseSelectQueryErrorMessage = 'There was an error inserting the record.';
|
||||
}
|
||||
|
||||
/**
|
||||
* A list of the types of employee used in the system
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function listEmployeeTypes(){
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
@@ -36,16 +34,11 @@ class EmployeeApplication{
|
||||
$results = $stmt->fetchAll();
|
||||
|
||||
if(!$results){
|
||||
throw new Exception("The types of employees could not be found..");
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
$employeeTypes = array();
|
||||
foreach($results as $row){
|
||||
$employeeTypes[] = array('id' => (int)$row['id'], 'name' => $row['name']);
|
||||
}
|
||||
|
||||
return $employeeTypes;
|
||||
return $results;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -56,15 +49,13 @@ class EmployeeApplication{
|
||||
* @param $email string
|
||||
* @param $phone string
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function saveNewPerson($firstName, $middleName, $lastName, $birthDate, $email, $phone){
|
||||
$this->asserts->isNotEmpty($firstName, "The first name can't be empty.");
|
||||
$this->asserts->isNotEmpty($middleName, "The middle name can't be empty.");
|
||||
$this->asserts->isNotEmpty($birthDate, "The birth date can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($birthDate, "The birth date can't be in the future.");
|
||||
$this->asserts->isNotEmpty($email, "The email can't be empty.");
|
||||
$this->asserts->isNotEmpty($phone, "The phone number can't be empty.");
|
||||
$this->asserts->firstName($firstName);
|
||||
$this->asserts->middleName($middleName);
|
||||
$this->asserts->birthDate($birthDate);
|
||||
$this->asserts->email($email);
|
||||
$this->asserts->phone($phone);
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("INSERT INTO persons (firstName, middleName, lastName, birthDate, email, phone)
|
||||
@@ -91,13 +82,8 @@ class EmployeeApplication{
|
||||
* @param $code string
|
||||
* @param $contractType string
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
function savePersonAsEmployee($idEmployeeType, $idPerson, $code, $contractType){
|
||||
$this->asserts->higherThanZero($idEmployeeType, "idEmployeeType must be higher than 0");
|
||||
$this->asserts->higherThanZero($idPerson, "idPerson must be higher than 0");
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
$this->asserts->isNotEmpty($contractType, "The contract type can't be empty.");
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("INSERT INTO employees (idEmployeeType, idPerson, code, contractType)
|
||||
VALUES (:idEmployeeType, :idPerson, :code, :contractType)");
|
||||
@@ -120,43 +106,28 @@ class EmployeeApplication{
|
||||
/**
|
||||
* @param $requestData object
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function saveNewEmployee($requestData){
|
||||
// Getting and validating the data
|
||||
$firstName = $requestData['firstName'];
|
||||
$this->asserts->isNotEmpty($firstName, "The first name can't be empty.");
|
||||
$this->asserts->isString($firstName, "The first name must be a string.");
|
||||
$this->asserts->betweenLength($firstName, 1, 50, "The first name must have a length between 1 and 50 characters.");
|
||||
$this->asserts->firstName($firstName);
|
||||
|
||||
$middleName = $requestData['middleName'];
|
||||
$this->asserts->isNotEmpty($middleName, "The middle name can't be empty.");
|
||||
$this->asserts->isString($middleName, "The middle name must be a string.");
|
||||
$this->asserts->betweenLength($middleName, 1, 50, "The middle name must have a length between 1 and 50 characters.");
|
||||
$this->asserts->middleName($middleName);
|
||||
|
||||
$lastName = isset($requestData['lastName'])
|
||||
? $requestData['lastName']
|
||||
: null;
|
||||
$lastName = isset($requestData['lastName']) ? $requestData['lastName'] : null;
|
||||
|
||||
$birthDate = $requestData['birthDate'];
|
||||
$this->asserts->isNotEmpty($birthDate, "The birth date can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($birthDate, "The birth date can't be in the future.");
|
||||
$this->asserts->birthDate($birthDate);
|
||||
|
||||
$email = $requestData['email'];
|
||||
$this->asserts->isNotEmpty($email, "The email can't be empty.");
|
||||
$this->asserts->betweenLength($email, 1, 100, "The middle name must have a length between 1 and 100 characters.");
|
||||
$this->asserts->isEmail($email, "The email isn't in a correct format");
|
||||
$this->asserts->email($email);
|
||||
|
||||
$phone = $requestData['phone'];
|
||||
$this->asserts->isNotEmpty($phone, "The phone number can't be empty.");
|
||||
$this->asserts->betweenLength($phone, 10, 10, "The phone number must be 10 digits without special characters.");
|
||||
$this->asserts->phone($phone);
|
||||
|
||||
$idEmployeeType = $requestData{'idEmployeeType'};
|
||||
$this->asserts->higherThanZero($idEmployeeType, 'idEmployeeType must be higher than zero.');
|
||||
|
||||
$contractType = $requestData{'contractType'};
|
||||
$this->asserts->isNotEmpty($contractType, "The contract type can't be empty.");
|
||||
$this->asserts->existInArray($contractType, $this->settings['contractTypes'], 'The contract type is not a valid one.');
|
||||
|
||||
// Encrypting the sensitive data
|
||||
$securedFirstName = $this->cryptographyService->encryptString($firstName);
|
||||
@@ -191,11 +162,8 @@ class EmployeeApplication{
|
||||
/**
|
||||
* @param $idEmployee
|
||||
* @return Integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function getIdPersonByIdEmployee($idEmployee){
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
COALESCE((SELECT
|
||||
idPerson
|
||||
@@ -208,7 +176,7 @@ class EmployeeApplication{
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("An error occurred while trying to find the person associated with the employee..");
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
@@ -216,13 +184,10 @@ class EmployeeApplication{
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $code string
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
* @param $code
|
||||
* @return mixed
|
||||
*/
|
||||
function getIdEmployeeTypeByCode($code){
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT COALESCE((SELECT
|
||||
et.id
|
||||
FROM
|
||||
@@ -235,35 +200,7 @@ class EmployeeApplication{
|
||||
$stmt->execute(array(':code' => $code));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("The employee could not be found.");
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results[0]['id'];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $code string
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function getIdEmployeeByCode($code){
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
COALESCE((SELECT
|
||||
id
|
||||
FROM
|
||||
employees
|
||||
WHERE
|
||||
code = :code),
|
||||
0) AS id;
|
||||
");
|
||||
|
||||
$stmt->execute(array(':code' => $code));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("The employee could not be found.");
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
@@ -275,22 +212,16 @@ class EmployeeApplication{
|
||||
*
|
||||
* @param $idEmployee
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function getEmployeeDataById($idEmployee){
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
e.id AS idEmployee,
|
||||
p.id AS idPerson,
|
||||
p.firstName,
|
||||
p.middleName,
|
||||
IFNULL(p.lastName, '') AS lastName,
|
||||
p.birthDate,
|
||||
p.email,
|
||||
p.phone,
|
||||
e.code,
|
||||
e.idEmployeeType,
|
||||
e.contractType
|
||||
FROM
|
||||
employees e
|
||||
@@ -302,7 +233,7 @@ class EmployeeApplication{
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("The employee could not be found.");
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
@@ -315,15 +246,11 @@ class EmployeeApplication{
|
||||
*
|
||||
* @param $idEmployee
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function proxyGetEmployeeDataById($idEmployee){
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$employeeData = $this->getEmployeeDataById($idEmployee);
|
||||
|
||||
$response = array(
|
||||
"idEmployee" => (int)$employeeData['idEmployee'],
|
||||
"idPerson" => (int)$employeeData['idPerson'],
|
||||
"firstName" => $this->cryptographyService->decryptString($employeeData['firstName']),
|
||||
"middleName" => $this->cryptographyService->decryptString($employeeData['middleName']),
|
||||
@@ -332,11 +259,9 @@ class EmployeeApplication{
|
||||
? $this->cryptographyService->decryptString($employeeData['lastName'])
|
||||
: '',
|
||||
|
||||
"birthDate" => $employeeData['birthDate'],
|
||||
"email" => $this->cryptographyService->decryptString($employeeData['email']),
|
||||
"phone" => $employeeData['phone'],
|
||||
"code" => $employeeData['code'],
|
||||
"idEmployeeType" => $employeeData['idEmployeeType'],
|
||||
"contractType" => $employeeData['contractType']
|
||||
|
||||
);
|
||||
@@ -344,19 +269,6 @@ class EmployeeApplication{
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $code string
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function getEmployeeDataByCode($code){
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
|
||||
return $this->proxyGetEmployeeDataById($idEmployee);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $idPerson integer
|
||||
* @param $firstName binary
|
||||
@@ -367,14 +279,6 @@ class EmployeeApplication{
|
||||
* @param $phone string
|
||||
*/
|
||||
function updatePerson($idPerson, $firstName, $middleName, $lastName, $birthDate, $email, $phone){
|
||||
$this->asserts->higherThanZero($idPerson, "idPerson must be higher than 0");
|
||||
$this->asserts->isNotEmpty($firstName, "The first name can't be empty.");
|
||||
$this->asserts->isNotEmpty($middleName, "The middle name can't be empty.");
|
||||
$this->asserts->isNotEmpty($birthDate, "The birth date can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($birthDate, "The birth date can't be in the future.");
|
||||
$this->asserts->isNotEmpty($email, "The email can't be empty.");
|
||||
$this->asserts->isNotEmpty($phone, "The phone number can't be empty.");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("UPDATE persons
|
||||
SET
|
||||
@@ -404,11 +308,6 @@ class EmployeeApplication{
|
||||
* @param $contractType string
|
||||
*/
|
||||
function updateEmployee($idEmployee, $code, $idEmployeeType, $contractType){
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
$this->asserts->higherThanZero($idEmployeeType, "idEmployeeType must be higher than 0");
|
||||
$this->asserts->isNotEmpty($contractType, "The contract type can't be empty.");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("UPDATE employees
|
||||
SET
|
||||
@@ -431,47 +330,32 @@ class EmployeeApplication{
|
||||
/**
|
||||
* @param $requestData object
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function updateEmployeeData($requestData){
|
||||
// Getting and validating the data
|
||||
$code = $requestData['code'];
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
$idEmployee = $requestData['idEmployee'];
|
||||
$idPerson = $this->getIdPersonByIdEmployee($idEmployee);
|
||||
$code = $requestData['code'];
|
||||
|
||||
$firstName = $requestData['firstName'];
|
||||
$this->asserts->isNotEmpty($firstName, "The first name can't be empty.");
|
||||
$this->asserts->isString($firstName, "The first name must be a string.");
|
||||
$this->asserts->betweenLength($firstName, 1, 50, "The first name must have a length between 1 and 50 characters.");
|
||||
$this->asserts->firstName($firstName);
|
||||
|
||||
$middleName = $requestData['middleName'];
|
||||
$this->asserts->isNotEmpty($middleName, "The middle name can't be empty.");
|
||||
$this->asserts->isString($middleName, "The middle name must be a string.");
|
||||
$this->asserts->betweenLength($middleName, 1, 50, "The middle name must have a length between 1 and 50 characters.");
|
||||
$this->asserts->middleName($middleName);
|
||||
|
||||
$lastName = isset($requestData['lastName']) ? $requestData['lastName'] : null;
|
||||
|
||||
$birthDate = $requestData['birthDate'];
|
||||
$this->asserts->isNotEmpty($birthDate, "The birth date can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($birthDate, "The birth date can't be in the future.");
|
||||
$this->asserts->birthDate($birthDate);
|
||||
|
||||
$email = $requestData['email'];
|
||||
$this->asserts->isNotEmpty($email, "The email can't be empty.");
|
||||
$this->asserts->betweenLength($email, 1, 100, "The middle name must have a length between 1 and 100 characters.");
|
||||
$this->asserts->isEmail($email, "The email isn't in a correct format");
|
||||
$this->asserts->email($email);
|
||||
|
||||
$phone = $requestData['phone'];
|
||||
$this->asserts->isNotEmpty($phone, "The phone number can't be empty.");
|
||||
$this->asserts->betweenLength($phone, 10, 10, "The phone number must be 10 digits without special characters.");
|
||||
$this->asserts->phone($phone);
|
||||
|
||||
$idEmployeeType = $requestData{'idEmployeeType'};
|
||||
$this->asserts->higherThanZero($idEmployeeType, "idEmployeeType must be higher than 0");
|
||||
|
||||
$contractType = $requestData{'contractType'};
|
||||
$this->asserts->isNotEmpty($contractType, "The contract type can't be empty.");
|
||||
$this->asserts->existInArray($contractType, $this->settings['contractTypes'], 'The contract type is not a valid one.');
|
||||
|
||||
// Encrypting the sensitive data
|
||||
$securedFirstName = $this->cryptographyService->encryptString($firstName);
|
||||
@@ -504,16 +388,7 @@ class EmployeeApplication{
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $code string
|
||||
* @throws Exception
|
||||
*/
|
||||
function disableEmployeeRecord($code){
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
function disableEmployeeRecord($idEmployee){
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("UPDATE employees
|
||||
SET
|
||||
@@ -537,7 +412,6 @@ class EmployeeApplication{
|
||||
* currently active in the system
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function getIdEmployeeFromAllActiveEmployees(){
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
@@ -551,624 +425,23 @@ class EmployeeApplication{
|
||||
$results = $stmt->fetchAll();
|
||||
|
||||
if(!$results){
|
||||
throw new Exception("The employee could not be found.");
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results;
|
||||
}
|
||||
|
||||
/**
|
||||
* Uses an already existing method to create and array containing the details of
|
||||
* all currently active employees
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function listAllActiveEmployees(){
|
||||
$ids = $this->getIdEmployeeFromAllActiveEmployees();
|
||||
|
||||
$result = array();
|
||||
|
||||
foreach($ids as $row){
|
||||
$currentEmployee = $this->proxyGetEmployeeDataById($row['id']);
|
||||
|
||||
$result[] = array(
|
||||
'fullName' => $currentEmployee['firstName']." ".
|
||||
$currentEmployee['middleName']." ".
|
||||
$currentEmployee['lastName'],
|
||||
'code' => $currentEmployee['code']
|
||||
);
|
||||
$result[] = $this->proxyGetEmployeeDataById($row['id']);
|
||||
}
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Takes an array of all active employees and filters them by a string, returning
|
||||
* all sub arrays that contain such string
|
||||
*
|
||||
* @param $partialName string
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function findEmployeeByFullName($partialName){
|
||||
$fullList = $this->listAllActiveEmployees();
|
||||
|
||||
$pattern = '/'.$partialName.'/';
|
||||
|
||||
$matches = array_filter($fullList, function($a) use($pattern) {
|
||||
return preg_grep($pattern, $a);
|
||||
});
|
||||
|
||||
return $matches;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $idEmployee integer
|
||||
* @param $date date
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function findIdPaymentPerDayByEmployeeAndDate($idEmployee, $date){
|
||||
$this->asserts->isNotEmpty($idEmployee, "The code can't be empty.");
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$this->asserts->isNotEmpty($date, "The code can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
COALESCE((SELECT
|
||||
id
|
||||
FROM
|
||||
paymentsPerEmployeePerDay
|
||||
WHERE
|
||||
date = :date AND idEmployee = :idEmployee),
|
||||
0) AS id;
|
||||
");
|
||||
|
||||
$stmt->execute(array(':date' => $date, ':idEmployee' => $idEmployee));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("The registry of the worked day could not be found.");
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results[0]['id'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Helper to determine if the date has already been saved as a worked day for
|
||||
* an employee, so long as it's currently active in the database
|
||||
*
|
||||
* @param $idEmployee integer
|
||||
* @param $date date
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function checkDateNotUsedWorkDayPerEmployee($idEmployee, $date){
|
||||
$this->asserts->isNotEmpty($idEmployee, "The code can't be empty.");
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$this->asserts->isNotEmpty($date, "The code can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
COALESCE((SELECT
|
||||
COUNT(*)
|
||||
FROM
|
||||
paymentsPerEmployeePerDay
|
||||
WHERE
|
||||
date = :date AND idEmployee = :idEmployee
|
||||
AND status = 'ACTIVE'),
|
||||
0) AS timesDateFound");
|
||||
|
||||
$stmt->execute(array(':date' => $date, ':idEmployee' => $idEmployee));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception('Unable to find the date of the worked days.');
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results[0]['timesDateFound'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Saves the new worked day for the employee
|
||||
*
|
||||
* @param $idEmployee integer
|
||||
* @param $date date
|
||||
* @param $baseAmount double
|
||||
* @param $bonusTime double
|
||||
* @param $deliveries double
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function saveWorkedDay($idEmployee, $date, $baseAmount, $bonusTime, $deliveries){
|
||||
$this->asserts->isNotEmpty($idEmployee, "The idEmployee can't be empty.");
|
||||
$this->asserts->isNotEmpty($date, "The date can't be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
$this->asserts->isNotEmpty($baseAmount, "The base payment per day can't be empty.");
|
||||
$this->asserts->isNotEmpty($bonusTime, "The bonus per worked hours can't be empty.");
|
||||
$this->asserts->isNotEmpty($deliveries, "The payment for deliveries can't be empty.");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("INSERT INTO paymentsPerEmployeePerDay
|
||||
(idEmployee, date, baseAmount, bonusTime, deliveries)
|
||||
VALUES (:idEmployee, :date, :baseAmount, :bonusTime, :deliveries)");
|
||||
$this->pdo->beginTransaction();
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee, ':date' => $date, ':baseAmount' => $baseAmount,
|
||||
':bonusTime' => $bonusTime, ':deliveries' => $deliveries));
|
||||
$id = $this->pdo->lastInsertId();
|
||||
$this->pdo->commit();
|
||||
|
||||
return $id;
|
||||
|
||||
$stmt = null;
|
||||
} catch( PDOExecption $e ) {
|
||||
$this->pdo->rollback();
|
||||
throw new Exception('There was an error while trying to save the worked day.');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Changes the status in the detail table for the registry of worked days so
|
||||
* that it behaves as if deleted
|
||||
* @param $idEmployee
|
||||
* @param $date
|
||||
*/
|
||||
function dissablePaymentPerDayDetailsByEmployeeAndDate($idEmployee, $date){
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
$this->asserts->isNotEmpty($date, "The worked date cannot be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("UPDATE paymentsPerEmployeePerDayDetail a
|
||||
INNER JOIN
|
||||
paymentsPerEmployeePerDay b ON b.id = a.idPaymentPerEmployeePerDay
|
||||
SET
|
||||
a.status = 'INACTIVE'
|
||||
WHERE
|
||||
b.date = :date AND b.idEmployee = :idEmployee");
|
||||
$this->pdo->beginTransaction();
|
||||
$stmt->execute(array(':date' => $date, ':idEmployee' => $idEmployee));
|
||||
$this->pdo->commit();
|
||||
|
||||
$stmt = null;
|
||||
} catch( PDOExecption $e ) {
|
||||
$this->pdo->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $id integer - references paymentsPerEmployeePerDay
|
||||
* @param $baseAmount double
|
||||
* @param $bonusTime double
|
||||
* @param $deliveries double
|
||||
*/
|
||||
function updateWorkedDayPayments($id, $baseAmount, $bonusTime, $deliveries){
|
||||
$this->asserts->higherThanZero($id, "id payment must be higher than 0");
|
||||
$this->asserts->higherThanZero($baseAmount, "baseAmount must be higher than 0");
|
||||
$this->asserts->higherThanZero($bonusTime, "bonusTime must be higher than 0");
|
||||
$this->asserts->higherThanZero($deliveries, "deliveries must be higher than 0");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("UPDATE paymentsPerEmployeePerDay
|
||||
SET
|
||||
baseAmount = :baseAmount,
|
||||
bonusTime = :bonusTime,
|
||||
deliveries = :deliveries
|
||||
WHERE
|
||||
id = :id");
|
||||
$this->pdo->beginTransaction();
|
||||
$stmt->execute(array(':baseAmount' => $baseAmount, ':bonusTime' => $bonusTime, ':deliveries' => $deliveries,
|
||||
':id' => $id));
|
||||
$this->pdo->commit();
|
||||
|
||||
$stmt = null;
|
||||
} catch( PDOExecption $e ) {
|
||||
$this->pdo->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Takes the data from the front end for the work day, this coulld be
|
||||
* for an update or a creation of a new registry
|
||||
*
|
||||
* The function will take the request body, validate it and pass the
|
||||
* processed data back to the wrapper method
|
||||
*
|
||||
* @param $requestData object
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function validateDataForStorageWorkDay($requestData){
|
||||
$code = $requestData['code'];
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$idEmployeeType = $this->getIdEmployeeTypeByCode($code);
|
||||
$this->asserts->higherThanZero($idEmployeeType, "idEmployeeType must be higher than 0");
|
||||
|
||||
$idEmployeeTypePerformed = $requestData['idEmployeeTypePerformed'];
|
||||
$this->asserts->isNotEmpty($idEmployeeTypePerformed, "The performed rol must be provided.");
|
||||
$this->asserts->higherThanZero($idEmployeeTypePerformed, "idEmployeeTypePerformed must be higher than 0");
|
||||
|
||||
$deliveries = $requestData['deliveries'];
|
||||
$this->asserts->isNotEmpty($deliveries, "The number of deliveries cannot be empty or 0.");
|
||||
|
||||
$date = $requestData['date'];
|
||||
$this->asserts->isNotEmpty($date, "The worked date cannot be empty.");
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
|
||||
// The emplpoyee can't take that rol
|
||||
if($idEmployeeType != 3 and $idEmployeeType != $idEmployeeTypePerformed){
|
||||
throw new Exception("The performed rol can't be done by this type of employee.");
|
||||
}
|
||||
|
||||
// If we're working on a different month
|
||||
$this->asserts->datesHaveSameMonth($date, date('Y-m-d'), "Work days can only be registered within the same month.");
|
||||
|
||||
$baseAmountPaid = $this->settings['hoursPerWorkDay'] * $this->settings['paymentPerHour'];
|
||||
|
||||
// Getting setting data based on employee type that was performed
|
||||
switch ($idEmployeeTypePerformed) {
|
||||
case 1:
|
||||
$perHourBonus = $this->settings['perHourBonusDriver'];
|
||||
break;
|
||||
case 2:
|
||||
$perHourBonus = $this->settings['perHourBonusLoader'];
|
||||
break;
|
||||
case 3:
|
||||
$perHourBonus = $this->settings['perHourBonusAux'];
|
||||
break;
|
||||
}
|
||||
|
||||
$bonusTime = $perHourBonus * $this->settings['hoursPerWorkDay'];
|
||||
$bonusDeliveries = $deliveries * $this->settings['bonusPerDelivery'];
|
||||
|
||||
$contractType = $this->getContractTypeByEmployee($idEmployee);
|
||||
|
||||
$result = array(
|
||||
'idEmployee' => (int)$idEmployee,
|
||||
'date' => $date,
|
||||
'baseAmountPaid' => $baseAmountPaid,
|
||||
'bonusTime' => $bonusTime,
|
||||
'bonusDeliveries' => $bonusDeliveries,
|
||||
'contractType' => $contractType,
|
||||
'idEmployeeType' => (int)$idEmployeeType,
|
||||
'idEmployeeTypePerformed' => (int)$idEmployeeTypePerformed,
|
||||
'hoursPerWorkDay' => $this->settings['hoursPerWorkDay'],
|
||||
'paymentPerHour' => $this->settings['paymentPerHour'],
|
||||
'perHourBonus' => $perHourBonus,
|
||||
'deliveries' => $deliveries,
|
||||
'bonusPerDelivery' => $this->settings['bonusPerDelivery']
|
||||
);
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Wrapper function to store a new day that has been worked by an employee
|
||||
*
|
||||
* @param $requestData object
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function newWorkedDay($requestData){
|
||||
$data = $this->validateDataForStorageWorkDay($requestData);
|
||||
|
||||
if($this->checkDateNotUsedWorkDayPerEmployee($data['idEmployee'], $data['date']) > 0){
|
||||
throw new Exception("This date has already been saved as a worked day.");
|
||||
}
|
||||
|
||||
$idPaymentPerEmployeePerDay = $this->saveWorkedDay($data['idEmployee'], $data['date'],
|
||||
$data['baseAmountPaid'], $data['bonusTime'], $data['bonusDeliveries']);
|
||||
|
||||
$this->storeWorkDayDetails($idPaymentPerEmployeePerDay, $data['idEmployeeType'],
|
||||
$data['idEmployeeTypePerformed'], $data['contractType'], $data['hoursPerWorkDay'],
|
||||
$data['paymentPerHour'], $data['perHourBonus'], $data['deliveries'], $data['bonusPerDelivery']);
|
||||
|
||||
return array('status' => 'success', 'message' => 'The worked day has been saved.', 'data' => $requestData);
|
||||
}
|
||||
|
||||
/**
|
||||
* Wrapper method to update a worked day for an employee
|
||||
*
|
||||
* @param $requestData object
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function updateWorkDay($requestData){
|
||||
$data = $this->validateDataForStorageWorkDay($requestData);
|
||||
|
||||
$this->dissablePaymentPerDayDetailsByEmployeeAndDate($data['idEmployee'], $data['date']);
|
||||
|
||||
$idPaymentPerEmployeePerDay = $this->findIdPaymentPerDayByEmployeeAndDate($data['idEmployee'], $data['date']);
|
||||
|
||||
$this->updateWorkedDayPayments($idPaymentPerEmployeePerDay, $data['baseAmountPaid'], $data['bonusTime'], $data['bonusDeliveries']);
|
||||
|
||||
$this->storeWorkDayDetails($idPaymentPerEmployeePerDay, $data['idEmployeeType'],
|
||||
$data['idEmployeeTypePerformed'], $data['contractType'], $data['hoursPerWorkDay'],
|
||||
$data['paymentPerHour'], $data['perHourBonus'], $data['deliveries'], $data['bonusPerDelivery']);
|
||||
|
||||
return array('status' => 'success', 'message' => 'The worked day has been updated.', 'data' => $requestData);
|
||||
}
|
||||
|
||||
/**
|
||||
* The number of days the employee has worked for a given year and month only
|
||||
* taking into accout the active ones
|
||||
*
|
||||
* @param $idEmployee integer
|
||||
* @param $year integer
|
||||
* @param $month integer
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function findNumberWorkedOfDaysByEmployeeAndDate($idEmployee, $year, $month){
|
||||
$this->asserts->isNotEmpty($idEmployee, "The code can't be empty.");
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
$this->asserts->higherThanZero($year, "year must be higher than 0");
|
||||
$this->asserts->higherThanZero($month, "month must be higher than 0");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
COALESCE((SELECT
|
||||
COUNT(*)
|
||||
FROM
|
||||
paymentsPerEmployeePerDay
|
||||
WHERE
|
||||
idEmployee = :idEmployee
|
||||
AND YEAR(date) = :year
|
||||
AND MONTH(date) = :month
|
||||
AND status = 'ACTIVE'),
|
||||
0) AS workedDays");
|
||||
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee, ':year' => $year, ':month' => $month));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception('Unable to determine the amount of worked days.');
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results[0]['workedDays'];
|
||||
}
|
||||
|
||||
/**
|
||||
* A list of the data contained from all the days the employee has worked
|
||||
* for the given month and year
|
||||
*
|
||||
* @param $idEmployee integer
|
||||
* @param $year integer
|
||||
* @param $month integer
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function getDataWorkedDaysByEmployee($idEmployee, $year, $month){
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
baseAmount, bonusTime, deliveries
|
||||
FROM
|
||||
paymentsPerEmployeePerDay
|
||||
WHERE
|
||||
idEmployee = :idEmployee AND
|
||||
YEAR(date) = :year
|
||||
AND MONTH(date) = :month
|
||||
AND status = 'ACTIVE'");
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee, ':year' => $year, ':month' => $month));
|
||||
|
||||
$results = $stmt->fetchAll();
|
||||
|
||||
if(!$results){
|
||||
throw new Exception("No data of the worked days could be found.");
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $idEmployee integer
|
||||
* @return string
|
||||
* @throws Exception
|
||||
*/
|
||||
function getContractTypeByEmployee($idEmployee){
|
||||
$this->asserts->isNotEmpty($idEmployee, "The code can't be empty.");
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
contractType
|
||||
FROM
|
||||
employees
|
||||
WHERE
|
||||
id = :idEmployee");
|
||||
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception("The employee wasn't found.");
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
return $results[0]['contractType'];
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a backup of the information used to calculate the amount that the employee
|
||||
* will be paid for the submitted day
|
||||
*
|
||||
* @param $idPaymentPerEmployeePerDay integer
|
||||
* @param $idEmployeeType integer
|
||||
* @param $idEmployeeTypePerformed integer
|
||||
* @param $contractType string
|
||||
* @param $hoursWorked double
|
||||
* @param $paymentPerHour double
|
||||
* @param $bonusPerHour double
|
||||
* @param $deliveries integer
|
||||
* @param $paymentPerDelivery double
|
||||
* @return integer
|
||||
* @throws Exception
|
||||
*/
|
||||
function storeWorkDayDetails($idPaymentPerEmployeePerDay, $idEmployeeType, $idEmployeeTypePerformed, $contractType, $hoursWorked,
|
||||
$paymentPerHour, $bonusPerHour, $deliveries, $paymentPerDelivery){
|
||||
$this->asserts->isNotEmpty($idPaymentPerEmployeePerDay, "The idPaymentPerEmployeePerDay can't be empty.");
|
||||
$this->asserts->isNotEmpty($idEmployeeType, "The idEmployeeType can't be empty.");
|
||||
$this->asserts->isNotEmpty($idEmployeeTypePerformed, "The idEmployeeTypePerformed can't be empty.");
|
||||
$this->asserts->isNotEmpty($contractType, "The contractType can't be empty.");
|
||||
$this->asserts->isNotEmpty($hoursWorked, "The hoursWorked can't be empty.");
|
||||
$this->asserts->isNotEmpty($paymentPerHour, "The paymentPerHour can't be empty.");
|
||||
$this->asserts->isNotEmpty($bonusPerHour, "The bonusPerHour can't be empty.");
|
||||
$this->asserts->isNotEmpty($deliveries, "The deliveries can't be empty.");
|
||||
$this->asserts->isNotEmpty($paymentPerDelivery, "The paymentPerDelivery can't be empty.");
|
||||
|
||||
try {
|
||||
$stmt = $this->pdo->prepare("INSERT INTO paymentsPerEmployeePerDayDetail
|
||||
(idPaymentPerEmployeePerDay, idEmployeeType, idEmployeeTypePerformed,
|
||||
contractType, hoursWorked, paymentPerHour, bonusPerHour, deliveries, paymentPerDelivery)
|
||||
VALUES
|
||||
(:idPaymentPerEmployeePerDay, :idEmployeeType, :idEmployeeTypePerformed,
|
||||
:contractType, :hoursWorked, :paymentPerHour, :bonusPerHour, :deliveries, :paymentPerDelivery)");
|
||||
$this->pdo->beginTransaction();
|
||||
$stmt->execute(array(':idPaymentPerEmployeePerDay' => $idPaymentPerEmployeePerDay,
|
||||
':idEmployeeType' => $idEmployeeType,
|
||||
':idEmployeeTypePerformed' => $idEmployeeTypePerformed,
|
||||
':contractType' => $contractType,
|
||||
':hoursWorked' => $hoursWorked,
|
||||
':paymentPerHour' => $paymentPerHour,
|
||||
':bonusPerHour' => $bonusPerHour,
|
||||
':deliveries' => $deliveries,
|
||||
':paymentPerDelivery' => $paymentPerDelivery)
|
||||
);
|
||||
$id = $this->pdo->lastInsertId();
|
||||
$this->pdo->commit();
|
||||
|
||||
return $id;
|
||||
|
||||
$stmt = null;
|
||||
} catch( PDOExecption $e ) {
|
||||
$this->pdo->rollback();
|
||||
throw new Exception("An error occured while saving the work day details.");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $date date
|
||||
* @param $code string
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function getDataWorkDayByDateAndCode($date, $code){
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
$this->asserts->dateIsNotInTheFuture($date, "The date can't be in the future.");
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT
|
||||
b.idPaymentPerEmployeePerDay,
|
||||
b.idEmployeeType,
|
||||
b.idEmployeeTypePerformed,
|
||||
b.contractType,
|
||||
b.hoursWorked,
|
||||
b.paymentPerHour,
|
||||
b.bonusPerHour,
|
||||
b.deliveries,
|
||||
b.paymentPerDelivery
|
||||
FROM
|
||||
paymentsPerEmployeePerDay a
|
||||
INNER JOIN
|
||||
paymentsPerEmployeePerDayDetail b ON b.idPaymentPerEmployeePerDay = a.id
|
||||
WHERE
|
||||
a.idEmployee = :idEmployee
|
||||
AND a.date = :date
|
||||
AND a.status = 'ACTIVE'
|
||||
AND b.status = 'ACTIVE'
|
||||
ORDER BY b.id DESC
|
||||
LIMIT 1");
|
||||
$stmt->execute(array(':idEmployee' => $idEmployee, ':date' => $date));
|
||||
|
||||
$results = $stmt->fetchAll();
|
||||
|
||||
if(!$results){
|
||||
throw new Exception("No data of the work day was found.");
|
||||
}
|
||||
$stmt = null;
|
||||
|
||||
foreach($results as $row){
|
||||
$data = array(
|
||||
'idPaymentPerEmployeePerDay' => (int)$row['idPaymentPerEmployeePerDay'],
|
||||
'idEmployeeType' => (int)$row['idEmployeeType'],
|
||||
'idEmployeeTypePerformed' => (int)$row['idEmployeeTypePerformed'],
|
||||
'contractType' => $row['contractType'],
|
||||
'hoursWorked' => (int)$row['hoursWorked'],
|
||||
'paymentPerHour' => (int)$row['paymentPerHour'],
|
||||
'bonusPerHour' => (int)$row['bonusPerHour'],
|
||||
'deliveries' => (int)$row['deliveries'],
|
||||
'paymentPerDelivery' => (int)$row['paymentPerDelivery']
|
||||
);
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets all the worked days for an employee and determines how much they're
|
||||
* getting paid
|
||||
*
|
||||
* Will only work for the current month
|
||||
*
|
||||
* @param $code string
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function calculateSalaryByCode($code){
|
||||
$this->asserts->isNotEmpty($code, "The code can't be empty.");
|
||||
|
||||
$idEmployee = $this->getIdEmployeeByCode($code);
|
||||
$this->asserts->higherThanZero($idEmployee, "idEmployee must be higher than 0");
|
||||
|
||||
$salary = array(
|
||||
'raw' => 0,
|
||||
'taxes' => 0,
|
||||
'real' => 0,
|
||||
'vouchers' => 0
|
||||
);
|
||||
|
||||
// No worked days found
|
||||
if($this->findNumberWorkedOfDaysByEmployeeAndDate($idEmployee, date('Y'), date('m')) <= 0){
|
||||
return $salary;
|
||||
}
|
||||
|
||||
$dataWorkedDays = $this->getDataWorkedDaysByEmployee($idEmployee, date('Y'), date('m'));
|
||||
|
||||
$monthlyPayment = 0;
|
||||
foreach($dataWorkedDays as $row){
|
||||
$monthlyPayment = $monthlyPayment + $row['baseAmount'] + $row['bonusTime'] + $row['deliveries'];
|
||||
}
|
||||
|
||||
$salary['raw'] = $monthlyPayment;
|
||||
|
||||
if($monthlyPayment >= $this->settings['amountForExtraTaxes']){
|
||||
$this->settings['taxesAddUp']
|
||||
? $taxes = $monthlyPayment * ($this->settings['baseIsr'] + $this->settings['extraIsr'])
|
||||
: $taxes = ($monthlyPayment * $this->settings['baseIsr']) + (($monthlyPayment * $this->settings['baseIsr']) * $this->settings['extraIsr']);
|
||||
}else{
|
||||
$taxes = $monthlyPayment * $this->settings['baseIsr'];
|
||||
}
|
||||
|
||||
$salary['taxes'] = $taxes;
|
||||
$salary['real'] = $monthlyPayment - $taxes;
|
||||
|
||||
$contractType = $this->getContractTypeByEmployee($idEmployee);
|
||||
|
||||
if($contractType == 'INTERNO'){
|
||||
$vouchers = $monthlyPayment * $this->settings['percentOfPaymentForVouchers'];
|
||||
}elseif ($contractType == 'EXTERNO'){
|
||||
$this->settings['vouchersForAllContractTypes']
|
||||
? $vouchers = $monthlyPayment * $this->settings['percentOfPaymentForVouchers']
|
||||
: $vouchers = 0;
|
||||
}
|
||||
|
||||
$salary['vouchers'] = $vouchers;
|
||||
|
||||
return $salary;
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -12,6 +12,8 @@ class SessionApplication{
|
||||
$this->cryptographyService = $cryptographyService;
|
||||
$this->pdo = $mysql;
|
||||
$this->asserts = $asserts;
|
||||
|
||||
$this->databaseSelectQueryErrorMessage = 'There was an error inserting the record.';
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -39,18 +41,15 @@ class SessionApplication{
|
||||
/**
|
||||
* @param $userName string
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
function getPassword($userName){
|
||||
$this->asserts->isNotEmpty($userName, "The username can't be empty");
|
||||
$this->asserts->isString($userName, "The username must be a string.");
|
||||
$this->asserts->betweenLength($userName, 1, 50, "The username must have a length between 1 and 50 characters.");
|
||||
$this->asserts->userName($userName);
|
||||
|
||||
$stmt = $this->pdo->prepare("SELECT password FROM users WHERE name = :userName");
|
||||
$stmt->execute(array(':userName' => $userName));
|
||||
$results = $stmt->fetchAll();
|
||||
if(!$results){
|
||||
throw new Exception('The user or password didnt match, please try again.');
|
||||
exit($this->databaseSelectQueryErrorMessage);
|
||||
}
|
||||
$stmt = null;
|
||||
return $results[0]['password'];
|
||||
@@ -63,18 +62,14 @@ class SessionApplication{
|
||||
* @throws Exception
|
||||
*/
|
||||
function newSession($userName, $password){
|
||||
$this->asserts->isNotEmpty($userName, "The username can't be empty");
|
||||
$this->asserts->isString($userName, "The username must be a string.");
|
||||
$this->asserts->betweenLength($userName, 1, 50, "The username must have a length between 1 and 50 characters.");
|
||||
$this->asserts->isNotEmpty($password, "The password can't be empty");
|
||||
$this->asserts->isString($password, "The password must be a string.");
|
||||
$this->asserts->betweenLength($password, 1, 50, "The password must have a length between 1 and 50 characters.");
|
||||
$this->asserts->userName($userName);
|
||||
$this->asserts->password($password);
|
||||
|
||||
$storedPassword = $this->getPassword($userName);
|
||||
|
||||
// If the credentials don't match anything in the the records
|
||||
if(!isset($storedPassword)){
|
||||
return false;
|
||||
throw new Exception('The user or password didnt match, please try again.');
|
||||
}
|
||||
|
||||
// Already has a session
|
||||
@@ -87,40 +82,17 @@ class SessionApplication{
|
||||
return true;
|
||||
}
|
||||
else{
|
||||
throw new Exception('The user or password didnt match, please try again.');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $userName
|
||||
* @param $password
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
function login($userName, $password){
|
||||
$this->asserts->isNotEmpty($userName, "The username can't be empty");
|
||||
$this->asserts->isString($userName, "The username must be a string.");
|
||||
$this->asserts->betweenLength($userName, 1, 50, "The username must have a length between 1 and 50 characters.");
|
||||
$this->asserts->isNotEmpty($password, "The password can't be empty");
|
||||
$this->asserts->isString($password, "The password must be a string.");
|
||||
$this->asserts->betweenLength($password, 1, 50, "The password must have a length between 1 and 50 characters.");
|
||||
|
||||
|
||||
if($this->newSession($userName, $password)){
|
||||
return array('status' => 'success', 'message' => 'Logged in successfully.');
|
||||
}
|
||||
else{
|
||||
throw new Exception('The user or password didnt match, please try again.');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array
|
||||
* @return string
|
||||
*/
|
||||
function destroySession(){
|
||||
session_destroy();
|
||||
|
||||
return array('status' => 'success', 'message' => 'Successfully logged out.');
|
||||
return "Sucessfully logged out.";
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -24,7 +24,6 @@ $container['mysql'] = function ($c) {
|
||||
|
||||
// The database parameters
|
||||
$host = $mysqlSettings['host'];
|
||||
$port = $mysqlSettings['port'];
|
||||
$database = $mysqlSettings['database'];
|
||||
$user = $mysqlSettings['user'];
|
||||
$password = $mysqlSettings['password'];
|
||||
@@ -35,7 +34,7 @@ $container['mysql'] = function ($c) {
|
||||
$databaseConnectionErrorMessage = $mysqlSettings['databaseConnectionErrorMessage'];
|
||||
|
||||
// Initiate the connection
|
||||
$dsn = "mysql:host=$host;port=$port;dbname=$database;charset=$charset";
|
||||
$dsn = "mysql:host=$host;dbname=$database;charset=$charset";
|
||||
try {
|
||||
$pdo = new PDO($dsn, $user, $password, $pdoConnectionOptions);
|
||||
} catch (Exception $e) {
|
||||
|
||||
@@ -22,14 +22,14 @@ $app->get('/api/session', function (Request $request, Response $response, array
|
||||
$app->post('/api/session/login', function ($request, $response) {
|
||||
$requestData = $request->getParsedBody();
|
||||
|
||||
$data = $this->sessionApplication->login($requestData['userName'], $requestData['password']);
|
||||
$data = $this->sessionApplication->newSession($requestData['userName'], $requestData['password']);
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($data));
|
||||
});
|
||||
|
||||
$app->get('/api/session/logout', function (Request $request, Response $response, array $args) {
|
||||
$app->post('/api/session/logout', function (Request $request, Response $response, array $args) {
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->sessionApplication->destroySession()));
|
||||
@@ -41,12 +41,10 @@ $app->get('/api/employee/types', function (Request $request, Response $response,
|
||||
->write(json_encode($this->employeeApplication->listEmployeeTypes()));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/find/{partialName}', function (Request $request, Response $response, array $args) {
|
||||
$partialName = $args['partialName'];
|
||||
|
||||
$app->get('/api/employee/all', function (Request $request, Response $response, array $args) {
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->findEmployeeByFullName($partialName)));
|
||||
->write(json_encode($this->employeeApplication->listAllActiveEmployees()));
|
||||
});
|
||||
|
||||
$app->post('/api/employee', function ($request, $response) {
|
||||
@@ -65,12 +63,12 @@ $app->put('/api/employee', function ($request, $response) {
|
||||
->write(json_encode($this->employeeApplication->updateEmployeeData($requestData)));
|
||||
});
|
||||
|
||||
$app->DELETE('/api/employee/{code}', function (Request $request, Response $response, array $args) {
|
||||
$code = $args['code'];
|
||||
$app->DELETE('/api/employee/{idEmployee}', function (Request $request, Response $response, array $args) {
|
||||
$idEmployee = $args['idEmployee'];
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->disableEmployeeRecord($code)));
|
||||
->write(json_encode($this->employeeApplication->disableEmployeeRecord($idEmployee)));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/type/{code}', function (Request $request, Response $response, array $args) {
|
||||
@@ -81,51 +79,10 @@ $app->get('/api/employee/type/{code}', function (Request $request, Response $res
|
||||
->write(json_encode($this->employeeApplication->getIdEmployeeTypeByCode($code)));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/id/{idEmployee}', function (Request $request, Response $response, array $args) {
|
||||
$app->get('/api/employee/{idEmployee}', function (Request $request, Response $response, array $args) {
|
||||
$idEmployee = $args['idEmployee'];
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->proxyGetEmployeeDataById($idEmployee)));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/code/{code}', function (Request $request, Response $response, array $args) {
|
||||
$code = $args['code'];
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->getEmployeeDataByCode($code)));
|
||||
});
|
||||
|
||||
$app->post('/api/employee/workday', function ($request, $response) {
|
||||
$requestData = $request->getParsedBody();
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->newWorkedDay($requestData)));
|
||||
});
|
||||
|
||||
$app->put('/api/employee/workday', function ($request, $response) {
|
||||
$requestData = $request->getParsedBody();
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->updateWorkDay($requestData)));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/salary/{code}', function (Request $request, Response $response, array $args) {
|
||||
$code = $args['code'];
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->calculateSalaryByCode($code)));
|
||||
});
|
||||
|
||||
$app->get('/api/employee/salary/date/{date}/code/{code}', function (Request $request, Response $response, array $args) {
|
||||
$date = $args['date'];
|
||||
$code = $args['code'];
|
||||
|
||||
return $response->withStatus(200)
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->write(json_encode($this->employeeApplication->getDataWorkDayByDateAndCode($date, $code)));
|
||||
});
|
||||
|
||||
@@ -6,104 +6,78 @@ use Respect\Validation\Validator as v;
|
||||
|
||||
class Asserts{
|
||||
/**
|
||||
* @param $string string
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function isString($string, $errorMessage){
|
||||
$validation = v::stringType()->validate($string);
|
||||
function userName($string){
|
||||
$validateFirstName = v::stringType()->notEmpty()->length(1, 50)->validate($string);
|
||||
|
||||
if(!$validation){
|
||||
throw new Exception($errorMessage);
|
||||
if(!$validateFirstName){
|
||||
throw new Exception('The user name must be a string between 1 and 50 characters');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $string string
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function isNotEmpty($string, $errorMessage){
|
||||
$validation = v::notEmpty()->validate($string);
|
||||
function password($string){
|
||||
$validateFirstName = v::stringType()->notEmpty()->length(1, 50)->validate($string);
|
||||
|
||||
if(!$validation){
|
||||
throw new Exception($errorMessage);
|
||||
if(!$validateFirstName){
|
||||
throw new Exception('The password must be a string between 1 and 50 characters');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $string string
|
||||
* @param $min integer
|
||||
* @param $max integer
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function betweenLength($string, $min, $max, $errorMessage){
|
||||
$validation = v::length($min, $max)->validate($string);
|
||||
function firstName($string){
|
||||
$validateFirstName = v::stringType()->notEmpty()->length(1, 100)->validate($string);
|
||||
|
||||
if(!$validation){
|
||||
throw new Exception($errorMessage);
|
||||
if(!$validateFirstName){
|
||||
throw new Exception('The first name must be a string between 1 and 100 characters');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $number integer
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function higherThanZero($number, $errorMessage){
|
||||
if($number <= 0){
|
||||
throw new Exception($errorMessage);
|
||||
function middleName($string){
|
||||
if(!v::stringType()->notEmpty()->length(1, 100)->validate($string)){
|
||||
throw new Exception('The middle name must be a string between 1 and 100 characters');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Compares a string against a regex to determine if it's an email
|
||||
*
|
||||
* @param $string string
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function isEmail($string, $errorMessage){
|
||||
if(!filter_var($string, FILTER_VALIDATE_EMAIL)){
|
||||
throw new Exception($errorMessage);
|
||||
function birthDate($string){
|
||||
if(!v::date('Y-m-d')->notEmpty()->validate($string)){
|
||||
throw new Exception('The birth date must be in the yyyy-mm-dd format');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $string string
|
||||
* @param $array array
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function existInArray($string, $array, $errorMessage){
|
||||
if(!in_array($string, $array)){
|
||||
throw new Exception($errorMessage);
|
||||
function email($string){
|
||||
if(!v::stringType()->notEmpty()->length(1, 100)->validate($string)){
|
||||
throw new Exception('The email must be a string between 1 and 100 characters');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Compares two dates to dertermine if they have the same month
|
||||
*
|
||||
* @param $firstDate date
|
||||
* @param $secondDate date
|
||||
* @param $errorMessage string
|
||||
* @param $string
|
||||
* @throws Exception
|
||||
*/
|
||||
function datesHaveSameMonth($firstDate, $secondDate, $errorMessage){
|
||||
if (date("m",strtotime($firstDate)) != date("m",strtotime($secondDate))){
|
||||
throw new Exception($errorMessage);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $date
|
||||
* @param $errorMessage
|
||||
* @throws Exception
|
||||
*/
|
||||
function dateIsNotInTheFuture($date, $errorMessage){
|
||||
if ($date > date('Y-m-d')){
|
||||
throw new Exception($errorMessage);
|
||||
function phone($string){
|
||||
if(!v::digit()->notEmpty()->length(10, 10)->validate($string)){
|
||||
throw new Exception('The phone must be a numeric value of 10 digits');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,8 +26,7 @@ return [
|
||||
|
||||
// Datanase settings
|
||||
'mysql' => [
|
||||
'host' => 'mysql',
|
||||
'port' => '3307',
|
||||
'host' => 'localhost',
|
||||
'database' => 'payroll',
|
||||
'user' => 'root',
|
||||
'password' => '12345678',
|
||||
@@ -44,20 +43,7 @@ return [
|
||||
|
||||
// Employee settings
|
||||
'employee' => [
|
||||
'codeLength' => '3',
|
||||
'contractTypes' => array('INTERNO', 'EXTERNO'),
|
||||
'hoursPerWorkDay' => 8,
|
||||
'paymentPerHour' => 30,
|
||||
'bonusPerDelivery' => 5,
|
||||
'perHourBonusDriver' => 10,
|
||||
'perHourBonusLoader' => 5,
|
||||
'perHourBonusAux' => 0,
|
||||
'baseIsr' => .09,
|
||||
'extraIsr' => .03,
|
||||
'taxesAddUp' => true, // If true this will be total/(9 + 3) else they're subtracted separately
|
||||
'amountForExtraTaxes' => 16000,
|
||||
'vouchersForAllContractTypes' => false, // Outsourced personal won't get vouchers
|
||||
'percentOfPaymentForVouchers' => .04,
|
||||
'codeLength' => '5',
|
||||
],
|
||||
],
|
||||
];
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
Dockerfile
|
||||
@@ -1,7 +0,0 @@
|
||||
FROM mysql:5.7
|
||||
|
||||
# Starting scripts
|
||||
ADD . /docker-entrypoint-initdb.d
|
||||
|
||||
# Config
|
||||
ADD my.cnf /etc/mysql
|
||||
@@ -11,7 +11,7 @@ CREATE TABLE IF NOT EXISTS `persons` (
|
||||
`lastName` varbinary(500) comment 'The last name of the person',
|
||||
`birthDate` DATE NOT NULL DEFAULT '1900-01-01' comment 'Date of birth of the person',
|
||||
`email` varbinary(500) NOT NULL comment 'The email adress of the person',
|
||||
`phone` BIGINT(10) UNSIGNED NOT NULL comment 'The phone number of the person should be the mobile one but leaves room for home ones',
|
||||
`phone` INT(10) UNSIGNED NOT NULL comment 'The phone number of the person should be the mobile one but leaves room for home ones',
|
||||
`status` ENUM('ACTIVE', 'INACTIVE') NOT NULL DEFAULT 'ACTIVE',
|
||||
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP comment 'The date on which the registry was created',
|
||||
`updated_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP comment 'The date of the last time the row was modified',
|
||||
@@ -71,44 +71,5 @@ CREATE TABLE IF NOT EXISTS `employees` (
|
||||
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP comment 'The date on which the registry was created',
|
||||
`updated_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP comment 'The date of the last time the row was modified',
|
||||
PRIMARY KEY (`id`),
|
||||
INDEX `idx_contractType` (`contractType`),
|
||||
UNIQUE (`code`)
|
||||
);
|
||||
|
||||
DROP TABLE IF EXISTS paymentsPerEmployeePerDay;
|
||||
CREATE TABLE IF NOT EXISTS `paymentsPerEmployeePerDay` (
|
||||
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`idEmployee` INT UNSIGNED NOT NULL comment 'The employee to who this payment will be made',
|
||||
`date` DATE NOT NULL DEFAULT '1900-01-01' comment 'Date of the worked day',
|
||||
`baseAmount` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Amount paid for the hours worked',
|
||||
`bonusTime` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Bonus paid for the hours worked',
|
||||
`deliveries` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Bonus for the number of deliveries',
|
||||
`status` ENUM('ACTIVE', 'INACTIVE') NOT NULL DEFAULT 'ACTIVE',
|
||||
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP comment 'The date on which the registry was created',
|
||||
`updated_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP comment 'The date of the last time the row was modified',
|
||||
PRIMARY KEY (`id`),
|
||||
FOREIGN KEY (idEmployee) REFERENCES employees(id),
|
||||
UNIQUE (`idEmployee`, `date`, `status`)
|
||||
);
|
||||
|
||||
DROP TABLE IF EXISTS paymentsPerEmployeePerDayDetail;
|
||||
CREATE TABLE IF NOT EXISTS `paymentsPerEmployeePerDayDetail` (
|
||||
`id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
`idPaymentPerEmployeePerDay` INT UNSIGNED NOT NULL comment 'References the payment for the work day',
|
||||
`idEmployeeType` INT UNSIGNED NOT NULL comment 'The type of employee',
|
||||
`idEmployeeTypePerformed` INT UNSIGNED NOT NULL comment 'The employee working for the day as',
|
||||
`contractType` ENUM('INTERNO', 'EXTERNO') NOT NULL comment 'The type of contract',
|
||||
`hoursWorked` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Hours worked for the day',
|
||||
`paymentPerHour` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Payment per hour worked',
|
||||
`bonusPerHour` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Bonus payment per hour worked',
|
||||
`deliveries` INT UNSIGNED NOT NULL DEFAULT 0 comment 'Total amount of deliveries for the day',
|
||||
`paymentPerDelivery` DOUBLE(10,2) NOT NULL DEFAULT 0.0 comment 'Payment for each delivery done',
|
||||
`status` ENUM('ACTIVE', 'INACTIVE') NOT NULL DEFAULT 'ACTIVE',
|
||||
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP comment 'The date on which the registry was created',
|
||||
`updated_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP comment 'The date of the last time the row was modified',
|
||||
PRIMARY KEY (`id`),
|
||||
FOREIGN KEY (idPaymentPerEmployeePerDay) REFERENCES paymentsPerEmployeePerDay(id),
|
||||
FOREIGN KEY (idEmployeeType) REFERENCES employeeType(id),
|
||||
FOREIGN KEY (idEmployeeTypePerformed) REFERENCES employeeType(id),
|
||||
FOREIGN KEY (contractType) REFERENCES employees(contractType)
|
||||
);
|
||||
@@ -1,20 +0,0 @@
|
||||
# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
[mysqld]
|
||||
port = 3307
|
||||
|
||||
!includedir /etc/mysql/conf.d/
|
||||
!includedir /etc/mysql/mysql.conf.d/
|
||||
@@ -1,28 +0,0 @@
|
||||
version: '3'
|
||||
services:
|
||||
api:
|
||||
container_name: payroll_api
|
||||
build: api-payroll/
|
||||
ports:
|
||||
- "8085:80"
|
||||
volumes:
|
||||
- ./volumes/apache-logs:/var/log/apache2
|
||||
depends_on:
|
||||
- mysql
|
||||
mysql:
|
||||
container_name: payroll_mysql
|
||||
restart: always
|
||||
build: database
|
||||
expose:
|
||||
- "3307"
|
||||
ports:
|
||||
- "3307:3307"
|
||||
volumes:
|
||||
- ./volumes/mysql-data:/var/lib/mysql
|
||||
environment:
|
||||
MYSQL_ROOT_PASSWORD: '12345678'
|
||||
MYSQL_USER: 'sloth'
|
||||
MYSQL_PASS: '12345678'
|
||||
volumes:
|
||||
mysql-data:
|
||||
apache-logs:
|
||||
25
front-end/.editorconfig
Normal file
25
front-end/.editorconfig
Normal file
@@ -0,0 +1,25 @@
|
||||
# EditorConfig helps developers define and maintain consistent
|
||||
# coding styles between different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
|
||||
# Change these settings to your own preference
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
max_line_length = 180
|
||||
|
||||
# We recommend you to keep these unchanged
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
[*.{ts,tsx,js,jsx,json,css,scss,sql,ejs}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
||||
[*.md]
|
||||
trim_trailing_whitespace = false
|
||||
1
front-end/.gitignore
vendored
Normal file
1
front-end/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
node_modules/*
|
||||
2
front-end/.prettierignore
Normal file
2
front-end/.prettierignore
Normal file
@@ -0,0 +1,2 @@
|
||||
node_modules
|
||||
target
|
||||
12
front-end/.prettierrc
Normal file
12
front-end/.prettierrc
Normal file
@@ -0,0 +1,12 @@
|
||||
# Prettier configuration
|
||||
|
||||
printWidth: 140
|
||||
singleQuote: true
|
||||
tabWidth: 2
|
||||
useTabs: false
|
||||
|
||||
# js and ts rules:
|
||||
arrowParens: avoid
|
||||
|
||||
# jsx and tsx rules:
|
||||
jsxBracketSameLine: false
|
||||
25
front-end/.yo-rc.json
Normal file
25
front-end/.yo-rc.json
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"generator-jhipster": {
|
||||
"jhipsterVersion": "5.1.0",
|
||||
"applicationType": "monolith",
|
||||
"baseName": "payroll",
|
||||
"clientFramework": "react",
|
||||
"useSass": true,
|
||||
"clientPackageManager": "yarn",
|
||||
"authenticationType": "session",
|
||||
"cacheProvider": "no",
|
||||
"databaseType": "sql",
|
||||
"devDatabaseType": "mysql",
|
||||
"prodDatabaseType": "mysql",
|
||||
"testFrameworks": [],
|
||||
"jhiPrefix": "jhi",
|
||||
"otherModules": [
|
||||
{
|
||||
"name": "generator-jhipster-docker",
|
||||
"version": "2.5.0"
|
||||
}
|
||||
],
|
||||
"enableTranslation": false,
|
||||
"skipServer": true
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/util/pagination.constants.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/util/pagination.constants.ts","mtime":1533613273281},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["export var ITEMS_PER_PAGE = 20;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/util/pagination.constants.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/util/pagination.constants.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,IAAM,cAAc,GAAG,EAAE,CAAC","sourcesContent":["export const ITEMS_PER_PAGE = 20;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/application-profile.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/application-profile.ts","mtime":1533613271641},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import * as tslib_1 from \"tslib\";\nimport axios from 'axios';\nimport { SUCCESS } from 'app/shared/reducers/action-type.util';\nexport var ACTION_TYPES = {\n GET_PROFILE: 'applicationProfile/GET_PROFILE'\n};\nvar initialState = {\n ribbonEnv: '',\n inProduction: true,\n isSwaggerEnabled: false\n};\nexport default (function (state, action) {\n if (state === void 0) { state = initialState; }\n switch (action.type) {\n case SUCCESS(ACTION_TYPES.GET_PROFILE):\n var data = action.payload.data;\n return tslib_1.__assign({}, state, { ribbonEnv: data['display-ribbon-on-profiles'], inProduction: data.activeProfiles.includes('prod'), isSwaggerEnabled: data.activeProfiles.includes('swagger') });\n default:\n return state;\n }\n});\nexport var getProfile = function () { return ({\n type: ACTION_TYPES.GET_PROFILE,\n payload: axios.get('management/info')\n}); };\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/application-profile.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/application-profile.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,OAAO,EAAE,MAAM,sCAAsC,CAAC;AAE/D,MAAM,CAAC,IAAM,YAAY,GAAG;IAC1B,WAAW,EAAE,gCAAgC;CAC9C,CAAC;AAEF,IAAM,YAAY,GAAG;IACnB,SAAS,EAAE,EAAE;IACb,YAAY,EAAE,IAAI;IAClB,gBAAgB,EAAE,KAAK;CACxB,CAAC;AAIF,gBAAe,UAAC,KAA6C,EAAE,MAAM;IAArD,sBAAA,EAAA,oBAA6C;IAC3D,QAAQ,MAAM,CAAC,IAAI,EAAE;QACnB,KAAK,OAAO,CAAC,YAAY,CAAC,WAAW,CAAC;YAC5B,IAAA,0BAAI,CAAoB;YAChC,4BACK,KAAK,IACR,SAAS,EAAE,IAAI,CAAC,4BAA4B,CAAC,EAC7C,YAAY,EAAE,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,MAAM,CAAC,EAClD,gBAAgB,EAAE,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,SAAS,CAAC,IACzD;QACJ;YACE,OAAO,KAAK,CAAC;KAChB;AACH,CAAC,EAAC;AAEF,MAAM,CAAC,IAAM,UAAU,GAAG,cAAM,OAAA,CAAC;IAC/B,IAAI,EAAE,YAAY,CAAC,WAAW;IAC9B,OAAO,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC;CACtC,CAAC,EAH8B,CAG9B,CAAC","sourcesContent":["import axios from 'axios';\n\nimport { SUCCESS } from 'app/shared/reducers/action-type.util';\n\nexport const ACTION_TYPES = {\n GET_PROFILE: 'applicationProfile/GET_PROFILE'\n};\n\nconst initialState = {\n ribbonEnv: '',\n inProduction: true,\n isSwaggerEnabled: false\n};\n\nexport type ApplicationProfileState = Readonly<typeof initialState>;\n\nexport default (state: ApplicationProfileState = initialState, action): ApplicationProfileState => {\n switch (action.type) {\n case SUCCESS(ACTION_TYPES.GET_PROFILE):\n const { data } = action.payload;\n return {\n ...state,\n ribbonEnv: data['display-ribbon-on-profiles'],\n inProduction: data.activeProfiles.includes('prod'),\n isSwaggerEnabled: data.activeProfiles.includes('swagger')\n };\n default:\n return state;\n }\n};\n\nexport const getProfile = () => ({\n type: ACTION_TYPES.GET_PROFILE,\n payload: axios.get('management/info')\n});\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/index.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/index.ts","mtime":1533613273189},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["export * from './account';\nexport * from './admin';\nexport * from './entities';\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/index.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,YAAY,CAAC","sourcesContent":["export * from './account';\nexport * from './admin';\nexport * from './entities';\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/store.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/store.ts","mtime":1533613271013},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import { createStore, applyMiddleware, compose } from 'redux';\nimport promiseMiddleware from 'redux-promise-middleware';\nimport thunkMiddleware from 'redux-thunk';\nimport reducer from 'app/shared/reducers';\nimport DevTools from './devtools';\nimport errorMiddleware from './error-middleware';\nimport notificationMiddleware from './notification-middleware';\nimport loggerMiddleware from './logger-middleware';\nimport { loadingBarMiddleware } from 'react-redux-loading-bar';\nvar defaultMiddlewares = [\n thunkMiddleware,\n errorMiddleware,\n notificationMiddleware,\n promiseMiddleware(),\n loadingBarMiddleware(),\n loggerMiddleware\n];\nvar composedMiddlewares = function (middlewares) {\n return process.env.NODE_ENV === 'development'\n ? compose(applyMiddleware.apply(void 0, defaultMiddlewares.concat(middlewares)), DevTools.instrument())\n : compose(applyMiddleware.apply(void 0, defaultMiddlewares.concat(middlewares)));\n};\nvar initialize = function (initialState, middlewares) {\n if (middlewares === void 0) { middlewares = []; }\n return createStore(reducer, initialState, composedMiddlewares(middlewares));\n};\nexport default initialize;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/store.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/store.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAC9D,OAAO,iBAAiB,MAAM,0BAA0B,CAAC;AACzD,OAAO,eAAe,MAAM,aAAa,CAAC;AAC1C,OAAO,OAAuB,MAAM,qBAAqB,CAAC;AAC1D,OAAO,QAAQ,MAAM,YAAY,CAAC;AAClC,OAAO,eAAe,MAAM,oBAAoB,CAAC;AACjD,OAAO,sBAAsB,MAAM,2BAA2B,CAAC;AAC/D,OAAO,gBAAgB,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAE/D,IAAM,kBAAkB,GAAG;IACzB,eAAe;IACf,eAAe;IACf,sBAAsB;IACtB,iBAAiB,EAAE;IACnB,oBAAoB,EAAE;IACtB,gBAAgB;CACjB,CAAC;AACF,IAAM,mBAAmB,GAAG,UAAA,WAAW;IACrC,OAAA,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,aAAa;QACpC,CAAC,CAAC,OAAO,CACL,eAAe,eAAI,kBAAkB,QAAK,WAAW,IACrD,QAAQ,CAAC,UAAU,EAAE,CACtB;QACH,CAAC,CAAC,OAAO,CAAC,eAAe,eAAI,kBAAkB,QAAK,WAAW,GAAE;AALnE,CAKmE,CAAC;AAEtE,IAAM,UAAU,GAAG,UAAC,YAAyB,EAAE,WAAgB;IAAhB,4BAAA,EAAA,gBAAgB;IAAK,OAAA,WAAW,CAAC,OAAO,EAAE,YAAY,EAAE,mBAAmB,CAAC,WAAW,CAAC,CAAC;AAApE,CAAoE,CAAC;AAEzI,eAAe,UAAU,CAAC","sourcesContent":["import { createStore, applyMiddleware, compose } from 'redux';\nimport promiseMiddleware from 'redux-promise-middleware';\nimport thunkMiddleware from 'redux-thunk';\nimport reducer, { IRootState } from 'app/shared/reducers';\nimport DevTools from './devtools';\nimport errorMiddleware from './error-middleware';\nimport notificationMiddleware from './notification-middleware';\nimport loggerMiddleware from './logger-middleware';\nimport { loadingBarMiddleware } from 'react-redux-loading-bar';\n\nconst defaultMiddlewares = [\n thunkMiddleware,\n errorMiddleware,\n notificationMiddleware,\n promiseMiddleware(),\n loadingBarMiddleware(),\n loggerMiddleware\n];\nconst composedMiddlewares = middlewares =>\n process.env.NODE_ENV === 'development'\n ? compose(\n applyMiddleware(...defaultMiddlewares, ...middlewares),\n DevTools.instrument()\n )\n : compose(applyMiddleware(...defaultMiddlewares, ...middlewares));\n\nconst initialize = (initialState?: IRootState, middlewares = []) => createStore(reducer, initialState, composedMiddlewares(middlewares));\n\nexport default initialize;\n"]}]}
|
||||
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/model/user.model.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/model/user.model.ts","mtime":1533613273393},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["export var defaultValue = {\n id: null,\n login: null,\n firstName: null,\n lastName: null,\n email: null,\n activated: false,\n langKey: null,\n authorities: null,\n createdBy: null,\n createdDate: null,\n lastModifiedBy: null,\n lastModifiedDate: null,\n password: null\n};\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/model/user.model.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/model/user.model.ts"],"names":[],"mappings":"AAgBA,MAAM,CAAC,IAAM,YAAY,GAAoB;IAC3C,EAAE,EAAE,IAAI;IACR,KAAK,EAAE,IAAI;IACX,SAAS,EAAE,IAAI;IACf,QAAQ,EAAE,IAAI;IACd,KAAK,EAAE,IAAI;IACX,SAAS,EAAE,KAAK;IAChB,OAAO,EAAE,IAAI;IACb,WAAW,EAAE,IAAI;IACjB,SAAS,EAAE,IAAI;IACf,WAAW,EAAE,IAAI;IACjB,cAAc,EAAE,IAAI;IACpB,gBAAgB,EAAE,IAAI;IACtB,QAAQ,EAAE,IAAI;CACf,CAAC","sourcesContent":["export interface IUser {\n id?: any;\n login?: string;\n firstName?: string;\n lastName?: string;\n email?: string;\n activated?: boolean;\n langKey?: string;\n authorities?: any[];\n createdBy?: string;\n createdDate?: Date;\n lastModifiedBy?: string;\n lastModifiedDate?: Date;\n password?: string;\n}\n\nexport const defaultValue: Readonly<IUser> = {\n id: null,\n login: null,\n firstName: null,\n lastName: null,\n email: null,\n activated: false,\n langKey: null,\n authorities: null,\n createdBy: null,\n createdDate: null,\n lastModifiedBy: null,\n lastModifiedDate: null,\n password: null\n};\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/docs/docs.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/docs/docs.tsx","mtime":1533613272309},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nvar DocsPage = function () { return (React.createElement(\"div\", null,\n React.createElement(\"iframe\", { src: \"../swagger-ui/index.html\", width: \"100%\", height: \"800\", title: \"Swagger UI\", seamless: true, style: { border: 'none' } }))); };\nexport default DocsPage;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/docs/docs.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/docs/docs.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,IAAM,QAAQ,GAAG,cAAM,OAAA,CACrB;IACE,gCAAQ,GAAG,EAAC,0BAA0B,EAAC,KAAK,EAAC,MAAM,EAAC,MAAM,EAAC,KAAK,EAAC,KAAK,EAAC,YAAY,EAAC,QAAQ,QAAC,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,GAAI,CACtH,CACP,EAJsB,CAItB,CAAC;AAEF,eAAe,QAAQ,CAAC","sourcesContent":["import React from 'react';\n\nconst DocsPage = () => (\n <div>\n <iframe src=\"../swagger-ui/index.html\" width=\"100%\" height=\"800\" title=\"Swagger UI\" seamless style={{ border: 'none' }} />\n </div>\n);\n\nexport default DocsPage;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/index.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/index.tsx","mtime":1533613271665},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nimport ErrorBoundaryRoute from 'app/shared/error/error-boundary-route';\nimport Settings from './settings/settings';\nimport Password from './password/password';\nimport Sessions from './sessions/sessions';\nvar Routes = function (_a) {\n var match = _a.match;\n return (React.createElement(\"div\", null,\n React.createElement(ErrorBoundaryRoute, { path: match.url + \"/settings\", component: Settings }),\n React.createElement(ErrorBoundaryRoute, { path: match.url + \"/password\", component: Password }),\n React.createElement(ErrorBoundaryRoute, { path: match.url + \"/sessions\", component: Sessions })));\n};\nexport default Routes;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/index.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,kBAAkB,MAAM,uCAAuC,CAAC;AAEvE,OAAO,QAAQ,MAAM,qBAAqB,CAAC;AAC3C,OAAO,QAAQ,MAAM,qBAAqB,CAAC;AAC3C,OAAO,QAAQ,MAAM,qBAAqB,CAAC;AAE3C,IAAM,MAAM,GAAG,UAAC,EAAS;QAAP,gBAAK;IAAO,OAAA,CAC5B;QACE,oBAAC,kBAAkB,IAAC,IAAI,EAAK,KAAK,CAAC,GAAG,cAAW,EAAE,SAAS,EAAE,QAAQ,GAAI;QAC1E,oBAAC,kBAAkB,IAAC,IAAI,EAAK,KAAK,CAAC,GAAG,cAAW,EAAE,SAAS,EAAE,QAAQ,GAAI;QAC1E,oBAAC,kBAAkB,IAAC,IAAI,EAAK,KAAK,CAAC,GAAG,cAAW,EAAE,SAAS,EAAE,QAAQ,GAAI,CACtE,CACP;AAN6B,CAM7B,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import React from 'react';\n\nimport ErrorBoundaryRoute from 'app/shared/error/error-boundary-route';\n\nimport Settings from './settings/settings';\nimport Password from './password/password';\nimport Sessions from './sessions/sessions';\n\nconst Routes = ({ match }) => (\n <div>\n <ErrorBoundaryRoute path={`${match.url}/settings`} component={Settings} />\n <ErrorBoundaryRoute path={`${match.url}/password`} component={Password} />\n <ErrorBoundaryRoute path={`${match.url}/sessions`} component={Sessions} />\n </div>\n);\n\nexport default Routes;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/activate/activate.reducer.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/activate/activate.reducer.ts","mtime":1533613271985},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import * as tslib_1 from \"tslib\";\nimport axios from 'axios';\nimport { REQUEST, SUCCESS, FAILURE } from 'app/shared/reducers/action-type.util';\nexport var ACTION_TYPES = {\n ACTIVATE_ACCOUNT: 'activate/ACTIVATE_ACCOUNT',\n RESET: 'activate/RESET'\n};\nvar initialState = {\n activationSuccess: false,\n activationFailure: false\n};\n// Reducer\nexport default (function (state, action) {\n if (state === void 0) { state = initialState; }\n switch (action.type) {\n case REQUEST(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return tslib_1.__assign({}, state);\n case FAILURE(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return tslib_1.__assign({}, state, { activationFailure: true });\n case SUCCESS(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return tslib_1.__assign({}, state, { activationSuccess: true });\n case ACTION_TYPES.RESET:\n return tslib_1.__assign({}, initialState);\n default:\n return state;\n }\n});\n// Actions\nexport var activateAction = function (key) { return ({\n type: ACTION_TYPES.ACTIVATE_ACCOUNT,\n payload: axios.get('api/activate?key=' + key)\n}); };\nexport var reset = function () { return ({\n type: ACTION_TYPES.RESET\n}); };\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/activate/activate.reducer.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/account/activate/activate.reducer.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,sCAAsC,CAAC;AAEjF,MAAM,CAAC,IAAM,YAAY,GAAG;IAC1B,gBAAgB,EAAE,2BAA2B;IAC7C,KAAK,EAAE,gBAAgB;CACxB,CAAC;AAEF,IAAM,YAAY,GAAG;IACnB,iBAAiB,EAAE,KAAK;IACxB,iBAAiB,EAAE,KAAK;CACzB,CAAC;AAIF,UAAU;AACV,gBAAe,UAAC,KAAmC,EAAE,MAAM;IAA3C,sBAAA,EAAA,oBAAmC;IACjD,QAAQ,MAAM,CAAC,IAAI,EAAE;QACnB,KAAK,OAAO,CAAC,YAAY,CAAC,gBAAgB,CAAC;YACzC,4BACK,KAAK,EACR;QACJ,KAAK,OAAO,CAAC,YAAY,CAAC,gBAAgB,CAAC;YACzC,4BACK,KAAK,IACR,iBAAiB,EAAE,IAAI,IACvB;QACJ,KAAK,OAAO,CAAC,YAAY,CAAC,gBAAgB,CAAC;YACzC,4BACK,KAAK,IACR,iBAAiB,EAAE,IAAI,IACvB;QACJ,KAAK,YAAY,CAAC,KAAK;YACrB,4BACK,YAAY,EACf;QACJ;YACE,OAAO,KAAK,CAAC;KAChB;AACH,CAAC,EAAC;AAEF,UAAU;AACV,MAAM,CAAC,IAAM,cAAc,GAAG,UAAA,GAAG,IAAI,OAAA,CAAC;IACpC,IAAI,EAAE,YAAY,CAAC,gBAAgB;IACnC,OAAO,EAAE,KAAK,CAAC,GAAG,CAAC,mBAAmB,GAAG,GAAG,CAAC;CAC9C,CAAC,EAHmC,CAGnC,CAAC;AAEH,MAAM,CAAC,IAAM,KAAK,GAAG,cAAM,OAAA,CAAC;IAC1B,IAAI,EAAE,YAAY,CAAC,KAAK;CACzB,CAAC,EAFyB,CAEzB,CAAC","sourcesContent":["import axios from 'axios';\n\nimport { REQUEST, SUCCESS, FAILURE } from 'app/shared/reducers/action-type.util';\n\nexport const ACTION_TYPES = {\n ACTIVATE_ACCOUNT: 'activate/ACTIVATE_ACCOUNT',\n RESET: 'activate/RESET'\n};\n\nconst initialState = {\n activationSuccess: false,\n activationFailure: false\n};\n\nexport type ActivateState = Readonly<typeof initialState>;\n\n// Reducer\nexport default (state: ActivateState = initialState, action): ActivateState => {\n switch (action.type) {\n case REQUEST(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return {\n ...state\n };\n case FAILURE(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return {\n ...state,\n activationFailure: true\n };\n case SUCCESS(ACTION_TYPES.ACTIVATE_ACCOUNT):\n return {\n ...state,\n activationSuccess: true\n };\n case ACTION_TYPES.RESET:\n return {\n ...initialState\n };\n default:\n return state;\n }\n};\n\n// Actions\nexport const activateAction = key => ({\n type: ACTION_TYPES.ACTIVATE_ACCOUNT,\n payload: axios.get('api/activate?key=' + key)\n});\n\nexport const reset = () => ({\n type: ACTION_TYPES.RESET\n});\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/axios-interceptor.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/axios-interceptor.ts","mtime":1533613270825},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import axios from 'axios';\nimport { SERVER_API_URL } from 'app/config/constants';\nvar TIMEOUT = 1000000; // 10000\nvar setupAxiosInterceptors = function (onUnauthenticated) {\n var onRequestSuccess = function (config) {\n config.timeout = TIMEOUT;\n config.url = \"\" + SERVER_API_URL + config.url;\n return config;\n };\n var onResponseSuccess = function (response) { return response; };\n var onResponseError = function (err) {\n var status = err.status || err.response.status;\n if (status === 403 || status === 401) {\n onUnauthenticated();\n }\n return Promise.reject(err);\n };\n axios.interceptors.request.use(onRequestSuccess);\n axios.interceptors.response.use(onResponseSuccess, onResponseError);\n};\nexport default setupAxiosInterceptors;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/axios-interceptor.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/axios-interceptor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAEtD,IAAM,OAAO,GAAG,OAAO,CAAC,CAAC,QAAQ;AACjC,IAAM,sBAAsB,GAAG,UAAA,iBAAiB;IAC9C,IAAM,gBAAgB,GAAG,UAAA,MAAM;QAC7B,MAAM,CAAC,OAAO,GAAG,OAAO,CAAC;QACzB,MAAM,CAAC,GAAG,GAAG,KAAG,cAAc,GAAG,MAAM,CAAC,GAAK,CAAC;QAC9C,OAAO,MAAM,CAAC;IAChB,CAAC,CAAC;IACF,IAAM,iBAAiB,GAAG,UAAA,QAAQ,IAAI,OAAA,QAAQ,EAAR,CAAQ,CAAC;IAC/C,IAAM,eAAe,GAAG,UAAA,GAAG;QACzB,IAAM,MAAM,GAAG,GAAG,CAAC,MAAM,IAAI,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC;QACjD,IAAI,MAAM,KAAK,GAAG,IAAI,MAAM,KAAK,GAAG,EAAE;YACpC,iBAAiB,EAAE,CAAC;SACrB;QACD,OAAO,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAC7B,CAAC,CAAC;IACF,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;IACjD,KAAK,CAAC,YAAY,CAAC,QAAQ,CAAC,GAAG,CAAC,iBAAiB,EAAE,eAAe,CAAC,CAAC;AACtE,CAAC,CAAC;AAEF,eAAe,sBAAsB,CAAC","sourcesContent":["import axios from 'axios';\nimport { getBasePath, Storage } from 'react-jhipster';\n\nimport { SERVER_API_URL } from 'app/config/constants';\n\nconst TIMEOUT = 1000000; // 10000\nconst setupAxiosInterceptors = onUnauthenticated => {\n const onRequestSuccess = config => {\n config.timeout = TIMEOUT;\n config.url = `${SERVER_API_URL}${config.url}`;\n return config;\n };\n const onResponseSuccess = response => response;\n const onResponseError = err => {\n const status = err.status || err.response.status;\n if (status === 403 || status === 401) {\n onUnauthenticated();\n }\n return Promise.reject(err);\n };\n axios.interceptors.request.use(onRequestSuccess);\n axios.interceptors.response.use(onResponseSuccess, onResponseError);\n};\n\nexport default setupAxiosInterceptors;\n"]}]}
|
||||
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/logger-middleware.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/logger-middleware.ts","mtime":1533613270897},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["export default (function () { return function (next) { return function (action) {\n if (process.env.NODE_ENV !== 'production') {\n var type = action.type, payload = action.payload, meta = action.meta;\n console.groupCollapsed(type);\n // tslint:disable-next-line\n console.log('Payload:', payload);\n // tslint:disable-next-line\n console.log('Meta:', meta);\n console.groupEnd();\n }\n return next(action);\n}; }; });\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/logger-middleware.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/logger-middleware.ts"],"names":[],"mappings":"AAAA,gBAAe,cAAM,OAAA,UAAA,IAAI,IAAI,OAAA,UAAA,MAAM;IACjC,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,YAAY,EAAE;QACjC,IAAA,kBAAI,EAAE,wBAAO,EAAE,kBAAI,CAAY;QAEvC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QAC7B,2BAA2B;QAC3B,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;QACjC,2BAA2B;QAC3B,OAAO,CAAC,GAAG,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;QAC3B,OAAO,CAAC,QAAQ,EAAE,CAAC;KACpB;IAED,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC;AACtB,CAAC,EAb4B,CAa5B,EAboB,CAapB,EAAC","sourcesContent":["export default () => next => action => {\n if (process.env.NODE_ENV !== 'production') {\n const { type, payload, meta } = action;\n\n console.groupCollapsed(type);\n // tslint:disable-next-line\n console.log('Payload:', payload);\n // tslint:disable-next-line\n console.log('Meta:', meta);\n console.groupEnd();\n }\n\n return next(action);\n};\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary-route.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary-route.tsx","mtime":1533613273381},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import * as tslib_1 from \"tslib\";\nimport React from 'react';\nimport { Route } from 'react-router-dom';\nimport ErrorBoundary from 'app/shared/error/error-boundary';\nexport var ErrorBoundaryRoute = function (_a) {\n var Component = _a.component, rest = tslib_1.__rest(_a, [\"component\"]);\n var encloseInErrorBoundary = function (props) { return (React.createElement(ErrorBoundary, null,\n React.createElement(Component, tslib_1.__assign({}, props)))); };\n if (!Component)\n throw new Error(\"A component needs to be specified for path \" + rest.path);\n return React.createElement(Route, tslib_1.__assign({}, rest, { render: encloseInErrorBoundary }));\n};\nexport default ErrorBoundaryRoute;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary-route.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary-route.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,KAAK,EAAc,MAAM,kBAAkB,CAAC;AACrD,OAAO,aAAa,MAAM,iCAAiC,CAAC;AAE5D,MAAM,CAAC,IAAM,kBAAkB,GAAG,UAAC,EAA6C;IAA3C,IAAA,wBAAoB,EAAE,wCAAO;IAChE,IAAM,sBAAsB,GAAG,UAAA,KAAK,IAAI,OAAA,CACtC,oBAAC,aAAa;QACZ,oBAAC,SAAS,uBAAK,KAAK,EAAI,CACV,CACjB,EAJuC,CAIvC,CAAC;IAEF,IAAI,CAAC,SAAS;QAAE,MAAM,IAAI,KAAK,CAAC,gDAA+C,IAAY,CAAC,IAAM,CAAC,CAAC;IAEpG,OAAO,oBAAC,KAAK,uBAAK,IAAI,IAAE,MAAM,EAAE,sBAAsB,IAAI,CAAC;AAC7D,CAAC,CAAC;AAEF,eAAe,kBAAkB,CAAC","sourcesContent":["import React from 'react';\nimport { Route, RouteProps } from 'react-router-dom';\nimport ErrorBoundary from 'app/shared/error/error-boundary';\n\nexport const ErrorBoundaryRoute = ({ component: Component, ...rest }: RouteProps) => {\n const encloseInErrorBoundary = props => (\n <ErrorBoundary>\n <Component {...props} />\n </ErrorBoundary>\n );\n\n if (!Component) throw new Error(`A component needs to be specified for path ${(rest as any).path}`);\n\n return <Route {...rest} render={encloseInErrorBoundary} />;\n};\n\nexport default ErrorBoundaryRoute;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/entities.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/entities.tsx","mtime":1533613273229},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nimport { NavDropdown } from '../header-components';\nexport var EntitiesMenu = function (props) { return (\n// tslint:disable-next-line:jsx-self-close\nReact.createElement(NavDropdown, { icon: \"th-list\", name: \"Entities\", id: \"entity-menu\" })); };\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/entities.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/header/menus/entities.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,MAAM,CAAC,IAAM,YAAY,GAAG,UAAA,KAAK,IAAI,OAAA;AACnC,0CAA0C;AAC1C,oBAAC,WAAW,IAAC,IAAI,EAAC,SAAS,EAAC,IAAI,EAAC,UAAU,EAAC,EAAE,EAAC,aAAa,GAE9C,CACf,EALoC,CAKpC,CAAC","sourcesContent":["import React from 'react';\nimport { DropdownItem } from 'reactstrap';\nimport { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\n\nimport { NavLink as Link } from 'react-router-dom';\nimport { NavDropdown } from '../header-components';\n\nexport const EntitiesMenu = props => (\n // tslint:disable-next-line:jsx-self-close\n <NavDropdown icon=\"th-list\" name=\"Entities\" id=\"entity-menu\">\n {/* jhipster-needle-add-entity-to-menu - JHipster will add entities to the menu here */}\n </NavDropdown>\n);\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/action-type.util.ts","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/action-type.util.ts","mtime":1533613271581},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["/**\n * Appends REQUEST asyc action type\n */\nexport var REQUEST = function (actionType) { return actionType + \"_PENDING\"; };\n/**\n * Appends SUCCESS asyc action type\n */\nexport var SUCCESS = function (actionType) { return actionType + \"_FULFILLED\"; };\n/**\n * Appends FAILURE asyc action type\n */\nexport var FAILURE = function (actionType) { return actionType + \"_REJECTED\"; };\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/action-type.util.ts","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/reducers/action-type.util.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,CAAC,IAAM,OAAO,GAAG,UAAA,UAAU,IAAI,OAAG,UAAU,aAAU,EAAvB,CAAuB,CAAC;AAE7D;;GAEG;AAEH,MAAM,CAAC,IAAM,OAAO,GAAG,UAAA,UAAU,IAAI,OAAG,UAAU,eAAY,EAAzB,CAAyB,CAAC;AAE/D;;GAEG;AAEH,MAAM,CAAC,IAAM,OAAO,GAAG,UAAA,UAAU,IAAI,OAAG,UAAU,cAAW,EAAxB,CAAwB,CAAC","sourcesContent":["/**\n * Appends REQUEST asyc action type\n */\n\nexport const REQUEST = actionType => `${actionType}_PENDING`;\n\n/**\n * Appends SUCCESS asyc action type\n */\n\nexport const SUCCESS = actionType => `${actionType}_FULFILLED`;\n\n/**\n * Appends FAILURE asyc action type\n */\n\nexport const FAILURE = actionType => `${actionType}_REJECTED`;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/entities/index.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/entities/index.tsx","mtime":1533613271345},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nimport { Switch } from 'react-router-dom';\n/* jhipster-needle-add-route-import - JHipster will add routes here */\nvar Routes = function (_a) {\n var match = _a.match;\n return (React.createElement(\"div\", null,\n React.createElement(Switch, null)));\n};\nexport default Routes;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/entities/index.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/entities/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAK1C,sEAAsE;AAEtE,IAAM,MAAM,GAAG,UAAC,EAAS;QAAP,gBAAK;IAAO,OAAA,CAC5B;QACE,oBAAC,MAAM,OAGE,CACL,CACP;AAP6B,CAO7B,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import React from 'react';\nimport { Switch } from 'react-router-dom';\n\n// tslint:disable-next-line:no-unused-variable\nimport ErrorBoundaryRoute from 'app/shared/error/error-boundary-route';\n\n/* jhipster-needle-add-route-import - JHipster will add routes here */\n\nconst Routes = ({ match }) => (\n <div>\n <Switch>\n {/* prettier-ignore */}\n {/* jhipster-needle-add-route-path - JHipster will routes here */}\n </Switch>\n </div>\n);\n\nexport default Routes;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/user-management/index.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/user-management/index.tsx","mtime":1533613272877},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nimport { Switch } from 'react-router-dom';\nimport ErrorBoundaryRoute from 'app/shared/error/error-boundary-route';\nimport UserManagement from './user-management';\nimport UserManagementDetail from './user-management-detail';\nimport UserManagementUpdate from './user-management-update';\nimport UserManagementDeleteDialog from './user-management-delete-dialog';\nvar Routes = function (_a) {\n var match = _a.match;\n return (React.createElement(React.Fragment, null,\n React.createElement(Switch, null,\n React.createElement(ErrorBoundaryRoute, { exact: true, path: match.url + \"/new\", component: UserManagementUpdate }),\n React.createElement(ErrorBoundaryRoute, { exact: true, path: match.url + \"/:login/edit\", component: UserManagementUpdate }),\n React.createElement(ErrorBoundaryRoute, { exact: true, path: match.url + \"/:login\", component: UserManagementDetail }),\n React.createElement(ErrorBoundaryRoute, { path: match.url, component: UserManagement })),\n React.createElement(ErrorBoundaryRoute, { path: match.url + \"/:login/delete\", component: UserManagementDeleteDialog })));\n};\nexport default Routes;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/user-management/index.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/modules/administration/user-management/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAE1C,OAAO,kBAAkB,MAAM,uCAAuC,CAAC;AACvE,OAAO,cAAc,MAAM,mBAAmB,CAAC;AAC/C,OAAO,oBAAoB,MAAM,0BAA0B,CAAC;AAC5D,OAAO,oBAAoB,MAAM,0BAA0B,CAAC;AAC5D,OAAO,0BAA0B,MAAM,iCAAiC,CAAC;AAEzE,IAAM,MAAM,GAAG,UAAC,EAAS;QAAP,gBAAK;IAAO,OAAA,CAC5B;QACE,oBAAC,MAAM;YACL,oBAAC,kBAAkB,IAAC,KAAK,QAAC,IAAI,EAAK,KAAK,CAAC,GAAG,SAAM,EAAE,SAAS,EAAE,oBAAoB,GAAI;YACvF,oBAAC,kBAAkB,IAAC,KAAK,QAAC,IAAI,EAAK,KAAK,CAAC,GAAG,iBAAc,EAAE,SAAS,EAAE,oBAAoB,GAAI;YAC/F,oBAAC,kBAAkB,IAAC,KAAK,QAAC,IAAI,EAAK,KAAK,CAAC,GAAG,YAAS,EAAE,SAAS,EAAE,oBAAoB,GAAI;YAC1F,oBAAC,kBAAkB,IAAC,IAAI,EAAE,KAAK,CAAC,GAAG,EAAE,SAAS,EAAE,cAAc,GAAI,CAC3D;QACT,oBAAC,kBAAkB,IAAC,IAAI,EAAK,KAAK,CAAC,GAAG,mBAAgB,EAAE,SAAS,EAAE,0BAA0B,GAAI,CAChG,CACJ;AAV6B,CAU7B,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import React from 'react';\nimport { Switch } from 'react-router-dom';\n\nimport ErrorBoundaryRoute from 'app/shared/error/error-boundary-route';\nimport UserManagement from './user-management';\nimport UserManagementDetail from './user-management-detail';\nimport UserManagementUpdate from './user-management-update';\nimport UserManagementDeleteDialog from './user-management-delete-dialog';\n\nconst Routes = ({ match }) => (\n <>\n <Switch>\n <ErrorBoundaryRoute exact path={`${match.url}/new`} component={UserManagementUpdate} />\n <ErrorBoundaryRoute exact path={`${match.url}/:login/edit`} component={UserManagementUpdate} />\n <ErrorBoundaryRoute exact path={`${match.url}/:login`} component={UserManagementDetail} />\n <ErrorBoundaryRoute path={match.url} component={UserManagement} />\n </Switch>\n <ErrorBoundaryRoute path={`${match.url}/:login/delete`} component={UserManagementDeleteDialog} />\n </>\n);\n\nexport default Routes;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/devtools.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/devtools.tsx","mtime":1533613270845},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import React from 'react';\nimport { createDevTools } from 'redux-devtools';\nimport LogMonitor from 'redux-devtools-log-monitor';\nimport DockMonitor from 'redux-devtools-dock-monitor';\n// You can toggle visibility of devTools with ctrl + H\n// and change their position with ctrl + Q\nexport default createDevTools(React.createElement(DockMonitor, { toggleVisibilityKey: \"ctrl-h\", changePositionKey: \"ctrl-q\", defaultIsVisible: false },\n React.createElement(LogMonitor, null)));\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/devtools.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/config/devtools.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,UAAU,MAAM,4BAA4B,CAAC;AACpD,OAAO,WAAW,MAAM,6BAA6B,CAAC;AACtD,sDAAsD;AACtD,0CAA0C;AAC1C,eAAe,cAAc,CAC3B,oBAAC,WAAW,IAAC,mBAAmB,EAAC,QAAQ,EAAC,iBAAiB,EAAC,QAAQ,EAAC,gBAAgB,EAAE,KAAK;IAC1F,oBAAC,UAAU,OAAG,CACF,CACf,CAAC","sourcesContent":["import React from 'react';\nimport { createDevTools } from 'redux-devtools';\nimport LogMonitor from 'redux-devtools-log-monitor';\nimport DockMonitor from 'redux-devtools-dock-monitor';\n// You can toggle visibility of devTools with ctrl + H\n// and change their position with ctrl + Q\nexport default createDevTools(\n <DockMonitor toggleVisibilityKey=\"ctrl-h\" changePositionKey=\"ctrl-q\" defaultIsVisible={false}>\n <LogMonitor />\n </DockMonitor>\n);\n"]}]}
|
||||
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary.tsx","mtime":1533613273369},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import * as tslib_1 from \"tslib\";\nimport React from 'react';\nvar ErrorBoundary = /** @class */ (function (_super) {\n tslib_1.__extends(ErrorBoundary, _super);\n function ErrorBoundary() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n _this.state = { error: undefined, errorInfo: undefined };\n return _this;\n }\n ErrorBoundary.prototype.componentDidCatch = function (error, errorInfo) {\n this.setState({\n error: error,\n errorInfo: errorInfo\n });\n };\n ErrorBoundary.prototype.render = function () {\n var _a = this.state, error = _a.error, errorInfo = _a.errorInfo;\n if (errorInfo) {\n var errorDetails = process.env.NODE_ENV === 'development' ? (React.createElement(\"details\", { className: \"preserve-space\" },\n error && error.toString(),\n React.createElement(\"br\", null),\n errorInfo.componentStack)) : (undefined);\n return (React.createElement(\"div\", null,\n React.createElement(\"h2\", { className: \"error\" }, \"An unexpected error has occurred.\"),\n errorDetails));\n }\n return this.props.children;\n };\n return ErrorBoundary;\n}(React.Component));\nexport default ErrorBoundary;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/error/error-boundary.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B;IAA4B,yCAAyD;IAArF;QAAA,qEAgCC;QA/BU,WAAK,GAAwB,EAAE,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,EAAE,CAAC;;IA+BnF,CAAC;IA7BC,yCAAiB,GAAjB,UAAkB,KAAK,EAAE,SAAS;QAChC,IAAI,CAAC,QAAQ,CAAC;YACZ,KAAK,OAAA;YACL,SAAS,WAAA;SACV,CAAC,CAAC;IACL,CAAC;IAED,8BAAM,GAAN;QACQ,IAAA,eAAiC,EAA/B,gBAAK,EAAE,wBAAS,CAAgB;QACxC,IAAI,SAAS,EAAE;YACb,IAAM,YAAY,GAChB,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,aAAa,CAAC,CAAC,CAAC,CACvC,iCAAS,SAAS,EAAC,gBAAgB;gBAChC,KAAK,IAAI,KAAK,CAAC,QAAQ,EAAE;gBAC1B,+BAAM;gBACL,SAAS,CAAC,cAAc,CACjB,CACX,CAAC,CAAC,CAAC,CACF,SAAS,CACV,CAAC;YACJ,OAAO,CACL;gBACE,4BAAI,SAAS,EAAC,OAAO,wCAAuC;gBAC3D,YAAY,CACT,CACP,CAAC;SACH;QACD,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC;IAC7B,CAAC;IACH,oBAAC;AAAD,CAAC,AAhCD,CAA4B,KAAK,CAAC,SAAS,GAgC1C;AAED,eAAe,aAAa,CAAC","sourcesContent":["import React from 'react';\n\ninterface IErrorBoundaryProps {\n readonly children: JSX.Element | JSX.Element[];\n}\n\ninterface IErrorBoundaryState {\n readonly error: any;\n readonly errorInfo: any;\n}\n\nclass ErrorBoundary extends React.Component<IErrorBoundaryProps, IErrorBoundaryState> {\n readonly state: IErrorBoundaryState = { error: undefined, errorInfo: undefined };\n\n componentDidCatch(error, errorInfo) {\n this.setState({\n error,\n errorInfo\n });\n }\n\n render() {\n const { error, errorInfo } = this.state;\n if (errorInfo) {\n const errorDetails =\n process.env.NODE_ENV === 'development' ? (\n <details className=\"preserve-space\">\n {error && error.toString()}\n <br />\n {errorInfo.componentStack}\n </details>\n ) : (\n undefined\n );\n return (\n <div>\n <h2 className=\"error\">An unexpected error has occurred.</h2>\n {errorDetails}\n </div>\n );\n }\n return this.props.children;\n }\n}\n\nexport default ErrorBoundary;\n"]}]}
|
||||
@@ -0,0 +1 @@
|
||||
{"remainingRequest":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js??ref--4-2!/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js??ref--4-3!/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/footer/footer.tsx","dependencies":[{"path":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/footer/footer.tsx","mtime":1533613273125},{"path":"/var/www/html/payroll_manager/front-end/node_modules/react-hot-loader/webpack.js","mtime":1505850161000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/cache-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/thread-loader/dist/cjs.js","mtime":0},{"path":"/var/www/html/payroll_manager/front-end/node_modules/ts-loader/index.js","mtime":1530127508000},{"path":"/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js","mtime":1519899048000}],"contextDependencies":[],"result":["import './footer.scss';\nimport React from 'react';\nimport { Col, Row } from 'reactstrap';\nvar Footer = function (props) { return (React.createElement(\"div\", { className: \"footer page-content\" },\n React.createElement(Row, null,\n React.createElement(Col, { md: \"12\" },\n React.createElement(\"p\", null, \"Your footer\"))))); };\nexport default Footer;\n",{"version":3,"file":"/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/footer/footer.tsx","sourceRoot":"","sources":["/var/www/html/payroll_manager/front-end/node_modules/tslint-loader/index.js!/var/www/html/payroll_manager/front-end/src/main/webapp/app/shared/layout/footer/footer.tsx"],"names":[],"mappings":"AAAA,OAAO,eAAe,CAAC;AAEvB,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,GAAG,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEtC,IAAM,MAAM,GAAG,UAAA,KAAK,IAAI,OAAA,CACtB,6BAAK,SAAS,EAAC,qBAAqB;IAClC,oBAAC,GAAG;QACF,oBAAC,GAAG,IAAC,EAAE,EAAC,IAAI;YACV,6CAAkB,CACd,CACF,CACF,CACP,EARuB,CAQvB,CAAC;AAEF,eAAe,MAAM,CAAC","sourcesContent":["import './footer.scss';\n\nimport React from 'react';\n\nimport { Col, Row } from 'reactstrap';\n\nconst Footer = props => (\n <div className=\"footer page-content\">\n <Row>\n <Col md=\"12\">\n <p>Your footer</p>\n </Col>\n </Row>\n </div>\n);\n\nexport default Footer;\n"]}]}
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user