|
@@ -3,9 +3,14 @@ package com.caimei365.user.controller;
|
|
|
import com.caimei365.user.model.ResponseJson;
|
|
|
import com.caimei365.user.model.dto.ShopUpdateDto;
|
|
|
import com.caimei365.user.service.ShopService;
|
|
|
-import io.swagger.annotations.*;
|
|
|
+import io.swagger.annotations.Api;
|
|
|
+import io.swagger.annotations.ApiImplicitParam;
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
-import org.springframework.web.bind.annotation.*;
|
|
|
+import org.springframework.web.bind.annotation.GetMapping;
|
|
|
+import org.springframework.web.bind.annotation.PostMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
import java.util.Map;
|
|
|
|
|
@@ -15,7 +20,7 @@ import java.util.Map;
|
|
|
* @author : Charles
|
|
|
* @date : 2021/3/9
|
|
|
*/
|
|
|
-@Api(tags="供应商用户API")
|
|
|
+@Api(tags = "供应商用户API")
|
|
|
@RestController
|
|
|
@RequiredArgsConstructor
|
|
|
@RequestMapping("/user/shop")
|
|
@@ -25,12 +30,11 @@ public class ShopApi {
|
|
|
|
|
|
/**
|
|
|
* 根据用户Id查询供应商资料
|
|
|
- *
|
|
|
+ * <p>
|
|
|
* spi旧接口:/supplier/shopInfo
|
|
|
*
|
|
|
* @param userId 用户Id
|
|
|
- *
|
|
|
- * @return Map(userPo,clubPo)
|
|
|
+ * @return Map(userPo, clubPo)
|
|
|
*/
|
|
|
@ApiOperation("查询供应商资料")
|
|
|
@ApiImplicitParam(required = true, name = "userId", value = "用户Id")
|
|
@@ -41,52 +45,52 @@ public class ShopApi {
|
|
|
|
|
|
/**
|
|
|
* 修改供应商资料
|
|
|
- *
|
|
|
+ * <p>
|
|
|
* spi旧接口:/supplier/modifiedData
|
|
|
*
|
|
|
* @param shopUpdateDto ShopUpdateDto{
|
|
|
- * shopId 供应商Id
|
|
|
- * userId 用户Id
|
|
|
- * name 组织名称
|
|
|
- * shortName 供应商公司简称(shortName)
|
|
|
- * email 邮箱
|
|
|
- * contractPhone 固定电话
|
|
|
- * linkMan 联系人
|
|
|
- * provinceId 省(provinceID)
|
|
|
- * cityId 市(cityID)
|
|
|
- * townId 所在县区Id(townID)
|
|
|
- * address 地址
|
|
|
- * socialCreditCode 统一社会信用代码(营业执照编号)
|
|
|
- * businessLicense 营业执照(businessLicenseImage)
|
|
|
- * firstShopType 医疗=1和非医疗=2
|
|
|
- * secondShopType 医疗的二级分类 一类器械=1、二类器械 =2、三类器械=3、其他=4 /// 1和非医疗没有二级分类
|
|
|
- * mainProduct 主打项目(mainpro)
|
|
|
- * mainProductDesc 主打商品说明(productDesc)
|
|
|
- * legalPerson 法人代表
|
|
|
- * registeredCapital 注册资本
|
|
|
- * faxNumber 传真号(fax)
|
|
|
- * companyNature 传真号(nature)
|
|
|
- * turnover 年营业额
|
|
|
- * medicalPracticeLicense 医疗执业许可证(medicalPracticeLicenseImg1)
|
|
|
- * shopDesc 公司介绍(info)
|
|
|
- * businessScope 经营范围
|
|
|
- * logo 公司LOGO
|
|
|
- * operationLicence 生产经营证书(productionLicence)
|
|
|
- * hygienicLicense 卫生许可证
|
|
|
- * taxLicense 税务登记证
|
|
|
- * honorCertification 荣誉证书(certificateHonor)
|
|
|
- * productCertification 产品证书
|
|
|
- * }
|
|
|
+ * shopId 供应商Id
|
|
|
+ * userId 用户Id
|
|
|
+ * name 组织名称
|
|
|
+ * shortName 供应商公司简称(shortName)
|
|
|
+ * email 邮箱
|
|
|
+ * contractPhone 固定电话
|
|
|
+ * linkMan 联系人
|
|
|
+ * provinceId 省(provinceID)
|
|
|
+ * cityId 市(cityID)
|
|
|
+ * townId 所在县区Id(townID)
|
|
|
+ * address 地址
|
|
|
+ * socialCreditCode 统一社会信用代码(营业执照编号)
|
|
|
+ * businessLicense 营业执照(businessLicenseImage)
|
|
|
+ * firstShopType 医疗=1和非医疗=2
|
|
|
+ * secondShopType 医疗的二级分类 一类器械=1、二类器械 =2、三类器械=3、其他=4 /// 1和非医疗没有二级分类
|
|
|
+ * mainProduct 主打项目(mainpro)
|
|
|
+ * mainProductDesc 主打商品说明(productDesc)
|
|
|
+ * legalPerson 法人代表
|
|
|
+ * registeredCapital 注册资本
|
|
|
+ * faxNumber 传真号(fax)
|
|
|
+ * companyNature 传真号(nature)
|
|
|
+ * turnover 年营业额
|
|
|
+ * medicalPracticeLicense 医疗执业许可证(medicalPracticeLicenseImg1)
|
|
|
+ * shopDesc 公司介绍(info)
|
|
|
+ * businessScope 经营范围
|
|
|
+ * logo 公司LOGO
|
|
|
+ * operationLicence 生产经营证书(productionLicence)
|
|
|
+ * hygienicLicense 卫生许可证
|
|
|
+ * taxLicense 税务登记证
|
|
|
+ * honorCertification 荣誉证书(certificateHonor)
|
|
|
+ * productCertification 产品证书
|
|
|
+ * }
|
|
|
* @return ClubUpdateDto
|
|
|
*/
|
|
|
@ApiOperation("更新供应商资料")
|
|
|
@PostMapping("/info/update")
|
|
|
public ResponseJson updateShopUserInfo(ShopUpdateDto shopUpdateDto) {
|
|
|
String operationLicence = shopUpdateDto.getOperationLicence();
|
|
|
- String hygienicLicense = shopUpdateDto.getOperationLicence();
|
|
|
- String taxLicense = shopUpdateDto.getOperationLicence();
|
|
|
- String honorCertification = shopUpdateDto.getOperationLicence();
|
|
|
- String productCertification = shopUpdateDto.getOperationLicence();
|
|
|
+ String hygienicLicense = shopUpdateDto.getHygienicLicense();
|
|
|
+ String taxLicense = shopUpdateDto.getTaxLicense();
|
|
|
+ String honorCertification = shopUpdateDto.getHonorCertification();
|
|
|
+ String productCertification = shopUpdateDto.getProductCertification();
|
|
|
return shopService.updateShopUserInfo(shopUpdateDto, operationLicence, hygienicLicense, taxLicense, honorCertification, productCertification);
|
|
|
}
|
|
|
|