Merge branch 'develop' of http://10.0.6.99/gwall/gwall.git into develop
This commit is contained in:
@@ -4,6 +4,9 @@
|
||||
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
|
||||
<dependent-module archiveName="maat-tools-0.0.1-SNAPSHOT.jar" deploy-path="/WEB-INF/lib" handle="module:/classpath/lib/gwall/lib/maat-tools-0.0.1-SNAPSHOT.jar">
|
||||
<dependency-type>uses</dependency-type>
|
||||
</dependent-module>
|
||||
<property name="java-output-path" value="/gk/target/classes"/>
|
||||
<property name="context-root" value="gwall"/>
|
||||
</wb-module>
|
||||
|
||||
@@ -32,7 +32,7 @@ public class ServiceDictInfo extends BaseEntity<ServiceDictInfo>{
|
||||
private SysUser serviceDictEditor; //editor_id 修改人员 int Y 取自sys_user.id
|
||||
private Date editTime; //edit_time 修改时间 date Y
|
||||
private Integer levelNo; //层级
|
||||
private List<ServiceDictInfo> ChildrenList = new ArrayList<ServiceDictInfo>();//子列表
|
||||
private List<ServiceDictInfo> childrenList = new ArrayList<ServiceDictInfo>();//子列表
|
||||
|
||||
private Date beginDate; // 开始日期
|
||||
private Date endDate; // 结束日期
|
||||
@@ -123,11 +123,11 @@ public class ServiceDictInfo extends BaseEntity<ServiceDictInfo>{
|
||||
public void setEditTime(Date editTime) {
|
||||
this.editTime = editTime;
|
||||
}
|
||||
public List<ServiceDictInfo> getChildrenList() {
|
||||
return ChildrenList;
|
||||
public List<ServiceDictInfo> getChildrenList() {
|
||||
return childrenList;
|
||||
}
|
||||
public void setChildrenList(List<ServiceDictInfo> childrenList) {
|
||||
ChildrenList = childrenList;
|
||||
this.childrenList = childrenList;
|
||||
}
|
||||
public Date getBeginDate() {
|
||||
return beginDate;
|
||||
|
||||
@@ -77,23 +77,53 @@ public class ConfigDictUtils {
|
||||
public static String getItemTypeByNo(String dictKey, List intArr){
|
||||
String result = "";
|
||||
String value = DictUtils.getDictLabel(dictKey,intArr.get(0).toString());
|
||||
if(value.trim().equals("分类")){
|
||||
result = "分类";
|
||||
if(value.trim().equals("classification")){
|
||||
result = "classification_manage";
|
||||
}
|
||||
if(value.trim().equals("性质")){
|
||||
result = "性质";
|
||||
if(value.trim().equals("attribute")){
|
||||
result = "attribute_manage";
|
||||
}
|
||||
if(value.trim().equals("标签")){
|
||||
result = "标签";
|
||||
if(value.trim().equals("label")){
|
||||
result = "label_manage";
|
||||
}
|
||||
if(value.trim().equals("地域")){
|
||||
result = "地域";
|
||||
if(value.trim().equals("area")){
|
||||
result = "area_manage";
|
||||
}
|
||||
if(value.trim().equals("运营商")){
|
||||
result = "运营商";
|
||||
if(value.trim().equals("isp")){
|
||||
result = "isp_manage";
|
||||
}
|
||||
if(value.trim().equals("特征作用域")){
|
||||
result = "特征作用域";
|
||||
if(value.trim().equals("scope")){
|
||||
result = "feature_scope_manage";
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据数据类型编码取出权限标识码
|
||||
* @param dictKey
|
||||
* @param intArr
|
||||
* @return
|
||||
*/
|
||||
public static String getPermissionByNo(String dictKey, List intArr){
|
||||
String result = "";
|
||||
String value = DictUtils.getDictLabel(dictKey,intArr.get(0).toString());
|
||||
if(value.trim().equals("classification")){
|
||||
result = "classification";
|
||||
}
|
||||
if(value.trim().equals("attribute")){
|
||||
result = "attribute";
|
||||
}
|
||||
if(value.trim().equals("label")){
|
||||
result = "label";
|
||||
}
|
||||
if(value.trim().equals("area")){
|
||||
result = "area";
|
||||
}
|
||||
if(value.trim().equals("isp")){
|
||||
result = "isp";
|
||||
}
|
||||
if(value.trim().equals("scope")){
|
||||
result = "scope";
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -1,12 +1,14 @@
|
||||
package com.nis.web.controller.basics;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.Logical;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.apache.zookeeper.ZooDefs.Ids;
|
||||
import org.springframework.stereotype.Controller;
|
||||
@@ -67,11 +69,10 @@ public class ServiceDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequiresPermissions(value={"basics:classification:view","basics:attribute:view","basics:label:view"},logical=Logical.OR)
|
||||
@RequestMapping(value = {"list", ""})
|
||||
public String list(String itType, ServiceDictInfo serviceDictInfo,HttpServletRequest request, HttpServletResponse response, Model model,Integer selectedType,boolean isFilterAction) {
|
||||
public String list(String itType, ServiceDictInfo serviceDictInfo,HttpServletRequest request, HttpServletResponse response, Model model) {
|
||||
//处理数据
|
||||
serviceDictInfo.setIsFilterAction(isFilterAction);
|
||||
String[] strArr = itType.split("-");
|
||||
Integer[] intArr = new Integer[strArr.length];
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
@@ -104,7 +105,7 @@ public class ServiceDictInfoController extends BaseController {
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
|
||||
// 删除顶层数据、取出id 优化处理
|
||||
// 删除顶层数据、取出id
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
|
||||
for(ServiceDictInfo tempSe : page.getList()) {
|
||||
@@ -140,6 +141,7 @@ public class ServiceDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions(value={"basics:classification:edit","basics:attribute:edit","basics:label:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value={"form"})
|
||||
public String form(ServiceDictInfo serviceDictInfo, Model model,String doAction,String itType, String mulitId) {
|
||||
if(doAction!=null&&doAction.equals("0")){
|
||||
@@ -156,7 +158,7 @@ public class ServiceDictInfoController extends BaseController {
|
||||
if (serviceDictInfo.getParent() == null || serviceDictInfo.getParent().getServiceDictId() == null||serviceDictInfo.getParent().getServiceDictId() == 0) {
|
||||
ServiceDictInfo parent = new ServiceDictInfo();
|
||||
parent.setServiceDictId(0);
|
||||
parent.setItemValue("根节点");
|
||||
parent.setItemValue("root_node");
|
||||
serviceDictInfo.setParent(parent);
|
||||
}
|
||||
String[] strArr = itType.split("-");
|
||||
@@ -176,16 +178,16 @@ public class ServiceDictInfoController extends BaseController {
|
||||
* @param redirectAttributes
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:edit")
|
||||
@RequiresPermissions(value={"basics:classification:edit","basics:attribute:edit","basics:label:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(ServiceDictInfo serviceDictInfo,Model model, RedirectAttributes redirectAttributes,String itType) {
|
||||
|
||||
try {
|
||||
serviceDictInfoService.saveOrUpdate(serviceDictInfo);
|
||||
addMessage(redirectAttributes, "保存成功");
|
||||
addMessage(redirectAttributes, "save_success");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "保存失败!");
|
||||
addMessage(redirectAttributes, "save_failed");
|
||||
}
|
||||
|
||||
return "redirect:" + adminPath + "/basics/serviceDictInfo/list?itType="+itType;
|
||||
@@ -200,14 +202,15 @@ public class ServiceDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions(value={"basics:classification:edit","basics:attribute:edit","basics:label:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value={"delete"})
|
||||
public String delete(ServiceDictInfo serviceDictInfo, RedirectAttributes redirectAttributes, String itType, String mulitId) {
|
||||
try {
|
||||
serviceDictInfoService.deleteDict(mulitId);
|
||||
addMessage(redirectAttributes, "删除成功");
|
||||
addMessage(redirectAttributes, "delete_success");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "删除失败!");
|
||||
addMessage(redirectAttributes, "delete_failed");
|
||||
}
|
||||
return "redirect:" + adminPath + "/basics/serviceDictInfo/list?itType="+itType;
|
||||
}
|
||||
@@ -228,7 +231,7 @@ public class ServiceDictInfoController extends BaseController {
|
||||
Map<String, Object> map2 = Maps.newHashMap();
|
||||
map2.put("id", 0);
|
||||
map2.put("pId", 0);
|
||||
map2.put("name","根节点");
|
||||
map2.put("name","root_node");
|
||||
//map2.put("placeholder","0");
|
||||
mapList.add(map2);
|
||||
//找出该类型所有的非叶子配置
|
||||
@@ -394,14 +397,42 @@ public class ServiceDictInfoController extends BaseController {
|
||||
}
|
||||
}else{
|
||||
ServiceDictInfo c = serviceDictInfoService.getDictById(currentId);
|
||||
if((p.getLevelNo()+c.getLevelNo())<(max+1)){
|
||||
return true;
|
||||
if(p.getLevelNo()<max){
|
||||
//查出该类所有下级的层级数之和
|
||||
List<ServiceDictInfo> list = serviceDictInfoService.getDictByParentId(currentId);
|
||||
if(list==null||list.size()==0){
|
||||
return true;
|
||||
}
|
||||
List<ServiceDictInfo> resultList = Lists.newArrayList();
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
allTreeNode(1,list,resultList);
|
||||
for(ServiceDictInfo se:resultList){
|
||||
intList.add(se.getLevelNo());
|
||||
}
|
||||
int x = Collections.max(intList);
|
||||
if((p.getLevelNo()+x)<(max+1)){
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 查出所该节点下有树形子节点
|
||||
*/
|
||||
|
||||
void allTreeNode(Integer levelNo, List<ServiceDictInfo> list,List<ServiceDictInfo> resultList){
|
||||
if(list!=null&&list.size()>0){
|
||||
for(ServiceDictInfo se:list){
|
||||
se.setLevelNo(levelNo+1);
|
||||
resultList.add(se);
|
||||
List<ServiceDictInfo> newList = serviceDictInfoService.getDictByParentId(se.getServiceDictId());
|
||||
allTreeNode(se.getLevelNo(),newList,resultList);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import java.util.Map;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.apache.shiro.authz.annotation.Logical;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
@@ -66,11 +67,10 @@ public class SysDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequiresPermissions(value={"basics:area:view","basics:isp:view","basics:scope:view"},logical=Logical.OR)
|
||||
@RequestMapping(value = {"list", ""})
|
||||
public String list(String itType, SysDictInfo sysDictInfo,HttpServletRequest request, HttpServletResponse response, Model model, Integer selectedType,boolean isFilterAction) {
|
||||
public String list(String itType, SysDictInfo sysDictInfo,HttpServletRequest request, HttpServletResponse response, Model model) {
|
||||
//处理数据
|
||||
sysDictInfo.setIsFilterAction(isFilterAction);
|
||||
String[] strArr = itType.split("-");
|
||||
Integer[] intArr = new Integer[strArr.length];
|
||||
for(int i=0;i<strArr.length;i++){
|
||||
@@ -91,12 +91,7 @@ public class SysDictInfoController extends BaseController {
|
||||
}
|
||||
model.addAttribute("searchType", searchType);
|
||||
model.addAttribute("searchContent", searchContent);
|
||||
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);
|
||||
|
||||
//查询符合条件总数
|
||||
@@ -111,7 +106,7 @@ public class SysDictInfoController extends BaseController {
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
|
||||
//处理数据,取出主键优化处理
|
||||
//处理数据,取出主键
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
for(SysDictInfo se:page.getList()){
|
||||
if(se!=null){
|
||||
@@ -143,6 +138,7 @@ public class SysDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions(value={"basics:area:edit","basics:isp:edit","basics:scope:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value={"form"})
|
||||
public String form(SysDictInfo sysDictInfo, Model model, String doAction, String itType, String mulitId) {
|
||||
if(doAction!=null&&doAction.equals("0")){
|
||||
@@ -160,7 +156,7 @@ public class SysDictInfoController extends BaseController {
|
||||
if (sysDictInfo.getParent() == null || sysDictInfo.getParent().getSysDictId() == null||sysDictInfo.getParent().getSysDictId() == 0) {
|
||||
SysDictInfo parent = new SysDictInfo();
|
||||
parent.setSysDictId(0);
|
||||
parent.setItemValue("根节点");
|
||||
parent.setItemValue("root_node");
|
||||
sysDictInfo.setParent(parent);
|
||||
}
|
||||
String[] strArr = itType.split("-");
|
||||
@@ -183,16 +179,16 @@ public class SysDictInfoController extends BaseController {
|
||||
* @param redirectAttributes
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:edit")
|
||||
@RequiresPermissions(value={"basics:area:edit","basics:isp:edit","basics:scope:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(SysDictInfo sysDictInfo,Model model, RedirectAttributes redirectAttributes, String itType) {
|
||||
|
||||
try {
|
||||
sysDictInfoService.saveOrUpdate(sysDictInfo);
|
||||
addMessage(redirectAttributes, "保存成功");
|
||||
addMessage(redirectAttributes, "save_success");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "保存失败!");
|
||||
addMessage(redirectAttributes, "save_failed");
|
||||
}
|
||||
|
||||
return "redirect:" + adminPath + "/basics/sysDictInfo/list?itType="+itType;
|
||||
@@ -204,14 +200,15 @@ public class SysDictInfoController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions(value={"basics:area:edit","basics:isp:edit","basics:scope:edit"},logical=Logical.OR)
|
||||
@RequestMapping(value={"delete"})
|
||||
public String delete(SysDictInfo sysDictInfo, RedirectAttributes redirectAttributes, String itType, String mulitId) {
|
||||
try {
|
||||
sysDictInfoService.deleteDict(mulitId);
|
||||
addMessage(redirectAttributes, "删除成功");
|
||||
addMessage(redirectAttributes, "delete_success");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
addMessage(redirectAttributes, "删除失败!");
|
||||
addMessage(redirectAttributes, "delete_failed");
|
||||
}
|
||||
return "redirect:" + adminPath + "/basics/sysDictInfo/list?itType="+itType;
|
||||
}
|
||||
@@ -232,7 +229,7 @@ public class SysDictInfoController extends BaseController {
|
||||
Map<String, Object> map2 = Maps.newHashMap();
|
||||
map2.put("id", 0);
|
||||
map2.put("pId", 0);
|
||||
map2.put("name","根节点");
|
||||
map2.put("name","root_node");
|
||||
//map2.put("placeholder","0");
|
||||
mapList.add(map2);
|
||||
//找出该类型所有的非叶子配置
|
||||
|
||||
@@ -46,7 +46,7 @@ public class SpecificServiceCfgController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequiresPermissions("specific:service:view")
|
||||
@RequestMapping(value = "list")
|
||||
public String list(SpecificServiceCfg specificServiceCfg, HttpServletRequest request, HttpServletResponse response,
|
||||
Model model) {
|
||||
@@ -83,7 +83,7 @@ public class SpecificServiceCfgController extends BaseController {
|
||||
page.getList().get(i).setShowSequence("" + (i + 1 + ((page.getPageNo() - 1) * page.getPageSize())));
|
||||
}
|
||||
model.addAttribute("page", page);
|
||||
// 删除顶层数据、取出id 优化处理
|
||||
// 删除顶层数据、取出id
|
||||
List<Integer> intList = Lists.newArrayList();
|
||||
for (SpecificServiceCfg tempSS : page.getList()) {
|
||||
if (tempSS != null) {
|
||||
@@ -118,6 +118,7 @@ public class SpecificServiceCfgController extends BaseController {
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("specific:service:edit")
|
||||
@RequestMapping(value = { "form" })
|
||||
public String form(SpecificServiceCfg specificServiceCfg, Model model, String doAction, String mulitId) {
|
||||
|
||||
@@ -150,7 +151,7 @@ public class SpecificServiceCfgController extends BaseController {
|
||||
* @param redirectAttributes
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:edit")
|
||||
@RequiresPermissions("specific:service:edit")
|
||||
@RequestMapping(value="saveOrUpdate")
|
||||
public String saveOrUpdate(SpecificServiceCfg specificServiceCfg, Model model,
|
||||
RedirectAttributes redirectAttributes,Integer oldId) {
|
||||
@@ -171,6 +172,7 @@ public class SpecificServiceCfgController extends BaseController {
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("specific:service:edit")
|
||||
@RequestMapping(value="delete")
|
||||
public String delete(SpecificServiceCfg specificServiceCfg, RedirectAttributes redirectAttributes, String mulitId){
|
||||
try{
|
||||
|
||||
@@ -45,7 +45,7 @@ public class SpecificServiceHostCfgController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequiresPermissions("specific:serviceIp:view")
|
||||
@RequestMapping(value = "list")
|
||||
public String list(SpecificServiceHostCfg specificServiceHostCfg, HttpServletRequest request, HttpServletResponse response,
|
||||
Model model) {
|
||||
@@ -67,7 +67,7 @@ public class SpecificServiceHostCfgController extends BaseController {
|
||||
* @param model
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("sys:dict:view")
|
||||
@RequiresPermissions("specific:serviceIp:edit")
|
||||
@RequestMapping(value = "form")
|
||||
public String form(SpecificServiceHostCfg specificServiceHostCfg, HttpServletRequest request, HttpServletResponse response, Model model) {
|
||||
//查询协议id供下拉选择
|
||||
@@ -84,6 +84,7 @@ public class SpecificServiceHostCfgController extends BaseController {
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("specific:serviceIp:edit")
|
||||
@RequestMapping(value = "saveOrUpdate")
|
||||
public String saveOrUpdate(SpecificServiceHostCfg specificServiceHostCfg,Model model,RedirectAttributes redirectAttributes){
|
||||
try {
|
||||
@@ -102,6 +103,7 @@ public class SpecificServiceHostCfgController extends BaseController {
|
||||
* @param mulitId
|
||||
* @return
|
||||
*/
|
||||
@RequiresPermissions("specific:serviceIp:edit")
|
||||
@RequestMapping(value="delete")
|
||||
public String delete(SpecificServiceHostCfg specificServiceHostCfg, RedirectAttributes redirectAttributes, String mulitId){
|
||||
try{
|
||||
|
||||
@@ -29,6 +29,11 @@
|
||||
<result property="loginId" column="login_id"/>
|
||||
<result property="name" column="name"/>
|
||||
</association>
|
||||
<!-- 子集合 -->
|
||||
<collection property="childrenList" javaType="com.nis.domain.basics.ServiceDictInfo">
|
||||
<id column="service_dict_id" property="serviceDictId" jdbcType="INTEGER" />
|
||||
<result column="item_type" property="itemType" jdbcType="INTEGER" />
|
||||
</collection>
|
||||
</resultMap>
|
||||
<resultMap id="dictResultSimpleMap" type="com.nis.domain.basics.ServiceDictInfo" >
|
||||
<id column="service_dict_id" property="serviceDictId" jdbcType="INTEGER" />
|
||||
@@ -295,7 +300,7 @@
|
||||
|
||||
<select id="getDictByParentId" resultMap="dictResultMap">
|
||||
select *
|
||||
from service_dict_info s where parent_id = #{parentId}
|
||||
from service_dict_info s where parent_id = #{parentId} and is_valid = 1
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
@@ -313,7 +313,7 @@
|
||||
|
||||
<select id="getDictByParentId" resultMap="dictResultMap">
|
||||
select *
|
||||
from sys_dict_info s where parent_id = #{parentId}
|
||||
from sys_dict_info s where parent_id = #{parentId} and is_valid = 1
|
||||
</select>
|
||||
|
||||
<!-- 查询最大itemCode值 -->
|
||||
|
||||
@@ -45,7 +45,6 @@ domain_control=domain control
|
||||
dns_control=dns control
|
||||
basic_configuration=basic configuration
|
||||
letter_from=letter from
|
||||
classification=classification
|
||||
classification_manage=classification manage
|
||||
area_manage=area manage
|
||||
feature_scope_manage=feature scope manage
|
||||
@@ -141,12 +140,17 @@ item_code=itemcode
|
||||
item_value=itemvalue
|
||||
desc=description
|
||||
parent_id=parentid
|
||||
is_leaf=whether subnode
|
||||
is_leaf=whether leaf node
|
||||
is_valid=whether valid
|
||||
create_time=create time
|
||||
superior_config=superior configuration
|
||||
config_content=configuration content
|
||||
|
||||
root_node=root node
|
||||
leafChange=this configuration includes subnode,cannot be leaf node
|
||||
typeChild=this data type will be not same with subnode
|
||||
typeSame=please select the consistent upper and lower data types
|
||||
isLevelNoSure=more than the maximum level
|
||||
submitting=submitting
|
||||
#============yewu end======================
|
||||
|
||||
#============laihan begin======================
|
||||
@@ -276,8 +280,12 @@ key_word=key word
|
||||
block_type=block type
|
||||
letter=letter
|
||||
whether_area_block=whether area block
|
||||
classification=classification
|
||||
label=label
|
||||
attribute=attribute
|
||||
area=area
|
||||
isp=isp
|
||||
scope=scope
|
||||
valid_identifier=valid identifier
|
||||
is_audit=whether audit
|
||||
creator=creator
|
||||
|
||||
@@ -45,7 +45,6 @@ domain_control=domain control
|
||||
dns_control=dns control
|
||||
basic_configuration=basic configuration
|
||||
letter_from=letter from
|
||||
classification=classification
|
||||
classification_manage=classification manage
|
||||
attribute_manage=attribute manage
|
||||
area_manage=area manage
|
||||
@@ -146,13 +145,18 @@ item_code=itemcode
|
||||
item_value=itemvalue
|
||||
desc=description
|
||||
parent_id=parentid
|
||||
is_leaf=whether subnode
|
||||
is_leaf=whether leaf node
|
||||
is_valid=whether valid
|
||||
create_time=createtime
|
||||
edit_time=edittime
|
||||
superior_config=superior configuration
|
||||
config_content=configuration content
|
||||
|
||||
root_node=root node
|
||||
leafChange=this configuration includes subnode,cannot be leaf node
|
||||
typeChild=this data type will be not same with subnode
|
||||
typeSame=please select the consistent upper and lower data types
|
||||
isLevelNoSure=more than the maximum level
|
||||
submitting=submitting
|
||||
#============yewu end======================
|
||||
|
||||
#============laihan begin======================
|
||||
@@ -268,8 +272,12 @@ key_word=key word
|
||||
block_type=block type
|
||||
letter=letter
|
||||
whether_area_block=whether area block
|
||||
classification=classification
|
||||
label=label
|
||||
attribute=attribute
|
||||
area=area
|
||||
isp=isp
|
||||
scope=scope
|
||||
valid_identifier=valid identifier
|
||||
is_audit=whether audit
|
||||
creator=creator
|
||||
|
||||
@@ -44,7 +44,6 @@ domain_control=\u57df\u540d\u7ba1\u63a7
|
||||
dns_control=DNS\u7ba1\u63a7
|
||||
basic_configuration=\u57fa\u672c\u914d\u7f6e
|
||||
letter_from=\u6765\u51fd\u5355\u4f4d
|
||||
classification=\u5206\u7c7b\u6027\u8d28
|
||||
classification_manage=\u5206\u7c7b\u7ba1\u7406
|
||||
attribute_manage=\u6027\u8d28\u7ba1\u7406
|
||||
area_manage=\u5730\u57df\u7ba1\u7406
|
||||
@@ -142,7 +141,12 @@ is_valid=\u6709\u6548\u6807\u5fd7
|
||||
create_time=\u521b\u5efa\u65f6\u95f4
|
||||
superior_config=\u4e0a\u7ea7\u914d\u7f6e
|
||||
config_content=\u914d\u7f6e\u5185\u5bb9
|
||||
|
||||
root_node=\u6839\u8282\u70b9
|
||||
leafChange=\u8be5\u914d\u7f6e\u5305\u542b\u4e0b\u7ea7\u914d\u7f6e\uff0c\u4e0d\u5f97\u6539\u4e3a\u53f6\u5b50\u8282\u70b9
|
||||
typeChild=\u8be5\u914d\u7f6e\u5305\u542b\u4e0b\u7ea7\u914d\u7f6e\uff0c\u6570\u636e\u7c7b\u578b\u66f4\u6539\u540e\u4e0e\u5b50\u7c7b\u4e0d\u4e00\u81f4
|
||||
typeSame=\u8bf7\u9009\u62e9\u4e00\u81f4\u7684\u4e0a\u4e0b\u7ea7\u914d\u7f6e\u6570\u636e\u7c7b\u578b
|
||||
isLevelNoSure=\u9009\u62e9\u6b64\u914d\u7f6e\u4e0a\u4e0b\u5c42\u7ea7\u6570\u5c06\u8d85\u8fc7\u6700\u5927\u5c42\u7ea7
|
||||
submitting=submitting
|
||||
#==========yewu zidian end=====================
|
||||
|
||||
#==========laihan begin=====================
|
||||
@@ -270,8 +274,12 @@ key_word=\u5173\u952e\u5b57
|
||||
block_type=\u7ba1\u63a7\u7c7b\u578b
|
||||
letter=\u6765\u51fd
|
||||
whether_area_block=\u662f\u5426\u533a\u57df\u7ba1\u63a7
|
||||
classification=\u5206\u7c7b
|
||||
label=\u6807\u7b7e
|
||||
attribute=\u6027\u8d28
|
||||
area=\u5730\u57df
|
||||
isp=\u8fd0\u8425\u5546
|
||||
scope=\u7279\u5f81\u4f5c\u7528\u57df
|
||||
valid_identifier=\u6709\u6548\u6807\u8bc6
|
||||
is_audit=\u662f\u5426\u5ba1\u6838
|
||||
creator=\u521b\u5efa\u4eba\u5458
|
||||
|
||||
@@ -331,13 +331,23 @@
|
||||
<!-- 根据数据类型编码取出数据类型 -->
|
||||
|
||||
<function>
|
||||
<description>计算序号</description>
|
||||
<description>取出数据类型</description>
|
||||
<name>getItemTypeByNo</name>
|
||||
<function-class>com.nis.util.ConfigDictUtils</function-class>
|
||||
<function-signature>java.lang.String getItemTypeByNo(java.lang.String,java.util.List)</function-signature>
|
||||
<example>${fns:getItemTypeByNo(str1,list)}</example>
|
||||
</function>
|
||||
|
||||
<!-- 根据数据类型编码取出权限编码 -->
|
||||
|
||||
<function>
|
||||
<description>取出权限编码</description>
|
||||
<name>getPermissionByNo</name>
|
||||
<function-class>com.nis.util.ConfigDictUtils</function-class>
|
||||
<function-signature>java.lang.String getPermissionByNo(java.lang.String,java.util.List)</function-signature>
|
||||
<example>${fns:getPermissionByNo(str1,list)}</example>
|
||||
</function>
|
||||
|
||||
|
||||
|
||||
</taglib>
|
||||
|
||||
@@ -23,18 +23,36 @@
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
errorShow();
|
||||
|
||||
}
|
||||
function errorShow(){
|
||||
var flaelNoSure = false;
|
||||
$.ajax({
|
||||
type:'post',
|
||||
async:false,
|
||||
url:'${ctx}/basics/serviceDictInfo/isLevelTotalSure',
|
||||
data:{parentId:$(".singleClass").val(),currentId:'${serviceDictInfo.serviceDictId}'},
|
||||
success:function(data){
|
||||
if(data){
|
||||
$(".errorShow").hide();
|
||||
}else{
|
||||
$(".errorShow").show();
|
||||
}
|
||||
flaelNoSure = data;
|
||||
}
|
||||
});
|
||||
return flaelNoSure;
|
||||
}
|
||||
$(document).ready(function() {
|
||||
$("#serviceDictInfoId").on('onchange',errorShow);
|
||||
|
||||
//层级校验
|
||||
jQuery.validator.addMethod("isLevelNoSure",function(value,element){
|
||||
//层级校验
|
||||
/* jQuery.validator.addMethod("isLevelNoSure",function(value,element){
|
||||
var flagIsLevelNoSure = false;
|
||||
$.ajax({
|
||||
type:'post',
|
||||
async:false,
|
||||
cache:false,
|
||||
url:'${ctx}/basics/serviceDictInfo/isLevelTotalSure',
|
||||
data:{parentId:$(".singleClass").val(),currentId:'${serviceDictInfo.serviceDictId}'},
|
||||
success:function(data){
|
||||
@@ -43,7 +61,7 @@
|
||||
});
|
||||
return flagIsLevelNoSure;
|
||||
|
||||
},"选择此配置上下层级数将超过最大层级");
|
||||
},"选择此配置上下层级数将超过最大层级"); */
|
||||
|
||||
//类型选择与上级是否冲突
|
||||
jQuery.validator.addMethod("typeSame",function(value,element){
|
||||
@@ -109,9 +127,9 @@
|
||||
//ignore:[],
|
||||
//需验证 item_code item_value
|
||||
rules: {
|
||||
'parent.itemValue':{
|
||||
/* 'parent.itemValue':{
|
||||
isLevelNoSure:true
|
||||
},
|
||||
}, */
|
||||
|
||||
'itemCode':{
|
||||
//isLevelNoSure:true,
|
||||
@@ -126,35 +144,40 @@
|
||||
typeChild:true
|
||||
},
|
||||
'isLeaf':{
|
||||
leafChange:true,
|
||||
leafHasTree:true
|
||||
leafChange:true
|
||||
//leafHasTree:true
|
||||
}
|
||||
|
||||
},
|
||||
messages: {
|
||||
'parent.itemValue':{
|
||||
isLevelNoSure:"选择此配置上下层级数将超过最大层级"
|
||||
},
|
||||
/* 'parent.itemValue':{
|
||||
isLevelNoSure:'<spring:message code="isLevelNoSure"/>'
|
||||
}, */
|
||||
'itemCode':{
|
||||
//isLevelNoSure:"选择此配置上下层级数将超过四级",
|
||||
required:'请填写配置编码',
|
||||
remote:'该配置编码已存在'
|
||||
required:'<spring:message code="required"/>',
|
||||
remote:'<spring:message code="repeat"/>'
|
||||
},
|
||||
'itemValue':{
|
||||
required:'编码对应值必须填写'
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
'itemType':{
|
||||
typeSame:'请选择一致的上下级配置数据类型',
|
||||
typeChild:'该配置包含下级配置,数据类型更改后与子类不一致'
|
||||
typeSame:'<spring:message code="typeSame"/>',
|
||||
typeChild:'<spring:message code="typeChild"/>'
|
||||
},
|
||||
'isLeaf':{
|
||||
leafChange:'该配置包含下级配置,不得改为叶子节点',
|
||||
leafHasTree:'该配置上级为根节点,不得设为叶子节点'
|
||||
leafChange:'<spring:message code="leafChange"/>'
|
||||
//leafHasTree:'该配置上级为根节点,不得设为叶子节点'
|
||||
}
|
||||
},
|
||||
|
||||
submitHandler: function(form){
|
||||
loading('正在提交,请稍等...');
|
||||
var is_level_wrong=errorShow();
|
||||
if(!is_level_wrong){
|
||||
return false;
|
||||
$(".errorShow").show();
|
||||
}
|
||||
loading('<spring:message code="submitting"/>');
|
||||
form.submit();
|
||||
},
|
||||
errorContainer: "#messageBox",
|
||||
@@ -191,7 +214,7 @@
|
||||
<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 serviceDictInfo.serviceDictId?'修改':'添加'}</shiro:hasPermission><shiro:lacksPermission name="sys:menu:edit"><spring:message code="show"/></shiro:lacksPermission></div>
|
||||
<i class="fa fa-gift"></i><c:if test="${not empty serviceDictInfo.serviceDictId}"><spring:message code='edit'/></c:if><c:if test="${empty serviceDictInfo.serviceDictId}"><spring:message code='add'/></c:if></div>
|
||||
<div class="tools">
|
||||
<!-- <a href="javascript:;" class="collapse"> </a>
|
||||
<a href="#portlet-config" data-toggle="modal" class="config"> </a>
|
||||
@@ -212,8 +235,10 @@
|
||||
<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="serviceDictInfo" name="parent.serviceDictId" value="${serviceDictInfo.parent.serviceDictId}" labelName="parent.itemValue" labelValue="${serviceDictInfo.parent.itemValue eq '根节点'?'根节点':fns:getServiceDictInfoById(serviceDictInfo.parent.serviceDictId).itemValue}"
|
||||
<c:set var="fatherName"><spring:message code="root_node"/></c:set>
|
||||
<sys:treeselect id="serviceDictInfo" name="parent.serviceDictId" value="${serviceDictInfo.parent.serviceDictId}" labelName="parent.itemValue" labelValue="${serviceDictInfo.parent.itemValue eq 'root_node'?fatherName:fns:getServiceDictInfoById(serviceDictInfo.parent.serviceDictId).itemValue}"
|
||||
title="菜单" url="/basics/serviceDictInfo/treeData?itType=${itType}" extId="${serviceDictInfo.serviceDictId}" cssClass="required form-control"/>
|
||||
<label class="error errorShow" style="display: none;"><spring:message code="isLevelNoSure"/></label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -223,9 +248,7 @@
|
||||
<c:forEach items="${fns:getDictList('SERVICE_DICT_ITM_TYPE')}" var="dict">
|
||||
<c:forEach items="${intArr}" var="itTemp">
|
||||
<c:if test="${dict.itemCode eq itTemp}">
|
||||
<option value="${dict.itemCode}"
|
||||
<c:if test="${serviceDictInfo.itemType eq dict.itemCode}">selected="selected"</c:if>
|
||||
>${dict.itemValue}</option>
|
||||
<option value="${dict.itemCode}" <c:if test="${serviceDictInfo.itemType eq dict.itemCode}">selected="selected"</c:if>><spring:message code="${dict.itemValue}"/></option>
|
||||
</c:if>
|
||||
</c:forEach>
|
||||
</c:forEach>
|
||||
@@ -233,7 +256,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>配置编码:</label>
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="item_code"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="itemCode" htmlEscape="false" maxlength="50" class="form-control"/>
|
||||
</div>
|
||||
@@ -247,9 +270,10 @@
|
||||
<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"/>
|
||||
<c:forEach items="${fns:getDictList('INT_YES_NO')}" var="dict">
|
||||
<form:option value="${dict.itemCode}"><spring:message code="${dict.itemValue}"/></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -41,7 +41,8 @@
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="superior_config"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${serviceDictInfo.parent.serviceDictId == 0?'根节点':fns:getServiceDictInfoById(serviceDictInfo.parent.serviceDictId).itemValue}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<c:set var="fatherName"><spring:message code="root_node"/></c:set>
|
||||
<input value="${serviceDictInfo.parent.serviceDictId == 0?fatherName:fns:getServiceDictInfoById(serviceDictInfo.parent.serviceDictId).itemValue}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<%-- <div class="form-group">
|
||||
@@ -53,7 +54,7 @@
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label radio-lable"><font color="red">*</font> <spring:message code="item_type"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${fns:getDictLabel('SERVICE_DICT_ITM_TYPE',serviceDictInfo.itemType,'0')}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<input value=<spring:message code="${fns:getDictLabel('SERVICE_DICT_ITM_TYPE',serviceDictInfo.itemType,'0')}"/> maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -71,7 +72,7 @@
|
||||
<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',serviceDictInfo.isLeaf,'0')}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<input value=<spring:message code="${fns:getDictLabel('INT_YES_NO',serviceDictInfo.isLeaf,'0')}"/> maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<%-- <div class="form-group">
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
<head>
|
||||
<title>配置信息</title>
|
||||
<link href="${ctxStatic}/global/plugins/treeTable/themes/vsStyle/treeTable.min.css" rel="stylesheet" type="text/css" />
|
||||
<%-- <link href="${ctxStatic}/pages/css/dictInfo.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>
|
||||
<script type="text/javascript">
|
||||
@@ -15,20 +14,12 @@
|
||||
处理全选、全取消
|
||||
**/
|
||||
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");
|
||||
});
|
||||
}
|
||||
@@ -45,9 +36,9 @@
|
||||
}
|
||||
});
|
||||
if(mulitId!=""){
|
||||
confirmx('您确认要执行该操作?', url+"&mulitId="+mulitId);
|
||||
confirmx("<spring:message code='confirm_message'/>", url+"&mulitId="+mulitId);
|
||||
}else{
|
||||
alert("至少选择一条数据记录");
|
||||
alert("<spring:message code='one_more'/>");
|
||||
}
|
||||
}
|
||||
//查询
|
||||
@@ -84,7 +75,7 @@
|
||||
|
||||
$("#seltype").change(function(){
|
||||
$("#intype").val("");
|
||||
$("#intype").attr("placeholder","请输入"+$(this).find("option:selected").text());
|
||||
$("#intype").attr("placeholder","<spring:message code='input'/>"+$(this).find("option:selected").text());
|
||||
$("#intype").attr("name",$(this).find("option:selected").val());
|
||||
});
|
||||
$("#treeTable").treeTable({expandLevel : 3}).show();
|
||||
@@ -99,16 +90,20 @@
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<c:set var="permission_type">${fns:getPermissionByNo('SERVICE_DICT_ITM_TYPE',intArr)}</c:set>
|
||||
<div class="page-content">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<shiro:hasPermission name="basics:${permission_type}:edit">
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/basics/serviceDictInfo/form?itType=${itType}'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"></spring:message>配置</button>
|
||||
<spring:message code="add"></spring:message><spring:message code="configuration"></spring:message>
|
||||
</button>
|
||||
</shiro:hasPermission>
|
||||
</div>
|
||||
|
||||
<h3 class="page-title">
|
||||
${fns:getItemTypeByNo("SERVICE_DICT_ITM_TYPE",intArr)}
|
||||
<spring:message code="${fns:getItemTypeByNo('SERVICE_DICT_ITM_TYPE',intArr)}"/>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
</h3>
|
||||
|
||||
@@ -154,7 +149,7 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<input id="intype" class="form-control input-medium" placeholder="请输入配置编码" type="text">
|
||||
<input id="intype" class="form-control input-medium" placeholder="<spring:message code='item_code'></spring:message>" type="text">
|
||||
|
||||
|
||||
</div>
|
||||
@@ -168,12 +163,17 @@
|
||||
|
||||
<div class="pull-right">
|
||||
|
||||
<shiro:hasPermission name="basics:${permission_type}:edit">
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/basics/serviceDictInfo/form?itType=${itType}')">
|
||||
<i class="fa fa-edit"></i> 编辑</button>
|
||||
<i class="fa fa-edit"></i> <spring:message code="edit" /></button>
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/basics/serviceDictInfo/delete?itType=${itType}')">
|
||||
<i class="fa fa-trash"></i> 删除</button>
|
||||
<i class="fa fa-trash"></i><spring:message code="delete" /></button>
|
||||
</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>
|
||||
@@ -280,8 +280,8 @@
|
||||
<td nowrap><i class="icon-icon-tablet"></i><a href="${ctx}/basics/serviceDictInfo/form?serviceDictId=${serviceDictInfo.serviceDictId}&doAction=0">${serviceDictInfo.itemCode}</a></td>
|
||||
<td>${serviceDictInfo.itemValue}</td>
|
||||
<td title="${serviceDictInfo.itemDesc}">${fns:abbr(serviceDictInfo.itemDesc,15)}</td>
|
||||
<td>${fns:getDictLabel("SERVICE_DICT_ITM_TYPE",serviceDictInfo.itemType,"0")}</td>
|
||||
<td>${fns:getDictLabel("SYS_YES_NO",serviceDictInfo.isLeaf,"0")}</td>
|
||||
<td><spring:message code='${fns:getDictLabel("SERVICE_DICT_ITM_TYPE",serviceDictInfo.itemType,"0")}'/></td>
|
||||
<td><spring:message code='${fns:getDictLabel("INT_YES_NO",serviceDictInfo.isLeaf,"0")}'/></td>
|
||||
<td><c:if test="${serviceDictInfo.serviceDictCreator != null}">
|
||||
${fns:getUserById(serviceDictInfo.serviceDictCreator.id).name}
|
||||
</c:if></td>
|
||||
|
||||
@@ -118,34 +118,34 @@
|
||||
typeChild:true
|
||||
},
|
||||
'isLeaf':{
|
||||
leafChange:true,
|
||||
leafHasTree:true
|
||||
leafChange:true
|
||||
//leafHasTree:true
|
||||
}
|
||||
|
||||
},
|
||||
messages: {
|
||||
'parent.itemValue':{
|
||||
isLevelNoSure:"选择此配置上下层级数将超过最大层级"
|
||||
isLevelNoSure:'<spring:message code="isLevelNoSure"/>'
|
||||
},
|
||||
'itemCode':{
|
||||
required:'请填写配置编码',
|
||||
remote:'该配置编码已存在'
|
||||
required:'<spring:message code="required"/>',
|
||||
remote:'<spring:message code="repeat"/>'
|
||||
},
|
||||
'itemValue':{
|
||||
required:'编码对应值必须填写'
|
||||
required:'<spring:message code="required"/>'
|
||||
},
|
||||
'itemType':{
|
||||
typeSame:'请选择一致的上下级配置数据类型',
|
||||
typeChild:'该配置包含下级配置,数据类型更改后与子类不一致'
|
||||
typeSame:'<spring:message code="typeSame"/>',
|
||||
typeChild:'<spring:message code="typeChild"/>'
|
||||
},
|
||||
'isLeaf':{
|
||||
leafChange:'该配置包含下级配置,不得改为叶子节点',
|
||||
leafHasTree:'该配置上级为根节点,不得设为叶子节点'
|
||||
leafChange:'<spring:message code="leafChange"/>'
|
||||
//leafHasTree:'该配置上级为根节点,不得设为叶子节点'
|
||||
}
|
||||
},
|
||||
|
||||
submitHandler: function(form){
|
||||
loading('正在提交,请稍等...');
|
||||
loading('<spring:message code="submitting"/>');
|
||||
form.submit();
|
||||
},
|
||||
errorContainer: "#messageBox",
|
||||
@@ -182,7 +182,7 @@
|
||||
<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 sysDictInfo.sysDictId?'修改':'添加'}</shiro:hasPermission><shiro:lacksPermission name="sys:menu:edit"><spring:message code="show"/></shiro:lacksPermission></div>
|
||||
<i class="fa fa-gift"></i><c:if test="${not empty sysDictInfo.sysDictId}"><spring:message code='edit'/></c:if><c:if test="${empty sysDictInfo.sysDictId}"><spring:message code='add'/></c:if></div>
|
||||
<div class="tools">
|
||||
<!-- <a href="javascript:;" class="collapse"> </a>
|
||||
<a href="#portlet-config" data-toggle="modal" class="config"> </a>
|
||||
@@ -204,7 +204,8 @@
|
||||
<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="sysDictInfo" name="parent.sysDictId" value="${sysDictInfo.parent.sysDictId}" labelName="parent.itemValue" labelValue="${sysDictInfo.parent.itemValue eq '根节点'?'根节点':fns:getSysDictInfoById(sysDictInfo.parent.sysDictId).itemValue}"
|
||||
<c:set var="fatherName"><spring:message code="root_node"/></c:set>
|
||||
<sys:treeselect id="sysDictInfo" name="parent.sysDictId" value="${sysDictInfo.parent.sysDictId}" labelName="parent.itemValue" labelValue="${sysDictInfo.parent.itemValue eq 'root_node'?fatherName:fns:getSysDictInfoById(sysDictInfo.parent.sysDictId).itemValue}"
|
||||
title="菜单" url="/basics/sysDictInfo/treeData?itType=${itType}" extId="${sysDictInfo.sysDictId}" cssClass="required form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -216,9 +217,7 @@
|
||||
<c:forEach items="${fns:getDictList('SYS_DICT_ITM_TYPE')}" var="dict">
|
||||
<c:forEach items="${intArr}" var="itTemp">
|
||||
<c:if test="${dict.itemCode eq itTemp}">
|
||||
<option value="${dict.itemCode}"
|
||||
<c:if test="${sysDictInfo.itemType eq dict.itemCode}">selected="selected"</c:if>
|
||||
>${dict.itemValue}</option>
|
||||
<option value="${dict.itemCode}" <c:if test="${sysDictInfo.itemType eq dict.itemCode}">selected="selected"</c:if>><spring:message code="${dict.itemValue}"/></option>
|
||||
</c:if>
|
||||
</c:forEach>
|
||||
</c:forEach>
|
||||
@@ -226,7 +225,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font>配置编码:</label>
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="itemCode"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<form:input path="itemCode" htmlEscape="false" maxlength="50" class="form-control"/>
|
||||
</div>
|
||||
@@ -238,14 +237,16 @@
|
||||
</div>
|
||||
</div>
|
||||
<c:if test="${specType != null and specType==3 }">
|
||||
<form:hidden path="isLeaf" value="0"/>
|
||||
<form:hidden path="isLeaf" value="1"/>
|
||||
</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:select path="isLeaf" class="form-control">
|
||||
<form:options items="${fns:getDictList('SYS_YES_NO')}" itemLabel="itemValue" itemValue="itemCode" htmlEscape="false"/>
|
||||
<c:forEach items="${fns:getDictList('INT_YES_NO')}" var="dict">
|
||||
<form:option value="${dict.itemCode}"><spring:message code="${dict.itemValue}"/></form:option>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -42,7 +42,8 @@
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label"><font color="red">*</font><spring:message code="superior_config"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${sysDictInfo.parent.sysDictId == 0?'根节点':fns:getSysDictInfoById(sysDictInfo.parent.sysDictId).itemValue}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<c:set var="fatherName"><spring:message code="root_node"/></c:set>
|
||||
<input value="${sysDictInfo.parent.sysDictId == 0?fatherName:fns:getSysDictInfoById(sysDictInfo.parent.sysDictId).itemValue}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
@@ -55,7 +56,7 @@
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label radio-lable"><font color="red">*</font> <spring:message code="item_type"/>:</label>
|
||||
<div class="col-md-4">
|
||||
<input value="${fns:getDictLabel('SYS_DICT_ITM_TYPE',sysDictInfo.itemType,'0')}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<input value=<spring:message code="${fns:getDictLabel('SYS_DICT_ITM_TYPE',sysDictInfo.itemType,'0')}"/> maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -74,7 +75,7 @@
|
||||
<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',sysDictInfo.isLeaf,'0')}" maxlength="50" class="form-control" readonly="readonly"/>
|
||||
<input value=<spring:message code="${fns:getDictLabel('INT_YES_NO',sysDictInfo.isLeaf,'0')}"/> maxlength="50" class="form-control" readonly="readonly"/>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
|
||||
@@ -16,20 +16,12 @@
|
||||
处理全选、全取消
|
||||
**/
|
||||
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");
|
||||
});
|
||||
}
|
||||
@@ -49,9 +41,9 @@
|
||||
}
|
||||
});
|
||||
if(mulitId!=""){
|
||||
confirmx('您确认要执行该操作?', url+"&mulitId="+mulitId);
|
||||
confirmx("<spring:message code='confirm_message'/>", url+"&mulitId="+mulitId);
|
||||
}else{
|
||||
alert("至少选择一条数据记录");
|
||||
alert("<spring:message code='one_more'/>");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,7 +80,7 @@
|
||||
|
||||
$("#seltype").change(function(){
|
||||
$("#intype").val("");
|
||||
$("#intype").attr("placeholder","请输入"+$(this).find("option:selected").text());
|
||||
$("#intype").attr("placeholder","<spring:message code='input'/>"+$(this).find("option:selected").text());
|
||||
$("#intype").attr("name",$(this).find("option:selected").val());
|
||||
});
|
||||
$("#treeTable").treeTable({expandLevel : 3}).show();
|
||||
@@ -102,16 +94,19 @@
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<c:set var="permission_type">${fns:getPermissionByNo('SYS_DICT_ITM_TYPE',intArr)}</c:set>
|
||||
<div class="page-content">
|
||||
<div class="theme-panel hidden-xs hidden-sm">
|
||||
<shiro:hasPermission name="basics:${permission_type}:edit">
|
||||
<button type="button" class="btn btn-primary"
|
||||
onClick="javascript:window.location='${ctx}/basics/sysDictInfo/form?itType=${itType}'">
|
||||
<i class="fa fa-plus"></i>
|
||||
<spring:message code="add"></spring:message>配置</button>
|
||||
<spring:message code="add"></spring:message><spring:message code="configuration" /></button>
|
||||
</shiro:hasPermission>
|
||||
</div>
|
||||
|
||||
<h3 class="page-title">
|
||||
${fns:getItemTypeByNo("SYS_DICT_ITM_TYPE",intArr)}
|
||||
<spring:message code="${fns:getItemTypeByNo('SYS_DICT_ITM_TYPE',intArr)}"/>
|
||||
<small><spring:message code="date_list"/></small>
|
||||
</h3>
|
||||
|
||||
@@ -157,7 +152,7 @@
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<input id="intype" class="form-control input-medium" placeholder="请输入配置编码" type="text">
|
||||
<input id="intype" class="form-control input-medium" placeholder="<spring:message code='item_code'></spring:message>" type="text">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -169,15 +164,16 @@
|
||||
</div>
|
||||
|
||||
<div class="pull-right">
|
||||
|
||||
<shiro:hasPermission name="basics:${permission_type}:edit">
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/basics/sysDictInfo/form?itType=${itType}')">
|
||||
<i class="fa fa-edit"></i> 编辑</button>
|
||||
<i class="fa fa-edit"></i> <spring:message code="edit"/> </button>
|
||||
<button type="button" class="btn btn-default" onclick="cmd('${ctx}/basics/sysDictInfo/delete?itType=${itType}')">
|
||||
<i class="fa fa-trash"></i> 删除</button>
|
||||
<i class="fa fa-trash"></i> <spring:message code="delete"/> </button>
|
||||
<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>
|
||||
</shiro:hasPermission>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /搜索内容与操作按钮栏-->
|
||||
@@ -282,9 +278,9 @@
|
||||
<td nowrap><i class="icon-icon-tablet"></i><a href="${ctx}/basics/sysDictInfo/form?sysDictId=${sysDictInfo.sysDictId}&doAction=0">${sysDictInfo.itemCode}</a></td>
|
||||
<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>
|
||||
<td><spring:message code='${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>
|
||||
<td><spring:message code='${fns:getDictLabel("INT_YES_NO",sysDictInfo.isLeaf,"0")}'/></td>
|
||||
</c:if>
|
||||
<td><c:if test="${sysDictInfo.sysDictCreator != null}">
|
||||
${fns:getUserById(sysDictInfo.sysDictCreator.id).name}
|
||||
|
||||
@@ -170,7 +170,7 @@
|
||||
<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:options items="${fns:getDictList('INT_YES_NO')}" itemLabel="<spring:message code="itemValue"/>" itemValue="itemCode" htmlEscape="false"/>
|
||||
</form:select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
<div class="portlet box blue">
|
||||
<div class="portlet-title">
|
||||
<div class="caption">
|
||||
<i class="fa fa-gift"></i><c:if test="${not empty requestInfo.id}"><spring:message code="edit"/></c:if><c:if test="${empty requestInfo.id}"><spring:message code="add"/></c:if></div>
|
||||
<i class="fa fa-gift"></i><c:if test="${not empty office.id}"><spring:message code="edit"/></c:if><c:if test="${empty office.id}"><spring:message code="add"/></c:if></div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
|
||||
@@ -166,8 +166,8 @@
|
||||
<form:textarea path="remarks" htmlEscape="false" rows="3" maxlength="200" class="input-xlarge form-control"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<c:if test="${empty office.id}">
|
||||
<div class="form-group">
|
||||
<label class="col-md-3 control-label">快速添加下级部门:</label>
|
||||
<div class="col-md-4">
|
||||
<div class="mt-checkbox-inline">
|
||||
@@ -175,8 +175,8 @@
|
||||
<span> </span>
|
||||
</div>
|
||||
</div>
|
||||
</c:if>
|
||||
</div>
|
||||
</c:if>
|
||||
</div>
|
||||
<div class="form-actions">
|
||||
<div class="row">
|
||||
|
||||
Reference in New Issue
Block a user