This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @var \App\View\AppView $this | |
* @var \App\Model\Entity\Facture $facture | |
*/ | |
?> | |
<table> | |
<thead> | |
<tr> | |
<th><?= __('Date') ?></th> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Spreadsheet; | |
use App\Model\Entity\Facture; | |
use Cake\Http\Response; | |
use Cake\Http\Session; | |
use Cake\View\View; | |
use PhpOffice\PhpSpreadsheet\IOFactory; | |
use PhpOffice\PhpSpreadsheet\Reader\Html; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Model\Entity; | |
use App\Utility\Overtime; | |
use App\Utility\Periode; | |
use Cake\Collection\Collection; | |
use Cake\ORM\Entity; | |
use Cake\ORM\TableRegistry; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function index($week = null, $year = null) | |
{ | |
// Si variable non défini choisi semaine courante | |
if (!$year) { | |
$year = date("Y"); | |
} | |
if (!$week) { | |
$week = date("W") - 1; | |
} | |
// Range de date |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function index() { | |
// if($this->request->is('ajax')){ | |
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'XMLHttpRequest'; | |
// $this->request->allowMethod('ajax'); | |
$this->loadComponent('Ajax.Ajax'); | |
// } | |
$carottiers = [1=>'bgdyuvgfdfcyuwe',2=>'ubvyfuvbc']; | |
$this->set([$carottiers,'_serialize'=>['carottiers']]); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Routes configuration | |
* | |
* In this file, you set up routes to your controllers and their actions. | |
* Routes are very important mechanism that allows you to freely connect | |
* different URLs to chosen controllers and their actions (functions). | |
* | |
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org) | |
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Routes configuration | |
* | |
* In this file, you set up routes to your controllers and their actions. | |
* Routes are very important mechanism that allows you to freely connect | |
* different URLs to chosen controllers and their actions (functions). | |
* | |
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org) | |
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Controller; | |
use Cake\ORM\TableRegistry; | |
use Cake\I18n\Time; | |
use iio\libmergepdf\Merger; | |
/** | |
* Factures Controller | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Router::scope('/', function (RouteBuilder $routes) { | |
$routes->extensions(['json', 'pdf']); | |
$routes->resources('Clients', function (RouteBuilder $routes) { | |
$routes->resources('Localisations'); | |
}); | |
$routes->resources('Contrats'); | |
$routes->resources('Holes'); | |
$routes->resources('ContratsProduits'); | |
$routes->resources('ContratsEmployees'); | |
$routes->resources('ContratsEquipements', [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$paie = $this->Paies->get($id, [ | |
'contain' => [ | |
'Contrats.Entreprises.Pays', | |
'Contrats.Entreprises.Provinces', | |
'PaieHeures'=> function (Query $q) { | |
debug($q->select(['date', "h_payable"=>$q->func()->sum('h_payable'), 'fonction_id', 'task_id','taux_reg'])->order(['date'])); | |
die(); | |
}, | |
'PaieHeures.Fonctions', | |
'PaieHeures.Equipements', |
NewerOlder