Skip to content

Instantly share code, notes, and snippets.

@carneirocorp
carneirocorp / 0_reuse_code.js
Created August 1, 2014 04:57
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
"pedido": {
"id": 1,
"status": "Pedido enviado (rastreio pelo link)",
"envio": {
"link": "http://tracking.totalexpress.com.br/poupup_track.php?reid=2964&pedido=21530932811&nfiscal=5369",
"transportadora": {
"id": 1,
"nome": "correios"
}
}
{
"phases": [
{
"filter": [
{
"field": "",
"compare": ">",
"value": "",
"boolean": "AND"
},
{
"workflow_id": 123, /* Obteria as ações a partir do id do wf */
"suppliers": [ 18, 22, 223, 3431, 1234123 ], /* IDs dos fornecedores */
"execution": [ "2017-12-28 12:23:00" ], /* Opção de múltiplas execuções */
"recurrence": [ "daily", "monthly" ] /* Opção de configurar recorrência, talvez usar o padrão de anotação do crontab */
}
{
"filters": [
{
"id": 1,
"text": "Tipoo de empresa",
"eq": [
{
"id": "EQ",
"name": "Igual a"
},

public/view/propostas/detail.html

<div class="row">
    <div class="col s12 m6" id="timeline">
    </div>
</div>

public/js/proposta.table.js

@carneirocorp
carneirocorp / privacy.html
Created December 24, 2018 22:46
AI Extractor policy
<h1>Privacy Policy</h1>
<p>Effective date: December 24, 2018</p>
<p>AC Consultoria ("us", "we", or "our") operates the https://about.me/carneirinho website (the "Service").</p>
<p>This page informs you of our policies regarding the collection, use, and disclosure of personal data when you use our Service and the choices you have associated with that data. Our Privacy Policy for AC Consultoria is based on the <a href="https://www.freeprivacypolicy.com/blog/sample-privacy-policy-template/">Free Privacy Policy Template Website</a>.</p>
@carneirocorp
carneirocorp / gist:9f9458b3c2938655c9bf9305d4a86899
Created February 26, 2019 22:26
lista com twoway binding
<tbody>
<tr *ngFor="let item of contrato.contractItemViewModels; let in = index" >
<td>{{ item.contractItem }}</td>
<td>{{ item.productCode }}</td>
<td>{{ item.shortDescription }}</td>
<td>{{ item.value | currency:'BRL' }}</td>
<td><input type="number" class="form-control" [(ngModel)]="contrato.contractItemViewModels[in].stockPlanned" [ngModelOptions]="{standalone: true}" /></td>
<td><input type="number" class="form-control" [(ngModel)]="contrato.contractItemViewModels[in].stockCustomer" [ngModelOptions]="{standalone: true}" /></td>
<td><input type="number" class="form-control" [(ngModel)]="contrato.contractItemViewModels[in].stockControl" [ngModelOptions]="{standalone: true}" /></td>
</tr>
Finalidade: pagamento
=====================
POST /api/pdv/payment
Payload:
{
orderId: number,
finalPrice: number,
comments: string,
{
"_id" : "21484",
"CreatedAt" : {
"$date" : 1597800435631
},
"DeletedAt" : null,
"AlternativeOption" : "Substituir por produto similar",
"ScheduleDescription" : "19/8/2020 - das 08:00 - 19:00",
"DeliveryMessage" : "Agendamento de entrega",
"Products" : [