Compare commits

..

22 Commits

Author SHA1 Message Date
thinkgem
dc10f8670b update 2023-04-06 23:59:56 +08:00
thinkgem
f429bf1c83 5.3.1 2023-04-06 15:09:33 +08:00
thinkgem
3086736d4e update 2023-04-05 18:53:38 +08:00
thinkgem
5562a98a0e update 2023-04-04 11:32:23 +08:00
thinkgem
cd4fc57eb8 update 2023-04-03 11:27:43 +08:00
thinkgem
bdfd9d8b28 修正cloud工程生成模板的启动脚本路径问题 2023-04-03 11:27:33 +08:00
thinkgem
8336b993ac 优化空值针容错 2023-04-03 11:26:54 +08:00
thinkgem
6757958342 update 2023-03-28 09:42:23 +08:00
thinkgem
b40de7ec25 update README.md 2023-03-28 09:40:47 +08:00
thinkgem
c2e71cb80a 登录超时提示信息调整 2023-03-27 09:50:31 +08:00
thinkgem
8b0453b0c0 细节优化 2023-03-25 11:43:03 +08:00
thinkgem
532a20ed6f upgrade spring boot 2.7.10 2023-03-24 23:45:08 +08:00
thinkgem
f3b2e2204b 默认不继承上级任务的优先级,根据需要模型里设置,或每次审批的时候根据需要指定。 2023-03-20 15:27:39 +08:00
thinkgem
09a57cb928 增加 mybatis.scanTypeAliasesBasePackage 配置 2023-03-20 15:21:56 +08:00
thinkgem
c59564b393 修正oauth2绑定账号后的没有跳转到vue页面的问题 2023-03-20 13:12:29 +08:00
thinkgem
0a2c29abc3 update README.md 2023-03-17 15:42:17 +08:00
thinkgem
3b04eff399 增加子表编辑的另一种实现例子 2023-03-16 20:19:41 +08:00
thinkgem
ee3adf6fee update //<% 2023-03-16 19:20:27 +08:00
thinkgem
b9f614479b update sysDesktop.html 2023-03-15 16:59:25 +08:00
thinkgem
563fa84f49 优化CMS各种url生成调用 2023-03-15 11:59:31 +08:00
thinkgem
513fd4ca50 优化vue代码生成模板子表验证提示信息 2023-03-13 17:44:14 +08:00
thinkgem
1e4c9914fa update 2023-03-08 17:39:20 +08:00
63 changed files with 764 additions and 214 deletions

View File

@@ -23,6 +23,9 @@
![JeeSite微信公众号](https://images.gitee.com/uploads/images/2020/0727/091951_a3ab258c_6732.jpeg "JeeSite微信公众号")
* 源码仓库地址:<https://gitee.com/thinkgem/jeesite4>
* 分离版前端源码仓库:<https://gitee.com/thinkgem/jeesite-vue>
## 平台介绍
JeeSite 快速开发平台,不仅仅是一个后台开发框架,它是一个企业级快速开发解决方案,后端基于经典组合 Spring Boot、Shiro、MyBatis前端采用 Beetl、Bootstrap、AdminLTE 经典开发模式,或者分离版 Vue3、Vite、Ant Design Vue、TypeScript、Vben Admin 最先进技术栈。提供在线代码生成功能可自动创建业务模块工程和微服务模块工程自动生成前端代码和后端代码包括功能模块如组织机构、角色用户、菜单及按钮授权、数据权限、系统参数、内容管理、工作流等。采用松耦合设计微内核和插件架构模块增减便捷界面无刷新一键换肤众多账号安全设置密码策略文件在线预览消息推送多元化第三方登录在线定时任务配置支持集群支持SAAS支持多数据源支持读写分离、分库分表支持微服务应用。
@@ -43,6 +46,8 @@ JeeSite 是一个低代码开发平台,具有较高的封装度、扩展性,
大家都在用 Spring也在学习 Spring 的优点Spring 提供了较好的扩展性,可又有多少人去修改它的源代码呢,退一步说,大家去修改了 Spring 的源码反而会对未来升级造成很大困扰您说不是呢这样的例子很多所以不要纠结我们非常注重这一点JeeSite 也一样具备强大的扩展性。
为什么说 JeeSite 比较易于学习JeeSite 很好的把握了设计的 “度”,避免过度设计的情况。过度设计是在产品设计过程中忽略了产品和用户的实际需求,反而带来了不必要的复杂性,而忽略了系统的学习、开发和维护成本。
* 至今 JeeSite 平台架构已经非常稳定。
* JeeSite 精益求精,用心打磨每一个细节。
* JeeSite 是一个专业的平台,是一个让你使用放心的平台。

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>

View File

@@ -65,17 +65,26 @@ public class ListUtils extends org.apache.commons.collections.ListUtils {
@SafeVarargs
public static <E> ArrayList<E> newArrayList(E... elements) {
if (elements == null) {
return newArrayList();
}
ArrayList<E> list = new ArrayList<E>(elements.length);
Collections.addAll(list, elements);
return list;
}
public static <E> ArrayList<E> newArrayList(Iterable<? extends E> elements) {
if (elements == null) {
return newArrayList();
}
return (elements instanceof Collection) ? new ArrayList<E>(cast(elements))
: newArrayList(elements.iterator());
}
public static <E> ArrayList<E> newArrayList(Iterator<? extends E> elements) {
if (elements == null) {
return newArrayList();
}
ArrayList<E> list = newArrayList();
addAll(list, elements);
return list;
@@ -86,6 +95,9 @@ public class ListUtils extends org.apache.commons.collections.ListUtils {
}
public static <E> LinkedList<E> newLinkedList(Iterable<? extends E> elements) {
if (elements == null) {
return newLinkedList();
}
LinkedList<E> list = newLinkedList();
addAll(list, elements);
return list;
@@ -96,6 +108,9 @@ public class ListUtils extends org.apache.commons.collections.ListUtils {
}
public static <E> CopyOnWriteArrayList<E> newCopyOnWriteArrayList(Iterable<? extends E> elements) {
if (elements == null) {
return new CopyOnWriteArrayList<E>();
}
Collection<? extends E> elementsCollection = (elements instanceof Collection)
? cast(elements) : newArrayList(elements);
return new CopyOnWriteArrayList<E>(elementsCollection);
@@ -106,6 +121,9 @@ public class ListUtils extends org.apache.commons.collections.ListUtils {
}
private static <T> boolean addAll(Collection<T> addTo, Iterator<? extends T> iterator) {
if (addTo == null || iterator == null) {
return false;
}
boolean wasModified = false;
while (iterator.hasNext()) {
wasModified |= addTo.add(iterator.next());
@@ -114,6 +132,9 @@ public class ListUtils extends org.apache.commons.collections.ListUtils {
}
public static <T> boolean addAll(Collection<T> addTo, Iterable<? extends T> elementsToAdd) {
if (addTo == null || elementsToAdd == null) {
return false;
}
if (elementsToAdd instanceof Collection) {
Collection<? extends T> c = cast(elementsToAdd);
return addTo.addAll(c);

View File

@@ -4,25 +4,14 @@
*/
package com.jeesite.common.collect;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Comparator;
import java.util.EnumMap;
import java.util.HashMap;
import java.util.IdentityHashMap;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.SortedMap;
import java.util.TreeMap;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
import com.jeesite.common.lang.StringUtils;
import org.apache.commons.beanutils.BeanUtils;
import org.apache.commons.beanutils.PropertyUtils;
import com.jeesite.common.lang.StringUtils;
import java.lang.reflect.InvocationTargetException;
import java.util.*;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
/**
* Map工具类实现 Map <-> Bean 互相转换
@@ -85,8 +74,7 @@ public class MapUtils extends org.apache.commons.collections.MapUtils {
* @param clazz
* @param list
*/
public static <T, V> List<T> toObjectList(Class<T> clazz, List<HashMap<String, V>> list) throws Exception,
InvocationTargetException, NoSuchMethodException, InstantiationException {
public static <T, V> List<T> toObjectList(Class<T> clazz, List<HashMap<String, V>> list) throws Exception {
List<T> retList = new ArrayList<T>();
if (list != null && !list.isEmpty()) {
for (HashMap<String, V> m : list) {
@@ -101,8 +89,7 @@ public class MapUtils extends org.apache.commons.collections.MapUtils {
* @param clazz 目标对象的类
* @param map 待转换Map
*/
public static <T, V> T toObject(Class<T> clazz, Map<String, V> map) throws Exception,
InvocationTargetException {
public static <T, V> T toObject(Class<T> clazz, Map<String, V> map) throws Exception {
T object = clazz.getDeclaredConstructor().newInstance();
return toObject(object, map);
}
@@ -113,15 +100,13 @@ public class MapUtils extends org.apache.commons.collections.MapUtils {
* @param map 待转换Map
* @param toCamelCase 是否去掉下划线
*/
public static <T, V> T toObject(Class<T> clazz, Map<String, V> map, boolean toCamelCase) throws Exception,
InvocationTargetException {
public static <T, V> T toObject(Class<T> clazz, Map<String, V> map, boolean toCamelCase) throws Exception {
T object = clazz.getDeclaredConstructor().newInstance();
return toObject(object, map, toCamelCase);
}
/**
* 将Map转换为Object
* @param clazz 目标对象的类
* @param map 待转换Map
*/
public static <T, V> T toObject(T object, Map<String, V> map) throws InstantiationException, IllegalAccessException, InvocationTargetException {
@@ -203,9 +188,7 @@ public class MapUtils extends org.apache.commons.collections.MapUtils {
/**
* 转换成Map并提供字段命名驼峰转平行
* @param clazz 目标对象所在类
* @param object 目标对象
* @param map 待转换Map
* @throws NoSuchMethodException
* @throws InvocationTargetException
* @throws IllegalAccessException

View File

@@ -4,36 +4,26 @@
*/
package com.jeesite.common.io;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.RandomAccessFile;
import java.util.Enumeration;
import java.util.List;
import java.util.zip.ZipEntry;
import java.util.zip.ZipFile;
import java.util.zip.ZipOutputStream;
import javax.activation.MimetypesFileTypeMap;
import javax.servlet.ServletOutputStream;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.jeesite.common.codec.EncodeUtils;
import com.jeesite.common.collect.ListUtils;
import com.jeesite.common.lang.StringUtils;
import net.sf.jmimemagic.Magic;
import net.sf.jmimemagic.MagicMatch;
import org.apache.commons.io.IOUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.core.io.ClassPathResource;
import com.jeesite.common.codec.EncodeUtils;
import com.jeesite.common.collect.ListUtils;
import com.jeesite.common.lang.StringUtils;
import net.sf.jmimemagic.Magic;
import net.sf.jmimemagic.MagicMatch;
import javax.activation.MimetypesFileTypeMap;
import javax.servlet.ServletOutputStream;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.*;
import java.util.Enumeration;
import java.util.List;
import java.util.zip.ZipEntry;
import java.util.zip.ZipFile;
import java.util.zip.ZipOutputStream;
/**
* 文件操作工具类
@@ -41,6 +31,7 @@ import net.sf.jmimemagic.MagicMatch;
* @author ThinkGem
* @version 2015-3-16
*/
@SuppressWarnings("deprecation")
public class FileUtils extends org.apache.commons.io.FileUtils {
private static Logger logger = LoggerFactory.getLogger(FileUtils.class);

View File

@@ -23,6 +23,7 @@ import java.security.ProtectionDomain;
import java.util.HashSet;
import java.util.WeakHashMap;
@SuppressWarnings({"restriction", "rawtypes", "unchecked"})
class AccessClassLoader extends ClassLoader {
// Weak-references to class loaders, to avoid perm gen memory leaks, for example in app servers/web containters if the
// reflectasm library (including this class) is loaded outside the deployed applications (WAR/EAR) using ReflectASM/Kryo (exts,

View File

@@ -27,6 +27,7 @@ import java.util.Map;
import static org.springframework.asm.Opcodes.*;
@SuppressWarnings("rawtypes")
public abstract class FieldAccess {
private String[] fieldNames;
private Class[] fieldTypes;

View File

@@ -25,6 +25,7 @@ import java.util.Map;
import static org.springframework.asm.Opcodes.*;
@SuppressWarnings("rawtypes")
public abstract class MethodAccess {
private String[] methodNames;
private Class[][] parameterTypes;

View File

@@ -71,6 +71,7 @@ public class ExcelExport implements Closeable{
*/
private Map<Class<? extends FieldType>, FieldType> fieldTypes = MapUtils.newHashMap();
@SuppressWarnings("rawtypes")
private static Class dictUtilsClass = null;
/**

View File

@@ -63,6 +63,7 @@ public class ExcelImport implements Closeable {
*/
private Map<Class<? extends FieldType>, FieldType> fieldTypes = MapUtils.newHashMap();
@SuppressWarnings("rawtypes")
private static Class dictUtilsClass = null;
/**

View File

@@ -183,7 +183,6 @@ public class ServletUtils {
* 返回结果JSON字符串支持JsonP请求参数加__callback=回调函数名)
* @param result Global.TRUE or Globle.False
* @param message 执行消息
* @param data 消息数据
* @return JSON字符串{result:'true',message:''}
*/
public static String renderResult(String result, String message) {
@@ -304,7 +303,6 @@ public class ServletUtils {
/**
* 将对象转换为JSON、XML、JSONP字符串渲染到客户端JsonP请求参数加__callback=回调函数名)
* @param request 请求对象用来得到输出格式的指令JSON、XML、JSONP
* @param response 渲染对象
* @param object 待转换JSON并渲染的对象
* @return null
@@ -315,7 +313,6 @@ public class ServletUtils {
/**
* 将对象转换为JSON、XML、JSONP字符串渲染到客户端JsonP请求参数加__callback=回调函数名)
* @param request 请求对象用来得到输出格式的指令JSON、XML、JSONP
* @param response 渲染对象
* @param object 待转换JSON并渲染的对象
* @param jsonView 根据 JsonView 过滤

View File

@@ -868,7 +868,7 @@ layer.iframeAuto = function(index, diffVal, $this){
var layero = $('#'+ doms[0] + index);
var titHeight = layero.find(doms[1]).outerHeight() || 0;
var btnHeight = layero.find('.'+doms[6]).outerHeight() || 0;
// var heg = layer.getChildFrame('html', index).outerHeight();
//var heg = layer.getChildFrame('html', index).outerHeight();
var heg = iframeWin.document.body.scrollHeight;
var layerHeight = heg + titHeight + btnHeight;
var layerTop = ($(window).height() - layerHeight) / 2;
@@ -876,7 +876,7 @@ layer.iframeAuto = function(index, diffVal, $this){
var $iframe = layero.find('iframe');
if (Math.abs($iframe.height() - heg) < (diffVal || 9000)){
layero.animate({height: layerHeight, top: layerTop}, 20);
$iframe.animate({height: heg}, 20);
$iframe.animate({height: heg + 1}, 20);
}
}
}

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../../parent/pom.xml</relativePath>
</parent>

View File

@@ -4,20 +4,20 @@
*/
package com.jeesite.modules.cms.entity;
import java.util.List;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import com.jeesite.common.config.Global;
import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.lang.StringUtils;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;
import com.jeesite.modules.cms.utils.CmsUtils;
import com.jeesite.modules.sys.utils.CorpUtils;
import com.jeesite.modules.sys.utils.UserUtils;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.util.List;
/**
* 站点表Entity
* @author 长春叭哥、ThinkGem
@@ -209,15 +209,16 @@ public class Site extends DataEntity<Site> {
this.categoryList = categoryList;
}
/**
* 判断是否为当前站点
*/
public Boolean getIsCurrentSite(){
return getCurrentSiteCode().equals(siteCode);
}
public String getUrl() {
return CmsUtils.getUrlDynamic(this);
}
/**
* 判断是否为默认(主站)站点

View File

@@ -43,7 +43,6 @@ public class CmsUtils {
/**
* 获得当前站点信息
* @param siteCode 站点编号
*/
public static Site getCurrentSite() {
return getSite(Site.getCurrentSiteCode());
@@ -296,6 +295,26 @@ public class CmsUtils {
return str.toString();
}
/**
* 获得站点动态URL地址
* @param site
* @return url
*/
public static String getUrlDynamic(Site site) {
StringBuilder str = new StringBuilder();
str.append(Static.context.getContextPath()).append(Global.getFrontPath());
if (StringUtils.isNotBlank(site.getDomain())) {
if (site.getDomain().contains("://")) {
return site.getDomain();
} else {
str.append(site.getDomain());
return str.toString();
}
}
str.append("/index-").append(site.getSiteCode()).append(".html");
return str.toString();
}
/**
* 获得栏目动态URL地址
* @param category

View File

@@ -14,4 +14,5 @@
5.1.0
5.2.0
5.2.1
5.3.0
5.3.0
5.3.1

View File

@@ -129,7 +129,7 @@ $('#dataGrid').dataGrid({
}},
{header:'${text('操作')}', name:'actions', width:120, formatter: function(val, obj, row, act){
var actions = [];
<% if(hasPermi('cms:comment:edit')){ %>
//<% if(hasPermi('cms:comment:edit')){ %>
actions.push('<a href="${ctx}/cms/comment/form?id='+row.id+'" class="btnList" title="${text('编辑文章评论表')}"><i class="fa fa-pencil"></i></a>&nbsp;');
if (row.status == Global.STATUS_NORMAL){
actions.push('<a href="${ctx}/cms/comment/disable?id='+row.id+'" class="btnList" title="${text('停用文章评论表')}" data-confirm="${text('确认要停用该文章评论表吗')}"><i class="glyphicon glyphicon-ban-circle"></i></a>&nbsp;');
@@ -138,7 +138,7 @@ $('#dataGrid').dataGrid({
actions.push('<a href="${ctx}/cms/comment/enable?id='+row.id+'" class="btnList" title="${text('启用文章评论表')}" data-confirm="${text('确认要启用该文章评论表吗')}"><i class="glyphicon glyphicon-ok-circle"></i></a>&nbsp;');
}
actions.push('<a href="${ctx}/cms/comment/delete?id='+row.id+'" class="btnList" title="${text('删除文章评论表')}" data-confirm="${text('确认要删除该文章评论表吗')}"><i class="fa fa-trash-o"></i></a>&nbsp;');
<% } %>
//<% } %>
return actions.join('');
}}
],

View File

@@ -1,15 +1,15 @@
<div class="row"><br/>
<ul class="breadcrumb">
<li><span style="color:#999;">当前位置:</span><a href="${ctx}/index-${site.siteCode}">首页</a></li>
<li><span style="color:#999;">当前位置:</span><a href="${site.url}">首页</a></li>
<%
var pcs = @StringUtils.split(category.parentCodes, ',');
var tns = @StringUtils.split(category.treeNames, '/');
for(var i = 0; i < pcs.~size - 1; i++){
%>
<li><a href="${ctx}/list-${pcs[i+1]}">${tns[i]}</a></li>
<li><a href="${ctx}/list-${pcs[i+1]}.html">${tns[i]}</a></li>
<%
}
%>
<li><a href="${ctx}/list-${category.categoryCode}">${category.categoryName}</a></li>
<li><a href="${category.url}">${category.categoryName}</a></li>
</ul>
</div>

View File

@@ -4,7 +4,7 @@
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<a href="${ctx}/index-${site.siteCode}" class="navbar-brand">${site.title}</a>
<a href="${site.url}" class="navbar-brand">${site.title}</a>
<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#navbar-main">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
@@ -16,7 +16,7 @@
<#html:foreach items="${categoryList(site.siteCode, '0', 4, '')}" var="c">
<#html:if test="${c.inMenu == @Global.YES}">
<li class="${c.categoryCode == category.categoryCode! ? 'active' : ''}"><a
href="${ctx}/list-${c.categoryCode}">${c.categoryName}</a></li>
href="${c.url}">${c.categoryName}</a></li>
</#html:if>
</#html:foreach>
<li><a href="http://s.jeesite.com" target="_blank">技术服务</a></li>
@@ -24,7 +24,7 @@
<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="站点">子站切换 <span class="caret"></span></a>
<ul class="dropdown-menu">
<#html:foreach items="${siteList()}" var="site,status">
<li><a href="#" onclick="location='${ctx}/index-${site.id}'">${site.title}</a></li>
<li><a href="#" onclick="location='${site.url}'">${site.title}</a></li>
</#html:foreach>
</ul>
</li>

View File

@@ -15,7 +15,7 @@
<div class="bs-component">
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title"><small><a href="${ctx}/list-${category.categoryCode}" class="pull-right more">更多&gt;&gt;</a></small>${category.categoryName}</h3>
<h3 class="panel-title"><small><a href="${category.url}" class="pull-right more">更多&gt;&gt;</a></small>${category.categoryName}</h3>
</div>
<div class="panel-body">
<ul class="article-list">

View File

@@ -21,7 +21,7 @@
<div class="pagination">${@page.toHtml()}</div>
<script type="text/javascript">
function page(n,s){
location="${ctx}/list-${category.categoryCode}?pageNo="+n+"&pageSize="+s;
location="${category.url}?pageNo="+n+"&pageSize="+s;
}
</script>
</#html:if>

View File

@@ -18,7 +18,7 @@
<div class="bs-component">
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title"><small><a href="${ctx}/list-${category.categoryCode}" class="pull-right more">更多&gt;&gt;</a></small>${category.categoryName}</h3>
<h3 class="panel-title"><small><a href="${category.url}" class="pull-right more">更多&gt;&gt;</a></small>${category.categoryName}</h3>
</div>
<div class="panel-body">
<ul class="article-list">

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../../parent/pom.xml</relativePath>
</parent>
@@ -40,11 +40,13 @@
<dependency>
<groupId>com.oracle.ojdbc</groupId>
<artifactId>ojdbc8</artifactId>
<version>19.3.0.0</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.oracle.ojdbc</groupId>
<artifactId>orai18n</artifactId>
<version>19.3.0.0</version>
<scope>runtime</scope>
</dependency> -->
<!-- SqlServer 2008 -->

View File

@@ -300,7 +300,7 @@ public class FormFilter extends org.apache.shiro.web.filter.authc.FormAuthentica
authorizingRealm.onLoginSuccess(UserUtils.getLoginInfo(), request);
// 跳转到登录成功页面
String successUrl = getSuccessUrl(); // shiro.successUrl in application.yml
if (StringUtils.contains((request).getRequestURI(), "/oauth2/")) {
if (StringUtils.contains((request).getRequestURI(), "/oauth2/callback/")) {
successUrl = Global.getConfig("oauth2.successUrl", successUrl);
}
ServletUtils.redirectUrl(request, (HttpServletResponse)response, successUrl);

View File

@@ -4,12 +4,6 @@
*/
package com.jeesite.common.shiro.realm;
import javax.servlet.http.HttpServletRequest;
import org.apache.shiro.authc.AuthenticationException;
import org.apache.shiro.authc.AuthenticationInfo;
import org.apache.shiro.authc.AuthenticationToken;
import com.jeesite.common.codec.EncodeUtils;
import com.jeesite.common.codec.Sha1Utils;
import com.jeesite.common.shiro.authc.FormToken;
@@ -19,6 +13,11 @@ import com.jeesite.modules.sys.entity.User;
import com.jeesite.modules.sys.service.UserService;
import com.jeesite.modules.sys.utils.LogUtils;
import com.jeesite.modules.sys.utils.UserUtils;
import org.apache.shiro.authc.AuthenticationException;
import org.apache.shiro.authc.AuthenticationInfo;
import org.apache.shiro.authc.AuthenticationToken;
import javax.servlet.http.HttpServletRequest;
/**
* 系统认证授权实现类
@@ -51,12 +50,13 @@ public class AuthorizingRealm extends BaseAuthorizingRealm {
/**
* 用于用户根据登录信息获取用户信息<br>
* 1、默认根据登录账号登录信息UserUtils.getByLoginCode(token.getUsername(), token.getParam("corpCode"));<br>
* 2、如果增加其它登录,请重写此方法,如根据手机号或邮箱登录返回用户信息。
* 1、默认根据登录账号登录信息UserUtils.getByLoginCode(formToken.getUsername(), formToken.getParam("corpCode"));<br>
* 2、中断操作,可抛出异常提示用户 throw new AuthenticationException("msg:登录失败");<br>
* 3、如果增加其它登录方式请重写此方法如根据手机号或邮箱登录返回用户信息。
*/
@Override
protected User getUserInfo(FormToken token) {
return super.getUserInfo(token);
protected User getUserInfo(FormToken formToken) {
return super.getUserInfo(formToken);
}
/**

View File

@@ -1,48 +0,0 @@
/**
* Copyright (c) 2013-Now http://jeesite.com All rights reserved.
* No deletion without permission, or be held responsible to law.
*/
package com.jeesite.modules.config.web;
/**
* 页面缓存,如果需要,则加入如下依赖并取消下面注释
1、pom.xml:
<dependency>
<groupId>net.sf.ehcache</groupId>
<artifactId>ehcache-web</artifactId>
<version>2.0.4</version>
</dependency>
2、application.yml:
# 页面缓存配置
ehcache:
pageCaching:
enabled: false
urlPatterns: "*.html"
* @author ThinkGem
* @version 2017年11月30日
*/
//@Configuration
public class PageCacheConfig {
// /**
// * PageCache Filter, cache .html suffix.
// */
// @Bean
// @Order(2000)
// @ConditionalOnProperty(name = "ehcache.pageCaching.enabled", havingValue = "true")
// @ConditionalOnMissingBean(name="pageCachingFilter")
// public FilterRegistrationBean<PageCachingFilter> pageCachingFilter(EhCacheManagerFactoryBean ehCacheManager) {
// FilterRegistrationBean<PageCachingFilter> bean = new FilterRegistrationBean<>();
// SimplePageCachingFilter pageCachingFilter = new SimplePageCachingFilter();
// pageCachingFilter.setCacheManager(ehCacheManager.getObject());
// bean.setFilter(pageCachingFilter);
// bean.addInitParameter("cacheName", "pageCachingFilter");
// bean.addUrlPatterns(StringUtils.split(Global.getProperty(
// "ehcache.pageCaching.urlPatterns"), ","));
// return bean;
// }
}

View File

@@ -26,7 +26,7 @@ public interface EmpUserService extends CrudServiceApi<EmpUser> {
/**
* 添加数据权限过滤条件
* @param entity 控制对象
* @param empUser 控制对象
* @param ctrlPermi 控制权限类型拥有的数据权限DataScope.CTRL_PERMI_HAVE、可管理的数据权限DataScope.CTRL_PERMI_HAVE
*/
@Override

View File

@@ -461,7 +461,7 @@ session:
# 会话超时时间单位毫秒10m=600000, 20m=1200000ms, 30m=1800000ms, 60m=3600000ms, 12h=43200000ms, 1day=86400000ms
# 注意如果超时超过30m你还需要同步修改当前配置文件的属性j2cache.caffeine.region.sessionCache 超时时间,大于这个值。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为10分钟,如:未登录系统时的图片验证码有效时间。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为3分钟,如:未登录系统时的图片验证码有效时间。
sessionTimeout: 180000
# 登录系统后的用户超时时间(不明确 param_deviceType 参数的,默认设备为 pc 登录)
@@ -533,8 +533,11 @@ j2cache:
# MyBatis 相关
mybatis:
# @MyBatisDao、Aliases 扫描基础包,如果多个,用“,”分隔
scanBasePackage: com.jeesite.modules
# @MyBatisDao 扫描基础包,如果多个,用“,”分隔
#scanBasePackage: com.jeesite.modules.**.dao
# TypeAliases 扫描基础包,如果多个,用“,”分隔 v5.3.1
#scanTypeAliasesBasePackage: com.jeesite.modules.**.entity
# TypeHandlers 扫描基础包,如果多个,用“,”分隔
scanTypeHandlersPackage: ~

View File

@@ -1,7 +1,7 @@
# =========== 登录登出相关 ===========
sys.login.notLongIn=No login or login timeout.Please login again, thank you!
sys.login.notLongIn=Your login information has expired. Please log in again.
sys.login.success=Login successful!
sys.login.getInfo=Get info successful!
sys.login.failure=Account or password error, please try again.

View File

@@ -1,7 +1,7 @@
# =========== 登录登出相关 ===========
sys.login.notLongIn=ログインしていないか、またはログインがタイムアウトしました。もう一度ログインしてください
sys.login.notLongIn=ログイン情報が期限切れになっています。再度ログインしてください
sys.login.success=ログイン成功!
sys.login.getInfo=情報取得成功!
sys.login.failure=ログインID或いはパスワードに誤りがあります。もう一度にゅうしてください。

View File

@@ -1,7 +1,7 @@
# =========== 登录登出相关 ===========
sys.login.notLongIn=未登录或登录超时。请重新登录,谢谢!
sys.login.notLongIn=您的登录信息已过期,请重新登录
sys.login.success=登录成功!
sys.login.getInfo=获取信息成功!
sys.login.failure=账号或密码错误,请重试。

View File

@@ -233,6 +233,7 @@
<template>module_cloud/web/src/main/webapp/WEB-INF/startup.bat.xml</template>
<template>module_cloud/web/src/main/webapp/WEB-INF/startup.sh.xml</template>
<template>module_cloud/web/pom.xml</template>
<template>module_cloud/pom.xml</template>
</category>
</moduleTplCategory>
</config>

View File

@@ -104,7 +104,7 @@ public class ${ClassName}Service extends ${table.isTreeEntity?'Tree':'Crud'}Serv
/**
* 查询子表分页数据
* @param ${@StringUtils.uncap(child.className)}
* @param ${@StringUtils.uncap(child.className)}.page 分页对象
* @param ${@StringUtils.uncap(child.className)} page 分页对象
* @return
*/
public Page<${@StringUtils.cap(child.className)}> findSubPage(${@StringUtils.cap(child.className)} ${@StringUtils.uncap(child.className)}) {

View File

@@ -545,7 +545,7 @@ for (c in table.columnList){
});
}
if (!${@StringUtils.uncap(child.className)}ListValid) {
throw new Error('${@StringUtils.uncap(child.className)}List valid.');
throw { errorFields: [{ name: ['${@StringUtils.uncap(child.className)}List'] }] };
}
return ${@StringUtils.uncap(child.className)}List;
}

View File

@@ -110,7 +110,7 @@ public class ${ClassName}Service extends ${table.isTreeEntity?'Tree':'Crud'}Serv
/**
* 查询子表分页数据
* @param ${@StringUtils.uncap(child.className)}
* @param ${@StringUtils.uncap(child.className)}.page 分页对象
* @param ${@StringUtils.uncap(child.className)} page 分页对象
* @return
*/
public Page<${@StringUtils.cap(child.className)}> findSubPage(${@StringUtils.cap(child.className)} ${@StringUtils.uncap(child.className)}) {

View File

@@ -89,11 +89,7 @@ $('#btnDraft').click(function(){
});
// 流程按钮操作事件
BpmButton = window.BpmButton || {};
BpmButton.init = function(task){
if (task && task.priority){
$('#bpm_priority').val(task.priority).trigger('change'); // 设置下一个任务的优先级
}
}
BpmButton.init = function(task){}
BpmButton.complete = function($this, task){
$('#status').val(Global.STATUS_AUDIT);
};

View File

@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2013-Now http://jeesite.com All rights reserved.
No deletion without permission, or be held responsible to law. -->
<template>
<name>pom</name>
<filePath>${baseDir}/${moduleCode}</filePath>
<fileName>pom.xml</fileName>
<charset></charset>
<content><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-cloud-module-${moduleCode}</artifactId>
<version>${jeesiteVersion}-SNAPSHOT</version>
<packaging>pom</packaging>
<name>JeeSite Cloud Module ${moduleName}</name>
<url>http://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>
<modules>
<module>${moduleCode}</module>
<module>${moduleCode}-client</module>
</modules>
<developers>
<developer>
<id>thinkgem</id>
<name>WangZhen</name>
<email>thinkgem at 163.com</email>
<roles><role>Project lead</role></roles>
<timezone>+8</timezone>
</developer>
</developers>
<organization>
<name>JeeSite</name>
<url>http://jeesite.com</url>
</organization>
</project>
]]>
</content>
</template>

View File

@@ -18,10 +18,10 @@
<relativePath>../../../parent/web/pom.xml</relativePath>
</parent>
<artifactId>jeesite-cloud-module-${moduleCode}</artifactId>
<artifactId>jeesite-cloud-module-${moduleCode}-web</artifactId>
<packaging>war</packaging>
<name>JeeSite Cloud Module ${moduleName}</name>
<name>JeeSite Cloud Module ${moduleName} Web</name>
<url>http://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>

View File

@@ -31,7 +31,8 @@ eureka:
# 客户端设置
client:
# 注册中心地址(集群时指定另外一个注册中心地址)
serviceUrl.defaultZone: http://127.0.0.1:8970/eureka/
serviceUrl:
defaultZone: http://127.0.0.1:8970/eureka/
#======================================#
#========== Spring settings ===========#

View File

@@ -3,7 +3,7 @@
No deletion without permission, or be held responsible to law. -->
<template>
<name>run-web</name>
<filePath>${module.moduleCode}/${module.moduleCode}/src/main/webapp/WEB-INF</filePath>
<filePath>${baseDir}/${moduleCode}/${moduleCode}/src/main/webapp/WEB-INF</filePath>
<fileName>startup.bat</fileName>
<content><![CDATA[chcp 65001
@echo off

View File

@@ -3,7 +3,7 @@
No deletion without permission, or be held responsible to law. -->
<template>
<name>run-web</name>
<filePath>${module.moduleCode}/${module.moduleCode}/src/main/webapp/WEB-INF</filePath>
<filePath>${baseDir}/${moduleCode}/${moduleCode}/src/main/webapp/WEB-INF</filePath>
<fileName>startup.sh</fileName>
<content><![CDATA[#!/bin/sh
# /**

View File

@@ -83,7 +83,7 @@ public class ${ClassName}Service extends ${table.isTreeEntity?'Tree':'Query'}Ser
/**
* 查询子表分页数据
* @param ${@StringUtils.uncap(child.className)}
* @param ${@StringUtils.uncap(child.className)}.page 分页对象
* @param ${@StringUtils.uncap(child.className)} page 分页对象
* @return
*/
public Page<${@StringUtils.cap(child.className)}> findSubPage(${@StringUtils.cap(child.className)} ${@StringUtils.uncap(child.className)}) {

View File

@@ -732,7 +732,9 @@ $(function(){
var footerHeight = $('.main-footer').outerHeight() || 0;
var windowHeight = $(window).height();
$('.content').css('min-height', windowHeight - footerHeight);
myChart1.resize(); myChart2.resize(); myChart3.resize();
if(myChart1) myChart1.resize();
if(myChart2) myChart2.resize();
if(myChart3) myChart3.resize();
}).resize();
$('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
$(window).resize();

35
modules/pom.xml Normal file
View File

@@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-modules</artifactId>
<version>5.3.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>JeeSite Modules</name>
<url>http://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>
<modules>
<module>core</module>
<module>cms</module>
</modules>
<developers>
<developer>
<id>thinkgem</id>
<name>WangZhen</name>
<email>thinkgem at 163.com</email>
<roles><role>Project lead</role></roles>
<timezone>+8</timezone>
</developer>
</developers>
<organization>
<name>JeeSite</name>
<url>http://jeesite.com</url>
</organization>
</project>

View File

@@ -6,13 +6,13 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.7.9</version>
<version>2.7.10</version>
<relativePath />
</parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>JeeSite Parent</name>

View File

@@ -5,7 +5,7 @@
<groupId>com.jeesite</groupId>
<artifactId>jeesite</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>JeeSite</name>

View File

@@ -5,7 +5,7 @@
<groupId>com.jeesite</groupId>
<artifactId>jeesite-root</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>JeeSite Root</name>
@@ -15,8 +15,7 @@
<modules>
<module>../parent</module>
<module>../common</module>
<module>../modules/core</module>
<module>../modules/cms</module>
<module>../modules</module>
<module>../web</module>
<module>../web-api</module>
<module>../web-fast</module>

View File

@@ -24,4 +24,4 @@ cd app
jar -xvf web.war
rm web.war
cd WEB-INF
sh ./startup.sh
sh ./startup.sh

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>
@@ -88,7 +88,7 @@
<build>
<finalName>${finalName}</finalName>
<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>
<!--<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>-->
<plugins>
<!-- Spring Boot -->

View File

@@ -49,8 +49,8 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
/**
* 查询分页数据
* @param page 分页对象
* @param testData
* @param testData page 分页对象
* @param testData 查询条件
* @return
*/
@Override
@@ -70,8 +70,8 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
/**
* 查询子表分页数据
* @param page 分页对象
* @param testData
* @param testData 查询条件
* @param testData page 分页对象
* @return
*/
public List<TestDataChild> findSubList(TestDataChild testData) {

View File

@@ -625,7 +625,7 @@ session:
# 会话超时时间单位毫秒10m=600000, 20m=1200000ms, 30m=1800000ms, 60m=3600000ms, 12h=43200000ms, 1day=86400000ms
# 注意如果超时超过30m你还需要同步修改当前配置文件的属性j2cache.caffeine.region.sessionCache 超时时间,大于这个值。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为10分钟,如:未登录系统时的图片验证码有效时间。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为3分钟,如:未登录系统时的图片验证码有效时间。
sessionTimeout: 180000
# 登录系统后的用户超时时间(不明确 param_deviceType 参数的,默认设备为 pc 登录)
@@ -697,8 +697,11 @@ session:
# MyBatis 相关
mybatis:
# @MyBatisDao、Aliases 扫描基础包,如果多个,用“,”分隔
scanBasePackage: com.jeesite.modules
# @MyBatisDao 扫描基础包,如果多个,用“,”分隔
scanBasePackage: com.jeesite.modules.**.dao
# TypeAliases 扫描基础包,如果多个,用“,”分隔 v5.3.1
scanTypeAliasesBasePackage: com.jeesite.modules.**.entity
# # TypeHandlers 扫描基础包,如果多个,用“,”分隔
# scanTypeHandlersPackage: ~

View File

@@ -17,4 +17,4 @@ mvn clean package spring-boot:repackage -Dmaven.test.skip=true -U
# 启动服务
cd target
java -jar web.jar
java -jar web.jar

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>
@@ -97,7 +97,7 @@
<build>
<finalName>${finalName}</finalName>
<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>
<!--<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>-->
<plugins>
<!-- Spring Boot -->

View File

@@ -49,8 +49,8 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
/**
* 查询分页数据
* @param page 分页对象
* @param testData
* @param testData 查询条件
* @param testData page 分页对象
* @return
*/
@Override

View File

@@ -64,7 +64,7 @@ $('#dataGrid').dataGrid({
{header:'${text("备注信息")}', name:'remarks', index:'a.remarks', width:150, align:"left"},
{header:'${text("操作")}', name:'actions', width:120, formatter: function(val, obj, row, act){
var actions = [];
<% if(hasPermi('test:testTree:edit')){ %>
//<% if(hasPermi('test:testTree:edit')){ %>
actions.push('<a href="${ctx}/test/testTree/form?treeCode='+row.treeCode+'" class="btnList" title="${text("编辑数据")}"><i class="fa fa-pencil"></i></a>&nbsp;');
if (row.status == Global.STATUS_NORMAL){
actions.push('<a href="${ctx}/test/testTree/disable?treeCode='+row.treeCode+'" class="btnList" title="${text("停用数据")}" data-confirm="${text("确认要停用该数据吗?")}"><i class="glyphicon glyphicon-ban-circle"></i></a>&nbsp;');
@@ -73,7 +73,7 @@ $('#dataGrid').dataGrid({
}
actions.push('<a href="${ctx}/test/testTree/delete?treeCode='+row.treeCode+'" class="btnList" title="${text("删除数据")}" data-confirm="${text("确认要删除该数据及所有子数据吗?")}" data-deltreenode="'+row.id+'"><i class="fa fa-trash-o"></i></a>&nbsp;');
actions.push('<a href="${ctx}/test/testTree/form?parentCode='+row.id+'" class="btnList" title="${text("新增下级数据")}"><i class="fa fa-plus-square"></i></a>&nbsp;');
<% } %>
//<% } %>
return actions.join('');
}}
],

View File

@@ -24,4 +24,4 @@ cd app
jar -xvf web.war
rm web.war
cd WEB-INF
sh ./startup.sh
sh ./startup.sh

View File

@@ -6,7 +6,7 @@
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.3.0-SNAPSHOT</version>
<version>5.3.1-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>
@@ -88,7 +88,7 @@
<build>
<finalName>${finalName}</finalName>
<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>
<!--<outputDirectory>${project.basedir}/src/main/webapp/WEB-INF/classes/</outputDirectory>-->
<plugins>
<!-- Spring Boot -->

View File

@@ -38,19 +38,25 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
*/
@Override
public TestData get(TestData testData) {
TestData entity = super.get(testData);
if (entity != null){
TestDataChild testDataChild = new TestDataChild(entity);
return super.get(testData);
}
/**
* 加载子表数据
*/
public TestData loadChildData(TestData testData) {
if (testData != null && !testData.getIsNewRecord()){
TestDataChild testDataChild = new TestDataChild(testData);
testDataChild.setStatus(TestDataChild.STATUS_NORMAL);
entity.setTestDataChildList(testDataChildDao.findList(testDataChild));
testData.setTestDataChildList(testDataChildDao.findList(testDataChild));
}
return entity;
return testData;
}
/**
* 查询分页数据
* @param page 分页对象
* @param testData
* @param testData page 分页对象
* @return
*/
@Override
@@ -70,8 +76,8 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
/**
* 查询子表分页数据
* @param page 分页对象
* @param testData
* @param testData 查询条件
* @param testData page 分页对象
* @return
*/
public List<TestDataChild> findSubList(TestDataChild testData) {
@@ -146,7 +152,7 @@ public class TestDataService extends CrudService<TestDataDao, TestData> {
/**
* 事务测试,若 Child 报错,则回滚
*/
@Transactional//(propagation = Propagation.NOT_SUPPORTED)
@Transactional//(propagation=Propagation.NOT_SUPPORTED)
public void transTest(TestData testData) {
testData.setTestInput("transTest");
testData.setTestTextarea(IdGen.randomBase62(5));

View File

@@ -4,11 +4,13 @@
*/
package com.jeesite.modules.test.web;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.jeesite.common.config.Global;
import com.jeesite.common.entity.Page;
import com.jeesite.common.lang.StringUtils;
import com.jeesite.common.web.BaseController;
import com.jeesite.modules.test.entity.TestData;
import com.jeesite.modules.test.entity.TestDataChild;
import com.jeesite.modules.test.service.TestDataService;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
@@ -19,12 +21,9 @@ import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.jeesite.common.config.Global;
import com.jeesite.common.entity.Page;
import com.jeesite.common.web.BaseController;
import com.jeesite.modules.test.entity.TestData;
import com.jeesite.modules.test.entity.TestDataChild;
import com.jeesite.modules.test.service.TestDataService;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
/**
* 测试数据Controller
@@ -83,9 +82,10 @@ public class TestDataController extends BaseController {
*/
@RequiresPermissions("test:testData:view")
@RequestMapping(value = "form")
public String form(TestData testData, Model model) {
public String form(TestData testData, String flag, Model model) {
testDataService.loadChildData(testData);
model.addAttribute("testData", testData);
return "modules/test/testDataForm";
return "modules/test/testDataForm"+ StringUtils.defaultString(flag, "");
}
/**

View File

@@ -625,7 +625,7 @@ session:
# 会话超时时间单位毫秒10m=600000, 20m=1200000ms, 30m=1800000ms, 60m=3600000ms, 12h=43200000ms, 1day=86400000ms
# 注意如果超时超过30m你还需要同步修改当前配置文件的属性j2cache.caffeine.region.sessionCache 超时时间,大于这个值。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为10分钟,如:未登录系统时的图片验证码有效时间。
# 游客会话超时时间:只访问了系统,但未登录系统的用户为游客,游客默认超时时间为3分钟,如:未登录系统时的图片验证码有效时间。
sessionTimeout: 180000
# 登录系统后的用户超时时间(不明确 param_deviceType 参数的,默认设备为 pc 登录)
@@ -697,8 +697,11 @@ session:
# MyBatis 相关
mybatis:
# @MyBatisDao、Aliases 扫描基础包,如果多个,用“,”分隔
scanBasePackage: com.jeesite.modules
# @MyBatisDao 扫描基础包,如果多个,用“,”分隔
scanBasePackage: com.jeesite.modules.**.dao
# TypeAliases 扫描基础包,如果多个,用“,”分隔 v5.3.1
scanTypeAliasesBasePackage: com.jeesite.modules.**.entity
# # TypeHandlers 扫描基础包,如果多个,用“,”分隔
# scanTypeHandlersPackage: ~

View File

@@ -0,0 +1,478 @@
<% layout('/layouts/default.html', {title: '数据管理', libs: ['validate','fileupload','dataGrid']}){ %>
<div class="main-content">
<div class="box box-main">
<div class="box-header with-border">
<div class="box-title">
<i class="fa icon-note"></i> ${text(testData.isNewRecord ? '新增数据' : '编辑数据')}
</div>
<div class="box-tools pull-right">
<button type="button" class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button>
</div>
</div>
<#form:form id="inputForm" model="${testData}" action="${ctx}/test/testData/save" method="post" class="form-horizontal">
<div class="box-body">
<div class="form-unit">${text('基本信息')}</div>
<#form:hidden path="id"/>
<div class="row">
<div class="col-xs-12">
<div class="form-group">
<label class="control-label col-sm-2" title="">
<span class="required hide">*</span> ${text('单行文本')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-10">
<#form:input path="testInput" maxlength="200" class="form-control"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12">
<div class="form-group">
<label class="control-label col-sm-2" title="">
<span class="required hide">*</span> ${text('多行文本')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-10">
<#form:textarea path="testTextarea" rows="4" maxlength="200" class="form-control"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('下拉框')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:select path="testSelect" dictType="sys_menu_type" blankOption="true" class="form-control" />
</div>
</div>
</div>
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('下拉多选')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:select path="testSelectMultiple" dictType="sys_menu_type" multiple="true" blankOption="true" class="form-control" />
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('单选框')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:radio path="testRadio" dictType="sys_menu_type" class="form-control" />
</div>
</div>
</div>
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('复选框')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:checkbox path="testCheckbox" dictType="sys_menu_type" class="form-control" />
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('日期选择')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:input path="testDate" readonly="true" maxlength="20" class="form-control laydate"
dataFormat="date" data-type="date" data-format="yyyy-MM-dd"/>
</div>
</div>
</div>
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('日期时间')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:input path="testDatetime" readonly="true" maxlength="20" class="form-control laydate"
dataFormat="datetime" data-type="datetime" data-format="yyyy-MM-dd HH:mm"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('用户选择')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:treeselect id="testUser" title="${text('用户选择')}"
path="testUser.userCode" labelPath="testUser.userName"
url="${ctx}/sys/office/treeData?isLoadUser=true"
class="" allowClear="true"/>
</div>
</div>
</div>
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('机构选择')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:treeselect id="testOffice" title="${text('机构选择')}"
path="testOffice.officeCode" labelPath="testOffice.officeName"
url="${ctx}/sys/office/treeData"
class="" allowClear="true"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-6">
<div class="form-group">
<label class="control-label col-sm-4" title="">
<span class="required hide">*</span> ${text('区域选择')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-8">
<#form:treeselect id="testAreaCode" title="${text('区域选择')}"
path="testAreaCode" labelPath="testAreaName"
url="${ctx}/sys/area/treeData"
class="" allowClear="true"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12">
<div class="form-group">
<label class="control-label col-sm-2" title="">
<span class="required hide">*</span> ${text('备注信息')}<i class="fa icon-question hide"></i></label>
<div class="col-sm-10">
<#form:textarea path="remarks" rows="4" maxlength="500" class="form-control"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12">
<div class="form-group">
<label class="control-label col-sm-2">${text('图片上传')}</label>
<div class="col-sm-10">
<#form:fileupload id="uploadImage" bizKey="${testData.id}" bizType="testData_image"
uploadType="image" class="" readonly="false" preview="true"/>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-xs-12">
<div class="form-group">
<label class="control-label col-sm-2">${text('附件上传')}</label>
<div class="col-sm-10">
<#form:fileupload id="uploadFile" bizKey="${testData.id}" bizType="testData_file"
uploadType="all" class="" readonly="false" preview="true"/>
</div>
</div>
</div>
</div>
<h4 class="form-unit">${text('子表数据')}</h4>
<div class="ml10 mr10 table-form">
<table id="testDataChildDataGrid"></table>
<% if (hasPermi('test:testData:edit')){ %>
<a href="#" id="testDataChildDataGridAddRowBtn" class="btn btn-primary btn-sm mt10 mb10"><i class="fa fa-plus"></i> ${text('增行')}</a>
<% } %>
</div>
</div>
<div class="box-footer">
<div class="row">
<div class="col-sm-offset-2 col-sm-10">
<% if (hasPermi('test:testData:edit')){ %>
<button type="submit" class="btn btn-sm btn-primary" id="btnSubmit"><i class="fa fa-check"></i> ${text('保 存')}</button>&nbsp;
<% } %>
<button type="button" class="btn btn-sm btn-default" id="btnCancel" onclick="js.closeCurrentTabPage()"><i class="fa fa-reply-all"></i> ${text('关 闭')}</button>
</div>
</div>
</div>
</#form:form>
</div>
</div>
<% } %>
<script id="treeselectTpl" type="text/template">//<!--<div>
<#form:treeselect id="{{d.id}}" title="{{d.title}}" name="{{d.name}}" value="{{d.value}}"
labelName="{{d.labelName}}" labelValue="{{d.labelValue}}" url="{{d.url}}"
class="{{d.cssClass}}" btnClass="btn-sm" allowClear="true" readonly="{{d.readonly}}"/>
</div>//--></script>
<script id="listselectTpl" type="text/template">//<!--<div>
<#form:listselect id="{{d.id}}" title="{{d.title}}" name="{{d.name}}" value="{{d.value}}"
labelName="{{d.labelName}}" labelValue="{{d.labelValue}}" url="{{d.url}}"
class="{{d.cssClass}}" btnClass="btn-sm" allowClear="true" readonly="{{d.readonly}}"
itemCode="{{d.itemCode}}" itemName="{{d.itemName}}"/>
</div>//--></script>
<script id="fileuploadTpl" type="text/template">//<!--<div>
<#form:fileupload id="{{d.id}}" bizKey="{{d.bizKey}}" bizType="{{d.bizType}}" uploadType="all"
class="{{d.cssClass}}" isMini="true" preview="true" readonly="{{d.readonly}}"/>
</div>//--></script>
<script>
//初始化测试数据子表DataGrid对象
$("#testDataChildDataGrid").dataGrid({
data: ${toJson(testData.testDataChildList)},
datatype: "local", // 设置本地数据
autoGridHeight: function(){return 'auto'}, // 设置自动高度
// 设置数据表格列
columnModel: [
{header:'${text("操作")}', name:'actions', width:40, align:"center", formatter: function(val, obj, row, act){
var actions = [];
if (val == 'new'){
actions.push('<a href="#" onclick="js.confirm(\'${text("你确认要删除这条数据吗?")}\', function(){$(\'#testDataChildDataGrid\').dataGrid(\'delRowData\',\''+obj.rowId+'\')});return false;"><i class="fa fa-trash-o"></i></a>&nbsp;');
}else{
actions.push('<a href="#" onclick="js.confirm(\'${text("你确认要删除这条数据吗?")}\', function(){$(\'#testDataChildDataGrid\').dataGrid(\'setRowData\',\''+obj.rowId+'\',null,{display:\'none\'});$(\'#'+obj.rowId+'_status\').val(\''+Global.STATUS_DELETE+'\');});return false;"><i class="fa fa-trash-o"></i></a>&nbsp;');
}
//actions.push('<a href="#" onclick="$(\'#testDataChildDataGrid\').dataGrid(\'editRow\',\''+obj.rowId+'\',{keys:true,focusField:true});return false;"><i class="fa fa-pencil"></i></a>&nbsp;');
return actions.join('');
}, editoptions: {defaultValue: 'new'}},
{header:'状态', name:'status', editable:true, hidden:true},
{header:'主键', name:'id', editable:true, hidden:true},
{header:'${text("排序号")}', name:'testSort', width:100, editable:true, edittype:'text', editoptions:{'maxlength':'11', 'class':'form-control digits'}},
{header:'${text("父表主键")}', name:'testData.id', editable:true, hidden:true},
{header:'${text("单行文本")}', name:'testInput', width:100, editable:true, edittype:'text', editoptions:{'maxlength':'200', 'class':'form-control'}},
{header:'${text("多行文本")}', name:'testTextarea', width:100, editable:true, edittype:'textarea', editoptions:{'maxlength':'200', 'class':'form-control', 'rows':'1'}},
{header:'${text("下拉框")}', name:'testSelect', width:100,
formatter: function(val, obj, row, act){
return js.getDictLabel(obj.colModel.editoptions.items, val, '${text("未知")}', true);
},
unformat: function(val, obj, cell){
return val;
},
editable:true, edittype:'select', editoptions:{'class':'form-control',
items: $.merge([{dictLabel:'&nbsp;',dictValue:''}], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
js.select2(element).on("change",function(){$(this).resetValid()});
}
}
},
{header:'${text("下拉多选")}', name:'testSelectMultiple', width:90, fixed: true,
formatter: function(val, obj, row, act){
return js.getDictLabel(obj.colModel.editoptions.items, val, '${text("未知")}', true);
},
unformat: function(val, obj, cell){
return val;
},
editable:true, edittype:'select', editoptions:{multiple:true, 'class':'form-control',
items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
js.select2(element).on("change",function(){$(this).resetValid()});
}
}
},
{header:'${text("单选框")}', name:'testRadio', width:135, fixed: true,
formatter: function(val, obj, row, act){
return js.getDictLabel(obj.colModel.editoptions.items, val, '${text("未知")}', true);
},
unformat: function(val, obj, cell){
return val;
},
editable:true, edittype:'radio', editoptions:{'class':'form-control icheck',
items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
js.iCheck(element).on("ifChanged",function(){$(this).resetValid()});
}
}
},
{header:'${text("复选框")}', name:'testCheckbox', width:135, fixed: true,
formatter: function(val, obj, row, act){
return js.getDictLabel(${@DictUtils.getDictListJson('sys_menu_type')}, val, '${text("未知")}', true);
},
unformat: function(val, obj, cell){
return val;
},
editable:true, edittype:'checkbox', editoptions:{'class':'form-control icheck',
items: $.merge([], ${@DictUtils.getDictListJson('sys_menu_type')}),
itemLabel: 'dictLabel', itemValue: 'dictValue', dataInit: function(element){
js.iCheck(element).on("ifChanged",function(){$(this).resetValid()});
}
}
},
{header:'${text("日期选择")}', name:'testDate', width:120,
formatter:'date', formatoptions:{srcformat:'Y-m-d H:i:s',newformat:'Y-m-d'},
editable:true, edittype:'text', editoptions:{'class':'form-control laydate', 'readonly':'true',
dataInit: function(element){
laydate.render({elem:element, type:'date', format:'yyyy-MM-dd', done: function(){
// 选择日期后,自动给下一个输入框赋值(联动实例)
// $(element).closest('td').next().find('.form-control').val('2020-11-26 10:10');
}});
}
}
},
{header:'${text("日期时间")}', name:'testDatetime', width:155,
formatter:'date', formatoptions:{srcformat:'Y-m-d H:i:s',newformat:'Y-m-d H:i'},
editable:true, edittype:'text', editoptions:{'class':'form-control laydate', 'readonly':'true',
dataInit: function(element){
laydate.render({elem:element, type:'datetime', format:'yyyy-MM-dd HH:mm'});
}
}
},
{header:'${text("用户选择")}', name:'testUser', width:100,
formatter: function(val, obj, row, act){
return js.val(row, 'testUser.userName');
},
unformat: function(val, obj, cell){
return js.val(obj.colModel.data[obj.rowId], 'userCode')
+ '|' + js.val(obj.colModel.data[obj.rowId], 'userName');
},
editable: true, edittype: "custom", editoptions: {
custom_element: function(val, editOptions) {
return js.template('treeselectTpl', {
id: 'user_'+editOptions.id, title: '用户选择',
name: 'testUser.userCode', value: val.split('|')[0],
labelName: 'testUser.userName', labelValue: val.split('|')[1],
url: '${ctx}/sys/office/treeData?isLoadUser=true', cssClass: '', readonly: false
});
},
custom_value: function(element, act){
return {userCode: element.find('[type=hidden]').val(),
userName: element.find('[type=text]').val()};
},
dataInit: function(element){
// 初始化控件后设置只读模式(实例)
// $(element).find('.form-control, .btn').addClass('disabled');
}
},
},
{header:'${text("列表选择")}', name:'testUser2', width:100,
formatter: function(val, obj, row, act){
obj.colModel.data[obj.rowId] = row.testUser;
return js.val(row, 'testUser.userName');
},
unformat: function(val, obj, cell){
return js.val(obj.colModel.data[obj.rowId], 'userCode')
+ '|' + js.val(obj.colModel.data[obj.rowId], 'userName');
},
editable: true, edittype: "custom", editoptions: {
custom_element: function(val, editOptions) {
return js.template('listselectTpl', {
id: 'user_'+editOptions.id, title: '用户选择',
name: 'testUser2.userCode', value: val.split('|')[0],
labelName: 'testUser2.userName', labelValue: val.split('|')[1],
url: '${ctx}/sys/empUser/empUserSelect', cssClass: '', readonly: false,
itemCode: 'userCode', itemName: 'userName'
});
},
custom_value: function(element, act){
return {userCode2: element.find('[type=hidden]').val(),
userName2: element.find('[type=text]').val()};
}
}
},
{header:'${text("机构选择")}', name:'testOffice', width:100, title:false,
formatter: function(val, obj, row, act){
return js.val(row, 'testOffice.officeName');
},
unformat: function(val, obj, cell){
return js.val(obj.colModel.data[obj.rowId], 'officeCode')
+ '|' + js.val(obj.colModel.data[obj.rowId], 'officeName');
},
editable: true, edittype: "custom", editoptions: {
custom_element: function(val, editOptions) {
return js.template('treeselectTpl', {
id: 'office_'+editOptions.id, title: '机构选择',
name: 'testOffice.officeCode', value: val.split('|')[0],
labelName: 'testOffice.officeName', labelValue: val.split('|')[1],
url: '${ctx}/sys/office/treeData?officeTypes=1,2', cssClass: '', readonly: false
});
},
custom_value: function(element, act){
return {officeCode: element.find('[type=hidden]').val(),
officeName: element.find('[type=text]').val()};
}
}
},
{header:'${text("区域选择")}', name:'testAreaCode', width:100,
formatter: function(val, obj, row, act){
obj.colModel.data[obj.rowId] = {
testAreaCode: row.testAreaCode,
testAreaName: row.testAreaName
};
return js.val(row, 'testAreaName');
},
unformat: function(val, obj, cell){
return js.val(obj.colModel.data[obj.rowId], 'testAreaCode')
+ '|' + js.val(obj.colModel.data[obj.rowId], 'testAreaName');
},
editable: true, edittype: "custom", editoptions: {
custom_element: function(val, editOptions) {
return js.template('treeselectTpl', {
id: 'area_'+editOptions.id, title: '区域选择',
name: 'testAreaCode', value: val.split('|')[0],
labelName: 'testAreaName', labelValue: val.split('|')[1],
url: '${ctx}/sys/area/treeData', cssClass: '', readonly: false
});
},
custom_value: function(element, act){
return {areaCode: element.find('[type=hidden]').val(),
areaName: element.find('[type=text]').val()};
}
}
},
{header:'${text("文件上传")}', name:'id', width:200, classes:'editable',
formatter: function(val, obj, row, act){
return '<button type="button" class="btn btn-xs btn-default uploaderFile" data-val="'
+(obj.rowId)+'">查看文件</button>';
},
editable: true, edittype: "custom", editoptions: {
custom_element: function(val, editOptions) {
log(val, editOptions)
return js.template('fileuploadTpl', {
id: 'fileupload_'+editOptions.rowId, bizKey: editOptions.rowId,
bizType: 'testDataChild_file', cssClass: '', readonly: false
});
}
}
}
],
onSelectRow: function(id, stat, e) {
if (id && e && !$(e.target).hasClass('btn')){
$('#testDataChildDataGrid').dataGrid('editRow', id,{keys:true,focusField:true});
}
},
shrinkToFit: false, // 是否按百分比自动调整列宽
// 编辑表格参数
editGrid: true, // 是否是编辑表格
editGridInitRowNum: 1, // 编辑表格的初始化新增行数
editGridInitAllRowEdit: false, // 是否初始化就编辑所有行(*** 重点 ***
editGridAddRowBtn: $('#testDataChildDataGridAddRowBtn'), // 子表增行按钮
editGridAddRowBtnToHeader: true, // 子表增行按钮是否显示到表头上 v4.1.7
editGridAddRowInitData: {id: '', status: Global.STATUS_NORMAL}, // 新增行的时候初始化的数据
// 编辑表格的提交数据参数
editGridInputFormListName: 'testDataChildList', // 提交的数据列表名
editGridInputFormListAttrs: 'status,id,testSort,testData.id,testInput,testTextarea,testSelect,testSelectMultiple,'
+'testRadio,testCheckbox,testDate,testDatetime,testUser.userCode,testUser.userName,testOffice.officeCode,'
+'testOffice.officeName,testAreaCode,testAreaName,testDataChild_file,testDataChild_file__del', // 提交数据列表的属性字段
// 加载成功后执行事件
ajaxSuccess: function(data){
// $('#jqgh_testDataChildDataGrid_rn').append('<a href="javascript:" onclick="'
// + '$(\'#testDataChildDataGridAddRowBtn\').click();">'
// + '<i class="fa fa-plus"></i></a>');
}
});
$('#testDataChildDataGrid').on('click', '.uploaderFile', function(){
var val = $(this).data('val'); layer.open({ title: '查看文件',
content: '文件列表:' + js.template('fileuploadTpl', {
id: 'fileupload_'+val, bizKey: val, bizType: 'testDataChild_file', cssClass: '', readonly: true
})
});
});
$("#inputForm").validate({
submitHandler: function(form){
js.ajaxSubmitForm($(form), function(data){
js.showMessage(data.message);
if(data.result == Global.TRUE){
js.closeCurrentTabPage(function(contentWindow){
contentWindow.page();
});
}
}, "json");
}
});
</script>

View File

@@ -123,7 +123,7 @@ $('#dataGrid').dataGrid({
searchForm: $("#searchForm"),
columnModel: [
{header:'${text("单行文本")}', name:'testInput', index:'a.test_input', width:250, align:"left", frozen:true, formatter: function(val, obj, row, act){
return '<a href="${ctx}/test/testData/form?id='+row.id+'" class="btnList" data-title="${text("编辑数据")}">'+(val||row.id)+'</a>';
return '<a href="${ctx}/test/testData/form?id='+row.id+'&flag=2" class="btnList" data-title="${text("编辑数据")}">'+(val||row.id)+'</a>';
}, searchoptions: { dataInit: function (element) {
$(element).attr('form', 'searchForm').attr('name', 'testInput2');
}}},

View File

@@ -64,7 +64,7 @@ $('#dataGrid').dataGrid({
{header:'${text("备注信息")}', name:'remarks', index:'a.remarks', width:150, align:"left"},
{header:'${text("操作")}', name:'actions', width:120, formatter: function(val, obj, row, act){
var actions = [];
<% if(hasPermi('test:testTree:edit')){ %>
//<% if(hasPermi('test:testTree:edit')){ %>
actions.push('<a href="${ctx}/test/testTree/form?treeCode='+row.treeCode+'" class="btnList" title="${text("编辑数据")}"><i class="fa fa-pencil"></i></a>&nbsp;');
if (row.status == Global.STATUS_NORMAL){
actions.push('<a href="${ctx}/test/testTree/disable?treeCode='+row.treeCode+'" class="btnList" title="${text("停用数据")}" data-confirm="${text("确认要停用该数据吗?")}"><i class="glyphicon glyphicon-ban-circle"></i></a>&nbsp;');
@@ -73,7 +73,7 @@ $('#dataGrid').dataGrid({
}
actions.push('<a href="${ctx}/test/testTree/delete?treeCode='+row.treeCode+'" class="btnList" title="${text("删除数据")}" data-confirm="${text("确认要删除该数据及所有子数据吗?")}" data-deltreenode="'+row.id+'"><i class="fa fa-trash-o"></i></a>&nbsp;');
actions.push('<a href="${ctx}/test/testTree/form?parentCode='+row.id+'" class="btnList" title="${text("新增下级数据")}"><i class="fa fa-plus-square"></i></a>&nbsp;');
<% } %>
//<% } %>
return actions.join('');
}}
],