定时任务屏蔽违规的字符
parent
14db619b20
commit
d0a19e5b6f
|
@ -127,5 +127,5 @@ public class Constants
|
||||||
* 定时任务违规的字符
|
* 定时任务违规的字符
|
||||||
*/
|
*/
|
||||||
public static final String[] JOB_ERROR_STR = { "java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml",
|
public static final String[] JOB_ERROR_STR = { "java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml",
|
||||||
"org.springframework", "org.apache" };
|
"org.springframework", "org.apache", "com.ruoyi.common.core.utils.file" };
|
||||||
}
|
}
|
||||||
|
|
|
@ -302,12 +302,15 @@ public class GenTableServiceImpl implements IGenTableService
|
||||||
{
|
{
|
||||||
GenTableColumn prevColumn = tableColumnMap.get(column.getColumnName());
|
GenTableColumn prevColumn = tableColumnMap.get(column.getColumnName());
|
||||||
column.setColumnId(prevColumn.getColumnId());
|
column.setColumnId(prevColumn.getColumnId());
|
||||||
if (column.isList()) {
|
if (column.isList())
|
||||||
|
{
|
||||||
// 如果是列表,继续保留字典类型
|
// 如果是列表,继续保留字典类型
|
||||||
column.setDictType(prevColumn.getDictType());
|
column.setDictType(prevColumn.getDictType());
|
||||||
}
|
}
|
||||||
genTableColumnMapper.updateGenTableColumn(column);
|
genTableColumnMapper.updateGenTableColumn(column);
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
genTableColumnMapper.insertGenTableColumn(column);
|
genTableColumnMapper.insertGenTableColumn(column);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -451,6 +454,7 @@ public class GenTableServiceImpl implements IGenTableService
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 设置主子表信息
|
* 设置主子表信息
|
||||||
*
|
*
|
||||||
|
|
|
@ -93,7 +93,7 @@ public class SysJobController extends BaseController
|
||||||
}
|
}
|
||||||
else if (StringUtils.containsAnyIgnoreCase(job.getInvokeTarget(), new String[] { Constants.LOOKUP_LDAP, Constants.LOOKUP_LDAPS }))
|
else if (StringUtils.containsAnyIgnoreCase(job.getInvokeTarget(), new String[] { Constants.LOOKUP_LDAP, Constants.LOOKUP_LDAPS }))
|
||||||
{
|
{
|
||||||
return error("新增任务'" + job.getJobName() + "'失败,目标字符串不允许'ldap'调用");
|
return error("新增任务'" + job.getJobName() + "'失败,目标字符串不允许'ldap(s)'调用");
|
||||||
}
|
}
|
||||||
else if (StringUtils.containsAnyIgnoreCase(job.getInvokeTarget(), new String[] { Constants.HTTP, Constants.HTTPS }))
|
else if (StringUtils.containsAnyIgnoreCase(job.getInvokeTarget(), new String[] { Constants.HTTP, Constants.HTTPS }))
|
||||||
{
|
{
|
||||||
|
|
|
@ -141,7 +141,8 @@ public class SysDictTypeServiceImpl implements ISysDictTypeService
|
||||||
SysDictData dictData = new SysDictData();
|
SysDictData dictData = new SysDictData();
|
||||||
dictData.setStatus("0");
|
dictData.setStatus("0");
|
||||||
Map<String, List<SysDictData>> dictDataMap = dictDataMapper.selectDictDataList(dictData).stream().collect(Collectors.groupingBy(SysDictData::getDictType));
|
Map<String, List<SysDictData>> dictDataMap = dictDataMapper.selectDictDataList(dictData).stream().collect(Collectors.groupingBy(SysDictData::getDictType));
|
||||||
for (Map.Entry<String, List<SysDictData>> entry: dictDataMap.entrySet()) {
|
for (Map.Entry<String, List<SysDictData>> entry : dictDataMap.entrySet())
|
||||||
|
{
|
||||||
DictUtils.setDictCache(entry.getKey(), entry.getValue().stream().sorted(Comparator.comparing(SysDictData::getDictSort)).collect(Collectors.toList()));
|
DictUtils.setDictCache(entry.getKey(), entry.getValue().stream().sorted(Comparator.comparing(SysDictData::getDictSort)).collect(Collectors.toList()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue