TimeTrex/interface/html5/dist/employees-remittance_destination_account-RemittanceDestinationAccountViewController.bundle.js

1 line
86 KiB
JavaScript
Raw Permalink Normal View History

2022-12-13 07:10:06 +01:00
"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["employees-remittance_destination_account-RemittanceDestinationAccountViewController"],{4333:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"RemittanceDestinationAccountViewController\": () => (/* binding */ RemittanceDestinationAccountViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass RemittanceDestinationAccountViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#remittance_destination_account_view_container',\n\n\t\t\tstatus_array: null,\n\t\t\ttype_array: null,\n\t\t\tpriority_array: [],\n\t\t\tamount_type_array: null,\n\t\t\tach_transaction_type_array: null,\n\t\t\tach_transaction_type_data: null,\n\t\t\tremittance_source_account_array: null,\n\t\t\tcompany_api: null,\n\t\t\tuser_default_api: null,\n\t\t\tuser_api: null,\n\t\t\tlegal_entity_id: false,\n\t\t\tremittance_source_account_api: null,\n\t\t\tsub_document_view_controller: null,\n\t\t\tdocument_object_type_id: null,\n\t\t\tis_first_load: true,\n\t\t\tis_subview: false\n\t\t} );\n\n\t\tsuper( options );\n\t}\n\n\tinit( options ) {\n\t\tthis.type_array = [];\n\t\t//this._super('initialize', options );\n\t\tthis.edit_view_tpl = 'RemittanceDestinationAccountEditView.html';\n\t\tthis.permission_id = 'remittance_destination_account';\n\t\tthis.viewId = 'RemittanceDestinationAccount';\n\t\tthis.script_name = 'RemittanceDestinationAccountView';\n\t\tthis.table_name_key = 'remittance_destination_account';\n\t\tthis.context_menu_name = $.i18n._( 'Pay Methods' );\n\t\tthis.navigation_label = $.i18n._( 'Pay Methods' );\n\t\tthis.document_object_type_id = 320;\n\t\tthis.api = TTAPI.APIRemittanceDestinationAccount;\n\t\tthis.company_api = TTAPI.APICompany;\n\t\tthis.user_api = TTAPI.APIUser;\n\t\tthis.user_default_api = TTAPI.APIUserDefault;\n\t\tthis.remittance_source_account_api = TTAPI.APIRemittanceSourceAccount;\n\n\t\tthis.render();\n\t\tif ( this.sub_view_mode ) {\n\t\t\tthis.buildContextMenu( true );\n\t\t} else {\n\t\t\tthis.buildContextMenu();\n\t\t}\n\n\t\t//call init data in parent view\n\t\tif ( !this.sub_view_mode ) {\n\t\t\tthis.initData();\n\t\t}\n\t}\n\n\tinitOptions() {\n\t\tvar $this = this;\n\t\tthis.initDropDownOption( 'status' );\n\t\tthis.initDropDownOption( 'amount_type' );\n\t\tthis.api.getOptions( 'priority', {\n\t\t\tonResult: function( res ) {\n\t\t\t\t$this.priority_array = res.getResult();\n\t\t\t}\n\t\t} );\n\t\tthis.api.getOptions( 'ach_transaction_type', {\n\t\t\tonResult: function( res ) {\n\t\t\t\tvar result = res.getResult();\n\t\t\t\t$this.ach_transaction_type_data = result;\n\t\t\t\t$this.ach_transaction_type_array = Global.buildRecordArray( result );\n\t\t\t}\n\t\t} );\n\n\t\tthis.remittance_source_account_api.getOptions( 'type', {\n\t\t\tonResult: function( result ) {\n\t\t\t\tresult = result.getResult();\n\t\t\t\t//Prevent exception when in subgrid mode: \"TypeError: $this.basic_search_field_ui_dic.type_id is undefined\"\n\t\t\t\tif ( $this.basic_search_field_ui_dic && $this.basic_search_field_ui_dic['type_id'] ) {\n\t\t\t\t\t$this.basic_search_field_ui_dic['type_id'].setSourceData( Global.buildRecordArray( result ) );\n\t\t\t\t}\n\t\t\t\tif ( $this.adv_search_field_ui_dic && $this.adv_search_field_ui_dic['type_id'] ) {\n\t\t\t\t\t$this.adv_search_field_ui_dic['type_id'].setSourceData( Global.buildRecordArray( result ) );\n\t\t\t\t}\n\t\t\t}\n\t\t} );\n\t}\n\n\tgetDefaultDisplayColumns( callBack ) {\n\n\t\tvar $this = this;\n\t\tthis.api.getOptions( 'default_display_columns', {\n\t\t\tonResult: function( columns_result ) {\n\n\t\t\t\tvar columns_result_data = columns_result.getResult();\n\t\t\t\t$this.default_display_columns = [];\n\n\t\t\t\tfor ( var n in columns_result_data ) {\n\t\t\t\t\tif ( $this.is_subview