"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["policy-schedule_policy-SchedulePolicyViewController"],{7911:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"SchedulePolicyViewController\": () => (/* binding */ SchedulePolicyViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass SchedulePolicyViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#schedule_policy_view_container',\n\n\t\t\tover_time_policy_api: null\n\t\t} );\n\n\t\tsuper( options );\n\t}\n\n\tinit( options ) {\n\t\t//this._super('initialize', options );\n\t\tthis.edit_view_tpl = 'SchedulePolicyEditView.html';\n\t\tthis.permission_id = 'schedule_policy';\n\t\tthis.viewId = 'SchedulePolicy';\n\t\tthis.script_name = 'SchedulePolicyView';\n\t\tthis.table_name_key = 'schedule_policy';\n\t\tthis.context_menu_name = $.i18n._( 'Schedule Policy' );\n\t\tthis.navigation_label = $.i18n._( 'Schedule Policy' );\n\t\tthis.api = TTAPI.APISchedulePolicy;\n\t\tthis.over_time_policy_api = TTAPI.APIOverTimePolicy;\n\t\tthis.render();\n\t\tthis.buildContextMenu();\n\n\t\tthis.initData();\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_schedule_policy': { 'label': $.i18n._( 'Schedule Policy' ) },\n\t\t\t'tab_audit': true,\n\t\t};\n\t\tthis.setTabModel( tab_model );\n\n\t\tthis.navigation.AComboBox( {\n\t\t\tapi_class: TTAPI.APISchedulePolicy,\n\t\t\tid: this.script_name + '_navigation',\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_schedule',\n\t\t\tnavigation_mode: true,\n\t\t\tshow_search_inputs: true\n\t\t} );\n\n\t\tthis.setNavigation();\n\n\t\t//Tab 0 start\n\n\t\tvar tab_schedule_policy = this.edit_view_tab.find( '#tab_schedule_policy' );\n\n\t\tvar tab_schedule_policy_column1 = tab_schedule_policy.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[0] = [];\n\n\t\tthis.edit_view_tabs[0].push( tab_schedule_policy_column1 );\n\n\t\t//Name\n\t\tvar form_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'name', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Name' ), form_item_input, tab_schedule_policy_column1, '' );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Description\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_AREA );\n\t\tform_item_input.TTextArea( { field: 'description', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Description' ), form_item_input, tab_schedule_policy_column1, '', null, null, true );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t//Meal Policy\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIMealPolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_meal',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_any: true,\n\t\t\tfield: 'meal_policy',\n\t\t\tcustom_first_label: $.i18n._( '-- No Meal --' ),\n\t\t\taddition_source_function: this.onMealOrBreakSourceCreate,\n\t\t\tadded_items: [\n\t\t\t\t{ value: TTUUID.zero_id, label: $.i18n._( '-- Defined By Policy Group --' ) }\n\t\t\t]\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Meal Policy' ), form_item_input, tab_schedule_policy_column1 );\n\n\t\t//Break Policy\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIBreakPolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_break',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_any: true,\n\t\t\tfield: 'break_policy',\n\t\t\tcustom_first_label: '-- ' + $.i18n._( 'No Break' ) + ' --',\n\t\t\taddition_source_function: this.onMealOrBreakSourceCreate,\n\t\t\tadded_items: [\n\t\t\t\t{ value: TTUUID.zero_id, label: '-- ' + $.i18n._( 'Defined By Policy Group' ) + ' --' }\n\t\t\t]\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Break Policy' ), form_item_input, tab_schedule_policy_column1 );\n\n\t\t// Regular Time Policy\n\t\tvar v_box = $( '
' );\n\t\t//Include\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIRegularTimePolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_regular_time',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'include_regular_time_policy'\n\t\t} );\n\n\t\tvar form_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Include' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Exclude\n\t\tvar form_item_input_1 = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input_1.AComboBox( {\n\t\t\tapi_class: TTAPI.APIRegularTimePolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_regular_time',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'exclude_regular_time_policy'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Exclude' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Regular Time Policy' ), [form_item_input, form_item_input_1], tab_schedule_policy_column1, '', v_box, false, true );\n\n\t\t//Overtime Policy\n\n\t\tv_box = $( '
' );\n\n\t\tvar default_args = {};\n\t\tdefault_args.filter_data = {};\n\t\tdefault_args.filter_data.type_id = [10, 40, 50, 60, 70, 80, 90, 100, 180, 200];\n\n\t\t//Include\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIOverTimePolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_over_time',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'include_over_time_policy'\n\t\t} );\n\n\t\tform_item_input.setDefaultArgs( default_args );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Include' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Exclude\n\t\tform_item_input_1 = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input_1.AComboBox( {\n\t\t\tapi_class: TTAPI.APIOverTimePolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_over_time',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'exclude_over_time_policy'\n\t\t} );\n\n\t\tform_item_input_1.setDefaultArgs( default_args );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Exclude' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Overtime Policy' ), [form_item_input, form_item_input_1], tab_schedule_policy_column1, '', v_box, false, true );\n\n\t\t//Premium Policy\n\t\tv_box = $( '
' );\n\n\t\t//Include\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIPremiumPolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_premium',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'include_premium_policy'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Include' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Exclude\n\t\tform_item_input_1 = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input_1.AComboBox( {\n\t\t\tapi_class: TTAPI.APIPremiumPolicy,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_premium',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'exclude_premium_policy'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Exclude' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Premium Policy' ), [form_item_input, form_item_input_1], tab_schedule_policy_column1, '', v_box, false, true );\n\n\t\t//Full Shift Undertime Absence Policy\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIAbsencePolicy,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_absences',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'full_shift_absence_policy_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Full Shift Undertime Absence Policy' ), form_item_input, tab_schedule_policy_column1 );\n\n\t\t//Partial Shift Undertime Absence Policy\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIAbsencePolicy,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_absences',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'partial_shift_absence_policy_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Partial Shift Undertime Absence Policy' ), form_item_input, tab_schedule_policy_column1 );\n\n\t\t//Start / Stop Window\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'start_stop_window', mode: 'time_unit', need_parser_sec: true } );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Start / Stop Window' ), form_item_input, tab_schedule_policy_column1, '', null );\n\t}\n\n\tonMealOrBreakSourceCreate( target, source_data ) {\n\t\tvar display_columns = target.getDisplayColumns();\n\n\t\tvar first_item = {};\n\t\t$.each( display_columns, function( index, content ) {\n\n\t\t\tfirst_item.id = TTUUID.zero_id;\n\t\t\tfirst_item[content.name] = $.i18n._( '-- Defined By Policy Group --' );\n\n\t\t\treturn false;\n\t\t} );\n\n\t\tsource_data.unshift( first_item );\n\n\t\treturn source_data;\n\t}\n\n\tsetCurrentEditRecordData() {\n\n\t\t//Set current edit record data to all widgets\n\t\tfor ( var key in this.current_edit_record ) {\n\n\t\t\tif ( !this.current_edit_record.hasOwnProperty( key ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\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\tcase 'country': //popular case\n\t\t\t\t\t\tthis.setCountryValue( widget, key );\n\t\t\t\t\t\tbreak;\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\n\t\tthis.collectUIDataToCurrentEditRecord();\n\t\tthis.setEditViewDataDone();\n\t}\n\n\tonFormItemChange( target, doNotValidate ) {\n\t\tthis.setIsChanged( target );\n\t\tthis.setMassEditingFieldsWhenFormChange( target );\n\n\t\tvar key = target.getField();\n\t\tvar c_value = target.getValue();\n\n//\t\tswitch ( key ) {\n//\t\t\tcase 'start_stop_window':\n//\t\t\t\tc_value = this.date_api.parseTimeUnit( target.getValue(), {async: false} ).getResult();\n//\t\t\t\tbreak;\n//\t\t}\n\n\t\tthis.current_edit_record[key] = c_value;\n\n\t\tif ( !doNotValidate ) {\n\t\t\tthis.validate();\n\t\t}\n\t}\n\n\tbuildSearchFields() {\n\n\t\tsuper.buildSearchFields();\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\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: false,\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._( 'Full Shift Absence Policy' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'full_shift_absence_policy_id',\n\t\t\t\tlayout_name: 'global_absences',\n\t\t\t\tapi_class: TTAPI.APIAbsencePolicy,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: false,\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._( 'Partial Shift Absence Policy' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'partial_shift_absence_policy_id',\n\t\t\t\tlayout_name: 'global_absences',\n\t\t\t\tapi_class: TTAPI.APIAbsencePolicy,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: false,\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._( '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\tadv_search: false,\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} ),\n\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\tadv_search: false,\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} )\n\t\t];\n\t}\n\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiNzkxMS5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7QUFBTztBQUNQLDJCQUEyQjtBQUMzQixFQUFFLENBQUM7QUFDSDs7QUFFQTtBQUNBLElBQUk7O0FBRUo7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBLDJCQUEyQixDQUFDO0FBQzVCLDBCQUEwQixDQUFDO0FBQzNCO0FBQ0E7QUFDQTtBQUNBOztBQUVBO0FBQ0E7O0FBRUE7O0FBRUE7O0FBRUE7O0FBRUE7QUFDQSw0QkFBNEIsU0FBUyxDQUFDLDhCQUE4QjtBQUNwRTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQSxJQUFJOztBQUVKOztBQUVBOztBQUVBOztBQUVBOztBQUVBOztBQUVBOztBQUVBO0FBQ0E7O0FBRUEsZ0NBQWdDLCtCQUErQjtBQUMvRCw2QkFBNkIsQ0FBQzs7QUFFOUI7O0FBRUE7QUFDQTtBQUNBLCtCQUErQixzQ0FBc0M7QUFDckUsNkJBQTZCLENBQUM7O0FBRTlCOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBL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