Added solt key when transmitting transaction data via WebSocket.

This commit is contained in:
Преподобный Ален
2024-10-06 18:57:14 +03:00
parent a3459d370d
commit a88e2248c9

View File

@@ -614,6 +614,7 @@ namespace Apostol {
const auto &formType = FormData["type"];
const auto &formAt = FormData["at"];
const auto &formDate = FormData["date"];
const auto &formSalt = FormData["salt"];
const auto &formSellerAddress = FormData["seller_address"];
const auto &formSellerRating = FormData["seller_rating"];
const auto &formSellerSignature = FormData["seller_signature"];
@@ -630,7 +631,6 @@ namespace Apostol {
CheckKeyForNull("order", Action.c_str());
CheckKeyForNull("type", formType.c_str());
CheckKeyForNull("at", formAt.c_str());
// CheckKeyForNull("date", formDate.c_str());
CheckKeyForNull("seller_address", formSellerAddress.c_str());
CheckKeyForNull("customer_address", formCustomerAddress.c_str());
CheckKeyForNull("payment_sum", formPaymentSum.c_str());
@@ -650,6 +650,7 @@ namespace Apostol {
Deal["at"] = formAt.c_str();
Deal["date"] = formDate.IsEmpty() ? UTCFormat(DateToString(utc)).c_str() : formDate.c_str();
Deal["salt"] = formSalt.IsEmpty() ? GenSalt().c_str() : formSalt.c_str();
YAML::Node Seller = Deal["seller"];
@@ -701,6 +702,7 @@ namespace Apostol {
const auto &formType = FormData.Data("type");
const auto &formAt = FormData.Data("at");
const auto &formDate = FormData.Data("date");
const auto &formSalt = FormData.Data("salt");
const auto &formSellerAddress = FormData.Data("seller_address");
const auto &formSellerRating = FormData.Data("seller_rating");
const auto &formSellerSignature = FormData.Data("seller_signature");
@@ -717,7 +719,6 @@ namespace Apostol {
CheckKeyForNull("order", Action.c_str());
CheckKeyForNull("type", formType.c_str());
CheckKeyForNull("at", formAt.c_str());
//CheckKeyForNull("date", formDate.c_str());
CheckKeyForNull("seller_address", formSellerAddress.c_str());
CheckKeyForNull("customer_address", formCustomerAddress.c_str());
CheckKeyForNull("payment_sum", formPaymentSum.c_str());
@@ -737,6 +738,7 @@ namespace Apostol {
Deal["at"] = formAt.c_str();
Deal["date"] = formDate.IsEmpty() ? UTCFormat(DateToString(utc)).c_str() : formDate.c_str();
Deal["salt"] = formSalt.IsEmpty() ? GenSalt().c_str() : formSalt.c_str();
YAML::Node Seller = Deal["seller"];
@@ -789,6 +791,7 @@ namespace Apostol {
const auto &formAt = jsonData["at"].AsString();
const auto &formDate = jsonData["date"].AsString();
const auto &formSalt = jsonData["salt"].AsString();
const CJSONValue &jsonSeller = jsonData["seller"];
@@ -819,7 +822,6 @@ namespace Apostol {
CheckKeyForNull("order", action.c_str());
CheckKeyForNull("type", formType.c_str());
CheckKeyForNull("at", formAt.c_str());
//CheckKeyForNull("date", formDate.c_str());
CheckKeyForNull("seller.address", formSellerAddress.c_str());
CheckKeyForNull("customer.address", formCustomerAddress.c_str());
CheckKeyForNull("payment.sum", formPaymentSum.c_str());
@@ -839,6 +841,7 @@ namespace Apostol {
Deal["at"] = formAt.c_str();
Deal["date"] = formDate.IsEmpty() ? UTCFormat(DateToString(utc)).c_str() : formDate.c_str();
Deal["salt"] = formSalt.IsEmpty() ? GenSalt().c_str() : formSalt.c_str();
YAML::Node Seller = Deal["seller"];