package com.fzm.mall.server.front.asset.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fzm.mall.server.front.asset.model.Tran;
import com.baomidou.mybatisplus.extension.service.IService;
import com.fzm.mall.server.front.asset.model.dto.UserAssetTransferSaveDTO;
import com.fzm.mall.server.front.asset.model.dto.UserAssetTransferUpdateDTO;
import com.fzm.mall.server.front.asset.model.vo.GoodsTransVO;
import com.fzm.mall.server.front.asset.model.vo.UserAssetTransferVO;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author fzm
 * @since 2021-09-07
 */
public interface ITranService extends IService<Tran> {
    IPage<GoodsTransVO> page(Page<GoodsTransVO> page, String keyword);

    IPage<GoodsTransVO> pageSerach(Page<GoodsTransVO> page, String keyword,String goodsIds,String price,String sale);

    Tran getByTranId(String tranId);

    Tran getByTranIdForUpdate(Integer id);

    int delStock(Integer id, Integer number);

    Tran getByUidAndOid(String uid, String tranId);

    void save(UserAssetTransferSaveDTO saveDTO);

    Long update(UserAssetTransferUpdateDTO updateDTO);

    void cancle(String uid, String transferId);

    UserAssetTransferVO read(String transferId);

    IPage<UserAssetTransferVO> page(Page<UserAssetTransferVO> page, String uid, String keyword);
}
