| | |
| | | Completable insert(InspectionBean inspectionBean); |
| | | |
| | | @Update |
| | | void update(InspectionBean inspectionBean); |
| | | Completable update(InspectionBean inspectionBean); |
| | | |
| | | @Delete |
| | | void delete(InspectionBean inspectionBean); |
| | |
| | | @Query("DELETE FROM InspectionBean") |
| | | void deleteAll(); |
| | | |
| | | |
| | | //查询当前没有关闭巡检的巡检ID |
| | | @Query("SELECT * FROM InspectionBean WHERE stopTime IS NULL OR stopTime = '' ORDER BY startTime DESC LIMIT 1") |
| | | Single<InspectionBean> getMostRecentInspectionWithNoStopTime(); |
| | | |
| | | /** |
| | | * 根据本地巡检id查询巡检记录信息 |
| | | * |
| | | * @param mInspectId |
| | | * @return |
| | | */ |
| | | @Query("SELECT * FROM InspectionBean WHERE mInspectId =:mInspectId ORDER BY startTime DESC LIMIT 1") |
| | | Single<InspectionBean> findBymInspectId(String mInspectId); |
| | | |
| | | } |