第二处,EsiElecDynamic.java
private User user; public User getUser() { return user; } public void setUser(User user) { this.user = user; }1
2
3
4
5
6
7
8
第三处,EsiElecDynamicDao.xml
<sql id="esiElecDynamicColumns"> a.id AS "id", a.title AS "title", a.content AS "content", a.files AS "files", a.create_by AS "createBy.id", a.create_date AS "createDate", a.update_by AS "updateBy.id", a.update_date AS "updateDate", a.remarks AS "remarks", a.del_flag AS "delFlag", u.name AS "user.name" </sql> <sql id="esiElecDynamicJoins"> JOIN sys_user u ON u.id = a.create_by </sql>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
第八步、设置列宽esiElecDynamicList.jsp
<th>标题</th> <th width="30%">发布内容</th> <th>发布者</th> <th width="20%">发布时间</th> <shiro:hasPermission name="esi:esiElecDynamic:edit"> <th>操作</th> </shiro:hasPermission>1
2
3
4
5
6
7
第九步、增加状态的选择查询当点击发布、审核单选按钮的时候,我们希望页面能自动查询,怎么做呢?
esiElecDynamicList.jsp
<li><label>状态:</label> <form:radiobuttons onclick="$(\'#searchForm\').submit();" path="delFlag" items="${fns:getDictList(\'esi_audit_status\')}" itemLabel="label" itemValue="value" htmlEscape="false" /></li>1
2
path=”delFlag”会关联到数据库中的del_flag字段。
onclick时提交表单。
好了好了,做到这里的时候其实你发现,增删改查太简单了,但如果没有了解jeesite的话,做起来就费劲了,我就费了老大劲。