Skip to content

Instantly share code, notes, and snippets.

View amitaibu's full-sized avatar

Amitai Burstein amitaibu

View GitHub Profile
2019/11/07 set initial assets balance
(assets:banks:BOA) USD50
(assets:banks:CITI) USD500
2019/11/10 Some payment from BOA
expenses:food USD60 ; <- This means "assets:banks:BOA" should be negative
assets:banks:BOA
P 2019-01-01 USD ILS5
2019/01/01 set initial assets balance
(assets:banks:ils) ILS500
(assets:banks:us) USD100
2019/11/07 Salaries Israel
expenses:salary:Israel ILS400
assets:banks:ils
main =
   Browser.element
       { init = App.Update.init
-       , update = App.Update.update
+       , update = Update.Fetch.andThenFetch App.Fetch.fetch App.Update.update
       , view = App.View.view
       , subscriptions = App.Update.subscriptions
 }
<?php
/**
* @file
* Contains \HedleyMigrateUsers.
*/
/**
* Class HedleyMigrateUsers.
*/
APIVersion: v1.6.0
name: my-drupal8-site
type: php
docroot: ""
php_version: "7.1"
webserver_type: nginx-fpm
router_http_port: "80"
router_https_port: "443"
xdebug_enabled: false
additional_hostnames: []
ddev composer create drupal-composer/drupal-project:8.x-dev --stability dev --no-interaction
Warning: Any existing contents of the project root (/Users/itama/Sites/my-drupal8-site) will be removed
Removing any existing files in project root
Executing composer command: composer create-project drupal-composer/drupal-project:8.x-dev /var/www/html/.tmp_ddev_composer_create_VjDray --stability dev --no-interaction
Installing drupal-composer/drupal-project (8.x-dev 4229acea4bb6181f421e8dd0e72a02ccdc98df1d)
- Installing drupal-composer/drupal-project (8.x-dev 4229ace): Cloning 4229acea4b from cache
Created project in /var/www/html/.tmp_ddev_composer_create_VjDray
> DrupalProject\composer\ScriptHandler::checkComposerVersion
Loading composer repositories with package information
type alias Site =
{ label : String
, machineName : String
, statusCount : EveryDict Status Int
-- For UI puropses
, showStatus : EveryDict Status Bool
}
function show_query($sale_nid) {
$query = db_select('node', 'n');
$query->fields('n', ['nid', 'uid']);
$field_names = [
'field_sale',
'field_user',
'field_website_bidder_id',
];
module Backend.Endpoint
exposing
( (</>)
, AccessToken
, BackendUrl
, EndPoint
, Entity
, EntityDictList
, EntityId
, EntityUuid
@amitaibu
amitaibu / Model.elm
Created December 23, 2017 18:39
Excerpt of Item's status
{-| These are the the states of an open item. You will notice there is a state
called `GoneTranstion` which exists under the Open. This state is a special case
that really exists only as a transition state. That is, when we want to finish
the sale of an item we cannot decide ourself it it's "sold" or "unsold" - that
is the responsibility of the server. So we will send the server a `gone` request,
which will be later decided if the item is sold or not.
So a `GoneTransition` is a very temporarye state, for until we are clear on the `SoldStatus`.
This also works the other way around. That is, when we are in `ItemClosed` state, the clerk
may still go back to `Going` or `Open` in case there was some mistake or a bid was
placed in the room in the right time.