正在显示
5 个修改的文件
包含
24 行增加
和
15 行删除
| @@ -798,14 +798,23 @@ public class Convert | @@ -798,14 +798,23 @@ public class Convert | ||
| 798 | { | 798 | { |
| 799 | return (String) obj; | 799 | return (String) obj; |
| 800 | } | 800 | } |
| 801 | - else if (obj instanceof byte[]) | 801 | + else if (obj instanceof byte[] || obj instanceof Byte[]) |
| 802 | { | 802 | { |
| 803 | - return str((byte[]) obj, charset); | ||
| 804 | - } | ||
| 805 | - else if (obj instanceof Byte[]) | ||
| 806 | - { | ||
| 807 | - byte[] bytes = ArrayUtils.toPrimitive((Byte[]) obj); | ||
| 808 | - return str(bytes, charset); | 803 | + if (obj instanceof byte[]) |
| 804 | + { | ||
| 805 | + return str((byte[]) obj, charset); | ||
| 806 | + } | ||
| 807 | + else | ||
| 808 | + { | ||
| 809 | + Byte[] bytes = (Byte[]) obj; | ||
| 810 | + int length = bytes.length; | ||
| 811 | + byte[] dest = new byte[length]; | ||
| 812 | + for (int i = 0; i < length; i++) | ||
| 813 | + { | ||
| 814 | + dest[i] = bytes[i]; | ||
| 815 | + } | ||
| 816 | + return str(dest, charset); | ||
| 817 | + } | ||
| 809 | } | 818 | } |
| 810 | else if (obj instanceof ByteBuffer) | 819 | else if (obj instanceof ByteBuffer) |
| 811 | { | 820 | { |
| @@ -961,9 +970,7 @@ public class Convert | @@ -961,9 +970,7 @@ public class Convert | ||
| 961 | c[i] = (char) (c[i] - 65248); | 970 | c[i] = (char) (c[i] - 65248); |
| 962 | } | 971 | } |
| 963 | } | 972 | } |
| 964 | - String returnString = new String(c); | ||
| 965 | - | ||
| 966 | - return returnString; | 973 | + return new String(c); |
| 967 | } | 974 | } |
| 968 | 975 | ||
| 969 | /** | 976 | /** |
| @@ -64,7 +64,7 @@ public class GenController extends BaseController | @@ -64,7 +64,7 @@ public class GenController extends BaseController | ||
| 64 | } | 64 | } |
| 65 | 65 | ||
| 66 | /** | 66 | /** |
| 67 | - * 修改代码生成业务 | 67 | + * 获取代码生成信息 |
| 68 | */ | 68 | */ |
| 69 | @PreAuthorize("@ss.hasPermi('tool:gen:query')") | 69 | @PreAuthorize("@ss.hasPermi('tool:gen:query')") |
| 70 | @GetMapping(value = "/{tableId}") | 70 | @GetMapping(value = "/{tableId}") |
| @@ -177,7 +177,7 @@ public class SysJobController extends BaseController | @@ -177,7 +177,7 @@ public class SysJobController extends BaseController | ||
| 177 | @PreAuthorize("@ss.hasPermi('monitor:job:remove')") | 177 | @PreAuthorize("@ss.hasPermi('monitor:job:remove')") |
| 178 | @Log(title = "定时任务", businessType = BusinessType.DELETE) | 178 | @Log(title = "定时任务", businessType = BusinessType.DELETE) |
| 179 | @DeleteMapping("/{jobIds}") | 179 | @DeleteMapping("/{jobIds}") |
| 180 | - public AjaxResult remove(@PathVariable Long[] jobIds) throws SchedulerException, TaskException | 180 | + public AjaxResult remove(@PathVariable Long[] jobIds) throws SchedulerException |
| 181 | { | 181 | { |
| 182 | jobService.deleteJobByIds(jobIds); | 182 | jobService.deleteJobByIds(jobIds); |
| 183 | return success(); | 183 | return success(); |
| @@ -3,7 +3,6 @@ package com.ruoyi.quartz.util; | @@ -3,7 +3,6 @@ package com.ruoyi.quartz.util; | ||
| 3 | import java.util.Date; | 3 | import java.util.Date; |
| 4 | import org.quartz.Job; | 4 | import org.quartz.Job; |
| 5 | import org.quartz.JobExecutionContext; | 5 | import org.quartz.JobExecutionContext; |
| 6 | -import org.quartz.JobExecutionException; | ||
| 7 | import org.slf4j.Logger; | 6 | import org.slf4j.Logger; |
| 8 | import org.slf4j.LoggerFactory; | 7 | import org.slf4j.LoggerFactory; |
| 9 | import com.ruoyi.common.constant.Constants; | 8 | import com.ruoyi.common.constant.Constants; |
| @@ -31,7 +30,7 @@ public abstract class AbstractQuartzJob implements Job | @@ -31,7 +30,7 @@ public abstract class AbstractQuartzJob implements Job | ||
| 31 | private static ThreadLocal<Date> threadLocal = new ThreadLocal<>(); | 30 | private static ThreadLocal<Date> threadLocal = new ThreadLocal<>(); |
| 32 | 31 | ||
| 33 | @Override | 32 | @Override |
| 34 | - public void execute(JobExecutionContext context) throws JobExecutionException | 33 | + public void execute(JobExecutionContext context) |
| 35 | { | 34 | { |
| 36 | SysJob sysJob = new SysJob(); | 35 | SysJob sysJob = new SysJob(); |
| 37 | BeanUtils.copyBeanProp(sysJob, context.getMergedJobDataMap().get(ScheduleConstants.TASK_PROPERTIES)); | 36 | BeanUtils.copyBeanProp(sysJob, context.getMergedJobDataMap().get(ScheduleConstants.TASK_PROPERTIES)); |
| @@ -167,6 +167,9 @@ export function handleTree(data, id, parentId, children) { | @@ -167,6 +167,9 @@ export function handleTree(data, id, parentId, children) { | ||
| 167 | for (let d of data) { | 167 | for (let d of data) { |
| 168 | let id = d[config.id]; | 168 | let id = d[config.id]; |
| 169 | childrenListMap[id] = d; | 169 | childrenListMap[id] = d; |
| 170 | + if (!d[config.childrenList]) { | ||
| 171 | + d[config.childrenList] = []; | ||
| 172 | + } | ||
| 170 | } | 173 | } |
| 171 | 174 | ||
| 172 | for (let d of data) { | 175 | for (let d of data) { |
| @@ -216,7 +219,7 @@ export function getNormalPath(p) { | @@ -216,7 +219,7 @@ export function getNormalPath(p) { | ||
| 216 | if (res[res.length - 1] === '/') { | 219 | if (res[res.length - 1] === '/') { |
| 217 | return res.slice(0, res.length - 1) | 220 | return res.slice(0, res.length - 1) |
| 218 | } | 221 | } |
| 219 | - return res; | 222 | + return res |
| 220 | } | 223 | } |
| 221 | 224 | ||
| 222 | // 验证是否为blob格式 | 225 | // 验证是否为blob格式 |
-
请 注册 或 登录 后发表评论