This commit is contained in:
stephb9959
2022-02-22 12:08:41 -08:00
parent 96bb22033e
commit f659da3b8e
10 changed files with 82 additions and 23 deletions

View File

@@ -188,6 +188,7 @@ namespace OpenWifi {
UInfo.changePassword = false;
UInfo.lastEmailCheck = std::time(nullptr);
UInfo.waitingForEmailCheck = false;
UInfo.validated = OpenWifi::Now();
StorageService()->SubDB().UpdateUserInfo(UInfo.email,Link.userId,UInfo);
@@ -195,6 +196,20 @@ namespace OpenWifi {
Types::StringPairVec FormVars{ {"UUID", Id},
{"USERNAME", UInfo.email} };
StorageService()->ActionLinksDB().CompleteAction(Id);
// Send the update to the provisioning service
Poco::JSON::Object Body;
OpenAPIRequestPut ProvRequest(uSERVICE_PROVISIONING,"/api/v1/signup",
{
{"signupUUID", UInfo.signingUp} ,
{"operation", "emailVerified"}
},
Body,30000);
Poco::JSON::Object::Ptr Response;
ProvRequest.Do(Response);
SendHTMLFileBack(FormFile,FormVars);
} else {
DoReturnA404();