|
|
@@ -146,4 +146,20 @@ public class SysQuotationController extends BaseController {
|
|
|
return HttpResult.ok("配置成功");
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ @ApiOperation(value = "获取用户对应报价单")
|
|
|
+ @GetMapping(value = "/getThemeByUserId")
|
|
|
+ public HttpResult<SysOrganizationQuotation> getThemeByUserId() {
|
|
|
+ SysUser user = getUser();
|
|
|
+ LambdaQueryWrapper<SysOrganizationQuotation> oQueryWrapper = new LambdaQueryWrapper<>();
|
|
|
+ oQueryWrapper.eq(SysOrganizationQuotation::getAuthorizationId, user.getId());
|
|
|
+ SysOrganizationQuotation quotationServiceOne = sysOrganizationQuotationService.getOne(oQueryWrapper);
|
|
|
+ if (quotationServiceOne == null) {
|
|
|
+ quotationServiceOne = new SysOrganizationQuotation();
|
|
|
+ quotationServiceOne.setThemeCode("QD");
|
|
|
+ }
|
|
|
+ return HttpResult.ok(quotationServiceOne);
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
}
|