任务管理后端 解救文件无法上传

dev
shiji 1 year ago
parent c492700f6b
commit 6b0f78f0a0
  1. 2
      ant-design-vue-jeecg/public/index.html
  2. 20
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/task/controller/TaskController.java
  3. 20
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/task/entity/Task.java

@ -268,7 +268,7 @@
<!-- 全局配置 -->
<script>
window._CONFIG = {};
window._CONFIG['domianURL'] = 'http://localhost:8081/jeecg-boot';
window._CONFIG['domianURL'] = 'http://localhost:18081/jeecg-boot';
window._CONFIG['casPrefixUrl'] = 'http://cas.example.org:8443/cas';
window._CONFIG['imgDomainURL'] = window._CONFIG['domianURL'] + '/sys/common/view';
window._CONFIG['downloadUrl'] = window._CONFIG['domianURL'] + '/sys/common/download';

@ -26,6 +26,8 @@ import org.jeecg.modules.modulex.entity.Modulex;
import org.jeecg.modules.modulex.service.IModulexService;
import org.jeecg.modules.projectx.entity.Projectx;
import org.jeecg.modules.projectx.service.IProjectxService;
import org.jeecg.modules.system.entity.SysUser;
import org.jeecg.modules.system.service.ISysUserService;
import org.jeecg.modules.task.entity.Task;
import org.jeecg.modules.task.service.ITaskService;
import org.jeecg.modules.taskType.entity.TaskType;
@ -40,6 +42,7 @@ import javax.servlet.http.HttpServletResponse;
import java.text.SimpleDateFormat;
import java.util.Arrays;
import java.util.Date;
import java.util.List;
import java.util.Optional;
/**
@ -70,7 +73,8 @@ public class TaskController extends JeecgController<Task, ITaskService> {
@Resource
private IModulexService iModulexService;
@Resource
private ISysUserService iSysUserService;
@Resource
private IRulexService iRulexService;
@ -124,6 +128,20 @@ public class TaskController extends JeecgController<Task, ITaskService> {
e.setUpperTaskName(taskUpper.getTaskName());
}
}
if (e.getTaskFile()!=null&& !e.getTaskFile().equals("")){
e.setContentType("file");
}else if(e.getTaskPic()!=null&& !e.getTaskPic().equals("")){
e.setContentType("image");
}else{
e.setContentType("text");
}
String managerUsers = e.getManagerUsers();
if (managerUsers!=null&&!managerUsers.equals("")) {
SysUser byId = iSysUserService.getById(managerUsers);
if (byId!=null)
e.setHeadpic(byId.getAvatar());
}
});
return Result.OK(pageList);
}

@ -60,12 +60,15 @@ public class Task implements Serializable {
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新日期")
private java.util.Date updateTime;
/**
* 上级任务id
*/
@Excel(name = "上级任务id", width = 15)
/**上级任务id*/
@Excel(name = "上级任务id", width = 15, dictTable = "task", dicText = "task_name", dicCode = "id")
@Dict(dictTable = "task", dicText = "task_name", dicCode = "id")
@ApiModelProperty(value = "上级任务id")
private java.lang.String upperId;
// /**上级任务*/
// @Excel(name = "上级任务", width = 15)
// @ApiModelProperty(value = "上级任务")
// private java.lang.String upperName;
/**
* 中文名称
*/
@ -195,4 +198,13 @@ public class Task implements Serializable {
@Excel(name = "项目图片", width = 15)
@ApiModelProperty(value = "项目图片")
private java.lang.String taskPic;
@Excel(name = "项目文件", width = 15)
@ApiModelProperty(value = "项目文件")
private java.lang.String taskFile;
@ApiModelProperty(value = "返回类型")
@TableField(exist = false)
private java.lang.String contentType;
@ApiModelProperty(value = "负责人头像")
@TableField(exist = false)
private java.lang.String headpic;
}

Loading…
Cancel
Save