@veloceapps/api 3.0.0 → 3.0.1
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.
- package/bundles/veloce-api.umd.js +16 -35
- package/bundles/veloce-api.umd.js.map +1 -1
- package/esm2015/lib/services/quote-api.service.js +5 -13
- package/esm2015/lib/services/salesforce-api.service.js +13 -24
- package/fesm2015/veloce-api.js +16 -35
- package/fesm2015/veloce-api.js.map +1 -1
- package/lib/services/quote-api.service.d.ts +3 -3
- package/lib/services/salesforce-api.service.d.ts +7 -7
- package/package.json +2 -1
@@ -968,40 +968,29 @@
|
|
968
968
|
this.httpService = httpService;
|
969
969
|
this.SERVICE_URL = '/proxy';
|
970
970
|
}
|
971
|
-
SalesforceApiService.prototype.query = function (searchRequest, objectName) {
|
972
|
-
return this.httpService.api({
|
973
|
-
method: 'post',
|
974
|
-
body: Object.assign(Object.assign({}, searchRequest), { count: searchRequest.count || 100 }),
|
975
|
-
url: this.SERVICE_URL + "/query/" + objectName,
|
976
|
-
});
|
971
|
+
SalesforceApiService.prototype.query = function (searchRequest, objectName, options) {
|
972
|
+
return this.httpService.api(Object.assign({ method: 'post', body: Object.assign(Object.assign({}, searchRequest), { count: searchRequest.count || 100 }), url: this.SERVICE_URL + "/query/" + objectName }, options));
|
977
973
|
};
|
978
|
-
SalesforceApiService.prototype.queryObjects = function (search) {
|
974
|
+
SalesforceApiService.prototype.queryObjects = function (search, options) {
|
979
975
|
var params = new i5.HttpParams();
|
980
976
|
if (search) {
|
981
977
|
params.append('search', search);
|
982
978
|
}
|
983
|
-
return this.httpService.api({
|
984
|
-
url: this.SERVICE_URL + "/query",
|
985
|
-
params: params,
|
986
|
-
});
|
979
|
+
return this.httpService.api(Object.assign({ url: this.SERVICE_URL + "/query", params: params }, options));
|
987
980
|
};
|
988
|
-
SalesforceApiService.prototype.describe = function (objectName, fieldName) {
|
981
|
+
SalesforceApiService.prototype.describe = function (objectName, fieldName, options) {
|
989
982
|
var methodUrl = this.SERVICE_URL + "/describe/" + objectName + "/fields" + (fieldName ? "/" + fieldName : '');
|
990
|
-
return this.httpService.api({ url: methodUrl });
|
983
|
+
return this.httpService.api(Object.assign({ url: methodUrl }, options));
|
991
984
|
};
|
992
|
-
SalesforceApiService.prototype.describe2 = function (objectName, fields) {
|
985
|
+
SalesforceApiService.prototype.describe2 = function (objectName, fields, options) {
|
993
986
|
var methodUrl = this.SERVICE_URL + "/describe/" + objectName + "/fields";
|
994
|
-
return this.httpService.api({ method: 'post', url: methodUrl, body: fields });
|
987
|
+
return this.httpService.api(Object.assign({ method: 'post', url: methodUrl, body: fields }, options));
|
995
988
|
};
|
996
|
-
SalesforceApiService.prototype.apexGetRequest = function (path, params) {
|
997
|
-
return this.httpService.api({ url: this.SERVICE_URL + "/apex" + path, params: params });
|
989
|
+
SalesforceApiService.prototype.apexGetRequest = function (path, params, options) {
|
990
|
+
return this.httpService.api(Object.assign({ url: this.SERVICE_URL + "/apex" + path, params: params }, options));
|
998
991
|
};
|
999
|
-
SalesforceApiService.prototype.apexPostRequest = function (path, body) {
|
1000
|
-
return this.httpService.api({
|
1001
|
-
method: 'post',
|
1002
|
-
body: body,
|
1003
|
-
url: this.SERVICE_URL + "/apex" + path,
|
1004
|
-
});
|
992
|
+
SalesforceApiService.prototype.apexPostRequest = function (path, body, options) {
|
993
|
+
return this.httpService.api(Object.assign({ method: 'post', body: body, url: this.SERVICE_URL + "/apex" + path }, options));
|
1005
994
|
};
|
1006
995
|
return SalesforceApiService;
|
1007
996
|
}());
|
@@ -1032,19 +1021,11 @@
|
|
1032
1021
|
errorHandler: errorHandler,
|
1033
1022
|
});
|
1034
1023
|
};
|
1035
|
-
QuoteApiService.prototype.upsertQuote = function (request) {
|
1036
|
-
return this.httpService.api({
|
1037
|
-
method: 'post',
|
1038
|
-
url: "" + this.SERVICE_URL,
|
1039
|
-
body: request,
|
1040
|
-
});
|
1024
|
+
QuoteApiService.prototype.upsertQuote = function (request, options) {
|
1025
|
+
return this.httpService.api(Object.assign({ method: 'post', url: "" + this.SERVICE_URL, body: request }, options));
|
1041
1026
|
};
|
1042
|
-
QuoteApiService.prototype.submitQuote = function (request) {
|
1043
|
-
return this.httpService.api({
|
1044
|
-
method: 'post',
|
1045
|
-
url: this.SERVICE_URL + "/submit",
|
1046
|
-
body: request,
|
1047
|
-
});
|
1027
|
+
QuoteApiService.prototype.submitQuote = function (request, options) {
|
1028
|
+
return this.httpService.api(Object.assign({ method: 'post', url: this.SERVICE_URL + "/submit", body: request }, options));
|
1048
1029
|
};
|
1049
1030
|
QuoteApiService.prototype.attachDocument = function (id, documentName, data) {
|
1050
1031
|
var formData = new FormData();
|