Merge branch 'develop' of http://10.0.6.99/gwall/gwall.git into develop
This commit is contained in:
154
src/main/java/com/nis/domain/specific/SpecificServiceCfg.java
Normal file
154
src/main/java/com/nis/domain/specific/SpecificServiceCfg.java
Normal file
@@ -0,0 +1,154 @@
|
||||
package com.nis.domain.specific;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.nis.domain.BaseEntity;
|
||||
import com.nis.util.Configurations;
|
||||
|
||||
/**
|
||||
* 系统特定服务信息表-记录特定服务信息(specific_service_cfg)
|
||||
* @author zsl
|
||||
*
|
||||
*/
|
||||
public class SpecificServiceCfg extends BaseEntity<SpecificServiceCfg>{
|
||||
|
||||
private static final long serialVersionUID = -1133644323636425766L;
|
||||
|
||||
private Integer specServiceId; //spec_service_id 协议ID int N 主键,初始化
|
||||
//private Integer specServiceCode; //协议编码 int N 暂定,以后可扩展 1000:微信 , 1001:QQ
|
||||
private String specServiceName; //spec_service_name 协议名称 varchar(64) N
|
||||
private String specServiceDesc; //spec_service_desc 协议描述 varchar2(64) N
|
||||
private Integer isValid; //is_valid 有效标志 int N 1-有效 0-无效
|
||||
private Date opTime; //op_time 操作时间 date N
|
||||
private SpecificServiceCfg parent; //parent_id 父节点id int N 0表示一级节点
|
||||
private Integer isLeaf; //is_leaf 是否是叶子节点 int N 0否,1是,只有一级填0
|
||||
private Integer groupId; //group_id maat端配置分组id int N 缺省0,表示未与maat分组同步
|
||||
|
||||
private Date beginDate; // 开始日期
|
||||
private Date endDate; // 结束日期
|
||||
private String showSequence; //显示序号
|
||||
|
||||
public Integer getSpecServiceId() {
|
||||
return specServiceId;
|
||||
}
|
||||
public void setSpecServiceId(Integer specServiceId) {
|
||||
this.specServiceId = specServiceId;
|
||||
}
|
||||
public String getSpecServiceName() {
|
||||
return specServiceName;
|
||||
}
|
||||
public void setSpecServiceName(String specServiceName) {
|
||||
this.specServiceName = specServiceName;
|
||||
}
|
||||
public String getSpecServiceDesc() {
|
||||
return specServiceDesc;
|
||||
}
|
||||
public void setSpecServiceDesc(String specServiceDesc) {
|
||||
this.specServiceDesc = specServiceDesc;
|
||||
}
|
||||
public Integer getIsValid() {
|
||||
return isValid;
|
||||
}
|
||||
public void setIsValid(Integer isValid) {
|
||||
this.isValid = isValid;
|
||||
}
|
||||
public Date getOpTime() {
|
||||
return opTime;
|
||||
}
|
||||
public void setOpTime(Date opTime) {
|
||||
this.opTime = opTime;
|
||||
}
|
||||
public SpecificServiceCfg getParent() {
|
||||
return parent;
|
||||
}
|
||||
public void setParent(SpecificServiceCfg parent) {
|
||||
this.parent = parent;
|
||||
}
|
||||
public Integer getIsLeaf() {
|
||||
return isLeaf;
|
||||
}
|
||||
public void setIsLeaf(Integer isLeaf) {
|
||||
this.isLeaf = isLeaf;
|
||||
}
|
||||
public Integer getGroupId() {
|
||||
return groupId;
|
||||
}
|
||||
public void setGroupId(Integer groupId) {
|
||||
this.groupId = groupId;
|
||||
}
|
||||
public Date getBeginDate() {
|
||||
return beginDate;
|
||||
}
|
||||
public void setBeginDate(Date beginDate) {
|
||||
this.beginDate = beginDate;
|
||||
}
|
||||
public Date getEndDate() {
|
||||
return endDate;
|
||||
}
|
||||
public void setEndDate(Date endDate) {
|
||||
this.endDate = endDate;
|
||||
}
|
||||
public String getShowSequence() {
|
||||
return showSequence;
|
||||
}
|
||||
public void setShowSequence(String showSequence) {
|
||||
this.showSequence = showSequence;
|
||||
}
|
||||
@JsonIgnore
|
||||
public static void sortList(List<SpecificServiceCfg> list, List<SpecificServiceCfg> allList, Integer parentId, boolean cascade) {
|
||||
|
||||
for(int i=0;i<allList.size();i++){
|
||||
SpecificServiceCfg ss = allList.get(i);
|
||||
System.out.println("处理"+ss.getSpecServiceName()+"id:"+ss.getSpecServiceId()+"父ID:"+ss.getParent().getSpecServiceId()+"条件》》"+parentId);
|
||||
if(ss!=null&&ss.getParent()!=null&&ss.getParent().getSpecServiceId()!=null&&ss.getParent().getSpecServiceId().equals(parentId)){
|
||||
list.add(ss);
|
||||
System.out.println("list加入"+ss.getSpecServiceName()+"id:"+ss.getSpecServiceId()+"父ID:"+ss.getParent().getSpecServiceId());
|
||||
if(cascade){
|
||||
for(int j=0;j<allList.size();j++){
|
||||
SpecificServiceCfg child = allList.get(j);
|
||||
if(child!=null&&child.getParent()!=null&&child.getParent().getSpecServiceId()!=null&&child.getParent().getSpecServiceId().equals(ss.getSpecServiceId())){
|
||||
sortList(list,allList,ss.getSpecServiceId(),true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
//处理下级序号
|
||||
public static void addChildrenSeq(List<SpecificServiceCfg> list,Integer parentId){
|
||||
int countNo = 1;
|
||||
for(int i=0; i<list.size(); i++){
|
||||
SpecificServiceCfg ss = list.get(i);
|
||||
if(ss.getParent()!=null && ss.getParent().getSpecServiceId()!=null
|
||||
&& ss.getParent().getSpecServiceId().equals(parentId)){
|
||||
//找出该父类
|
||||
for(SpecificServiceCfg se:list){
|
||||
if(se.getSpecServiceId()==parentId){
|
||||
ss.setShowSequence(se.getShowSequence()+Configurations.getStringProperty("childrenMark", ".")+countNo);
|
||||
countNo++;
|
||||
}
|
||||
}
|
||||
//继续获取子节点
|
||||
for (int j=0; j<list.size(); j++){
|
||||
SpecificServiceCfg child = list.get(j);
|
||||
if (child.getParent()!=null && child.getParent().getSpecServiceId()!=null
|
||||
&& child.getParent().getSpecServiceId().equals(ss.getSpecServiceId())){
|
||||
addChildrenSeq(list, ss.getSpecServiceId());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,236 @@
|
||||
package com.nis.domain.specific;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.nis.domain.BaseEntity;
|
||||
import com.nis.domain.SysUser;
|
||||
|
||||
/**
|
||||
* 系统特定服务信息表-记录特定服务信息(specific_service_cfg)
|
||||
* @author zsl
|
||||
*
|
||||
*/
|
||||
public class SpecificServiceHostCfg extends BaseEntity<SpecificServiceHostCfg>{
|
||||
|
||||
private static final long serialVersionUID = -301627652860717175L;
|
||||
|
||||
private Integer hostId; //host_id 配置ID bigint N 主键,自增
|
||||
private Integer specServiceId; //spec_service_id 协议id int N protocol_info_cfg.protocol_id
|
||||
private Integer ipType; //ip地址类型 ipV4=4 ipV6=6
|
||||
private String srcIp; //src_ip 源IP地址 varchar(64) N 缺省0.0.0.0值表示任意
|
||||
private String srcIpMask; //src_ip_mask 源地址掩码 varchar(64) N IPV4:255.255.255.255表示无掩码,即精确IP匹配,0.0.0.0值表示任意;
|
||||
//IPV6:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF表示无掩码,::(两个半角冒号)表示任意。非0掩码值必须是2的指数幂,下同。
|
||||
private String srcPort; //src_port 源端口 varchar(6) N 0表示任意值
|
||||
private String srcPortMask; //src_port_mask 源端口掩码 varchar(6) N 65535表示无掩码,即精确端口匹配,0表示任意
|
||||
private String dstIp; //dst_ip 目的IP地址 varchar(64) N 缺省0.0.0.0值表示任意
|
||||
private String dstIpMask; //dst_ip_mask 目的地址掩码 varchar(64) N 同源ip地址掩码
|
||||
private String dstPort; //dst_port 目的端口 varchar(6) N 目的端口,0表示任意值
|
||||
private String dstPortMask; //dst_port_mask 目的端口掩码 varchar(6) N 同源端口掩码
|
||||
private Integer direction;; //direction 方向 int N 0双向,1单向,默认缺省为双向。
|
||||
private Integer protocol; //protocol 协议 int N 6表示tcp,17表示udp,0表示任意
|
||||
private Integer isValid; //is_valid 有效标识 int N 0无效,1有效
|
||||
private Integer isAudit; //is_audit 是否审核 int N 0未审核,1审核通过,2审核未通过,3取消审核通过(即删除)
|
||||
private SysUser creator; //creator_id 创建人员 int N 取自sys_user.id
|
||||
private Date createTime; //create_time 配置时间 date N
|
||||
private SysUser editor; //editor_id 修改人员 int Y 取自sys_user.id
|
||||
private Date editTime; //edit_time 修改时间 date Y
|
||||
private SysUser auditor; //auditor_id 审核人员 int Y 取自sys_user.id
|
||||
private Date auditTime; //audit_time 审核时间 date Y
|
||||
|
||||
|
||||
|
||||
|
||||
private Date beginDate;
|
||||
private Date endDate;
|
||||
private Date editBeginDate;
|
||||
private Date editEndDate;
|
||||
private Date auditBeginDate;
|
||||
private Date auditEndDate;
|
||||
|
||||
|
||||
public Integer getHostId() {
|
||||
return hostId;
|
||||
}
|
||||
public void setHostId(Integer hostId) {
|
||||
this.hostId = hostId;
|
||||
}
|
||||
public Integer getSpecServiceId() {
|
||||
return specServiceId;
|
||||
}
|
||||
public void setSpecServiceId(Integer specServiceId) {
|
||||
this.specServiceId = specServiceId;
|
||||
}
|
||||
public Integer getIpType() {
|
||||
return ipType;
|
||||
}
|
||||
public void setIpType(Integer ipType) {
|
||||
this.ipType = ipType;
|
||||
}
|
||||
public String getSrcIp() {
|
||||
return srcIp;
|
||||
}
|
||||
public void setSrcIp(String srcIp) {
|
||||
this.srcIp = srcIp;
|
||||
}
|
||||
public String getSrcIpMask() {
|
||||
return srcIpMask;
|
||||
}
|
||||
public void setSrcIpMask(String srcIpMask) {
|
||||
this.srcIpMask = srcIpMask;
|
||||
}
|
||||
public String getSrcPort() {
|
||||
return srcPort;
|
||||
}
|
||||
public void setSrcPort(String srcPort) {
|
||||
this.srcPort = srcPort;
|
||||
}
|
||||
public String getSrcPortMask() {
|
||||
return srcPortMask;
|
||||
}
|
||||
public void setSrcPortMask(String srcPortMask) {
|
||||
this.srcPortMask = srcPortMask;
|
||||
}
|
||||
public String getDstIp() {
|
||||
return dstIp;
|
||||
}
|
||||
public void setDstIp(String dstIp) {
|
||||
this.dstIp = dstIp;
|
||||
}
|
||||
public String getDstIpMask() {
|
||||
return dstIpMask;
|
||||
}
|
||||
public void setDstIpMask(String dstIpMask) {
|
||||
this.dstIpMask = dstIpMask;
|
||||
}
|
||||
public String getDstPort() {
|
||||
return dstPort;
|
||||
}
|
||||
public void setDstPort(String dstPort) {
|
||||
this.dstPort = dstPort;
|
||||
}
|
||||
public String getDstPortMask() {
|
||||
return dstPortMask;
|
||||
}
|
||||
public void setDstPortMask(String dstPortMask) {
|
||||
this.dstPortMask = dstPortMask;
|
||||
}
|
||||
public Integer getDirection() {
|
||||
return direction;
|
||||
}
|
||||
public void setDirection(Integer direction) {
|
||||
this.direction = direction;
|
||||
}
|
||||
public Integer getProtocol() {
|
||||
return protocol;
|
||||
}
|
||||
public void setProtocol(Integer protocol) {
|
||||
this.protocol = protocol;
|
||||
}
|
||||
public Integer getIsValid() {
|
||||
return isValid;
|
||||
}
|
||||
public void setIsValid(Integer isValid) {
|
||||
this.isValid = isValid;
|
||||
}
|
||||
public Integer getIsAudit() {
|
||||
return isAudit;
|
||||
}
|
||||
public void setIsAudit(Integer isAudit) {
|
||||
this.isAudit = isAudit;
|
||||
}
|
||||
public SysUser getCreator() {
|
||||
return creator;
|
||||
}
|
||||
public void setCreator(SysUser creator) {
|
||||
this.creator = creator;
|
||||
}
|
||||
public Date getCreateTime() {
|
||||
return createTime;
|
||||
}
|
||||
public void setCreateTime(Date createTime) {
|
||||
this.createTime = createTime;
|
||||
}
|
||||
public SysUser getEditor() {
|
||||
return editor;
|
||||
}
|
||||
public void setEditor(SysUser editor) {
|
||||
this.editor = editor;
|
||||
}
|
||||
public Date getEditTime() {
|
||||
return editTime;
|
||||
}
|
||||
public void setEditTime(Date editTime) {
|
||||
this.editTime = editTime;
|
||||
}
|
||||
public SysUser getAuditor() {
|
||||
return auditor;
|
||||
}
|
||||
public void setAuditor(SysUser auditor) {
|
||||
this.auditor = auditor;
|
||||
}
|
||||
public Date getAuditTime() {
|
||||
return auditTime;
|
||||
}
|
||||
public void setAuditTime(Date auditTime) {
|
||||
this.auditTime = auditTime;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public Date getBeginDate() {
|
||||
return beginDate;
|
||||
}
|
||||
public void setBeginDate(Date beginDate) {
|
||||
this.beginDate = beginDate;
|
||||
}
|
||||
public Date getEndDate() {
|
||||
return endDate;
|
||||
}
|
||||
public void setEndDate(Date endDate) {
|
||||
this.endDate = endDate;
|
||||
}
|
||||
public Date getEditBeginDate() {
|
||||
return editBeginDate;
|
||||
}
|
||||
public void setEditBeginDate(Date editBeginDate) {
|
||||
this.editBeginDate = editBeginDate;
|
||||
}
|
||||
public Date getEditEndDate() {
|
||||
return editEndDate;
|
||||
}
|
||||
public void setEditEndDate(Date editEndDate) {
|
||||
this.editEndDate = editEndDate;
|
||||
}
|
||||
public Date getAuditBeginDate() {
|
||||
return auditBeginDate;
|
||||
}
|
||||
public void setAuditBeginDate(Date auditBeginDate) {
|
||||
this.auditBeginDate = auditBeginDate;
|
||||
}
|
||||
public Date getAuditEndDate() {
|
||||
return auditEndDate;
|
||||
}
|
||||
public void setAuditEndDate(Date auditEndDate) {
|
||||
this.auditEndDate = auditEndDate;
|
||||
}
|
||||
/**
|
||||
* 处理数据
|
||||
* @param list
|
||||
* @param sourceList
|
||||
* @param ParentId
|
||||
* @param cascade
|
||||
*/
|
||||
@JsonIgnore
|
||||
public static void sort(List<SpecificServiceHostCfg> list, List<SpecificServiceHostCfg> sourceList, Integer ParentId, boolean cascade){
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -11,9 +11,11 @@ import com.nis.domain.SysDataDictionaryItem;
|
||||
import com.nis.domain.SysDataDictionaryName;
|
||||
import com.nis.domain.basics.ServiceDictInfo;
|
||||
import com.nis.domain.basics.SysDictInfo;
|
||||
import com.nis.domain.specific.SpecificServiceCfg;
|
||||
import com.nis.web.dao.SysDictDao;
|
||||
import com.nis.web.dao.basics.ServiceDictInfoDao;
|
||||
import com.nis.web.dao.basics.SysDictInfoDao;
|
||||
import com.nis.web.dao.specific.SpecificServiceCfgDao;
|
||||
import com.nis.web.service.SpringContextHolder;
|
||||
|
||||
|
||||
@@ -29,6 +31,7 @@ public class ConfigDictUtils {
|
||||
|
||||
private final static ServiceDictInfoDao serviceDictInfoDao = SpringContextHolder.getBean(ServiceDictInfoDao.class);
|
||||
private final static SysDictInfoDao sysDictInfoDao = SpringContextHolder.getBean(SysDictInfoDao.class);
|
||||
private final static SpecificServiceCfgDao specificServiceCfgDao = SpringContextHolder.getBean(SpecificServiceCfgDao.class);
|
||||
|
||||
/**
|
||||
* 根据主键查询配置详情
|
||||
@@ -47,6 +50,15 @@ public class ConfigDictUtils {
|
||||
public static SysDictInfo getSysDictInfoById(Integer sysDictId){
|
||||
return sysDictInfoDao.getDictById(sysDictId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键查询配置详情
|
||||
* @param sysDictId
|
||||
* @return
|
||||
*/
|
||||
public static SpecificServiceCfg getBySpecServiceId(Integer specServiceId){
|
||||
return specificServiceCfgDao.getBySpecServiceId(specServiceId);
|
||||
}
|
||||
/**
|
||||
* 根据计算公式计算数据结果
|
||||
* @param sysDictId
|
||||
|
||||
@@ -40,6 +40,8 @@ import com.nis.web.service.configuration.SslCfgService;
|
||||
import com.nis.web.service.configuration.StringCfgService;
|
||||
import com.nis.web.service.configuration.TunnelCfgService;
|
||||
import com.nis.web.service.configuration.WebCfgService;
|
||||
import com.nis.web.service.specific.SpecificServiceCfgService;
|
||||
import com.nis.web.service.specific.SpecificServiceHostCfgService;
|
||||
import com.nis.web.service.systemService.ServiceConfigInfoService;
|
||||
import com.nis.web.service.systemService.SystemServiceService;
|
||||
|
||||
@@ -121,6 +123,10 @@ public class BaseController {
|
||||
protected NumCfgService numCfgService;
|
||||
@Autowired
|
||||
protected ComplexStringCfgService complexStringCfgService;
|
||||
@Autowired
|
||||
protected SpecificServiceCfgService specificServiceCfgService;
|
||||
@Autowired
|
||||
protected SpecificServiceHostCfgService specificServiceHostCfgService;
|
||||
/**
|
||||
* 管理基础路径
|
||||
*/
|
||||
|
||||
@@ -77,79 +77,7 @@ public class ServiceDictInfoController extends BaseController {
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
intArr[i] = Integer.valueOf(strArr[i]);
|
||||
}
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
model.addAttribute("selectedType", serviceDictInfo.getItemType());
|
||||
}else{
|
||||
model.addAttribute("selectedType", selectedType);
|
||||
serviceDictInfo.setItemType(selectedType);
|
||||
}
|
||||
//查询符合条件总数
|
||||
List<ServiceDictInfo> showTotalCount = serviceDictInfoService.findAllDictSearchList(serviceDictInfo,intArr);
|
||||
model.addAttribute("showTotalCount", showTotalCount.size());
|
||||
|
||||
//查出顶层分页数据
|
||||
Page<ServiceDictInfo> page = serviceDictInfoService.findTopDictList(new Page<ServiceDictInfo>(request, response), serviceDictInfo,intArr);
|
||||
//植入序号
|
||||
for(int i=0;i<page.getList().size();i++){
|
||||
page.getList().get(i).setShowSequence(""+(i+1+((page.getPageNo()-1)*page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
//查出所有数据
|
||||
List<ServiceDictInfo> allList = serviceDictInfoService.findAllDictList();
|
||||
//处理数据,保留顶层中的所有下层数据
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
for(int i=allList.size()-1;i>=0;i--){
|
||||
ServiceDictInfo se = allList.get(i);
|
||||
if(se!=null&&se.getParent()!=null&&se.getParent().getServiceDictId()!=null&&se.getParent().getServiceDictId()==0){
|
||||
allList.remove(se);
|
||||
}
|
||||
}
|
||||
allList.addAll(page.getList());
|
||||
ServiceDictInfo.sortList(list,allList,0,true);
|
||||
|
||||
//处理下级序号
|
||||
ServiceDictInfo.addChildrenSeq(list, 0);
|
||||
model.addAttribute("itType", itType);
|
||||
model.addAttribute("intArr", Arrays.asList(intArr));
|
||||
model.addAttribute("list", list);
|
||||
return "/basics/serviceDictList";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询业务辅助表-业务字典信息列表(含条件查询)
|
||||
* @param serviceDictInfo
|
||||
* @param request
|
||||
* @param response
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequestMapping(value = {"searchList"})
|
||||
public String searchList(String itType, ServiceDictInfo serviceDictInfo,HttpServletRequest request, HttpServletResponse response, Model model,Integer selectedType) {
|
||||
if(StringUtils.strIsBlank(serviceDictInfo.getItemValue())
|
||||
&&StringUtils.strIsBlank(serviceDictInfo.getItemCode())
|
||||
&&serviceDictInfo.getBeginDate()==null
|
||||
&&serviceDictInfo.getEndDate()==null
|
||||
&&serviceDictInfo.getEditBeginDate()==null
|
||||
&&serviceDictInfo.getEditEndDate()==null){
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
selectedType = serviceDictInfo.getItemType();
|
||||
return "redirect:"+ adminPath + "/basics/serviceDictInfo/list?itType="+itType+"&selectedType="+selectedType+"&isFilterAction="+serviceDictInfo.getIsFilterAction();
|
||||
}
|
||||
return "redirect:"+ adminPath + "/basics/serviceDictInfo/list?itType="+itType+"&isFilterAction="+serviceDictInfo.getIsFilterAction();
|
||||
}
|
||||
String[] strArr = itType.split("-");
|
||||
Integer[] intArr = new Integer[strArr.length];
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
intArr[i] = Integer.valueOf(strArr[i]);
|
||||
}
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
model.addAttribute("selectedType", serviceDictInfo.getItemType());
|
||||
}else{
|
||||
model.addAttribute("selectedType", selectedType);
|
||||
serviceDictInfo.setItemType(selectedType);
|
||||
}
|
||||
String searchType = null;
|
||||
String searchContent = null;
|
||||
if(!StringUtils.isBlank(serviceDictInfo.getItemCode())){
|
||||
@@ -163,46 +91,46 @@ public class ServiceDictInfoController extends BaseController {
|
||||
model.addAttribute("searchType", searchType);
|
||||
model.addAttribute("searchContent", searchContent);
|
||||
|
||||
//先查出条件查询所有数据(注意顺序)
|
||||
List<ServiceDictInfo> allList = serviceDictInfoService.findAllDictSearchList(serviceDictInfo,intArr);
|
||||
Page<ServiceDictInfo> pageCondition = new Page<ServiceDictInfo>(request, response);
|
||||
//查询符合条件总数
|
||||
List<ServiceDictInfo> allList = serviceDictInfoService.findAllServiceDictInfo(serviceDictInfo,intArr,pageCondition.getOrderBy());
|
||||
model.addAttribute("showTotalCount", allList.size());
|
||||
//查出条件查询顶层分页数据
|
||||
Page<ServiceDictInfo> page = serviceDictInfoService.findDictTopSearchList(new Page<ServiceDictInfo>(request, response), serviceDictInfo,intArr);
|
||||
//植入序号
|
||||
for(int i=0;i<page.getList().size();i++){
|
||||
page.getList().get(i).setShowSequence(""+(i+1+((page.getPageNo()-1)*page.getPageSize())));
|
||||
|
||||
//查出顶层分页数据
|
||||
Page<ServiceDictInfo> page = serviceDictInfoService.findTopDictList(pageCondition, serviceDictInfo,intArr);
|
||||
// 植入序号
|
||||
for (int i = 0; i < page.getList().size(); i++) {
|
||||
page.getList().get(i).setShowSequence("" + (i + 1 + ((page.getPageNo() - 1) * page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
|
||||
//处理数据,保留顶层中的所有下层数据
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
//取出主键优化处理
|
||||
List<Integer> tempList = Lists.newArrayList();
|
||||
for(ServiceDictInfo se:page.getList()){
|
||||
if(se!=null&&se.getServiceDictId()!=null){
|
||||
tempList.add(se.getServiceDictId());
|
||||
// 删除顶层数据、取出id 优化处理
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
|
||||
for(ServiceDictInfo tempSe : page.getList()) {
|
||||
if (tempSe != null) {
|
||||
intList.add(tempSe.getServiceDictId());
|
||||
}
|
||||
}
|
||||
//删除所有重复
|
||||
for(int i=allList.size()-1;i>=0;i--){
|
||||
|
||||
for (int i = allList.size() - 1; i >= 0; i--) {
|
||||
ServiceDictInfo se = allList.get(i);
|
||||
if(se!=null&&se.getServiceDictId()!=null){
|
||||
if(tempList.contains(se.getServiceDictId())||se.getParent().getServiceDictId()==0){
|
||||
if(se!=null&&intList.contains(se.getServiceDictId())||(se!=null&&se.getParent().getServiceDictId()==0)){
|
||||
allList.remove(se);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
|
||||
allList.addAll(page.getList());
|
||||
ServiceDictInfo.sortList(list,allList,0,true);
|
||||
|
||||
//处理下级序号
|
||||
ServiceDictInfo.addChildrenSeq(list, 0);
|
||||
//serviceDictInfo.setItemType(selectedType);
|
||||
model.addAttribute("itType", itType);
|
||||
model.addAttribute("intArr", Arrays.asList(intArr));
|
||||
model.addAttribute("list", list);
|
||||
|
||||
return "/basics/serviceDictInfoSearchList";
|
||||
return "/basics/serviceDictList";
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -76,77 +76,8 @@ public class SysDictInfoController extends BaseController {
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
intArr[i] = Integer.valueOf(strArr[i]);
|
||||
}
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
model.addAttribute("selectedType", sysDictInfo.getItemType());
|
||||
}else{
|
||||
model.addAttribute("selectedType", selectedType);
|
||||
sysDictInfo.setItemType(selectedType);
|
||||
}
|
||||
//查询符合条件总数
|
||||
List<SysDictInfo> showTotalCount = sysDictInfoService.findAllDictSearchList(sysDictInfo,intArr);
|
||||
model.addAttribute("showTotalCount", showTotalCount.size());
|
||||
|
||||
//查出顶层分页数据
|
||||
Page<SysDictInfo> page = sysDictInfoService.findTopDictList(new Page<SysDictInfo>(request, response), sysDictInfo,intArr);
|
||||
//植入序号
|
||||
for(int i=0;i<page.getList().size();i++){
|
||||
page.getList().get(i).setShowSequence(""+(i+1+((page.getPageNo()-1)*page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
//查出所有数据
|
||||
List<SysDictInfo> allList = sysDictInfoService.findAllDictList();
|
||||
//处理数据,保留顶层中的所有下层数据
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
for(int i=allList.size()-1;i>=0;i--){
|
||||
SysDictInfo se = allList.get(i);
|
||||
if(se!=null&&se.getParent()!=null&&se.getParent().getSysDictId()!=null&&se.getParent().getSysDictId()==0){
|
||||
allList.remove(se);
|
||||
}
|
||||
}
|
||||
allList.addAll(page.getList());
|
||||
SysDictInfo.sortList(list,allList,0,true);
|
||||
|
||||
//处理下级序号
|
||||
SysDictInfo.addChildrenSeq(list, 0);
|
||||
model.addAttribute("itType", itType);
|
||||
model.addAttribute("intArr", Arrays.asList(intArr));
|
||||
model.addAttribute("list", list);
|
||||
return "/basics/sysDictList";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询业务辅助表-系统字典信息列表(含条件查询)
|
||||
* @param sysDictInfo
|
||||
* @param request
|
||||
* @param response
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequestMapping(value = {"searchList"})
|
||||
public String searchList(String itType, SysDictInfo sysDictInfo,HttpServletRequest request, HttpServletResponse response, Model model, Integer selectedType) {
|
||||
if(StringUtils.strIsBlank(sysDictInfo.getItemValue())
|
||||
&&StringUtils.strIsBlank(sysDictInfo.getItemCode())
|
||||
&&sysDictInfo.getBeginDate()==null
|
||||
&&sysDictInfo.getEndDate()==null
|
||||
&&sysDictInfo.getEditBeginDate()==null
|
||||
&&sysDictInfo.getEditEndDate()==null){
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
selectedType = sysDictInfo.getItemType();
|
||||
return "redirect:"+ adminPath + "/basics/sysDictInfo/list?itType="+itType+"&selectedType="+selectedType+"&isFilterAction="+sysDictInfo.getIsFilterAction();
|
||||
}
|
||||
return "redirect:"+ adminPath + "/basics/sysDictInfo/list?itType="+itType+"&isFilterAction="+sysDictInfo.getIsFilterAction();
|
||||
}
|
||||
String[] strArr = itType.split("-");
|
||||
Integer[] intArr = new Integer[strArr.length];
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
intArr[i] = Integer.valueOf(strArr[i]);
|
||||
}
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
model.addAttribute("selectedType", sysDictInfo.getItemType());
|
||||
}else{
|
||||
model.addAttribute("selectedType", selectedType);
|
||||
sysDictInfo.setItemType(selectedType);
|
||||
if(intArr.length==1){
|
||||
model.addAttribute("specType", intArr[0]);
|
||||
}
|
||||
String searchType = null;
|
||||
String searchContent = null;
|
||||
@@ -160,70 +91,52 @@ public class SysDictInfoController extends BaseController {
|
||||
}
|
||||
model.addAttribute("searchType", searchType);
|
||||
model.addAttribute("searchContent", searchContent);
|
||||
//先查出条件查询所有数据(注意顺序)
|
||||
List<SysDictInfo> allList = sysDictInfoService.findAllDictSearchList(sysDictInfo,intArr);
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
model.addAttribute("selectedType", sysDictInfo.getItemType());
|
||||
}else{
|
||||
model.addAttribute("selectedType", selectedType);
|
||||
sysDictInfo.setItemType(selectedType);
|
||||
}
|
||||
Page<SysDictInfo> pageCondition = new Page<SysDictInfo>(request, response);
|
||||
|
||||
//查询符合条件总数
|
||||
List<SysDictInfo> allList = sysDictInfoService.findAllSysDictInfo(sysDictInfo,intArr,pageCondition.getOrderBy());
|
||||
model.addAttribute("showTotalCount", allList.size());
|
||||
//查出条件查询顶层分页数据
|
||||
Page<SysDictInfo> page = sysDictInfoService.findDictTopSearchList(new Page<SysDictInfo>(request, response), sysDictInfo,intArr);
|
||||
|
||||
//查出顶层分页数据
|
||||
Page<SysDictInfo> page = sysDictInfoService.findTopDictList(pageCondition, sysDictInfo,intArr);
|
||||
//植入序号
|
||||
for(int i=0;i<page.getList().size();i++){
|
||||
page.getList().get(i).setShowSequence(""+(i+1+((page.getPageNo()-1)*page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
|
||||
//处理数据,保留顶层中的所有下层数据
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
//取出主键优化处理
|
||||
List<Integer> tempList = Lists.newArrayList();
|
||||
//处理数据,取出主键优化处理
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
for(SysDictInfo se:page.getList()){
|
||||
if(se!=null&&se.getSysDictId()!=null){
|
||||
tempList.add(se.getSysDictId());
|
||||
if(se!=null){
|
||||
intList.add(se.getSysDictId());
|
||||
}
|
||||
}
|
||||
//删除所有重复
|
||||
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
for(int i=allList.size()-1;i>=0;i--){
|
||||
SysDictInfo se = allList.get(i);
|
||||
//System.out.println("删前顺序"+se.getSysDictId());
|
||||
if(se!=null&&se.getSysDictId()!=null){
|
||||
if(tempList.contains(se.getSysDictId())||se.getParent().getSysDictId()==0){
|
||||
if(se!=null&&intList.contains(se.getSysDictId())||(se!=null&&se.getParent().getSysDictId()==0)){
|
||||
allList.remove(se);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* for(int i=allList.size()-1;i>=0;i--){
|
||||
SysDictInfo se = allList.get(i);
|
||||
System.out.println("删后顺序"+se.getSysDictId());
|
||||
}*/
|
||||
|
||||
|
||||
allList.addAll(page.getList());
|
||||
SysDictInfo.sortList(list,allList,0,true);
|
||||
|
||||
|
||||
//处理下级序号
|
||||
SysDictInfo.addChildrenSeq(list, 0);
|
||||
/*for(int i=list.size()-1;i>=0;i--){
|
||||
SysDictInfo se = list.get(i);
|
||||
System.out.println("最终顺序"+se.getSysDictId()+":"+se.getParent().getSysDictId());
|
||||
}*/
|
||||
|
||||
model.addAttribute("itType", itType);
|
||||
model.addAttribute("intArr", Arrays.asList(intArr));
|
||||
model.addAttribute("list", list);
|
||||
|
||||
return "/basics/sysDictInfoSearchList";
|
||||
return "/basics/sysDictList";
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 进入添加或修改页面
|
||||
* @param sysDictInfo
|
||||
@@ -254,6 +167,9 @@ public class SysDictInfoController extends BaseController {
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
intArr[i] = Integer.valueOf(strArr[i]);
|
||||
}
|
||||
if(intArr.length==1){
|
||||
model.addAttribute("specType", intArr[0]);
|
||||
}
|
||||
model.addAttribute("intArr", Arrays.asList(intArr));
|
||||
model.addAttribute("sysDictInfo", sysDictInfo);
|
||||
model.addAttribute("itType", itType);
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
@@ -37,6 +38,7 @@ public class TaskInfoController extends BaseController{
|
||||
/**
|
||||
* 进入用户添加或修改页面
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value={"form"})
|
||||
public String form(TaskInfo taskInfo, Model model) {
|
||||
if(taskInfo.getId()!=null){
|
||||
@@ -51,6 +53,7 @@ public class TaskInfoController extends BaseController{
|
||||
/**
|
||||
* 新增/修改
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(TaskInfo taskInfo, HttpServletRequest request, Model model, RedirectAttributes redirectAttributes) {
|
||||
try {
|
||||
@@ -96,6 +99,7 @@ public class TaskInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value = "taskExamine")
|
||||
public String taskExamine(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] exId = ids.split(",");
|
||||
@@ -110,6 +114,7 @@ public class TaskInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value = "taskExamineNo")
|
||||
public String taskExamineNo(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] noId = ids.split(",");
|
||||
@@ -124,6 +129,7 @@ public class TaskInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value = "taskCancelExamine")
|
||||
public String taskCancelExamine(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] canclelId = ids.split(",");
|
||||
@@ -138,6 +144,7 @@ public class TaskInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("basics:taskInfo:edit")
|
||||
@RequestMapping(value = "delete")
|
||||
public String delete(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] delId = ids.split(",");
|
||||
|
||||
@@ -5,6 +5,7 @@ import java.util.List;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
@@ -38,6 +39,7 @@ public class RequestInfoController extends BaseController{
|
||||
/**
|
||||
* 进入用户添加或修改页面
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value={"form"})
|
||||
public String form(RequestInfo requestInfo, Model model) {
|
||||
TaskInfo taskInfo = new TaskInfo();
|
||||
@@ -55,6 +57,7 @@ public class RequestInfoController extends BaseController{
|
||||
/**
|
||||
* 新增/修改
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(RequestInfo requestInfo, HttpServletRequest request, Model model, RedirectAttributes redirectAttributes) {
|
||||
try {
|
||||
@@ -100,6 +103,7 @@ public class RequestInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value = "requestExamine")
|
||||
public String requestExamine(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] exId = ids.split(",");
|
||||
@@ -114,6 +118,7 @@ public class RequestInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value = "requestExamineNo")
|
||||
public String requestExamineNo(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] noId = ids.split(",");
|
||||
@@ -128,6 +133,7 @@ public class RequestInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value = "requestCancelExamine")
|
||||
public String requestCancelExamine(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] canclelId = ids.split(",");
|
||||
@@ -142,6 +148,7 @@ public class RequestInfoController extends BaseController{
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("cfg:requestInfo:edit")
|
||||
@RequestMapping(value = "delete")
|
||||
public String delete(String ids, Model model,RedirectAttributes redirectAttributes){
|
||||
String[] delId = ids.split(",");
|
||||
|
||||
@@ -0,0 +1,292 @@
|
||||
package com.nis.web.controller.specific;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import org.springframework.web.servlet.mvc.support.RedirectAttributes;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import com.google.common.collect.Maps;
|
||||
import com.nis.domain.Page;
|
||||
import com.nis.domain.specific.SpecificServiceCfg;
|
||||
import com.nis.util.StringUtil;
|
||||
import com.nis.util.StringUtils;
|
||||
import com.nis.web.controller.BaseController;
|
||||
|
||||
@Controller
|
||||
@RequestMapping(value = "${adminPath}/specific/specificServiceCfg")
|
||||
public class SpecificServiceCfgController extends BaseController {
|
||||
|
||||
/* @ModelAttribute
|
||||
public SpecificServiceCfg get(@RequestParam(required=false)Integer specServiceId) {
|
||||
if (!StringUtil.isEmpty(specServiceId)) {
|
||||
SpecificServiceCfg ss = specificServiceCfgService.getBySpecServiceId(specServiceId);
|
||||
return ss==null?new SpecificServiceCfg():ss;
|
||||
} else {
|
||||
return new SpecificServiceCfg();
|
||||
}
|
||||
}*/
|
||||
|
||||
/**
|
||||
* 查出分页列表
|
||||
*
|
||||
* @param specificServiceCfg
|
||||
* @param request
|
||||
* @param response
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequestMapping(value = "list")
|
||||
public String list(SpecificServiceCfg specificServiceCfg, HttpServletRequest request, HttpServletResponse response,
|
||||
Model model) {
|
||||
String searchType = null;
|
||||
String searchContent = null;
|
||||
if(specificServiceCfg.getSpecServiceId()!=null){
|
||||
searchType = "specServiceId";
|
||||
searchContent = specificServiceCfg.getSpecServiceId().toString();
|
||||
}
|
||||
if(!StringUtils.isBlank(specificServiceCfg.getSpecServiceName())){
|
||||
searchType = "specServiceName";
|
||||
searchContent = specificServiceCfg.getSpecServiceName();
|
||||
}
|
||||
if(!StringUtils.isBlank(specificServiceCfg.getSpecServiceDesc())){
|
||||
searchType = "specServiceDesc";
|
||||
searchContent = specificServiceCfg.getSpecServiceDesc();
|
||||
}
|
||||
if(specificServiceCfg.getGroupId()!=null){
|
||||
searchType = "groupId";
|
||||
searchContent = specificServiceCfg.getGroupId().toString();
|
||||
}
|
||||
model.addAttribute("searchType", searchType);
|
||||
model.addAttribute("searchContent", searchContent);
|
||||
|
||||
Page<SpecificServiceCfg> pageCondition = new Page<SpecificServiceCfg>(request, response);
|
||||
// 取出所有符合条件的数据
|
||||
List<SpecificServiceCfg> allList = specificServiceCfgService.findAllSpecificServiceCfg(specificServiceCfg,pageCondition.getOrderBy());
|
||||
model.addAttribute("showTotalCount", allList.size());
|
||||
// 取出所有符合条件的顶层分页
|
||||
Page<SpecificServiceCfg> page = specificServiceCfgService
|
||||
.findTopPage(pageCondition, specificServiceCfg);
|
||||
// 植入序号
|
||||
for (int i = 0; i < page.getList().size(); i++) {
|
||||
page.getList().get(i).setShowSequence("" + (i + 1 + ((page.getPageNo() - 1) * page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
// 删除顶层数据、取出id 优化处理
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
for (SpecificServiceCfg tempSS : page.getList()) {
|
||||
if (tempSS != null) {
|
||||
intList.add(tempSS.getSpecServiceId());
|
||||
}
|
||||
}
|
||||
for (int i = allList.size() - 1; i >= 0; i--) {
|
||||
SpecificServiceCfg ss = allList.get(i);
|
||||
if ((ss != null && intList.contains(ss.getSpecServiceId())) || (ss != null && ss.getParent().getSpecServiceId() == 0)) {
|
||||
allList.remove(ss);
|
||||
}
|
||||
}
|
||||
|
||||
allList.addAll(page.getList());
|
||||
|
||||
List<SpecificServiceCfg> list = Lists.newArrayList();
|
||||
SpecificServiceCfg.sortList(list, allList, 0, true);
|
||||
//处理下级序号
|
||||
SpecificServiceCfg.addChildrenSeq(list, 0);
|
||||
|
||||
model.addAttribute("list", list);
|
||||
|
||||
return "/specific/specificServiceCfgList";
|
||||
}
|
||||
|
||||
/**
|
||||
* 进入查看或新增、修改页面
|
||||
*
|
||||
* @param specificServiceCfg
|
||||
* @param model
|
||||
* @param doAction
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = { "form" })
|
||||
public String form(SpecificServiceCfg specificServiceCfg, Model model, String doAction, String mulitId) {
|
||||
|
||||
Integer id = 0;
|
||||
if (mulitId != null) {
|
||||
String[] ids = mulitId.split(",");
|
||||
id = Integer.valueOf(ids[0]);
|
||||
}
|
||||
if (id != 0) {
|
||||
specificServiceCfg = specificServiceCfgService.getBySpecServiceId(id);
|
||||
}
|
||||
if (specificServiceCfg == null || specificServiceCfg.getParent() == null
|
||||
|| specificServiceCfg.getParent().getSpecServiceId() == 0) {
|
||||
SpecificServiceCfg parent = new SpecificServiceCfg();
|
||||
parent.setSpecServiceId(0);
|
||||
parent.setSpecServiceName("根节点");
|
||||
specificServiceCfg.setParent(parent);
|
||||
}
|
||||
model.addAttribute("specificServiceCfg", specificServiceCfg);
|
||||
if (doAction != null && doAction.equals("0")) {
|
||||
return "/specific/specificServiceCfgInfo";
|
||||
}
|
||||
return "/specific/specificServiceCfgForm";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增或保存
|
||||
* @param specificServiceCfg
|
||||
* @param model
|
||||
* @param redirectAttributes
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:edit")
|
||||
@RequestMapping(value="saveOrUpdate")
|
||||
public String saveOrUpdate(SpecificServiceCfg specificServiceCfg, Model model,
|
||||
RedirectAttributes redirectAttributes,Integer oldId) {
|
||||
try {
|
||||
specificServiceCfgService.saveOrUpdate(specificServiceCfg,oldId);
|
||||
addMessage(redirectAttributes, "保存成功");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "保存失败!");
|
||||
}
|
||||
return "redirect:" + adminPath + "/specific/specificServiceCfg/list";
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除
|
||||
* @param specificServiceCfg
|
||||
* @param redirectAttributes
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value="delete")
|
||||
public String delete(SpecificServiceCfg specificServiceCfg, RedirectAttributes redirectAttributes, String mulitId){
|
||||
try{
|
||||
specificServiceCfgService.delete(mulitId);
|
||||
addMessage(redirectAttributes,"删除成功");
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes,"删除失败");
|
||||
}
|
||||
|
||||
return "redirect:"+adminPath+"/specific/specificServiceCfg/list";
|
||||
}
|
||||
|
||||
/**
|
||||
* 父节点选择树形结构
|
||||
* @param extId
|
||||
* @param isShowHide
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("user")
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "treeData")
|
||||
public List<Map<String, Object>> treeData(@RequestParam(required=false) String extId,@RequestParam(required=false) String isShowHide, HttpServletResponse response){
|
||||
List<Map<String, Object>> mapList = Lists.newArrayList();
|
||||
Map<String, Object> map2 = Maps.newHashMap();
|
||||
map2.put("id", 0);
|
||||
map2.put("pId", 0);
|
||||
map2.put("name","根节点");
|
||||
//map2.put("placeholder","0");
|
||||
mapList.add(map2);
|
||||
List<SpecificServiceCfg> list = specificServiceCfgService.findAllSpecificServiceCfg(new SpecificServiceCfg(),"");
|
||||
for (int i=0; i<list.size(); i++){
|
||||
SpecificServiceCfg specificServiceCfg = list.get(i);
|
||||
if(StringUtils.isBlank(extId)||(extId!=null&&!extId.equals(specificServiceCfg.getSpecServiceId().toString()))){
|
||||
if(specificServiceCfg.getIsValid().equals(0)||specificServiceCfg.getIsLeaf().equals(1)){
|
||||
continue;
|
||||
}
|
||||
Map<String, Object> map = Maps.newHashMap();
|
||||
map.put("id", specificServiceCfg.getSpecServiceId());
|
||||
map.put("pId", specificServiceCfg.getParent().getSpecServiceId());
|
||||
map.put("name",specificServiceCfg.getSpecServiceName());
|
||||
mapList.add(map);
|
||||
}
|
||||
}
|
||||
return mapList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验协议id是否重复
|
||||
* @param specServiceId
|
||||
* @param oldId
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "isIdRepeat")
|
||||
public boolean isIdRepeat(String specServiceId,String oldId){
|
||||
if(oldId!=null){
|
||||
if(oldId.trim().equals(specServiceId)){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if(specServiceId!=null){
|
||||
SpecificServiceCfg ss = specificServiceCfgService.getBySpecServiceId(Integer.valueOf(specServiceId));
|
||||
if(ss==null){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 校验叶子节点无上级不得选为叶子节点
|
||||
* @param specServiceId
|
||||
* @param oldId
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "ajaxLeafHasTree")
|
||||
public boolean ajaxLeafHasTree(Integer parentId, Integer newIsLeaf){
|
||||
if(parentId==null||parentId==0){
|
||||
if(newIsLeaf==0){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
if(parentId!=null&parentId!=0){
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 校验叶子节点有下级不得更改为叶子节点
|
||||
* @param parent
|
||||
* @param newIsLeaf
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "ajaxLeafChange")
|
||||
public boolean ajaxLeafChange(Integer parent,Integer newIsLeaf){
|
||||
if(parent==null){
|
||||
return true;
|
||||
}
|
||||
List<SpecificServiceCfg> list = specificServiceCfgService.getChildrenById(parent);
|
||||
if(list==null||list.size()==0){
|
||||
return true;
|
||||
}else{
|
||||
if(newIsLeaf==0){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,149 @@
|
||||
package com.nis.web.controller.specific;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import org.springframework.web.servlet.mvc.support.RedirectAttributes;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import com.nis.domain.Page;
|
||||
import com.nis.domain.specific.SpecificServiceHostCfg;
|
||||
import com.nis.util.StringUtil;
|
||||
import com.nis.web.controller.BaseController;
|
||||
|
||||
@Controller
|
||||
@RequestMapping(value = "${adminPath}/specific/specificServiceHostCfg")
|
||||
public class SpecificServiceHostCfgController extends BaseController {
|
||||
|
||||
|
||||
@ModelAttribute
|
||||
public SpecificServiceHostCfg get(@RequestParam(required=false) Integer hostId) {
|
||||
if (!StringUtil.isEmpty(hostId)){
|
||||
return specificServiceHostCfgService.getDictByHostId(hostId);
|
||||
}else{
|
||||
return new SpecificServiceHostCfg();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param specificServiceHostCfg
|
||||
* @param request
|
||||
* @param response
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequestMapping(value = "list")
|
||||
public String list(SpecificServiceHostCfg specificServiceHostCfg, HttpServletRequest request, HttpServletResponse response,
|
||||
Model model) {
|
||||
|
||||
//查出分页数据
|
||||
Page<SpecificServiceHostCfg> page = specificServiceHostCfgService.findSpecHostList(new Page<SpecificServiceHostCfg>(request, response), specificServiceHostCfg);
|
||||
model.addAttribute("page", page);
|
||||
//查出所有
|
||||
List<SpecificServiceHostCfg> list = specificServiceHostCfgService.getAll();
|
||||
List<Integer> listSpecServiceId = Lists.newArrayList();
|
||||
List<String> listSrcIp = Lists.newArrayList();
|
||||
List<String> listDstIp = Lists.newArrayList();
|
||||
for(SpecificServiceHostCfg ssh:list){
|
||||
if(ssh!=null&&ssh.getSpecServiceId()!=null&&(!listSpecServiceId.contains(ssh.getSpecServiceId()))){
|
||||
listSpecServiceId.add(ssh.getSpecServiceId());
|
||||
}
|
||||
if(ssh!=null&&ssh.getSrcIp()!=null&&(!listSrcIp.contains(ssh.getSrcIp()))){
|
||||
listSrcIp.add(ssh.getSrcIp());
|
||||
}
|
||||
if(ssh!=null&&ssh.getDstIp()!=null&&(!listDstIp.contains(ssh.getDstIp()))){
|
||||
listDstIp.add(ssh.getDstIp());
|
||||
}
|
||||
}
|
||||
model.addAttribute("listSpecServiceId", listSpecServiceId);
|
||||
model.addAttribute("listSrcIp", listSrcIp);
|
||||
model.addAttribute("listDstIp", listDstIp);
|
||||
return "/specific/specificServiceHostCfgList";
|
||||
}
|
||||
|
||||
/**
|
||||
* 进入查看、修改或新增页面
|
||||
* @param specificServiceHostCfg
|
||||
* @param request
|
||||
* @param response
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequestMapping(value = "form")
|
||||
public String form(SpecificServiceHostCfg specificServiceHostCfg, HttpServletRequest request, HttpServletResponse response, Model model) {
|
||||
|
||||
return "/specific/specificServiceHostCfgForm";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增或修改
|
||||
* @param specificServiceHostCfg
|
||||
* @param model
|
||||
* @param redirectAttributes
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(SpecificServiceHostCfg specificServiceHostCfg,Model model,RedirectAttributes redirectAttributes){
|
||||
try {
|
||||
specificServiceHostCfgService.saveOrUpdate(specificServiceHostCfg);
|
||||
addMessage(redirectAttributes, "保存成功");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "保存失败!");
|
||||
}
|
||||
return "redirect:"+adminPath+"/specific/specificServiceHostCfg/list";
|
||||
}
|
||||
/**
|
||||
* 删除
|
||||
* @param specificServiceHostCfg
|
||||
* @param redirectAttributes
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value="delete")
|
||||
public String delete(SpecificServiceHostCfg specificServiceHostCfg, RedirectAttributes redirectAttributes, String mulitId){
|
||||
try{
|
||||
specificServiceHostCfgService.delete(mulitId);
|
||||
addMessage(redirectAttributes,"删除成功");
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes,"删除失败");
|
||||
}
|
||||
|
||||
return "redirect:"+adminPath+"/specific/specificServiceHostCfg/list";
|
||||
}
|
||||
/**
|
||||
* 校验spec_service_id重复
|
||||
* @param newId
|
||||
* @param oldId
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "isSpecServiceIdRepeat")
|
||||
public boolean isSpecServiceIdRepeat(String newId,String oldId){
|
||||
if(oldId!=null){
|
||||
oldId.trim().equals(newId);
|
||||
return true;
|
||||
}else{
|
||||
SpecificServiceHostCfg sshc = specificServiceHostCfgService.getBySpecServiceId(Integer.valueOf(newId));
|
||||
if(sshc==null){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -13,17 +13,32 @@ import com.nis.web.dao.MyBatisDao;
|
||||
public interface ServiceDictInfoDao extends CrudDao<ServiceDictInfo> {
|
||||
|
||||
/**
|
||||
* 查询顶层字典列表(无条件查询(==))
|
||||
* 查询顶层字典列表(==)
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findTopDictList(ServiceDictInfo serviceDictInfo);
|
||||
/**
|
||||
* 查询顶层字典列表(无条件查询(!=))
|
||||
* 查询顶层字典列表(!=)
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findTopDictListN(ServiceDictInfo serviceDictInfo);
|
||||
/**
|
||||
* findAllServiceDictInfo
|
||||
*/
|
||||
/**
|
||||
* 查询所有字典列表(==)
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findAllServiceDictInfo(@Param("serviceDictInfo")ServiceDictInfo serviceDictInfo,@Param("orderBy")String orderBy);
|
||||
/**
|
||||
* 查询所有字典列表(!=)
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findAllServiceDictInfoN(@Param("serviceDictInfo")ServiceDictInfo serviceDictInfo,@Param("orderBy")String orderBy);
|
||||
/**
|
||||
* 查出所有有效数据
|
||||
*/
|
||||
@@ -38,32 +53,6 @@ public interface ServiceDictInfoDao extends CrudDao<ServiceDictInfo> {
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> getDictByParentId(Integer parentId);
|
||||
/**
|
||||
* 查询条件查询顶层字典列表(含条件查询(==))
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findDictTopSearchList(ServiceDictInfo serviceDictInfo);
|
||||
/**
|
||||
* 查询条件查询顶层字典列表(含条件查询(!=))
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findDictTopSearchListN(ServiceDictInfo serviceDictInfo);
|
||||
/**
|
||||
* 查询条件查询所有字典列表(含条件查询(==))
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findAllDictSearchList(ServiceDictInfo serviceDictInfo);
|
||||
/**
|
||||
* 查询条件查询所有字典列表(含条件查询(!=))
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<ServiceDictInfo> findAllDictSearchListN(ServiceDictInfo serviceDictInfo);
|
||||
|
||||
|
||||
/**
|
||||
* 添加字典信息
|
||||
* @param serviceDictInfo
|
||||
|
||||
@@ -69,101 +69,6 @@
|
||||
|
||||
<!-- 查询顶层分页列表 (==)-->
|
||||
<select id="findTopDictList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
SELECT * FROM service_dict_info WHERE is_valid=1 AND parent_id = 0
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type = #{itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 查询顶层分页列表 (!=)-->
|
||||
<select id="findTopDictListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
SELECT * FROM service_dict_info WHERE is_valid=1 AND parent_id = 0
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type != #{itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- 查出所有 -->
|
||||
<select id="findAllDictList" resultType="serviceDictInfo">
|
||||
SELECT
|
||||
<include refid="serviceDictInfoColumns"/>
|
||||
FROM service_dict_info s
|
||||
<include refid="menuJoins"/>
|
||||
WHERE s.is_valid =1 AND s.parent_id != 0
|
||||
</select>
|
||||
|
||||
<!-- 查询所有非叶子配置 -->
|
||||
<select id="findAllNoLeafDictList" resultType="com.nis.domain.basics.ServiceDictInfo" parameterType="java.lang.Integer">
|
||||
SELECT
|
||||
<include refid="serviceDictInfoColumns"/>
|
||||
FROM service_dict_info s
|
||||
WHERE s.is_valid = 1 AND s.is_leaf = 0 AND item_type = #{itemType}
|
||||
ORDER BY s.create_time desc
|
||||
</select>
|
||||
|
||||
<!-- 条件查询顶层分页(==) -->
|
||||
<select id="findDictTopSearchList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
SELECT * FROM service_dict_info s WHERE s.is_valid=1
|
||||
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
@@ -222,8 +127,8 @@
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 条件查询顶层分页(!=) -->
|
||||
<select id="findDictTopSearchListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
<!-- 查询顶层分页列表 (!=)-->
|
||||
<select id="findTopDictListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
SELECT * FROM service_dict_info s WHERE s.is_valid=1
|
||||
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
@@ -282,62 +187,98 @@
|
||||
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
<!-- 条件查询所有列表 (==)-->
|
||||
<select id="findAllDictSearchList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
<!-- 查询所有列表 (==)-->
|
||||
<select id="findAllServiceDictInfo" resultMap="dictResultMap">
|
||||
SELECT * FROM service_dict_info WHERE is_valid=1
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
<if test="serviceDictInfo.itemValue != null and serviceDictInfo.itemValue != '' " >
|
||||
AND item_value like '%${serviceDictInfo.itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
<if test="serviceDictInfo.itemCode != null and serviceDictInfo.itemCode != '' " >
|
||||
AND item_code like '%${serviceDictInfo.itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type = #{itemType}
|
||||
<if test="serviceDictInfo.itemType != null and serviceDictInfo.itemType != '' " >
|
||||
AND item_type = #{serviceDictInfo.itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.beginDate !=null" >
|
||||
AND create_time >= #{serviceDictInfo.beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.endDate !=null" >
|
||||
AND create_time <= #{serviceDictInfo.endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.editBeginDate !=null" >
|
||||
AND edit_time >= #{serviceDictInfo.editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.editEndDate !=null" >
|
||||
AND edit_time <= #{serviceDictInfo.editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="orderBy != null and orderBy != ''">
|
||||
ORDER BY ${orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
|
||||
<!-- 条件查询所有列表 (!=)-->
|
||||
<select id="findAllDictSearchListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.ServiceDictInfo">
|
||||
<!-- 查询所有列表 (!=)-->
|
||||
<select id="findAllServiceDictInfoN" resultMap="dictResultMap">
|
||||
SELECT * FROM service_dict_info WHERE is_valid=1
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
<if test="serviceDictInfo.itemValue != null and serviceDictInfo.itemValue != '' " >
|
||||
AND item_value like '%${serviceDictInfo.itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
<if test="serviceDictInfo.itemCode != null and serviceDictInfo.itemCode != '' " >
|
||||
AND item_code like '%${serviceDictInfo.itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type != #{itemType}
|
||||
<if test="serviceDictInfo.itemType != null and serviceDictInfo.itemType != '' " >
|
||||
AND item_type != #{serviceDictInfo.itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.beginDate !=null" >
|
||||
AND create_time >= #{serviceDictInfo.beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.endDate !=null" >
|
||||
AND create_time <= #{serviceDictInfo.endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.editBeginDate !=null" >
|
||||
AND edit_time >= #{serviceDictInfo.editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
<if test="serviceDictInfo.editEndDate !=null" >
|
||||
AND edit_time <= #{serviceDictInfo.editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="orderBy != null and orderBy != ''">
|
||||
ORDER BY ${orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
|
||||
<!-- 查出所有 -->
|
||||
<select id="findAllDictList" resultType="serviceDictInfo">
|
||||
SELECT
|
||||
<include refid="serviceDictInfoColumns"/>
|
||||
FROM service_dict_info s
|
||||
<include refid="menuJoins"/>
|
||||
WHERE s.is_valid =1 AND s.parent_id != 0
|
||||
</select>
|
||||
|
||||
<!-- 查询所有非叶子配置 -->
|
||||
<select id="findAllNoLeafDictList" resultType="com.nis.domain.basics.ServiceDictInfo" parameterType="java.lang.Integer">
|
||||
SELECT
|
||||
<include refid="serviceDictInfoColumns"/>
|
||||
FROM service_dict_info s
|
||||
WHERE s.is_valid = 1 AND s.is_leaf = 0 AND item_type = #{itemType}
|
||||
ORDER BY s.create_time desc
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -2,6 +2,8 @@ package com.nis.web.dao.basics;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import com.nis.domain.basics.SysDictInfo;
|
||||
import com.nis.web.dao.CrudDao;
|
||||
import com.nis.web.dao.MyBatisDao;
|
||||
@@ -12,48 +14,35 @@ public interface SysDictInfoDao extends CrudDao<SysDictInfo> {
|
||||
|
||||
|
||||
/**
|
||||
* 查询顶层字典列表(无条件查询(==))
|
||||
* 查询顶层字典列表(==))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findTopDictList(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 查询顶层字典列表(无条件查询(!=))
|
||||
* 查询顶层字典列表(!=)
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findTopDictListN(SysDictInfo sysDictInfo);
|
||||
|
||||
/**
|
||||
* 查询所有字典列表(含条件查询(==))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findAllSysDictInfo(@Param("sysDictInfo")SysDictInfo sysDictInfo,@Param("orderBy")String orderBy);
|
||||
/**
|
||||
* 查询所有字典列表(含条件查询(!=))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findAllSysDictInfoN(@Param("sysDictInfo")SysDictInfo sysDictInfo,@Param("orderBy")String orderBy);
|
||||
/**
|
||||
* 查出所有有效数据
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findAllDictList(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 查询条件查询顶层字典列表(含条件查询(==))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findDictTopSearchList(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 查询条件查询顶层字典列表(含条件查询(!=))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findDictTopSearchListN(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 查询字典列表(含条件查询(==))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findAllDictSearchList(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 查询字典列表(含条件查询(!=))
|
||||
* @param sysDictInfo
|
||||
* @return
|
||||
*/
|
||||
List<SysDictInfo> findAllDictSearchListN(SysDictInfo sysDictInfo);
|
||||
/**
|
||||
* 添加字典信息
|
||||
* @param sysDictInfo
|
||||
@@ -66,8 +55,6 @@ public interface SysDictInfoDao extends CrudDao<SysDictInfo> {
|
||||
* @return
|
||||
*/
|
||||
SysDictInfo getDictById(Integer sysDictId);
|
||||
|
||||
|
||||
/**
|
||||
* 查询所有的非叶子配置
|
||||
* @param itemType
|
||||
|
||||
@@ -50,79 +50,6 @@
|
||||
LEFT JOIN sys_dict_info p ON p.sys_dict_id = s.parent_id
|
||||
</sql>
|
||||
|
||||
<!-- 查询顶层分页列表 (==)-->
|
||||
<select id="findTopDictList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
SELECT * FROM sys_dict_info WHERE is_valid=1 AND parent_id = 0
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type = #{itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 查询顶层分页列表 (!=)-->
|
||||
<select id="findTopDictListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
SELECT * FROM sys_dict_info WHERE is_valid=1 AND parent_id = 0
|
||||
|
||||
<if test="itemValue != null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
</if>
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type != #{itemType}
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 查出所有 -->
|
||||
<select id="findAllDictList" resultType="sysDictInfo">
|
||||
SELECT
|
||||
@@ -132,8 +59,8 @@
|
||||
WHERE s.is_valid =1
|
||||
</select>
|
||||
|
||||
<!-- 条件查询顶层分页(==) -->
|
||||
<select id="findDictTopSearchList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
<!-- 查询顶层分页(==) -->
|
||||
<select id="findTopDictList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
SELECT * FROM sys_dict_info s WHERE s.is_valid=1
|
||||
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
@@ -192,8 +119,8 @@
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 条件查询顶层分页(!=) -->
|
||||
<select id="findDictTopSearchListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
<!-- 查询顶层分页(!=) -->
|
||||
<select id="findTopDictListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
SELECT * FROM sys_dict_info s WHERE s.is_valid=1
|
||||
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
@@ -252,57 +179,73 @@
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 条件查询所有(==) -->
|
||||
<select id="findAllDictSearchList" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
<!-- 查询所有(==) -->
|
||||
<select id="findAllSysDictInfo" resultMap="dictResultMap">
|
||||
SELECT * FROM sys_dict_info WHERE is_valid=1
|
||||
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type = ${itemType}
|
||||
<if test="sysDictInfo.itemType != null and sysDictInfo.itemType != '' " >
|
||||
AND item_type = ${sysDictInfo.itemType}
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
<if test="sysDictInfo.itemCode != null and sysDictInfo.itemCode != '' " >
|
||||
AND item_code like '%${sysDictInfo.itemCode}%'
|
||||
</if>
|
||||
<if test="itemValue!= null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
<if test="sysDictInfo.itemValue!= null and sysDictInfo.itemValue != '' " >
|
||||
AND item_value like '%${sysDictInfo.itemValue}%'
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.beginDate !=null" >
|
||||
AND create_time >= #{sysDictInfo.beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.endDate !=null" >
|
||||
AND create_time <= #{sysDictInfo.endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.editBeginDate !=null" >
|
||||
AND edit_time >= #{sysDictInfo.editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.editEndDate !=null" >
|
||||
AND edit_time <= #{sysDictInfo.editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="orderBy != null and orderBy != ''">
|
||||
ORDER BY ${orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
<!-- 条件查询所有(!=) -->
|
||||
<select id="findAllDictSearchListN" resultMap="dictResultMap" parameterType="com.nis.domain.basics.SysDictInfo">
|
||||
<!-- 查询所有(!=) -->
|
||||
<select id="findAllSysDictInfoN" resultMap="dictResultMap">
|
||||
SELECT * FROM sys_dict_info WHERE is_valid=1
|
||||
|
||||
<if test="itemType != null and itemType != '' " >
|
||||
AND item_type = ${itemType}
|
||||
<if test="sysDictInfo.itemType != null and sysDictInfo.itemType != '' " >
|
||||
AND item_type = ${sysDictInfo.itemType}
|
||||
</if>
|
||||
<if test="itemCode != null and itemCode != '' " >
|
||||
AND item_code like '%${itemCode}%'
|
||||
<if test="sysDictInfo.itemCode != null and sysDictInfo.itemCode != '' " >
|
||||
AND item_code like '%${sysDictInfo.itemCode}%'
|
||||
</if>
|
||||
<if test="itemValue!= null and itemValue != '' " >
|
||||
AND item_value like '%${itemValue}%'
|
||||
<if test="sysDictInfo.itemValue!= null and sysDictInfo.itemValue != '' " >
|
||||
AND item_value like '%${sysDictInfo.itemValue}%'
|
||||
</if>
|
||||
<if test="beginDate !=null" >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.beginDate !=null" >
|
||||
AND create_time >= #{sysDictInfo.beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null" >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.endDate !=null" >
|
||||
AND create_time <= #{sysDictInfo.endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null" >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.editBeginDate !=null" >
|
||||
AND edit_time >= #{sysDictInfo.editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null" >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
<if test="sysDictInfo.editEndDate !=null" >
|
||||
AND edit_time <= #{sysDictInfo.editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="orderBy != null and orderBy != ''">
|
||||
ORDER BY ${orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
|
||||
<!-- 根据主键查询字典详细信息 -->
|
||||
|
||||
@@ -39,6 +39,7 @@
|
||||
u.name AS editorName,
|
||||
r.edit_time AS editTime,
|
||||
e.name AS currentName,
|
||||
e.name AS auditorName,
|
||||
r.audit_time AS auditTime,
|
||||
t.task_name AS taskName
|
||||
from request_info r
|
||||
@@ -46,7 +47,7 @@
|
||||
left join sys_user u on r.editor_id=u.id
|
||||
left join sys_user e on r.auditor_id=e.id
|
||||
left join task_info t on r.task_id=t.id
|
||||
where r.is_valid=1 and r.is_audit !=3
|
||||
where r.is_valid!=-1 and r.is_audit !=3
|
||||
<if test="requestTitle != null and requestTitle != ''">
|
||||
AND r.request_title like
|
||||
<if test="dbName == 'mysql'">CONCAT('%',#{requestTitle}, '%')</if>
|
||||
@@ -56,7 +57,8 @@
|
||||
<if test="dbName == 'mysql'">CONCAT('%',#{requestContent},'%')</if>
|
||||
</if>
|
||||
<if test="requestNumber != null and requestNumber != ''">
|
||||
AND r.request_number=#{requestNumber}
|
||||
AND r.request_number like
|
||||
<if test="dbName == 'mysql'">CONCAT('%',#{requestNumber},'%')</if>
|
||||
</if>
|
||||
<if test="isAudit != null">
|
||||
AND r.is_audit=${isAudit}
|
||||
@@ -65,9 +67,18 @@
|
||||
AND r.request_time between #{beginDate} and #{endDate}
|
||||
</if>
|
||||
<if test="dobeginDate!=null and dobeginDate!='' and doendDate!=null and doendDate!=''">
|
||||
AND (r.create_time between #{dobeginDate} and #{doendDate}) or (r.audit_time between #{dobeginDate} and #{doendDate})
|
||||
AND r.edit_time between #{dobeginDate} and #{doendDate}
|
||||
</if>
|
||||
order by r.request_time desc
|
||||
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY r.create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
<!-- 根据来函号查询 -->
|
||||
<select id="getRequestInfoByRequestNumber" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
@@ -79,9 +90,30 @@
|
||||
<!-- 根据来id查询 -->
|
||||
<select id="getRequestInfoById" parameterType="java.lang.Long" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List"/>
|
||||
from request_info
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
r.id AS id,
|
||||
r.task_id AS taskId,
|
||||
r.request_number AS requestNumber,
|
||||
r.request_org AS requestOrg,
|
||||
r.request_time AS requestTime,
|
||||
r.request_title AS requestTitle,
|
||||
r.request_content AS requestContent,
|
||||
r.is_valid AS isValid,
|
||||
r.is_audit AS isAudit,
|
||||
s.name AS creatorName,
|
||||
r.create_time AS createTime,
|
||||
u.name AS editorName,
|
||||
r.edit_time AS editTime,
|
||||
e.name AS currentName,
|
||||
e.name AS auditorName,
|
||||
r.audit_time AS auditTime,
|
||||
t.task_name AS taskName
|
||||
from request_info r
|
||||
left join sys_user s on r.creator_id=s.id
|
||||
left join sys_user u on r.editor_id=u.id
|
||||
left join sys_user e on r.auditor_id=e.id
|
||||
left join task_info t on r.task_id=t.id
|
||||
where r.is_valid!=-1 and r.is_audit !=3
|
||||
and r.id = #{id,jdbcType=BIGINT}
|
||||
</select>
|
||||
<!-- 新增 -->
|
||||
<insert id="insert" parameterType="com.nis.domain.configuration.RequestInfo">
|
||||
@@ -98,31 +130,32 @@
|
||||
editor_id,
|
||||
edit_time,
|
||||
auditor_id,
|
||||
audit_time
|
||||
audit_time,
|
||||
task_id
|
||||
)
|
||||
values (#{requestNumber,jdbcType=VARCHAR}, #{requestOrg,jdbcType=VARCHAR},
|
||||
#{requestTime,jdbcType=DATE}, #{requestTitle,jdbcType=VARCHAR}, #{requestContent,jdbcType=VARCHAR},
|
||||
#{isValid,jdbcType=INTEGER}, #{isAudit,jdbcType=INTEGER}, #{creatorId,jdbcType=INTEGER},
|
||||
#{createTime,jdbcType=DATE}, #{editorId,jdbcType=INTEGER}, #{editTime,jdbcType=DATE},
|
||||
#{auditorId,jdbcType=INTEGER}, #{auditTime,jdbcType=DATE})
|
||||
#{auditorId,jdbcType=INTEGER}, #{auditTime,jdbcType=DATE}, #{taskId,jdbcType=BIGINT})
|
||||
</insert>
|
||||
<!--修改 -->
|
||||
<update id="update" parameterType="com.nis.domain.configuration.RequestInfo">
|
||||
update request_info
|
||||
<set>
|
||||
<if test="requestNumber != null">
|
||||
<if test="requestNumber != null and requestNumber!=''" >
|
||||
request_number = #{requestNumber,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="requestOrg != null">
|
||||
<if test="requestOrg != null and requestOrg!=''">
|
||||
request_org = #{requestOrg,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="requestTime != null">
|
||||
request_time = #{requestTime,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="requestTitle != null">
|
||||
<if test="requestTitle != null and requestTitle!=''">
|
||||
request_title = #{requestTitle,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="requestContent != null">
|
||||
<if test="requestContent != null and requestContent!=''">
|
||||
request_content = #{requestContent,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="isValid != null">
|
||||
@@ -149,6 +182,9 @@
|
||||
<if test="auditTime != null">
|
||||
audit_time = #{auditTime,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="taskId != null">
|
||||
task_id = #{taskId},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
|
||||
@@ -20,13 +20,14 @@
|
||||
id, task_name, task_org, task_time, task_desc, is_valid, is_audit, creator_id, create_time,
|
||||
editor_id, edit_time, auditor_id, audit_time
|
||||
</sql>
|
||||
|
||||
<!-- 查询有效且通过审核 -->
|
||||
<select id="findList" parameterType="com.nis.domain.configuration.TaskInfo" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from task_info
|
||||
from task_info t
|
||||
where is_valid =1 and is_audit =1
|
||||
<if test="id!=null">
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
AND id = #{id,jdbcType=BIGINT}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
@@ -36,6 +37,7 @@
|
||||
r.id AS id,
|
||||
r.task_name AS taskName,
|
||||
r.task_org AS taskOrg,
|
||||
r.task_desc AS taskDesc,
|
||||
r.task_time AS taskTime,
|
||||
r.is_valid AS isValid,
|
||||
r.is_audit AS isAudit,
|
||||
@@ -43,13 +45,13 @@
|
||||
r.create_time AS createTime,
|
||||
u.name AS editorName,
|
||||
r.edit_time AS editTime,
|
||||
e.name AS currentName,
|
||||
e.name AS auditorName,
|
||||
r.audit_time AS auditTime
|
||||
from task_info r
|
||||
left join sys_user s on r.creator_id=s.id
|
||||
left join sys_user u on r.editor_id=u.id
|
||||
left join sys_user e on r.auditor_id=e.id
|
||||
where r.is_valid=1 and r.is_audit !=3
|
||||
where r.is_valid!=-1 and r.is_audit !=3
|
||||
<if test="taskName != null and taskName != ''">
|
||||
AND r.task_name like
|
||||
<if test="dbName == 'mysql'">CONCAT('%',#{taskName}, '%')</if>
|
||||
@@ -61,9 +63,16 @@
|
||||
AND r.task_time between #{beginDate} and #{endDate}
|
||||
</if>
|
||||
<if test="dobeginDate!=null and dobeginDate!='' and doendDate!=null and doendDate!=''">
|
||||
AND (r.create_time between #{dobeginDate} and #{doendDate}) or (r.audit_time between #{dobeginDate} and #{doendDate})
|
||||
AND r.edit_time between #{dobeginDate} and #{doendDate}
|
||||
</if>
|
||||
order by r.task_time desc
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY r.create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
<!-- 根据来函号查询 -->
|
||||
<select id="getTaskInfoByTaskName" parameterType="java.lang.String" resultMap="BaseResultMap">
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
package com.nis.web.dao.specific;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import com.nis.domain.specific.SpecificServiceCfg;
|
||||
import com.nis.web.dao.CrudDao;
|
||||
import com.nis.web.dao.MyBatisDao;
|
||||
|
||||
@MyBatisDao
|
||||
public interface SpecificServiceCfgDao extends CrudDao<SpecificServiceCfg> {
|
||||
|
||||
/**
|
||||
* 根据id查出对象
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
SpecificServiceCfg getBySpecServiceId(Integer specServiceId);
|
||||
/**
|
||||
* 查询所有符合条件顶层分页列表
|
||||
* @param specificServiceCfg
|
||||
*/
|
||||
List<SpecificServiceCfg> findTopPage(SpecificServiceCfg specificServiceCfg);
|
||||
/**
|
||||
* 查询所有符合条件的数据
|
||||
* @param specificServiceCfg
|
||||
* @return
|
||||
*/
|
||||
List<SpecificServiceCfg> findAllSpecificServiceCfg(@Param("specificServiceCfg")SpecificServiceCfg specificServiceCfg,@Param("orderBy")String orderBy);
|
||||
/**
|
||||
* 修改配置信息
|
||||
* @param specificServiceCfg
|
||||
* @param oldId
|
||||
*/
|
||||
void update(@Param("specificServiceCfg")SpecificServiceCfg specificServiceCfg, @Param("oldId")Integer oldId);
|
||||
/**
|
||||
* 根据specServiceId查询所有下级
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
List<SpecificServiceCfg> getChildrenById(Integer specServiceId);
|
||||
|
||||
|
||||
|
||||
}
|
||||
151
src/main/java/com/nis/web/dao/specific/SpecificServiceCfgDao.xml
Normal file
151
src/main/java/com/nis/web/dao/specific/SpecificServiceCfgDao.xml
Normal file
@@ -0,0 +1,151 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.nis.web.dao.specific.SpecificServiceCfgDao" >
|
||||
|
||||
<resultMap id="CFGResultMap" type="com.nis.domain.specific.SpecificServiceCfg" >
|
||||
<id column="spec_service_id" property="specServiceId" jdbcType="INTEGER" />
|
||||
<result column="spec_service_name" property="specServiceName" jdbcType="VARCHAR" />
|
||||
<result column="spec_service_desc" property="specServiceDesc" jdbcType="VARCHAR" />
|
||||
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
|
||||
<result column="op_time" property="opTime" jdbcType="TIMESTAMP" />
|
||||
<result column="is_leaf" property="isLeaf" jdbcType="INTEGER" />
|
||||
<result column="group_id" property="groupId" jdbcType="INTEGER" />
|
||||
<!-- 父id -->
|
||||
<association property="parent" javaType="com.nis.domain.specific.SpecificServiceCfg">
|
||||
<id column="parent_id" property="specServiceId" jdbcType="INTEGER" />
|
||||
</association>
|
||||
</resultMap>
|
||||
|
||||
<sql id="specificServiceCfgColumns">
|
||||
s.spec_service_id AS specServiceId,
|
||||
s.spec_service_name AS specServiceName,
|
||||
s.spec_service_desc AS specServiceDesc,
|
||||
s.is_valid AS isValid,
|
||||
s.op_time AS opTime,
|
||||
s.parent_id AS "parent.specServiceId",
|
||||
s.is_leaf AS isLeaf,
|
||||
s.group_id AS groupId
|
||||
</sql>
|
||||
|
||||
|
||||
<!-- 根据id查出对象 -->
|
||||
<select id="getBySpecServiceId" resultType="com.nis.domain.specific.SpecificServiceCfg" parameterType="java.lang.Integer">
|
||||
select <include refid="specificServiceCfgColumns" />
|
||||
from specific_service_cfg s where s.spec_service_id = #{specServiceId}
|
||||
</select>
|
||||
|
||||
<!-- 查出所有符合条件的顶层数据 -->
|
||||
|
||||
<select id="findTopPage" resultMap="CFGResultMap" parameterType="com.nis.domain.specific.SpecificServiceCfg">
|
||||
SELECT * FROM specific_service_cfg s WHERE s.is_valid=1
|
||||
|
||||
<if test="specServiceId != null">
|
||||
AND s.spec_service_id like '%${specServiceId}%'
|
||||
</if>
|
||||
<if test="specServiceName != null and specServiceName != '' ">
|
||||
AND s.spec_service_name like '%${specServiceName}%'
|
||||
</if>
|
||||
<if test="specServiceDesc != null and specServiceDesc != '' ">
|
||||
AND s.spec_service_desc like '%${specServiceDesc}%'
|
||||
</if>
|
||||
<if test="groupId != null and groupId != '' ">
|
||||
AND group_id like '%${groupId}%'
|
||||
</if>
|
||||
<if test="beginDate != null" >
|
||||
AND s.op_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate != null" >
|
||||
AND s.op_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
AND s.parent_id not in (
|
||||
SELECT s2.spec_service_id FROM specific_service_cfg s2 WHERE s2.is_valid=1
|
||||
<if test="specServiceId != null">
|
||||
AND s2.spec_service_id like '%${specServiceId}%'
|
||||
</if>
|
||||
<if test="specServiceName != null and specServiceName != '' ">
|
||||
AND s2.spec_service_name like '%${specServiceName}%'
|
||||
</if>
|
||||
<if test="specServiceDesc != null and specServiceDesc != '' ">
|
||||
AND s2.spec_service_desc like '%${specServiceDesc}%'
|
||||
</if>
|
||||
<if test="groupId != null and groupId != '' ">
|
||||
AND group_id like '%${groupId}%'
|
||||
</if>
|
||||
<if test="beginDate != null" >
|
||||
AND s2.op_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate != null" >
|
||||
AND s2.op_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
)
|
||||
<choose>
|
||||
<when test="page != null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY s.${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY s.op_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 查询符合条件的所有数据 -->
|
||||
<select id="findAllSpecificServiceCfg" resultMap="CFGResultMap" >
|
||||
SELECT * from specific_service_cfg where is_valid = 1
|
||||
<if test="specificServiceCfg.specServiceId != null">
|
||||
AND spec_service_id like '%${specificServiceCfg.specServiceId}%'
|
||||
</if>
|
||||
<if test="specificServiceCfg.specServiceName != null and specificServiceCfg.specServiceName != '' ">
|
||||
AND spec_service_name like '%${specificServiceCfg.specServiceName}%'
|
||||
</if>
|
||||
<if test="specificServiceCfg.specServiceDesc != null and specificServiceCfg.specServiceDesc != '' ">
|
||||
AND spec_service_desc like '%${specificServiceCfg.specServiceDesc}%'
|
||||
</if>
|
||||
<if test="specificServiceCfg.groupId != null and specificServiceCfg.groupId != '' ">
|
||||
AND group_id like '%${specificServiceCfg.groupId}%'
|
||||
</if>
|
||||
<if test="specificServiceCfg.beginDate != null">
|
||||
AND op_time > #{specificServiceCfg.beginDate}
|
||||
</if>
|
||||
<if test="specificServiceCfg.endDate != null" >
|
||||
AND op_time < #{specificServiceCfg.endDate}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="orderBy != null and orderBy != '' ">
|
||||
ORDER BY ${orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY op_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
</select>
|
||||
|
||||
<!-- 新增 -->
|
||||
<insert id="insert" parameterType="com.nis.domain.specific.SpecificServiceCfg" useGeneratedKeys="true">
|
||||
insert into specific_service_cfg (spec_service_id,spec_service_name,spec_service_desc,is_valid, op_time, parent_id,is_leaf,group_id)
|
||||
values(#{specServiceId},#{specServiceName},#{specServiceDesc},#{isValid},#{opTime},#{parent.specServiceId},#{isLeaf},#{groupId})
|
||||
</insert>
|
||||
|
||||
<!-- 修改 -->
|
||||
<update id="update" parameterType="com.nis.domain.specific.SpecificServiceCfg">
|
||||
UPDATE specific_service_cfg s SET
|
||||
s.spec_service_id = #{specificServiceCfg.specServiceId},
|
||||
s.spec_service_name = #{specificServiceCfg.specServiceName},
|
||||
s.spec_service_desc = #{specificServiceCfg.specServiceDesc},
|
||||
s.is_valid = #{specificServiceCfg.isValid},
|
||||
s.op_time = #{specificServiceCfg.opTime},
|
||||
s.parent_id = #{specificServiceCfg.parent.specServiceId},
|
||||
s.is_leaf = #{specificServiceCfg.isLeaf},
|
||||
s.group_id = #{specificServiceCfg.groupId}
|
||||
WHERE s.spec_service_id = #{oldId}
|
||||
</update>
|
||||
|
||||
<!-- 删除 -->
|
||||
<update id="delete" parameterType="com.nis.domain.specific.SpecificServiceCfg">
|
||||
UPDATE specific_service_cfg s set s.is_valid = #{isValid} where s.spec_service_id = #{specServiceId}
|
||||
</update>
|
||||
<!-- getChildrenById -->
|
||||
<select id="getChildrenById" resultMap="CFGResultMap" parameterType="java.lang.Integer">
|
||||
SELECT * FROM specific_service_cfg s WHERE s.is_valid = 1 and s.parent_id = #{specServiceId}
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -0,0 +1,48 @@
|
||||
package com.nis.web.dao.specific;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.nis.domain.specific.SpecificServiceHostCfg;
|
||||
import com.nis.web.dao.CrudDao;
|
||||
import com.nis.web.dao.MyBatisDao;
|
||||
|
||||
|
||||
@MyBatisDao
|
||||
public interface SpecificServiceHostCfgDao extends CrudDao<SpecificServiceHostCfg> {
|
||||
|
||||
/**
|
||||
* 根据主键查询数据对象
|
||||
* @param hostId
|
||||
* @return
|
||||
*/
|
||||
SpecificServiceHostCfg getByHostId(Integer hostId);
|
||||
|
||||
/**
|
||||
* 查询分页
|
||||
* @param specificServiceHostCfg
|
||||
* @return
|
||||
*/
|
||||
List<SpecificServiceHostCfg> findSpecHostList(SpecificServiceHostCfg specificServiceHostCfg);
|
||||
|
||||
/**
|
||||
* 查出所有
|
||||
* @return
|
||||
*/
|
||||
List<SpecificServiceHostCfg> getAll();
|
||||
|
||||
/**
|
||||
* 删除
|
||||
* @param hostId
|
||||
*/
|
||||
void delete(Integer hostId);
|
||||
|
||||
/**
|
||||
* 根据协议ID查询对象
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
SpecificServiceHostCfg getBySpecServiceId(Integer specServiceId);
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,174 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.nis.web.dao.specific.SpecificServiceHostCfgDao">
|
||||
|
||||
<resultMap id="specificServiceHostCfgResultMap"
|
||||
type="com.nis.domain.specific.SpecificServiceHostCfg">
|
||||
<id column="host_id" property="hostId" jdbcType="INTEGER" />
|
||||
<result column="spec_service_id" property="specServiceId" jdbcType="INTEGER" />
|
||||
<result column="ip_type" property="ipType" jdbcType="INTEGER" />
|
||||
<result column="src_ip" property="srcIp" jdbcType="VARCHAR" />
|
||||
<result column="src_ip_mask" property="srcIpMask" jdbcType="VARCHAR" />
|
||||
<result column="src_port" property="srcPort" jdbcType="VARCHAR" />
|
||||
<result column="src_port_mask" property="srcPortMask" jdbcType="VARCHAR" />
|
||||
<result column="dst_ip" property="dstIp" jdbcType="VARCHAR" />
|
||||
<result column="dst_ip_mask" property="dstIpMask" jdbcType="VARCHAR" />
|
||||
<result column="dst_port" property="dstPort" jdbcType="VARCHAR" />
|
||||
<result column="dst_port_mask" property="dstPortMask" jdbcType="VARCHAR" />
|
||||
<result column="direction" property="direction" jdbcType="INTEGER" />
|
||||
<result column="protocol" property="protocol" jdbcType="INTEGER" />
|
||||
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
|
||||
<result column="is_audit" property="isAudit" jdbcType="INTEGER" />
|
||||
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
|
||||
<result column="edit_time" property="editTime" jdbcType="TIMESTAMP" />
|
||||
<result column="audit_time" property="auditTime" jdbcType="TIMESTAMP" />
|
||||
<!-- 创建人员 -->
|
||||
<association property="creator" javaType="com.nis.domain.SysUser">
|
||||
<id property="id" column="creator_id" />
|
||||
</association>
|
||||
<!-- 修改人员 -->
|
||||
<association property="editor" javaType="com.nis.domain.SysUser">
|
||||
<id property="id" column="editor_id" />
|
||||
</association>
|
||||
<!-- 审核人员 -->
|
||||
<association property="auditor" javaType="com.nis.domain.SysUser">
|
||||
<id property="id" column="auditor_id" />
|
||||
</association>
|
||||
</resultMap>
|
||||
|
||||
<sql id="specificServiceHostCfgColumns">
|
||||
s.host_id AS hostId,
|
||||
s.spec_service_id AS specServiceId,
|
||||
s.ip_type AS ipType,
|
||||
s.src_ip AS srcIp,
|
||||
s.src_ip_mask AS srcIpMask,
|
||||
s.src_port AS srcPort,
|
||||
s.src_port_mask AS srcPortMask,
|
||||
s.dst_ip AS dstIp,
|
||||
s.dst_ip_mask AS dstIpMask,
|
||||
s.dst_port AS dstPort,
|
||||
s.dst_port_mask AS dstPortMask,
|
||||
s.direction AS direction,
|
||||
s.protocol AS protocol,
|
||||
s.is_valid AS isValid,
|
||||
s.is_audit AS isAudit,
|
||||
s.creator_id AS "creator.id",
|
||||
s.create_time AS createTime,
|
||||
s.editor_id AS "editor.id",
|
||||
s.edit_time AS editTime,
|
||||
s.auditor_id AS "auditor.id",
|
||||
s.audit_time AS auditTime
|
||||
</sql>
|
||||
|
||||
|
||||
<!-- 根据id查出对象 -->
|
||||
<select id="getByHostId" resultType="com.nis.domain.specific.SpecificServiceHostCfg"
|
||||
parameterType="java.lang.Integer">
|
||||
select
|
||||
<include refid="specificServiceHostCfgColumns" />
|
||||
from specific_service_host_cfg s where s.host_id = #{hostId}
|
||||
</select>
|
||||
|
||||
<!-- 查询分页 -->
|
||||
<select id="findSpecHostList" resultMap="specificServiceHostCfgResultMap" parameterType="com.nis.domain.specific.SpecificServiceHostCfg">
|
||||
select * from specific_service_host_cfg where is_valid = 1
|
||||
<if test="isAudit !=null" >
|
||||
AND is_audit = #{isAudit}
|
||||
</if>
|
||||
<if test="specServiceId !=null" >
|
||||
AND spec_service_id = #{specServiceId}
|
||||
</if>
|
||||
<if test="ipType !=null" >
|
||||
AND ip_type = #{ipType}
|
||||
</if>
|
||||
<if test="srcIp !=null and srcIp !='' " >
|
||||
AND src_ip = #{srcIp}
|
||||
</if>
|
||||
<if test="dstIp !=null and dstIp !='' " >
|
||||
AND dst_ip = #{dstIp}
|
||||
</if>
|
||||
<if test="protocol !=null" >
|
||||
AND protocol = #{protocol}
|
||||
</if>
|
||||
<if test="direction !=null" >
|
||||
AND direction = #{direction}
|
||||
</if>
|
||||
<if test="beginDate !=null and beginDate !='' " >
|
||||
AND create_time >= #{beginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="endDate !=null and endDate !='' " >
|
||||
AND create_time <= #{endDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editBeginDate !=null and editBeginDate !='' " >
|
||||
AND edit_time >= #{editBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="editEndDate !=null and editEndDate !='' " >
|
||||
AND edit_time <= #{editEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="auditBeginDate !=null and auditBeginDate !='' " >
|
||||
AND audit_time >= #{auditBeginDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<if test="auditEndDate !=null and auditEndDate !='' " >
|
||||
AND audit_time <= #{auditEndDate,jdbcType=TIMESTAMP}
|
||||
</if>
|
||||
<choose>
|
||||
<when test="page !=null and page.orderBy != null and page.orderBy != ''">
|
||||
ORDER BY ${page.orderBy}
|
||||
</when>
|
||||
<otherwise>
|
||||
ORDER BY create_time desc
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</select>
|
||||
|
||||
<!-- 查询所有 -->
|
||||
<select id="getAll" resultMap="specificServiceHostCfgResultMap">
|
||||
select * from specific_service_host_cfg
|
||||
</select>
|
||||
<!-- 根据协议ID查询对象 -->
|
||||
<select id="getBySpecServiceId" resultType="com.nis.domain.specific.SpecificServiceHostCfg" parameterType="java.lang.Integer">
|
||||
select
|
||||
<include refid="specificServiceHostCfgColumns" />
|
||||
from specific_service_host_cfg s where s.spec_service_id = #{specServiceId}
|
||||
</select>
|
||||
|
||||
<!-- 新增 -->
|
||||
<insert id="insert" parameterType="com.nis.domain.specific.SpecificServiceHostCfg">
|
||||
insert into specific_service_host_cfg (spec_service_id,ip_type,src_ip,src_ip_mask,src_port,src_port_mask,dst_ip,dst_ip_mask,dst_port,dst_port_mask,direction,protocol,is_valid,is_audit,creator_id,create_time,editor_id,edit_time,auditor_id,audit_time)
|
||||
values(#{specServiceId},#{ipType},#{srcIp},#{srcIpMask},#{srcPort},#{srcPortMask},#{dstIp},#{dstIpMask},#{dstPort},#{dstPortMask},#{direction},#{protocol},#{isValid},#{isAudit},#{creator.id},#{createTime},#{editor.id},#{editTime},#{auditor.id},#{auditTime})
|
||||
</insert>
|
||||
<!-- 修改 -->
|
||||
<update id="update" parameterType="com.nis.domain.specific.SpecificServiceHostCfg">
|
||||
update specific_service_host_cfg s set
|
||||
s.spec_service_id = #{specServiceId},
|
||||
s.ip_type = #{ipType},
|
||||
s.src_ip = #{srcIp},
|
||||
s.src_ip_mask = #{srcIpMask},
|
||||
s.src_port = #{srcPort},
|
||||
s.src_port_mask = #{srcPortMask},
|
||||
s.dst_ip = #{dstIp},
|
||||
s.dst_ip_mask = #{dstIpMask},
|
||||
s.dst_port = #{dstPort},
|
||||
s.dst_port_mask = #{dstPortMask},
|
||||
s.direction = #{direction},
|
||||
s.protocol = #{protocol},
|
||||
s.is_valid = #{isValid},
|
||||
s.is_audit = #{isAudit},
|
||||
s.creator_id = #{creator.id},
|
||||
s.create_time = #{createTime},
|
||||
s.editor_id = #{editor.id},
|
||||
s.edit_time = #{editTime},
|
||||
s.auditor_id = #{auditor.id},
|
||||
s.audit_time = #{auditTime}
|
||||
where s.host_id = #{hostId}
|
||||
</update>
|
||||
<!-- 删除 -->
|
||||
<update id="delete" parameterType="java.lang.Integer">
|
||||
update specific_service_host_cfg s set
|
||||
s.is_valid = 0
|
||||
where s.host_id = #{hostId}
|
||||
</update>
|
||||
|
||||
|
||||
</mapper>
|
||||
@@ -25,7 +25,7 @@ public class ServiceDictInfoService extends BaseService{
|
||||
private ServiceDictInfoDao serviceDictInfoDao;
|
||||
|
||||
/**
|
||||
* 查询业务字典分页(无条件查询)
|
||||
* 查询业务字典顶层分页
|
||||
* @param page
|
||||
* @param serviceDictInfo
|
||||
* @return
|
||||
@@ -61,11 +61,67 @@ public class ServiceDictInfoService extends BaseService{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
ServiceDictInfo sd = new ServiceDictInfo();
|
||||
sd.setServiceDictId(0);
|
||||
for(ServiceDictInfo se:parentList){
|
||||
se.setParent(sd);
|
||||
}
|
||||
if(tempType!=0){
|
||||
serviceDictInfo.setItemType(tempType);
|
||||
}else{
|
||||
serviceDictInfo.setItemType(null);
|
||||
}
|
||||
page.setList(parentList);
|
||||
return page;
|
||||
}
|
||||
/**
|
||||
* 查询所有数据
|
||||
* @param serviceDictInfo
|
||||
* @param itType
|
||||
* @return
|
||||
*/
|
||||
public List<ServiceDictInfo> findAllServiceDictInfo(ServiceDictInfo serviceDictInfo,Integer[] itType,String orderBy){
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
tempType = serviceDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
serviceDictInfo.setItemType(itType[0]);
|
||||
list = serviceDictInfoDao.findAllServiceDictInfo(serviceDictInfo,orderBy);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
list = serviceDictInfoDao.findAllServiceDictInfo(serviceDictInfo,orderBy);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
serviceDictInfo.setItemType(tempIntegerList.get(0));
|
||||
list = serviceDictInfoDao.findAllServiceDictInfoN(serviceDictInfo,orderBy);
|
||||
}
|
||||
}
|
||||
if(tempType!=0){
|
||||
serviceDictInfo.setItemType(tempType);
|
||||
}else{
|
||||
serviceDictInfo.setItemType(null);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 查询所有有效字典配置
|
||||
* @return
|
||||
@@ -91,178 +147,6 @@ public class ServiceDictInfoService extends BaseService{
|
||||
}
|
||||
return list;
|
||||
}
|
||||
/**
|
||||
* 查询条件查询顶层分页(含条件查询,考虑排序接入可行性)
|
||||
* @param page
|
||||
* @param serviceDictInfo
|
||||
* @param itType
|
||||
* @return
|
||||
*/
|
||||
public Page<ServiceDictInfo> findDictTopSearchList(Page<ServiceDictInfo> page, ServiceDictInfo serviceDictInfo, Integer[] itType) {
|
||||
// 设置分页参数
|
||||
serviceDictInfo.setPage(page);
|
||||
//根据条件查询符合数据
|
||||
List<ServiceDictInfo> allList = Lists.newArrayList();
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
tempType = serviceDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
serviceDictInfo.setItemType(itType[0]);
|
||||
allList = serviceDictInfoDao.findDictTopSearchList(serviceDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
allList = serviceDictInfoDao.findDictTopSearchList(serviceDictInfo);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
serviceDictInfo.setItemType(tempIntegerList.get(0));
|
||||
allList = serviceDictInfoDao.findDictTopSearchListN(serviceDictInfo);
|
||||
}
|
||||
|
||||
}
|
||||
ServiceDictInfo tempSe = new ServiceDictInfo();
|
||||
tempSe.setServiceDictId(0);
|
||||
for(ServiceDictInfo se:allList){
|
||||
se.setParent(tempSe);
|
||||
}
|
||||
page.setList(allList);
|
||||
|
||||
|
||||
/*//根据条件查询符合数据
|
||||
List<ServiceDictInfo> allList = Lists.newArrayList();
|
||||
List<Integer> tempList = Lists.newArrayList();
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
List<ServiceDictInfo> listChild = Lists.newArrayList();
|
||||
List<ServiceDictInfo> listParent = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
Integer total = 0;
|
||||
Integer pageCount = 0;
|
||||
Integer lostCount = 0;
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
tempType = serviceDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
serviceDictInfo.setItemType(itType[0]);
|
||||
allList = serviceDictInfoDao.findDictSearchList(serviceDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
allList = serviceDictInfoDao.findDictSearchList(serviceDictInfo);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
serviceDictInfo.setItemType(tempIntegerList.get(0));
|
||||
allList = serviceDictInfoDao.findDictSearchListN(serviceDictInfo);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//处理数据
|
||||
//page.list中有多少个不是page.list中的顶层(其上级在page.list)
|
||||
ServiceDictInfo tempSe = new ServiceDictInfo();
|
||||
tempSe.setServiceDictId(0);
|
||||
//取出主键优化处理
|
||||
for(ServiceDictInfo se:allList){
|
||||
if(se!=null&&se.getServiceDictId()!=null){
|
||||
tempList.add(se.getServiceDictId());
|
||||
}
|
||||
}
|
||||
|
||||
for(ServiceDictInfo se:allList){
|
||||
if(se!=null&&se.getParent()!=null&&se.getParent().getServiceDictId()!=null){
|
||||
//ServiceDictInfo temp = serviceDictInfoDao.getDictById(se.getParent().getServiceDictId());
|
||||
if(tempList.contains(se.getParent().getServiceDictId())){
|
||||
listChild.add(se);
|
||||
lostCount+=lostCount;
|
||||
}else{
|
||||
se.setParent(tempSe);
|
||||
listParent.add(se);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//确定总页数
|
||||
total = allList.size() - lostCount;
|
||||
pageCount = total%page.getPageSize()==0?total%page.getPageSize():(total%page.getPageSize()+1);
|
||||
if(pageCount==0){
|
||||
pageCount=1;
|
||||
}
|
||||
//取出所有的顶层
|
||||
//获取分页 每页数量pageSize、、当前页数pageNo (排序,,,) 每页第一个(pageNo-1)*pageSize+1 最后一个pageNo*pageSize
|
||||
List<ServiceDictInfo> parentShow = Lists.newArrayList();
|
||||
for(int i=0;i<listParent.size();i++){
|
||||
if(i>=((page.getPageNo()-1)*page.getPageSize())&&i<page.getPageNo()*page.getPageSize()){
|
||||
parentShow.add(listParent.get(i));
|
||||
}
|
||||
}
|
||||
parentShow.addAll(listChild);
|
||||
|
||||
ServiceDictInfo.sortList(list,parentShow,0,true);
|
||||
|
||||
page.setList(list);*/
|
||||
return page;
|
||||
}
|
||||
/**
|
||||
* 条件查询所有数据
|
||||
* @param serviceDictInfo
|
||||
* @param itType
|
||||
* @return
|
||||
*/
|
||||
public List<ServiceDictInfo> findAllDictSearchList(ServiceDictInfo serviceDictInfo,Integer[] itType){
|
||||
List<ServiceDictInfo> list = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(serviceDictInfo.getItemType()!=null){
|
||||
tempType = serviceDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
serviceDictInfo.setItemType(itType[0]);
|
||||
list = serviceDictInfoDao.findAllDictSearchList(serviceDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
list = serviceDictInfoDao.findAllDictSearchList(serviceDictInfo);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
serviceDictInfo.setItemType(tempIntegerList.get(0));
|
||||
list = serviceDictInfoDao.findAllDictSearchListN(serviceDictInfo);
|
||||
}
|
||||
}
|
||||
if(tempType!=0){
|
||||
serviceDictInfo.setItemType(tempType);
|
||||
}else{
|
||||
serviceDictInfo.setItemType(null);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 根据主键查询字典详细信息
|
||||
* @param serviceDictId
|
||||
|
||||
@@ -24,9 +24,8 @@ public class SysDictInfoService extends BaseService{
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 查询顶层分页(无条件查询)
|
||||
* 查询顶层分页(含条件查询,考虑排序接入可行性)
|
||||
* @param page
|
||||
* @param sysDictInfo
|
||||
* @param itType
|
||||
@@ -35,70 +34,22 @@ public class SysDictInfoService extends BaseService{
|
||||
public Page<SysDictInfo> findTopDictList(Page<SysDictInfo> page, SysDictInfo sysDictInfo, Integer[] itType) {
|
||||
// 设置分页参数
|
||||
sysDictInfo.setPage(page);
|
||||
List<SysDictInfo> parentList = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
//预留以后分开用
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
tempType = sysDictInfo.getItemType();
|
||||
}
|
||||
//查出顶层分页查询
|
||||
if(itType.length==1){
|
||||
sysDictInfo.setItemType(itType[0]);
|
||||
parentList = sysDictInfoDao.findTopDictList(sysDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
parentList = sysDictInfoDao.findTopDictList(sysDictInfo);
|
||||
}else{
|
||||
List<Integer> tempList = Lists.newArrayList();
|
||||
tempList.add(1);tempList.add(2);tempList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempList.contains(itType[0])){
|
||||
tempList.remove(itType[0]);
|
||||
}
|
||||
if(tempList.contains(itType[1])){
|
||||
tempList.remove(itType[1]);
|
||||
}
|
||||
sysDictInfo.setItemType(tempList.get(0));
|
||||
parentList = sysDictInfoDao.findTopDictListN(sysDictInfo);
|
||||
}
|
||||
|
||||
}
|
||||
page.setList(parentList);
|
||||
return page;
|
||||
}
|
||||
/**
|
||||
* 查询所有有效字典配置
|
||||
*/
|
||||
public List<SysDictInfo> findAllDictList() {
|
||||
return sysDictInfoDao.findAllDictList(new SysDictInfo());
|
||||
|
||||
}
|
||||
/**
|
||||
* 条件查询所有数据
|
||||
* @param page
|
||||
* @param sysDictInfo
|
||||
* @param intArr
|
||||
* @return
|
||||
*/
|
||||
public List<SysDictInfo> findAllDictSearchList(SysDictInfo sysDictInfo, Integer[] itType) {
|
||||
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
//根据条件查询符合数据
|
||||
List<SysDictInfo> allList = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
tempType = sysDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
sysDictInfo.setItemType(itType[0]);
|
||||
list = sysDictInfoDao.findAllDictSearchList(sysDictInfo);
|
||||
allList = sysDictInfoDao.findTopDictList(sysDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
list = sysDictInfoDao.findAllDictSearchList(sysDictInfo);
|
||||
allList = sysDictInfoDao.findTopDictList(sysDictInfo);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
@@ -106,56 +57,16 @@ public class SysDictInfoService extends BaseService{
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
sysDictInfo.setItemType(tempIntegerList.get(0));
|
||||
list = sysDictInfoDao.findAllDictSearchListN(sysDictInfo);
|
||||
allList = sysDictInfoDao.findTopDictListN(sysDictInfo);
|
||||
}
|
||||
|
||||
}
|
||||
//allList = sysDictInfoDao.findDictTopSearchList(sysDictInfo);
|
||||
if(tempType!=0){
|
||||
sysDictInfo.setItemType(tempType);
|
||||
}else{
|
||||
sysDictInfo.setItemType(null);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
/**
|
||||
* 查询条件查询顶层分页(含条件查询,考虑排序接入可行性)
|
||||
* @param page
|
||||
* @param sysDictInfo
|
||||
* @param itType
|
||||
* @return
|
||||
*/
|
||||
public Page<SysDictInfo> findDictTopSearchList(Page<SysDictInfo> page, SysDictInfo sysDictInfo, Integer[] itType) {
|
||||
// 设置分页参数
|
||||
sysDictInfo.setPage(page);
|
||||
//根据条件查询符合数据
|
||||
List<SysDictInfo> allList = Lists.newArrayList();
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
tempType = sysDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
sysDictInfo.setItemType(itType[0]);
|
||||
allList = sysDictInfoDao.findDictTopSearchList(sysDictInfo);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
allList = sysDictInfoDao.findDictTopSearchList(sysDictInfo);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
//Map<String,String> map = DictUtils.getDictOption("SERVICE_DICT_ITM_TYPE");
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
sysDictInfo.setItemType(tempIntegerList.get(0));
|
||||
allList = sysDictInfoDao.findDictTopSearchListN(sysDictInfo);
|
||||
}
|
||||
|
||||
}
|
||||
allList = sysDictInfoDao.findDictTopSearchList(sysDictInfo);
|
||||
SysDictInfo tempSe = new SysDictInfo();
|
||||
tempSe.setSysDictId(0);
|
||||
for(SysDictInfo se:allList){
|
||||
@@ -167,6 +78,60 @@ public class SysDictInfoService extends BaseService{
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
* @param page
|
||||
* @param sysDictInfo
|
||||
* @param intArr
|
||||
* @return
|
||||
*/
|
||||
public List<SysDictInfo> findAllSysDictInfo(SysDictInfo sysDictInfo, Integer[] itType,String orderBy) {
|
||||
|
||||
List<SysDictInfo> list = Lists.newArrayList();
|
||||
Integer tempType = 0;
|
||||
if(sysDictInfo.getItemType()!=null){
|
||||
tempType = sysDictInfo.getItemType();
|
||||
}
|
||||
if(itType.length==1){
|
||||
sysDictInfo.setItemType(itType[0]);
|
||||
list = sysDictInfoDao.findAllSysDictInfo(sysDictInfo,orderBy);
|
||||
}
|
||||
if(itType.length==2){
|
||||
if(tempType!=0){
|
||||
list = sysDictInfoDao.findAllSysDictInfo(sysDictInfo,orderBy);
|
||||
}else{
|
||||
List<Integer> tempIntegerList = Lists.newArrayList();
|
||||
tempIntegerList.add(1);tempIntegerList.add(2);tempIntegerList.add(3);
|
||||
if(tempIntegerList.contains(itType[0])){
|
||||
tempIntegerList.remove(itType[0]);
|
||||
}
|
||||
if(tempIntegerList.contains(itType[1])){
|
||||
tempIntegerList.remove(itType[1]);
|
||||
}
|
||||
sysDictInfo.setItemType(tempIntegerList.get(0));
|
||||
list = sysDictInfoDao.findAllSysDictInfoN(sysDictInfo,orderBy);
|
||||
}
|
||||
}
|
||||
if(tempType!=0){
|
||||
sysDictInfo.setItemType(tempType);
|
||||
}else{
|
||||
sysDictInfo.setItemType(null);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 查询所有有效字典配置
|
||||
*/
|
||||
public List<SysDictInfo> findAllDictList() {
|
||||
return sysDictInfoDao.findAllDictList(new SysDictInfo());
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 根据主键查询生效范围字典详细信息
|
||||
* @param sysDictId
|
||||
|
||||
@@ -36,12 +36,13 @@ public class TaskInfoService extends BaseService{
|
||||
public void saveOrUpdate(TaskInfo taskInfo) {
|
||||
if (StringUtil.isEmpty(taskInfo.getId())) {
|
||||
//设置默认参数值
|
||||
taskInfo.setIsValid(1);//有效
|
||||
taskInfo.setIsValid(0);//无效
|
||||
taskInfo.setIsAudit(0);//未审核
|
||||
taskInfo.setCreatorId((UserUtils.getUser().getId()).intValue());//创建人员
|
||||
taskInfo.setCreateTime(new Date());//创建时间
|
||||
taskInfoDao.insert(taskInfo);
|
||||
}else{
|
||||
taskInfo.setIsAudit(0);//修改后状态为未审核
|
||||
taskInfo.setEditorId((UserUtils.getUser().getId()).intValue());//修改人员
|
||||
taskInfo.setEditTime(new Date());//修改时间
|
||||
taskInfoDao.update(taskInfo);
|
||||
@@ -63,6 +64,7 @@ public class TaskInfoService extends BaseService{
|
||||
for (int i = 0; i < exId.length; i++) {
|
||||
taskInfo.setId(Long.valueOf(exId[i]));
|
||||
taskInfo.setIsAudit(1);//审核通过
|
||||
taskInfo.setIsValid(1);//审核通过
|
||||
taskInfo.setAuditTime(new Date());
|
||||
taskInfo.setAuditorId((UserUtils.getUser().getId()).intValue());//审核人员
|
||||
taskInfoDao.update(taskInfo);
|
||||
@@ -85,6 +87,7 @@ public class TaskInfoService extends BaseService{
|
||||
for (int i = 0; i < cancelId.length; i++) {
|
||||
taskInfo.setId(Long.valueOf(cancelId[i]));
|
||||
taskInfo.setIsAudit(3);//取消审核通过
|
||||
taskInfo.setIsValid(0);
|
||||
taskInfo.setAuditTime(new Date());
|
||||
taskInfo.setAuditorId((UserUtils.getUser().getId()).intValue());//审核人员
|
||||
taskInfoDao.update(taskInfo);
|
||||
|
||||
@@ -40,12 +40,13 @@ public class RequestInfoService extends BaseService{
|
||||
public void saveOrUpdate(RequestInfo requestInfo) {
|
||||
if (StringUtil.isEmpty(requestInfo.getId())) {
|
||||
//设置默认参数值
|
||||
requestInfo.setIsValid(1);//有效
|
||||
requestInfo.setIsValid(0);//无效
|
||||
requestInfo.setIsAudit(0);//未审核
|
||||
requestInfo.setCreatorId((UserUtils.getUser().getId()).intValue());//创建人员
|
||||
requestInfo.setCreateTime(new Date());//创建时间
|
||||
requestInfoDao.insert(requestInfo);
|
||||
}else{
|
||||
requestInfo.setIsAudit(0);//修改后状态为未审核
|
||||
requestInfo.setEditorId((UserUtils.getUser().getId()).intValue());//修改人员
|
||||
requestInfo.setEditTime(new Date());//修改时间
|
||||
requestInfoDao.update(requestInfo);
|
||||
@@ -67,6 +68,7 @@ public class RequestInfoService extends BaseService{
|
||||
for (int i = 0; i < exId.length; i++) {
|
||||
requestInfo.setId(Long.valueOf(exId[i]));
|
||||
requestInfo.setIsAudit(1);//审核通过
|
||||
requestInfo.setIsValid(1);//审核通过有效
|
||||
requestInfo.setAuditTime(new Date());
|
||||
requestInfo.setAuditorId((UserUtils.getUser().getId()).intValue());//审核人员
|
||||
requestInfoDao.update(requestInfo);
|
||||
@@ -89,6 +91,7 @@ public class RequestInfoService extends BaseService{
|
||||
for (int i = 0; i < cancelId.length; i++) {
|
||||
requestInfo.setId(Long.valueOf(cancelId[i]));
|
||||
requestInfo.setIsAudit(3);//取消审核通过
|
||||
requestInfo.setIsValid(0);//取消审核通过无效
|
||||
requestInfo.setAuditTime(new Date());
|
||||
requestInfo.setAuditorId((UserUtils.getUser().getId()).intValue());//审核人员
|
||||
requestInfoDao.update(requestInfo);
|
||||
|
||||
@@ -0,0 +1,122 @@
|
||||
package com.nis.web.service.specific;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.beust.jcommander.internal.Lists;
|
||||
import com.nis.domain.Page;
|
||||
import com.nis.domain.specific.SpecificServiceCfg;
|
||||
import com.nis.util.StringUtil;
|
||||
import com.nis.web.dao.specific.SpecificServiceCfgDao;
|
||||
import com.nis.web.service.BaseService;
|
||||
|
||||
@Service
|
||||
public class SpecificServiceCfgService extends BaseService{
|
||||
|
||||
@Autowired
|
||||
private SpecificServiceCfgDao specificServiceCfgDao;
|
||||
|
||||
/**
|
||||
* 根据id查询对象
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
public SpecificServiceCfg getBySpecServiceId(Integer specServiceId) {
|
||||
return specificServiceCfgDao.getBySpecServiceId(specServiceId);
|
||||
}
|
||||
/**
|
||||
* 查询所有符合条件的顶层分页
|
||||
* @param page
|
||||
* @param specificServiceCfg
|
||||
* @return
|
||||
*/
|
||||
public Page<SpecificServiceCfg> findTopPage(Page<SpecificServiceCfg> page, SpecificServiceCfg specificServiceCfg){
|
||||
// 设置分页参数
|
||||
specificServiceCfg.setPage(page);
|
||||
// 执行分页查询
|
||||
List<SpecificServiceCfg> list = Lists.newArrayList();
|
||||
list = specificServiceCfgDao.findTopPage(specificServiceCfg);
|
||||
SpecificServiceCfg ss = new SpecificServiceCfg();
|
||||
ss.setSpecServiceId(0);
|
||||
for(SpecificServiceCfg ssc:list){
|
||||
ssc.setParent(ss);
|
||||
}
|
||||
page.setList(list);
|
||||
return page;
|
||||
}
|
||||
/**
|
||||
* 查询所有符合条件的数据
|
||||
* @param specificServiceCfg
|
||||
* @return
|
||||
*/
|
||||
public List<SpecificServiceCfg> findAllSpecificServiceCfg(SpecificServiceCfg specificServiceCfg, String orderBy) {
|
||||
return specificServiceCfgDao.findAllSpecificServiceCfg(specificServiceCfg,orderBy);
|
||||
}
|
||||
/**
|
||||
* 保存或修改
|
||||
* @param specificServiceCfg
|
||||
*/
|
||||
public void saveOrUpdate(SpecificServiceCfg specificServiceCfg, Integer oldId) {
|
||||
if(specificServiceCfg.getGroupId()==null){
|
||||
specificServiceCfg.setGroupId(0);
|
||||
}
|
||||
if(oldId==null){//新增
|
||||
specificServiceCfg.setIsValid(1);
|
||||
specificServiceCfg.setOpTime(new Date());
|
||||
specificServiceCfgDao.insert(specificServiceCfg);
|
||||
}else{//修改
|
||||
specificServiceCfg.setOpTime(new Date());
|
||||
//修改id则将其子类的parent_id一并修改
|
||||
if(oldId!=specificServiceCfg.getSpecServiceId()){
|
||||
//找出所有子类
|
||||
List<SpecificServiceCfg> list = specificServiceCfgDao.getChildrenById(oldId);
|
||||
SpecificServiceCfg se =new SpecificServiceCfg();
|
||||
se.setSpecServiceId(specificServiceCfg.getSpecServiceId());
|
||||
for(SpecificServiceCfg ss:list){
|
||||
if(ss!=null){
|
||||
ss.setParent(se);
|
||||
specificServiceCfgDao.update(ss,ss.getSpecServiceId());
|
||||
}
|
||||
}
|
||||
}
|
||||
specificServiceCfgDao.update(specificServiceCfg,oldId);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 删除
|
||||
* @param specificServiceCfg
|
||||
*/
|
||||
public void delete(String mulitId) {
|
||||
String[] ids = mulitId.split(",");
|
||||
for(String id:ids){
|
||||
if (!id.equals("")) {
|
||||
SpecificServiceCfg specificServiceCfg = specificServiceCfgDao.getBySpecServiceId(Integer.valueOf(id));
|
||||
List<SpecificServiceCfg> list = Lists.newArrayList();
|
||||
//找出所有下级
|
||||
if(specificServiceCfg!=null){
|
||||
SpecificServiceCfg.sortList(list, specificServiceCfgDao.findAllSpecificServiceCfg(new SpecificServiceCfg(),""), specificServiceCfg.getSpecServiceId(), true);
|
||||
list.add(specificServiceCfg);
|
||||
for(SpecificServiceCfg ss:list){
|
||||
ss.setIsValid(0);
|
||||
specificServiceCfgDao.delete(ss);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据specServiceId查询所有下级
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
public List<SpecificServiceCfg> getChildrenById(Integer specServiceId) {
|
||||
return specificServiceCfgDao.getChildrenById(specServiceId);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,110 @@
|
||||
package com.nis.web.service.specific;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import com.nis.domain.Page;
|
||||
import com.nis.domain.SysUser;
|
||||
import com.nis.domain.specific.SpecificServiceHostCfg;
|
||||
import com.nis.web.dao.specific.SpecificServiceHostCfgDao;
|
||||
import com.nis.web.security.UserUtils;
|
||||
import com.nis.web.service.BaseService;
|
||||
|
||||
@Service
|
||||
public class SpecificServiceHostCfgService extends BaseService{
|
||||
|
||||
@Autowired
|
||||
private SpecificServiceHostCfgDao specificServiceHostCfgDao;
|
||||
|
||||
/**
|
||||
* 根据主键查询数据对象
|
||||
* @param hostId
|
||||
* @return
|
||||
*/
|
||||
public SpecificServiceHostCfg getDictByHostId(Integer hostId) {
|
||||
return specificServiceHostCfgDao.getByHostId(hostId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查出分页
|
||||
* @param page
|
||||
* @param specificServiceHostCfg
|
||||
* @return
|
||||
*/
|
||||
public Page<SpecificServiceHostCfg> findSpecHostList(Page<SpecificServiceHostCfg> page,
|
||||
SpecificServiceHostCfg specificServiceHostCfg) {
|
||||
specificServiceHostCfg.setPage(page);
|
||||
page.setList(specificServiceHostCfgDao.findSpecHostList(specificServiceHostCfg));
|
||||
return page;
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增或修改
|
||||
* @param specificServiceHostCfg
|
||||
*/
|
||||
public void saveOrUpdate(SpecificServiceHostCfg specificServiceHostCfg) {
|
||||
SysUser user = UserUtils.getUser();
|
||||
Date date = new Date();
|
||||
if(specificServiceHostCfg.getHostId()==null){//新增
|
||||
specificServiceHostCfg.setIsValid(1);
|
||||
specificServiceHostCfg.setCreator(user);
|
||||
specificServiceHostCfg.setCreateTime(date);
|
||||
specificServiceHostCfg.setEditor(user);
|
||||
specificServiceHostCfg.setEditTime(date);
|
||||
specificServiceHostCfg.setAuditor(user);
|
||||
specificServiceHostCfg.setAuditTime(date);
|
||||
specificServiceHostCfgDao.insert(specificServiceHostCfg);
|
||||
}else{//修改
|
||||
//是否进行了审核操作
|
||||
//SpecificServiceHostCfg ssh = specificServiceHostCfgDao.getByHostId(specificServiceHostCfg.getHostId());
|
||||
/*if(ssh.getIsAudit()!=specificServiceHostCfg.getIsAudit()){
|
||||
specificServiceHostCfg.setAuditor(user);
|
||||
specificServiceHostCfg.setAuditTime(date);
|
||||
}*/
|
||||
specificServiceHostCfg.setEditor(user);
|
||||
specificServiceHostCfg.setEditTime(date);
|
||||
specificServiceHostCfg.setAuditor(user);
|
||||
specificServiceHostCfg.setAuditTime(date);
|
||||
specificServiceHostCfgDao.update(specificServiceHostCfg);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 查出所有
|
||||
* @return
|
||||
*/
|
||||
public List<SpecificServiceHostCfg> getAll() {
|
||||
|
||||
return specificServiceHostCfgDao.getAll();
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除
|
||||
* @param mulitId
|
||||
*/
|
||||
public void delete(String mulitId) {
|
||||
String[] ids = mulitId.split(",");
|
||||
for(String hostId:ids){
|
||||
if (!StringUtils.isEmpty(hostId)) {
|
||||
specificServiceHostCfgDao.delete(Integer.valueOf(hostId));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据协议ID查询对象
|
||||
* @param specServiceId
|
||||
* @return
|
||||
*/
|
||||
public SpecificServiceHostCfg getBySpecServiceId(Integer specServiceId) {
|
||||
|
||||
return specificServiceHostCfgDao.getBySpecServiceId(specServiceId);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -11,7 +11,7 @@ officeManage=office management
|
||||
userManage=user management
|
||||
notify=my notify
|
||||
help=help
|
||||
home=home
|
||||
home=Home
|
||||
panel=my panel
|
||||
userInfo=personal information
|
||||
updatePwd=update password
|
||||
@@ -95,6 +95,7 @@ log_search=log search
|
||||
sysService_manage=system service manage
|
||||
service_manage=service type manage
|
||||
system_service_manage=system service type manage
|
||||
specific_service_cfg=specific service cfg
|
||||
#============menu end======================
|
||||
|
||||
#============yewu begin======================
|
||||
@@ -172,6 +173,12 @@ has_approved=It has been approved and can not be operated on !
|
||||
hasnot_approved=It has not been approved and can not be operated on !
|
||||
check_one=choose one please !
|
||||
one_more=please choose at least one !
|
||||
custom_columns=custom columns
|
||||
maxlength_64=The maxlength is 64\uff01
|
||||
maxlength_128=The maxlength is 128\uff01
|
||||
maxlength_256=The maxlength is 256\uff01
|
||||
maxlength_512=The maxlength is 512\uff01
|
||||
maxlength_4000=The maxlength is 4000\uff01
|
||||
#==========message end=====================
|
||||
|
||||
#==========yewuliexingguanli begin=====================
|
||||
|
||||
@@ -11,7 +11,7 @@ officeManage=office management
|
||||
userManage=user management
|
||||
notify=my notify
|
||||
help=help
|
||||
home=home
|
||||
home=Home
|
||||
panel=my panel
|
||||
userInfo=personal information
|
||||
updatePwd=update password
|
||||
@@ -95,6 +95,7 @@ log_search=log search
|
||||
sysService_manage=system service manage
|
||||
service_manage=service type manage
|
||||
system_service_manage=system service type manage
|
||||
specific_service_cfg=specific service cfg
|
||||
#============menu end======================
|
||||
|
||||
#============yewu begin======================
|
||||
|
||||
@@ -11,7 +11,7 @@ officeManage=\u673a\u6784\u7ba1\u7406
|
||||
userManage=\u7528\u6237\u7ba1\u7406
|
||||
notify=\u6211\u7684\u540c\u5fd7
|
||||
help=\u5173\u4e8e\u5e2e\u52a9
|
||||
home=\u5b98\u65b9\u9996\u9875
|
||||
home=\u9996\u9875
|
||||
panel=\u6211\u7684\u9762\u677f
|
||||
userInfo=\u4e2a\u4eba\u4fe1\u606f
|
||||
updatePwd=\u4fee\u6539\u5bc6\u7801
|
||||
@@ -95,6 +95,7 @@ text_monitor=\u6587\u672c\u5e38\u89c4\u76d1\u6d4b
|
||||
sysService_manage=\u7cfb\u7edf\u4e1a\u52a1\u7ba1\u7406
|
||||
service_manage=\u4e1a\u52a1\u7c7b\u578b\u7ba1\u7406
|
||||
system_service_manage=\u7cfb\u7edf\u4e1a\u52a1\u7c7b\u578b\u7ba1\u7406
|
||||
specific_service_cfg=\u7279\u5b9a\u670d\u52a1\u7ba1\u7406
|
||||
#==========menu end=====================
|
||||
|
||||
#==========yewu zidian begin=====================
|
||||
@@ -106,7 +107,7 @@ desc=\u63cf\u8ff0\u4fe1\u606f
|
||||
parent_id=\u7236ID
|
||||
is_leaf=\u662f\u5426\u53f6\u5b50\u8282\u70b9
|
||||
is_valid=\u6709\u6548\u6807\u5fd7
|
||||
create_time=\u914d\u7f6e\u65f6\u95f4
|
||||
create_time=\u521b\u5efa\u65f6\u95f4
|
||||
edit_time=\u4fee\u6539\u65f6\u95f4
|
||||
superior_config=\u4e0a\u7ea7\u914d\u7f6e
|
||||
config_content=\u914d\u7f6e\u5185\u5bb9
|
||||
@@ -171,6 +172,12 @@ has_approved=\u5df2\u7ecf\u901a\u8fc7\u5ba1\u6838\uff0c\u65e0\u6cd5\u8fdb\u884c\
|
||||
hasnot_approved=\u672a\u901a\u8fc7\u5ba1\u6838\uff0c\u65e0\u6cd5\u8fdb\u884c\u8be5\u64cd\u4f5c\uff01
|
||||
check_one=\u8bf7\u9009\u62e9\u4e00\u6761\u6570\u636e\uff01
|
||||
one_more=\u8bf7\u81f3\u5c11\u9009\u62e9\u4e00\u6761\u6570\u636e!
|
||||
custom_columns=\u81ea\u5b9a\u4e49\u5217\u5b57\u6bb5
|
||||
maxlength_64=\u8bf7\u8f93\u5165\u4e00\u4e2a\u957f\u5ea6\u6700\u591a\u662f 64\u7684\u5b57\u7b26\u4e32\uff01
|
||||
maxlength_128=\u8bf7\u8f93\u5165\u4e00\u4e2a\u957f\u5ea6\u6700\u591a\u662f 128\u7684\u5b57\u7b26\u4e32\uff01
|
||||
maxlength_256=\u8bf7\u8f93\u5165\u4e00\u4e2a\u957f\u5ea6\u6700\u591a\u662f256\u7684\u5b57\u7b26\u4e32\uff01
|
||||
maxlength_512=\u8bf7\u8f93\u5165\u4e00\u4e2a\u957f\u5ea6\u6700\u591a\u662f512\u7684\u5b57\u7b26\u4e32\uff01
|
||||
maxlength_4000=\u8bf7\u8f93\u5165\u4e00\u4e2a\u957f\u5ea6\u6700\u591a\u662f4000\u7684\u5b57\u7b26\u4e32\uff01
|
||||
#==========message end=====================
|
||||
|
||||
#==========yewuliexingguanli begin=====================
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<div for="cfgDesc"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%--
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="match_area"/></label>
|
||||
@@ -20,9 +20,7 @@
|
||||
</div>
|
||||
<div for="district"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div> --%>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="key_word"/></label>
|
||||
@@ -32,42 +30,6 @@
|
||||
<div for="keywords"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%-- <div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3">管控类型</label>
|
||||
<div class="col-md-6">
|
||||
<select name="action" class="selectpicker select2 form-control" readonly="readonly">
|
||||
<option value="1" <c:if test="${_cfg.action==1}">selected</c:if><c:if test="${_cfg.action!=1}">disabled="disabled"</c:if> >阻断</option>
|
||||
<option value="2" <c:if test="${_cfg.action==2}">selected</c:if><c:if test="${_cfg.action!=2}">disabled="disabled"</c:if> >监测</option>
|
||||
<option value="5" <c:if test="${_cfg.action==5}">selected</c:if><c:if test="${_cfg.action!=5}">disabled="disabled"</c:if> >封堵白名单</option>
|
||||
<option value="6" <c:if test="${_cfg.action==6}">selected</c:if><c:if test="${_cfg.action!=6}">disabled="disabled"</c:if> >监测白名单</option>
|
||||
<option value="7" <c:if test="${_cfg.action==7}">selected</c:if><c:if test="${_cfg.action!=7}">disabled="disabled"</c:if> >封堵监测都白名单</option>
|
||||
<option value="8" <c:if test="${_cfg.action==8}">selected</c:if><c:if test="${_cfg.action!=8}">disabled="disabled"</c:if> >灰名单</option>
|
||||
</select>
|
||||
<input class="form-control" type="hidden" name="action" value="${_cfg.action}">
|
||||
</div>
|
||||
</div>
|
||||
</div> --%>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_area_block"/></label>
|
||||
<div class="col-md-6">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="1"
|
||||
<c:if test="${_cfg.isAreaEffective==1}">checked</c:if>
|
||||
><spring:message code="yes"/>
|
||||
</label>
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="0"
|
||||
<c:if test="${_cfg.isAreaEffective==0}">checked</c:if>
|
||||
><spring:message code="no"/>
|
||||
</label>
|
||||
<%-- <input class="form-control" type="text" name="isAreaEffective" value="${_cfg.isAreaEffective}"> --%>
|
||||
</div>
|
||||
<div for="isAreaEffective"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
@@ -116,6 +78,27 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_area_block"/></label>
|
||||
<div class="col-md-6">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="1"
|
||||
<c:if test="${_cfg.isAreaEffective==1}">checked</c:if>
|
||||
><spring:message code="yes"/>
|
||||
</label>
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="0"
|
||||
<c:if test="${_cfg.isAreaEffective==0}">checked</c:if>
|
||||
><spring:message code="no"/>
|
||||
</label>
|
||||
<%-- <input class="form-control" type="text" name="isAreaEffective" value="${_cfg.isAreaEffective}"> --%>
|
||||
</div>
|
||||
<div for="isAreaEffective"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="area_effect_id"></spring:message></label>
|
||||
|
||||
@@ -105,16 +105,22 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
<input type="hidden" name="protocol" value="0">
|
||||
<input type="hidden" name="direction" value="0">
|
||||
<input type="hidden" name="isAreaEffective" value="0">
|
||||
</c:when>
|
||||
<c:when test="${action==8}">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="direction"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="direction" class="selectpicker show-tick form-control" title=<spring:message code="select"/>>
|
||||
<option value="0" <c:if test="${_cfg.direction==0}">selected</c:if>>0</option>
|
||||
<option value="1" <c:if test="${_cfg.direction==1}">selected</c:if>>1</option>
|
||||
<option value="0" <c:if test="${_cfg.direction==0}">selected</c:if>><spring:message code="twoway"/></option>
|
||||
<option value="1" <c:if test="${_cfg.direction==1}">selected</c:if>><spring:message code="oneway"/></option>
|
||||
</select>
|
||||
<%-- <input class="form-control" type="text" name="direction" value="${_cfg.direction}"> --%>
|
||||
</div>
|
||||
<div for="direction"></div>
|
||||
</div>
|
||||
@@ -133,34 +139,40 @@
|
||||
<div for="protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<%-- <div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3">协议ID</label>
|
||||
<div class="col-md-6">
|
||||
<input class="form-control" type="text" name="protocolId" value="${_cfg.protocolId}" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<input type="hidden" name="isAreaEffective" value="0">
|
||||
<input type="hidden" name="areaEffectiveIds" value="">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3">管控类型</div>
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="protocol"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="action" class="selectpicker select2 form-control" readonly="readonly">
|
||||
<option value="1" <c:if test="${_cfg.action==1}">selected</c:if><c:if test="${_cfg.action!=1}">disabled="disabled"</c:if> >阻断</option>
|
||||
<option value="2" <c:if test="${_cfg.action==2}">selected</c:if><c:if test="${_cfg.action!=2}">disabled="disabled"</c:if> >监测</option>
|
||||
<option value="5" <c:if test="${_cfg.action==5}">selected</c:if><c:if test="${_cfg.action!=5}">disabled="disabled"</c:if> >封堵白名单</option>
|
||||
<option value="6" <c:if test="${_cfg.action==6}">selected</c:if><c:if test="${_cfg.action!=6}">disabled="disabled"</c:if> >监测白名单</option>
|
||||
<option value="7" <c:if test="${_cfg.action==7}">selected</c:if><c:if test="${_cfg.action!=7}">disabled="disabled"</c:if> >封堵监测都白名单</option>
|
||||
<option value="8" <c:if test="${_cfg.action==8}">selected</c:if><c:if test="${_cfg.action!=8}">disabled="disabled"</c:if> >灰名单</option>
|
||||
<select name="protocol" class="selectpicker show-tick form-control" title=<spring:message code="select"/>>
|
||||
<option value="6" <c:if test="${_cfg.protocol==6}">selected</c:if>>TCP</option>
|
||||
<option value="17" <c:if test="${_cfg.protocol==17}">selected</c:if>>UDP</option>
|
||||
<option value="0" <c:if test="${_cfg.protocol==0}">selected</c:if>><spring:message code="arbitrary"/></option>
|
||||
</select>
|
||||
<input class="form-control" type="hidden" name="action" value="${_cfg.action}">
|
||||
<%-- <input class="form-control" type="text" name="protocol" value="${_cfg.protocol}"> --%>
|
||||
</div>
|
||||
<div for="protocol"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="direction"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="direction" class="selectpicker show-tick form-control" title=<spring:message code="select"/>>
|
||||
<option value="0" <c:if test="${_cfg.direction==0}">selected</c:if>><spring:message code="twoway"/></option>
|
||||
<option value="1" <c:if test="${_cfg.direction==1}">selected</c:if>><spring:message code="oneway"/></option>
|
||||
</select>
|
||||
</div>
|
||||
<div for="direction"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --%>
|
||||
<div class="row">
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_area_block"/></label>
|
||||
@@ -189,5 +201,7 @@
|
||||
<div for="areaEffectiveIds"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<!--/row-->
|
||||
@@ -21,45 +21,15 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="block_type"/></label>
|
||||
<div class="col-md-6">
|
||||
<select name="action" class="selectpicker select2 form-control" readonly="readonly">
|
||||
<option value="1" <c:if test="${_cfg.action==1}">selected</c:if><c:if test="${_cfg.action!=1}">disabled="disabled"</c:if> ><spring:message code="block"/></option>
|
||||
<option value="2" <c:if test="${_cfg.action==2}">selected</c:if><c:if test="${_cfg.action!=2}">disabled="disabled"</c:if> ><spring:message code="monitor"/></option>
|
||||
<option value="5" <c:if test="${_cfg.action==5}">selected</c:if><c:if test="${_cfg.action!=5}">disabled="disabled"</c:if> ><spring:message code="block_white_list"/></option>
|
||||
<option value="6" <c:if test="${_cfg.action==6}">selected</c:if><c:if test="${_cfg.action!=6}">disabled="disabled"</c:if> ><spring:message code="monitor_white_list"/></option>
|
||||
<option value="7" <c:if test="${_cfg.action==7}">selected</c:if><c:if test="${_cfg.action!=7}">disabled="disabled"</c:if> ><spring:message code="block_monitor_white_list"/></option>
|
||||
<option value="8" <c:if test="${_cfg.action==8}">selected</c:if><c:if test="${_cfg.action!=8}">disabled="disabled"</c:if> ><spring:message code="grey_list"/></option>
|
||||
</select>
|
||||
<%-- <input class="form-control" type="hidden" name="action" value="${_cfg.action}"> --%>
|
||||
</div>
|
||||
<div for="action"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_area_block"/></label>
|
||||
<div class="col-md-6">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="1"
|
||||
<c:if test="${_cfg.isAreaEffective==1}">checked</c:if>
|
||||
><spring:message code="yes"/>
|
||||
</label>
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="0"
|
||||
<c:if test="${_cfg.isAreaEffective==0}">checked</c:if>
|
||||
><spring:message code="no"/>
|
||||
</label>
|
||||
<%-- <input class="form-control" type="text" name="isAreaEffective" value="${_cfg.isAreaEffective}"> --%>
|
||||
</div>
|
||||
<div for="isAreaEffective"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<c:choose>
|
||||
<c:when test="${action ==5}">
|
||||
<input type="hidden" name="isAreaEffective" value="0">
|
||||
<input type="hidden" name="exprType" value="0">
|
||||
<input type="hidden" name="matchMethod" value="0">
|
||||
<input type="hidden" name="isHexbin" value="0">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="expression_type"/></label>
|
||||
@@ -92,8 +62,8 @@
|
||||
<div for="matchMethod"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_hexbinary"/></label>
|
||||
@@ -106,8 +76,28 @@
|
||||
</div>
|
||||
<div for="isHexbin"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3"><font color="red">*</font><spring:message code="whether_area_block"/></label>
|
||||
<div class="col-md-6">
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="1"
|
||||
<c:if test="${_cfg.isAreaEffective==1}">checked</c:if>
|
||||
><spring:message code="yes"/>
|
||||
</label>
|
||||
<label class="radio-inline">
|
||||
<input type="radio" name="isAreaEffective" value="0"
|
||||
<c:if test="${_cfg.isAreaEffective==0}">checked</c:if>
|
||||
><spring:message code="no"/>
|
||||
</label>
|
||||
<%-- <input class="form-control" type="text" name="isAreaEffective" value="${_cfg.isAreaEffective}"> --%>
|
||||
</div>
|
||||
<div for="isAreaEffective"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3"><spring:message code="area_effect_id"></spring:message></label>
|
||||
@@ -117,5 +107,7 @@
|
||||
<div for="areaEffectiveIds"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<!--/row-->
|
||||
@@ -1,3 +1,4 @@
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
@@ -47,6 +48,10 @@
|
||||
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/jquery-jbox/2.3/jquery.jBox-2.3.src.js" type="text/javascript"></script>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
|
||||
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-typeahead/bootstrap3-typeahead.min.js" type="text/javascript"></script>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/unicodes.js" type="text/javascript"></script>
|
||||
|
||||
<!-- END CORE PLUGINS -->
|
||||
|
||||
|
||||
@@ -62,4 +67,17 @@
|
||||
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
|
||||
@@ -7,16 +7,17 @@
|
||||
<c:forEach items="${fns:getLeftMenuTreeList()}" var="menu" varStatus="idxStatus">
|
||||
|
||||
<ul id="menu_${menu.id }" class="hide accordion page-sidebar-menu page-header-fixed page-sidebar-menu-light"
|
||||
data-keep-expanded="false" data-auto-scroll="true" data-slide-speed="200">
|
||||
data-keep-expanded="false" data-auto-scroll="true" data-slide-speed="200"
|
||||
menu-id="${menu.id }" menu-name="<spring:message code="${menu.code}"></spring:message>" >
|
||||
|
||||
<c:if test="${not empty menu.children }">
|
||||
<c:forEach items="${menu.children}" var="secondMenu" varStatus="secondStatus">
|
||||
|
||||
<li class="nav-item <c:if test="${secondStatus.index==0 }"> active open</c:if>">
|
||||
<li class="nav-item" id="menu_${secondMenu.id }" menu-id="${secondMenu.id }" menu-name="<spring:message code="${secondMenu.code}"></spring:message>" >
|
||||
|
||||
<a class="nav-link nav-toggle"
|
||||
<c:if test="${secondMenu.href != null && secondMenu.href != ''}" var="secondHref">
|
||||
href="${ctx}/${secondMenu.href }" target="mainFrame" >
|
||||
href="javascript:;" onclick="page_turn('${secondMenu.id }','1','','${ctx}/${secondMenu.href }',this)" target="mainFrame" >
|
||||
</c:if>
|
||||
<c:if test="${!secondHref }">
|
||||
href="javascript:;" class="nav-link nav-toggle">
|
||||
@@ -26,7 +27,7 @@
|
||||
<span class="title">
|
||||
<%-- ${secondMenu.name } --%> <spring:message code="${secondMenu.code}"></spring:message></span>
|
||||
<c:if test="${not empty secondMenu.children }" var="secondClid">
|
||||
<span class="arrow open"></span>
|
||||
<span class="arrow "></span>
|
||||
</c:if>
|
||||
</a>
|
||||
|
||||
@@ -37,11 +38,12 @@
|
||||
<c:forEach items="${secondMenu.children}" var="thirdMenu" varStatus="thirdStatus">
|
||||
|
||||
|
||||
<li class="nav-item <c:if test="${not empty thirdMenu.children && thirdStatus.index==0}">active open</c:if>">
|
||||
<li class="nav-item" id="menu_${thirdMenu.id }" menu-id="${thirdMenu.id }" menu-name="<spring:message code="${thirdMenu.code}"></spring:message>">
|
||||
|
||||
<a class="nav-link nav-toggle"
|
||||
<c:if test="${thirdMenu.href != null && thirdMenu.href != ''}" var="thirdHref">
|
||||
href="${ctx}/${thirdMenu.href }" target="mainFrame" >
|
||||
href="javascript:;" onclick="page_turn('${thirdMenu.id }','2','','${ctx}/${thirdMenu.href }',this)" target="mainFrame" >
|
||||
|
||||
</c:if>
|
||||
<c:if test="${!thirdHref }">
|
||||
href="javascript:;" class="nav-link nav-toggle">
|
||||
@@ -50,15 +52,17 @@
|
||||
<span class="title">
|
||||
<%-- ${thirdMenu.name } --%><spring:message code="${thirdMenu.code}"></spring:message></span>
|
||||
<c:if test="${not empty thirdMenu.children }" var="thiredClid">
|
||||
<span class="arrow open"></span>
|
||||
<span class="arrow "></span>
|
||||
</c:if>
|
||||
</a>
|
||||
|
||||
<c:if test="${thiredClid}">
|
||||
<ul class="sub-menu">
|
||||
<c:forEach items="${thirdMenu.children}" var="fourthMenu">
|
||||
<li class="nav-item">
|
||||
<a href="${ctx}/${fourthMenu.href }" target="mainFrame" class="nav-link ">
|
||||
<li class="nav-item" id="menu_${fourthMenu.id }" menu-id="${fourthMenu.id }" menu-name="<spring:message code="${fourthMenu.code}"></spring:message>" >
|
||||
<a href="javascript:;"
|
||||
onclick="page_turn('${fourthMenu.id }','3','','${ctx}/${fourthMenu.href }',this)" target="mainFrame"
|
||||
class="nav-link ">
|
||||
<%-- ${fourthMenu.name } --%> <spring:message code="${fourthMenu.code}"></spring:message>
|
||||
<!-- <span class="badge badge-danger">1</span> -->
|
||||
</a>
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
<%@ attribute name="label" type="java.lang.String" required="false"%>
|
||||
<c:choose>
|
||||
<c:when test="${label eq 'delete'}">
|
||||
<button class="btn btn-default" onclick="del('${url}')" data-toggle="tooltip" data-placement="top">
|
||||
<a href="javascript:void(0);" class="btn btn-default" onclick="del('${url}')" data-toggle="tooltip" data-placement="top">
|
||||
<i class="fa fa-trash"> <spring:message code="delete"/></i>
|
||||
</button>
|
||||
</a>
|
||||
</c:when>
|
||||
|
||||
<c:when test="${label eq 'approved'}">
|
||||
|
||||
@@ -10,10 +10,15 @@
|
||||
$(document).ready(function() {
|
||||
var orderBy = $("#${id}").val().split(" ");
|
||||
$(".sort-column").each(function(){
|
||||
|
||||
if ($(this).hasClass(orderBy[0])){
|
||||
orderBy[1] = orderBy[1]&&orderBy[1].toUpperCase()=="DESC"?"down":"up";
|
||||
$(this).html($(this).html()+" <i class=\"icon icon-arrow-"+orderBy[1]+"\"></i>");
|
||||
$(this).html($(this).html()+" <i class=\"sort-icon-"+orderBy[1]+"\"></i>");
|
||||
}else {
|
||||
$(this).html($(this).html()+" <i class=\"sort-icon\"></i>");
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
$(".sort-column").click(function(){
|
||||
var order = $(this).attr("class").split(" ");
|
||||
@@ -23,10 +28,11 @@
|
||||
}
|
||||
if (order == sort[0]){
|
||||
sort = (sort[1]&&sort[1].toUpperCase()=="DESC"?"ASC":"DESC");
|
||||
$("#${id}").val(order+" DESC"!=order+" "+sort?"":order+" "+sort);
|
||||
$("#${id}").val(order+" "+sort);
|
||||
}else{
|
||||
$("#${id}").val(order+" ASC");
|
||||
}
|
||||
|
||||
${callback}
|
||||
});
|
||||
});
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
<div class="input-append">
|
||||
<input id="${id}Id" name="${name}" class="${cssClass} singleClass" type="hidden" value="${value}" />
|
||||
<input id="${id}Name" name="${labelName}" ${allowInput?'':'readonly="readonly"'} type="text" value="${labelValue}" data-msg-required="${dataMsgRequired}" placeholder="${value}"
|
||||
class="${cssClass}" style="${cssStyle}"/><a id="${id}Button" href="javascript:" class="btn ${disabled} ${hideBtn ? 'hide' : ''}" style="${smallBtn?'padding:4px 2px;':''}"> <i class="icon-search"></i> </a>
|
||||
class="${cssClass}" style="${cssStyle} background-color:transparent"/><a id="${id}Button" href="javascript:" class="btn ${disabled} ${hideBtn ? 'hide' : ''}" style="${smallBtn?'padding:4px 2px;':''}"> <i class="icon-search"></i> </a>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$("#${id}Button, #${id}Name").click(function(){
|
||||
|
||||
@@ -311,6 +311,14 @@
|
||||
<example>${fns:getSysDictInfoById(id)}</example>
|
||||
</function>
|
||||
|
||||
<function>
|
||||
<description>根据id获取特定服务配置</description>
|
||||
<name>getBySpecServiceId</name>
|
||||
<function-class>com.nis.util.ConfigDictUtils</function-class>
|
||||
<function-signature>java.lang.String getBySpecServiceId(java.lang.Integer)</function-signature>
|
||||
<example>${fns:getBySpecServiceId(id)}</example>
|
||||
</function>
|
||||
|
||||
<!-- 计算序号 -->
|
||||
<function>
|
||||
<description>计算序号</description>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
function reset(){
|
||||
$("#searchForm").reset();
|
||||
}
|
||||
|
||||
/**
|
||||
处理全选、全取消
|
||||
**/
|
||||
@@ -69,6 +70,12 @@
|
||||
}
|
||||
$(document).ready(function() {
|
||||
|
||||
//reset
|
||||
$("#resetBtn").on("click",function(){
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
});
|
||||
|
||||
//设定显示总条数
|
||||
$("#showTotalCount").text('${showTotalCount}');
|
||||
//设定selected,设定name 设定value
|
||||
@@ -230,7 +237,7 @@
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page2()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
<button type="button" id="resetBtn" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -293,7 +300,7 @@
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/form?serviceDictId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要修改该项配置吗?', this.href)"><spring:message code="edit"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/delete?serviceDictId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/delete?mulitId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
|
||||
</ul>
|
||||
|
||||
@@ -58,14 +58,6 @@
|
||||
$("#searchForm").attr("action","${ctx}/basics/serviceDictInfo/list?itType=${itType}");
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
function page2(n,s){
|
||||
$("#intype").attr("name",$("#seltype").val());
|
||||
$("#pageNo").val(n);
|
||||
$("#pageSize").val(s);
|
||||
$("#searchForm").attr("action","${ctx}/basics/serviceDictInfo/searchList?itType=${itType}");
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
$(document).ready(function() {
|
||||
|
||||
@@ -77,6 +69,11 @@
|
||||
$("#intype").attr("name",$("#seltype").find("option:selected").val());
|
||||
$("#intype").val('${searchContent}');
|
||||
|
||||
//reset
|
||||
$("#resetBtn").on("click",function(){
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
});
|
||||
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
@@ -123,13 +120,13 @@
|
||||
<div class="portlet-body">
|
||||
|
||||
<div class="row" >
|
||||
<form:form id="searchForm" modelAttribute="serviceDictInfo" action="${ctx}/basics/serviceDictInfo/searchList?itType=${itType}" method="post" class="form-search">
|
||||
<form:form id="searchForm" modelAttribute="serviceDictInfo" action="${ctx}/basics/serviceDictInfo/list?itType=${itType}" method="post" class="form-search">
|
||||
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
|
||||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||||
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${serviceDictInfo.isFilterAction}"/>
|
||||
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
|
||||
@@ -160,7 +157,7 @@
|
||||
<input id="intype" class="form-control input-medium" placeholder="请输入配置编码" type="text">
|
||||
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page2()"><i class="fa fa-search"></i></button>
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page()"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -229,8 +226,8 @@
|
||||
<div class="row">
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page2()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
<button type="button" class="btn blue" onclick="page()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()" id="resetBtn"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -247,9 +244,9 @@
|
||||
|
||||
|
||||
|
||||
<!-- <div class="table-responsive"> -->
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="treeTable" class="table table-striped table-bordered table-condensed">
|
||||
<table id="treeTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" class="ckboxs" id="selAll" onclick="selectAll()"></th>
|
||||
@@ -260,9 +257,9 @@
|
||||
<th><spring:message code="item_type"/></th>
|
||||
<th><spring:message code="is_leaf"/></th>
|
||||
<th><spring:message code="creator"/></th>
|
||||
<th><spring:message code="create_time"/>
|
||||
<th class="sort-column create_time"><spring:message code="create_time"/>
|
||||
</th><th><spring:message code="editor"/></th>
|
||||
<th><spring:message code="edit_time"/></th>
|
||||
<th class="sort-column edit_time"><spring:message code="edit_time"/></th>
|
||||
<shiro:hasPermission name="sys:menu:edit"><th><spring:message code="operation"/></th></shiro:hasPermission>
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -293,7 +290,7 @@
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/form?serviceDictId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要修改该项配置吗?', this.href)"><spring:message code="edit"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/delete?serviceDictId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
<li><a href="${ctx}/basics/serviceDictInfo/delete?mulitId=${serviceDictInfo.serviceDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
|
||||
</ul>
|
||||
@@ -309,5 +306,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -235,15 +235,19 @@
|
||||
<form:input path="itemValue" htmlEscape="false" maxlength="2000" class="form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
<c:if test="${specType != null and specType==3 }">
|
||||
<form:hidden path="isLeaf" value="0"/>
|
||||
</c:if>
|
||||
<c:if test="${specType != null and specType!=3 }">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="is_leaf"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<%-- <form:radiobuttons path="isLeaf" items="${fns:getDictOption('SYS_YES_NO')}" /> --%>
|
||||
<form:select path="isLeaf" class="form-control">
|
||||
<form:options items="${fns:getDictList('SYS_YES_NO')}" itemLabel="itemValue" itemValue="itemCode" htmlEscape="false"/>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><spring:message code="desc"/>:</label>
|
||||
<div class="col-md-4">
|
||||
|
||||
@@ -77,6 +77,11 @@
|
||||
$("#intype").attr("name",$("#seltype").find("option:selected").val());
|
||||
$("#intype").val('${searchContent}');
|
||||
|
||||
//reset
|
||||
$("#resetBtn").on("click",function(){
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
});
|
||||
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
@@ -228,7 +233,7 @@
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page2()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
<button type="button" id="resetBtn" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -291,7 +296,7 @@
|
||||
<li><a href="${ctx}/basics/sysDictInfo/form?sysDictId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要修改该项配置吗?', this.href)"><spring:message code="edit"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/basics/sysDictInfo/delete?sysDictId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
<li><a href="${ctx}/basics/sysDictInfo/delete?mulitId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
|
||||
</ul>
|
||||
|
||||
@@ -64,14 +64,6 @@
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
function page2(n,s){
|
||||
$("#intype").attr("name",$("#seltype").val());
|
||||
$("#pageNo").val(n);
|
||||
$("#pageSize").val(s);
|
||||
$("#searchForm").attr("action","${ctx}/basics/sysDictInfo/searchList?itType=${itType}");
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
$(document).ready(function() {
|
||||
//设定显示总条数
|
||||
$("#showTotalCount").text('${showTotalCount}');
|
||||
@@ -79,8 +71,13 @@
|
||||
|
||||
$("#seltype").find("option[value='${searchType==null?11:searchType}']").attr("selected",true);
|
||||
$("#intype").attr("name",$("#seltype").find("option:selected").val());
|
||||
$("#intype").val('${sysDictInfo.itemValue}');
|
||||
$("#intype").val('${searchContent}');
|
||||
|
||||
//reset
|
||||
$("#resetBtn").on("click",function(){
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
});
|
||||
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
@@ -126,13 +123,13 @@
|
||||
<div class="portlet-body">
|
||||
|
||||
<div class="row" >
|
||||
<form:form id="searchForm" modelAttribute="sysDictInfo" action="${ctx}/basics/sysDictInfo/searchList?itType=${itType}" method="post" class="form-search">
|
||||
<form:form id="searchForm" modelAttribute="sysDictInfo" action="${ctx}/basics/sysDictInfo/list?itType=${itType}" method="post" class="form-search">
|
||||
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
|
||||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||||
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${sysDictInfo.isFilterAction}"/>
|
||||
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
|
||||
@@ -163,7 +160,7 @@
|
||||
<input id="intype" class="form-control input-medium" placeholder="请输入配置编码" type="text">
|
||||
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page2()"><i class="fa fa-search"></i></button>
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page()"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -232,8 +229,8 @@
|
||||
<div class="row">
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page2()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
<button type="button" class="btn blue" onclick="page()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" class="btn btn-default" onclick="reset()" id="resetBtn"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@@ -250,9 +247,9 @@
|
||||
|
||||
|
||||
|
||||
<!-- <div class="table-responsive"> -->
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="treeTable" class="table table-striped table-bordered table-condensed">
|
||||
<table id="treeTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" id="selAll" class="ckboxs" onclick="selectAll()"></th>
|
||||
@@ -261,11 +258,13 @@
|
||||
<th><spring:message code="config_content"/></th>
|
||||
<th><spring:message code="desc"/></th>
|
||||
<th><spring:message code="item_type"/></th>
|
||||
<c:if test="${specType != null and specType!=3 }">
|
||||
<th><spring:message code="is_leaf"/></th>
|
||||
</c:if>
|
||||
<th><spring:message code="creator"/></th>
|
||||
<th><spring:message code="create_time"/>
|
||||
<th class="sort-column create_time"><spring:message code="create_time"/>
|
||||
</th><th><spring:message code="editor"/></th>
|
||||
<th><spring:message code="edit_time"/></th>
|
||||
<th class="sort-column edit_time"><spring:message code="edit_time"/></th>
|
||||
<shiro:hasPermission name="sys:menu:edit"><th><spring:message code="operation"/></th></shiro:hasPermission>
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -278,7 +277,9 @@
|
||||
<td>${sysDictInfo.itemValue}</td>
|
||||
<td title="${sysDictInfo.itemDesc}">${fns:abbr(sysDictInfo.itemDesc,15)}</td>
|
||||
<td>${fns:getDictLabel("SYS_DICT_ITM_TYPE",sysDictInfo.itemType,"0")}</td>
|
||||
<c:if test="${specType != null and specType!=3 }">
|
||||
<td>${fns:getDictLabel("SYS_YES_NO",sysDictInfo.isLeaf,"0")}</td>
|
||||
</c:if>
|
||||
<td><c:if test="${sysDictInfo.sysDictCreator != null}">
|
||||
${fns:getUserById(sysDictInfo.sysDictCreator.id).name}
|
||||
</c:if></td>
|
||||
@@ -296,7 +297,7 @@
|
||||
<li><a href="${ctx}/basics/sysDictInfo/form?sysDictId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要修改该项配置吗?', this.href)"><spring:message code="edit"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/basics/sysDictInfo/delete?sysDictId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
<li><a href="${ctx}/basics/sysDictInfo/delete?mulitId=${sysDictInfo.sysDictId}&itType=${itType}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
|
||||
</ul>
|
||||
@@ -312,5 +313,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -9,6 +9,13 @@
|
||||
|
||||
<div class="page-content">
|
||||
<div class="row">
|
||||
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-default" onclick="history.go(-1)"><spring:message code="back"/></button>
|
||||
</div>
|
||||
<h3 class="page-title">
|
||||
<spring:message code="special_task"/>
|
||||
</h3>
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
@@ -81,25 +88,35 @@
|
||||
rules: {
|
||||
taskName: {
|
||||
required: true,
|
||||
maxlength:64,
|
||||
},
|
||||
taskOrg: {
|
||||
required: true,
|
||||
maxlength:128,
|
||||
},
|
||||
taskTime: {
|
||||
required: true,
|
||||
},
|
||||
taskDesc: {
|
||||
maxlength:512,
|
||||
},
|
||||
|
||||
},
|
||||
messages: {
|
||||
taskName: {
|
||||
required: '<spring:message code="required"/>',
|
||||
maxlength: '<spring:message code="maxlength_64"/>',
|
||||
},
|
||||
taskOrg: {
|
||||
required: '<spring:message code="required"/>',
|
||||
maxlength: '<spring:message code="maxlength_128"/>',
|
||||
},
|
||||
taskTime: {
|
||||
required: '<spring:message code="required"/>',
|
||||
},
|
||||
taskDesc: {
|
||||
maxlength: '<spring:message code="maxlength_512"/>',
|
||||
},
|
||||
},
|
||||
submitHandler: function(form){
|
||||
//loading('onloading...');
|
||||
|
||||
@@ -9,13 +9,15 @@
|
||||
<body>
|
||||
|
||||
<div class="page-content">
|
||||
<shiro:hasPermission name="basics:taskInfo:edit">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-default" onclick="javascript:window.location='${ctx}/basics/taskInfo/list'"><spring:message code="refresh"></spring:message></button>
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/basics/taskInfo/form'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"/></button>
|
||||
</div>
|
||||
|
||||
</shiro:hasPermission>
|
||||
<h3 class="page-title">
|
||||
<spring:message code="special_task"></spring:message>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
@@ -35,7 +37,7 @@
|
||||
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${taskInfo.isFilterAction }"/>
|
||||
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
|
||||
@@ -50,7 +52,7 @@
|
||||
<div class="pull-left">
|
||||
<div class="input-group">
|
||||
<div class="input-group-btn">
|
||||
<input id="taskName" name="taskName" class="form-control input-medium" placeholder=<spring:message code="input_title"/> type="text" value="${taskInfo.taskName }">
|
||||
<input id="taskName" name="taskName" class="form-control input-medium" type="text" value="${taskInfo.taskName }">
|
||||
</div>
|
||||
|
||||
<div class="input-group-btn">
|
||||
@@ -65,7 +67,7 @@
|
||||
</div>
|
||||
|
||||
<div class="pull-right">
|
||||
|
||||
<shiro:hasPermission name="basics:taskInfo:edit">
|
||||
<button type="button" class="btn btn-default" onclick="edit()">
|
||||
<i class="fa fa-edit"></i> <spring:message code="edit"></spring:message></button>
|
||||
<sys:delRow url="${ctx}/basics/taskInfo/delete" id="contentTable" label="delete"></sys:delRow>
|
||||
@@ -82,6 +84,11 @@
|
||||
<li><sys:delRow url="${ctx}/basics/taskInfo/taskCancelExamine" id="contentTable" label="cancelPass"></sys:delRow></li>
|
||||
</ul>
|
||||
</div>
|
||||
</shiro:hasPermission>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -112,7 +119,7 @@
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="operate_time"/>:</label>
|
||||
<label><spring:message code="edit_time"/>:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="dobeginDate" name="dobeginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
@@ -145,9 +152,9 @@
|
||||
|
||||
</div>
|
||||
|
||||
<!-- <div class="table-responsive"> -->
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed">
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
|
||||
@@ -156,8 +163,13 @@
|
||||
<th><spring:message code="task_org"></spring:message></th>
|
||||
<th><spring:message code="task_time"></spring:message></th>
|
||||
<th><spring:message code="state"></spring:message></th>
|
||||
<th><spring:message code="operator"></spring:message></th>
|
||||
<th><spring:message code="operate_time"></spring:message></th>
|
||||
<th><spring:message code="desc"></spring:message></th>
|
||||
<th><spring:message code="creator"></spring:message></th>
|
||||
<th class="sort-column createTime"><spring:message code="create_time"/></th>
|
||||
<th><spring:message code="editor"/></th>
|
||||
<th class="sort-column editTime"><spring:message code="edit_time"/></th>
|
||||
<th><spring:message code="auditor"></spring:message></th>
|
||||
<th class="sort-column auditTime"><spring:message code="audit_time"></spring:message></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -175,18 +187,13 @@
|
||||
<c:when test="${taskInfo.isAudit eq '2'}"><span class="label label-warning"><spring:message code="unapproved"></spring:message></span></c:when>
|
||||
</c:choose>
|
||||
</td>
|
||||
<td>${taskInfo.taskDesc }</td>
|
||||
<td>${taskInfo.creatorName }</td>
|
||||
<td>
|
||||
<!-- 编辑时间为空则显示创建时间 -->
|
||||
<c:choose>
|
||||
<c:when test="${empty taskInfo.editTime}">
|
||||
<fmt:formatDate value="${taskInfo.createTime }" pattern="yyyy-MM-dd"/>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<fmt:formatDate value="${taskInfo.editTime }" pattern="yyyy-MM-dd"/>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</td>
|
||||
<td><fmt:formatDate value="${taskInfo.createTime }" pattern="yyyy-MM-dd"/></td>
|
||||
<td>${taskInfo.editorName }</td>
|
||||
<td><fmt:formatDate value="${taskInfo.editTime }" pattern="yyyy-MM-dd"/></td>
|
||||
<td>${taskInfo.auditorName }</td>
|
||||
<td><fmt:formatDate value="${taskInfo.auditTime }" pattern="yyyy-MM-dd"/></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
|
||||
@@ -198,6 +205,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
@@ -228,12 +236,13 @@
|
||||
|
||||
|
||||
function resetx(){
|
||||
// $("#searchForm").reset();
|
||||
$(':input','#searchForm')
|
||||
.not(':button,:submit,:reset,:hidden')
|
||||
.val('')
|
||||
.removeAttr('checked')
|
||||
.removeAttr('selected');
|
||||
$("select.selectpicker").each(function(){
|
||||
$(this).selectpicker('val',$(this).find('option:first').val());
|
||||
$(this).find("option").attr("selected",false);
|
||||
$(this).find("option:first").attr("selected",true);
|
||||
});
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -3,22 +3,6 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$("#save").on("click",function(){
|
||||
@@ -36,9 +20,6 @@ $(function(){
|
||||
'keywords':{
|
||||
required:true
|
||||
},
|
||||
'district':{
|
||||
required:true
|
||||
},
|
||||
'isAreaEffective':{
|
||||
required:true
|
||||
},
|
||||
@@ -59,9 +40,6 @@ $(function(){
|
||||
'keywords':{
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
'district':{
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
'isAreaEffective':{
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
@@ -123,10 +101,16 @@ $(function(){
|
||||
<input type="hidden" name="tableName" value="${_cfg.tableName}">
|
||||
<input type="hidden" name="serviceId" value="${_cfg.serviceId}">
|
||||
<input type="hidden" name="cfgName" value="${cfgName}">
|
||||
<input type="hidden" name="action" value="${_cfg.action}">
|
||||
<input type="hidden" name="action" value="${action}">
|
||||
<input type="hidden" name="district" value="${_cfg.district}">
|
||||
<c:choose>
|
||||
<c:when test="${action!=5 and action!=8}">
|
||||
<%@include file="/WEB-INF/include/form/basicInfo.jsp" %>
|
||||
|
||||
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<input type="hidden" name=requestId value="0">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
|
||||
@@ -3,22 +3,6 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
//筛选功能初始化
|
||||
@@ -140,6 +124,10 @@
|
||||
</div>
|
||||
<div class="pull-right">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="return page()"><i class="fa fa-search"></i></button>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
@@ -222,22 +210,18 @@
|
||||
</form:form>
|
||||
</div>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><spring:message code="seq"/></th>
|
||||
<th><spring:message code="config_describe"/></th>
|
||||
<th><spring:message code="match_area"/></th>
|
||||
<th><spring:message code="key_word"/></th>
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<!-- <th>业务id</th> -->
|
||||
<th><spring:message code="letter"/></th>
|
||||
<!-- <th>编译id</th> -->
|
||||
<th><spring:message code="whether_area_block"/></th>
|
||||
<th><spring:message code="letter"/></th>
|
||||
<th><spring:message code="type"/></th>
|
||||
<th><spring:message code="attribute"/></th>
|
||||
<th><spring:message code="label"/></th>
|
||||
<!-- <th>区域生效id</th> -->
|
||||
<th><spring:message code="valid_identifier"/></th>
|
||||
<th><spring:message code="is_audit"/></th>
|
||||
<th><spring:message code="creator"/></th>
|
||||
@@ -254,7 +238,7 @@
|
||||
<tr>
|
||||
<td>${status.index+1 }</td>
|
||||
<td>${cfg.cfgDesc }</td>
|
||||
<td>${cfg.district }</td>
|
||||
<%-- <td>${cfg.district }</td> --%>
|
||||
<td>${cfg.keywords }</td>
|
||||
<td>
|
||||
<c:if test="${1 eq cfg.action }"><spring:message code="block"/></c:if>
|
||||
@@ -264,13 +248,11 @@
|
||||
<c:if test="${7 eq cfg.action }"><spring:message code="block_monitor_white_list"/></c:if>
|
||||
<c:if test="${8 eq cfg.action }"><spring:message code="grey_list"/></c:if>
|
||||
</td>
|
||||
<%-- <td>${cfg.serviceId }</td> --%>
|
||||
<td>${cfg.requestName }</td>
|
||||
<%-- <td>${cfg.compileId }</td> --%>
|
||||
<td>
|
||||
<c:if test="${cfg.isAreaEffective==0}"><spring:message code="no"/></c:if>
|
||||
<c:if test="${cfg.isAreaEffective==1}"><spring:message code="yes"/></c:if>
|
||||
</td>
|
||||
<td>${cfg.requestName }</td>
|
||||
<td>
|
||||
<c:forEach items="${fn:split(cfg.classify,',')}" var="classifyId">
|
||||
<c:forEach items="${fls}" var="fl">
|
||||
|
||||
@@ -4,21 +4,6 @@
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$("#save").on("click",function(){
|
||||
@@ -222,12 +207,6 @@ $(function(){
|
||||
<c:if test="${empty _cfg.cfgId}"><spring:message code="add"></spring:message></c:if>
|
||||
<c:if test="${not empty _cfg.cfgId}"><spring:message code="edit"></spring:message></c:if>
|
||||
</div>
|
||||
<!-- <div class="tools">
|
||||
<a href="javascript:;" class="collapse" data-original-title="" title=""> </a>
|
||||
<a href="#portlet-config" data-toggle="modal" class="config" data-original-title="" title=""> </a>
|
||||
<a href="javascript:;" class="reload" data-original-title="" title=""> </a>
|
||||
<a href="javascript:;" class="remove" data-original-title="" title=""> </a>
|
||||
</div> -->
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
<!-- BEGIN FORM-->
|
||||
@@ -242,26 +221,14 @@ $(function(){
|
||||
<input type="hidden" name="cfgName" value="${cfgName}">
|
||||
<input type="hidden" name="action" value="${action}">
|
||||
<input type="hidden" name="protocolId" value="${_cfg.protocolId}">
|
||||
<!-- <div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3">IP地址</label>
|
||||
<div class="col-md-8">
|
||||
<input class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3">配置名称</label>
|
||||
<div class="col-md-8">
|
||||
<input class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
-->
|
||||
<c:choose>
|
||||
<c:when test="${action!=5 and action!=8}">
|
||||
<%@include file="/WEB-INF/include/form/basicInfo.jsp" %>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<input type="hidden" name=requestId value="0">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
@@ -3,24 +3,11 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$("seltype").on("click",function(){
|
||||
alert(2333)
|
||||
});
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
$("#isAudit").change(function(){
|
||||
@@ -55,9 +42,7 @@
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/cfg/ip/form?serviceId=${serviceId}&action=${action}&cfgName=${cfgName}&audit=${audit}'"><spring:message code="add"></spring:message></button>
|
||||
</c:if>
|
||||
|
||||
</div>
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="${cfgName}"></spring:message>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
@@ -90,36 +75,22 @@
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="request_number"><spring:message code='request_number'/></c:set>
|
||||
<form:select path="requestId" class="selectpicker select2 input-small" title="${request_number}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${requestInfos}" var="requestInfo" >
|
||||
<form:option value="${requestInfo.id}"><spring:message code="${requestInfo.requestTitle}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
<%-- <div class="input-group">
|
||||
<div class="input-group-btn">
|
||||
<form:select path="seltype" class="selectpicker select2 input-small" >
|
||||
<form:option value="cfgDesc"><spring:message code="config_describe"></spring:message></form:option>
|
||||
<form:option value="srcIp"><spring:message code="client_ip"></spring:message></form:option>
|
||||
<form:option value="dstIp"><spring:message code="server_ip"></spring:message></form:option>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="flI18n"><spring:message code='type'/></c:set>
|
||||
<form:select path="classify" class="selectpicker select2 input-small" title="${flI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${fls}" var="fl" >
|
||||
<form:option value="${fl.serviceDictId}"><spring:message code="${fl.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
|
||||
<input id="intype" class="form-control input-medium" type="text" value="">
|
||||
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page()"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="attributeI18n"><spring:message code='attribute'/></c:set>
|
||||
<form:select path="attribute" class="selectpicker select2 input-small" title="${attributeI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${xzs}" var="xz" >
|
||||
<form:option value="${xz.serviceDictId}"><spring:message code="${xz.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="labelI18n"><spring:message code='label'/></c:set>
|
||||
<form:select path="lable" class="selectpicker select2 input-small" title="${labelI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${lables}" var="lable" >
|
||||
<form:option value="${lable.serviceDictId}"><spring:message code="${lable.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
|
||||
</div> --%>
|
||||
</div>
|
||||
<!-- <div class="pull-right">
|
||||
<button type="button" class="btn btn-default">
|
||||
@@ -164,6 +135,10 @@
|
||||
</div>
|
||||
<div class="pull-right">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="return page()"><i class="fa fa-search"></i></button>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
@@ -171,7 +146,48 @@
|
||||
<!-- 筛选搜索内容栏默认隐藏-->
|
||||
<div class="col-md-12 filter-action-select-panle hide" >
|
||||
<div class="row">
|
||||
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:when test="${action==8}">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="pull-left">
|
||||
<c:set var="request_number"><spring:message code='request_number'/></c:set>
|
||||
<form:select path="requestId" class="selectpicker select2 input-small" title="${request_number}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${requestInfos}" var="requestInfo" >
|
||||
<form:option value="${requestInfo.id}"><spring:message code="${requestInfo.requestTitle}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="flI18n"><spring:message code='type'/></c:set>
|
||||
<form:select path="classify" class="selectpicker select2 input-small" title="${flI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${fls}" var="fl" >
|
||||
<form:option value="${fl.serviceDictId}"><spring:message code="${fl.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="attributeI18n"><spring:message code='attribute'/></c:set>
|
||||
<form:select path="attribute" class="selectpicker select2 input-small" title="${attributeI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${xzs}" var="xz" >
|
||||
<form:option value="${xz.serviceDictId}"><spring:message code="${xz.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="labelI18n"><spring:message code='label'/></c:set>
|
||||
<form:select path="lable" class="selectpicker select2 input-small" title="${labelI18n}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${lables}" var="lable" >
|
||||
<form:option value="${lable.serviceDictId}"><spring:message code="${lable.itemValue}"></spring:message></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="config_time"/>:</label>
|
||||
@@ -187,7 +203,6 @@
|
||||
<input name="search_create_time_end" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${ipCfg.search_create_time_end}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
@@ -240,7 +255,7 @@
|
||||
</form:form>
|
||||
</div>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><spring:message code="seq"/></th>
|
||||
@@ -254,18 +269,24 @@
|
||||
<th><spring:message code="server_address_mask"/></th>
|
||||
<th><spring:message code="server_port"/></th>
|
||||
<th><spring:message code="server_port_mask"/></th>
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:when test="${action==8}">
|
||||
<th><spring:message code="direction"/></th>
|
||||
<th><spring:message code="protocol"/></th>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<th><spring:message code="direction"/></th>
|
||||
<th><spring:message code="protocol"/></th>
|
||||
<!-- <th>协议ID</th> -->
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<!-- <th>业务id</th> -->
|
||||
<th><spring:message code="letter"/></th>
|
||||
<!-- <th>编译id</th> -->
|
||||
<th><spring:message code="whether_area_block"/></th>
|
||||
<th><spring:message code="letter"/></th>
|
||||
<th><spring:message code="type"/></th>
|
||||
<th><spring:message code="attribute"/></th>
|
||||
<th><spring:message code="label"/></th>
|
||||
<!-- <th>区域生效id</th> -->
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<th><spring:message code="valid_identifier"/></th>
|
||||
<th><spring:message code="is_audit"/></th>
|
||||
<th><spring:message code="creator"/></th>
|
||||
@@ -291,6 +312,18 @@
|
||||
<td>${ipCfg.dstIpMask }</td>
|
||||
<td>${ipCfg.dstPort }</td>
|
||||
<td>${ipCfg.dstPortMask }</td>
|
||||
<td>
|
||||
<c:if test="${1 eq ipCfg.action }"><spring:message code="block"/></c:if>
|
||||
<c:if test="${2 eq ipCfg.action }"><spring:message code="monitor"/></c:if>
|
||||
<c:if test="${5 eq ipCfg.action }"><spring:message code="block_white_list"/></c:if>
|
||||
<c:if test="${6 eq ipCfg.action }"><spring:message code="monitor_white_list"/></c:if>
|
||||
<c:if test="${7 eq ipCfg.action }"><spring:message code="block_monitor_white_list"/></c:if>
|
||||
<c:if test="${8 eq ipCfg.action }"><spring:message code="grey_list"/></c:if>
|
||||
</td>
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:when test="${action==8}">
|
||||
<td>
|
||||
<c:if test="${ipCfg.direction==0}"><spring:message code="twoway"/></c:if>
|
||||
<c:if test="${ipCfg.direction==1}"><spring:message code="oneway"/></c:if>
|
||||
@@ -300,22 +333,22 @@
|
||||
<c:if test="${ipCfg.protocol==17}"><spring:message code="UDP"/></c:if>
|
||||
<c:if test="${ipCfg.protocol==0}"><spring:message code="arbitrary"/></c:if>
|
||||
</td>
|
||||
<%-- <td>${ipCfg.protocolId }</td> --%>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<td>
|
||||
<c:if test="${1 eq ipCfg.action }"><spring:message code="block"/></c:if>
|
||||
<c:if test="${2 eq ipCfg.action }"><spring:message code="monitor"/></c:if>
|
||||
<c:if test="${5 eq ipCfg.action }"><spring:message code="block_white_list"/></c:if>
|
||||
<c:if test="${6 eq ipCfg.action }"><spring:message code="monitor_white_list"/></c:if>
|
||||
<c:if test="${7 eq ipCfg.action }"><spring:message code="block_monitor_white_list"/></c:if>
|
||||
<c:if test="${8 eq ipCfg.action }"><spring:message code="grey_list"/></c:if>
|
||||
<c:if test="${ipCfg.direction==0}"><spring:message code="twoway"/></c:if>
|
||||
<c:if test="${ipCfg.direction==1}"><spring:message code="oneway"/></c:if>
|
||||
</td>
|
||||
<td>
|
||||
<c:if test="${ipCfg.protocol==6}"><spring:message code="TCP"/></c:if>
|
||||
<c:if test="${ipCfg.protocol==17}"><spring:message code="UDP"/></c:if>
|
||||
<c:if test="${ipCfg.protocol==0}"><spring:message code="arbitrary"/></c:if>
|
||||
</td>
|
||||
<%-- <td>${ipCfg.serviceId }</td> --%>
|
||||
<td>${ipCfg.requestName }</td>
|
||||
<%-- <td>${ipCfg.compileId }</td> --%>
|
||||
<td>
|
||||
<c:if test="${ipCfg.isAreaEffective==0}"><spring:message code="no"/></c:if>
|
||||
<c:if test="${ipCfg.isAreaEffective==1}"><spring:message code="yes"/></c:if>
|
||||
</td>
|
||||
<td>${ipCfg.requestName }</td>
|
||||
<td>
|
||||
<c:forEach items="${fn:split(ipCfg.classify,',')}" var="classifyId">
|
||||
<c:forEach items="${fls}" var="fl">
|
||||
@@ -340,6 +373,8 @@
|
||||
</c:forEach>
|
||||
</c:forEach>
|
||||
</td>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<%-- <td>${ipCfg.areaEffectiveIds }</td> --%>
|
||||
<td>
|
||||
<c:if test="${ipCfg.isValid==0}"><spring:message code="no"/></c:if>
|
||||
|
||||
@@ -81,16 +81,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<style>
|
||||
.input-medium {
|
||||
width: 200px !important;
|
||||
}
|
||||
.Wdate {
|
||||
border: #c2cad8 1px solid;
|
||||
height: 34px;
|
||||
}
|
||||
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
|
||||
@@ -98,15 +88,21 @@
|
||||
rules: {
|
||||
requestNumber: {
|
||||
required: true,
|
||||
maxlength:64,
|
||||
},
|
||||
requestOrg: {
|
||||
required: true,
|
||||
maxlength:128,
|
||||
},
|
||||
requestTime: {
|
||||
required: true,
|
||||
},
|
||||
requestTitle: {
|
||||
maxlength:512,
|
||||
},
|
||||
requestContent: {
|
||||
required: true,
|
||||
maxlength:4000,
|
||||
},
|
||||
|
||||
|
||||
@@ -114,15 +110,21 @@
|
||||
messages: {
|
||||
requestNumber: {
|
||||
required: '<spring:message code="required"/>',
|
||||
maxlength:'<spring:message code="maxlength_64"/>',
|
||||
},
|
||||
requestOrg: {
|
||||
required: '<spring:message code="required"/>',
|
||||
maxlength:'<spring:message code="maxlength_128"/>',
|
||||
},
|
||||
requestTime: {
|
||||
required: '<spring:message code="required"/>',
|
||||
},
|
||||
requestTitle: {
|
||||
maxlength:'<spring:message code="maxlength_512"/>',
|
||||
},
|
||||
requestContent: {
|
||||
required: '<spring:message code="required"/>',
|
||||
maxlength:'<spring:message code="maxlength_4000"/>',
|
||||
},
|
||||
},
|
||||
submitHandler: function(form){
|
||||
|
||||
@@ -9,13 +9,14 @@
|
||||
<body>
|
||||
|
||||
<div class="page-content">
|
||||
<shiro:hasPermission name="cfg:requestInfo:edit">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/cfg/request/form'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"/></button>
|
||||
</div>
|
||||
|
||||
</shiro:hasPermission>
|
||||
<h3 class="page-title">
|
||||
<spring:message code="requestInfo"></spring:message>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
@@ -36,6 +37,8 @@
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${requestInfo.isFilterAction }"/>
|
||||
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
|
||||
@@ -71,7 +74,7 @@
|
||||
</div>
|
||||
|
||||
<div class="pull-right">
|
||||
|
||||
<shiro:hasPermission name="cfg:requestInfo:edit">
|
||||
<button type="button" class="btn btn-default" onclick="edit()">
|
||||
<i class="fa fa-edit"></i> <spring:message code="edit"></spring:message></button>
|
||||
<sys:delRow url="${ctx}/cfg/request/delete" id="contentTable" label="delete"></sys:delRow>
|
||||
@@ -88,9 +91,9 @@
|
||||
<li><sys:delRow url="${ctx}/cfg/request/requestCancelExamine" id="contentTable" label="cancelPass"></sys:delRow></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</shiro:hasPermission>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title="自定义列字段" href="javascript:;">
|
||||
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
@@ -126,7 +129,7 @@
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="operate_time"/>:</label>
|
||||
<label><spring:message code="edit_time"/>:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="dobeginDate" name="dobeginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
@@ -164,9 +167,9 @@
|
||||
|
||||
|
||||
|
||||
<!-- <div class="table-responsive"> -->
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed">
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
|
||||
@@ -175,12 +178,16 @@
|
||||
<th><spring:message code="request_organization"></spring:message></th>
|
||||
<th><spring:message code="request_time"></spring:message></th>
|
||||
<th><spring:message code="state"></spring:message></th>
|
||||
<th><spring:message code="operator"></spring:message></th>
|
||||
<th><spring:message code="operate_time"></spring:message></th>
|
||||
<th><spring:message code="title"></spring:message></th>
|
||||
<th><spring:message code="content"></spring:message></th>
|
||||
<th><spring:message code="special_task"></spring:message></th>
|
||||
<%-- <th><spring:message code="operation"></spring:message></th> --%>
|
||||
<th><spring:message code="creator"/></th>
|
||||
<th class="sort-column createTime"><spring:message code="create_time"/></th>
|
||||
<th><spring:message code="editor"/></th>
|
||||
<th class="sort-column editTime"><spring:message code="edit_time"/></th>
|
||||
<th><spring:message code="auditor"></spring:message></th>
|
||||
<th class="sort-column auditTime"><spring:message code="audit_time"></spring:message></th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -198,21 +205,15 @@
|
||||
<c:when test="${requestInfo.isAudit eq '2'}"><span class="label label-warning"><spring:message code="unapproved"></spring:message></span></c:when>
|
||||
</c:choose>
|
||||
</td>
|
||||
<td>${requestInfo.creatorName }</td>
|
||||
<td>
|
||||
<!-- 编辑时间为空则显示创建时间 -->
|
||||
<c:choose>
|
||||
<c:when test="${empty requestInfo.editTime}">
|
||||
<fmt:formatDate value="${requestInfo.createTime }" pattern="yyyy-MM-dd"/>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<fmt:formatDate value="${requestInfo.editTime }" pattern="yyyy-MM-dd"/>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</td>
|
||||
<td>${requestInfo.requestTitle }</td>
|
||||
<td>${requestInfo.requestContent }</td>
|
||||
<td>${requestInfo.taskName }</td>
|
||||
<td>${requestInfo.creatorName }</td>
|
||||
<td><fmt:formatDate value="${requestInfo.createTime }" pattern="yyyy-MM-dd"/></td>
|
||||
<td>${requestInfo.editorName }</td>
|
||||
<td><fmt:formatDate value="${requestInfo.editTime }" pattern="yyyy-MM-dd"/></td>
|
||||
<td>${requestInfo.auditorName }</td>
|
||||
<td><fmt:formatDate value="${requestInfo.auditTime }" pattern="yyyy-MM-dd"/></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
|
||||
@@ -224,6 +225,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
@@ -265,11 +267,20 @@
|
||||
|
||||
function resetx(){
|
||||
// $("#searchForm").reset();
|
||||
$(':input','#searchForm')
|
||||
.not(':button,:submit,:reset,:hidden')
|
||||
.val('')
|
||||
.removeAttr('checked')
|
||||
.removeAttr('selected');
|
||||
// $(':input','#searchForm')
|
||||
// .not(':button,:submit,:reset,:hidden')
|
||||
// .val('')
|
||||
// .removeAttr('checked')
|
||||
// .removeAttr('selected');
|
||||
$("select.selectpicker").each(function(){
|
||||
$(this).selectpicker('val',$(this).find('option:first').val());
|
||||
$(this).find("option").attr("selected",false);
|
||||
$(this).find("option:first").attr("selected",true);
|
||||
});
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
$("#intype").attr("placeholder","<spring:message code='input'/> "+"<spring:message code='title'/>");
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -3,22 +3,6 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$("#cfgFrom").validate({
|
||||
@@ -123,31 +107,18 @@ $(function(){
|
||||
<input type="hidden" name="cfgId" value="${_cfg.cfgId}">
|
||||
</c:if>
|
||||
<input id="audit" name="audit" type="hidden" value="${audit}"/>
|
||||
<input id="action" name="action" type="hidden" value="${action}"/>
|
||||
<input type="hidden" name="tableName" value="${_cfg.tableName}">
|
||||
<input type="hidden" name="serviceId" value="${_cfg.serviceId}">
|
||||
<input type="hidden" name="cfgName" value="${cfgName}">
|
||||
<!-- <div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label col-md-3">IP地址</label>
|
||||
<div class="col-md-8">
|
||||
<input class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group ">
|
||||
<label class="control-label col-md-3">配置名称</label>
|
||||
<div class="col-md-8">
|
||||
<input class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
-->
|
||||
<c:choose>
|
||||
<c:when test="${action!=5 and action!=8}">
|
||||
<%@include file="/WEB-INF/include/form/basicInfo.jsp" %>
|
||||
|
||||
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<input type="hidden" name=requestId value="0">
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
|
||||
@@ -3,22 +3,6 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="${cfgName}"></spring:message></title>
|
||||
<link href="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/css/bootstrap-select.min.css" rel="stylesheet"/>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/bootstrap-select.min.js"></script>
|
||||
<c:choose>
|
||||
<c:when test="${cookie.Language.value eq 'zh_CN'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-zh_CN.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'en'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:when>
|
||||
<c:when test="${cookie.Language.value eq 'ru_RU'}">
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-ru_RU.min.js"></script>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<script src="${pageContext.request.contextPath}/static/global/plugins/bootstrap-select/js/i18n/defaults-en_US.min.js"></script>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
//筛选功能初始化
|
||||
@@ -89,6 +73,10 @@
|
||||
<form:option value="3"><spring:message code="cancel_approved"></spring:message></form:option>
|
||||
</form:select>
|
||||
</div>
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<div class="pull-left">
|
||||
<c:set var="request_number"><spring:message code='request_number'/></c:set>
|
||||
<form:select path="requestId" class="selectpicker select2 input-small" title="${request_number}" data-live-search="true" data-live-search-placeholder="search">
|
||||
@@ -121,6 +109,8 @@
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<%-- <button type="button" class="btn btn-default btn-sm" onclick="return page()">
|
||||
<i class="fa fa-edit"></i><spring:message code="search"></spring:message>
|
||||
</button> --%>
|
||||
@@ -140,6 +130,10 @@
|
||||
</div>
|
||||
<div class="pull-right">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="return page()"><i class="fa fa-search"></i></button>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title=<spring:message code="custom_columns"/> href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
@@ -222,21 +216,24 @@
|
||||
</form:form>
|
||||
</div>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><spring:message code="seq"/></th>
|
||||
<th><spring:message code="config_describe"/></th>
|
||||
<th><spring:message code="key_word"/></th>
|
||||
<th><spring:message code="block_type"/></th>
|
||||
<!-- <th>业务id</th> -->
|
||||
<th><spring:message code="letter"/></th>
|
||||
<!-- <th>编译id</th> -->
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<th><spring:message code="whether_area_block"/></th>
|
||||
<th><spring:message code="letter"/></th>
|
||||
<th><spring:message code="type"/></th>
|
||||
<th><spring:message code="attribute"/></th>
|
||||
<th><spring:message code="label"/></th>
|
||||
<!-- <th>区域生效id</th> -->
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<th><spring:message code="valid_identifier"/></th>
|
||||
<th><spring:message code="is_audit"/></th>
|
||||
<th><spring:message code="creator"/></th>
|
||||
@@ -262,13 +259,15 @@
|
||||
<c:if test="${7 eq cfg.action }"><spring:message code="block_monitor_white_list"/></c:if>
|
||||
<c:if test="${8 eq cfg.action }"><spring:message code="grey_list"/></c:if>
|
||||
</td>
|
||||
<%-- <td>${cfg.serviceId }</td> --%>
|
||||
<td>${cfg.requestName }</td>
|
||||
<%-- <td>${cfg.compileId }</td> --%>
|
||||
<c:choose>
|
||||
<c:when test="${action==5}">
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<td>
|
||||
<c:if test="${cfg.isAreaEffective==0}"><spring:message code="no"/></c:if>
|
||||
<c:if test="${cfg.isAreaEffective==1}"><spring:message code="yes"/></c:if>
|
||||
</td>
|
||||
<td>${cfg.requestName }</td>
|
||||
<td>
|
||||
<c:forEach items="${fn:split(cfg.classify,',')}" var="classifyId">
|
||||
<c:forEach items="${fls}" var="fl">
|
||||
@@ -293,7 +292,8 @@
|
||||
</c:forEach>
|
||||
</c:forEach>
|
||||
</td>
|
||||
<%-- <td>${cfg.areaEffectiveIds }</td> --%>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<td>
|
||||
<c:if test="${cfg.isValid==0}"><spring:message code="no"/></c:if>
|
||||
<c:if test="${cfg.isValid==1}"><spring:message code="yes"/></c:if>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
|
||||
<script src="${pageContext.request.contextPath}/static/pages/scripts/home.js" type="text/javascript"></script>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
|
||||
@@ -28,9 +29,43 @@
|
||||
$obj.parent("li").addClass("hide");
|
||||
|
||||
|
||||
|
||||
|
||||
// === Search input typeahead === //
|
||||
$('#searchText').typeahead({
|
||||
source: function(query,process) {
|
||||
|
||||
var sourceArray = new Array();
|
||||
$(".accordion:visible a[target='mainFrame']").each(function(){
|
||||
|
||||
sourceArray.push($(this).parents("li").attr("menu-name")+"_"+$(this).parents("li").attr("menu-id"));
|
||||
})
|
||||
|
||||
return process(sourceArray)
|
||||
},
|
||||
setValue:function(item){
|
||||
},
|
||||
items: 8,
|
||||
matcher:function(term){
|
||||
var mod1 = pinyin.getPY_Header(term);
|
||||
var mod2 = pinyin.getPY_All(term);
|
||||
var mod3 = term;
|
||||
var s1 = mod1.toUpperCase().indexOf(this.query.toUpperCase())!=-1;
|
||||
var s2 = mod2.toUpperCase().indexOf(this.query.toUpperCase())!=-1;
|
||||
var s3 = mod3.toUpperCase().indexOf(this.query.toUpperCase())!=-1;
|
||||
|
||||
return (s1||s2||s3);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
$("#searchText").click(function(){
|
||||
$(this).val("");
|
||||
});
|
||||
|
||||
});
|
||||
//面包屑导航
|
||||
$(function(){
|
||||
/* $(function(){
|
||||
|
||||
$("div ul li a").click(function(){
|
||||
if(typeof $(this).attr("id") !='undefined'){
|
||||
@@ -43,7 +78,61 @@
|
||||
// var ur="${ctx}"+urlto.split("nis")[1];
|
||||
// $("#menutwo").attr("href",ur);
|
||||
})
|
||||
})
|
||||
}) */
|
||||
|
||||
//页面跳转函数 level:级别,1顶级,2有子级。name:菜单名称,有多级#间隔。url:访问路径。object:点击元素对象。
|
||||
function page_turn(id, level, name, url,obj){
|
||||
var $object = $("#menu_"+id);//点击当前级别
|
||||
$(".page-sidebar li").filter(".active,.open").removeClass("active open");//删除选中样式
|
||||
|
||||
var $header = $(".page-breadcrumb");//添加头部信息
|
||||
$(".page-breadcrumb").empty();
|
||||
|
||||
|
||||
var parent_li = $object.parents("li");
|
||||
var parent_parent_li = $object.parents("li").parents("li");
|
||||
|
||||
var breadcrumb = $(".accordion:visible").attr("menu-name");
|
||||
if(level==1){//一级菜单
|
||||
breadcrumb += "#"+$object.attr("menu-name");
|
||||
}else if(level==2){//二级菜单
|
||||
parent_li.addClass("active open");
|
||||
breadcrumb += "#"+parent_li.attr("menu-name")+"#"+$object.attr("menu-name");
|
||||
}else if(level==3){//三级
|
||||
parent_li.addClass("active open");
|
||||
parent_parent_li.addClass("active open");
|
||||
breadcrumb += "#"+parent_parent_li.attr("menu-name")+"#"+parent_li.attr("menu-name")+"#"+$object.attr("menu-name");
|
||||
}
|
||||
$object.addClass("active");
|
||||
|
||||
|
||||
|
||||
$header.append("<li><a href='index.html'><spring:message code='home'></spring:message></a> <i class='fa fa-circle'></i></li>");
|
||||
var breadcrumbs = breadcrumb.split("#");
|
||||
for(var i=0;i<breadcrumbs.length;i++) {
|
||||
var circle="";
|
||||
if(i!=breadcrumbs.length-1) {
|
||||
circle = " <i class='fa fa-circle'></i>";
|
||||
}
|
||||
$header.append("<li><a href='javascript:void(0);'>"+breadcrumbs[i]+"</a>"+circle+"</li>");
|
||||
}
|
||||
|
||||
//调入页面
|
||||
window.frames['mainFrame'].location=url;
|
||||
|
||||
App.scrollTo()
|
||||
|
||||
}
|
||||
|
||||
function searchMenu() {
|
||||
var search_txt = $("#searchText").val();
|
||||
if(search_txt.indexOf('_')!=-1){
|
||||
search_txt = search_txt.substring(search_txt.lastIndexOf('_'));
|
||||
$("#menu"+search_txt+" >a").trigger('click');
|
||||
}else {
|
||||
alert('未找到该菜单!');
|
||||
}
|
||||
}
|
||||
|
||||
</script>
|
||||
</head>
|
||||
@@ -193,14 +282,13 @@
|
||||
</li>
|
||||
|
||||
<li class="sidebar-search-wrapper">
|
||||
<form class="sidebar-search " action="page_general_search_3.html"
|
||||
method="POST">
|
||||
<form class="sidebar-search">
|
||||
<a href="javascript:;" class="remove"> <i class="icon-close"></i>
|
||||
</a>
|
||||
<div class="input-group">
|
||||
<input class="form-control" placeholder="Search..." type="text">
|
||||
<input class="form-control" autocomplete="off" spellcheck="false" placeholder="Search..." type="text" id="searchText">
|
||||
<span class="input-group-btn"> <a href="javascript:;"
|
||||
class="btn submit"> <i class="icon-magnifier"></i>
|
||||
class="btn" onclick="searchMenu();"> <i class="icon-magnifier"></i>
|
||||
</a>
|
||||
</span>
|
||||
</div>
|
||||
@@ -225,10 +313,7 @@
|
||||
|
||||
<div class="page-bar">
|
||||
<ul class="page-breadcrumb">
|
||||
<li><a href="index.html">Home</a> <i class="fa fa-circle"></i>
|
||||
</li>
|
||||
<li><a href="#" id="menutwo" target="mainFrame">Tables</a> <i class="fa fa-circle"></i></li>
|
||||
<li><span id="menuthree">Datatables</span></li>
|
||||
<li><a href="index.html"><spring:message code="home"></spring:message></a> <i class="fa fa-circle"></i></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -0,0 +1,205 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8" %>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css" href="${ctxStatic}/pages/css/dictInfo.css" />
|
||||
<script type="text/javascript" src="${ctxStatic}/pages/scripts/specificServiceForm/specificServiceFormCfg.js"></script>
|
||||
<title></title>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
jQuery.validator.addMethod("maxValue", function(value, element) {
|
||||
return value >=0&&value<210000000;
|
||||
}, "请填写正确的协议id");
|
||||
//校验叶子节点无上级不得选为叶子节点
|
||||
jQuery.validator.addMethod("leafHasTree",function(value,element){
|
||||
var flagLeafHasTree=false;
|
||||
$.ajax({
|
||||
type:'post',
|
||||
async:false,
|
||||
url:'${ctx}/specific/specificServiceCfg/ajaxLeafHasTree',
|
||||
data:{parentId:$("#specificServiceCfgId").val(),newIsLeaf:$("#isLeaf option:selected").val()},
|
||||
success:function(data){
|
||||
flagLeafHasTree=data;
|
||||
}
|
||||
});
|
||||
return flagLeafHasTree;
|
||||
},"该配置上级为根节点,不得设为叶子节点");
|
||||
|
||||
//校验叶子节点有下级不得更改为叶子节点
|
||||
jQuery.validator.addMethod("leafChange",function(value,element){
|
||||
var flagLeafChange=false;
|
||||
$.ajax({
|
||||
type:'post',
|
||||
async:false,
|
||||
url:'${ctx}/specific/specificServiceCfg/ajaxLeafChange',
|
||||
data:{parent:"${specificServiceCfg.specServiceId}",newIsLeaf:$("#isLeaf option:selected").val()},
|
||||
success:function(data){
|
||||
flagLeafChange=data;
|
||||
}
|
||||
});
|
||||
return flagLeafChange;
|
||||
},"该配置包含下级配置,不得改为叶子节点");
|
||||
|
||||
$("#name").focus();
|
||||
$("#inputForm").validate({
|
||||
rules:{
|
||||
specServiceId:{
|
||||
required:true,
|
||||
digits:true,
|
||||
maxValue: true,
|
||||
remote:'${ctx}/specific/specificServiceCfg/isIdRepeat?oldId=${specificServiceCfg.specServiceId}'
|
||||
},
|
||||
specServiceName:{
|
||||
required:true
|
||||
},
|
||||
groupId:{
|
||||
digits:true,
|
||||
maxValue:true
|
||||
},
|
||||
isLeaf:{
|
||||
leafHasTree:true,
|
||||
leafChange:true
|
||||
}
|
||||
},
|
||||
messages: {
|
||||
specServiceId:{
|
||||
required:'请填写协议ID',
|
||||
digits:"请填写整数数字",
|
||||
maxValue: "请填写正确的协议ID(0~210000000)",
|
||||
remote:'该协议ID已存在'
|
||||
},
|
||||
specServiceName:{
|
||||
required:'请填写协议名称'
|
||||
},
|
||||
groupId:{
|
||||
digits:'请填写整数数值',
|
||||
maxValue:'请填写正确的分组Id(0~210000000)'
|
||||
},
|
||||
isLeaf:{
|
||||
leafHasTree:'该配置上级为根节点,不得设为叶子节点',
|
||||
leafChange:'该配置包含下级配置,不得改为叶子节点'
|
||||
}
|
||||
},
|
||||
|
||||
submitHandler: function(form){
|
||||
if(!validateItem()) {
|
||||
return false;
|
||||
}
|
||||
loading('正在提交,请稍等...');
|
||||
form.submit();
|
||||
},
|
||||
errorContainer: "#messageBox",
|
||||
errorPlacement: function(error, element) {
|
||||
$("#messageBox").text("输入有误,请先更正。");
|
||||
if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
|
||||
error.appendTo(element.parent().parent());
|
||||
} else {
|
||||
error.insertAfter(element);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
|
||||
<button type="button" class="btn btn-default" onclick="history.go(-1)"><spring:message code="back"/></button>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="specific_service_cfg"/>
|
||||
</h3>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i><shiro:hasPermission name="sys:menu:edit">${not empty specificServiceCfg.specServiceId?'修改':'添加'}</shiro:hasPermission><shiro:lacksPermission name="sys:menu:edit"><spring:message code="show"/></shiro:lacksPermission></div>
|
||||
<div class="tools">
|
||||
<!-- <a href="javascript:;" class="collapse"> </a>
|
||||
<a href="#portlet-config" data-toggle="modal" class="config"> </a>
|
||||
<a href="javascript:;" class="reload"> </a>
|
||||
<a href="javascript:;" class="remove"> </a> -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="portlet-body form">
|
||||
|
||||
|
||||
<div class="form-body">
|
||||
|
||||
<!-- BEGIN FORM-->
|
||||
<form:form id="inputForm" modelAttribute="specificServiceCfg" action="${ctx}/specific/specificServiceCfg/saveOrUpdate" method="post" class="form-horizontal">
|
||||
<input name="oldId" type="hidden" value="${specificServiceCfg.specServiceId}"/>
|
||||
<form:hidden path="isValid" class="form-control"/>
|
||||
<sys:message content="${message}"/>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><spring:message code="superior_config"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<sys:treeselect id="specificServiceCfg" name="parent.specServiceId" value="${specificServiceCfg.parent.specServiceId}" labelName="parent.specServiceName" labelValue="${specificServiceCfg.parent.specServiceName eq '根节点'?'根节点':fns:getBySpecServiceId(specificServiceCfg.parent.specServiceId).specServiceName}"
|
||||
title="菜单" url="/specific/specificServiceCfg/treeData" extId="${specificServiceCfg.specServiceId}" cssClass="required form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议ID:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="specServiceId" name="specServiceId" maxlength="50" class="form-control" value="${specificServiceCfg.specServiceId}"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议名称:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="specServiceName" htmlEscape="false" maxlength="50" class="form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">maat端配置分组id:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="groupId" htmlEscape="false" maxlength="50" class="form-control" placeholder="0"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="is_leaf"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<form:select path="isLeaf" class="form-control">
|
||||
<form:options items="${fns:getDictList('SYS_YES_NO')}" itemLabel="itemValue" itemValue="itemCode" htmlEscape="false"/>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">协议描述:</label>
|
||||
<div class="col-md-4">
|
||||
<form:textarea path="specServiceDesc" htmlEscape="false" maxlength="2000" class="form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
<div class="col-md-offset-3 col-md-9">
|
||||
<shiro:hasPermission name="sys:menu:edit"><button type="submit" class="btn btn-circle blue"><spring:message code="submit"/></button></shiro:hasPermission>
|
||||
<button type="button" class="btn btn-circle grey-salsa btn-outline" onclick="history.go(-1)"><spring:message code="cancel"/></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
<!-- END FORM-->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,97 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8" %>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css" href="${ctxStatic}/pages/css/dictInfo.css" />
|
||||
<script type="text/javascript" src="${ctxStatic}/pages/scripts/dict.js"></script>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
|
||||
<button type="button" class="btn btn-default" onclick="history.go(-1)"><spring:message code="back"/></button>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="specific_service_cfg"/>
|
||||
</h3>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i><spring:message code="show"/></div>
|
||||
<div class="tools">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="portlet-body form">
|
||||
|
||||
|
||||
<div class="form-body">
|
||||
<!-- BEGIN FORM-->
|
||||
<form:form id="inputForm" modelAttribute="specificServiceCfg" class="form-horizontal">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><spring:message code="superior_config"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${specificServiceCfg.parent.specServiceId == 0?'根节点':fns:getBySpecServiceId(specificServiceCfg.parent.specServiceId).specServiceName}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议ID:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="specServiceId" name="specServiceId" maxlength="50" class="form-control" value="${specificServiceCfg.specServiceId}" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议名称:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="specServiceName" htmlEscape="false" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>maat端配置分组id:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="groupId" htmlEscape="false" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="is_leaf"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${fns:getDictLabel('SYS_YES_NO',specificServiceCfg.isLeaf,'0')}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="is_leaf"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="<fmt:formatDate value='${specificServiceCfg.opTime}' pattern='yyyy-MM-dd HH:mm:ss'/>" maxlength="50" class="form-control" readonly="readonly" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">协议描述:</label>
|
||||
<div class="col-md-4">
|
||||
<form:textarea path="specServiceDesc" htmlEscape="false" maxlength="2000" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
<!-- END FORM-->
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,286 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8"%>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<title></title>
|
||||
<link href="${ctxStatic}/global/plugins/treeTable/themes/vsStyle/treeTable.min.css" rel="stylesheet" type="text/css" />
|
||||
<script src="${ctxStatic}/global/plugins/treeTable/jquery.treeTable.min.js" type="text/javascript"></script>
|
||||
<script src="${ctxStatic}/pages/scripts/dict.js" type="text/javascript"></script>
|
||||
<style type="text/css">
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
function reset(){
|
||||
$("#searchForm").reset();
|
||||
}
|
||||
|
||||
/**
|
||||
处理全选、全取消
|
||||
**/
|
||||
function selectAll(){
|
||||
//alert($("#selAll").prop("checked"));
|
||||
if($("#selAll").prop("checked")){
|
||||
//$("#treeTable").find(":checkbox[name='check']").attr("checked","checked");
|
||||
//$("#treeTable").find(":checkbox[name='check']").each(function(){
|
||||
$("input[name='check']:checkbox").each(function(){
|
||||
$(this).prop("checked",true);
|
||||
});
|
||||
|
||||
|
||||
}else{
|
||||
//$("#treeTable").find(":checkbox[name='check']").attr("checked",false);
|
||||
//$("#treeTable").find(":checkbox[name='check']").each(function(){
|
||||
$("input[name='check']:checkbox").each(function(){
|
||||
//$(this).attr("checked",false);
|
||||
$(this).removeProp("checked");
|
||||
});
|
||||
}
|
||||
}
|
||||
/*
|
||||
系统通用方法,根据参数来决定处理的url和参数
|
||||
*/
|
||||
function cmd(){
|
||||
var url=arguments[0];
|
||||
var mulitId="";
|
||||
jQuery("#treeTable").find(":checkbox:checked[name='check']").each(function(){
|
||||
if(jQuery(this).val()!=""){
|
||||
mulitId+=jQuery(this).val()+",";
|
||||
}
|
||||
});
|
||||
if(mulitId!=""){
|
||||
confirmx('您确认要执行该操作?', url+"?mulitId="+mulitId);
|
||||
}else{
|
||||
alert("至少选择一条数据记录");
|
||||
}
|
||||
}
|
||||
function casec(){
|
||||
if($("#intype").attr("name")=="specServiceId"||$("#intype").attr("name")=="groupId"){
|
||||
if(isNaN($("#intype").val())){
|
||||
$("#showError").show();
|
||||
return false;
|
||||
}else{
|
||||
$("#showError").hide();
|
||||
//alert(11);
|
||||
return true;
|
||||
}
|
||||
}else{
|
||||
$("#showError").hide();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
//查询
|
||||
function page(n,s){
|
||||
//$("#intype").attr("name",$("#seltype").val());
|
||||
$("#pageNo").val(n);
|
||||
$("#pageSize").val(s);
|
||||
$("#searchForm").attr("action","${ctx}/specific/specificServiceCfg/list");
|
||||
if(!casec()){
|
||||
return false;
|
||||
}
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
$(document).ready(function() {
|
||||
|
||||
//reset
|
||||
$("#resetBtn").on("click",function(){
|
||||
$(".Wdate").attr("value",'');
|
||||
$("#searchForm")[0].reset();
|
||||
});
|
||||
|
||||
//设定显示总条数
|
||||
$("#showTotalCount").text('${showTotalCount}');
|
||||
//条件回传
|
||||
$("#seltype").find("option[value=${searchType==null?11:searchType}]").attr("selected",true);
|
||||
$("#intype").attr("name",$("#seltype").find("option:selected").val());
|
||||
$("#intype").val('${searchContent}');
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
$("#seltype").change(function(){
|
||||
$("#intype").val("");
|
||||
$("#intype").attr("placeholder","请输入"+$(this).find("option:selected").text());
|
||||
$("#intype").attr("name",$(this).find("option:selected").val());
|
||||
$("#showError").hide();
|
||||
});
|
||||
$("#treeTable").treeTable({expandLevel : 3}).show();
|
||||
});
|
||||
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.dropdown-menu {
|
||||
min-width: 70px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="page-content">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/specific/specificServiceCfg/form'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"></spring:message>配置</button>
|
||||
</div>
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="specific_service_cfg"/>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
</h3>
|
||||
|
||||
<h5 class="page-header"></h5>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="portlet">
|
||||
|
||||
<div class="portlet-body">
|
||||
|
||||
<div class="row" >
|
||||
<form:form id="searchForm" modelAttribute="specificServiceCfg" action="${ctx}/specific/specificServiceCfg/list" method="post" class="form-search">
|
||||
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
|
||||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||||
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${specificServiceCfg.isFilterAction}"/>
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
<div class="pull-left">
|
||||
<div class="input-group">
|
||||
<div class="input-group-btn">
|
||||
<select id="seltype" class="selectpicker select2 input-middle" >
|
||||
<option value="specServiceId">协议ID</option>
|
||||
<option value="specServiceName">协议名称</option>
|
||||
<option value="groupId">maat端配置分组ID</option>
|
||||
</select>
|
||||
</div>
|
||||
<input id="intype" class="form-control input-medium" placeholder="请输入协议ID" type="text" onchange="casec()">
|
||||
<div class="input-group-btn">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="page()"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="pull-left" style="margin-top:10px;display:none" id="showError">
|
||||
<label class="error">请填写整数</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn btn-default" id="filter-btn"> 筛选 <i class="fa fa-angle-double-down"></i></button>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="pull-right">
|
||||
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/specific/specificServiceCfg/form')">
|
||||
<i class="fa fa-edit"></i> 编辑</button>
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/specific/specificServiceCfg/delete')">
|
||||
<i class="fa fa-trash"></i> 删除</button>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title="自定义列字段" href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /搜索内容与操作按钮栏-->
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- 筛选搜索内容栏默认隐藏-->
|
||||
<div class="col-md-12 filter-action-select-panle hide" >
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label>操作时间:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="beginDate" name="beginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceCfg.beginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<label>到</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="endDate" name="endDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceCfg.endDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h5 class="page-header"></h5>
|
||||
<div class="row">
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page()"> <i class="fa fa-search"></i> 搜索 </button>
|
||||
<button type="button" id="resetBtn" class="btn btn-default" onclick="reset()"> <i class="fa fa-refresh"></i> 重置 </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- /筛选搜索内容栏 结束-->
|
||||
|
||||
</form:form>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="treeTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" class="ckboxs" id="selAll" onclick="selectAll()"></th>
|
||||
<th>序号</th>
|
||||
<th>协议ID</th>
|
||||
<th>协议名称</th>
|
||||
<th>协议描述</th>
|
||||
<th>maat端配置分组id</th>
|
||||
<th><spring:message code="is_leaf"/></th>
|
||||
<th class="sort-column op_time">操作时间</th>
|
||||
<%-- <shiro:hasPermission name="sys:menu:edit"><th><spring:message code="operation"/></th></shiro:hasPermission>
|
||||
--%> </tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${list}" var="specificServiceCfg" varStatus="ss">
|
||||
<tr id="${specificServiceCfg.specServiceId}" pId="${specificServiceCfg.parent.specServiceId ne 0?specificServiceCfg.parent.specServiceId:0}">
|
||||
<td><input type="checkbox" class="ckbox" name="check" value="${specificServiceCfg.specServiceId}"></td>
|
||||
<td>${specificServiceCfg.showSequence}</td>
|
||||
<td nowrap><i class="icon-icon-tablet"></i><a href="${ctx}/specific/specificServiceCfg/form?specServiceId=${specificServiceCfg.specServiceId}&doAction=0">${specificServiceCfg.specServiceId}</a></td>
|
||||
<td title="${specificServiceCfg.specServiceName}">${specificServiceCfg.specServiceName}</td>
|
||||
<td title="${specificServiceCfg.specServiceDesc}">${fns:abbr(specificServiceCfg.specServiceDesc,15)}</td>
|
||||
<td>${specificServiceCfg.groupId }</td>
|
||||
<td>${fns:getDictLabel("SYS_YES_NO",specificServiceCfg.isLeaf,"0")}</td>
|
||||
<td><fmt:formatDate value="${specificServiceCfg.opTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
|
||||
<%-- <td>
|
||||
<div class="btn-group btn-xs">
|
||||
<a class="btn btn-primary btn-xs dropdown-toggle" data-toggle="dropdown" href="#"><spring:message code="operation"/><span class="caret"></span></a>
|
||||
<ul class="dropdown-menu btn-xs">
|
||||
<li><a href="${ctx}/specific/specificServiceCfg/form?mulitId=${specificServiceCfg.specServiceId}&doAction=0"><spring:message code="show"/></a></li>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/specific/specificServiceCfg/form?mulitId=${specificServiceCfg.specServiceId}" onclick="return confirmx('您确认要修改该项配置吗?', this.href)"><spring:message code="edit"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
<shiro:hasPermission name="sys:dict:edit">
|
||||
<li><a href="${ctx}/specific/specificServiceCfg/delete?mulitId=${specificServiceCfg.specServiceId}" onclick="return confirmx('您确认要删除该项配置吗?', this.href)"><spring:message code="delete"/></a></li>
|
||||
</shiro:hasPermission>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</td> --%>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="page">${page}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,436 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8"%>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" type="text/css"
|
||||
href="${ctxStatic}/pages/css/dictInfo.css" />
|
||||
<script type="text/javascript" src="${ctxStatic}/pages/scripts/dict.js"></script>
|
||||
<title></title>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$("[data-toogle='tooltip']").tooltip();
|
||||
$("select[name='ipType']").on("change",function(){
|
||||
var type=$(this).val();
|
||||
if(4==type){
|
||||
$("input[name='srcIpMask']").attr("placeholder","任意掩码请填0.0.0.0,无掩码请填255.255.255.255");
|
||||
$("input[name='dstIpMask']").attr("placeholder","任意掩码请填0.0.0.0,无掩码请填255.255.255.255");
|
||||
$("input[name='srcIp']").attr("placeholder","任意ip请填0.0.0.0");
|
||||
$("input[name='dstIp']").attr("placeholder","任意ip请填0.0.0.0");
|
||||
$("input[name='srcIpMask']").attr("title","任意掩码请填0.0.0.0,无掩码请填255.255.255.255");
|
||||
$("input[name='dstIpMask']").attr("title","任意掩码请填0.0.0.0,无掩码请填255.255.255.255");
|
||||
$("input[name='srcIp']").attr("title","任意ip请填0.0.0.0");
|
||||
$("input[name='dstIp']").attr("title","任意ip请填0.0.0.0");
|
||||
}
|
||||
if(6==type){
|
||||
$("input[name='srcIpMask']").attr("placeholder","若无请填FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF,任意请填 ::");
|
||||
$("input[name='dstIpMask']").attr("placeholder","若无请填FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF,任意请填 ::");
|
||||
$("input[name='srcIp']").attr("placeholder","任意ip请填 ::");
|
||||
$("input[name='dstIp']").attr("placeholder","任意ip请填 ::");
|
||||
$("input[name='srcIpMask']").attr("title","若无请填FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF,任意请填 ::");
|
||||
$("input[name='dstIpMask']").attr("title","若无请填FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF,任意请填 ::");
|
||||
$("input[name='srcIp']").attr("title","任意ip请填 ::");
|
||||
$("input[name='dstIp']").attr("title","任意ip请填 ::");
|
||||
}
|
||||
});
|
||||
jQuery.validator.addMethod("maxValue",
|
||||
function(value, element) {
|
||||
return value >= 0 && value < 210000000;
|
||||
}, "请填写正确的协议id");
|
||||
//ip地址校验
|
||||
jQuery.validator.addMethod("ip",function(value, element) {
|
||||
var typeInt=$("select[name='ipType']").val();
|
||||
if(typeInt==4){
|
||||
return this.optional(element)||(/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.test(value) && (RegExp.$1 <256 && RegExp.$2<256 && RegExp.$3<256 && RegExp.$4<256));
|
||||
}else if(typeInt==6){
|
||||
return this.optional(element)||/^\s*((([0-9A-Fa-f]{1,4}:){7}(([0-9A-Fa-f]{1,4})|:))|(([0-9A-Fa-f]{1,4}:){6}(:|((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})|(:[0-9A-Fa-f]{1,4})))|(([0-9A-Fa-f]{1,4}:){5}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){4}(:[0-9A-Fa-f]{1,4}){0,1}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){3}(:[0-9A-Fa-f]{1,4}){0,2}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:){2}(:[0-9A-Fa-f]{1,4}){0,3}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(([0-9A-Fa-f]{1,4}:)(:[0-9A-Fa-f]{1,4}){0,4}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(:(:[0-9A-Fa-f]{1,4}){0,5}((:((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})?)|((:[0-9A-Fa-f]{1,4}){1,2})))|(((25[0-5]|2[0-4]\d|[01]?\d{1,2})(\.(25[0-5]|2[0-4]\d|[01]?\d{1,2})){3})))(%.+)?\s*$/.test(value);
|
||||
}}, "请填写正确的IP地址");
|
||||
//ip地址掩码校验
|
||||
jQuery.validator.addMethod("ipMask",function(value, element) {
|
||||
obj=value;
|
||||
var typeInt=$("select[name='ipType']").val();
|
||||
if(typeInt==4){
|
||||
if(obj=="255.255.255.255"){
|
||||
return true;
|
||||
}else{
|
||||
var exp=/^(254|252|248|240|224|192|128|0)\.0\.0\.0|255\.(254|252|248|240|224|192|128|0)\.0\.0|255\.255\.(254|252|248|240|224|192|128|0)\.0|255\.255\.255\.(254|252|248|240|224|192|128|0)$/;
|
||||
var reg = obj.match(exp);
|
||||
if(reg==null){return false;}else{return true}
|
||||
}
|
||||
}else if(typeInt==6){
|
||||
if(obj=="FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF"||obj==0||obj=="::"){
|
||||
return true;
|
||||
}else{return (obj > 0) && ((obj & (obj - 1)) == 0)};
|
||||
}
|
||||
}, "请填写正确的IP地址掩码");
|
||||
$("#name").focus();
|
||||
$("#inputForm")
|
||||
.validate(
|
||||
{
|
||||
rules : {
|
||||
specServiceId:{
|
||||
required:true,
|
||||
digits:true,
|
||||
maxValue:true
|
||||
},
|
||||
srcIp:{
|
||||
required:true,
|
||||
ip:true
|
||||
},
|
||||
dstIp:{
|
||||
required:true,
|
||||
ip:true
|
||||
},
|
||||
srcIpMask:{
|
||||
required:true,
|
||||
ipMask:true
|
||||
},
|
||||
dstIpMask:{
|
||||
required:true,
|
||||
ipMask:true
|
||||
},
|
||||
srcPort:{
|
||||
required:true,
|
||||
digits:true,
|
||||
max: 65535,
|
||||
min: 0
|
||||
},
|
||||
dstPort:{
|
||||
required:true,
|
||||
digits:true,
|
||||
max: 65535,
|
||||
min: 0
|
||||
},
|
||||
srcPortMask:{
|
||||
required:true,
|
||||
digits:true,
|
||||
max: 65535,
|
||||
min: 0
|
||||
},
|
||||
dstPortMask:{
|
||||
required:true,
|
||||
digits:true,
|
||||
max: 65535,
|
||||
min: 0
|
||||
}
|
||||
},
|
||||
messages : {
|
||||
specServiceId:{
|
||||
required:'<spring:message code="required"/>',
|
||||
digits:'请填写整数数值',
|
||||
maxValue:'请填写合适的值(0~210000000)'
|
||||
},
|
||||
srcIp:{
|
||||
required:'<spring:message code="required"/>',
|
||||
ip:'请填写正确的ip'
|
||||
},
|
||||
dstIp:{
|
||||
required:'<spring:message code="required"/>',
|
||||
ip:'请填写正确的ip'
|
||||
},
|
||||
srcIpMask:{
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
dstIpMask:{
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
srcPort:{
|
||||
required:'<spring:message code="required"/>',
|
||||
digits:'请填写整数',
|
||||
max: '数值不得大于65535',
|
||||
min: '数值不得小于0'
|
||||
},
|
||||
dstPort:{
|
||||
required:'<spring:message code="required"/>',
|
||||
digits:'请填写整数',
|
||||
max: '数值不得大于65535',
|
||||
min: '数值不得小于0'
|
||||
},
|
||||
srcPortMask:{
|
||||
required:'<spring:message code="required"/>',
|
||||
digits:'请填写整数',
|
||||
max: '数值不得大于65535',
|
||||
min: '数值不得小于0'
|
||||
},
|
||||
dstPortMask:{
|
||||
required:'<spring:message code="required"/>',
|
||||
digits:'请填写整数',
|
||||
max: '数值不得大于65535',
|
||||
min: '数值不得小于0'
|
||||
}
|
||||
},
|
||||
|
||||
submitHandler : function(form) {
|
||||
if (!validateItem()) {
|
||||
return false;
|
||||
}
|
||||
loading('正在提交,请稍等...');
|
||||
form.submit();
|
||||
},
|
||||
errorContainer : "#messageBox",
|
||||
errorPlacement : function(error, element) {
|
||||
$("#messageBox").text("输入有误,请先更正。");
|
||||
if (element.is(":checkbox")
|
||||
|| element.is(":radio")
|
||||
|| element.parent().is(
|
||||
".input-append")) {
|
||||
error.appendTo(element.parent()
|
||||
.parent());
|
||||
} else {
|
||||
error.insertAfter(element);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
<div class="page-content">
|
||||
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
|
||||
<button type="button" class="btn btn-default"
|
||||
onclick="history.go(-1)">
|
||||
<spring:message code="back" />
|
||||
</button>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="agreement_ip_configuration" />
|
||||
</h3>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i>
|
||||
<shiro:hasPermission name="sys:menu:edit">${not empty specificServiceHostCfg.hostId?'修改':'添加'}</shiro:hasPermission>
|
||||
<shiro:lacksPermission name="sys:menu:edit">
|
||||
<spring:message code="show" />
|
||||
</shiro:lacksPermission>
|
||||
</div>
|
||||
<div class="tools"></div>
|
||||
</div>
|
||||
|
||||
<div class="portlet-body form">
|
||||
|
||||
<div class="form-body">
|
||||
|
||||
<!-- BEGIN FORM-->
|
||||
<form:form id="inputForm" modelAttribute="specificServiceHostCfg" action="${ctx}/specific/specificServiceHostCfg/saveOrUpdate" method="post" class="form-horizontal" >
|
||||
<form:hidden path="hostId" class="form-control" />
|
||||
<sys:message content="${message}" />
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议ID:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="specServiceId" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>方向:</label>
|
||||
<div class="col-md-6">
|
||||
<form:select path="direction" class="selectpicker select2 form-control" >
|
||||
<c:forEach items="${fns:getDictList('SPEC_DIRECTION')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>协议:</label>
|
||||
<div class="col-md-6">
|
||||
<form:select path="protocol" class="selectpicker select2 form-control" >
|
||||
<c:forEach items="${fns:getDictList('SPEC_PROTOCOL')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>ip类型:</label>
|
||||
<div class="col-md-6">
|
||||
<form:select path="ipType" class="selectpicker select2 form-control" >
|
||||
<c:forEach items="${fns:getDictList('SPEC_IP_TYPE')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="col-md-6" style="display:none;">
|
||||
<input name="isAudit" value="1"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>源IP地址:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="srcIp" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意ip请填0.0.0.0" placeholder="任意ip请填0.0.0.0"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>目的IP地址:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="dstIp" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意ip请填0.0.0.0" placeholder="任意ip请填0.0.0.0"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>源地址掩码:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="srcIpMask" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" title="任意掩码请填0.0.0.0,无掩码请填255.255.255.255" data-placement="top" placeholder="任意掩码请填0.0.0.0,无掩码请填255.255.255.255"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>目的地址掩码:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="dstIpMask" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意掩码请填0.0.0.0,无掩码请填255.255.255.255" placeholder="任意掩码请填0.0.0.0,无掩码请填255.255.255.255"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>源端口:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="srcPort" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意端口请填0" placeholder="任意端口请填0"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>目的端口:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="dstPort" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意端口请填0" placeholder="任意端口请填0"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>源端口掩码:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="srcPortMask" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意掩码请填0,无掩码请填65535" placeholder="任意掩码请填0,无掩码请填65535"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>目的端口掩码:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="dstPortMask" htmlEscape="false" maxlength="50" class="form-control" data-toggle="tooltip" data-placement="top" title="任意掩码请填0,无掩码请填65535" placeholder="任意掩码请填0,无掩码请填65535"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%-- <div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>创建人员:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="creator.id" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>配置时间:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="createTime" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>修改人员:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="editor.id" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>修改时间:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="editTime" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>审核人员:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="auditor.id" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>审核时间:</label>
|
||||
<div class="col-md-6">
|
||||
<form:input path="auditTime" htmlEscape="false" maxlength="50" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> --%>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
<div class="col-md-offset-3 col-md-9">
|
||||
<shiro:hasPermission name="sys:menu:edit"><button type="submit" class="btn btn-circle blue"><spring:message code="submit" /></button></shiro:hasPermission>
|
||||
<button type="button" class="btn btn-circle grey-salsa btn-outline" onclick="history.go(-1)"> <spring:message code="cancel" /></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
<!-- END FORM-->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,353 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8"%>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<title><spring:message code="agreement_ip_configuration" /></title>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
//筛选功能初始化
|
||||
filterActionInit();
|
||||
|
||||
$("#isAudit").change(function(){
|
||||
page();
|
||||
});
|
||||
$("#direction").change(function(){
|
||||
page();
|
||||
});
|
||||
$("#protocol").change(function(){
|
||||
page();
|
||||
});
|
||||
$("#ipType").change(function(){
|
||||
page();
|
||||
});
|
||||
//全选及取消
|
||||
$("#checkAll").change(function(){
|
||||
if($("#checkAll").prop("checked")){
|
||||
$("input.i-checks").prop("checked",true);
|
||||
}else{
|
||||
$("input.i-checks").prop("checked",false);
|
||||
}
|
||||
});
|
||||
});
|
||||
function resetx(){
|
||||
$(':input','#searchForm')
|
||||
.not(':button,:submit,:reset,:hidden')
|
||||
.val('')
|
||||
.removeAttr('checked')
|
||||
.removeAttr('selected');
|
||||
$("select.selectpicker").each(function(){
|
||||
$(this).selectpicker('val',$(this).find('option:first').val());
|
||||
$(this).find("option").attr("selected",false);
|
||||
$(this).find("option:first").attr("selected",true);
|
||||
});
|
||||
$("#specServiceId").attr("value","");
|
||||
$("#srcIp").attr("value","");
|
||||
$("#dstIp").attr("value","");
|
||||
|
||||
}
|
||||
//编辑
|
||||
function edit(){
|
||||
var mulitId="";
|
||||
jQuery("#contentTable").find(":checkbox:checked[name='check']").each(function(){
|
||||
if(jQuery(this).val()!=""){
|
||||
mulitId+=jQuery(this).val()+",";
|
||||
}
|
||||
});
|
||||
if(mulitId!=""){
|
||||
confirmx('您确认要执行该操作?', '${ctx}/specific/specificServiceHostCfg/form?hostId='+mulitId.split(",", 1)[0]);
|
||||
}else{
|
||||
alert("至少选择一条数据记录");
|
||||
}
|
||||
}
|
||||
//删除
|
||||
function delAll(){
|
||||
var mulitId="";
|
||||
jQuery("#contentTable").find(":checkbox:checked[name='check']").each(function(){
|
||||
if(jQuery(this).val()!=""){
|
||||
mulitId+=jQuery(this).val()+",";
|
||||
}
|
||||
});
|
||||
if(mulitId!=""){
|
||||
confirmx('您确认要执行该操作?', '${ctx}/specific/specificServiceHostCfg/delete?mulitId='+mulitId);
|
||||
}else{
|
||||
alert("至少选择一条数据记录");
|
||||
}
|
||||
}
|
||||
//查询
|
||||
function page(n,s){
|
||||
$("#pageNo").val(n);
|
||||
$("#pageSize").val(s);
|
||||
$("#searchForm").attr("action","${ctx}/specific/specificServiceHostCfg/list");
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div class="page-content">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/specific/specificServiceHostCfg/form'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"/></button>
|
||||
</div>
|
||||
|
||||
<h3 class="page-title">
|
||||
<spring:message code="agreement_ip_configuration" />
|
||||
<small><spring:message code="date_list"/></small>
|
||||
</h3>
|
||||
|
||||
<h5 class="page-header"></h5>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="portlet">
|
||||
|
||||
<div class="portlet-body">
|
||||
|
||||
<div class="row" >
|
||||
<form:form id="searchForm" modelAttribute="specificServiceHostCfg" action="${ctx}/specific/specificServiceHostCfg/list" method="post" class="form-search">
|
||||
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
|
||||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||||
|
||||
<!-- 筛选按钮展开状态-->
|
||||
<input id="isFilterAction" name="isFilterAction" type="hidden" value="${specificServiceHostCfg.isFilterAction }"/>
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
|
||||
<!-- 搜索内容与操作按钮栏 -->
|
||||
<div class="col-md-12">
|
||||
<%-- <div class="pull-left">
|
||||
<form:select path="isAudit" class="selectpicker select2 input-small" >
|
||||
<form:option value=""><spring:message code="all_states"/></form:option>
|
||||
<c:forEach items="${fns:getDictList('SPEC_AUDIT')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div> --%>
|
||||
<div class="pull-left">
|
||||
<c:set var="spec_service_id">协议ID</c:set>
|
||||
<form:select path="specServiceId" class="selectpicker select2 input-small" title="${spec_service_id}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${listSpecServiceId}" var="specServiceId" >
|
||||
<form:option value="${specServiceId}">${specServiceId}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left" style="margin-right:0px;">
|
||||
<form:select path="ipType" class="selectpicker select2 input-small" >
|
||||
<form:option value="">-请选择ip类型-</form:option>
|
||||
<c:forEach items="${fns:getDictList('SPEC_IP_TYPE')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="src_ip">源Ip地址</c:set>
|
||||
<form:select path="srcIp" class="selectpicker select2 input-small" title="${src_ip}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${listSrcIp}" var="srcIp" >
|
||||
<form:option value="${srcIp}">${srcIp}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<c:set var="dst_ip">目的Ip地址</c:set>
|
||||
<form:select path="dstIp" class="selectpicker select2 input-small" title="${dst_ip}" data-live-search="true" data-live-search-placeholder="search">
|
||||
<c:forEach items="${listDstIp}" var="dstIp" >
|
||||
<form:option value="${dstIp}">${dstIp}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<form:select path="direction" class="selectpicker select2 input-small" >
|
||||
<form:option value="">-请选择方向-</form:option>
|
||||
<c:forEach items="${fns:getDictList('SPEC_DIRECTION')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left" style="margin-right:0px;">
|
||||
<form:select path="protocol" class="selectpicker select2 input-small" >
|
||||
<form:option value="">-请选择协议-</form:option>
|
||||
<c:forEach items="${fns:getDictList('SPEC_PROTOCOL')}" var="dict">
|
||||
<form:option value="${dict.itemCode}">${dict.itemValue}</form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<button class="btn btn-default btn-search" type="button" onclick="return page()"><i class="fa fa-search"></i></button>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn btn-default" id="filter-btn"> 筛选 <i class="fa fa-angle-double-down"></i></button>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="pull-right">
|
||||
<button type="button" class="btn btn-default" onclick="edit()">
|
||||
<i class="fa fa-edit"></i> <spring:message code="edit"></spring:message></button>
|
||||
<button type="button" class="btn btn-default" onclick="delAll()">
|
||||
<i class="fa fa-trash"></i> 删除</button>
|
||||
<%-- <div class="btn-group" >
|
||||
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
||||
<i class="fa fa-wrench"></i> <spring:message code="examine"></spring:message>
|
||||
<i class="fa fa-angle-down"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu pull-right">
|
||||
<li><sys:delRow url="" id="contentTable" label="approved"></sys:delRow></li>
|
||||
<li><sys:delRow url="" id="contentTable" label="unapproved"></sys:delRow></li>
|
||||
<li><sys:delRow url="" id="contentTable" label="cancelPass"></sys:delRow></li>
|
||||
</ul>
|
||||
</div> --%>
|
||||
<a class="btn btn-icon-only btn-default setfields tooltips"
|
||||
data-container="body" data-placement="top" data-original-title="自定义列字段" href="javascript:;">
|
||||
<i class="icon-wrench"></i>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<!-- /搜索内容与操作按钮栏-->
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- 筛选搜索内容栏默认隐藏-->
|
||||
<div class="col-md-12 filter-action-select-panle hide" >
|
||||
<div class="row">
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label>配置时间:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="beginDate" name="beginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate" data-options="buttons:buttons"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.beginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="to"/></label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="endDate" name="endDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.endDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label>修改时间:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="editBeginDate" name="editBeginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.editBeginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="to"/></label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="editEndDate" name="editEndDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.editEndDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="pull-left">
|
||||
<label>审核时间:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="auditBeginDate" name="auditBeginDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.auditBeginDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<label><spring:message code="to"/></label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<input id="auditEndDate" name="auditEndDate" type="text" readonly="readonly" maxlength="20" class="form-control input-small Wdate"
|
||||
value="<fmt:formatDate value="${specificServiceHostCfg.auditEndDate}" pattern="yyyy-MM-dd HH:mm:ss"/>" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss',isShowClear:true});"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h5 class="page-header"></h5>
|
||||
<div class="row">
|
||||
|
||||
<div class="pull-left">
|
||||
<button type="button" class="btn blue" onclick="page()"> <i class="fa fa-search"></i> <spring:message code="search"/> </button>
|
||||
<button type="button" class="btn btn-default" onclick="resetx()"> <i class="fa fa-refresh"></i> <spring:message code="reset"/> </button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- /筛选搜索内容栏 结束-->
|
||||
|
||||
</form:form>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="table-responsive">
|
||||
<sys:message content="${message}"/>
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed text-nowrap">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><input type="checkbox" class="i-checks" id="checkAll"></th>
|
||||
<th>协议id</th>
|
||||
<th>源IP地址</th>
|
||||
<th>源地址掩码</th>
|
||||
<th>源端口</th>
|
||||
<th>源端口掩码</th>
|
||||
<th>目的IP地址</th>
|
||||
<th>目的地址掩码</th>
|
||||
<th>目的端口</th>
|
||||
<th>目的端口掩码</th>
|
||||
<th>方向</th>
|
||||
<th>协议</th>
|
||||
<th>是否审核</th>
|
||||
<th>创建人员</th>
|
||||
<th class="sort-column create_time">配置时间</th>
|
||||
<th>修改人员</th>
|
||||
<th class="sort-column edit_time">修改时间</th>
|
||||
<th isVisible="false">审核人员</th>
|
||||
<th isVisible="false" class="sort-column audit_time">审核时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${page.list}" var="specificServiceHostCfg">
|
||||
<tr>
|
||||
<td><input type="checkbox" class="i-checks" name="check" id="${specificServiceHostCfg.hostId}" value="${specificServiceHostCfg.hostId}"></td>
|
||||
<td>${specificServiceHostCfg.specServiceId }</td>
|
||||
<td title="${specificServiceHostCfg.srcIp}">${fns:abbr(specificServiceHostCfg.srcIp,15)}</td>
|
||||
<td title="${specificServiceHostCfg.srcIpMask}">${fns:abbr(specificServiceHostCfg.srcIpMask,15) }</td>
|
||||
<td>${specificServiceHostCfg.srcPort}</td>
|
||||
<td>${specificServiceHostCfg.srcPortMask}</td>
|
||||
<td title="${specificServiceHostCfg.dstIp}">${fns:abbr(specificServiceHostCfg.dstIp,15) }</td>
|
||||
<td title="${specificServiceHostCfg.dstIpMask}">${fns:abbr(specificServiceHostCfg.dstIpMask,15) }</td>
|
||||
<td>${specificServiceHostCfg.dstPort }</td>
|
||||
<td>${specificServiceHostCfg.dstPortMask }</td>
|
||||
<td>${fns:getDictLabel("SPEC_DIRECTION",specificServiceHostCfg.direction,"0")}</td>
|
||||
<td>${fns:getDictLabel("SPEC_PROTOCOL",specificServiceHostCfg.protocol,"0")}</td>
|
||||
<td>${fns:getDictLabel("SPEC_AUDIT",specificServiceHostCfg.isAudit,"0")}</td>
|
||||
<td>${fns:getUserById(specificServiceHostCfg.creator.id).name}</td>
|
||||
<td><fmt:formatDate value="${specificServiceHostCfg.createTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
|
||||
<td>${fns:getUserById(specificServiceHostCfg.editor.id).name}</td>
|
||||
<td><fmt:formatDate value="${specificServiceHostCfg.editTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
|
||||
<td>${fns:getUserById(specificServiceHostCfg.auditor.id==null?0:specificServiceHostCfg.auditor.id).name}</td>
|
||||
<td><fmt:formatDate value="${specificServiceHostCfg.auditTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="page">${page}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -68,131 +68,158 @@
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<ul class="nav nav-tabs">
|
||||
<li><a href="${ctx}/sys/user/list">用户列表</a></li>
|
||||
<li class="active"><a href="${ctx}/sys/user/form?id=${user.id}">用户
|
||||
<shiro:hasPermission name="sys:user:edit"></shiro:hasPermission>${not empty user.id?'修改':'添加'}
|
||||
<shiro:lacksPermission name="sys:user:edit">查看</shiro:lacksPermission>
|
||||
</a></li>
|
||||
</ul><br/>
|
||||
<div class="page-content">
|
||||
|
||||
<div class="row">
|
||||
<!-- <ul class="nav nav-tabs"> -->
|
||||
<%-- <li><a href="${ctx}/sys/user/list">用户列表</a></li> --%>
|
||||
<%-- <li class="active"><a href="${ctx}/sys/user/form?id=${user.id}">用户 --%>
|
||||
<%-- <shiro:hasPermission name="sys:user:edit"></shiro:hasPermission>${not empty user.id?'修改':'添加'} --%>
|
||||
<%-- <shiro:lacksPermission name="sys:user:edit">查看</shiro:lacksPermission> --%>
|
||||
<!-- </a></li> -->
|
||||
<!-- </ul><br/> -->
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-default" onclick="history.go(-1)"><spring:message code="back"/></button>
|
||||
</div>
|
||||
<h3 class="page-title">
|
||||
<spring:message code="userManage"/>
|
||||
</h3>
|
||||
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i><c:if test="${not empty user.id}"><spring:message code="edit"/></c:if><c:if test="${empty user.id}"><spring:message code="add"/></c:if></div>
|
||||
</div>
|
||||
|
||||
<div class="portlet-body form">
|
||||
<form:form id="inputForm" modelAttribute="sysUser" action="${ctx}/sys/user/saveOrUpdate" method="post" class="form-horizontal">
|
||||
<form:hidden path="id"/>
|
||||
<sys:message content="${message}"/>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">头像:</label>
|
||||
<div class="controls">
|
||||
<div class="form-body">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">头像:</label>
|
||||
<div class="col-md-4">
|
||||
<form:hidden id="nameImage" path="photo" htmlEscape="false" maxlength="255" class="input-xlarge"/>
|
||||
<sys:ckfinder input="nameImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">登录名:</label>
|
||||
<div class="controls">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">登录名:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="oldLoginId" name="oldLoginId" type="hidden" value="${user.loginId}">
|
||||
<c:if test="${not empty user.id}" var="exisitUser">
|
||||
<form:input path="loginId" htmlEscape="false" maxlength="50" readonly="true" class="required userName"/>
|
||||
<form:input path="loginId" htmlEscape="false" maxlength="50" readonly="true" class="required userName form-control"/>
|
||||
</c:if>
|
||||
|
||||
<c:if test="${!exisitUser}">
|
||||
<form:input path="loginId" htmlEscape="false" maxlength="50" class="required userName"/>
|
||||
<form:input path="loginId" htmlEscape="false" maxlength="50" class="required userName form-control"/>
|
||||
</c:if>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label">归属公司:</label>
|
||||
<div class="controls">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">归属公司:</label>
|
||||
<div class="col-md-4">
|
||||
<sys:treeselect id="company" name="company.id" value="${user.company.id}" labelName="company.name" labelValue="${user.company.name}"
|
||||
title="公司" url="/sys/office/treeData?type=1" cssClass="required" notAllowSelectRoot="true"/>
|
||||
title="公司" url="/sys/office/treeData?type=1" cssClass="required form-control" notAllowSelectRoot="true"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">归属单位:</label>
|
||||
<div class="controls">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">归属单位:</label>
|
||||
<div class="col-md-4">
|
||||
<sys:treeselect id="entity" name="entity.id" value="${user.entity.id}" labelName="entity.name" labelValue="${user.entity.name}"
|
||||
title="单位" url="/sys/office/treeData?type=2" cssClass="required" notAllowSelectRoot="true"/>
|
||||
title="单位" url="/sys/office/treeData?type=2" cssClass="required form-control" notAllowSelectRoot="true"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">归属部门:</label>
|
||||
<div class="controls">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">归属部门:</label>
|
||||
<div class="col-md-4">
|
||||
<sys:treeselect id="office" name="office.id" value="${user.office.id}" labelName="office.name" labelValue="${user.office.name}"
|
||||
title="部门" url="/sys/office/treeData?type=3" cssClass="required" notAllowSelectRoot="true"/>
|
||||
title="部门" url="/sys/office/treeData?type=3" cssClass="required form-control" notAllowSelectRoot="true"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">姓名:</label>
|
||||
<div class="controls">
|
||||
<form:input path="name" htmlEscape="false" maxlength="50" class="required"/>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">姓名:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="name" htmlEscape="false" maxlength="50" class="required form-control"/>
|
||||
</div>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">密码:</label>
|
||||
<div class="controls">
|
||||
<input id="newPassword" name="newPassword" type="password" value="" maxlength="50" minlength="3" class="${empty user.id?'required':''}"/>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">密码:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="newPassword" name="newPassword" type="password" value="" maxlength="50" minlength="3" class="${empty user.id?'required':''} form-control"/>
|
||||
</div>
|
||||
<c:if test="${empty user.id}"><span class="help-inline"><font color="red">*</font> </span></c:if>
|
||||
<c:if test="${not empty user.id}"><span class="help-inline">若不修改密码,请留空。</span></c:if>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">确认密码:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="confirmNewPassword" name="confirmNewPassword" type="password" value="" maxlength="50" minlength="3" equalTo="#newPassword" class="form-control"/>
|
||||
<c:if test="${empty user.id}"></c:if>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label">确认密码:</label>
|
||||
<div class="controls">
|
||||
<input id="confirmNewPassword" name="confirmNewPassword" type="password" value="" maxlength="50" minlength="3" equalTo="#newPassword"/>
|
||||
<c:if test="${empty user.id}"><span class="help-inline"><font color="red">*</font> </span></c:if>
|
||||
</div>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">身份标识:</label>
|
||||
<div class="controls">
|
||||
<form:select path="identity" class="input-medium">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">身份标识:</label>
|
||||
<div class="col-md-4 ">
|
||||
<form:select path="identity" class="selectpicker select2 form-control">
|
||||
<form:option value="0">普通人员</form:option>
|
||||
<form:option value="1">管理人员</form:option>
|
||||
</form:select>
|
||||
<span class="help-inline">管理人员需指定身份标识为“管理人员”,否则影响信访审核流程!</span>
|
||||
</div>
|
||||
<span class="help-inline"><font>管理人员需指定身份标识为“管理人员”,否则影响审核流程!</font></span>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">邮箱:</label>
|
||||
<div class="controls">
|
||||
<form:input path="email" htmlEscape="false" maxlength="100" class="required email"/><span class="help-inline"><font color="red">*</font> </span>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">邮箱:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="email" htmlEscape="false" maxlength="100" class="required email form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">用户角色:</label>
|
||||
<div class="controls">
|
||||
<form:checkboxes path="roleIdList" items="${allRoles}" itemLabel="name" itemValue="id" htmlEscape="false" class="required"/>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">用户角色:</label>
|
||||
<div class="col-md-8">
|
||||
<form:checkboxes path="roleIdList" items="${allRoles}" itemLabel="name" itemValue="id" htmlEscape="false" class="required" style="vertical-align:middle;display:inline-block;margin-bottom:4px"/>
|
||||
<span class="help-inline "><font color="red">*</font> </span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<c:if test="${not empty user.id}">
|
||||
<div class="control-group">
|
||||
<label class="control-label">创建时间:</label>
|
||||
<div class="controls">
|
||||
<label class="lbl"><fmt:formatDate value="${user.createTime}" type="both" dateStyle="full"/></label>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">创建时间:</label>
|
||||
<div class="col-md-4">
|
||||
<label class="lbl form-control"><fmt:formatDate value="${user.createTime}" type="both" dateStyle="full"/></label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</c:if>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
<div class="col-md-offset-3 col-md-9">
|
||||
<shiro:hasPermission name="sys:user:edit"></shiro:hasPermission>
|
||||
<input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>
|
||||
<input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
|
||||
<button type="submit" class="btn btn-circle green"><spring:message code="submit"></spring:message></button>
|
||||
<button type="button" class="btn btn-circle grey-salsa btn-outline" onclick="history.go(-1)"><spring:message code="cancel"></spring:message></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,75 +1,114 @@
|
||||
<%@ page contentType="text/html;charset=UTF-8" %>
|
||||
<%@ page contentType="text/html;charset=UTF-8"%>
|
||||
<%@ include file="/WEB-INF/include/taglib.jsp"%>
|
||||
<html>
|
||||
<head>
|
||||
<title>个人信息</title>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$("#inputForm").validate({
|
||||
submitHandler: function(form){
|
||||
<title>个人信息</title>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(
|
||||
function() {
|
||||
$("#inputForm")
|
||||
.validate(
|
||||
{
|
||||
submitHandler : function(form) {
|
||||
loading('正在提交,请稍等...');
|
||||
form.submit();
|
||||
},
|
||||
errorContainer: "#messageBox",
|
||||
errorPlacement: function(error, element) {
|
||||
errorContainer : "#messageBox",
|
||||
errorPlacement : function(error, element) {
|
||||
$("#messageBox").text("输入有误,请先更正。");
|
||||
if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
|
||||
error.appendTo(element.parent().parent());
|
||||
if (element.is(":checkbox")
|
||||
|| element.is(":radio")
|
||||
|| element.parent().is(
|
||||
".input-append")) {
|
||||
error.appendTo(element.parent()
|
||||
.parent());
|
||||
} else {
|
||||
error.insertAfter(element);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="page-content">
|
||||
<div class="row">
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a href="${ctx}/sys/user/info">个人信息</a></li>
|
||||
<li><a href="${ctx}/sys/user/modifyPwd">修改密码</a></li>
|
||||
</ul><br/>
|
||||
<form:form id="inputForm" modelAttribute="user" action="${ctx}/sys/user/info" method="post" class="form-horizontal">
|
||||
<sys:message content="${message}"/>
|
||||
</ul>
|
||||
<br />
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">头像:</label>
|
||||
<div class="controls">
|
||||
<form:hidden id="nameImage" path="photo" htmlEscape="false" maxlength="255" class="input-xlarge"/>
|
||||
<sys:ckfinder input="nameImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i>
|
||||
<spring:message code="userInfo" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
<form:form id="inputForm" modelAttribute="user"
|
||||
action="${ctx}/sys/user/info" method="post"
|
||||
class="form-horizontal form-striped">
|
||||
<sys:message content="${message}" />
|
||||
<div class="form-body">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">头像:</label>
|
||||
<div class="col-md-4">
|
||||
<form:hidden id="nameImage" path="photo" htmlEscape="false"
|
||||
maxlength="255" class="input-xlarge" />
|
||||
<sys:ckfinder input="nameImage" type="images"
|
||||
uploadPath="/photo" selectMultiple="false" maxWidth="100"
|
||||
maxHeight="100" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">姓名:</label>
|
||||
<div class="controls">
|
||||
<form:input path="name" htmlEscape="false" maxlength="50" class="required" readonly="true"/>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">姓名:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="name" htmlEscape="false" maxlength="50"
|
||||
class="required form-control" readonly="true" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label">邮箱:</label>
|
||||
<div class="controls">
|
||||
<form:input path="email" htmlEscape="false" maxlength="50" class="email"/>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">邮箱:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="email" htmlEscape="false" maxlength="50"
|
||||
class="email form-control" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">用户部门:</label>
|
||||
<div class="controls">
|
||||
<label class="lbl">${user.office.name}</label>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">用户部门:</label>
|
||||
<div class="col-md-4">
|
||||
<label class="lbl control-label">${user.office.name}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="control-group">
|
||||
<label class="control-label">用户角色:</label>
|
||||
<div class="controls">
|
||||
<label class="lbl">${user.roleNames}</label>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">用户角色:</label>
|
||||
<div class="col-md-4">
|
||||
<label class="lbl control-label">${user.roleNames}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-actions">
|
||||
<input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>
|
||||
<div class="row">
|
||||
<div class="col-md-offset-3 col-md-9">
|
||||
<button id="btnSubmit" type="submit" class="btn btn-primary">
|
||||
<spring:message code="submit"></spring:message>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -5,76 +5,178 @@
|
||||
<title>用户管理</title>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$("#btnExport").click(function(){
|
||||
top.$.jBox.confirm("确认要导出用户数据吗?","系统提示",function(v,h,f){
|
||||
if(v=="ok"){
|
||||
$("#searchForm").attr("action","${ctx}/sys/user/export");
|
||||
$("#btnExport").click(function() {
|
||||
top.$.jBox.confirm("确认要导出用户数据吗?", "系统提示", function(v, h, f) {
|
||||
if (v == "ok") {
|
||||
$("#searchForm").attr("action", "${ctx}/sys/user/export");
|
||||
$("#searchForm").submit();
|
||||
}
|
||||
},{buttonsFocus:1});
|
||||
top.$('.jbox-body .jbox-icon').css('top','55px');
|
||||
}, {
|
||||
buttonsFocus : 1
|
||||
});
|
||||
top.$('.jbox-body .jbox-icon').css('top', '55px');
|
||||
});
|
||||
$("#btnImport").click(function() {
|
||||
$.jBox($("#importBox").html(), {
|
||||
title : "导入数据",
|
||||
buttons : {
|
||||
"关闭" : true
|
||||
},
|
||||
bottomText : "导入文件不能超过5M,仅允许导入“xls”或“xlsx”格式文件!"
|
||||
});
|
||||
$("#btnImport").click(function(){
|
||||
$.jBox($("#importBox").html(), {title:"导入数据", buttons:{"关闭":true},
|
||||
bottomText:"导入文件不能超过5M,仅允许导入“xls”或“xlsx”格式文件!"});
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
|
||||
function page(n,s){
|
||||
if(n) $("#pageNo").val(n);
|
||||
if(s) $("#pageSize").val(s);
|
||||
$("#searchForm").attr("action","${ctx}/sys/user/list");
|
||||
function page(n, s) {
|
||||
if (n)
|
||||
$("#pageNo").val(n);
|
||||
if (s)
|
||||
$("#pageSize").val(s);
|
||||
$("#searchForm").attr("action", "${ctx}/sys/user/list");
|
||||
$("#searchForm").submit();
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="page-content">
|
||||
<div id="importBox" class="hide">
|
||||
<form id="importForm" action="${ctx}/sys/user/import" method="post" enctype="multipart/form-data"
|
||||
class="form-search" style="padding-left:20px;text-align:center;" onsubmit="loading('正在导入,请稍等...');"><br/>
|
||||
<input id="uploadFile" name="file" type="file" style="width:330px"/><br/><br/>
|
||||
<input id="btnImportSubmit" class="btn btn-primary" type="submit" value=" 导 入 "/>
|
||||
<a href="${ctx}/sys/user/import/template">下载模板</a>
|
||||
<form id="importForm" action="${ctx}/sys/user/import" method="post"
|
||||
enctype="multipart/form-data" class="form-search"
|
||||
style="padding-left: 20px; text-align: center;"
|
||||
onsubmit="loading('正在导入,请稍等...');">
|
||||
<br /> <input id="uploadFile" name="file" type="file"
|
||||
style="width: 330px" /><br />
|
||||
<br /> <input id="btnImportSubmit" class="btn btn-primary"
|
||||
type="submit" value=" 导 入 " /> <a
|
||||
href="${ctx}/sys/user/import/template">下载模板</a>
|
||||
</form>
|
||||
</div>
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a href="${ctx}/sys/user/list">用户列表</a></li>
|
||||
<shiro:hasPermission name="sys:user:edit"></shiro:hasPermission>
|
||||
<li><a href="${ctx}/sys/user/form">用户添加</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<!-- <ul class="nav nav-tabs"> -->
|
||||
<%-- <li class="active"><a href="${ctx}/sys/user/list">用户列表</a></li> --%>
|
||||
<%-- <shiro:hasPermission name="sys:user:edit"></shiro:hasPermission> --%>
|
||||
<%-- <li><a href="${ctx}/sys/user/form">用户添加</a></li> --%>
|
||||
<!-- </ul> -->
|
||||
|
||||
|
||||
|
||||
<shiro:hasPermission name="sys:user:edit">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<button type="button" class="btn btn-default" onclick="javascript:window.location='${ctx}/sys/user/list'"><spring:message code="refresh"></spring:message></button>
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/sys/user/form'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add" />
|
||||
</button>
|
||||
</div>
|
||||
</shiro:hasPermission>
|
||||
|
||||
<form:form id="searchForm" modelAttribute="sysUser" action="${ctx}/sys/user/list" method="post" class="breadcrumb form-search ">
|
||||
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
|
||||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}" callback="page();"/>
|
||||
<ul class="ul-form">
|
||||
<li><label>归属公司:</label><sys:treeselect id="company" name="company.id" value="${user.company.id}" labelName="company.name" labelValue="${user.company.name}"
|
||||
title="公司" url="/sys/office/treeData?type=1" cssClass="input-small" allowClear="true"/></li>
|
||||
<li><label>登录名:</label><form:input path="loginId" htmlEscape="false" maxlength="50" class="input-medium"/></li>
|
||||
<li><label>姓 名:</label><form:input path="name" htmlEscape="false" maxlength="50" class="input-medium"/></li>
|
||||
<li class="clearfix"></li>
|
||||
<li><label>归属部门:</label><sys:treeselect id="office" name="office.id" value="${user.office.id}" labelName="office.name" labelValue="${user.office.name}"
|
||||
title="部门" url="/sys/office/treeData?type=3" cssClass="input-small" allowClear="true" notAllowSelectParent="true"/></li>
|
||||
<h3 class="page-title">
|
||||
<spring:message code="userManage"></spring:message>
|
||||
<small><spring:message code="date_list" /></small>
|
||||
</h3>
|
||||
|
||||
<li class="btns"><input id="btnSubmit" class="btn btn-primary" type="submit" value="查询" onclick="return page();"/>
|
||||
<input id="btnImport" class="btn btn-success" type="button" value="导入"/>
|
||||
<input id="btnExport" class="btn btn btn-inverse" type="button" value="导出"/>
|
||||
<h5 class="page-header"></h5>
|
||||
|
||||
</li>
|
||||
<!-- 筛选搜索内容栏默认隐藏-->
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<form:form id="searchForm" modelAttribute="sysUser"
|
||||
action="${ctx}/sys/user/list" method="post" class="form-search ">
|
||||
<input id="pageNo" name="pageNo" type="hidden"
|
||||
value="${page.pageNo}" />
|
||||
<input id="pageSize" name="pageSize" type="hidden"
|
||||
value="${page.pageSize}" />
|
||||
<sys:tableSort id="orderBy" name="orderBy" value="${page.orderBy}"
|
||||
callback="page();" />
|
||||
|
||||
<li class="clearfix"></li>
|
||||
<div class="col-md-12 filter-action-select-panle"
|
||||
style="background-color: transparent">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="pull-left">
|
||||
<label>归属公司:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<sys:treeselect id="company" name="company.id"
|
||||
value="${user.company.id}" labelName="company.name"
|
||||
labelValue="${user.company.name}" title="公司"
|
||||
url="/sys/office/treeData?type=1" cssClass="form-control"
|
||||
allowClear="true"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="pull-left">
|
||||
<label>登录名:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<form:input path="loginId" htmlEscape="false" maxlength="50"
|
||||
class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<div class="pull-left">
|
||||
<label>姓名:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<form:input path="name" htmlEscape="false" maxlength="50"
|
||||
class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="pull-left">
|
||||
<label>归属部门:</label>
|
||||
</div>
|
||||
<div class="pull-left">
|
||||
<sys:treeselect id="office" name="office.id" value="${user.office.id}" labelName="office.name"
|
||||
labelValue="${user.office.name}" title="部门"
|
||||
url="/sys/office/treeData?type=3" cssClass="form-control" allowClear="true"
|
||||
notAllowSelectParent="true"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="pull-left">
|
||||
<button type="submit" class="btn blue" onclick="return page();">
|
||||
<i class="fa fa-search"></i>
|
||||
<spring:message code="search" />
|
||||
</button>
|
||||
<button type="reset" class="btn btn-default">
|
||||
<i class="fa fa-refresh"></i>
|
||||
<spring:message code="reset" />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</ul>
|
||||
</form:form>
|
||||
<sys:message content="${message}"/>
|
||||
<table id="contentTable" class="table table-striped table-bordered table-condensed">
|
||||
<thead><tr><th>所属公司</th><th>所属部门</th><th class="sort-column login_id">登录名</th><th class="sort-column name">姓名</th><th>身份标识</th><th>邮箱</th><th>创建时间</th><%--<th>角色</th> --%><shiro:hasPermission name="sys:user:edit"><th>操作</th></shiro:hasPermission></tr></thead>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<sys:message content="${message}" />
|
||||
<table id="contentTable"
|
||||
class="table table-striped table-bordered table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>所属公司</th>
|
||||
<th>所属部门</th>
|
||||
<th class="sort-column login_id">登录名</th>
|
||||
<th class="sort-column name">姓名</th>
|
||||
<th>身份标识</th>
|
||||
<th>邮箱</th>
|
||||
<th>创建时间</th>
|
||||
<%--<th>角色</th> --%>
|
||||
<shiro:hasPermission name="sys:user:edit">
|
||||
<th>操作</th>
|
||||
</shiro:hasPermission>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${page.list}" var="user">
|
||||
<tr>
|
||||
@@ -84,16 +186,18 @@
|
||||
<td>${user.name}</td>
|
||||
<td>${user.identity eq 1 ?'信访办':'办理人员'}</td>
|
||||
<td>${user.email}</td>
|
||||
<td><fmt:formatDate value="${user.createTime}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
|
||||
<td><fmt:formatDate value="${user.createTime}"
|
||||
pattern="yyyy-MM-dd HH:mm:ss" /></td>
|
||||
<shiro:hasPermission name="sys:user:edit"></shiro:hasPermission>
|
||||
<td>
|
||||
<a href="${ctx}/sys/user/form?id=${user.id}">修改</a>
|
||||
<a href="${ctx}/sys/user/delete?id=${user.id}" onclick="return confirmx('确认要删除该用户吗?', this.href)">删除</a>
|
||||
</td>
|
||||
<td><a href="${ctx}/sys/user/form?id=${user.id}">修改</a> <a
|
||||
href="${ctx}/sys/user/delete?id=${user.id}"
|
||||
onclick="return confirmx('确认要删除该用户吗?', this.href)">删除</a></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="pagination">${page}</div>
|
||||
<div class="page">${page}</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -3,7 +3,7 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>修改密码</title>
|
||||
<script type="text/javascript">
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$("#oldPassword").focus();
|
||||
$("#inputForm").validate({
|
||||
@@ -30,37 +30,61 @@
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div class="page-content">
|
||||
<div class="row">
|
||||
<ul class="nav nav-tabs">
|
||||
<li><a href="${ctx}/sys/user/info">个人信息</a></li>
|
||||
<li class="active"><a href="${ctx}/sys/user/modifyPwd">修改密码</a></li>
|
||||
</ul><br/>
|
||||
<div class="col-md-12">
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i>
|
||||
<spring:message code="updatePwd" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
<form:form id="inputForm" modelAttribute="user" action="${ctx}/sys/user/modifyPwd" method="post" class="form-horizontal">
|
||||
<form:hidden path="id"/>
|
||||
<sys:message content="${message}"/>
|
||||
<div class="control-group">
|
||||
<label class="control-label">旧密码:</label>
|
||||
<div class="controls">
|
||||
<input id="oldPassword" name="oldPassword" type="password" value="" maxlength="50" minlength="3" class="required"/>
|
||||
<div class="form-body">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">旧密码:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="oldPassword" name="oldPassword" type="password" value="" maxlength="50" minlength="3" class="required form-control"/>
|
||||
</div>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">新密码:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="newPassword" name="newPassword" type="password" value="" maxlength="50" minlength="3" class="required form-control"/>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label">新密码:</label>
|
||||
<div class="controls">
|
||||
<input id="newPassword" name="newPassword" type="password" value="" maxlength="50" minlength="3" class="required"/>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">确认新密码:</label>
|
||||
<div class="col-md-4">
|
||||
<input id="confirmNewPassword" name="confirmNewPassword" type="password" value="" maxlength="50" minlength="3" class="required form-control" equalTo="#newPassword"/>
|
||||
</div>
|
||||
<div class="control-group">
|
||||
<label class="control-label">确认新密码:</label>
|
||||
<div class="controls">
|
||||
<input id="confirmNewPassword" name="confirmNewPassword" type="password" value="" maxlength="50" minlength="3" class="required" equalTo="#newPassword"/>
|
||||
<span class="help-inline"><font color="red">*</font> </span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/>
|
||||
<div class="row">
|
||||
<div class="col-md-offset-3 col-md-9">
|
||||
<button id="btnSubmit" type="submit" class="btn btn-primary">
|
||||
<spring:message code="submit"></spring:message>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -21575,4 +21575,38 @@ Color library demo
|
||||
}
|
||||
|
||||
|
||||
/*<2A><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʽ*/
|
||||
.sort-column {
|
||||
cursor: pointer;
|
||||
}
|
||||
.sort-column i {
|
||||
top: 2px;
|
||||
position: relative;
|
||||
display: inline-table;
|
||||
}
|
||||
.sort-icon {
|
||||
width: 9px;
|
||||
height: 13px;
|
||||
background-image: url('../img/bee.png');
|
||||
background-position: -232px -59px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
.sort-icon-down {
|
||||
width: 9px;
|
||||
height: 12px;
|
||||
background-image: url('../img/bee.png');
|
||||
background-position: -232px -73px;
|
||||
}
|
||||
|
||||
.sort-icon-up {
|
||||
width: 9px;
|
||||
height: 13px;
|
||||
background-image: url('../img/bee.png');
|
||||
background-position: -232px -86px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
BIN
src/main/webapp/static/global/img/bee.png
Normal file
BIN
src/main/webapp/static/global/img/bee.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 67 KiB |
@@ -0,0 +1,254 @@
|
||||
Bootstrap 3 Typeahead
|
||||
=====================
|
||||
|
||||
For simple autocomplete use cases there seems to be nothing wrong with the dropped typeahead plugin. Here you will find the typeahead autocomplete plugin for Twitter's Bootstrap 2 ready to use with Twitter's Bootstrap 3. The original code is written by [@mdo](http://twitter.com/mdo) and [@fat](http://twitter.com/fat).
|
||||
|
||||
Users who migrate their website or app from Twitter's Bootstrap 2 to Bootstrap 3 can also use this plugin to keep their current autocomplete functions. See for a complete list of migrations steps: [Migrate your templates from Twitter Bootstrap 2.x to Twitter Bootstrap 3](http://bassjobsen.weblogs.fm/migrate-your-templates-from-twitter-bootstrap-2-x-to-twitter-bootstrap-3/)
|
||||
|
||||
With Twitter Bootstrap 3 the typeahead plugin had been dropped. [@mdo](http://twitter.com/mdo) says: "in favor of folks using [Twitter's typeahead](https://github.com/twitter/typeahead.js). Twitter's typeahead has more features than the old bootstrap-typeahead.js and less bugs." Twitter's typeahead don't work direct with Bootstrap 3. The DOM structure of the dropdown menu used by `typeahead.js` differs from the DOM structure of the Bootstrap dropdown menu. You'll need to load some additional CSS in order to get the `typeahead.js` dropdown menu to fit the default Bootstrap theme. Try [extended Bootstrap LESS](https://github.com/bassjobsen/typeahead.js-bootstrap-css) or if your are looking for a more extended version try: [typeahead.js-bootstrap3.less](https://github.com/hyspace/typeahead.js-bootstrap3.less/blob/master/typeahead.less).
|
||||
|
||||
~~`Typeahead.js` doesn't seem ready for the new Twitter Bootstrap 3 at the moment. Code is not up to date and fixes are needed. See also:
|
||||
[Typeahead problems with Bootstrap 3.0 RC1](http://stackoverflow.com/questions/18167246/typeahead-problems-with-bootstrap-3-0-rc1).~~
|
||||
|
||||
Download
|
||||
========
|
||||
|
||||
- Download the latest [bootstrap3-typeahead.js](https://github.com/bassjobsen/Bootstrap-3-Typeahead/blob/master/bootstrap3-typeahead.js) or [bootstrap3-typeahead.min.js](https://github.com/bassjobsen/Bootstrap-3-Typeahead/blob/master/bootstrap3-typeahead.min.js).
|
||||
|
||||
- Include it in your source after jQuery and Bootstrap's JavaScript.
|
||||
|
||||
Full integration with Bootstrap 3 Typeahead
|
||||
-------------------------------------------
|
||||
Download the latest version of Boostrap from [Bootstrap](https://github.com/twbs/bootstrap/archive/master.zip). Copy `bootstrap3-typeahead.js` to the js/ folder. Edit `gruntfile.js` and add `bootstrap3-typeahead.js` to the plugins list.
|
||||
Build your own version with typeahead with `grunt dist`.
|
||||
|
||||
CSS
|
||||
===
|
||||
There is no additional CSS required to use the plugin. Bootstrap's CSS contains all required styles in the `.dropdown-menu` class. The original CSS adds a `z-index` of 1051 to the dropdownmenu via the typeahead class. You could add this if you need it.
|
||||
`.typeahead { z-index: 1051; }` (less or css).
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
<input type="text" data-provide="typeahead">
|
||||
|
||||
You'll want to set `autocomplete="off"` to prevent default browser menus from appearing over the Bootstrap typeahead dropdown.
|
||||
|
||||
Via data attributes
|
||||
-------------------
|
||||
Add data attributes to register an element with typeahead functionality as shown in the example above.
|
||||
|
||||
Via JavaScript
|
||||
--------------
|
||||
|
||||
Call the typeahead manually with:
|
||||
|
||||
$('.typeahead').typeahead()
|
||||
|
||||
Destroys previously initialized typeaheads. This entails reverting DOM modifications and removing event handlers:
|
||||
|
||||
$('.typeahead').typeahead('destroy')
|
||||
|
||||
Javascript Example
|
||||
=============
|
||||
|
||||
Loading a collection
|
||||
--------------------
|
||||
|
||||
$.get('example_collection.json', function(data){
|
||||
$("#name").typeahead({ source:data });
|
||||
},'json');
|
||||
//example_collection.json
|
||||
// ["item1","item2","item3"]
|
||||
|
||||
Using JSON objects instead of simple strings
|
||||
--------------------------------------------
|
||||
|
||||
You can add all the properties you wish on your objects, as long as you provide a "name" attribute OR you provide your own displayText method. The other values allow you to match the selected item with something in your model.
|
||||
|
||||
var $input = $('.typeahead');
|
||||
$input.typeahead({source:[{id: "someId1", name: "Display name 1"},
|
||||
{id: "someId2", name: "Display name 2"}],
|
||||
autoSelect: true});
|
||||
$input.change(function() {
|
||||
var current = $input.typeahead("getActive");
|
||||
if (current) {
|
||||
// Some item from your model is active!
|
||||
if (current.name == $input.val()) {
|
||||
// This means the exact match is found. Use toLowerCase() if you want case insensitive match.
|
||||
} else {
|
||||
// This means it is only a partial match, you can either add a new item
|
||||
// or take the active if you don't want new items
|
||||
}
|
||||
} else {
|
||||
// Nothing is active so it is a new value (or maybe empty value)
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Options
|
||||
=======
|
||||
|
||||
Options can be passed via data attributes or JavaScript. For data attributes, append the option name to `data-`, as in `data-source=""`.
|
||||
|
||||
<table class="table table-bordered table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 100px;">Name</th>
|
||||
<th style="width: 50px;">Type</th>
|
||||
<th style="width: 100px;">Default</th>
|
||||
<th>Description</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>source</td>
|
||||
<td>array, function</td>
|
||||
<td>[ ]</td>
|
||||
<td>The data source to query against. May be an array of strings, an array of JSON object with a name property or a function. The function accepts two arguments, the <code>query</code> value in the input field and the <code>process</code> callback. The function may be used synchronously by returning the data source directly or asynchronously via the <code>process</code> callback's single argument.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>items</td>
|
||||
<td>number</td>
|
||||
<td>8</td>
|
||||
<td>The max number of items to display in the dropdown. Can also be set to 'all'</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>minLength</td>
|
||||
<td>number</td>
|
||||
<td>1</td>
|
||||
<td>The minimum character length needed before triggering autocomplete suggestions. You can set it to 0 so suggestion are shown even when there is no text when lookup function is called.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>showHintOnFocus</td>
|
||||
<td>boolean</td>
|
||||
<td>false</td>
|
||||
<td>If hints should be shown when applicable as soon as the input gets focus.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>scrollHeight</td>
|
||||
<td>number, function</td>
|
||||
<td>0</td>
|
||||
<td>Number of pixels the scrollable parent container scrolled down (scrolled out the viewport).</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>matcher</td>
|
||||
<td>function</td>
|
||||
<td>case insensitive</td>
|
||||
<td>The method used to determine if a query matches an item. Accepts a single argument, the <code>item</code> against which to test the query. Access the current query with <code>this.query</code>. Return a boolean <code>true</code> if query is a match.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>sorter</td>
|
||||
<td>function</td>
|
||||
<td>exact match,<br> case sensitive,<br> case insensitive</td>
|
||||
<td>Method used to sort autocomplete results. Accepts a single argument <code>items</code> and has the scope of the typeahead instance. Reference the current query with <code>this.query</code>.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>updater</td>
|
||||
<td>function</td>
|
||||
<td>returns selected item</td>
|
||||
<td>The method used to return selected item. Accepts a single argument, the <code>item</code> and has the scope of the typeahead instance.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>highlighter</td>
|
||||
<td>function</td>
|
||||
<td>highlights all default matches</td>
|
||||
<td>Method used to highlight autocomplete results. Accepts a single argument <code>item</code> and has the scope of the typeahead instance. Should return html.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>displayText</td>
|
||||
<td>function</td>
|
||||
<td>item.name || item</td>
|
||||
<td>Method used to get textual representation of an item of the sources. Accepts a single argument <code>item</code> and has the scope of the typeahead instance. Should return a String.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>autoSelect</td>
|
||||
<td>boolean</td>
|
||||
<td>true</td>
|
||||
<td>Allows you to dictate whether or not the first suggestion is selected automatically. Turning autoselect off also means that the input won't clear if nothing is selected and <kbd>enter</kbd> or <kbd>tab</kbd> is hit.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>afterSelect</td>
|
||||
<td>function</td>
|
||||
<td>$.noop()</td>
|
||||
<td>Call back function to execute after selected an item. It gets the current active item in parameter if any.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>delay</td>
|
||||
<td>integer</td>
|
||||
<td>0</td>
|
||||
<td>Adds a delay between lookups.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<tr>
|
||||
<td>addItem</td>
|
||||
<td>JSON object</td>
|
||||
<td>false</td>
|
||||
<td>Adds an item to the end of the list, for example "New Entry". This could be used, for example, to pop a dialog when an item is not found in the list of data. Example: <a href="http://cl.ly/image/2u170I1q1G3A/addItem.png">http://cl.ly/image/2u170I1q1G3A/addItem.png</a></td>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Methods
|
||||
=======
|
||||
|
||||
.typeahead(options): Initializes an input with a typeahead.
|
||||
.lookup: To trigger the lookup function externally
|
||||
.getActive: To get the currently active item, you will get a String or a JSOn object depending on how you initialized typeahead. Works only for the first match.
|
||||
|
||||
|
||||
|
||||
Bower
|
||||
=====
|
||||
|
||||
To use with [Bower](http://bower.io/). Add to your bower.json file:
|
||||
|
||||
|
||||
{
|
||||
"name": "MyProject",
|
||||
"dependencies": {
|
||||
"bootstrap3-typeahead": "git@github.com:bassjobsen/Bootstrap-3-Typeahead.git#master"
|
||||
}
|
||||
}
|
||||
|
||||
Bloodhound
|
||||
==========
|
||||
[Bloodhound](https://github.com/twitter/typeahead.js/blob/master/doc/bloodhound.md) is the [typeahead.js](https://github.com/twitter/typeahead.js) suggestion engine, since version 0.10.0. Bloodhound is robust, flexible, and offers advanced functionalities such as prefetching, intelligent caching, fast lookups, and backfilling with remote data. To use Bloodhound with Bootstrap-3-Typeahead:
|
||||
|
||||
// instantiate the bloodhound suggestion engine
|
||||
var numbers = new Bloodhound({
|
||||
datumTokenizer: Bloodhound.tokenizers.whitespace,
|
||||
queryTokenizer: Bloodhound.tokenizers.whitespace,
|
||||
local: ["(A)labama","Alaska","Arizona","Arkansas","Arkansas2","Barkansas"]
|
||||
});
|
||||
|
||||
// initialize the bloodhound suggestion engine
|
||||
numbers.initialize();
|
||||
|
||||
$('.typeahead').typeahead(
|
||||
{
|
||||
items: 4,
|
||||
source:numbers.ttAdapter()
|
||||
});
|
||||
|
||||
|
||||
Bootstrap Tags Input
|
||||
====================
|
||||
[Bootstrap Tags Input](http://timschlechter.github.io/bootstrap-tagsinput/examples/) is a jQuery plugin providing a Twitter Bootstrap user interface for managing tags. Bootstrap Tags Input has a typeahead option which allows you to set the source:
|
||||
|
||||
$('input').tagsinput({
|
||||
typeahead: {
|
||||
source: ['Amsterdam', 'Washington', 'Sydney', 'Beijing', 'Cairo']
|
||||
}
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
$('input').tagsinput({
|
||||
typeahead: {
|
||||
source: function(query) {
|
||||
return $.get('http://someservice.com');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
See also: https://github.com/bassjobsen/Bootstrap-3-Typeahead/issues/40
|
||||
1
src/main/webapp/static/global/plugins/bootstrap-typeahead/bootstrap3-typeahead.min.js
vendored
Normal file
1
src/main/webapp/static/global/plugins/bootstrap-typeahead/bootstrap3-typeahead.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -591,16 +591,32 @@
|
||||
width: 350,
|
||||
height: 'auto',
|
||||
bottomText: '',
|
||||
buttons: { '确定': 'ok' },
|
||||
buttons: { 'ok': 'ok' },
|
||||
buttonsFocus: 0,
|
||||
loaded: function (h) { },
|
||||
submit: function (v, h, f) { return true; },
|
||||
closed: function () { }
|
||||
};
|
||||
//国际化切换
|
||||
var type=navigator.appName;
|
||||
if(type=="Netscape"){
|
||||
var lang = navigator.language;//获取浏览器语言配置支持非IE
|
||||
}else{
|
||||
var lang = navigator.userLanguage;//支持IE
|
||||
}
|
||||
var lang = lang.toLowerCase();
|
||||
if(lang.indexOf("zh")!=-1) {
|
||||
|
||||
$.jBox.stateDefaults = { content: '', buttons: { '确定': 'ok' }, buttonsFocus: 0, submit: function (v, h, f) { return true; } };
|
||||
$.jBox.languageDefaults = { close: '关闭', ok: '确定', yes: '是', no: '否', cancel: '取消' };
|
||||
}else{
|
||||
$.jBox.stateDefaults = { content: '', buttons: { 'ok': 'ok' }, buttonsFocus: 0, submit: function (v, h, f) { return true; } };
|
||||
$.jBox.languageDefaults = { close: 'close', ok: 'ok', yes: 'yes', no: 'no', cancel: 'cancel' };
|
||||
}
|
||||
|
||||
|
||||
$.jBox.tipDefaults = { content: '', icon: 'info', top: '40%', width: 'auto', height: 'auto', opacity: 0, timeout: 3000, closed: function () { } };
|
||||
$.jBox.messagerDefaults = { content: '', title: 'jBox', icon: 'none', width: 350, height: 'auto', timeout: 3000, showType: 'slide', showSpeed: 600, border: 0, buttons: {}, buttonsFocus: 0, loaded: function () { }, submit: function (v, h, f) { return true; }, closed: function () { } };
|
||||
$.jBox.languageDefaults = { close: '关闭', ok: '确定', yes: '是', no: '否', cancel: '取消' };
|
||||
|
||||
$.jBox.setDefaults = function (configs) {
|
||||
$.jBox.defaults = $.extend({}, $.jBox.defaults, configs.defaults);
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
Copyright (c) 2013-2014 Twitter, Inc
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
||||
@@ -1,188 +0,0 @@
|
||||
[](http://travis-ci.org/twitter/typeahead.js)
|
||||
[](http://gruntjs.com/)
|
||||
|
||||
|
||||
[typeahead.js][gh-page]
|
||||
=======================
|
||||
|
||||
Inspired by [twitter.com]'s autocomplete search functionality, typeahead.js is
|
||||
a flexible JavaScript library that provides a strong foundation for building
|
||||
robust typeaheads.
|
||||
|
||||
The typeahead.js library consists of 2 components: the suggestion engine,
|
||||
[Bloodhound], and the UI view, [Typeahead].
|
||||
The suggestion engine is responsible for computing suggestions for a given
|
||||
query. The UI view is responsible for rendering suggestions and handling DOM
|
||||
interactions. Both components can be used separately, but when used together,
|
||||
they can provide a rich typeahead experience.
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[gh-page]: http://twitter.github.io/typeahead.js/
|
||||
[twitter.com]: https://twitter.com
|
||||
[Bloodhound]: https://github.com/twitter/typeahead.js/blob/master/doc/bloodhound.md
|
||||
[Typeahead]: https://github.com/twitter/typeahead.js/blob/master/doc/jquery_typeahead.md
|
||||
|
||||
Getting Started
|
||||
---------------
|
||||
|
||||
How you acquire typeahead.js is up to you.
|
||||
|
||||
Preferred method:
|
||||
* Install with [Bower]: `$ bower install typeahead.js`
|
||||
|
||||
Other methods:
|
||||
* [Download zipball of latest release][zipball].
|
||||
* Download the latest dist files individually:
|
||||
* *[bloodhound.js]* (standalone suggestion engine)
|
||||
* *[typeahead.jquery.js]* (standalone UI view)
|
||||
* *[typeahead.bundle.js]* (*bloodhound.js* + *typeahead.jquery.js*)
|
||||
* *[typeahead.bundle.min.js]*
|
||||
|
||||
**Note:** both *bloodhound.js* and *typeahead.jquery.js* have a dependency on
|
||||
[jQuery] 1.9+.
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[Bower]: http://bower.io/
|
||||
[zipball]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.js.zip
|
||||
[bloodhound.js]: http://twitter.github.com/typeahead.js/releases/latest/bloodhound.js
|
||||
[typeahead.jquery.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.jquery.js
|
||||
[typeahead.bundle.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.bundle.js
|
||||
[typeahead.bundle.min.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.bundle.min.js
|
||||
[jQuery]: http://jquery.com/
|
||||
|
||||
Documentation
|
||||
-------------
|
||||
|
||||
* [Typeahead Docs]
|
||||
* [Bloodhound Docs]
|
||||
|
||||
[Typeahead Docs]: https://github.com/twitter/typeahead.js/blob/master/doc/jquery_typeahead.md
|
||||
[Bloodhound Docs]: https://github.com/twitter/typeahead.js/blob/master/doc/bloodhound.md
|
||||
|
||||
Examples
|
||||
--------
|
||||
|
||||
For some working examples of typeahead.js, visit the [examples page].
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[examples page]: http://twitter.github.io/typeahead.js/examples
|
||||
|
||||
Browser Support
|
||||
---------------
|
||||
|
||||
* Chrome
|
||||
* Firefox 3.5+
|
||||
* Safari 4+
|
||||
* Internet Explorer 7+
|
||||
* Opera 11+
|
||||
|
||||
**NOTE:** typeahead.js is not tested on mobile browers.
|
||||
|
||||
Customer Support
|
||||
----------------
|
||||
|
||||
For general questions about typeahead.js, tweet at [@typeahead].
|
||||
|
||||
For technical questions, you should post a question on [Stack Overflow] and tag
|
||||
it with [typeahead.js][so tag].
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[Stack Overflow]: http://stackoverflow.com/
|
||||
[@typeahead]: https://twitter.com/typeahead
|
||||
[so tag]: http://stackoverflow.com/questions/tagged/typeahead.js
|
||||
|
||||
Issues
|
||||
------
|
||||
|
||||
Discovered a bug? Please create an issue here on GitHub!
|
||||
|
||||
https://github.com/twitter/typeahead.js/issues
|
||||
|
||||
Versioning
|
||||
----------
|
||||
|
||||
For transparency and insight into our release cycle, releases will be numbered
|
||||
with the follow format:
|
||||
|
||||
`<major>.<minor>.<patch>`
|
||||
|
||||
And constructed with the following guidelines:
|
||||
|
||||
* Breaking backwards compatibility bumps the major
|
||||
* New additions without breaking backwards compatibility bumps the minor
|
||||
* Bug fixes and misc changes bump the patch
|
||||
|
||||
For more information on semantic versioning, please visit http://semver.org/.
|
||||
|
||||
Testing
|
||||
-------
|
||||
|
||||
Tests are written using [Jasmine] and ran with [Karma]. To run
|
||||
the test suite with PhantomJS, run `$ npm test`.
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[Jasmine]: http://pivotal.github.com/jasmine/
|
||||
[Karma]: http://karma-runner.github.io/
|
||||
|
||||
Developers
|
||||
----------
|
||||
|
||||
If you plan on contributing to typeahead.js, be sure to read the
|
||||
[contributing guidelines]. A good starting place for new contributors are issues
|
||||
labeled with [entry-level]. Entry-level issues tend to require minor changes
|
||||
and provide developers a chance to get more familiar with typeahead.js before
|
||||
taking on more challenging work.
|
||||
|
||||
In order to build and test typeahead.js, you'll need to install its dev
|
||||
dependencies (`$ npm install`) and have [grunt-cli]
|
||||
installed (`$ npm install -g grunt-cli`). Below is an overview of the available
|
||||
Grunt tasks that'll be useful in development.
|
||||
|
||||
* `grunt build` – Builds *typeahead.js* from source.
|
||||
* `grunt lint` – Runs source and test files through JSHint.
|
||||
* `grunt watch` – Rebuilds *typeahead.js* whenever a source file is modified.
|
||||
* `grunt server` – Serves files from the root of typeahead.js on localhost:8888.
|
||||
Useful for using *test/playground.html* for debugging/testing.
|
||||
* `grunt dev` – Runs `grunt watch` and `grunt server` in parallel.
|
||||
|
||||
<!-- section links -->
|
||||
|
||||
[contributing guidelines]: https://github.com/twitter/typeahead.js/blob/master/CONTRIBUTING.md
|
||||
[entry-level]: https://github.com/twitter/typeahead.js/issues?&labels=entry-level&state=open
|
||||
[grunt-cli]: https://github.com/gruntjs/grunt-cli
|
||||
|
||||
Maintainers
|
||||
-----------
|
||||
|
||||
* **Jake Harding**
|
||||
* [@JakeHarding](https://twitter.com/JakeHarding)
|
||||
* [GitHub](https://github.com/jharding)
|
||||
|
||||
* **You?**
|
||||
|
||||
Authors
|
||||
-------
|
||||
|
||||
* **Jake Harding**
|
||||
* [@JakeHarding](https://twitter.com/JakeHarding)
|
||||
* [GitHub](https://github.com/jharding)
|
||||
|
||||
* **Veljko Skarich**
|
||||
* [@vskarich](https://twitter.com/vskarich)
|
||||
* [GitHub](https://github.com/vskarich)
|
||||
|
||||
* **Tim Trueman**
|
||||
* [@timtrueman](https://twitter.com/timtrueman)
|
||||
* [GitHub](https://github.com/timtrueman)
|
||||
|
||||
License
|
||||
-------
|
||||
|
||||
Copyright 2013 Twitter, Inc.
|
||||
|
||||
Licensed under the MIT License
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1,68 +0,0 @@
|
||||
.twitter-typeahead {
|
||||
width: 100%;
|
||||
display: table !important;
|
||||
}
|
||||
|
||||
.twitter-typeahead .form-control {
|
||||
margin: 0 !important;
|
||||
}
|
||||
|
||||
.tt-hint,
|
||||
.tt-input {
|
||||
color: #999;
|
||||
font-size: 14px;
|
||||
height: 34px;
|
||||
padding: 6px 12px;
|
||||
font-size: 14px;
|
||||
line-height: 1.428571429;
|
||||
width: 100%;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.tt-hint[disabled] {
|
||||
background-color: #fff !important;
|
||||
}
|
||||
|
||||
|
||||
.tt-menu {
|
||||
min-width: 160px;
|
||||
margin-top: 2px;
|
||||
padding: 5px 0;
|
||||
background-color: #fff;
|
||||
border: 1px solid #ebebeb;
|
||||
-webkit-background-clip: padding-box;
|
||||
-moz-background-clip: padding;
|
||||
background-clip: padding-box;
|
||||
width: 100%;
|
||||
overflow-y: auto;
|
||||
max-height: 250px;
|
||||
}
|
||||
|
||||
.tt-menu h3 {
|
||||
margin: 5px 0;
|
||||
padding: 6px 12px;
|
||||
font-size: 18px;
|
||||
font-weight: 700;
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
.modal-open .tt-menu {
|
||||
z-index: 10055 !important;
|
||||
}
|
||||
|
||||
.tt-suggestion {
|
||||
padding: 6px 12px;
|
||||
font-size: 14px;
|
||||
line-height: 16px;
|
||||
}
|
||||
|
||||
.tt-suggestion:hover {
|
||||
cursor: pointer;
|
||||
background: #eee;
|
||||
}
|
||||
|
||||
.tt-suggestion p {
|
||||
margin: 0;
|
||||
}
|
||||
187
src/main/webapp/static/global/plugins/unicodes.js
Normal file
187
src/main/webapp/static/global/plugins/unicodes.js
Normal file
File diff suppressed because one or more lines are too long
@@ -325,13 +325,13 @@ function filterActionInit() {
|
||||
|
||||
function fiterPanleShow() {
|
||||
$("#filter-btn").find("i").removeClass("fa-angle-double-down").addClass("fa-angle-double-up");
|
||||
$(".btn-search").addClass("hide");
|
||||
//$(".btn-search").addClass("hide");
|
||||
$(".filter-action-select-panle").removeClass("hide");
|
||||
}
|
||||
|
||||
function fiterPanleHide() {
|
||||
$("#filter-btn").find("i").removeClass("fa-angle-double-up").addClass("fa-angle-double-down");
|
||||
$(".btn-search").removeClass("hide");
|
||||
//$(".btn-search").removeClass("hide");
|
||||
$(".filter-action-select-panle").addClass("hide");
|
||||
}
|
||||
|
||||
|
||||
@@ -945,7 +945,7 @@
|
||||
background:0 0;
|
||||
margin:0;
|
||||
padding:0;
|
||||
margin-top:1px!important
|
||||
margin-top:2px!important
|
||||
}
|
||||
.page-sidebar .page-sidebar-menu .sub-menu li>a,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu li>a {
|
||||
display:block;
|
||||
@@ -968,7 +968,8 @@
|
||||
.page-sidebar .page-sidebar-menu .sub-menu li>.sub-menu>li>.sub-menu,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu li>.sub-menu>li>.sub-menu {
|
||||
margin:0
|
||||
}
|
||||
.page-sidebar .page-sidebar-menu .sub-menu li>.sub-menu>li>.sub-menu>li>a,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu li>.sub-menu>li>.sub-menu>li>a {
|
||||
.page-sidebar .page-sidebar-menu .sub-menu li>.sub-menu>li>.sub-menu>li>a,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu li>.su
|
||||
b-menu>li>.sub-menu>li>a {
|
||||
padding-left:80px
|
||||
}
|
||||
.page-sidebar .page-sidebar-menu .sub-menu.always-open,.page-sidebar .page-sidebar-menu li.active>.sub-menu,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu.always-open,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu li.active>.sub-menu {
|
||||
@@ -989,7 +990,7 @@
|
||||
padding-bottom:8px
|
||||
}
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light>li .sub-menu li:first-child,.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light>li .sub-menu li:first-child {
|
||||
margin-top:0!important
|
||||
|
||||
}
|
||||
.page-sidebar-reversed .page-sidebar .page-sidebar-menu.page-sidebar-menu-light>li>a,.page-sidebar-reversed .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light>li>a {
|
||||
padding-left:15px;
|
||||
|
||||
@@ -260,8 +260,9 @@
|
||||
/* All links */ }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu > li > a,
|
||||
.page-sidebar .page-sidebar-menu > li > a {
|
||||
border-top: 1px solid #484848;
|
||||
color: #d9d9d9; }
|
||||
color: #fff;
|
||||
border-top: 1px solid #484848 !important;
|
||||
}
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu > li > a > i,
|
||||
.page-sidebar .page-sidebar-menu > li > a > i {
|
||||
color: #888888; }
|
||||
@@ -324,7 +325,7 @@
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu li > a > .arrow:before, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu li > a > .arrow.open:before,
|
||||
.page-sidebar .page-sidebar-menu li > a > .arrow:before,
|
||||
.page-sidebar .page-sidebar-menu li > a > .arrow.open:before {
|
||||
color: #777777; }
|
||||
color: #fff; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu li:hover > a > .arrow:before, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu li:hover > a > .arrow.open:before,
|
||||
.page-sidebar .page-sidebar-menu li:hover > a > .arrow:before,
|
||||
.page-sidebar .page-sidebar-menu li:hover > a > .arrow.open:before {
|
||||
@@ -350,7 +351,7 @@
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu > li > a > .arrow:before, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu > li > a > .arrow.open:before,
|
||||
.page-sidebar .page-sidebar-menu .sub-menu > li > a > .arrow:before,
|
||||
.page-sidebar .page-sidebar-menu .sub-menu > li > a > .arrow.open:before {
|
||||
color: #777777; }
|
||||
color: #fff; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu > li:hover > a, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu > li.open > a, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu .sub-menu > li.active > a,
|
||||
.page-sidebar .page-sidebar-menu .sub-menu > li:hover > a,
|
||||
.page-sidebar .page-sidebar-menu .sub-menu > li.open > a,
|
||||
@@ -376,18 +377,20 @@
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li:hover > a, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.open > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li:hover > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.open > a {
|
||||
background: #424242; }
|
||||
background: #303030; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active > a, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a {
|
||||
background: #474747;
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active > a {
|
||||
background: #303030;
|
||||
border-left: 4px solid #d64635;
|
||||
color: #f1f1f1; }
|
||||
color: #f1f1f1;
|
||||
}
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a {
|
||||
background: #303030;}
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active > a:hover, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a:hover,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active > a:hover,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a:hover {
|
||||
border-left: 4px solid #d64635;
|
||||
background: #424242; }
|
||||
background: #303030; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active > a > i, .page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a > i,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active > a > i,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li.active.open > a > i {
|
||||
@@ -405,7 +408,8 @@
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li .sub-menu > li:hover > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li .sub-menu > li.open > a,
|
||||
.page-sidebar .page-sidebar-menu.page-sidebar-menu-light > li .sub-menu > li.active > a {
|
||||
background: #474747 !important; }
|
||||
color: #ffffff !important;
|
||||
background: #575757 !important; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .sidebar-toggler,
|
||||
.page-sidebar .sidebar-toggler {
|
||||
background: #303030; }
|
||||
@@ -432,10 +436,10 @@
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .sidebar-search .input-group,
|
||||
.page-sidebar .sidebar-search .input-group {
|
||||
border-bottom: 1px solid #484848; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .sidebar-search .input-group .form-control,
|
||||
.page-sidebar-closed.pagek-sidebar-fixed .page-sidebar:hover .sidebar-search .input-group .form-control,
|
||||
.page-sidebar .sidebar-search .input-group .form-control {
|
||||
background-color: #3d3d3d;
|
||||
color: #5c5c5c; }
|
||||
color: #fffdfd; }
|
||||
.page-sidebar-closed.page-sidebar-fixed .page-sidebar:hover .sidebar-search .input-group .form-control::-moz-placeholder,
|
||||
.page-sidebar .sidebar-search .input-group .form-control::-moz-placeholder {
|
||||
color: #5c5c5c;
|
||||
|
||||
@@ -175,7 +175,7 @@ var Layout = function () {
|
||||
'scrollTo': (the.position()).top
|
||||
});
|
||||
} else {
|
||||
App.scrollTo(the, slideOffeset);
|
||||
//App.scrollTo();
|
||||
}
|
||||
}
|
||||
handleSidebarAndContentHeight();
|
||||
@@ -190,7 +190,7 @@ var Layout = function () {
|
||||
'scrollTo': (the.position()).top
|
||||
});
|
||||
} else {
|
||||
App.scrollTo(the, slideOffeset);
|
||||
//App.scrollTo(the, slideOffeset);
|
||||
}
|
||||
}
|
||||
handleSidebarAndContentHeight();
|
||||
|
||||
@@ -39,6 +39,31 @@ var home = function () {
|
||||
}
|
||||
|
||||
|
||||
//点击顶部菜单,默认展开左侧菜单,如果左侧菜单已有被选中的则忽视
|
||||
var left_menu_lis = $(menuId).find("li");
|
||||
if(!(left_menu_lis.hasClass("active") ||
|
||||
left_menu_lis.hasClass("open"))) {
|
||||
var $li1 = $(menuId).find("li:first");
|
||||
var $li2 = $(menuId).find("li:first").find("li:first");
|
||||
|
||||
var hasSubMenu1 = $li1.children().hasClass('sub-menu');
|
||||
if(hasSubMenu1) {
|
||||
$li1.addClass('open');
|
||||
$li1.find('> a > .arrow').addClass('open');
|
||||
$li1.find('> .sub-menu').slideDown();
|
||||
|
||||
var hasSubMenu2 = $li2.children().hasClass('sub-menu');
|
||||
if(hasSubMenu2) {
|
||||
$li2.addClass('open');
|
||||
$li2.find('> a > .arrow').addClass('open');
|
||||
$li2.find('> .sub-menu').slideDown();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
})
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user