@verified-network/verified-sdk 0.4.4 → 0.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -37,7 +37,7 @@ class ProductContract extends index_1.VerifiedContract {
|
|
|
37
37
|
await this.validateInput(index_1.DATATYPES.STRING, _arrangerCountry);
|
|
38
38
|
await this.validateInput(index_1.DATATYPES.STRING, _arrangerSignatoryEmail);
|
|
39
39
|
await this.validateInput(index_1.DATATYPES.STRING, _registrationDocuments);
|
|
40
|
-
return this.callContract(FUNCTIONS.
|
|
40
|
+
return this.callContract(FUNCTIONS.REGISTERPRODUCT, this.sanitiseInput(index_1.DATATYPES.BYTE32, _productCategory), this.sanitiseInput(index_1.DATATYPES.BYTE32, _issuerName), this.sanitiseInput(index_1.DATATYPES.BYTE32, _issuerAddress), this.sanitiseInput(index_1.DATATYPES.BYTE32, _issuerCountry), this.sanitiseInput(index_1.DATATYPES.BYTE32, _issuerSignatoryEmail), this.sanitiseInput(index_1.DATATYPES.BYTE32, _arrangerName), this.sanitiseInput(index_1.DATATYPES.BYTE32, _arrangerAddress), this.sanitiseInput(index_1.DATATYPES.BYTE32, _arrangerCountry), this.sanitiseInput(index_1.DATATYPES.BYTE32, _arrangerSignatoryEmail), _registrationDocuments, options);
|
|
41
41
|
}
|
|
42
42
|
async getProductsForClient() {
|
|
43
43
|
return this.callContract(FUNCTIONS.CLIENTPRODUCT);
|
|
@@ -55,33 +55,33 @@ class ProductContract extends index_1.VerifiedContract {
|
|
|
55
55
|
}
|
|
56
56
|
async getProduct(_ref, options) {
|
|
57
57
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
58
|
-
return this.callContract(FUNCTIONS.GETPRODUCT,
|
|
58
|
+
return this.callContract(FUNCTIONS.GETPRODUCT, _ref, options);
|
|
59
59
|
}
|
|
60
60
|
async registerCertificate(_ref, _issuerCertificate, _arrangerCertificate, options) {
|
|
61
61
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
62
62
|
await this.validateInput(index_1.DATATYPES.STRING, _issuerCertificate);
|
|
63
63
|
await this.validateInput(index_1.DATATYPES.STRING, _arrangerCertificate);
|
|
64
|
-
return this.callContract(FUNCTIONS.REGISTERCERTIFICATE,
|
|
64
|
+
return this.callContract(FUNCTIONS.REGISTERCERTIFICATE, _ref, _issuerCertificate, _arrangerCertificate, options);
|
|
65
65
|
}
|
|
66
66
|
async getCertificate(_ref, options) {
|
|
67
67
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
68
|
-
return this.callContract(FUNCTIONS.GETCERTIFICATE,
|
|
68
|
+
return this.callContract(FUNCTIONS.GETCERTIFICATE, _ref, options);
|
|
69
69
|
}
|
|
70
70
|
async confirmProduct(_ref, options) {
|
|
71
71
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
72
|
-
return this.callContract(FUNCTIONS.CONFIRMPRODUCT,
|
|
72
|
+
return this.callContract(FUNCTIONS.CONFIRMPRODUCT, _ref, options);
|
|
73
73
|
}
|
|
74
74
|
async getIssue(_ref, options) {
|
|
75
75
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
76
|
-
return this.callContract(FUNCTIONS.GETISSUE,
|
|
76
|
+
return this.callContract(FUNCTIONS.GETISSUE, _ref, options);
|
|
77
77
|
}
|
|
78
78
|
async getIssuerName(_ref, options) {
|
|
79
79
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
80
|
-
return this.callContract(FUNCTIONS.GETISSUERNAME,
|
|
80
|
+
return this.callContract(FUNCTIONS.GETISSUERNAME, _ref, options);
|
|
81
81
|
}
|
|
82
82
|
async getIssuerAddress(_ref, options) {
|
|
83
83
|
await this.validateInput(index_1.DATATYPES.STRING, _ref);
|
|
84
|
-
return this.callContract(FUNCTIONS.GETISSUERADDRESS,
|
|
84
|
+
return this.callContract(FUNCTIONS.GETISSUERADDRESS, _ref, options);
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
exports.default = ProductContract;
|