iwebshop后台模块的添加需要以下几个步骤
例如添加:”订单2“模块
1.在/classes/menu.php中找到
//菜单的配制数据
(添加方式如下)
'订单2'=>array(
'订单管理'=>array(
'/test/test_order_list' =>'订单列表',
),
),
2.在/classes/themeroute.php中找到
//后台管理的控制器
private static $syscontroller = array(
'pic','block','brand','comment','goods','market','member','message','order','system','systemadmin','tools','test'(红色为添加的控制器)
);
3.
在/controllers/下新建test.php
内容格式参考其他的.php
<?php
class Test extends IController
{
public $checkRight = 'all';
public $layout='admin';
function init()
{
IInterceptor::reg('CheckRights@onCreateAction');
}
public function test_order_list(){
$this->redirect('test_order_list',false);
}
}
?>
在/views/sysdefault/下新建 “文件夹test”,在test下新建test_order_list.html(对应的html模板)
创建完成