Skip to content

Instantly share code, notes, and snippets.

View nutch31's full-sized avatar

Nut Chantathab nutch31

View GitHub Profile
---
ip: "192.168.13.13"
memory: 2048
cpus: 1
name: laravel-apps-homestead-vmbox
provider: virtualbox
authorize: ~/.ssh/id_rsa.pub
keys:
<?php
namespace App\Console\Commands;
use Illuminate\Console\Command;
use Illuminate\Http\Request;
use Carbon\Carbon;
use DateTime;
use App\Model\Call;
<?php
// Query
$query = Lead::where([
['campaign_id', $request->get('campaignId')]
])
->whereBetween('submitted_date_time', [$startDateTime, $endDateTime])
->where(function($q) use ($analyticCampaignId_array, $trackingPhone_array, $directChannelId_array, $status)
{
if(!empty($analyticCampaignId_array))
// Query
$query = Lead::where([
['campaign_id', $request->get('campaignId')]
])
->whereBetween('submitted_date_time', [$startDateTime, $endDateTime])
->where(function($q) use ($analyticCampaignId_array, $trackingPhone_array, $directChannelId_array, $status)
{
if(!empty($analyticCampaignId_array))
{
$q->orWhereIn('analytic_campaign_id', $analyticCampaignId_array)
// Query
$query = Lead::where([
['campaign_id', $request->get('campaignId')]
])
->whereBetween('submitted_date_time', [$startDateTime, $endDateTime])
->where(function($q) use ($analyticCampaignId_array, $trackingPhone_array, $directChannelId_array, $status)
{
if(!empty($analyticCampaignId_array))
{
$q->orWhereIn('analytic_campaign_id', $analyticCampaignId_array)
APP_NAME=Laravel
APP_ENV=local
APP_KEY=base64:1WuQVFheOQ7smGaqur1IXIw7StnbRkoUdDn3o+HZMfQ=
APP_DEBUG=true
APP_URL=http://localhost
LOG_CHANNEL=stack
DB_CONNECTION=mysql
DB_HOST=localhost
---
ip: "192.168.13.13"
memory: 2048
cpus: 1
provider: virtualbox
authorize: ~/.ssh/id_rsa.pub
keys:
- ~/.ssh/id_rsa
module.exports = {
devServer: {
port: 4000,
proxy: {
/* Alpha Backend APIs */
"/api": {
target: "http://api.heroleads.com:8000/",
ws: true,
changeOrigin: true,
},
<?php
namespace App\Http\Middleware;
use Closure;
class CorsMiddleware
{
/**
* Handle an incoming request.
*
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Events\UserRegistered;
class AlphaController extends Controller
{