本文整理汇总了PHP中app\Company::insert方法的典型用法代码示例。如果您正苦于以下问题:PHP Company::insert方法的具体用法?PHP Company::insert怎么用?PHP Company::insert使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类app\Company
的用法示例。
在下文中一共展示了Company::insert方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: run
public function run()
{
DB::table('companies')->delete();
Eloquent::unguard();
Company::insert([['id' => 1, 'lat' => "39.114025", 'long' => "-84.513890", 'name' => "RoadTrippers", 'description' => "Roadtrippers HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.roadtrippers.com", 'category_id' => 1], ['id' => 2, 'lat' => "39.110624", 'long' => "-84.515660", 'name' => "Cintrifuse", 'description' => "Cintrifuse HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.cintrifuse.com", 'category_id' => 5], ['id' => 3, 'lat' => "39.110624", 'long' => "-84.515660", 'name' => "Brandery", 'description' => "The Brandery", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.brandery.com", 'category_id' => 2], ['id' => 4, 'lat' => "39.1100127", 'long' => "-84.5206703", 'name' => "Choremonster", 'description' => "Choremonster HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.choremonster.com", 'category_id' => 1], ['id' => 5, 'lat' => "39.1108908", 'long' => "-84.5157333", 'name' => "SQRL", 'description' => "SQRL HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.getsqrl.com", 'category_id' => 1], ['id' => 6, 'lat' => "39.109615", 'long' => "-84.516514", 'name' => "Frameri", 'description' => "Frameri retail location", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.frameri.com", 'category_id' => 1], ['id' => 7, 'lat' => "39.1286862", 'long' => "-84.4307708", 'name' => "Ahalogy", 'description' => "Ahalogy HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.ahalogy.com", 'category_id' => 1], ['id' => 8, 'lat' => "39.1150377", 'long' => "-84.5199733", 'name' => "Modulus", 'description' => "Modulus HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.modulus.com", 'category_id' => 1], ['id' => 9, 'lat' => "39.0955948", 'long' => "-84.523511", 'name' => "Dotloop", 'description' => "Dotloop HQ", 'status' => 1, 'created_at' => "0000-00-00 00:00:00", 'updated_at' => "0000-00-00 00:00:00", 'url' => "http://www.dotloop.com", 'category_id' => 1], ['id' => 15, 'lat' => "39.104971", 'long' => "-84.511328", 'name' => "Differential", 'description' => "Meteor.js development", 'status' => 1, 'created_at' => "2015-09-17 08:15:01", 'updated_at' => "2015-09-17 08:15:01", 'url' => "http://www.differential.com", 'category_id' => 1]]);
}