123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- #ifndef MINE_H
- #define MINE_H
- #include <unordered_map>
- #include <log.h>
- #include <chrono>
- #include "common.h"
- #include <memory>
- struct card_location_base;
- struct mine_tool
- {
- mine_tool()
- :m_over_speed_count(0)
- ,m_normal_speed_count(0)
- ,m_status_call(0)
- ,m_is_attendance(false)
- ,m_attendance_start_time(std::chrono::seconds(0))
- ,m_is_overtime(false)
- ,m_overtime(std::chrono::seconds(0))
- {
- }
- int m_over_speed_count;
- int m_normal_speed_count;
-
- int m_status_call;
-
- bool m_is_attendance;
-
- std::chrono::system_clock::time_point m_attendance_start_time;
-
- bool m_is_overtime;
-
- std::chrono::system_clock::time_point m_overtime;
- void on_point(uint32_t card_id, int32_t type, int vehicle_category_id);
-
- void on_check_overtime(uint32_t card_id, int32_t type);
- uint64_t get_down_time();
- uint64_t get_work_time();
- int32_t is_on_duty();
- };
- #endif
|