parent
b060f46fb2
commit
9b921c3753
@ -0,0 +1,21 @@
|
||||
package com.xjs.mall;
|
||||
|
||||
import com.ruoyi.common.core.constant.ServiceNameConstants;
|
||||
import com.xjs.mall.other.R;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
|
||||
/**
|
||||
* 远程调用商品服务feign
|
||||
*
|
||||
* @author xiejs
|
||||
* @since 2022-03-24
|
||||
*/
|
||||
@FeignClient(contextId = "remoteProductFeign",
|
||||
value = ServiceNameConstants.MALL_PRODUCT_SERVICE)
|
||||
public interface RemoteProductFeign {
|
||||
|
||||
@GetMapping("/product/skuinfo/getSkuNameByIdForRPC/{skuId}")
|
||||
R getSkuNameById(@PathVariable("skuId") Long skuId);
|
||||
}
|
@ -1,16 +1,22 @@
|
||||
package com.xjs.mall.ware.dao;
|
||||
|
||||
import com.xjs.mall.ware.entity.WareSkuEntity;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import com.xjs.mall.ware.entity.WareSkuEntity;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
* 商品库存
|
||||
*
|
||||
*
|
||||
* @author xiejs
|
||||
* @email 1294405880@qq.com
|
||||
* @date 2022-03-15 09:56:19
|
||||
*/
|
||||
public interface WareSkuDao extends BaseMapper<WareSkuEntity> {
|
||||
|
||||
/**
|
||||
* 添加库存
|
||||
* @param skuId 商品id
|
||||
* @param wareId 仓库id
|
||||
* @param skuNum 商品数量
|
||||
*/
|
||||
void addStock(@Param("skuId") Long skuId, @Param("wareId") Long wareId, @Param("skuNum") Integer skuNum);
|
||||
}
|
||||
|
@ -0,0 +1,18 @@
|
||||
package com.xjs.mall.ware.vo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 采购单完成vo
|
||||
*/
|
||||
@Data
|
||||
public class PurchaseDoneVo {
|
||||
|
||||
@NotNull
|
||||
private Long id;//采购单id
|
||||
|
||||
private List<PurchaseItemDoneVo> items;
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package com.xjs.mall.ware.vo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 采购单采购项目vo
|
||||
*/
|
||||
@Data
|
||||
public class PurchaseItemDoneVo {
|
||||
//{itemId:1,status:4,reason:""}
|
||||
private Long itemId;
|
||||
private Integer status;
|
||||
private String reason;
|
||||
}
|
Loading…
Reference in new issue