Skip to content

Instantly share code, notes, and snippets.

View fdonzello's full-sized avatar
🏠
Working from home

Francesco Donzello fdonzello

🏠
Working from home
View GitHub Profile
/**
* Fm\DocumentBundle\Entity\Document
*
* @ORM\Table()
* @ORM\Entity
* @ORM\InheritanceType("SINGLE_TABLE")
* @ORM\DiscriminatorColumn(name="type", type="string")
* @ORM\DiscriminatorMap({"playerList" = "PlayerList", "playerPrice" = "PlayerPrice", "avatar" = "Avatar", "playerPhoto" = "PlayerPhoto", "teamPhoto" = "TeamPhoto"})
* @ORM\HasLifecycleCallbacks
*/
@fdonzello
fdonzello / gist:2e1fa38e9e7c0aa85aa4
Created August 11, 2015 12:57 — forked from avimar/gist:3092732
install node.js from source with salt
nodejs-deps:
pkg.installed:
- names:
- g++
- curl
- libssl-dev
- apache2-utils
- build-essentials
require:
- pkg: git
@fdonzello
fdonzello / per_day_missing_fixtures.txt
Last active May 9, 2016 07:32
Formazioni non consegnate per giornata
*************************** 1. row ***************************
day: 6
fantateam: la Marchigiana
*************************** 2. row ***************************
day: 9
fantateam: la Marchigiana
*************************** 3. row ***************************
day: 11
fantateam: LinxLab
*************************** 4. row ***************************
@fdonzello
fdonzello / aggregate_missing_fixtures.txt
Created May 9, 2016 07:32
Formazioni non consegnate COUNT
*************************** 1. row ***************************
missing_fixture: 18
fantateam: la Marchigiana
*************************** 2. row ***************************
missing_fixture: 11
fantateam: Mexico United
*************************** 3. row ***************************
missing_fixture: 5
fantateam: Palazzinarese
*************************** 4. row ***************************
@fdonzello
fdonzello / .m
Created September 28, 2017 09:02
@implementation BridgeManagersNetwork
+ (NSString *)userAgent
{
return @"custom-user-agent-to-be-defined";
}
- (FBLResponse *)executeWithFBLApiRequest:(FBLApiRequest *)apiRequest
{
// implementazione del metodo GET e POST
@fdonzello
fdonzello / .m
Created September 28, 2017 09:08
use
// creazione classe che gestisce le api per i feeds
FBLFeedsApi *feedsApi = [[FBLFeedsApi alloc] initWithFBLNetworkManager:BRIDGE_NETWORK_NEW_MANAGER];
// chiamata alle api (bloccante)
FBLFeedResponse *feedResponse = [feedsApi get];
if ( [feedResponse isSuccess] )
{
// ogni response è uguale. isSuccess, getData, ....
[feedResponse getData]....
@fdonzello
fdonzello / server.js
Last active December 4, 2018 15:17
demo ng6
var sqlite3 = require("sqlite3").verbose();
var db = new sqlite3.Database("db");
db.serialize(function () {
db.run(
"CREATE TABLE IF NOT EXISTS users (name TEXT, password TEXT, role TEXT)"
);
db.run(
"INSERT INTO users (name, password, role) VALUES (?, ?, ?)",
"admin",
@fdonzello
fdonzello / db.json
Last active December 4, 2018 13:27
BRUX-4-12-18
{
"articles": [
{
"id": 1,
"title": "Belgium beers are awesome",
"description": "oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome oh yeah, awesome ",
"date": "2016-04-19T18:03:40.887",
"author": "francesco"
},
{
@fdonzello
fdonzello / db.json
Created January 31, 2019 10:00
Lux 30-31-jan
{
"results": [
{
"id": 132579,
"day": 21,
"redaction_id": 2,
"player_id": 157,
"player_name": "H. Kane",
"played": true,
"arbitrary": false,
@fdonzello
fdonzello / db.json
Last active February 5, 2019 08:28
Lux 04-05 Feb 19
{
"users": [
{
"id": 1,
"firstname": "Alan",
"lastname": "Sorrenti",
"email": "alan@email.me"
}
],
"news": [