商品模块会员价格显示
商品模块会员价格显示
public function add(){ $goods=D('goods'); if(IS_POST){ if($goods->create()){ if ($goods->add()) { $this->success('添加商品成功',U('index')); }else{ $this->error('添加商品失败'); } }else{ $this->error($goods->getError()); } return; } $cateres=D('cate')->catetree(); $this->assign('cateres',$cateres); $brandres=D('brand')->select(); $this->assign('brandres',$brandres); $levres=D('member_level')->select(); $this->assign('levres',$levres); $this->display(); }
$levres=D('member_level')->select();
$this->assign('levres',$levres);
分配添加的会员数据
<!DOCTYPE html> <html><head> <meta charset="utf-8"> <title>PHP中文网</title> <meta name="description" content="Dashboard"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <!--Basic Styles--> <link href="__PUBLIC__/style/bootstrap.css" rel="stylesheet"> <link href="__PUBLIC__/style/font-awesome.css" rel="stylesheet"> <link href="__PUBLIC__/style/weather-icons.css" rel="stylesheet"> <!--Beyond styles--> <link id="beyond-link" href="__PUBLIC__/style/beyond.css" rel="stylesheet" type="text/css"> <link href="__PUBLIC__/style/demo.css" rel="stylesheet"> <link href="__PUBLIC__/style/typicons.css" rel="stylesheet"> <link href="__PUBLIC__/style/animate.css" rel="stylesheet"> <!-- 引入ueditor --> <script src="__PUBLIC__/ueditor/ueditor.config.js"></script> <script src="__PUBLIC__/ueditor/ueditor.all.min.js"></script> <script src="__PUBLIC__/ueditor/lang/zh-cn/zh-cn.js"></script> </head> <body> <!-- 头部 --> <include file="Common/header" /> <!-- /头部 --> <div class="main-container container-fluid"> <div class="page-container"> <!-- Page Sidebar --> <include file="Common/left" /> <!-- /Page Sidebar --> <!-- Page Content --> <div class="page-content"> <!-- Page Breadcrumb --> <div class="page-breadcrumbs"> <ul class="breadcrumb"> <li> &am