Merge remote-tracking branch 'origin/feature/bug-1372' into prod/20260330
This commit is contained in:
commit
541735be36
|
|
@ -151,6 +151,7 @@ public class TicketController extends ControllerBase {
|
|||
|
||||
@Resource
|
||||
private DeepSeekTranslate deepSeekTranslate;
|
||||
|
||||
@Resource
|
||||
private ILanguageService languageService;
|
||||
|
||||
|
|
@ -161,9 +162,14 @@ public class TicketController extends ControllerBase {
|
|||
@GetMapping("getQuestions")
|
||||
@ApiMark(moduleName = "工单管理", apiName = "获取问题类型", isPublic = true)
|
||||
public ApiResult<List<String>> getQuestions() {
|
||||
return ApiResult.success(Arrays.asList("技术设计问题", "装配工艺问题", "焊接质量问题", "机组装配质量问题", "电控问题"
|
||||
, "工况方案问题", "客户操作不当", "原材料配件质量问题", "QC检验遗漏/误差", "部件/整机外观", "安装问题", "调试问题"
|
||||
, "外购件质量问题", "运输问题", "非故障问题/参数咨询"));
|
||||
// return ApiResult.success(Arrays.asList("技术设计问题", "装配工艺问题", "焊接质量问题", "机组装配质量问题", "电控问题"
|
||||
// , "工况方案问题", "客户操作不当", "原材料配件质量问题", "QC检验遗漏/误差", "部件/整机外观", "安装问题", "调试问题"
|
||||
// , "外购件质量问题", "运输问题", "非故障问题/参数咨询"));
|
||||
return ApiResult.success(dictionaryItemService.getListByDictionaryCodeAndType(Constant.DICTIONARY_TICKET_QUESTION,"移动破")
|
||||
.stream()
|
||||
.map(DictionaryItem::getName)
|
||||
.collect(Collectors.toList())
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -143,4 +143,6 @@ public class Constant {
|
|||
* 移动破产品线名称
|
||||
*/
|
||||
public static final String MOBILE_BROKEN = "移动破碎";
|
||||
|
||||
public static final String DICTIONARY_TICKET_QUESTION = "Question";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,6 +28,11 @@ public class SaveDictionaryItemRequest {
|
|||
@NotBlank(message = "属性值不能为空")
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* 类型(分组)
|
||||
*/
|
||||
private String type;
|
||||
|
||||
//多语言翻译
|
||||
private List<TranslateMap> languages;
|
||||
}
|
||||
|
|
@ -24,6 +24,11 @@ public class DictionaryItemVO {
|
|||
*/
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* 类型(分组)
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -154,9 +154,14 @@ public class TicketController extends ControllerBase {
|
|||
@GetMapping("getQuestions")
|
||||
@ApiMark(moduleName = "工单管理", apiName = "获取问题类型", isPublic = true)
|
||||
public ApiResult<List<String>> getQuestions() {
|
||||
return ApiResult.success(Arrays.asList("技术设计问题", "装配工艺问题", "焊接质量问题", "机组装配质量问题", "电控问题"
|
||||
, "工况方案问题", "客户操作不当", "原材料配件质量问题", "QC检验遗漏/误差", "部件/整机外观", "安装问题", "调试问题"
|
||||
, "外购件质量问题", "运输问题", "非故障问题/参数咨询"));
|
||||
// return ApiResult.success(Arrays.asList("技术设计问题", "装配工艺问题", "焊接质量问题", "机组装配质量问题", "电控问题"
|
||||
// , "工况方案问题", "客户操作不当", "原材料配件质量问题", "QC检验遗漏/误差", "部件/整机外观", "安装问题", "调试问题"
|
||||
// , "外购件质量问题", "运输问题", "非故障问题/参数咨询"));
|
||||
return ApiResult.success(dictionaryItemService.getListByDictionaryCodeAndType(Constant.DICTIONARY_TICKET_QUESTION,"工服")
|
||||
.stream()
|
||||
.map(DictionaryItem::getName)
|
||||
.collect(Collectors.toList())
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -48,6 +48,11 @@ public class DictionaryItem implements Serializable {
|
|||
*/
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* 类型(分组)
|
||||
*/
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -25,4 +25,6 @@ public interface DictionaryItemMapper extends BaseMapper<DictionaryItem> {
|
|||
List<DictionaryItem> getListByDictionaryCode(String code,String language);
|
||||
|
||||
DictionaryItem getByCode(String dictionaryCode, String dictionaryItemCode);
|
||||
|
||||
List<DictionaryItem> getListByDictionaryCodeAndType(String dictionaryCode, String type);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,4 +29,6 @@ public interface IDictionaryItemService extends IService<DictionaryItem> {
|
|||
List<DictionaryItem> getListByDictionaryCode(String code,String language);
|
||||
|
||||
DictionaryItem getByCode(String dictionaryCode, String DictionaryItemCode);
|
||||
|
||||
List<DictionaryItem> getListByDictionaryCodeAndType(String dictionaryCode,String type);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -86,6 +86,7 @@ public class DictionaryItemServiceImpl extends ServiceImpl<DictionaryItemMapper,
|
|||
.setName(request.getName())
|
||||
.setCode(request.getCode())
|
||||
.setValue(request.getValue())
|
||||
.setType(request.getType())
|
||||
.setCreateBy(AdminUserUtil.getUserName())
|
||||
.setCreateTime(LocalDateTime.now());
|
||||
save(dictionaryItem);
|
||||
|
|
@ -96,6 +97,7 @@ public class DictionaryItemServiceImpl extends ServiceImpl<DictionaryItemMapper,
|
|||
.setName(request.getName())
|
||||
.setCode(request.getCode())
|
||||
.setValue(request.getValue())
|
||||
.setType(request.getType())
|
||||
.setUpdateBy(AdminUserUtil.getUserName())
|
||||
.setUpdateTime(LocalDateTime.now());
|
||||
updateById(dictionaryItem);
|
||||
|
|
@ -146,4 +148,9 @@ public class DictionaryItemServiceImpl extends ServiceImpl<DictionaryItemMapper,
|
|||
public DictionaryItem getByCode(String dictionaryCode, String DictionaryItemCode) {
|
||||
return baseMapper.getByCode(dictionaryCode, DictionaryItemCode);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DictionaryItem> getListByDictionaryCodeAndType(String dictionaryCode, String type) {
|
||||
return baseMapper.getListByDictionaryCodeAndType(dictionaryCode, type);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,4 +24,10 @@
|
|||
INNER JOIN dictionary_item di ON d.id=di.dictionary_id
|
||||
WHERE d.`code`= #{dictionaryCode} AND di.`code`= #{dictionaryItemCode}
|
||||
</select>
|
||||
<select id="getListByDictionaryCodeAndType" resultType="com.nflg.mobilebroken.repository.entity.DictionaryItem">
|
||||
SELECT di.*
|
||||
FROM dictionary d
|
||||
INNER JOIN dictionary_item di ON d.id=di.dictionary_id
|
||||
WHERE d.`code`= #{dictionaryCode} AND di.`type`= #{type}
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
Loading…
Reference in New Issue