{"id":12511,"date":"2024-03-31T07:00:15","date_gmt":"2024-03-30T22:00:15","guid":{"rendered":"https:\/\/blog.capilano-fw.com\/?p=12511"},"modified":"2024-03-26T06:54:30","modified_gmt":"2024-03-25T21:54:30","slug":"laravel-%e3%81%a7%e3%80%8c%e3%82%ab%e3%82%b9%e3%82%bf%e3%83%9e%e3%83%bc%e3%82%b8%e3%83%a3%e3%83%bc%e3%83%8b%e3%83%bc%e3%80%8d%e3%82%92%e6%84%8f%e8%ad%98%e3%81%97%e3%81%9f%e3%83%a1%e3%83%ab%e3%83%9e","status":"publish","type":"post","link":"https:\/\/blog.capilano-fw.com\/?p=12511","title":{"rendered":"Laravel \u3067\u300c\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u300d\u3092\u610f\u8b58\u3057\u305f\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3092\u3064\u304f\u308b"},"content":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u307e\u3060\u307e\u3060\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u306e\u52c9\u5f37\u3092<code>Laravel<\/code>\u306b\u6d3b\u304b\u3057\u305f\u3044\u4eca\u65e5\u3053\u306e\u9803\u3067\u3059\u3002<\/p>\n<p>\u524d\u56de\u306e\u8a18\u4e8b\u306e\u7d9a\u304d\u306a\u306e\u3067\u3059\u304c\u3001\u307e\u305f\u65b0\u305f\u306a\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u7528\u8a9e\u306b\u51fa\u4f1a\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u308c\u306f\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><span style=\"font-size: 35px;\"><b>\u300c<strong style=\"font-size: 35px;\">\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc<\/strong>\u300d<\/b><\/span><\/p>\n<p>\u3067\u3059\u3002<\/p>\n<p>\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u3068\u306f\u3001\u7c21\u5358\u306b\u8a00\u3046\u3068\u300c<strong>\u304a\u5ba2\u3055\u3093\u304c\u3069\u3093\u306a\u6d41\u308c\u3067\u8cfc\u5165\u3059\u308b\u306e\u2753<\/strong>\u300d\u3067\u3059\u3002<\/p>\n<p>\u4f8b\u3048\u3070\u3001\u30d6\u30ed\u30b0\u3084<code>YouTube<\/code>\u304b\u3089\u6765\u305f\u4eba\u306a\u3089\u3001\u3088\u308a\u6df1\u3044\u77e5\u8b58\u3092\u5b66\u307c\u3046\u3068\u3044\u3046\u610f\u8b58\u304c\u5f37\u3044\u53cd\u9762\u3001\u30a4\u30f3\u30b9\u30bf\u30b0\u30e9\u30e0\u306a\u3089\u300c\u3082\u3063\u3068\u8efd\u3044\u6c17\u6301\u3061\u300d\u3067\u8a2a\u554f\u3057\u305d\u3046\u3067\u3059\u3002<\/p>\n<p>\u307e\u305f\u3001\u5e83\u544a\u7d4c\u7531\u306a\u3089\u3001\u51fa\u7a3f\u6761\u4ef6\u304c\u6c7a\u307e\u3063\u3066\u3044\u308c\u3070\u300c<strong>\u5bcc\u88d5\u5c64\u304c\u591a\u3044\u304b\u3089\u5358\u4fa1\u304c\u9ad8\u3044\u3082\u306e\u3092\u63d0\u6848\u3057\u3088\u3046<\/strong>\u300d\u3068\u3044\u3046\u5177\u5408\u306b\u30bb\u30fc\u30eb\u30b9\u306b\u6d3b\u304b\u3059\u3053\u3068\u304c\u3067\u304d\u308b\u308f\u3051\u3067\u3059\u306d\u3002<\/p>\n<p>\u305d\u3053\u3067\u2757<\/p>\n<p>\u4eca\u56de\u306f\u3053\u306e\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u3092\u610f\u8b58\u3057\u3066\u300c<strong>\u6d41\u5165\u7d4c\u8def<\/strong>\u300d\u3092\u6d3b\u304b\u3057\u305f\u30e1\u30eb\u30de\u30ac\u767b\u9332\u6a5f\u80fd\u3092<code>Laravel<\/code>\u3067\u4f5c\u3063\u3066\u307f\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u305c\u3072\u4f55\u304b\u306e\u53c2\u8003\u306b\u306a\u308a\u307e\u3057\u305f\u3089\u5b09\u3057\u3044\u3067\u3059\u3002\ud83d\ude04\u2728<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-4328 aligncenter\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/08\/no_3.png\" alt=\"\" width=\"364\" height=\"320\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/08\/no_3.png 364w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/08\/no_3-300x264.png 300w\" sizes=\"auto, (max-width: 364px) 100vw, 364px\" \/>\u300c\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc<br \/>\n\u3063\u3066\u306a\u3093\u304b<br \/>\n\u6614\u306e\u30d2\u30c3\u30c8\u30bd\u30f3\u30b0\u307f\u305f\u3044\u3067\u3059\u306d\u300d<\/p>\n<p><strong>\u958b\u767a\u74b0\u5883\uff1a<\/strong> Laravel 10.x<\/p>\n<h1>\u524d\u63d0\u3068\u3057\u3066<\/h1>\n<p>\u4eca\u56de\u306f\u524d\u56de\u8a18\u4e8b\u306e\u7d9a\u304d\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u305f\u3081\u3001\u30c6\u30fc\u30d6\u30eb\u69cb\u9020\u306f\u524d\u56de\u306e\u3082\u306e\u3092\u8e0f\u8972\u3057\u305f\u3082\u306e\u306b\u306a\u3063\u3066\u3044\u308b\u306e\u3067\u6c17\u3092\u3064\u3051\u3066\u304f\u3060\u3055\u3044\u3002\uff08\u30de\u30a4\u30b0\u30ec\u30fc\u30b7\u30e7\u30f3\u304c\u5f8c\u304b\u3089\u8ffd\u52a0\u306b\u306a\u3063\u3066\u308b\u30ab\u30f3\u30b8\u3067\u3059\uff09<\/p>\n<p>\u3082\u3057\u3054\u89a7\u306b\u306a\u3063\u3066\u3044\u306a\u3044\u65b9\u306f\u3001\u4ee5\u4e0b\u304b\u3089\u300c<strong>DB\u307e\u308f\u308a<\/strong>\u300d\u3060\u3051\u306f\u5b8c\u4e86\u3055\u305b\u3066\u304b\u3089\u3053\u3061\u3089\u3092\u304a\u8aad\u307f\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><strong>\ud83d\udcdd \u53c2\u8003\u30da\u30fc\u30b8\uff1a<\/strong>\u00a0<a href=\"https:\/\/blog.capilano-fw.com\/?p=12488\" target=\"_blank\" rel=\"noopener\">Laravel \u3067\u300c\u30c0\u30a4\u30ec\u30af\u30c8\u30fb\u30ec\u30b9\u30dd\u30f3\u30b9\u30fb\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u300d\u57fa\u790e\u30b7\u30b9\u30c6\u30e0\u3092\u3064\u304f\u308b<\/a><\/p>\n<h1>\u3084\u308a\u305f\u3044\u3053\u3068<\/h1>\n<p>\u4eca\u56de\u306f\u3001\u300c<strong>\u3069\u3053\u7d4c\u7531\u3067\u6d41\u5165\u3057\u3066\u304d\u305f\u30e1\u30eb\u30de\u30ac\u30e6\u30fc\u30b6\u30fc\u306a\u306e\u304b\uff1f<\/strong>\u300d\u304c\u5206\u304b\u308b\u3088\u3046\u306b\u300c<strong>\u6d41\u5165\u7d4c\u8def<\/strong>\u300d\u306e\u60c5\u5831\u3092<code>DB<\/code>\u30c6\u30fc\u30d6\u30eb\u306b\u4fdd\u5b58\u3059\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p>\u305f\u3060\u3001\u305d\u308c\u3060\u3051\u3067\u306f\u9762\u767d\u304f\u306a\u3044\u306e\u3067\u3001\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3057\u305f\u3089\u305d\u306e<strong>\u6d41\u5165\u7d4c\u8def\u306b\u95a2\u9023\u3059\u308b\u5546\u54c1\u306e\u5272\u5f15\u30af\u30fc\u30dd\u30f3\u3092\u9001\u4fe1<\/strong>\u3059\u308b\u3053\u3068\u306b\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u3001\u4eca\u56de\u3082\u697d\u3057\u3093\u3067\u3084\u3063\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u2757<\/p>\n<h1>\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u306e\u7a2e\u985e\u306e Enum \u3092\u3064\u304f\u308b<\/h1>\n<p>\u307e\u305a\u306f\u300c<strong>\u3069\u3053\u7d4c\u7531\u306e\u30b5\u30a4\u30c8\u6d41\u5165\u304b<\/strong>\u300d\u306e\u30bf\u30a4\u30d7\u3092\u5b9a\u7fa9\u3057\u3066\u304a\u3044\u3066\u3001\u3044\u3064\u3067\u3082\u53d6\u308a\u51fa\u305b\u308b\u3088\u3046\u306b\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u4eca\u56de\u7528\u610f\u3059\u308b\u306e\u306f\u3001\u4ee5\u4e0b\uff13\u3064\u306e\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u3067\u3059\u3002<\/p>\n<ul>\n<li>\u30e1\u30fc\u30eb\u7d4c\u7531<\/li>\n<li>\u30d6\u30ed\u30b0\u7d4c\u7531<\/li>\n<li>\u5e83\u544a\u7d4c\u7531<\/li>\n<\/ul>\n<p><strong>app\/Enums\/CustomerJourneyType.php<\/strong><\/p>\n<div>\n<pre><strong>&lt;?php<\/strong>\r\n\r\n<strong>namespace App\\Enums;<\/strong>\r\n\r\n<strong>enum CustomerJourneyType: int<\/strong>\r\n<strong>{<\/strong>\r\n<strong>    case From_Email = 1;    \/\/ \u30e1\u30fc\u30eb\u7d4c\u7531<\/strong>\r\n<strong>    case From_Blog = 2;     \/\/ \u30d6\u30ed\u30b0\u7d4c\u7531<\/strong>\r\n<strong>    case From_Ads = 3;      \/\/ \u5e83\u544a\u7d4c\u7531<\/strong>\r\n<strong>}<\/strong><\/pre>\n<\/div>\n<h1>\u3069\u3053\u7d4c\u7531\u306e\u30b5\u30a4\u30c8\u6d41\u5165\u304b\u3092 Cookie \u306b\u30bb\u30c3\u30c8\u3059\u308b\u30df\u30c9\u30eb\u30a6\u30a7\u30a2\u3092\u3064\u304f\u308b<\/h1>\n<p>\u8a2a\u554f\u30e6\u30fc\u30b6\u304c\u30b5\u30a4\u30c8\u306b\u6765\u3066\u3059\u3050\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3057\u3066\u304f\u308c\u305f\u3089\u554f\u984c\u306f\u306a\u3044\u3067\u3059\u304c\u3001\u5b9f\u969b\u306f\u5225\u306e\u30da\u30fc\u30b8\u3092\u898b\u305f\u308a\u3059\u308b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u306a\u306e\u3067\u3001\u3069\u3093\u306a\u5834\u5408\u3067\u3082\u300c<strong>\u3069\u3053\u7d4c\u7531\u306e\u30b5\u30a4\u30c8\u6d41\u5165\u304b\uff1f<\/strong>\u300d\u304c\u5206\u304b\u308b\u3088\u3046\u306b<code>Cookie<\/code>\u306b\u5024\u3092\u4fdd\u5b58\u3057\u3066\u304a\u304f\u3053\u3068\u306b\u3057\u307e\u3059\u3002<\/p>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:middleware CustomerJourneyMiddleware<\/strong><\/pre>\n<p>\u3059\u308b\u3068\u3001\u30df\u30c9\u30eb\u30a6\u30a7\u30a2\u30fb\u30d5\u30a1\u30a4\u30eb\u304c\u4f5c\u6210\u3055\u308c\u308b\u306e\u3067\u4e2d\u8eab\u3092\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p><strong>app\/Http\/Middleware\/CustomerJourneyMiddleware.php<\/strong><\/p>\n<div>\n<pre><strong>&lt;?php<\/strong>\r\n\r\n<strong>namespace App\\Http\\Middleware;<\/strong>\r\n\r\n<strong>use App\\Enums\\CustomerJourneyType;<\/strong>\r\n<strong>use Closure;<\/strong>\r\n<strong>use Illuminate\\Http\\Request;<\/strong>\r\n<strong>use Symfony\\Component\\HttpFoundation\\Response;<\/strong>\r\n\r\n<strong>class CustomerJourneyMiddleware<\/strong>\r\n<strong>{<\/strong>\r\n<strong>    \/**<\/strong>\r\n<strong>     * Handle an incoming request.<\/strong>\r\n<strong>     *<\/strong>\r\n<strong>     * @param  \\Closure(\\Illuminate\\Http\\Request): (\\Symfony\\Component\\HttpFoundation\\Response)  $next<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function handle(Request $request, Closure $next): Response<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        if($request-&gt;filled('cj')) {<\/strong>\r\n\r\n<strong>            $customer_journey_type = CustomerJourneyType::from($request-&gt;cj);<\/strong>\r\n\r\n<strong>            if(! is_null($customer_journey_type)) { \/\/ \u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u304c\u5b58\u5728\u3059\u308b\u5834\u5408<\/strong>\r\n\r\n<strong>                $minutes = 60 * 24 * 365 * 10; \/\/ 10\u5e74\u9593<\/strong>\r\n<strong>                cookie()-&gt;queue('customer_journey', $customer_journey_type-&gt;value, $minutes);<\/strong>\r\n\r\n<strong>            }<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n\r\n<strong>        return $next($request);<\/strong>\r\n<strong>    }<\/strong>\r\n<strong>}<\/strong><\/pre>\n<\/div>\n<\/div>\n<p>\u30df\u30c9\u30eb\u30a6\u30a7\u30a2\u306f\u3064\u304f\u3063\u305f\u3060\u3051\u3067\u306f\u6709\u52b9\u306b\u306a\u3089\u306a\u3044\u306e\u3067\u3001<strong>Kernel.php<\/strong>\u306b\u30bb\u30c3\u30c8\u3057\u307e\u3059\u3002<\/p>\n<p><strong>app\/Http\/Kernel.php<\/strong><\/p>\n<div>\n<pre>\/\/ \u7701\u7565\r\n\r\nclass Kernel extends HttpKernel\r\n{\r\n    \/\/ \u7701\u7565\r\n\r\n    protected $middlewareGroups = [\r\n        'web' =&gt; [\r\n\r\n            \/\/ \u7701\u7565\r\n\r\n            <strong>\\App\\Http\\Middleware\\CustomerJourneyMiddleware::class,<\/strong>\r\n        ],\r\n\r\n\/\/ \u7701\u7565<\/pre>\n<\/div>\n<p>\u3053\u308c\u3067\u3001<strong>\u30b5\u30a4\u30c8\u5185\u306e\u3069\u3053\u306b\u6765\u3066\u3082\u3053\u306e\u30df\u30c9\u30eb\u30a6\u30a7\u30a2\u304c\u5b9f\u884c\u3055\u308c\u308b<\/strong>\u3053\u3068\u306b\u306a\u308a\u307e\u3059\u3002\uff08API\u306f\u9664\u304f\uff09\u3064\u307e\u308a\u3001\u308f\u3056\u308f\u3056\u30eb\u30fc\u30c8\u5185\u3067\u30df\u30c9\u30eb\u30a6\u30a7\u30a2\u3092\u30bb\u30c3\u30c8\u3059\u308b\u5fc5\u8981\u306f\u3042\u308a\u307e\u305b\u3093\u3002<\/p>\n<h1>\u30ab\u30e9\u30e0\u3092\u8ffd\u52a0\u3059\u308b\u30de\u30a4\u30b0\u30ec\u30fc\u30b7\u30e7\u30f3\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u300c<strong>\u524d\u63d0\u3068\u3057\u3066<\/strong>\u300d\u306b\u66f8\u3044\u305f\u3068\u304a\u308a\u524d\u56de\u4f5c\u6210\u3057\u305f\u30c6\u30fc\u30d6\u30eb\u306b\u65b0\u3057\u3044\u30ab\u30e9\u30e0\u300c<strong>customer_journey_type<\/strong>\u300d\u3092\u8ffd\u52a0\u3059\u308b\u30de\u30a4\u30b0\u30ec\u30fc\u30b7\u30e7\u30f3\u3092\u3064\u304f\u308a\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:migration add_customer_journey_type_to_newsletter_users<\/strong><\/pre>\n<p>\u3059\u308b\u3068\u3001\u30de\u30a4\u30b0\u30ec\u30fc\u30b7\u30e7\u30f3\u30fb\u30d5\u30a1\u30a4\u30eb\u304c\u4f5c\u6210\u3055\u308c\u308b\u306e\u3067\u4e2d\u8eab\u3092\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n<p><strong>database\/migrations\/****_**_**_******_add_customer_journey_type_to_newsletter_users.php<\/strong><\/p>\n<div>\n<pre><strong>&lt;?php<\/strong>\r\n\r\n<strong>use Illuminate\\Database\\Migrations\\Migration;<\/strong>\r\n<strong>use Illuminate\\Database\\Schema\\Blueprint;<\/strong>\r\n<strong>use Illuminate\\Support\\Facades\\Schema;<\/strong>\r\n\r\n<strong>return new class extends Migration<\/strong>\r\n<strong>{<\/strong>\r\n<strong>    \/**<\/strong>\r\n<strong>     * Run the migrations.<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function up(): void<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        Schema::table('newsletter_users', function (Blueprint $table) {<\/strong>\r\n<strong>            $table-&gt;unsignedInteger('customer_journey_type') \/\/ App\\Enums\\CustomerJourneyType<\/strong>\r\n<strong>                -&gt;nullable()<\/strong>\r\n<strong>                -&gt;after('email');<\/strong>\r\n<strong>        });<\/strong>\r\n<strong>    }<\/strong>\r\n\r\n<strong>    \/**<\/strong>\r\n<strong>     * Reverse the migrations.<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function down(): void<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        Schema::table('newsletter_users', function (Blueprint $table) {<\/strong>\r\n<strong>            $table-&gt;dropColumn('customer_journey_type');<\/strong>\r\n<strong>        });<\/strong>\r\n<strong>    }<\/strong>\r\n<strong>};<\/strong><\/pre>\n<\/div>\n<p>\u3067\u306f\u3001\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3092\u521d\u671f\u5316\u3057\u3066\u304a\u304d\u307e\u3059\u3002<br \/>\n\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan migrate:fresh --seed<\/strong><\/pre>\n<p>\u3059\u308b\u3068\u3001\u5b9f\u969b\u306e\u30c6\u30fc\u30d6\u30eb\u306f\u3053\u3046\u306a\u308a\u307e\u3057\u305f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12512\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_1.png\" alt=\"\" width=\"640\" height=\"438\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_1.png 640w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_1-300x205.png 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<h1>\u30e1\u30fc\u30eb\u90e8\u5206\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u3064\u304f\u308b\u524d\u306b\u305d\u306e\u4e2d\u3067\u4f7f\u3046\u3053\u3068\u306b\u306a\u308b<code>Mailable<\/code>\uff08\u30e1\u30fc\u30eb\u9001\u4fe1\u90e8\u5206\uff09\u3092\u3064\u304f\u3063\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:mail NewsletterUserRegistered<\/strong><\/pre>\n<p>\u3059\u308b\u3068\u30d5\u30a1\u30a4\u30eb\u304c\u4f5c\u6210\u3055\u308c\u308b\u306e\u3067\u3001\u4e2d\u8eab\u3092\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p><strong>app\/Mail\/NewsletterUserRegistered.php<\/strong><\/p>\n<\/div>\n<\/div>\n<\/div>\n<div>\n<pre><strong>&lt;?php<\/strong>\r\n\r\n<strong>namespace App\\Mail;<\/strong>\r\n\r\n<strong>use App\\Enums\\CustomerJourneyType;<\/strong>\r\n<strong>use App\\Models\\NewsletterUser;<\/strong>\r\n<strong>use Illuminate\\Bus\\Queueable;<\/strong>\r\n<strong>use Illuminate\\Contracts\\Queue\\ShouldQueue;<\/strong>\r\n<strong>use Illuminate\\Mail\\Mailable;<\/strong>\r\n<strong>use Illuminate\\Mail\\Mailables\\Content;<\/strong>\r\n<strong>use Illuminate\\Mail\\Mailables\\Envelope;<\/strong>\r\n<strong>use Illuminate\\Queue\\SerializesModels;<\/strong>\r\n\r\n<strong>class NewsletterUserRegistered extends Mailable<\/strong>\r\n<strong>{<\/strong>\r\n<strong>    use Queueable, SerializesModels;<\/strong>\r\n\r\n<strong>    \/**<\/strong>\r\n<strong>     * Create a new message instance.<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function __construct(private NewsletterUser $newsletter_user)<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>    }<\/strong>\r\n\r\n<strong>    \/**<\/strong>\r\n<strong>     * Get the message envelope.<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function envelope(): Envelope<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        return new Envelope(<\/strong>\r\n<strong>            subject: '\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3057\u305f\uff01',<\/strong>\r\n<strong>        );<\/strong>\r\n<strong>    }<\/strong>\r\n\r\n<strong>    \/**<\/strong>\r\n<strong>     * Get the message content definition.<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function content(): Content<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        $is_cj_email = $this-&gt;newsletter_user-&gt;customer_journey_type === CustomerJourneyType::From_Email-&gt;value;<\/strong>\r\n<strong>        $is_cj_blog = $this-&gt;newsletter_user-&gt;customer_journey_type === CustomerJourneyType::From_Blog-&gt;value;<\/strong>\r\n<strong>        $is_cj_ads = $this-&gt;newsletter_user-&gt;customer_journey_type === CustomerJourneyType::From_Ads-&gt;value;<\/strong>\r\n\r\n<strong>        return new Content(<\/strong>\r\n<strong>            view: 'emails.newsletter_user_registered',<\/strong>\r\n<strong>            with: [<\/strong>\r\n<strong>                'newsletter_user' =&gt; $this-&gt;newsletter_user,<\/strong>\r\n<strong>                'is_cj_email' =&gt; $is_cj_email,<\/strong>\r\n<strong>                'is_cj_blog' =&gt; $is_cj_blog,<\/strong>\r\n<strong>                'is_cj_ads' =&gt; $is_cj_ads,<\/strong>\r\n<strong>            ],<\/strong>\r\n<strong>        );<\/strong>\r\n<strong>    }<\/strong>\r\n\r\n<strong>    \/**<\/strong>\r\n<strong>     * Get the attachments for the message.<\/strong>\r\n<strong>     *<\/strong>\r\n<strong>     * @return array&lt;int, \\Illuminate\\Mail\\Mailables\\Attachment&gt;<\/strong>\r\n<strong>     *\/<\/strong>\r\n<strong>    public function attachments(): array<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        return [];<\/strong>\r\n<strong>    }<\/strong>\r\n<strong>}<\/strong><\/pre>\n<\/div>\n<p>\u3067\u306f\u30e1\u30fc\u30eb\u306e\u30d3\u30e5\u30fc\u3082\u3064\u304f\u308a\u307e\u3057\u3087\u3046\u3002<br \/>\n\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:view emails.newsletter_user_registered<\/strong><\/pre>\n<p>\u4f5c\u6210\u3055\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u3092\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n<p><strong>resources\/views\/emails\/newsletter_user_registered.blade.php<\/strong><\/p>\n<div>\n<pre><strong>{{ $newsletter_user-&gt;name }}\u3055\u3093\u3001\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3059\u3002&lt;br&gt;&lt;br&gt;<\/strong>\r\n\r\n<strong>\uff08\u672c\u6587\u306f\u7701\u7565\uff09&lt;br&gt;&lt;br&gt;<\/strong>\r\n\r\n<strong>\u306a\u304a\u3001\u767b\u9332\u3057\u3066\u3044\u305f\u3060\u3044\u305f\u7279\u5178\u3068\u3057\u3066\u3001\u4ee5\u4e0b\u306e\u5272\u5f15\u30af\u30fc\u30dd\u30f3\u3092\u304a\u9001\u308a\u3044\u305f\u3057\u307e\u3059\u3002&lt;br&gt;<\/strong>\r\n<strong>\u305c\u3072\u3001\u6b21\u56de\u306e\u3054\u6765\u5e97\u6642\u306b\u3054\u5229\u7528\u304f\u3060\u3055\u3044\u3002&lt;br&gt;&lt;br&gt;<\/strong>\r\n\r\n<strong>@if($is_cj_email === true)<\/strong>\r\n<strong>    15% OFF \u30af\u30fc\u30dd\u30f3\u3092\u3053\u3053\u306b\u8868\u793a&lt;br&gt;&lt;br&gt;<\/strong>\r\n<strong>@elseif($is_cj_blog === true)<\/strong>\r\n<strong>    10% OFF \u30af\u30fc\u30dd\u30f3\u3092\u3053\u3053\u306b\u8868\u793a&lt;br&gt;&lt;br&gt;<\/strong>\r\n<strong>@elseif($is_cj_ads === true)<\/strong>\r\n<strong>    5% OFF \u30af\u30fc\u30dd\u30f3\u3092\u3053\u3053\u306b\u8868\u793a&lt;br&gt;&lt;br&gt;<\/strong>\r\n<strong>@endif<\/strong>\r\n\r\n<strong>\u4eca\u5f8c\u3068\u3082\u300cSukohi EC\u30b7\u30e7\u30c3\u30d7\u300d\u3092\u3088\u308d\u3057\u304f\u304a\u9858\u3044\u3044\u305f\u3057\u307e\u3059\u3002<\/strong><\/pre>\n<\/div>\n<\/div>\n<p>\u3061\u306a\u307f\u306b\u3001\u3053\u306e\u4e2d\u3067\u306f<code>CPA<\/code>\uff08\uff11\u4eba\u306e\u304a\u5ba2\u3055\u3093\u7372\u5f97\u306e\u30b3\u30b9\u30c8\uff09\u304c\u5b89\u3044\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u306e\u5834\u5408\u306f\u3001\u3088\u308a\u5272\u5f15\u7387\u304c\u9ad8\u3044\u30af\u30fc\u30dd\u30f3\u3092\u914d\u5e03\u3059\u308b\u30a4\u30e1\u30fc\u30b8\u306b\u306a\u3063\u3066\u307e\u3059\u3002<\/p>\n<div>\n<div>\n<h1>\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u6b21\u306b\u30e1\u30eb\u30de\u30ac\u306b\u767b\u9332\u3059\u308b\u90e8\u5206\u3092\u4f5c\u3063\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u3002<br \/>\n\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:controller NewsletterController<\/strong><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<p>\u3059\u308b\u3068\u30d5\u30a1\u30a4\u30eb\u304c\u4f5c\u6210\u3055\u308c\u308b\u306e\u3067\u3001\u4e2d\u8eab\u3092\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n<p><strong>app\/Http\/Controllers\/NewsletterController.php<\/strong><\/p>\n<div>\n<pre><strong>&lt;?php<\/strong>\r\n\r\n<strong>namespace App\\Http\\Controllers;<\/strong>\r\n\r\n<strong>use App\\Enums\\CustomerJourneyType;<\/strong>\r\n<strong>use App\\Mail\\NewsletterUserRegistered;<\/strong>\r\n<strong>use App\\Models\\NewsletterUser;<\/strong>\r\n<strong>use Illuminate\\Http\\Request;<\/strong>\r\n<strong>use Illuminate\\Support\\Facades\\Mail;<\/strong>\r\n<strong>use Illuminate\\Support\\Str;<\/strong>\r\n\r\n<strong>class NewsletterController extends Controller<\/strong>\r\n<strong>{<\/strong>\r\n<strong>    public function create()<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        return view('newsletter.create');<\/strong>\r\n<strong>    }<\/strong>\r\n\r\n<strong>    public function store(Request $request)<\/strong>\r\n<strong>    {<\/strong>\r\n<strong>        $request-&gt;validate([<\/strong>\r\n<strong>            'name' =&gt; 'required|string|max:255',<\/strong>\r\n<strong>            'email' =&gt; 'required|email|max:255|unique:newsletter_users,email',<\/strong>\r\n<strong>        ]);<\/strong>\r\n\r\n<strong>        \/\/ \u30e1\u30eb\u30de\u30ac\u767b\u9332<\/strong>\r\n<strong>        $newsletter_user = new NewsletterUser();<\/strong>\r\n<strong>        $newsletter_user-&gt;uuid = Str::uuid();<\/strong>\r\n<strong>        $newsletter_user-&gt;name = $request-&gt;name;<\/strong>\r\n<strong>        $newsletter_user-&gt;email = $request-&gt;email;<\/strong>\r\n<strong>        $newsletter_user-&gt;customer_journey_type = (int) $request-&gt;cookie('customer_journey');<\/strong>\r\n<strong>        $newsletter_user-&gt;save();<\/strong>\r\n\r\n<strong>        \/\/ \u30e1\u30fc\u30eb\u9001\u4fe1<\/strong>\r\n<strong>        Mail::to($newsletter_user-&gt;email)-&gt;send(new NewsletterUserRegistered($newsletter_user));<\/strong>\r\n\r\n<strong>        return '\u767b\u9332\u304c\u5b8c\u4e86\u3057\u307e\u3057\u305f';<\/strong>\r\n<strong>    }<\/strong>\r\n<strong>}<\/strong><\/pre>\n<\/div>\n<h1>\u30d3\u30e5\u30fc\u3092\u3064\u304f\u308b<\/h1>\n<p>\u7d9a\u3044\u3066\u3001\u3055\u3063\u304d\u306e\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u4e2d\u3067\u4f7f\u3063\u305f\u300c\u30d3\u30e5\u30fc\u300d\u3092\u3064\u304f\u308a\u307e\u3059\u3002<br \/>\n\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<div>\n<pre><strong>php artisan make:view newsletter.create<\/strong><\/pre>\n<\/div>\n<p>\u3059\u308b\u3068\u3001\u30d5\u30a1\u30a4\u30eb\u304c\u4f5c\u6210\u3055\u308c\u308b\u306e\u3067\u4e2d\u8eab\u3092\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n<p><strong>resources\/views\/newsletter\/create.blade.php<\/strong><\/p>\n<div>\n<pre><strong>&lt;html&gt;<\/strong>\r\n<strong>&lt;body&gt;<\/strong>\r\n<strong>    &lt;h1&gt;\u30e1\u30eb\u30de\u30ac\u767b\u9332&lt;\/h1&gt;<\/strong>\r\n<strong>    &lt;form method=\"POST\" action=\"{{ route('newsletter.store') }}\"&gt;<\/strong>\r\n<strong>        @csrf<\/strong>\r\n<strong>        &lt;div&gt;<\/strong>\r\n<strong>            &lt;label for=\"name\"&gt;\u540d\u524d&lt;\/label&gt;<\/strong>\r\n<strong>            &lt;br&gt;<\/strong>\r\n<strong>            &lt;input type=\"text\" id=\"name\" name=\"name\" required&gt;<\/strong>\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>        &lt;div&gt;<\/strong>\r\n<strong>            &lt;label for=\"email\"&gt;\u30e1\u30fc\u30eb\u30a2\u30c9\u30ec\u30b9&lt;\/label&gt;<\/strong>\r\n<strong>            &lt;br&gt;<\/strong>\r\n<strong>            &lt;input type=\"email\" id=\"email\" name=\"email\" required&gt;<\/strong>\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>        &lt;div style=\"padding:15px 0;\"&gt;<\/strong>\r\n<strong>            \uff08\u672c\u6765\u306f\u30aa\u30d7\u30c8\u30a4\u30f3\u306e\u540c\u610f\u3092\u53d6\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u304c\u3001\u4eca\u56de\u306f\u7701\u7565\u3057\u307e\u3059\uff09<\/strong>\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>        &lt;div&gt;<\/strong>\r\n<strong>            &lt;button type=\"submit\"&gt;\u767b\u9332\u3059\u308b&lt;\/button&gt;<\/strong>\r\n<strong>        &lt;\/div&gt;<\/strong>\r\n<strong>    &lt;\/form&gt;<\/strong>\r\n<strong>&lt;\/body&gt;<\/strong>\r\n<strong>&lt;\/html&gt;<\/strong><\/pre>\n<\/div>\n<h1>\u30eb\u30fc\u30c8\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u6700\u5f8c\u306b\u30eb\u30fc\u30c8\u3067\u3059\u3002<br \/>\n\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u3057\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><strong>routes\/web.php<\/strong><\/p>\n<div>\n<pre>\/\/ \u7701\u7565\r\n\r\n<strong>use App\\Http\\Controllers\\NewsletterController;<\/strong>\r\n\r\n\/\/ \u7701\u7565\r\n\r\n<strong>Route::prefix('newsletter')-&gt;controller(NewsletterController::class)-&gt;group(function(){<\/strong>\r\n\r\n<strong>    Route::get('create', 'create')-&gt;name('newsletter.create');<\/strong>\r\n<strong>    Route::post('store', 'store')-&gt;name('newsletter.store');<\/strong>\r\n\r\n<strong>});<\/strong><\/pre>\n<p>\u3053\u308c\u3067\u4f5c\u696d\u306f\u5b8c\u4e86\u3067\u3059\u3002<br \/>\n\u304a\u75b2\u308c\u69d8\u3067\u3057\u305f\u3002\ud83d\ude04<\/p>\n<h1>\u30c6\u30b9\u30c8\u3057\u3066\u307f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u5b9f\u969b\u306b\u4ee5\u4e0b\u306e\u624b\u9806\u3067\u30e1\u30eb\u30de\u30ac\u306b\u767b\u9332\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<ol>\n<li>\u307e\u305a\u30c8\u30c3\u30d7\u30da\u30fc\u30b8\u306b\u300c\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u300d\u756a\u53f7\u3092\u3064\u3051\u3066\u30a2\u30af\u30bb\u30b9\u3059\u308b<\/li>\n<li>\u30e1\u30eb\u30de\u30ac\u767b\u9332\u30da\u30fc\u30b8\u3078\u79fb\u52d5<\/li>\n<li>\u30d5\u30a9\u30fc\u30e0\u304b\u3089\u5fc5\u8981\u4e8b\u9805\u3092\u5165\u529b\u3057\u3066\u9001\u4fe1<\/li>\n<li>\u767b\u9332\u5b8c\u4e86\u5f8c\u3001\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u756a\u53f7\u304c\u5165\u3063\u3066\u3044\u308b\u304b\u30c1\u30a7\u30c3\u30af<\/li>\n<li>\u30e1\u30fc\u30eb\u304c\u9001\u4fe1\u3055\u308c\u3066\u3044\u308b\u304b\u30c1\u30a7\u30c3\u30af<\/li>\n<\/ol>\n<p>\u3067\u306f\u3001\u307e\u305a\u306f\u30d6\u30e9\u30a6\u30b6\u3067\u30c8\u30c3\u30d7\u30da\u30fc\u30b8 + \u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u756a\u53f7\u3092\u3064\u3051\u305f<code>URL<\/code>\u300c<strong>https:\/\/******\/?cj=2<\/strong>\u300d\uff08\ud83d\udc48 \u3064\u307e\u308a\u3001\u30d6\u30ed\u30b0\u7d4c\u7531\uff09\u306b\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002<\/p>\n<p>\u3059\u308b\u3068\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12513\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_2.png\" alt=\"\" width=\"640\" height=\"356\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_2.png 640w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_2-300x167.png 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>\u306f\u3044\u2757<\/p>\n<p>\u6211\u3005<code>Laravel<\/code>\u958b\u767a\u8005\u306b\u306f\u304a\u306a\u3058\u307f\u306e\u30c8\u30c3\u30d7\u30da\u30fc\u30b8\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u3002<\/p>\n<p>\u3067\u306f\u3001\u3053\u306e\u72b6\u614b\u3067\u30d6\u30e9\u30a6\u30b6\u306b<code>Cookie<\/code>\u304c\u767b\u9332\u3055\u308c\u3066\u3044\u308b\u304b\u30c1\u30a7\u30c3\u30af\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12514\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_3.png\" alt=\"\" width=\"532\" height=\"150\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_3.png 532w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_3-300x85.png 300w\" sizes=\"auto, (max-width: 532px) 100vw, 532px\" \/><\/p>\n<p>\u3061\u3083\u3093\u3068\u300c<strong>customer_journey<\/strong>\u300d\u304c\u767b\u9332\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u203b \u306a\u304a\u3001\u6570\u5b57\u3058\u3083\u306a\u3044\u306e\u306f<code>Laravel<\/code>\u304c\u6697\u53f7\u5316\u3057\u3066\u304f\u308c\u3066\u3044\u308b\u304b\u3089\u3067\u3059\u3002\u53d6\u308a\u51fa\u3059\u3068\u304d\u306f\u6570\u5b57\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u3001\u6b21\u306b\u30e1\u30eb\u30de\u30ac\u767b\u9332\u30d5\u30a9\u30fc\u30e0\u306e\u300c<strong>https:\/\/******\/newsletter\/create<\/strong>\u300d\u3078\u79fb\u52d5\u3057\u3066\u5fc5\u8981\u4e8b\u9805\u3092\u5165\u529b\u3057\u3001\u9001\u4fe1\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12515\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_4.png\" alt=\"\" width=\"555\" height=\"273\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_4.png 555w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_4-300x148.png 300w\" sizes=\"auto, (max-width: 555px) 100vw, 555px\" \/><\/p>\n<p>\u3046\u307e\u304f\u3044\u304f\u3067\u3057\u3087\u3046\u304b\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12516\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_5.png\" alt=\"\" width=\"170\" height=\"45\" \/><\/p>\n<p>\u306f\u3044\u2757<br \/>\n\u3046\u307e\u304f\u767b\u9332\u5b8c\u4e86\u30e1\u30c3\u30bb\u30fc\u30b8\u304c\u8868\u793a\u3055\u308c\u307e\u3057\u305f\u3002<\/p>\n<p>\u3067\u306f\u3001<code>DB<\/code>\u30c6\u30fc\u30d6\u30eb\u306e\u65b9\u3082\u78ba\u8a8d\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12517\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_6.png\" alt=\"\" width=\"640\" height=\"449\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_6.png 640w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_6-300x210.png 300w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>\u306f\u3044\u2757<\/p>\n<p>\u3061\u3087\u3063\u3068\u308f\u304b\u308a\u306b\u304f\u3044\u304b\u3082\u3067\u3059\u304c\u3001\u65b0\u3057\u3044\u30c7\u30fc\u30bf\u304c\u767b\u9332\u3055\u308c\u300c<strong>\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc<\/strong>\u300d\u756a\u53f7\u3082\u4fdd\u5b58\u3055\u308c\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u3001\u6700\u5f8c\u306b\u30e1\u30fc\u30eb\u304c\u3069\u3046\u306a\u3063\u3066\u3044\u308b\u304b\u78ba\u8a8d\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-12519\" style=\"border: 3px solid #000;\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_7.png\" alt=\"\" width=\"610\" height=\"377\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_7.png 610w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2024\/03\/laravel_customer_journey_7-300x185.png 300w\" sizes=\"auto, (max-width: 610px) 100vw, 610px\" \/><\/p>\n<p>\u3053\u3061\u3089\u3082\u3001\u30e1\u30fc\u30eb\u304c\u9001\u4fe1\u3055\u308c\u3066\u5272\u5f15\u30af\u30fc\u30dd\u30f3\u306f\u300c<strong>\u30d6\u30ed\u30b0\u7d4c\u7531<\/strong>\u300d\u306e\u3082\u306e\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n<p>\u3059\u3079\u3066\u6210\u529f\u3067\u3059\ud83d\ude04\u2728<\/p>\n<h1>\u4f01\u696d\u69d8\u3078\u306e\u3054\u63d0\u6848<\/h1>\n<p>\u4eca\u56de\u306f\u300c\u30aa\u30f3\u30e9\u30a4\u30f3\u30b7\u30e7\u30c3\u30d7\u300d\u3092\u60f3\u5b9a\u3057\u3066\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u3092\u6d3b\u7528\u3057\u3066\u307f\u307e\u3057\u305f\u304c\u3001\u30aa\u30f3\u30e9\u30a4\u30f3\u30b7\u30e7\u30c3\u30d7\u3067\u306a\u304f\u3066\u3082\u300c<strong>\u3069\u3053\u304b\u3089\u30b5\u30a4\u30c8\u6d41\u5165\u3057\u305f\u306e\u304b\uff1f<\/strong>\u300d\u3092\u6d3b\u7528\u3057\u3066\u4ee5\u4e0b\u306e\u3088\u3046\u306a\u5bfe\u7b56\u3092\u3059\u308b\u3068\u3001\u3088\u308a<code>CVR<\/code>\u5411\u4e0a\u3084\u30b3\u30b9\u30c8\u306e\u524a\u6e1b\u306b\u3064\u306a\u3052\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<ul>\n<li>\u554f\u3044\u5408\u308f\u305b\u304c\u3042\u3063\u305f\uff1a \u6d41\u5165\u5143\u306e CPA \u3092\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u3054\u3068\u306b\u5272\u308a\u51fa\u3057\u3001\u3042\u307e\u308a\u52b9\u679c\u7684\u306b\u96c6\u5ba2\u3067\u304d\u3066\u3044\u306a\u3044\u5834\u5408\u306f\u6539\u5584\u3059\u308b\u3001\u3082\u3057\u304f\u306f\u5ec3\u6b62\u3092\u691c\u8a0e\u3059\u308b<\/li>\n<li>\u7121\u6599\u30d5\u30a1\u30a4\u30eb\u304c\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3055\u308c\u305f\uff1a \u6d41\u5165\u5143\u306b\u3088\u3063\u3066\u3069\u306e\u7a0b\u5ea6\u306e\u7bc4\u56f2\u306e\u30b5\u30fc\u30d3\u30b9\u3092\u6c42\u3081\u3066\u3044\u308b\u304b\u304c\u5206\u304b\u308b<\/li>\n<li>\u8cc7\u6599\u8acb\u6c42\u304c\u3042\u3063\u305f\uff1a \u9867\u5ba2\u306e\u597d\u307f\u306b\u3088\u3063\u3066\u63d0\u6848\u3059\u308b\u8cc7\u6599\u3092\u5909\u66f4\u3059\u308b<\/li>\n<\/ul>\n<p>\u306a\u3069\u306a\u3069\u3002<\/p>\n<p>\u3082\u3057\u3053\u3046\u3044\u3063\u305f\u65bd\u7b56\u3092\u5b9f\u88c5\u3057\u305f\u3044\u5834\u5408\u306f\u304a\u554f\u3044\u5408\u308f\u305b\u304b\u3089\u3054\u76f8\u8ac7\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\u304a\u5f85\u3061\u3057\u3066\u304a\u308a\u307e\u3059\u3002\ud83d\ude04\u2728<\/p>\n<h1>\u304a\u308f\u308a\u306b<\/h1>\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001\u4eca\u56de\u306f\u300c<strong>\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc<\/strong>\u300d\u3092\u610f\u8b58\u3057\u305f\u30e1\u30eb\u30de\u30ac\u6a5f\u80fd\u3092\u5b9f\u88c5\u3057\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<\/div>\n<p>\u3053\u308c\u307e\u3067\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u306e\u52c9\u5f37\u3092\u3057\u3066\u3044\u306a\u3044\u3068\u304d\u306f\u3001\u3053\u3093\u306a\u3084\u308a\u65b9\u306f\u60f3\u50cf\u3082\u3057\u3066\u3044\u307e\u305b\u3093\u3067\u3057\u305f\u304c\u3001\u4f01\u696d\u306f\u300c<strong>\u3088\u308a\u58f2\u4e0a\u3092\u4e0a\u3052\u308b\u305f\u3081\u306b\u3053\u3053\u307e\u3067\u306e\u3053\u3068\u3092\u3057\u3066\u308b\u3093\u3060\u306a<\/strong>\u300d\u3068\u95a2\u5fc3\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u982d\u306e\u3044\u3044\u4eba\u3063\u3066\u3059\u3054\u3044\u3067\u3059\u306d\u3002<\/p>\n<p>\u79c1\u3082\u305d\u3046\u3044\u3046\u4eba\u305f\u3061\u306e\u30c6\u30af\u30cb\u30c3\u30af\u3092\u30d1\u30af\u3063\u3066\u3088\u308a\u4fa1\u5024\u306e\u3042\u308b\u3082\u306e\u3092\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u63d0\u4f9b\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u307f\u306a\u3055\u3093\u3082\u305c\u3072\u3044\u308d\u3044\u308d\u3068\u8003\u3048\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u306d\u3002<\/p>\n<p>\u3067\u306f\u3067\u306f\u301c\u2757<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-3405 aligncenter\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18.png\" alt=\"\" width=\"310\" height=\"320\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18.png 310w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2019\/04\/no_18-291x300.png 291w\" sizes=\"auto, (max-width: 310px) 100vw, 310px\" \/>\u300c\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u3092\u5b50\u4f9b\u306e\u9803\u306b<br \/>\n\u6559\u308f\u3063\u3066\u305f\u3089\u306a\u301c<br \/>\n\u3044\u3084\u3001\u62f3\u6cd5\u3068\u304b\u3057\u304b\u8208\u5473\u306a\u3044\u304b\u3089\u7121\u7406\u304b\uff08\u7b11\uff09\u300d<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u307e\u3060\u307e\u3060\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u306e\u52c9\u5f37\u3092Laravel\u306b\u6d3b\u304b\u3057\u305f\u3044\u4eca\u65e5\u3053\u306e\u9803\u3067\u3059\u3002 \u524d\u56de\u306e\u8a18\u4e8b\u306e\u7d9a\u304d\u306a\u306e\u3067\u3059\u304c\u3001\u307e\u305f\u65b0\u305f\u306a\u30de\u30fc\u30b1\u30c6\u30a3\u30f3\u30b0\u7528\u8a9e\u306b\u51fa\u4f1a\u3044\u307e\u3057\u305f\u3002 \u305d &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/blog.capilano-fw.com\/?p=12511\" class=\"more-link\"><span class=\"screen-reader-text\">&#8220;Laravel \u3067\u300c\u30ab\u30b9\u30bf\u30de\u30fc\u30b8\u30e3\u30fc\u30cb\u30fc\u300d\u3092\u610f\u8b58\u3057\u305f\u30e1\u30eb\u30de\u30ac\u767b\u9332\u3092\u3064\u304f\u308b&#8221; \u306e<\/span>\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":12523,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,258],"tags":[],"class_list":["post-12511","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-laravel","category-258"],"_links":{"self":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/12511","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=12511"}],"version-history":[{"count":7,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/12511\/revisions"}],"predecessor-version":[{"id":12606,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/12511\/revisions\/12606"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/media\/12523"}],"wp:attachment":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=12511"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=12511"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=12511"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}