XMTT 6 vuotta sitten
vanhempi
commit
78856864ef

+ 7 - 6
src/main/java/com/ekexiu/project/bridge/alarm/AlarmDao.java

1
package com.ekexiu.project.bridge.alarm;
1
package com.ekexiu.project.bridge.alarm;
2

2

3
import java.sql.Connection;
4
import java.sql.SQLException;
5
import java.util.List;
6

7
import org.jfw.apt.orm.annotation.dao.Batch;
3
import org.jfw.apt.orm.annotation.dao.Batch;
8
import org.jfw.apt.orm.annotation.dao.DAO;
4
import org.jfw.apt.orm.annotation.dao.DAO;
9
import org.jfw.apt.orm.annotation.dao.method.From;
5
import org.jfw.apt.orm.annotation.dao.method.From;
14
import org.jfw.apt.orm.annotation.dao.method.operator.PageSelect;
10
import org.jfw.apt.orm.annotation.dao.method.operator.PageSelect;
15
import org.jfw.apt.orm.annotation.dao.method.operator.SelectList;
11
import org.jfw.apt.orm.annotation.dao.method.operator.SelectList;
16
import org.jfw.apt.orm.annotation.dao.method.operator.UpdateWith;
12
import org.jfw.apt.orm.annotation.dao.method.operator.UpdateWith;
13
import org.jfw.apt.orm.annotation.dao.param.In;
17
import org.jfw.util.PageQueryResult;
14
import org.jfw.util.PageQueryResult;
15

16
import java.sql.Connection;
17
import java.sql.SQLException;
18
import java.util.List;
18
@DAO
19
@DAO
19
public interface AlarmDao {
20
public interface AlarmDao {
20
	@Insert
21
	@Insert
27
	int[] insertAlarmDataItems(Connection con, List<AlarmDataItem> items)throws SQLException;
28
	int[] insertAlarmDataItems(Connection con, List<AlarmDataItem> items)throws SQLException;
28
	
29
	
29
	@PageSelect
30
	@PageSelect
30
	@OrderBy("ORDER BY ALARM_TIME DESC,AID DESC")
31
	PageQueryResult<AlarmMsg> queryAlarmMsg(Connection con,String uid,int pageSize,int pageNo)throws SQLException;
31
	@OrderBy("ORDER BY ALARM_TIME DESC,SERVER DESC,AID DESC")
32
	PageQueryResult<AlarmMsg> queryAlarmMsg(Connection con, @In String[] server,String uid, int pageSize, int pageNo)throws SQLException;
32
	
33
	
33
	
34
	
34
	@UpdateWith
35
	@UpdateWith

+ 2 - 2
src/main/java/com/ekexiu/project/bridge/alarm/AlarmService.java

36

36

37
	@Get
37
	@Get
38
	@Path("/msg")
38
	@Path("/msg")
39
	public PageQueryResult<AlarmMsg> query(@JdbcConn Connection con,final @LoginUser SessionUser user,int pageSize,int pageNo)throws SQLException{
40
		return this.alarmDao.queryAlarmMsg(con,user.getId(), pageSize, pageNo);
39
	public PageQueryResult<AlarmMsg> query(@JdbcConn Connection con,String[] seq,final @LoginUser SessionUser user,int pageSize,int pageNo)throws SQLException{
40
		return this.alarmDao.queryAlarmMsg(con,seq,user.getId(), pageSize, pageNo);
41
	}
41
	}
42
	
42
	
43
	@Get
43
	@Get