1.模型运行其校验pyfile参数必填
2.mpk.list()方法添加参数过滤
3.methodSetting表的value字段长度增加为1000
| | |
| | | `method_id` varchar(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NOT NULL COMMENT '方法id', |
| | | `setting_key` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT 'key', |
| | | `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '参数名称', |
| | | `value` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '参数默认值', |
| | | `value` varchar(1000) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '参数默认值', |
| | | `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '输入类型', |
| | | `value_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '参数类型', |
| | | `max` int NULL DEFAULT NULL COMMENT '最大值', |
| | |
| | | } |
| | | |
| | | try { |
| | | if (dto.getModelSettings().stream().noneMatch(e -> e.getSettingKey().equals(MdkConstant.PY_FILE_KEY))) { |
| | | return error(GlobalErrorCodeConstants.BAD_REQUEST.getCode(),"模型设置参数缺少必要信息【" + MdkConstant.PY_FILE_KEY + "】,请重新上传模型!"); |
| | | } |
| | | |
| | | if (dto.getHasModel()) { |
| | | paramsValueArray[uuids.size()] = dto.getModel(); |
| | | paramsValueArray[uuids.size() + 1] = handleModelSettings(dto.getModelSettings()); |
| | |
| | | |
| | | @PreAuthorize("@ss.hasPermission('mpk:file:query')") |
| | | @GetMapping("list") |
| | | public CommonResult<List<MpkFileDTO>> list() { |
| | | List<MpkFileDTO> list = mpkFileService.list(new HashMap<>()); |
| | | public CommonResult<List<MpkFileDTO>> list(@RequestParam Map<String, Object> params) { |
| | | List<MpkFileDTO> list = mpkFileService.list(params); |
| | | |
| | | return success(list); |
| | | } |
| | |
| | | int getProjectModelCount(String projectId); |
| | | |
| | | List<MpkFileDTO> getProjectModel(@Param("params") Map<String, Object> params); |
| | | |
| | | List<MpkFileDTO> list(@Param("params") Map<String, Object> params); |
| | | } |
| | |
| | | |
| | | @Override |
| | | public List<MpkFileDTO> list(Map<String, Object> params) { |
| | | List<MpkFileEntity> entityList = baseDao.selectList(getWrapper(params).orderByDesc("create_date")); |
| | | // List<MpkFileEntity> entityList = baseDao.selectList(getWrapper(params).orderByDesc("create_date")); |
| | | List<MpkFileDTO> list = baseDao.list(params); |
| | | |
| | | return ConvertUtils.sourceToTarget(entityList, MpkFileDTO.class); |
| | | return list; |
| | | } |
| | | |
| | | private QueryWrapper<MpkFileEntity> getWrapper(Map<String, Object> params) { |
| | |
| | | </foreach> |
| | | ORDER BY b.sort,c.sort,d.sort,e.sort,f.sort,a.create_date |
| | | </select> |
| | | <select id="list" resultMap="mpkFile" parameterType="java.util.Map"> |
| | | SELECT |
| | | a.*, |
| | | b.id method_id, |
| | | b.method_name, |
| | | b.data_length, |
| | | b.model, |
| | | b.result_key, |
| | | c.id setting_id, |
| | | c.setting_key, |
| | | c.name setting_name, |
| | | c.value, |
| | | c.type, |
| | | c.value_type, |
| | | c.max, |
| | | c.min, |
| | | d.id select_id, |
| | | d.select_key, |
| | | d.name select_name |
| | | FROM |
| | | t_mpk_file a |
| | | LEFT JOIN t_mpk_model_method b ON a.id = b.mpk_file_id |
| | | LEFT JOIN t_mpk_method_setting c ON b.id = c.method_id |
| | | LEFT JOIN t_mpk_setting_select d ON c.id = d.setting_id |
| | | LEFT JOIN t_mpk_file_menu e ON e.name = a.menu_name |
| | | LEFT JOIN t_mpk_file_group f ON f.menu_id = e.id and f.name = a.group_name |
| | | <where> |
| | | <if test="params.pyType != null and params.pyType != ''"> |
| | | AND a.py_type = #{params.pyType} |
| | | </if> |
| | | </where> |
| | | ORDER BY b.sort,c.sort,d.sort,e.sort,f.sort,a.create_date |
| | | </select> |
| | | <select id="getProjectModelCount" resultType="java.lang.Integer" parameterType="java.lang.String"> |
| | | SELECT |
| | | count(*) |