Skip to content

Instantly share code, notes, and snippets.

@Tharos
Tharos / Applicant.js
Created October 3, 2017 08:34
First Mithril app
'use strict';
var constants = require('./constants');
var Applicant = function (type) {
this.type = type;
this.laboratoryId = null;
this.institution = null;
<?php
use Nette\Neon\Neon;
use Schematic\Entries;
use Schematic\Entry;
// composer.json
// {
// "require": {
@Tharos
Tharos / gist:8680094dddc708f65c27
Created November 16, 2014 12:44
Query Objects with Lean Mapper (snippet)
<?php
/**
* Vykreslení přehledu produktů v e-shopu
*
* @var Filter $filter Filtr, který omezuje množinu produktů podle nastavení uživatele
* @var int|null $limit Počet produktů zobrazených na stránce
* @var VisualPaginatorHelper $visualPaginatorHelper Jednoduchý helper, který pomáhá inicialzovat Paginator (Nette)
* @var VisualPaginator $visualPaginator VisualPaginator (Nette)
* @var Template $template Šablona view
@Tharos
Tharos / Mapper.php
Last active December 21, 2015 06:39
Translations in Lean Mapper. See http://www.leanmapper.com/samples/translations.zip for working example.
<?php
namespace Model;
class Mapper extends \LeanMapper\DefaultMapper implements ITranslatingMapper
{
/**
* @return string
*/