客户健康页面优化
This commit is contained in:
		| @@ -78,6 +78,26 @@ public class CommonController { | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     /** | ||||
|      * 通用上传请求(无需登录认证) | ||||
|      */ | ||||
|     @PostMapping("/common/customerUploadFile") | ||||
|     public AjaxResult customerUploadFile(MultipartFile file) throws Exception { | ||||
|         try { | ||||
|             // 上传文件路径 | ||||
|             String filePath = RuoYiConfig.getUploadPath(); | ||||
|             // 上传并返回新文件名称 | ||||
|             String fileName = FileUploadUtils.upload(filePath, file); | ||||
|             String url = serverConfig.getUrl() + fileName; | ||||
|             AjaxResult ajax = AjaxResult.success(); | ||||
|             ajax.put("fileName", fileName); | ||||
|             ajax.put("url", url); | ||||
|             return ajax; | ||||
|         } catch (Exception e) { | ||||
|             return AjaxResult.error(e.getMessage()); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     /** | ||||
|      * 本地资源通用下载 | ||||
|      */ | ||||
|   | ||||
| @@ -4,18 +4,21 @@ import com.stdiet.common.core.controller.BaseController; | ||||
| import com.stdiet.common.core.domain.AjaxResult; | ||||
| import com.stdiet.common.core.page.TableDataInfo; | ||||
| import com.stdiet.custom.domain.SysCustomer; | ||||
| import com.stdiet.custom.domain.SysCustomerHealthy; | ||||
| import com.stdiet.custom.domain.SysPhysicalSigns; | ||||
| import com.stdiet.custom.dto.request.CustomerInvestigateRequest; | ||||
| import com.stdiet.custom.service.ISysCustomerHealthyService; | ||||
| import com.stdiet.custom.service.ISysCustomerService; | ||||
| import com.stdiet.custom.service.ISysPhysicalSignsService; | ||||
| import com.stdiet.system.service.ISysDictTypeService; | ||||
| import org.springframework.beans.factory.annotation.Autowired; | ||||
| import org.springframework.web.bind.annotation.*; | ||||
| import org.springframework.web.multipart.MultipartFile; | ||||
|  | ||||
| import java.util.List; | ||||
|  | ||||
| /** | ||||
|  * 客户信息调查Controller | ||||
|  * 客户相关信息调查Controller | ||||
|  * | ||||
|  * @author xzj | ||||
|  * @date 2020-12-31 | ||||
| @@ -33,6 +36,9 @@ public class InvestigateController extends BaseController { | ||||
|     @Autowired | ||||
|     private ISysDictTypeService dictTypeService; | ||||
|  | ||||
|     @Autowired | ||||
|     private ISysCustomerHealthyService sysCustomerHealthyService; | ||||
|  | ||||
|     /** | ||||
|      * 建立客户信息档案 | ||||
|      */ | ||||
| @@ -68,6 +74,14 @@ public class InvestigateController extends BaseController { | ||||
|         return AjaxResult.success(dictTypeService.selectDictDataByType(dictType)); | ||||
|     } | ||||
|  | ||||
|  | ||||
|     /** | ||||
|      * 新增客户健康 | ||||
|      */ | ||||
|     @PostMapping("/addCustomerHealthy") | ||||
|     public AjaxResult addCustomerHealthy(@RequestBody SysCustomerHealthy sysCustomerHealthy) | ||||
|     { | ||||
|         System.out.println(sysCustomerHealthy.getSex()); | ||||
|         return toAjax(1); | ||||
|     } | ||||
|  | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user