Skip to content

Instantly share code, notes, and snippets.

View elton182's full-sized avatar

Elton Nicolau elton182

View GitHub Profile
<?php
namespace safed\Traits;
Trait DataTablesTrait{
/**
* receices the model collection with records and return a json needed for the datatable
* receives de name of the Controller to generate correct URLs
* receives the customfields (for relations) that you want to return with the json
@elton182
elton182 / validaContaSantander.js
Created August 5, 2019 22:55
Validação Digito Conta Corrente Santander
var agencia = '0189'
var conta = '01017417'
var dig = 9
var retorno = validaSantander(agencia,conta,dig);
console.log(retorno);
function validaSantander(agencia, conta, digito){
@elton182
elton182 / fluig_datepicker.html
Created July 6, 2017 13:18
fluig datepicker
<div class="form-group">
<label for="only-date">Data Emissão</label>
<div class="input-group date" id="dataEmissao">
<input type="text" class="form-control" placeholder="Informe a data de emissão" name="dataEmissao">
<span class="input-group-addon">
<span class="fluigicon fluigicon-calendar"></span>
</span>
</div>
</div>
@elton182
elton182 / UserController.php
Last active January 2, 2024 20:17
(Cakephp) Datatable Example - With custom column search and cache pagination
<?php
namespace App\Controller;
use App\Controller\AppController;
use Cake\Network\Email\Email;
/**
* Users Controller
*
* @property \App\Model\Table\UsersTable $Users