@RequestMapping("/page1")
    public ModelAndView editSharing(Integer id) {
        ModelAndView mav=new ModelAndView();
        List<Sharing> list = sharingService.list1(id);
        mav.addObject("list",list);
        mav.setViewName("knowledge/sharing/editsharing");
        return mav;
    }

在controller里面存入list,从前台取,

<div class="layui-form-item">
                <label class="layui-form-label">标题</label>
                <div class="layui-input-block">
                    <input id="password" type="text" name="name" value="${list.get(0).name }" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
                </div>
            </div>

 

相关文章:

  • 2021-04-17
  • 2022-12-23
  • 2022-12-23
  • 2021-07-01
  • 2021-08-10
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-12-25
  • 2022-12-23
  • 2021-08-29
  • 2022-12-23
  • 2021-07-11
  • 2022-12-23
  • 2021-11-14
相关资源
相似解决方案