/*
 * 封装发送类
*/
#ifndef VEHINFO_H
#define VEHINFO_H
#include <iostream>
#include <vector>
#include <QQueue>
using namespace std;
#pragma pack(1)
struct VehInfor
{
    string weightNum;
    string plateNum;
    int axleCnt;
    float sumWeight;
    float tareWeight;
    float grossWeight;
    float suttleWeight;
    int reduceWeightPer;
    float realWeight;
    float limitWeight;
    float overWeight;
    float overPer;
    string goodsName;
    string goodsType;
    string driver;
    string sendCompany;
    string recvCompany;
    string trafficCompany;
    string remark;
    int lane;
    int speed;
    int length;
    int width;
    int height;
    string picPath;
    string dateTime;
    string createTime;
    string weightTime;
    string printerTime;
    string interTime;//入口时间，格式yyyy-MM-dd HH:mm:ss
    string outTime;//入口时间，格式yyyy-MM-dd HH:mm:ss
    string platePic;    //车牌特写图，base64编码
    string platePicPostfix = "jpg";//图片后缀，默认jpg
    string frontPic;//前抓拍，base64编码
    string frontPicPostfix = "jpg";//图片后缀，默认jpg
    string key = "123456";
};
struct SelectInfor
{
    int ECode;
    string Operator;
    string startTime;
    string Pound;
    string stopTime;
    string Weight;
    string Type;
    string Time;
    string RealCache;
    string GoodsType;
    string Customer;
    string Notes;
    string remark;
};
struct SelectInfor1
{
    string startTime;
    string stopTime;
    string plateNum;
    float startWeight;
    float stopWeight;
    string remark;
};
typedef struct TSversion
{
    char szVersion[64];
    char szDateTime[64];
    char szDescription[128];
}TSVERSION;
struct Vehicle{
    int lane;
    long flowNo;
    char dateTime[50];
    unsigned char runState;
    unsigned char deviceState;
    double speed;
    double acceleration;
    int reverse;//0 正向，1 逆向
    int axleCnt;
    int axleGrpCnt;
    string axleWeight;
    string axleGrpWeight;
    string axleDis;
    string axleCrpType;
    long sumWeight;
    int length;
    char timeFlowNo[64];
};
struct VehicleCam
{
    string plateNum;
    string picPath;
    string deviceId;
    void* picContent;
    long picLen;
};
struct CameraInfor
{
    string ip;
    int port;
    string user;
    string pwd;
    int lane;
    int direction;
    string deviceId;
};
struct screenArea
{
    int areaId;
    int x;
    int y;
    int w;
    int h;
    int fontSize;
};
struct User
{
    string userName;
    string pwd;
    string sex;
    string mobile;
    string remark;
    bool isRemeber;
};
struct SendWeightForm
{
    string userName = "admin"; //过磅员
    string poundNo = "001"; //磅号
    string key = "123456";
    string stationCode; //站点编号
    string plateNum;    //车牌号
    string checkNo;
    string stationId;
    int patternType = 2; //业务模式:  1-标准流程一  2-标准流程二
    int modeDisplayType = 2; //业务详情显示:  1-标准流程一显示出入口信息  2-标准流程二不显示出入口信息
    int tareWeight;
    int grossWeight;
    int suttleWeight;
    string dateTime;
    //新增字段
    int weighterNum;
    int success;            //注册成功
    int exceptionCode;       //异常代码
    int vehicleType;        //车型
    int axleCnt;            //轴数
    int  axleType;          //轴型
    float sumWeight;          //车货总重，放大一百倍
    int axleWeight1;    //1轴重，放大一百倍
    int axleWeight2;    //2轴重，放大一百倍
    int axleWeight3;    //3轴重，放大一百倍
    int axleWeight4;    //4轴重，放大一百倍
    int axleWeight5;    //5轴重，放大一百倍
    int axleWeight6;    //6轴重，放大一百倍
    int axleWeight7;    //7轴重，放大一百倍
    int axleWeight8;    //8轴重，放大一百倍
    int limitWeight;    //限重，放大一百倍
    int overWeight;                    //超重，放大一百倍
    string weightTime;               //称重时间，格式yyyy-MM-dd HH:mm:ss
    string interTime;                   //入口时间，格式yyyy-MM-dd HH:mm:ss
    string outTime;                   //入口时间，格式yyyy-MM-dd HH:mm:ss
    string platePic;                 //车牌特写图，base64编码
    string platePicPostfix = "jpg"; //图片后缀，默认jpg
    string frontPic;                //前抓拍，base64编码
    string frontPicPostfix = "jpg"; //图片后缀，默认jpg
    string backPic;                 //后抓拍，base64编码
    string backPicPostfix = "jpg";  //图片后缀，默认jpg
    string lSidePic;                //左侧侧抓拍，base64编码
    string lsidePicPostfix = "jpg"; //图片后缀，默认jpg
    string rSidePic;                //右侧侧抓拍，base64编码
    string rsidePicPostfix = "jpg"; //图片后缀，默认jpg
    string upPic;                   //顶抓拍，base64编码
    string upPicPostfix = "jpg";    //图片后缀，默认jpg
    string movie;                   //过车小视频，base64编码
    string moviePostfix = "mp4";    //短视频后缀，默认mp4
    string busNum;                  //订单业务流水号
    string icNum;                  //订单业务流水号

};
struct PacketHeartBeat
{/*心跳包
    上行指令 0x05: 心跳包
    Json字段	数据类型	描述
    ping	String	值为1*/
    string key = "123456";
    string ping;
};
#pragma pack ()
#endif // VEHINFO_H
