-
言語系 Japanese Language Pack / 日本語言語パック envファイル .env files support 変数名変換系(スネーク、キャメル) String Manipulati …
-
PHPフレームワーク Laravel Webアプリケーション開発 バージョン8.x対応 [ 竹澤 有貴 ] のメモ
PHPフレームワーク Laravel Webアプリケーション開発 バージョン8.x対応 [ 竹澤 有貴 ] 価格:4180円(税込、送料無料) (2022/7/22時点) 楽天で購入 俺 …
-
楽天ふるさと納税では、税金で支援を行っている地域に直接寄付することができる制度です。 平成27年度より全国からの寄付が可能となり、年間の寄付金額は全国総額で2億円を超えているようです。 納税者は、支援 …
-
Binance Chainは、仮想通貨取引所であるBinanceが開発した、複数の仮想通貨のトークン・アルファットチェックブロックの機能を備えたネットワークです。 トークン・アルファットチェックブロッ …
-
Bybitは、2018年3月に設立したフィンテック企業であり、世界で最も成長しているバイナリーオプション交換プラットフォームです。 Bybitは、Cryptocurrencyを通貨ペアとして提供してい …
-
Bybit (バイビット) で クラウドマイニング してみた
Bybitでクラウドマイニングしてみました。 期間: 2021年9月25日 〜 2021年10月1日 (7日間) 購入代金: 288.94USDT 実現総マイニング収益(ETH): 0.1139279 …
-
翔泳社「AWSではじめるインフラ構築入門 安全で堅牢な本番環境のつくり方」メモ
AWSではじめるインフラ構築入門 安全で堅牢な本番環境のつくり方 第3章 ※AWSアカウント作成後にやること ルートユーザーのアクセスキーの削除 ルートユーザーのMFAを有効化 個々のIAMユーザーの …
-
モデル周り
123456789101112131415161718192021222324Schema::create('user_mails', function (Blueprint $table) {$table->bigIncrements('user_mail_id');$table->bigInteger('user_id')->unsigned()->comment('ユーザーID');$table->timestamps();$table->softDeletes();$table->foreign('user_id')->references('user_id')->on('users');});protected $fillable = ['user_id',];=Userpublic function userMails(): HasMany{return $this->hasMany('App\Models\UserMail', 'user_id');}=UserMailpublic function user(): BelongsTo{return $this->belongsTo('App\Models\User', 'user_id');}データ抽出
123456789101112131415$query = User::leftJoin('user_mails', function ($join) {$join->on('users.user_id', '=', 'user_mails.user_id')->whereNull('user_mails.deleted_at');});$query->select(['users.email',\DB::raw('(case when user_mails.user_mail_id is not null then 1 else 0 end) as is_mail')]);$query->where('user_mails.user_mail_id', 1);$query->where(function ($subQuery) use ($keyword) {$subQuery->where('users.name', 'LIKE', "%{$keyword}%")->orWhere('users.email', 'LIKE', "%{$keyword}%");});
-
2021/05/23 -その他
想定担当範囲 バックエンド開発メンバー ワイヤーフレーム ページネーションありなし(ある場合1ページあたりの件数) ajax処理ありなし 一覧ソート順 その他 仕様変更に対応するため初期はテストコード …
-
俺のDocker+PhpStorm 勉強用リンク【随時更新】
2020/12/15 -Docker
docker, docker-compose, phpstorm, xdebug仕事で一時的にDocker+PhpStormを触ることになったので、その勉強用リンクです。 Docker+PhpStorm+xdebug ・PhpStorm & Docker ( …
-
Laravel6のartisanコマンド一覧です。
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110$ php artisan listLaravel Framework 6.20.2Usage:command [options] [arguments]Options:-h, --help Display this help message-q, --quiet Do not output any message-V, --version Display this application version--ansi Force ANSI output--no-ansi Disable ANSI output-n, --no-interaction Do not ask any interactive question--env[=ENV] The environment the command should run under-v|vv|vvv, --verbose Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debugAvailable commands:clear-compiled Remove the compiled class filedown Put the application into maintenance modeenv Display the current framework environmenthelp Displays help for a commandlist Lists commandsmigrate Run the database migrationsoptimize Cache the framework bootstrap filespreset Swap the front-end scaffolding for the applicationserve Serve the application on the PHP development servertinker Interact with your applicationui Swap the front-end scaffolding for the applicationup Bring the application out of maintenance modeauthauth:clear-resets Flush expired password reset tokenscachecache:clear Flush the application cachecache:forget Remove an item from the cachecache:table Create a migration for the cache database tableconfigconfig:cache Create a cache file for faster configuration loadingconfig:clear Remove the configuration cache filedbdb:seed Seed the database with recordsdb:wipe Drop all tables, views, and typeseventevent:cache Discover and cache the application's events and listenersevent:clear Clear all cached events and listenersevent:generate Generate the missing events and listeners based on registrationevent:list List the application's events and listenerskeykey:generate Set the application keymakemake:channel Create a new channel classmake:command Create a new Artisan commandmake:controller Create a new controller classmake:event Create a new event classmake:exception Create a new custom exception classmake:factory Create a new model factorymake:job Create a new job classmake:listener Create a new event listener classmake:mail Create a new email classmake:middleware Create a new middleware classmake:migration Create a new migration filemake:model Create a new Eloquent model classmake:notification Create a new notification classmake:observer Create a new observer classmake:policy Create a new policy classmake:provider Create a new service provider classmake:request Create a new form request classmake:resource Create a new resourcemake:rule Create a new validation rulemake:seeder Create a new seeder classmake:test Create a new test classmigratemigrate:fresh Drop all tables and re-run all migrationsmigrate:install Create the migration repositorymigrate:refresh Reset and re-run all migrationsmigrate:reset Rollback all database migrationsmigrate:rollback Rollback the last database migrationmigrate:status Show the status of each migrationnotificationsnotifications:table Create a migration for the notifications tableoptimizeoptimize:clear Remove the cached bootstrap filespackagepackage:discover Rebuild the cached package manifestqueuequeue:failed List all of the failed queue jobsqueue:failed-table Create a migration for the failed queue jobs database tablequeue:flush Flush all of the failed queue jobsqueue:forget Delete a failed queue jobqueue:listen Listen to a given queuequeue:restart Restart queue worker daemons after their current jobqueue:retry Retry a failed queue jobqueue:table Create a migration for the queue jobs database tablequeue:work Start processing jobs on the queue as a daemonrouteroute:cache Create a route cache file for faster route registrationroute:clear Remove the route cache fileroute:list List all registered routesscheduleschedule:run Run the scheduled commandssessionsession:table Create a migration for the session database tablestoragestorage:link Create a symbolic link from "public/storage" to "storage/app/public"uiui:auth Scaffold basic login and registration views and routesvendorvendor:publish Publish any publishable assets from vendor packagesviewview:cache Compile all of the application's Blade templatesview:clear Clear all compiled view files
-
プログラミングでよく使う英単語のまとめです。 all change check disable display enable error exists find first last generate …
-
2019/09/25 -PHP7
Visual Studio Code個人的な設定メモです。 日本語化 メニューバー「表示」-「空白を表示」「制御文字を表示」をオン プラグイン「PHP Debug」インストール
-
仕事で一時的にRuby on Rails 5を触ることになったので、その勉強用リンクです。 DB検索 RubyonRails:Rails5で使えるデータ検索関連のメソッドをまとめてみた Rails M …
-
Nginx fastcgi_passを127.0.0.1からソケット通信に変更する方法
2018/11/18 -Nginx
fastcgi_pass, nginx, Socket, ソケット通信, チューニング, ループバックアドレスNginx(ver 1.13)のfastcgi_passを127.0.0.1:9000からソケット(Socket)通信に変更する方法です。 [crayon-647dca693f54f853671839 …
-
CakePHP3 Template用にsetした値を参照する方法
2018/11/13 -コントローラー(Controller)
set, Template, viewVarsCakePHP3 Template用にsetした値を参照する方法です。
123456<?php$aaa = 'test';$this->set('bbb', $aaa);var_dump($this->viewVars['bbb']);// 出力結果: test
-
CakePHP3 scriptタグ(HTMLヘルパー)のdefer・async属性設定方法
2018/11/09 -ビュー(Template)
async, defer, HtmlHelper, JavaScript, scriptCakePHP3 scriptタグ(HTMLヘルパー)のdefer・async属性オプションの設定方法です。
123456789101112131415// CakePHP3 HTMLヘルパー($this->Html->script - defer属性)<?= $this->Html->script(['jquery.min.js', 'bootstrap/bootstrap.min.js'], ['defer' => true])?>// 生成されるHTML<script src="/js/jquery.min.js" defer="defer"></script><script src="/js/bootstrap/bootstrap.min.js" defer="defer"></script>// CakePHP3 HTMLヘルパー($this->Html->script - async属性)<?= $this->Html->script(['jquery.min.js', 'bootstrap/bootstrap.min.js'], ['async' => true])?>// 生成されるHTML<script src="/js/jquery.min.js" async="async"></script><script src="/js/bootstrap/bootstrap.min.js" async="async"></script>