New sign up

This commit is contained in:
dev-chiefworks
2022-04-20 23:37:53 -04:00
parent 72dca21238
commit d9c091d8d5
2 changed files with 56 additions and 3 deletions
+2 -3
View File
@@ -5,7 +5,7 @@ use CodeIgniter\HTTP\URI;
use App\Services\FloatLogin;
use App\Services\UserProfile;
use App\Services\ResetPassword;
use App\Services\NewUserApi;
use GuzzleHttp\Client as HTTPClient;
@@ -222,8 +222,7 @@ private function testCards(){
$in["country"] = "US";
$in["loc"] = $_SERVER["REMOTE_ADDR"];
log_message('critical', "in API-WAS CALLED user 009=>".$endpoint );
$res = NewUserApi::createAccount($data);
log_message('critical', "out API-WAS CALLED user 009=>".$endpoint );
break;
case 'userlogin': $in["action"] = SAVVY_USER_LOGINACCOUNT;
+54
View File
@@ -0,0 +1,54 @@
<?php
namespace App\Services;
use GuzzleHttp\Client as HTTPClient;
class NewUserApi extends CoreServiceApi
{
public static function createAccount($data)
{
$res =[];
$mode = (int) $mode;
log_message('critical', "createAccount=>Mode ====>===>" );
/*
CRITICAL - 2022-04-20 22:27:16 --> API-WAS CALLED user
CRITICAL - 2022-04-20 22:27:16 --> API-WAS CALLED user
CRITICAL - 2022-04-20 22:27:16 --> API-WAS CALLED user 009=>createuser
CRITICAL - 2022-04-20 22:27:16 --> username=>lviet3@float.sg
CRITICAL - 2022-04-20 22:27:16 --> password=>a1234567
CRITICAL - 2022-04-20 22:27:16 --> sessionid=>DUMMYSESSION
CRITICAL - 2022-04-20 22:27:16 --> email=>lviet3@float.sg
CRITICAL - 2022-04-20 22:27:16 --> phone=>097879787
CRITICAL - 2022-04-20 22:27:16 --> firstname=>Le
CRITICAL - 2022-04-20 22:27:16 --> lastname=>Viet
CRITICAL - 2022-04-20 22:27:16 --> signup_random=>
CRITICAL - 2022-04-20 22:27:16 --> verify_link=>
CRITICAL - 2022-04-20 22:27:16 --> start_mode=>200
CRITICAL - 2022-04-20 22:27:16 --> signUpSurveyData=>ssq0 => Array
ssq1 => Array
ssq2 => Array
*/
$arr = array(
'start_mode' => $data['start_mode'],
'username' => $data['username'],
'password' => $data['password'],
'email' => $data['email'],
'phone' => $data['phone'],
'sessionid' => $data['sessionid'],
'firstname' => $data['firstname'],
'lastname' => $data['lastname'],
'signup_random' => $data['signup_random'],
'verify_link' => $data['verify_link']
);
$data_json = json_encode($arr);
$res = self::NodeServiceApi('user/register', $data_json);
return $res;
}
}