mirror of
				https://github.com/Telecominfraproject/wlan-cloud-ucentralsec.git
				synced 2025-10-31 02:37:56 +00:00 
			
		
		
		
	Compare commits
	
		
			5 Commits
		
	
	
		
			release/v3
			...
			v2.4.0-RC3
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
|   | 85d998ad76 | ||
|   | a407f2e38d | ||
|   | d0d2be0870 | ||
|   | 78cba562e6 | ||
|   | 350df38c3f | 
| @@ -8,7 +8,7 @@ fullnameOverride: "" | |||||||
| images: | images: | ||||||
|   owsec: |   owsec: | ||||||
|     repository: tip-tip-wlan-cloud-ucentral.jfrog.io/owsec |     repository: tip-tip-wlan-cloud-ucentral.jfrog.io/owsec | ||||||
|     tag: main |     tag: v2.4.0-RC3 | ||||||
|     pullPolicy: Always |     pullPolicy: Always | ||||||
| #    regcred: | #    regcred: | ||||||
| #      registry: tip-tip-wlan-cloud-ucentral.jfrog.io | #      registry: tip-tip-wlan-cloud-ucentral.jfrog.io | ||||||
|   | |||||||
| @@ -1900,7 +1900,7 @@ namespace OpenWifi { | |||||||
| 	            QB_.SerialNumber = GetParameter(RESTAPI::Protocol::SERIALNUMBER, ""); | 	            QB_.SerialNumber = GetParameter(RESTAPI::Protocol::SERIALNUMBER, ""); | ||||||
| 	            QB_.StartDate = GetParameter(RESTAPI::Protocol::STARTDATE, 0); | 	            QB_.StartDate = GetParameter(RESTAPI::Protocol::STARTDATE, 0); | ||||||
| 	            QB_.EndDate = GetParameter(RESTAPI::Protocol::ENDDATE, 0); | 	            QB_.EndDate = GetParameter(RESTAPI::Protocol::ENDDATE, 0); | ||||||
| 	            QB_.Offset = GetParameter(RESTAPI::Protocol::OFFSET, 1); | 	            QB_.Offset = GetParameter(RESTAPI::Protocol::OFFSET, 0); | ||||||
| 	            QB_.Limit = GetParameter(RESTAPI::Protocol::LIMIT, 100); | 	            QB_.Limit = GetParameter(RESTAPI::Protocol::LIMIT, 100); | ||||||
| 	            QB_.Filter = GetParameter(RESTAPI::Protocol::FILTER, ""); | 	            QB_.Filter = GetParameter(RESTAPI::Protocol::FILTER, ""); | ||||||
| 	            QB_.Select = GetParameter(RESTAPI::Protocol::SELECT, ""); | 	            QB_.Select = GetParameter(RESTAPI::Protocol::SELECT, ""); | ||||||
| @@ -1912,7 +1912,7 @@ namespace OpenWifi { | |||||||
| 	            QB_.AdditionalInfo = GetBoolParameter(RESTAPI::Protocol::WITHEXTENDEDINFO,false); | 	            QB_.AdditionalInfo = GetBoolParameter(RESTAPI::Protocol::WITHEXTENDEDINFO,false); | ||||||
|  |  | ||||||
| 	            if(QB_.Offset<1) | 	            if(QB_.Offset<1) | ||||||
| 	                QB_.Offset=1; | 	                QB_.Offset=0; | ||||||
| 	            return true; | 	            return true; | ||||||
| 	        } | 	        } | ||||||
|  |  | ||||||
|   | |||||||
| @@ -2,8 +2,7 @@ | |||||||
| // Created by stephane bourque on 2021-10-06. | // Created by stephane bourque on 2021-10-06. | ||||||
| // | // | ||||||
|  |  | ||||||
| #ifndef OPENWIFI_STORAGE_H | #pragma once | ||||||
| #define OPENWIFI_STORAGE_H |  | ||||||
|  |  | ||||||
| #include "Poco/Data/Session.h" | #include "Poco/Data/Session.h" | ||||||
| #include "Poco/Data/SessionPool.h" | #include "Poco/Data/SessionPool.h" | ||||||
| @@ -54,13 +53,13 @@ namespace OpenWifi { | |||||||
|  |  | ||||||
|         [[nodiscard]] inline std::string ComputeRange(uint64_t From, uint64_t HowMany) { |         [[nodiscard]] inline std::string ComputeRange(uint64_t From, uint64_t HowMany) { | ||||||
|             if(dbType_==sqlite) { |             if(dbType_==sqlite) { | ||||||
|                 return " LIMIT " + std::to_string(From-1) + ", " + std::to_string(HowMany) + " "; |                 return " LIMIT " + std::to_string(From) + ", " + std::to_string(HowMany) + " "; | ||||||
|             } else if(dbType_==pgsql) { |             } else if(dbType_==pgsql) { | ||||||
|                 return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From-1) + " "; |                 return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From) + " "; | ||||||
|             } else if(dbType_==mysql) { |             } else if(dbType_==mysql) { | ||||||
|                 return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From-1) + " "; |                 return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From) + " "; | ||||||
|             } |             } | ||||||
|             return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From-1) + " "; |             return " LIMIT " + std::to_string(HowMany) + " OFFSET " + std::to_string(From) + " "; | ||||||
|         } |         } | ||||||
|  |  | ||||||
|         inline std::string ConvertParams(const std::string & S) const { |         inline std::string ConvertParams(const std::string & S) const { | ||||||
| @@ -165,5 +164,3 @@ namespace OpenWifi { | |||||||
| #endif | #endif | ||||||
|  |  | ||||||
| } | } | ||||||
|  |  | ||||||
| #endif //OPENWIFI_STORAGE_H |  | ||||||
|   | |||||||
| @@ -15,23 +15,23 @@ namespace OpenWifi { | |||||||
|             "description    varchar," |             "description    varchar," | ||||||
|             "avatar         varchar," |             "avatar         varchar," | ||||||
|             "email          varchar," |             "email          varchar," | ||||||
|             "validated      int," |             "validated      boolean," | ||||||
|             "validationEmail    varchar," |             "validationEmail    varchar," | ||||||
|             "validationDate bigint," |             "validationDate bigint," | ||||||
|             "creationDate   bigint," |             "creationDate   bigint," | ||||||
|             "validationURI  varchar," |             "validationURI  varchar," | ||||||
|             "changePassword int," |             "changePassword boolean," | ||||||
|             "lastLogin      bigint," |             "lastLogin      bigint," | ||||||
|             "currentLoginURI    varchar," |             "currentLoginURI    varchar," | ||||||
|             "lastPasswordChange bigint," |             "lastPasswordChange bigint," | ||||||
|             "lastEmailCheck     bigint," |             "lastEmailCheck     bigint," | ||||||
|             "waitingForEmailCheck   int," |             "waitingForEmailCheck   boolean," | ||||||
|             "locale             varchar," |             "locale             varchar," | ||||||
|             "notes              text," |             "notes              text," | ||||||
|             "location           varchar," |             "location           varchar," | ||||||
|             "owner              varchar," |             "owner              varchar," | ||||||
|             "suspended          int," |             "suspended          boolean," | ||||||
|             "blackListed        int," |             "blackListed        boolean," | ||||||
|             "userRole           varchar," |             "userRole           varchar," | ||||||
|             "userTypeProprietaryInfo    text," |             "userTypeProprietaryInfo    text," | ||||||
|             "securityPolicy     text," |             "securityPolicy     text," | ||||||
| @@ -111,23 +111,23 @@ namespace OpenWifi { | |||||||
|         std::string,    // description; |         std::string,    // description; | ||||||
|         std::string,    // avatar; |         std::string,    // avatar; | ||||||
|         std::string,    // email; |         std::string,    // email; | ||||||
|         uint64_t,       // bool validated = false; |         bool,       // bool validated = false; | ||||||
|         std::string,    // validationEmail; |         std::string,    // validationEmail; | ||||||
|         uint64_t,       // validationDate = 0; |         uint64_t,       // validationDate = 0; | ||||||
|         uint64_t,       // creationDate = 0; |         uint64_t,       // creationDate = 0; | ||||||
|         std::string,    // validationURI; |         std::string,    // validationURI; | ||||||
|         uint64_t,       // bool changePassword = true; |         bool,       // bool changePassword = true; | ||||||
|         uint64_t,       // lastLogin = 0; |         uint64_t,       // lastLogin = 0; | ||||||
|         std::string,    // currentLoginURI; |         std::string,    // currentLoginURI; | ||||||
|         uint64_t,       // lastPasswordChange = 0; |         uint64_t,       // lastPasswordChange = 0; | ||||||
|         uint64_t,       // lastEmailCheck = 0; |         uint64_t,       // lastEmailCheck = 0; | ||||||
|         uint64_t,      // bool waitingForEmailCheck = false; |         bool,      // bool waitingForEmailCheck = false; | ||||||
|         std::string,    // locale; |         std::string,    // locale; | ||||||
|         std::string,    // notes; |         std::string,    // notes; | ||||||
|         std::string,    // location; |         std::string,    // location; | ||||||
|         std::string,    // owner; |         std::string,    // owner; | ||||||
|         uint64_t,       // bool suspended = false; |         bool,       // bool suspended = false; | ||||||
|         uint64_t,       // bool blackListed = false; |         bool,       // bool blackListed = false; | ||||||
|         std::string,    // userRole; |         std::string,    // userRole; | ||||||
|         std::string,    // userTypeProprietaryInfo; |         std::string,    // userTypeProprietaryInfo; | ||||||
|         std::string,    // securityPolicy; |         std::string,    // securityPolicy; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user