作者 潘浩文
1 个管道 的构建 通过 耗费 0 秒

测试反馈修改

... ... @@ -128,12 +128,24 @@ class BrandController extends WeChatBaseController
return $this->fetch('brand_detail');
}
public function comment(){
$id=$this->request->param('id');
$re=Db::name('users')->where(['open_id'=>session('wechat_user')['id']])->find();
if (!$re['mobile']){
return 2;
}
else {
return url('portal/brand/comment2',array('id'=>$id));
}
}
//品牌评论页面
public function comment()
public function comment2()
{
$id = $this->request->param('id');
$this->assign('id', $id);
return $this->fetch();
return $this->fetch('comment');
}
public function commentPost()
... ...
... ... @@ -356,13 +356,13 @@
id:"{$list.id}",
},
success: function (data) {
if (data==1) {
window.location.href="{:url('portal/brand/comment2'}"
if (data!=2) {
window.location.href=data
}
else {
else{
var a=confirm("是否注册")
if(a==true){
window.location.href=data
window.location.href="{:url('user/register/register')}"
}
}
}
... ...