@@ -174,12 +174,13 @@ public class DictBizController extends BladeController {
/**
* 获取字典
+ * @param type 系统类型 2-投资效益系统
*/
@GetMapping("/dictionary")
@ApiOperationSupport(order = 8)
@Operation(summary = "获取字典", description = "获取字典")
- public R<List<DictBiz>> dictionary(String code) {
- List<DictBiz> tree = dictService.getList(code);
+ public R<List<DictBiz>> dictionary(String code,Integer type) {
+ List<DictBiz> tree = dictService.getList(code,type);
return R.data(tree);
}
@@ -26,6 +26,7 @@
package org.springblade.modules.system.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
import org.springblade.modules.system.pojo.entity.DictBiz;
import org.springblade.modules.system.pojo.vo.DictBizVO;
@@ -53,7 +54,7 @@ public interface DictBizMapper extends BaseMapper<DictBiz> {
* @param code 字典编号
* @return
- List<DictBiz> getList(String code);
+ List<DictBiz> getList(String code,@Param("type") Integer type);
* 获取树形节点
@@ -37,7 +37,16 @@
</select>-->
<select id="getList" resultMap="dictResultMap">
- select id, tenant_id, parent_id, code, dict_key, dict_value, sort, remark from blade_dict_biz where code = #{param1} and parent_id > 0 and is_sealed = 0 and is_deleted = 0
+ select id, tenant_id, parent_id, code, dict_key, dict_value, sort, remark
+ from blade_dict_biz
+ where
+ code = #{param1}
+ and parent_id > 0
+ and is_sealed = 0
+ and is_deleted = 0
+ <if test="param2 != null">
+ and type = #{type}
+ </if>
</select>
<select id="tree" resultMap="treeNodeResultMap">
@@ -114,5 +114,12 @@ public class DictBiz implements Serializable {
@Schema(description = "是否已删除")
private Integer isDeleted;
+ /**
+ * 系统类型:2-投资效益系统
+ */
+ @TableLogic
+ @Schema(description = "系统类型:2-投资效益系统")
+ private Integer systemType;
+
@@ -80,7 +80,12 @@ public class DictBizServiceImpl extends ServiceImpl<DictBizMapper, DictBiz> impl
@Override
public List<DictBiz> getList(String code) {
- return baseMapper.getList(code);
+ return baseMapper.getList(code,null);
+ }
+ @Override
+ public List<DictBiz> getList(String code, Integer type) {
+ return baseMapper.getList(code,type);