初始字段

$fields = [
    'op_name'      => 'vip',//角色标识
    'op_valte'     => 'VIP用户',//角色描述
    'op_module'    => 'demo',//应用名
    'op_controll'  => 'role',
    'op_action'    => 'system',
    'op_order'     => 0,
    'op_status'    => 'normal',
    'op_autoload'  => 'no',
];

卸载插件时删除角色名

model('common/Role','loglic')->uninstall('demo');

安装插件时批量插入角色名
model('common/Role','loglic')->install([

    [
        'op_name'     => 'subscriber',
        'op_value'    => '订阅者',
        'op_module'   => 'demo',
    ],
    [
        'op_name'     => 'contributor',
        'op_value'    => '投稿者',
        'op_module'   => 'demo',
    ]
]);