(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["app-pages-relatorios-log-automacao-log-automacao-module"],{

/***/ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.html":
/*!*******************************************************************************************************************************************!*\
  !*** ./node_modules/raw-loader/dist/cjs.js!./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.html ***!
  \*******************************************************************************************************************************************/
/*! exports provided: default */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony default export */ __webpack_exports__["default"] = ("<app-menu-command-bar [sisFormularioId]=\"constantes.sisFormularioId\" [botoesComando]=\"constantes.listaForm\">\n</app-menu-command-bar>\n\n<div class=\"row\">\n    <div class=\"col-lg-12\">\n        <div class=\"section-comand-bar\">\n            <div class=\"\">\n                <app-form-legenda></app-form-legenda>\n                <div class=\"card-body widget-body\">\n                    <form class=\"form\" #logAutomacao=\"ngForm\" (ngSubmit)=\"onSubmit(logAutomacao)\">\n                        <app-validacoes></app-validacoes>\n                        <div class=\"row\">\n                            <div class=\"col-3\">\n                                <div class=\"form-group form-group-sm\">\n                                    <label for=\"ccd\" class=\"required\">{{\"labels.ccd\" | translate}}</label>\n                                    <input id=\"ccd\" name=\"ccd\" [(ngModel)]=\"data.automacaoId\"\n                                        class=\"form-control form-control-sm\" type=\"text\" required\n                                        [disabled]=\"funcoesService.isDetail(actionForm)\" />\n                                </div>\n                            </div>\n                        </div>\n                        <div class=\"clearfix\">&nbsp;</div>\n                        <div class=\"form-group\">\n                            <button class=\"btn btn-success mr-2\" type=\"submit\">\n                                {{ 'buttons.gerarRelatorio' | translate }}\n                            </button>\n                            <button class=\"btn btn-success mr-2\" (click)=\"export(logAutomacao)\" type=\"button\">{{\n                                'buttons.exportarExcel' | translate }}\n                            </button>\n                            <button class=\"btn btn-success mr-2\" (click)=\"sendMail(logAutomacao)\" type=\"button\">{{\n                                'buttons.enviarEmail' | translate }}\n                            </button>\n                        </div>\n                    </form>\n                </div>\n            </div>\n        </div>\n    </div>\n</div>\n<app-liberar-acesso-supervisor></app-liberar-acesso-supervisor>\n<app-permissoes-rotina [constantes]=\"constantes\"></app-permissoes-rotina>\n<app-email [reportId]=\"constantes.reportId\" [titulo]=\"constantes.reportTitulo.titulo\"\n    [subTitulo]=\"constantes.reportTitulo.subTitulo\" [data]=\"constantes.paramRelatorio\"></app-email>");

/***/ }),

/***/ "./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.ts":
/*!***************************************************************************************************!*\
  !*** ./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.ts ***!
  \***************************************************************************************************/
/*! exports provided: LogAutomacaoFormComponent */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LogAutomacaoFormComponent", function() { return LogAutomacaoFormComponent; });
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/fesm5/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/fesm5/router.js");
/* harmony import */ var _shared_services_message_message_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../shared/services/message/message.service */ "./src/app/shared/services/message/message.service.ts");
/* harmony import */ var _shared_services_funcoes_funcoes_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../shared/services/funcoes/funcoes.service */ "./src/app/shared/services/funcoes/funcoes.service.ts");
/* harmony import */ var _shared_services_event_emitter_event_emitter_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../shared/services/event-emitter/event-emitter.service */ "./src/app/shared/services/event-emitter/event-emitter.service.ts");
/* harmony import */ var _shared_components_corporate_base_base_permissoes__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../shared/components/corporate/base/base.permissoes */ "./src/app/shared/components/corporate/base/base.permissoes.ts");
/* harmony import */ var _log_automacao_model__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../log-automacao.model */ "./src/app/pages/relatorios/log-automacao/log-automacao.model.ts");
/* harmony import */ var _log_automacao_constants__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../log-automacao.constants */ "./src/app/pages/relatorios/log-automacao/log-automacao.constants.ts");
/* harmony import */ var app_pages_login_login_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! app/pages/login/login.service */ "./src/app/pages/login/login.service.ts");
/* harmony import */ var app_shared_services_funcoes_permissoes_utils_permissoes_utils_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! app/shared/services/funcoes/permissoes-utils/permissoes-utils.service */ "./src/app/shared/services/funcoes/permissoes-utils/permissoes-utils.service.ts");
/* harmony import */ var _shared_services_funcoes_excel_excel_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../../../shared/services/funcoes/excel/excel.service */ "./src/app/shared/services/funcoes/excel/excel.service.ts");
/* harmony import */ var _shared_components_report_report_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../../../shared/components/report/report.service */ "./src/app/shared/components/report/report.service.ts");
var __extends = (undefined && undefined.__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 (b.hasOwnProperty(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 __());
    };
})();
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (undefined && undefined.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
var __importDefault = (undefined && undefined.__importDefault) || function (mod) {
  return (mod && mod.__esModule) ? mod : { "default": mod };
};












var LogAutomacaoFormComponent = /** @class */ (function (_super) {
    __extends(LogAutomacaoFormComponent, _super);
    function LogAutomacaoFormComponent(router, messageService, activatedRoute, permissoesUtils, funcoesService, loginService, excelService, reportService) {
        var _this = _super.call(this, new _log_automacao_constants__WEBPACK_IMPORTED_MODULE_7__["LogAutomacaoConstants"](), funcoesService) || this;
        _this.router = router;
        _this.messageService = messageService;
        _this.activatedRoute = activatedRoute;
        _this.permissoesUtils = permissoesUtils;
        _this.funcoesService = funcoesService;
        _this.loginService = loginService;
        _this.excelService = excelService;
        _this.reportService = reportService;
        _this.data = new _log_automacao_model__WEBPACK_IMPORTED_MODULE_6__["LogAutomacao"]();
        _this.mensagens = [];
        _this.constantes = new _log_automacao_constants__WEBPACK_IMPORTED_MODULE_7__["LogAutomacaoConstants"]();
        _this.target = _this.funcoesService.getTargetLocation();
        _this.export = function (form) {
            if (!_this.printParams(form)) {
                return;
            }
            _this.reportService.export(_this.constantes.sisFormularioId, _this.constantes.paramRelatorio).subscribe(function (resp) {
                var headerDictionary = {
                    "regControle": "ccd",
                    "item": "item",
                    "evento": "evento",
                    "data": "data",
                    "descrStatus": "descricao"
                };
                var options = {
                    headerJsonKeys: true,
                    headerDictionary: headerDictionary
                };
                _this.excelService.exportAsExcelFile(resp, _this.messageService.getTranslates("titles", "logAutomacao"), options);
            });
        };
        router.events.subscribe(function (event) {
            var params = _this.funcoesService.formParams.getParams(router, event);
            if (params) {
                _this.actionForm = params.action;
            }
        });
        return _this;
    }
    LogAutomacaoFormComponent.prototype.ngOnInit = function () {
        var _this = this;
        this.permissoesUtils.verificaRotina(this.constantes.sisFormularioId, 1, function () { }, function () { return _this.permissoesUtils.back(); }, true);
    };
    LogAutomacaoFormComponent.prototype.printParams = function (form) {
        _shared_services_event_emitter_event_emitter_service__WEBPACK_IMPORTED_MODULE_4__["EventEmitterService"].get("formError").emit(form);
        if (form.invalid) {
            return false;
        }
        this.constantes.reportTitulo.subTitulo = "Número do CCD: " + this.data.automacaoId.toString();
        this.constantes.paramRelatorio = {
            automacaoId: this.data.automacaoId === undefined ? "0" : this.data.automacaoId,
            filialId: this.loginService.getLogin().filialId
        };
        return true;
    };
    LogAutomacaoFormComponent.prototype.onSubmit = function (form) {
        if (!this.printParams(form)) {
            return;
        }
        this.print();
    };
    LogAutomacaoFormComponent.prototype.permissoes = function () {
        var _this = this;
        this.permissoesUtils.verificaRotina(this.constantes.sisFormularioId, 2, function () {
            _super.prototype.permissoes.call(_this, _this.constantes);
        });
    };
    LogAutomacaoFormComponent.prototype.onCancelar = function () {
        this.data = new _log_automacao_model__WEBPACK_IMPORTED_MODULE_6__["LogAutomacao"]();
    };
    LogAutomacaoFormComponent.prototype.sendMail = function (form) {
        if (!this.printParams(form)) {
            return;
        }
        _super.prototype.sendMail.call(this, this.constantes);
    };
    LogAutomacaoFormComponent.ctorParameters = function () { return [
        { type: _angular_router__WEBPACK_IMPORTED_MODULE_1__["Router"] },
        { type: _shared_services_message_message_service__WEBPACK_IMPORTED_MODULE_2__["MessageService"] },
        { type: _angular_router__WEBPACK_IMPORTED_MODULE_1__["ActivatedRoute"] },
        { type: app_shared_services_funcoes_permissoes_utils_permissoes_utils_service__WEBPACK_IMPORTED_MODULE_9__["PermissoesUtilsService"] },
        { type: _shared_services_funcoes_funcoes_service__WEBPACK_IMPORTED_MODULE_3__["FuncoesService"] },
        { type: app_pages_login_login_service__WEBPACK_IMPORTED_MODULE_8__["LoginService"] },
        { type: _shared_services_funcoes_excel_excel_service__WEBPACK_IMPORTED_MODULE_10__["ExcelService"] },
        { type: _shared_components_report_report_service__WEBPACK_IMPORTED_MODULE_11__["ReportService"] }
    ]; };
    LogAutomacaoFormComponent = __decorate([
        Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["Component"])({
            selector: "app-log-automacao-form",
            template: __importDefault(__webpack_require__(/*! raw-loader!./log-automacao-form.component.html */ "./node_modules/raw-loader/dist/cjs.js!./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.html")).default,
            encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None
        }),
        __metadata("design:paramtypes", [_angular_router__WEBPACK_IMPORTED_MODULE_1__["Router"],
            _shared_services_message_message_service__WEBPACK_IMPORTED_MODULE_2__["MessageService"],
            _angular_router__WEBPACK_IMPORTED_MODULE_1__["ActivatedRoute"],
            app_shared_services_funcoes_permissoes_utils_permissoes_utils_service__WEBPACK_IMPORTED_MODULE_9__["PermissoesUtilsService"],
            _shared_services_funcoes_funcoes_service__WEBPACK_IMPORTED_MODULE_3__["FuncoesService"],
            app_pages_login_login_service__WEBPACK_IMPORTED_MODULE_8__["LoginService"],
            _shared_services_funcoes_excel_excel_service__WEBPACK_IMPORTED_MODULE_10__["ExcelService"],
            _shared_components_report_report_service__WEBPACK_IMPORTED_MODULE_11__["ReportService"]])
    ], LogAutomacaoFormComponent);
    return LogAutomacaoFormComponent;
}(_shared_components_corporate_base_base_permissoes__WEBPACK_IMPORTED_MODULE_5__["BasePermissoes"]));



/***/ }),

/***/ "./src/app/pages/relatorios/log-automacao/log-automacao.constants.ts":
/*!***************************************************************************!*\
  !*** ./src/app/pages/relatorios/log-automacao/log-automacao.constants.ts ***!
  \***************************************************************************/
/*! exports provided: LogAutomacaoConstants */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LogAutomacaoConstants", function() { return LogAutomacaoConstants; });
var __importDefault = (undefined && undefined.__importDefault) || function (mod) {
  return (mod && mod.__esModule) ? mod : { "default": mod };
};
var LogAutomacaoConstants = /** @class */ (function () {
    function LogAutomacaoConstants() {
        this.sisFormularioId = 65474;
        this.permissoes = [
            { sisFormularioId: this.sisFormularioId, libRotina: 1, acao: "labels.consulta" },
            { sisFormularioId: this.sisFormularioId, libRotina: 2, acao: "labels.permissoes" }
        ];
        this.sisSistemaId = "REL";
        this.nomeForm = "titles.logAutomacao";
        this.reportId = "REL0177";
        this.reportTitulo = { "titulo": "Relatório de Log de Automação", "subTitulo": "" };
        this.listaForm = [
            { title: 'Permissao', action: 'permissoes', icon: "icon-unlock", exibeButton: true, eximeMenu: true, menuName: 'Arquivo' }
        ];
    }
    return LogAutomacaoConstants;
}());



/***/ }),

/***/ "./src/app/pages/relatorios/log-automacao/log-automacao.model.ts":
/*!***********************************************************************!*\
  !*** ./src/app/pages/relatorios/log-automacao/log-automacao.model.ts ***!
  \***********************************************************************/
/*! exports provided: LogAutomacao */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LogAutomacao", function() { return LogAutomacao; });
var __importDefault = (undefined && undefined.__importDefault) || function (mod) {
  return (mod && mod.__esModule) ? mod : { "default": mod };
};
var LogAutomacao = /** @class */ (function () {
    function LogAutomacao() {
        this.automacaoId = "";
    }
    return LogAutomacao;
}());



/***/ }),

/***/ "./src/app/pages/relatorios/log-automacao/log-automacao.module.ts":
/*!************************************************************************!*\
  !*** ./src/app/pages/relatorios/log-automacao/log-automacao.module.ts ***!
  \************************************************************************/
/*! exports provided: LogAutomacaoModule */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LogAutomacaoModule", function() { return LogAutomacaoModule; });
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/fesm5/core.js");
/* harmony import */ var _shared_shared_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../shared/shared.module */ "./src/app/shared/shared.module.ts");
/* harmony import */ var _log_automacao_form_log_automacao_form_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./log-automacao-form/log-automacao-form.component */ "./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.ts");
/* harmony import */ var _log_automacao_routing_module__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./log-automacao.routing.module */ "./src/app/pages/relatorios/log-automacao/log-automacao.routing.module.ts");
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __importDefault = (undefined && undefined.__importDefault) || function (mod) {
  return (mod && mod.__esModule) ? mod : { "default": mod };
};




var LogAutomacaoModule = /** @class */ (function () {
    function LogAutomacaoModule() {
    }
    LogAutomacaoModule = __decorate([
        Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({
            imports: [_shared_shared_module__WEBPACK_IMPORTED_MODULE_1__["SharedModule"], _log_automacao_routing_module__WEBPACK_IMPORTED_MODULE_3__["LogAutomacaoRoutingModule"]],
            declarations: [_log_automacao_form_log_automacao_form_component__WEBPACK_IMPORTED_MODULE_2__["LogAutomacaoFormComponent"]]
        })
    ], LogAutomacaoModule);
    return LogAutomacaoModule;
}());



/***/ }),

/***/ "./src/app/pages/relatorios/log-automacao/log-automacao.routing.module.ts":
/*!********************************************************************************!*\
  !*** ./src/app/pages/relatorios/log-automacao/log-automacao.routing.module.ts ***!
  \********************************************************************************/
/*! exports provided: LogAutomacaoRoutingModule */
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "LogAutomacaoRoutingModule", function() { return LogAutomacaoRoutingModule; });
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "./node_modules/@angular/core/fesm5/core.js");
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/router */ "./node_modules/@angular/router/fesm5/router.js");
/* harmony import */ var _config_enumerables__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../config/enumerables */ "./src/app/config/enumerables.ts");
/* harmony import */ var _log_automacao_form_log_automacao_form_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./log-automacao-form/log-automacao-form.component */ "./src/app/pages/relatorios/log-automacao/log-automacao-form/log-automacao-form.component.ts");
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __importDefault = (undefined && undefined.__importDefault) || function (mod) {
  return (mod && mod.__esModule) ? mod : { "default": mod };
};




var MRoutes = [
    {
        path: "",
        component: _log_automacao_form_log_automacao_form_component__WEBPACK_IMPORTED_MODULE_3__["LogAutomacaoFormComponent"],
        data: { breadcrumb: "logAutomacao", formParams: { action: _config_enumerables__WEBPACK_IMPORTED_MODULE_2__["ActionForm"].index } }
    },
];
var LogAutomacaoRoutingModule = /** @class */ (function () {
    function LogAutomacaoRoutingModule() {
    }
    LogAutomacaoRoutingModule = __decorate([
        Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgModule"])({
            imports: [_angular_router__WEBPACK_IMPORTED_MODULE_1__["RouterModule"].forChild(MRoutes)],
            exports: [_angular_router__WEBPACK_IMPORTED_MODULE_1__["RouterModule"]],
        })
    ], LogAutomacaoRoutingModule);
    return LogAutomacaoRoutingModule;
}());



/***/ })

}]);
//# sourceMappingURL=app-pages-relatorios-log-automacao-log-automacao-module.js.map