/**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     $sms = SmsGateway::all();
     foreach ($sms as $s) {
         $s->delete();
     }
     //
     $gateways = [['name' => 'Sprint', 'address' => '@messaging.sprintpcs.com'], ['name' => 'AT&T', 'address' => '@txt.att.net'], ['name' => 'T-Mobile', 'address' => '@tmomail.net'], ['name' => 'Verizon', 'address' => '@vtext.com'], ['name' => 'MetroPCS', 'address' => '@messaging.sprintpcs.com'], ['name' => 'Cricket', 'address' => '@sms.mycricket.com'], ['name' => '3 River Wireless', 'address' => '@sms.3rivers.net'], ['name' => 'ACS Wireless', 'address' => '@paging.acswireless.com'], ['name' => 'Alltel', 'address' => '@message.alltel.com']];
     foreach ($gateways as $gateway) {
         SmsGateway::Create(['name' => $gateway['name'], 'address' => $gateway['address']]);
     }
 }
Exemple #2
0
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/
Route::post('request-more-info', 'AlertController@requestInfo');
Route::post('request-more-info-home', 'AlertController@requestInfoHome');
Route::post('register-device', function (\Illuminate\Http\Request $request) {
    \Log::info('request', $request->all());
    App\DeviceToken::Create(['token' => $request->token]);
});
Route::get('seed-front-page', 'FrontPageController@index');
Route::post('new-front-page-lit', 'FrontPageController@store');
Route::get('/', function () {
    //return view('spark::welcome');
    $frontPage = \App\FrontPageLit::find(1);
    $gateways = \App\SmsGateway::all()->sortBy('name');
    return view('index2')->with(['frontPage' => $frontPage, 'gateways' => $gateways]);
});
Route::resource('alert', 'AlertController');
Route::post('contact-requested', 'ContactRequestController@store');
Route::get('enrollment-forms', function () {
    $path = public_path('download-forms') . '/enrollment-forms.zip';
    return response()->download($path);
});
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| This route group applies the "web" middleware group to every route
| it contains. The "web" middleware group is defined in your HTTP