Skip to content

Instantly share code, notes, and snippets.

@devfabriciobr
devfabriciobr / .php
Created November 18, 2026 19:58
DESABILITAR ABERTURA AUTOMÁTICA CALENDÁRIO CAMPO TDate
<?php
$data_registro = new TDate('data_registro');
$data_registro->setMask('dd/mm/yyyy');
$data_registro->setDatabaseMask('yyyy-mm-dd');
$data_registro->setSize('100%');
$data_registro->setOption('showOnFocus', false); # DESABILITA CALENDÁRIO
@devfabriciobr
devfabriciobr / .txt
Created November 14, 2026 17:15
REGRAS GLOBAIS CLAUDE.md ( WIN + R (EXECUTAR WINDOWS): %USERPROFILE%\.claude )
# CLAUDE.md GLOBAL RULES
## Code
- Write the least code that fully solves the task. No speculative features, abstractions, config, or flags.
- Before writing code, in order: can deleting or not building solve it? Does the repo already have it? Does the framework provide it natively? Does the standard library cover it? Only then write custom code.
- No new dependency for anything under ~20 lines. New dependencies need a stated reason.
- Follow existing project conventions over personal preference.
- Don't refactor, rename, or reformat code outside the task.
## Never skip (quality guardrails)
@devfabriciobr
devfabriciobr / .txt
Last active November 14, 2026 17:03
IMPORTAR SKILL NO CLAUDE.md
# WIN + R (EXECUTAR WINDOWS): %USERPROFILE%\.claude
# CRIAR O CLAUDE.md GERAL COM REGRAS GLOBAIS
C:\Users\Administrator\.claude\CLAUDE.md
# CRIAR SKILL SEPARADAS
C:\Users\Administrator\.claude\adianti.md
C:\Users\Administrator\.claude\filament.md
CLAUDE.md (PROJETO) - GERADO PELO COMANDO /init
@devfabriciobr
devfabriciobr / gist:286a1885a38c4e02bd534a8da141b67c
Created November 5, 2026 19:03
PROGRAMA ACESSO REMOTO OPEN SOURCE (HopToDesk)
Download HopToDesk
https://dl.hoptodesk.com/HopToDesk.exe
@devfabriciobr
devfabriciobr / .sql
Created November 5, 2026 14:46
SQL LIMPAR REGISTROS E RESETAR O ID
(PostgreSQL)
BEGIN;
TRUNCATE TABLE
cliente
venda_item,
venda
RESTART IDENTITY CASCADE;
COMMIT;
(MySQL)
@devfabriciobr
devfabriciobr / .php
Created October 28, 2026 00:07
EXEMPLO BOTÃO DROPDOWN (TDropDown)
<?php
$dropdownFooter = new TDropDown("LANÇAMENTOS", 'fas:plus #000000');
$dropdownFooter->setPullSide('left');
$dropdownFooter->setButtonClass('btn btn-sm btn-default dropdown-toggle');
$btn_onshow = $dropdownFooter->addAction("ENTRADA", new TAction(['EntradaForm', 'onShow']), 'fas:dollar-sign #000000');
$btn_onshow = $dropdownFooter->addAction("SAÍDA", new TAction(['SaidaForm', 'onShow']), 'fas:dollar-sign #000000');
$this->form->addFooterWidget($dropdownFooter);
@devfabriciobr
devfabriciobr / .txt
Created October 27, 2026 13:59
Template Material Admin Pro Bootstrap
Template Material Admin Pro Bootstrap
https://startbootstrap.com/previews/material-admin-pro
@devfabriciobr
devfabriciobr / CLAUDE.txt
Last active November 3, 2026 18:00
REGRAS ADICIONAIS PARA O PROJETO CLAUDE.md (ADIANTI FRAMEWORK)
## ADICIONAR NO FINAL DO ARQUIVO CLAUDE.md
## REGRAS ADICIONAIS DO PROJETO (CLAUDE.md) ADIANTI FRAMEWORK
### Language
- **Always reply to the user in Brazilian Portuguese (pt-BR)**: explanations, summaries, questions, plans and reports of what was done. Keep code, identifiers, file paths, commands and technical terms in their original form.
### A. Adianti framework (`lib/adianti`)
- **NEVER, under any circumstances, modify, create or delete files inside `lib/adianti/`** (framework classes and methods). This folder is **read-only**: read it only for analysis and learning, in order to generate correct and working Adianti code.
- If something seems to require a framework change, solve it **in application code** (`app/`) by extending classes, using hooks or creating helpers. If that is impossible, stop and tell me instead of editing `lib/`.
@devfabriciobr
devfabriciobr / .php
Created October 24, 2026 21:39
HABILITAR CÂMERA NO CELULAR TFile
<?php
$foto_cliente->{'accept'} = "image/*;capture=camera";
@devfabriciobr
devfabriciobr / .php
Created October 24, 2026 21:33
VALIDAR CPF OU CNPJ
<?php
(new TCPFValidator)->validate('CPF', $param['cpf']);
(new TCNPJValidator)->validate('CNPJ', $param['cnpj']);