添加申请退货
This commit is contained in:
@@ -22,6 +22,9 @@ public interface DataDictMapper {
|
||||
@Param("values") Collection<String> values
|
||||
);
|
||||
|
||||
List<DataDictDO> selectByEnumValue(
|
||||
@Param("enumValue") String enumValue
|
||||
);
|
||||
|
||||
List<DataDictDO> selectList();
|
||||
|
||||
|
||||
@@ -97,6 +97,13 @@ public class DataDictServiceImpl implements DataDictService {
|
||||
return CommonResult.success(dataDictBO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CommonResult<List<DataDictBO>> getDataDict(String dictKey) {
|
||||
List<DataDictDO> dataDictDOList = dataDictMapper.selectByEnumValue(dictKey);
|
||||
List<DataDictBO> dataDictBOList = DataDictConvert.INSTANCE.convert(dataDictDOList);
|
||||
return CommonResult.success(dataDictBOList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CommonResult<List<DataDictBO>> getDataDictList(String dictKey, Collection<?> dictValueList) {
|
||||
Set<String> convertDictValueList = dictValueList.stream().map(o -> String.valueOf(o)).collect(Collectors.toSet());
|
||||
|
||||
@@ -44,6 +44,13 @@
|
||||
FROM data_dict
|
||||
WHERE deleted = 0
|
||||
</select>
|
||||
<select id="selectByEnumValue" resultType="cn.iocoder.mall.admin.dataobject.DataDictDO">
|
||||
SELECT
|
||||
<include refid="FIELDS"/>
|
||||
FROM data_dict
|
||||
WHERE deleted = 0
|
||||
AND enum_value = #{enumValue}
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="DataDictDO" useGeneratedKeys="true" keyColumn="id" keyProperty="id">
|
||||
INSERT INTO data_dict (
|
||||
|
||||
Reference in New Issue
Block a user