UNPKG

bitfront-library

Version:

Angular CLI project with components and classes used by other Angular projects of the BIT foundation.

65 lines 3.5 kB
"use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); Object.defineProperty(exports, "__esModule", { value: true }); exports.DeveloperService = void 0; var core_1 = require("@angular/core"); var http_utils_service_1 = require("../../../shared/service/http-utils.service"); var message_service_1 = require("../../../shared/service/message.service"); var base_service_1 = require("../../../base/shared/base.service"); var i0 = require("@angular/core"); var i1 = require("../../../shared/service/message.service"); var i2 = require("../../../shared/service/http-utils.service"); var DeveloperService = /** @class */ (function (_super) { __extends(DeveloperService, _super); function DeveloperService(messageService, http) { var _this = _super.call(this, messageService, http) || this; _this.messageService = messageService; _this.http = http; _this.baseUrl = "desarrollo"; _this.hqlUrl = _this.baseUrl + "/hql"; _this.sqlUrl = _this.baseUrl + "/sql"; _this.hqlExecuteUrl = _this.baseUrl + "/hql/execute"; _this.sqlExecuteUrl = _this.baseUrl + "/sql/execute"; _this.hqlSimulateUrl = _this.baseUrl + "/hql/simulate"; // TODO: no implementado en servidor _this.sqlSimulateUrl = _this.baseUrl + "/sql/simulate"; _this.countAllExceptionsByFilterUrl = _this.baseUrl + "/exceptions/count"; _this.getAllExceptionsByFilterUrl = _this.baseUrl + "/exceptions/filter"; return _this; } DeveloperService.prototype.sendSHQL = function (esHQL, hqlRequest, execute, simulate) { var url; if (esHQL) { url = execute ? this.hqlExecuteUrl : simulate ? this.hqlSimulateUrl : this.hqlUrl; } else { url = execute ? this.sqlExecuteUrl : simulate ? this.sqlSimulateUrl : this.sqlUrl; } return this.http.getHttpPost(url, hqlRequest); }; DeveloperService.prototype.getAllByFilter = function (logFilter) { return this.http.getHttpPost(this.getAllExceptionsByFilterUrl, logFilter); }; DeveloperService.prototype.countAllByFilter = function (logFilter) { return this.http.getHttpPost(this.countAllExceptionsByFilterUrl, logFilter); }; DeveloperService.ɵfac = function DeveloperService_Factory(t) { return new (t || DeveloperService)(i0.ɵɵinject(i1.MessageService), i0.ɵɵinject(i2.HttpUtilsService)); }; DeveloperService.ɵprov = i0.ɵɵdefineInjectable({ token: DeveloperService, factory: DeveloperService.ɵfac }); return DeveloperService; }(base_service_1.BaseCRUDService)); exports.DeveloperService = DeveloperService; (function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(DeveloperService, [{ type: core_1.Injectable }], function () { return [{ type: i1.MessageService }, { type: i2.HttpUtilsService }]; }, null); })(); //# sourceMappingURL=developer.service.js.map