Commit 68ac92bc authored by 刘林's avatar 刘林

fix(tcm):添加字典查核准证号接口

parent 3c5a993a
......@@ -115,6 +115,19 @@ public class DataDictionaryController extends BaseController {
}
/**
* 根据extend集合和Type查询
*
* @param extendList
* @return
*/
@TycloudOperation(needAuth = true, ApiLevel = UserType.AGENCY)
@RequestMapping(value = "/getDictByExtendsAndType", method = RequestMethod.GET)
@ApiOperation(httpMethod = "GET", value = "根据extend集合和Type查询", notes = "根据extend集合和Type查询")
public List<DataDictionary> getDictByExtendsAndType(@RequestParam("extendList") List<String> extendList, @RequestParam("type") String type) {
return iDataDictionaryService.getDictByExtendsAndType(extendList, type);
}
/**
* 列表分页查询
*
* @return
......
......@@ -36,4 +36,5 @@ public interface DataDictionaryMapper extends BaseMapper<DataDictionary> {
public List<DataDictionary> getFirefightersJobTitle(String type);
List<DataDictionary> getDictByExtendsAndType(List<String> extendList, String type);
}
......@@ -31,4 +31,6 @@ public interface IDataDictionaryService {
List<DataDictionary> getByTypeAndDesc(String type, String group);
DataDictionary getByExtend(String groupId, String type);
List<DataDictionary> getDictByExtendsAndType(List<String> extendList, String type);
}
......@@ -196,4 +196,9 @@ public class DataDictionaryServiceImpl extends BaseService<DataDictionaryDto, Da
DataDictionary dataDictionary = dataDictionaryMapper.selectOne(wrapper);
return ObjectUtils.isEmpty(dataDictionary) ? new DataDictionary() : dataDictionary;
}
@Override
public List<DataDictionary> getDictByExtendsAndType(List<String> extendList, String type) {
return dataDictionaryMapper.getDictByExtendsAndType(extendList,type);
}
}
......@@ -112,6 +112,18 @@ WHERE
cdd.type = 'XFSYLX'
</select>
<select id="getDictByExtendsAndType" resultType="com.yeejoin.amos.boot.biz.common.entity.DataDictionary">
SELECT cbb.*
FROM cb_data_dictionary cbb
WHERE cbb.is_delete = 0
AND cbb.type = #{type}
AND (
<foreach collection="extendList" item="item" separator=" OR ">
FIND_IN_SET(#{item}, cbb.extend)
</foreach>
)
ORDER BY cbb.sort_num
</select>
</mapper>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment