package com.huatek.busi.service.impl;

import com.alibaba.dubbo.config.annotation.Service;
import com.huatek.busi.entity.LabGenReportParamData;
import com.huatek.busi.service.ILabGenReportParamDataService;
import com.huatek.busi.service.ILabKggReportParamDataService;
import com.huatek.busi.service.ILabReportParamDataService;
import com.huatek.busi.vo.LabReportParamDataVo;
import com.huatek.frame.base.util.BeanUtils;
import com.huatek.torch.sql.dao.impl.BaseDao;
import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;

@Component
@Service(interfaceClass = ILabGenReportParamDataService.class)
@Transactional(rollbackFor = Exception.class)
public class LabGenReportParamDataServiceImpl extends BaseDao<LabGenReportParamData, String> implements ILabGenReportParamDataService {

    @Override
    public int insert(LabReportParamDataVo labReportParamDataVo){
        LabGenReportParamData labGenReportParamData = new LabGenReportParamData();
        BeanUtils.copyProperties(labReportParamDataVo, labGenReportParamData);
        return this.add(labGenReportParamData);
    }
}
