fix web cmd 70 bugs
This commit is contained in:
parent
8887d777b5
commit
7685e7240c
@ -1621,13 +1621,16 @@ std::string JsonData::JsonCmd_Cgi_70(Param_70 ¶m){
|
|||||||
jsonVal["message"] = " ";
|
jsonVal["message"] = " ";
|
||||||
char selectCon[256] = {0}, szTableName[100] = {0x00}, whereCon[256] = {0x00};
|
char selectCon[256] = {0}, szTableName[100] = {0x00}, whereCon[256] = {0x00};
|
||||||
sprintf(szTableName,"t_process_info");
|
sprintf(szTableName,"t_process_info");
|
||||||
int rows = sqlite_db_ctrl::instance().GetTableRows(szTableName, NULL);
|
memset(whereCon, 0x00, sizeof(whereCon));
|
||||||
|
sprintf(whereCon, "timeStamp < '%s' and timeStamp > '%s'", param.timeEnd.c_str(), param.timeStart.c_str());
|
||||||
|
int rows = sqlite_db_ctrl::instance().GetTableRows(szTableName, whereCon);
|
||||||
int packgeNo = param.mPackageFlag;
|
int packgeNo = param.mPackageFlag;
|
||||||
int packgeMax = 0;
|
int packgeMax = 0;
|
||||||
int packgeNum = 0;
|
int packgeNum = 0;
|
||||||
jsonVal["package"] = packgeNo;
|
jsonVal["package"] = packgeNo;
|
||||||
int lastSize = rows % 550;
|
int lastSize = rows % 550;
|
||||||
int index = rows / 550;
|
int index = rows / 550;
|
||||||
|
zlog_info(zct, "rows = %d, lastSize = %d, index = %d", rows, lastSize, index);
|
||||||
if (lastSize > 0 && index > 0) {
|
if (lastSize > 0 && index > 0) {
|
||||||
packgeMax = index + 1;
|
packgeMax = index + 1;
|
||||||
if (packgeNo + 1 == packgeMax) {
|
if (packgeNo + 1 == packgeMax) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user