- http://stackoverflow.com/questions/804115 (
rebase
vsmerge
). - https://www.atlassian.com/git/tutorials/merging-vs-rebasing (
rebase
vsmerge
) - https://www.atlassian.com/git/tutorials/undoing-changes/ (
reset
vscheckout
vsrevert
) - http://stackoverflow.com/questions/2221658 (HEAD^ vs HEAD~) (See
git rev-parse
) - http://stackoverflow.com/questions/292357 (
pull
vsfetch
) - http://stackoverflow.com/questions/39651 (
stash
vsbranch
) - http://stackoverflow.com/questions/8358035 (
reset
vscheckout
vsrevert
)
Discover gists
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 | |
$column_progresso->setTransformer(function($value, $object, $row, $cell = null, $last_row = null) | |
{ | |
$bar = new TProgressBar; | |
$bar->setMask("<b>{value}</b>%"); | |
$bar->setValue($value); | |
if ($value == 100) { | |
$bar->setClass("success"); |
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 | |
public function onSave($param = null) | |
{ | |
try | |
{ | |
TTransaction::open(self::$database); | |
$itens = $this->fieldList_itensVenda->getPostData(); |
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 | |
$data_cadastro = $venda->data_cadastro; | |
$data = new DateTime($data_cadastro); | |
echo $data->format('d/m/Y H:i:s'); | |
$data = DateTime::createFromFormat('Y-m-d H:i:s', $data_venda)->format( 'd/m/Y H:i:s'); | |
# RESULTADO: 16/02/2023 09:45:00 |
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 | |
class Funcao | |
{ | |
public static function restKey() | |
{ | |
# CARREGA O ARQUIVO application.ini | |
$ini = AdiantiApplicationConfig::get(); | |
# PEGA OS DADOS DO REST KEY |
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 | |
$horas = ['00:04:35', '00:02:06', '01:09:12']; | |
$sum = strtotime('00:00:00'); | |
$totaltime = 0; | |
foreach( $horas as $element ) |
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 | |
$pessoa = new TDBUniqueSearch(..... | |
$pessoa ->setOperator('like'); |
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 | |
$this->fieldList_item = new TFieldList(); | |
$this->criteria_fieldList_item = new TCriteria(); | |
# ADICIONE APÓS ESSA MARCAÇÃO NO ADIANTI BUILDER - onBeforeAddFieldsToForm | |
//<onBeforeAddFieldsToForm> | |
# AQUI TÁ SENDO APLICADO O FILTRO |
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 | |
$cliente = Cliente::find(1); | |
$arquivo = $cliente->imagem_base64; | |
$caminho = 'app/output/imagem'; | |
$explode = explode(";base64,", $arquivo); | |
$tipo = explode("image/", $explode[0]); | |
$extensao = $tipo[1]; |
NewerOlder