本文整理匯總了PHP中Dict::create方法的典型用法代碼示例。如果您正苦於以下問題:PHP Dict::create方法的具體用法?PHP Dict::create怎麽用?PHP Dict::create使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Dict
的用法示例。
在下文中一共展示了Dict::create方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: run
public function run()
{
DB::table('dicts')->delete();
Dict::create(array('code' => 'USER_LEVEL', 'name' => '會員等級', 'para_code' => '001', 'para_name' => '食客'));
Dict::create(array('code' => 'USER_LEVEL', 'name' => '會員等級', 'para_code' => '002', 'para_name' => '高級食客'));
Dict::create(array('code' => 'USER_LEVEL', 'name' => '會員等級', 'para_code' => '003', 'para_name' => '美食家'));
Dict::create(array('code' => 'USER_STATUS', 'name' => '會員狀態', 'para_code' => '001', 'para_name' => '正常'));
Dict::create(array('code' => 'USER_STATUS', 'name' => '會員狀態', 'para_code' => '002', 'para_name' => '待審核'));
Dict::create(array('code' => 'USER_STATUS', 'name' => '會員狀態', 'para_code' => '003', 'para_name' => '已禁用'));
Dict::create(array('code' => 'ARTICLE_STATUS', 'name' => '文章狀態', 'para_code' => '001', 'para_name' => '待發布'));
Dict::create(array('code' => 'ARTICLE_STATUS', 'name' => '文章狀態', 'para_code' => '002', 'para_name' => '待審核'));
Dict::create(array('code' => 'ARTICLE_STATUS', 'name' => '文章狀態', 'para_code' => '003', 'para_name' => '已審核'));
Dict::create(array('code' => 'ARTICLE_STATUS', 'name' => '文章狀態', 'para_code' => '004', 'para_name' => '已拒絕'));
Dict::create(array('code' => 'COOKBOOK_STATUS', 'name' => '菜譜狀態', 'para_code' => '001', 'para_name' => '待發布'));
Dict::create(array('code' => 'COOKBOOK_STATUS', 'name' => '菜譜狀態', 'para_code' => '002', 'para_name' => '待審核'));
Dict::create(array('code' => 'COOKBOOK_STATUS', 'name' => '菜譜狀態', 'para_code' => '003', 'para_name' => '已審核'));
Dict::create(array('code' => 'COOKBOOK_STATUS', 'name' => '菜譜狀態', 'para_code' => '004', 'para_name' => '已拒絕'));
}