Journal Entry, June 28th to July 5th 2019

July 5, 2019 · 1 min read


  1. Tue Jul 2

    • Actions in Laravel pass in a collection of models. On the index screen this could be hundreds but on the detail screen it is always exactly 1, the parent model.
    • This wasn't quite as easy to grok without attaching a debugger but this makes complete sense now.

       * Perform the action on the given models.
       * @param  \Laravel\Nova\Fields\ActionFields  $fields
       * @param  \Illuminate\Support\Collection  $models
       * @return mixed
      public function handle(ActionFields $fields, Collection $models)
          $count = 1;
          foreach ($models as $model) {
              $count = $this->generateCodes($model->id, $model->code_type_id, $fields->number);
          return Action::message("$count codes were successfully created.");

Phoenix Framework

  1. Sat Jun 29

    • Initial commit
    • Changes to .gitignore for VSCode integration and to remove /config/*.secret.exs. It's unclear if this was present in the earlier version of Phoenix and I weirdly need to add it. It's also possible that I just followed along with the up and running guide.
    • Added editorconfig from .editorconfig for Elixir projects · GitHub