package com.YuyeTech.TPlat.service.impl;

import com.YuyeTech.TPlat.dataobject.OtaInfo;
import com.YuyeTech.TPlat.repository.OtaInfoRepository;
import com.YuyeTech.TPlat.service.OtaInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author:slambb
 * @date:2020/1/10
 */
@Service
public class OtaInfoServiceImpl implements OtaInfoService {
    @Autowired
    private OtaInfoRepository otaInfoRepository;

    @Override
    public OtaInfo findOTAByBLETypeAndStatus(Integer bleType, Integer otaStatus) {
        return otaInfoRepository.findByBleTypeAndOtaStatus(bleType,otaStatus).orElse(null);
    }
}
