会议反馈和会议通知

本文介绍了会议管理系统中会议通知和会议反馈的实现。通过SQL查询获取会议通知,并展示了相关Java代码处理会议反馈,包括DAO方法和Action类。同时,提到了layui框架在前端界面展示中的应用,如表格渲染和查询功能。
摘要由CSDN通过智能技术生成

一、会议通知

 会议通知sql语句

select t1.* ,IFNULL(f.result,-1)result from 
(select * from t_oa_meeting_info where FIND_IN_SET(2,CONCAT(canyuze,',',liexize,',',zhuchiren))and state=4 ) t1 
left JOIN t_oa_meeting_feedback f on t1.id=f.meetingId  and f.personId=2 order by result ;

 

 

 .config.

layui.config({
  base: 'static/js/layui/modules/' //假设这是test.js所在的目录
}).extend({ //设定模块别名
  test: 'test' //如果test.js是在根目录,也可以不用设定别名
});

 header.jsp

<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
   
<!-- 引入 layui.css -->
<link rel="stylesheet" href="${pageContext.request.contextPath }/static/js/layui/css/layui.css">
<!-- 引入 layui.js -->
 <script src="${pageContext.request.contextPath }/static/js/layui/layui.js"></script>
<base href="${pageContext.request.contextPath }/">
    
<!-- 引入formSelects核心css -->
<link rel="stylesheet" href="${pageContext.request.contextPath }/static/js/plugins/formSelects/formSelects-v4.css" />
<!-- 引入formSelects核心js -->
<script src="${pageContext.request.contextPath }/static/js/plugins/formSelects/formSelects-v4.js" type="text/javascript" charset="utf-8"></script>
<!-- 引入config.js -->
<script src="${pageContext.request.contextPath }/static/js/layui/config.js" type="text/javascript" charset="utf-8"></script>

<input id="ctx" value="${pageContext.request.contextPath }" type="hidden" >
 

 配置文件mvc.xml

<?xml version="1.0" encoding="UTF-8"?>
<config>
    

<action path="/permission" type="com.zking.web.PermissonAction">
</action>
<action path="/user" type="com.zking.web.UserAction">
</action>
<action path="/info" type="com.zking.util.MeetingInfoAction">
</action>
<action path="/audit" type="com.zking.util.MeetingAuditAction">
</action>
<action path="/feedBack" type="com.zking.web.MeetingFeedbackAction">
</action>

</config>

 MeetingFeedbackAction类

package com.zking.web;

import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.zking.dao.MeetingFeedbackDao;
import com.zking.entity.MeetingFeedBack;
import com.zking.framework.ActionSupport;
import com.zking.framework.ModelDriver;
import com.zking.util.PageBean;
import com.zking.util.R;
import com.zking.util.ResponseUtil;

public class MeetingFeedbackAction extends ActionSupport implements ModelDriver<MeetingFeedBack>{
        private MeetingFeedBack back =new MeetingFeedBack();
        private MeetingFeedbackDao feedbackDao =new MeetingFeedbackDao();
            
        //我的会议通知
         
        public String queryMeetingFeedBackByUserId(HttpServletRequest req, HttpServletResponse resp) {
            
            try {
                PageBean pagebean=new PageBean();
                pagebean.setRequest(req);//设置界面跳转方式
                List<Map<String, Object>> ls=feedbackDao.queryMeetingFeedBackByUserId(back, pagebean);
                ResponseUtil.writeJson(resp, R.ok(0, "会议通知数据查询成功", pagebean.getTotal(),ls));
                
                
            } catch (Exception e) {
                e.printStackTrace();
                try {
                    ResponseUtil.writeJson(resp, R.error(0, "会议通知数据查询失败"));
                } catch (Exception e2) {
                    e2.printStackTrace();
                }
            }
            return null;
        }
        
        
                
    @Override
    public MeetingFeedBack getModel() {
        return back;
    }
    
    
    
}
 

dao方法

package com.zking.dao;

import java.sql.SQLException;
import java.util.List;
import java.util.Map;

import com.zking.entity.MeetingFeedBack;
import com.zking.entity.MeetingInfo;
import com.zking.util.BaseDao;
import com.zking.util.PageBean;
import com.zking.util.StringUtils;

public class MeetingFeedbackDao  extends BaseDao<MeetingFeedBack>{
        
    
    
    //我的会议通知
    
    public List<Map<String, Object>> queryMeetingFeedBackByUserId(MeetingFeedBack back, PageBean pageBean)
            throws SQLException, InstantiationException, IllegalAccessException {
//        String sql="select t1.* ,IFNULL(f.result,-1)result from \r\n" + 
//                "(select * from t_oa_meeting_info where FIND_IN_SET("+back.getPersonId()+",CONCAT(canyuze,',',liexize,',',zhuchiren))) t1 \r\n" + 
//                "left JOIN t_oa_meeting_feedback f on t1.id=f.meetingId  and f.personId="+back.getPersonId()+" order by t1.id desc ";//调用sql语句    

        
                String sql="select t1.*,ifnull(f.result,-1) result from \r\n" + 
                "(select * from t_oa_meeting_info where "
                + "find_in_set('"+back.getPersonId()+"',concat(canyuze,',',liexize,',',zhuchiren))) t1 \r\n" + 
                "left join t_oa_meeting_feedback f on "
                + "t1.id=f.meetin

评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值