layer content
请求参数
//弹出修改会员分组
function toupdatecustomergroupbyid(groupid){
alert(groupid);
layer.open({
type: 2, //iframe窗
title:'修改会员分组',
skin: 'layui-layer-rim', //加上边框
area: ['500px', '240px'], //宽高
content: "${ctx}/customer/toupdatecustomergroup?id="+groupid
});
}
//弹出修改会员分组信息
@RequestMapping("/toupdatecustomergroup")
public String toupdatecustomergroup(HttpServletRequest request,
@RequestParam("id") int id){ //引号里必须写id,不是变量
return "customer/updatecustomergroup"; //返回页面
}
-----------------------------------------------------------------------------------------------------------------------------------------------
layer content
地址参数
//弹出修改会员分组
function toupdatecustomergroupbyid(groupid){
alert(groupid);
layer.open({
type: 2,
title:'修改会员分组',
skin: 'layui-layer-rim', //加上边框
area: ['500px', '240px'], //宽高
content: "${ctx}/customer/toupdatecustomergroup/"+groupid
});
}
//弹出修改会员分组信息
@RequestMapping("/toupdatecustomergroup/{id}")
public String toupdatecustomergroup(HttpServletRequest request,
@PathVariable("id") int id){
CustomerGroup customergrouplist = customerservice.selectgroupbygroupid(id);
request.setAttribute("groupbyid", customergrouplist);
return "customer/updatecustomergroup";
}
-----------------------------------------------------------------------------------------------------------------------------------------------------
从session取shopid值
//session取shopid
Object objshopid = request.getSession().getAttribute("shopid");
Integer shopid = (Integer) objshopid;