| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 | 
							- #pragma once
 
- #include <httplib.h>
 
- #include "AlarmDefine.h"
 
- #define  IS_NULL(x)  (x ? x : "")
 
- void DealHttpGet(const httplib::Request& req, httplib::Response& res);
 
- void DealHttpPost(const httplib::Request& req, httplib::Response& res);
 
- //SVG
 
- int DealPostSvgData(const httplib::Request& req,const string token, httplib::Response& res);
 
- int DealGetSvgData(const httplib::Request& req, const string token, httplib::Response& res);
 
- int DealOptionSvgData(const httplib::Request& req, const string token, httplib::Response& res);
 
- //获取站场图状态
 
- int DealGetMpStat(const httplib::Request& req, const string token, httplib::Response& res);
 
- int DealGetMitieLock(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealGetConvertResist(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealGetRetesionForce(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- //获取日曲线
 
- int DealGetResistCurve(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealGetRetentionCurve(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- //获取日报表
 
- int DealGetResistReport(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealGetRetentionReport(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- //获取扳动信息
 
- int DealGetMoveInfo(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealResistMove(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- //上传升级文件
 
- int DealPostBinData(const httplib::Request& req, const string token, httplib::Response& res);
 
- int DealPostMitieLock(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- int DealPostConvertResist(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- int DealPosttRetesionForce(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- //浏览记录
 
- int DealPostCommitRecord(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- int DealGetOptLog(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int ExecSqlForRecord(eRecord_Module module, int dura, uint8_t analyze_type, string& strStation, string& strStationName, const char* mo, const char* mo_name, const char* mp, const char* mp_name,
 
- 	uint64_t start_time, uint64_t end_time, time_t tt, string& strName, const char* username, eRocord_Opt opt, string& mark);
 
- //参考曲线
 
- int DealGetrefer_option(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealGetrefer_curve(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int DealPostrefer_curve(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- int WriteReferFile(const string& station, const string& mo, const string& mp, uint8_t posi,
 
- 	const std::map<time_t, int>& data0, const std::map<time_t, int>& data1, const std::map<time_t, int>& data2, OUT string& msg);
 
- int ReadReferFile(const string& station, const string& mo, const string& mp, uint8_t posi, time_t show_time, yyjson_mut_doc* mut_doc,
 
- 	yyjson_mut_val* arr, OUT string& msg);
 
- //报警
 
- int deal_get_reminder_interval(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- int deal_post_reminder_interval(const char* body_ptr, const size_t body_len, const string token, char** json, size_t* json_len);
 
- int deal_get_alarm_list(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
- //历史数据
 
- int DealGetResistData(const httplib::Request& req, const string token, char** json, size_t* json_len);
 
 
  |