package org.jeecg.modules.mdc.service.impl;
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import org.jeecg.common.constant.CommonConstant;
|
import org.jeecg.modules.mdc.entity.MdcDriveTypeParamConfig;
|
import org.jeecg.modules.mdc.mapper.MdcDriveTypeParamConfigMapper;
|
import org.jeecg.modules.mdc.service.IMdcDriveTypeParamConfigService;
|
import org.springframework.stereotype.Service;
|
|
import java.util.Arrays;
|
import java.util.List;
|
|
/**
|
* @Description: 驱动参数配置
|
* @Author: jeecg-boot
|
* @Date: 2023-04-20
|
* @Version: V1.0
|
*/
|
@Service
|
public class MdcDriveTypeParamConfigServiceImpl extends ServiceImpl<MdcDriveTypeParamConfigMapper, MdcDriveTypeParamConfig> implements IMdcDriveTypeParamConfigService {
|
|
/**
|
* 根据驱动类型获取设备显示参数
|
*/
|
@Override
|
public List<MdcDriveTypeParamConfig> getShowDriveParam(String driveType) {
|
return lambdaQuery().eq(MdcDriveTypeParamConfig::getControlSystemType, driveType).eq(MdcDriveTypeParamConfig::getShowFlag, CommonConstant.YN_Y).list();
|
}
|
|
/**
|
* 根据设备编码获取工作曲线参数
|
*/
|
@Override
|
public List<MdcDriveTypeParamConfig> findWorkCurveParamList(String equipmentId) {
|
return this.baseMapper.findWorkCurveParamList(equipmentId);
|
}
|
|
@Override
|
public List<MdcDriveTypeParamConfig> getByTypeCodeMdcShowCode(String codeTypeId) {
|
return this.baseMapper.selectBatchIds(Arrays.asList(codeTypeId.split(",")));
|
}
|
}
|