"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["payperiod-PayPeriodScheduleViewController"],{6415:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PayPeriodScheduleViewController\": () => (/* binding */ PayPeriodScheduleViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass PayPeriodScheduleViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#pay_period_schedule_view_container', //Must set el here and can only set string, so events can work\n\n\t\t\tuser_preference_api: null,\n\t\t\ttype_array: null,\n\t\t\tpay_period_starts_on_array: null,\n\t\t\tstart_week_day_array: null,\n\t\t\ttransaction_date_array: null,\n\t\t\ttransaction_date_business_day_array: null,\n\t\t\ttime_zone_array: null,\n\t\t\tshift_assigned_day_array: null,\n\t\t\ttimesheet_verify_type_array: null,\n\t\t\tsub_pay_periods_view_controller: null\n\t\t} );\n\n\t\tsuper( options );\n\t}\n\n\tinit( options ) {\n\n\t\t//this._super('initialize', options );\n\t\tthis.edit_view_tpl = 'PayPeriodScheduleEditView.html';\n\t\tthis.permission_id = 'pay_period_schedule';\n\t\tthis.viewId = 'PayPeriodSchedule';\n\t\tthis.script_name = 'PayPeriodScheduleView';\n\t\tthis.table_name_key = 'pay_period_schedule';\n\t\tthis.context_menu_name = $.i18n._( 'Pay Period Schedule' );\n\t\tthis.navigation_label = $.i18n._( 'Pay Period Schedule' );\n\t\tthis.api = TTAPI.APIPayPeriodSchedule;\n\t\tthis.user_preference_api = TTAPI.APIUserPreference;\n\n\t\tthis.render();\n\t\tthis.buildContextMenu();\n\t\tthis.initData();\n\t}\n\n\tgetCustomContextMenuModel() {\n\t\tvar context_menu_model = {\n\t\t\texclude: ['copy', 'mass_edit'],\n\t\t\tinclude: []\n\t\t};\n\n\t\treturn context_menu_model;\n\t}\n\n\topenEditView( id ) {\n\t\tGlobal.setUINotready();\n\t\tTTPromise.add( 'init', 'init' );\n\t\tTTPromise.wait();\n\n\t\tvar $this = this;\n\n\t\tif ( $this.edit_only_mode ) {\n\n\t\t\t$this.initOptions( function( result ) {\n\n\t\t\t\tif ( !$this.edit_view ) {\n\t\t\t\t\t$this.initEditViewUI( $this.viewId, $this.edit_view_tpl );\n\t\t\t\t}\n\n\t\t\t\t$this.getPayPeriodScheduleData( id, function( result ) {\n\t\t\t\t\t// Waiting for the TTAPI.API returns data to set the current edit record.\n\t\t\t\t\t$this.current_edit_record = result;\n\n\t\t\t\t\t$this.initEditView();\n\n\t\t\t\t} );\n\n\t\t\t} );\n\n\t\t} else {\n\t\t\tif ( !this.edit_view ) {\n\t\t\t\tthis.initEditViewUI( $this.viewId, $this.edit_view_tpl );\n\t\t\t}\n\n\t\t}\n\t}\n\n\tgetPayPeriodScheduleData( id, callBack ) {\n\t\tvar filter = {};\n\t\tfilter.filter_data = {};\n\t\tfilter.filter_data.id = [id];\n\n\t\tthis.api['get' + this.api.key_name]( filter, {\n\t\t\tonResult: function( result ) {\n\t\t\t\tvar result_data = result.getResult();\n\n\t\t\t\tif ( !result_data ) {\n\t\t\t\t\tresult_data = [];\n\t\t\t\t}\n\t\t\t\tresult_data = result_data[0];\n\n\t\t\t\tcallBack( result_data );\n\n\t\t\t}\n\t\t} );\n\t}\n\n\tinitOptions( callBack ) {\n\t\tvar $this = this;\n\n\t\tvar options = [\n\t\t\t{ option_name: 'type' },\n\t\t\t{ option_name: 'transaction_date' },\n\t\t\t{ option_name: 'transaction_date_business_day' },\n\t\t\t{ option_name: 'shift_assigned_day' },\n\t\t\t{ option_name: 'time_zone', field_name: '', api: this.user_preference_api },\n\t\t\t{ option_name: 'timesheet_verify_type' },\n\t\t\t{ option_name: 'start_week_day' }\n\n\t\t];\n\n\t\tthis.initDropDownOptions( options, function( result ) {\n\t\t\t$this.transaction_date_array = Global.addLastItemToArray( $this.transaction_date_array, -1, $.i18n._( '- Last Day Of Month -' ) );\n\n\t\t\t$this.user_preference_api.getOptions( 'start_week_day', {\n\t\t\t\tonResult: function( res ) {\n\t\t\t\t\tvar result = res.getResult();\n\t\t\t\t\t$this.pay_period_starts_on_array = Global.buildRecordArray( result );\n\n\t\t\t\t\tif ( callBack ) {\n\t\t\t\t\t\tcallBack( result ); // First to initialize drop down options, and then to initialize edit view UI.\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} );\n\n\t\t} );\n\t}\n\n\tinitSubPayPeriodsView() {\n\t\tvar $this = this;\n\n\t\tif ( !this.current_edit_record.id ) {\n\t\t\tTTPromise.resolve( 'BaseViewController', 'onTabShow' ); //Since search() isn't called in this case, and we just display the \"Please Save This Record ...\" message, resolve the promise.\n\t\t\treturn;\n\t\t}\n\n\t\tif ( this.sub_pay_periods_view_controller ) {\n\t\t\tthis.sub_pay_periods_view_controller.buildContextMenu( true );\n\t\t\tthis.sub_pay_periods_view_controller.setDefaultMenu();\n\t\t\t$this.sub_pay_periods_view_controller.parent_value = $this.current_edit_record.id;\n\t\t\t$this.sub_pay_periods_view_controller.parent_edit_record = $this.current_edit_record;\n\t\t\t$this.sub_pay_periods_view_controller.initData(); //Init data in this parent view\n\t\t\treturn;\n\t\t}\n\n\t\tGlobal.loadScript( 'views/payroll/pay_periods/PayPeriodsViewController.js', function() {\n\n\t\t\tvar tab_pay_period_schedule = $this.edit_view_tab.find( '#tab_pay_period' );\n\n\t\t\tvar firstColumn = tab_pay_period_schedule.find( '.first-column-sub-view' );\n\n\t\t\tGlobal.trackView( 'Sub' + 'PayPeriods' + 'View' );\n\t\t\tPayPeriodsViewController.loadSubView( firstColumn, beforeLoadView, afterLoadView );\n\n\t\t} );\n\n\t\tfunction beforeLoadView() {\n\n\t\t}\n\n\t\tfunction afterLoadView( subViewController ) {\n\n\t\t\t$this.sub_pay_periods_view_controller = subViewController;\n\t\t\t$this.sub_pay_periods_view_controller.parent_key = 'pay_period_schedule_id';\n\t\t\t$this.sub_pay_periods_view_controller.parent_value = $this.current_edit_record.id;\n\t\t\t$this.sub_pay_periods_view_controller.parent_edit_record = $this.current_edit_record;\n\t\t\t$this.sub_pay_periods_view_controller.parent_view_controller = $this;\n\t\t\t$this.sub_pay_periods_view_controller.initData(); //Init data in this parent view\n\t\t}\n\t}\n\n\tonFormItemChange( target, doNotValidate ) {\n\n\t\tthis.setIsChanged( target );\n\t\tthis.setMassEditingFieldsWhenFormChange( target );\n\t\tvar key = target.getField();\n\t\tvar c_value = target.getValue();\n\n\t\tthis.current_edit_record[key] = c_value;\n\n\t\tif ( key == 'type_id' ) {\n\t\t\tthis.onTypeChange();\n\t\t} else if ( key == 'start_day_of_week' && ( !this.current_edit_record || !this.current_edit_record.id ) ) {\n\t\t\tthis.edit_view_ui_dic.start_week_day_id.setValue( this.edit_view_ui_dic.start_day_of_week.getValue() );\n\t\t\tthis.current_edit_record.start_week_day_id = this.edit_view_ui_dic.start_day_of_week.getValue();\n\t\t} else if ( key == 'timesheet_verify_type_id' ) {\n\t\t\tthis.onVerifyTypeChange();\n\t\t}\n\n\t\tif ( !doNotValidate ) {\n\t\t\tthis.validate();\n\t\t}\n\t}\n\n\tremoveEditView() {\n\n\t\tsuper.removeEditView();\n\t\tthis.sub_pay_periods_view_controller = null;\n\t}\n\n\tonVerifyTypeChange() {\n\t\tif ( this.current_edit_record.timesheet_verify_type_id == 10 ) {\n\t\t\tthis.detachElement( 'timesheet_verify_before_end_date' );\n\t\t\tthis.detachElement( 'timesheet_verify_before_transaction_date' );\n\t\t} else {\n\t\t\tthis.attachElement( 'timesheet_verify_before_end_date' );\n\t\t\tthis.attachElement( 'timesheet_verify_before_transaction_date' );\n\t\t}\n\n\t\tthis.editFieldResize();\n\t}\n\n\tonTypeChange() {\n\n\t\tif ( this.current_edit_record.type_id == 5 ) {\n\t\t\tthis.detachElement( 'anchor_date' );\n\t\t} else {\n\n\t\t\tif ( this.current_edit_record.id ) {\n\t\t\t\tthis.detachElement( 'anchor_date' );\n\t\t\t} else {\n\t\t\t\tthis.attachElement( 'anchor_date' );\n\t\t\t}\n\n\t\t}\n\n\t\tif ( this.current_edit_record.type_id == 5 ) {\n\t\t\tthis.detachElement( 'primary' );\n\t\t\tthis.detachElement( 'primary_day_of_month' );\n\t\t\tthis.detachElement( 'primary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'secondary' );\n\t\t\tthis.detachElement( 'secondary_day_of_month' );\n\t\t\tthis.detachElement( 'secondary_transaction_day_of_month' );\n\t\t\tthis.attachElement( 'annual_pay_periods' );\n\t\t\tthis.detachElement( 'start_day_of_week' );\n\t\t\tthis.detachElement( 'transaction_date' );\n\t\t\tthis.detachElement( 'transaction_date_bd' );\n\n\t\t} else if ( this.current_edit_record.type_id == 10 || this.current_edit_record.type_id == 20 || this.current_edit_record.type_id == 100 || this.current_edit_record.type_id == 200 ) {\n\t\t\tthis.detachElement( 'primary' );\n\t\t\tthis.detachElement( 'primary_day_of_month' );\n\t\t\tthis.detachElement( 'primary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'secondary' );\n\t\t\tthis.detachElement( 'secondary_day_of_month' );\n\t\t\tthis.detachElement( 'secondary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'annual_pay_periods' );\n\t\t\tthis.attachElement( 'start_day_of_week' );\n\t\t\tthis.attachElement( 'transaction_date' );\n\t\t\tthis.attachElement( 'transaction_date_bd' );\n\n\t\t} else if ( this.current_edit_record.type_id == 30 ) {\n\t\t\tthis.attachElement( 'primary' );\n\t\t\tthis.attachElement( 'primary_day_of_month' );\n\t\t\tthis.attachElement( 'primary_transaction_day_of_month' );\n\t\t\tthis.attachElement( 'secondary' );\n\t\t\tthis.attachElement( 'secondary_day_of_month' );\n\t\t\tthis.attachElement( 'secondary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'annual_pay_periods' );\n\t\t\tthis.detachElement( 'start_day_of_week' );\n\t\t\tthis.detachElement( 'transaction_date' );\n\t\t\tthis.attachElement( 'transaction_date_bd' );\n\t\t} else if ( this.current_edit_record.type_id == 50 ) {\n\t\t\tthis.attachElement( 'primary' );\n\t\t\tthis.attachElement( 'primary_day_of_month' );\n\t\t\tthis.attachElement( 'primary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'secondary' );\n\t\t\tthis.detachElement( 'secondary_day_of_month' );\n\t\t\tthis.detachElement( 'secondary_transaction_day_of_month' );\n\t\t\tthis.detachElement( 'annual_pay_periods' );\n\t\t\tthis.detachElement( 'start_day_of_week' );\n\t\t\tthis.detachElement( 'transaction_date' );\n\t\t\tthis.attachElement( 'transaction_date_bd' );\n\t\t}\n\n\t\tthis.editFieldResize();\n\t}\n\n\tsetCurrentEditRecordData() {\n\t\t//Set current edit record data to all widgets\n\t\tfor ( var key in this.current_edit_record ) {\n\t\t\tvar widget = this.edit_view_ui_dic[key];\n\t\t\tif ( Global.isSet( widget ) ) {\n\t\t\t\tswitch ( key ) {\n\t\t\t\t\tdefault:\n\t\t\t\t\t\twidget.setValue( this.current_edit_record[key] );\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\tthis.onTypeChange();\n\t\tthis.onVerifyTypeChange();\n\t\tthis.collectUIDataToCurrentEditRecord();\n\t\tthis.setEditViewDataDone();\n\t}\n\n\tbuildEditViewUI() {\n\n\t\tsuper.buildEditViewUI();\n\n\t\tvar $this = this;\n\n\t\tvar tab_model = {\n\t\t\t'tab_pay_period_schedule': {\n\t\t\t\t'label': $.i18n._( 'Pay Period Schedule' )\n\t\t\t},\n\t\t\t'tab_advanced': {\n\t\t\t\t'label': $.i18n._( 'Advanced' )\n\t\t\t},\n\t\t\t'tab_pay_period': {\n\t\t\t\t'label': $.i18n._( 'Pay Periods' ),\n\t\t\t\t'init_callback': 'initSubPayPeriodsView',\n\t\t\t\t'display_on_mass_edit': false\n\t\t\t},\n\t\t\t'tab_audit': true,\n\t\t};\n\t\tthis.setTabModel( tab_model );\n\n\t\tif ( !this.edit_only_mode ) {\n\t\t\tthis.navigation.AComboBox( {\n\t\t\t\tid: this.script_name + '_navigation',\n\t\t\t\tapi_class: TTAPI.APIPayPeriodSchedule,\n\t\t\t\tallow_multiple_selection: false,\n\t\t\t\tlayout_name: 'global_pay_period_schedule',\n\t\t\t\tnavigation_mode: true,\n\t\t\t\tshow_search_inputs: true\n\t\t\t} );\n\n\t\t\tthis.setNavigation();\n\t\t}\n\n\t\t//Tab 0 start\n\n\t\tvar tab_pay_period_schedule = this.edit_view_tab.find( '#tab_pay_period_schedule' );\n\n\t\tvar tab_pay_period_schedule_column1 = tab_pay_period_schedule.find( '.first-column' );\n\t\tthis.edit_view_tabs[0] = [];\n\n\t\tthis.edit_view_tabs[0].push( tab_pay_period_schedule_column1 );\n\n\t\tvar form_item_input;\n\t\tvar widgetContainer;\n\t\tvar label;\n\n\t\t//Name\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'name', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Name' ), form_item_input, tab_pay_period_schedule_column1, '' );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Description\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'description', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Description' ), form_item_input, tab_pay_period_schedule_column1 );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Pay Period Dates\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.SEPARATED_BOX );\n\t\tform_item_input.SeparatedBox( { label: $.i18n._( 'Pay Period Dates' ) } );\n\t\tthis.addEditFieldToColumn( null, form_item_input, tab_pay_period_schedule_column1 );\n\n\t\t// Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'type_id' } );\n\t\tform_item_input.setSourceData( $this.type_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Type' ), form_item_input, tab_pay_period_schedule_column1 );\n\n\t\t// Primary\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.SEPARATED_BOX );\n\t\tform_item_input.SeparatedBox( { label: $.i18n._( 'Primary' ) } );\n\t\tthis.addEditFieldToColumn( null, form_item_input, tab_pay_period_schedule_column1, '', null, true, false, 'primary' );\n\n\t\t// Pay Period Start Day of Month\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'primary_day_of_month' } );\n\t\twidgetContainer = $( '
' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tform_item_input.setSourceData( $this.transaction_date_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Pay Period Start Day of Month' ), form_item_input, tab_pay_period_schedule_column1, '', widgetContainer, true );\n\n\t\t// Transaction Day Of Month\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'primary_transaction_day_of_month' } );\n\t\tform_item_input.setSourceData( $this.transaction_date_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Transaction Day Of Month' ), form_item_input, tab_pay_period_schedule_column1, '', null, true );\n\n\t\t// Secondary\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.SEPARATED_BOX );\n\t\tform_item_input.SeparatedBox( { label: $.i18n._( 'Secondary' ) } );\n\t\tthis.addEditFieldToColumn( null, form_item_input, tab_pay_period_schedule_column1, '', null, true, false, 'secondary' );\n\n\t\t// Pay Period Start Day Of Month\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'secondary_day_of_month' } );\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tform_item_input.setSourceData( $this.transaction_date_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Pay Period Start Day of Month' ), form_item_input, tab_pay_period_schedule_column1, '', widgetContainer, true );\n\n\t\t// Transaction Day Of Month\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'secondary_transaction_day_of_month' } );\n\t\tform_item_input.setSourceData( $this.transaction_date_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Transaction Day Of Month' ), form_item_input, tab_pay_period_schedule_column1, '', null, true );\n\n\t\t// Annual Pay Periods\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'annual_pay_periods' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Annual Pay Periods' ), form_item_input, tab_pay_period_schedule_column1, '', null, true );\n\n\t\t// Pay Period Starts On\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'start_day_of_week' } );\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tform_item_input.setSourceData( $this.pay_period_starts_on_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Pay Period Starts On' ), form_item_input, tab_pay_period_schedule_column1, '', widgetContainer, true );\n\n\t\t// Transaction Date\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'transaction_date' } );\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tform_item_input.setSourceData( $this.transaction_date_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Transaction Date' ), form_item_input, tab_pay_period_schedule_column1, '', widgetContainer, true );\n\n\t\t// Transaction Always on Business Day\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'transaction_date_bd' } );\n\n\t\tform_item_input.setSourceData( $this.transaction_date_business_day_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Transaction Always on Business Day' ), form_item_input, tab_pay_period_schedule_column1, '', null, true );\n\n\t\t//Create Initial Pay Periods From\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.DATE_PICKER );\n\n\t\tform_item_input.TDatePicker( { field: 'anchor_date' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Create Initial Pay Periods From' ), form_item_input, tab_pay_period_schedule_column1, '', null, true );\n\n\t\t// employees\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIUser,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_user',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'user'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Employees' ), form_item_input, tab_pay_period_schedule_column1 );\n\n\t\t//Tab 0 start\n\n\t\tvar tab_advanced = this.edit_view_tab.find( '#tab_advanced' );\n\n\t\tvar tab_advanced_column1 = tab_advanced.find( '.first-column' );\n\t\tthis.edit_view_tabs[1] = [];\n\n\t\tthis.edit_view_tabs[1].push( tab_advanced_column1 );\n\n\t\t// Overtime Week\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'start_week_day_id' } );\n\t\tform_item_input.setSourceData( $this.start_week_day_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Overtime Week' ), form_item_input, tab_advanced_column1, '' );\n\n\t\t// Time Zone\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'time_zone', set_empty: true } );\n\t\tform_item_input.setSourceData( $this.time_zone_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Time Zone' ), form_item_input, tab_advanced_column1 );\n\n\t\t// Minimum Time-Off Between Shifts\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'new_day_trigger_time', mode: 'time_unit', need_parser_sec: true } );\n\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Minimum Time-Off Between Shifts' ), form_item_input, tab_advanced_column1, '', widgetContainer );\n\n\t\t// Maximum Shift Time\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'maximum_shift_time', mode: 'time_unit', need_parser_sec: true } );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Maximum Shift Time' ), form_item_input, tab_advanced_column1, '', null );\n\n\t\t// Assign Shifts To\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'shift_assigned_day_id' } );\n\t\tform_item_input.setSourceData( $this.shift_assigned_day_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Assign Shifts To' ), form_item_input, tab_advanced_column1 );\n\n\t\t// Populate Days in Advance\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'create_days_in_advance', width: 50 } );\n\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Create Pay Periods' ), form_item_input, tab_advanced_column1, '', widgetContainer );\n\n\t\t// Auto close pay period\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'auto_close_after_days', width: 50 } );\n\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Auto Close' ), form_item_input, tab_advanced_column1, '', widgetContainer );\n\n\t\t// TimeSheet Verification\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.SEPARATED_BOX );\n\t\tform_item_input.SeparatedBox( { label: $.i18n._( 'TimeSheet Verification' ) } );\n\t\tthis.addEditFieldToColumn( null, form_item_input, tab_advanced_column1 );\n\n\t\t// Timesheet Verification\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'timesheet_verify_type_id' } );\n\t\tform_item_input.setSourceData( $this.timesheet_verify_type_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TimeSheet Verification' ), form_item_input, tab_advanced_column1 );\n\n\t\t// Verification Window Starts\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'timesheet_verify_before_end_date', width: 30 } );\n\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Verification Window Starts' ), form_item_input, tab_advanced_column1, '', widgetContainer, true );\n\n\t\t// Verification Windows Ends\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'timesheet_verify_before_transaction_date', width: 30 } );\n\n\t\twidgetContainer = $( '' );\n\t\tlabel = $( ' ' );\n\t\twidgetContainer.append( form_item_input );\n\t\twidgetContainer.append( label );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Verification Window Ends' ), form_item_input, tab_advanced_column1, '', widgetContainer, true );\n\t}\n\n\tbuildSearchFields() {\n\n\t\tsuper.buildSearchFields();\n\n\t\tthis.search_fields = [\n\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Name' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'name',\n\t\t\t\tbasic_search: true,\n\t\t\t\tform_item_type: FormItemType.TEXT_INPUT\n\t\t\t} ),\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Type' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'type_id',\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tlayout_name: 'global_option_column',\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} ),\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Description' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'description',\n\t\t\t\tbasic_search: true,\n\t\t\t\tform_item_type: FormItemType.TEXT_INPUT\n\t\t\t} ),\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Created By' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tfield: 'created_by',\n\t\t\t\tlayout_name: 'global_user',\n\t\t\t\tapi_class: TTAPI.APIUser,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tscript_name: 'EmployeeView',\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} ),\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Updated By' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tfield: 'updated_by',\n\t\t\t\tlayout_name: 'global_user',\n\t\t\t\tapi_class: TTAPI.APIUser,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tscript_name: 'EmployeeView',\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} )\n\n\t\t];\n\n\t}\n\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNjQxNS5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7QUFBTztBQU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