package org.jeecg.modules.eam.service.impl; import org.jeecg.common.constant.CommonConstant; import org.jeecg.modules.eam.entity.TransferMethod; import org.jeecg.modules.eam.entity.TransferMethodCategory; import org.jeecg.modules.eam.mapper.TransferMethodMapper; import org.jeecg.modules.eam.service.ITransferMethodCategoryService; import org.jeecg.modules.eam.service.ITransferMethodService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import java.util.List; /** * @Description: 调拨方式 * @Author: houjie * @Date: 2023-03-06 * @Version: V1.0 */ @Service public class TransferMethodServiceImpl extends ServiceImpl implements ITransferMethodService { @Autowired ITransferMethodCategoryService transferMethodCategoryService; @Override public List getListByType(String type) { List transferMethodCategoryList = transferMethodCategoryService.listByType(type); TransferMethodCategory transferMethodCategory = transferMethodCategoryList.size() > 0 ? transferMethodCategoryList.get(0) : new TransferMethodCategory(); String transferMethodCategoryId = transferMethodCategory.getId(); List transferMethodList = super.lambdaQuery().eq(TransferMethod::getTransferMethodCategoryId, transferMethodCategoryId) .eq(TransferMethod::getDelFlag, CommonConstant.DEL_FLAG_0).list(); return transferMethodList; } }