1 line
8.8 KiB
JavaScript
1 line
8.8 KiB
JavaScript
"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["reports-pay_stub_summary-PayStubSummaryReportViewController"],{4421:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PayStubSummaryReportViewController\": () => (/* binding */ PayStubSummaryReportViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass PayStubSummaryReportViewController extends ReportBaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\n\t\t} );\n\n\t\tsuper( options );\n\t}\n\n\tinitReport( options ) {\n\t\tthis.script_name = 'PayStubSummaryReport';\n\t\tthis.viewId = 'PayStubSummaryReport';\n\t\tthis.context_menu_name = $.i18n._( 'Pay Stub Summary' );\n\t\tthis.navigation_label = $.i18n._( 'Saved Report' );\n\t\tthis.view_file = 'PayStubSummaryReportView.html';\n\t\tthis.api = TTAPI.APIPayStubSummaryReport;\n\t}\n\n\tonReportMenuClick( id ) {\n\t\tthis.processTransactions( id );\n\t}\n\n\tgetCustomContextMenuModel() {\n\t\tvar context_menu_model = {\n\t\t\tgroups: {\n\t\t\t\tpay_stub: {\n\t\t\t\t\tlabel: $.i18n._( 'Pay Stub' ),\n\t\t\t\t\tid: this.script_name + 'PayStub'\n\t\t\t\t},\n\t\t\t\texport: {\n\t\t\t\t\tlabel: $.i18n._( 'Export' ),\n\t\t\t\t\tid: this.viewId + 'Export'\n\t\t\t\t}\n\t\t\t},\n\t\t\texclude: [],\n\t\t\tinclude: [\n\t\t\t\t{\n\t\t\t\t\tlabel: '', //Empty label. vue_icon is displayed instead of text.\n\t\t\t\t\tid: 'other_header',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'pay_stub',\n\t\t\t\t\taction_group_header: true,\n\t\t\t\t\tvue_icon: 'tticon tticon-more_vert_black_24dp',\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Employee Pay Stubs' ),\n\t\t\t\t\tid: 'employee_pay_stubs',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'pay_stub'\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Employer Pay Stubs' ),\n\t\t\t\t\tid: 'employer_pay_stubs',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'pay_stub'\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Process Transactions' ),\n\t\t\t\t\tid: 'direct_deposit',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'pay_stub'\n\t\t\t\t}\n\t\t\t]\n\t\t};\n\n\t\treturn context_menu_model;\n\t}\n\n\t// Overriding empty ReportBaseViewController.processFilterField() called from base.openEditView to provide view specific logic.\n\tprocessFilterField() {\n\t\tfor ( var i = 0; i < this.setup_fields_array.length; i++ ) {\n\t\t\tvar item = this.setup_fields_array[i];\n\t\t\tif ( item.value === 'status_id' ) {\n\t\t\t\titem.value = 'filter';\n\t\t\t}\n\t\t}\n\t}\n\n\tonFormItemChangeProcessFilterField( target, key ) {\n\t\tvar filter = target.getValue();\n\t\tthis.visible_report_values[key] = { status_id: filter };\n\t}\n\n\tsetFilterValue( widget, value ) {\n\t\twidget.setValue( value.status_id );\n\t}\n\n\tonCustomContextClick( id ) {\n\t\tswitch ( id ) {\n\t\t\tcase 'employee_pay_stubs': //All report view\n\t\t\t\tthis.onViewClick( 'pdf_employee_pay_stub' );\n\t\t\t\tbreak;\n\t\t\tcase 'employer_pay_stubs': //All report view\n\t\t\t\tthis.onViewClick( 'pdf_employer_pay_stub' );\n\t\t\t\tbreak;\n\t\t\tcase 'direct_deposit':\n\t\t\t\tif ( !this.validate( true ) ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tIndexViewController.openWizardController( 'ProcessTransactionsWizardController', { filter_data: this.visible_report_values } );\n\t\t\t\tbreak;\n\t\t}\n\t}\n}//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNDQyMS5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7QUFBTztBQUNQLDJCQUEyQjtBQUMzQixFQUFFLENBQUM7O0FBRUgsSUFBSTs7QUFFSjtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBLDJCQUEyQixDQUFDO0FBQzVCLDBCQUEwQixDQUFDO0FBQzNCO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQSxZQUFZLENBQUM7QUFDYjtBQUNBLEtBQUs7QUFDTDtBQUNBLFlBQVksQ0FBQztBQUNiO0FBQ0E7QUFDQSxJQUFJO0FBQ0o7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMO0FBQ0EsWUFBWSxDQUFDO0FBQ2I7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMO0FBQ0EsWUFBWSxDQUFDO0FBQ2I7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMO0FBQ0EsWUFBWSxDQUFDO0FBQ2I7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBLG1CQUFtQixvQ0FBb0M7QUFDdkQ7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQSxzQ0FBc0M7QUFDdEM7O0FBRUE7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQSx1RkF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