"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["attendance-job-JobViewController"],{1088:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"JobViewController\": () => (/* binding */ JobViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass JobViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#job_view_container',\n\n\t\t\t// _required_files: {\n\t\t\t// \t15: ['leaflet-timetrex']\n\t\t\t// },\n\t\t\tstatus_array: null,\n\n\t\t\tjob_group_array: null,\n\t\t\tjob_group_api: null,\n\t\t\tuser_group_api: null,\n\t\t\tjob_item_group_api: null,\n\t\t\tjob_detail_report_api: null,\n\n\t\t\tuser_group_selection_type_array: null,\n\t\t\tuser_branch_selection_type_array: null,\n\t\t\tuser_department_selection_type_array: null,\n\t\t\tjob_item_group_selection_type_array: null,\n\t\t\tuser_title_selection_type_id_array: null,\n\n\t\t\tuser_group_array: null,\n\n\t\t\tsub_document_view_controller: null,\n\n\t\t\tsub_job_item_amendment_view_controller: null,\n\n\t\t\tdocument_object_type_id: null,\n\t\t\tdate_api: null,\n\t\t\treport_template: null,\n\t\t\tcountry_array: null,\n\t\t\tprovince_array: null,\n\n\t\t\te_province_array: null,\n\n\t\t\tcompany_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 = 'JobEditView.html';\n\t\tthis.permission_id = 'job';\n\t\tthis.viewId = 'Job';\n\t\tthis.script_name = 'JobView';\n\t\tthis.table_name_key = 'job';\n\t\tthis.context_menu_name = $.i18n._( 'Job' );\n\t\tthis.navigation_label = $.i18n._( 'Job' );\n\n\t\tthis.document_object_type_id = 60;\n\t\tthis.api = TTAPI.APIJob;\n\t\tthis.date_api = TTAPI.APITTDate;\n\t\tthis.job_group_api = TTAPI.APIJobGroup;\n\t\tthis.user_group_api = TTAPI.APIUserGroup;\n\t\tthis.job_item_group_api = TTAPI.APIJobItemGroup;\n\t\tthis.job_detail_report_api = TTAPI.APIJobDetailReport;\n\t\tthis.company_api = TTAPI.APICompany;\n\n\t\tthis.render();\n\t\tthis.buildContextMenu();\n\n\t\tthis.initData();\n\t}\n\n\tinitOptions() {\n\t\tvar $this = this;\n\n\t\tvar options = [\n\t\t\t{ option_name: 'status', api: this.api },\n\t\t\t{ option_name: 'user_group_selection_type', api: this.api },\n\t\t\t{ option_name: 'user_branch_selection_type', api: this.api },\n\t\t\t{ option_name: 'user_department_selection_type', api: this.api },\n\t\t\t{ option_name: 'user_title_selection_type_id', api: this.api },\n\t\t\t{ option_name: 'job_item_group_selection_type', api: this.api },\n\t\t\t{ option_name: 'country', field_name: 'country', api: this.company_api },\n\t\t];\n\n\t\tthis.initDropDownOptions( options );\n\n\t\tthis.job_group_api.getJobGroup( '', false, false, {\n\t\t\tonResult: function( res ) {\n\t\t\t\tres = res.getResult();\n\t\t\t\tres = Global.buildTreeRecord( res );\n\n\t\t\t\tif ( !$this.sub_view_mode && $this.basic_search_field_ui_dic['group_id'] ) {\n\t\t\t\t\t$this.basic_search_field_ui_dic['group_id'].setSourceData( res );\n\t\t\t\t\t$this.adv_search_field_ui_dic['group_id'].setSourceData( res );\n\t\t\t\t}\n\n\t\t\t\t$this.job_group_array = res;\n\n\t\t\t}\n\t\t} );\n\n\t\tthis.user_group_api.getUserGroup( '', false, false, {\n\t\t\tonResult: function( res ) {\n\n\t\t\t\tres = res.getResult();\n\t\t\t\tres = Global.buildTreeRecord( res );\n\t\t\t\t$this.user_group_array = res;\n\n\t\t\t}\n\t\t} );\n\n\t\tthis.job_item_group_api.getJobItemGroup( '', false, false, {\n\t\t\tonResult: function( res ) {\n\n\t\t\t\tres = res.getResult();\n\t\t\t\tres = Global.buildTreeRecord( res );\n\t\t\t\t$this.job_item_group_array = res;\n\n\t\t\t}\n\t\t} );\n\n\t\tthis.job_detail_report_api.getTemplate( 'view_job_detail', {\n\t\t\tonResult: function( res ) {\n\n\t\t\t\tres = res.getResult();\n\t\t\t\t$this.report_template = res;\n\n\t\t\t}\n\t\t} );\n\t}\n\n\tgetCustomContextMenuModel() {\n\t\tvar context_menu_model = {\n\t\t\texclude: [],\n\t\t\tinclude: [\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Import' ),\n\t\t\t\t\tid: 'import_icon',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'import_export',\n\t\t\t\t\tgroup: 'other',\n\t\t\t\t\tvue_icon: 'tticon tticon-file_download_black_24dp',\n\t\t\t\t\tpermission_result: PermissionManager.checkTopLevelPermission( 'ImportCSVJob' ),\n\t\t\t\t\tpermission: null,\n\t\t\t\t\tsort_order: 9010\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Map' ),\n\t\t\t\t\tid: 'map',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\tgroup: 'other',\n\t\t\t\t\tvue_icon: 'tticon tticon-map_black_24dp',\n\t\t\t\t\tsort_order: 8000,\n\t\t\t\t},\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: 'other',\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._( 'Invoice' ),\n\t\t\t\t\tid: 'job_invoice',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'other',\n\t\t\t\t\tpermission_result: PermissionManager.checkTopLevelPermission( 'JobInvoice' ),\n\t\t\t\t\tpermission: null\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tlabel: $.i18n._( 'Report' ),\n\t\t\t\t\tid: 'print',\n\t\t\t\t\tmenu_align: 'right',\n\t\t\t\t\taction_group: 'other',\n\t\t\t\t},\n\t\t\t]\n\t\t};\n\n\t\treturn context_menu_model;\n\t}\n\n\tonCustomContextClick( id ) {\n\t\tswitch ( id ) {\n\t\t\tcase 'import_icon':\n\t\t\t\tthis.onOtherIconsClick( 'ImportCSVWizard' );\n\t\t\t\tbreak;\n\t\t\tcase 'job_invoice':\n\t\t\t\tthis.onOtherIconsClick( 'JobInvoiceWizard' );\n\t\t\t\tbreak;\n\t\t\tcase 'print':\n\t\t\t\tthis.generatePDFReport();\n\t\t\t\tbreak;\n\t\t}\n\t}\n\n\tonMapClick() {\n\t\t// only trigger map load in specific product editions.\n\t\tif ( ( Global.getProductEdition() >= 15 ) ) {\n\t\t\tthis.is_viewing = false;\n\t\t\tProgressBar.showProgressBar();\n\t\t\tvar data = {\n\t\t\t\tfilter_columns: {\n\t\t\t\t\tid: true,\n\t\t\t\t\tname: true,\n\t\t\t\t\taddress1: true,\n\t\t\t\t\taddress2: true,\n\t\t\t\t\tcity: true,\n\t\t\t\t\tprovince: true,\n\t\t\t\t\tcountry: true,\n\t\t\t\t\tpostal_code: true,\n\t\t\t\t\tlatitude: true,\n\t\t\t\t\tlongitude: true\n\t\t\t\t}\n\t\t\t};\n\t\t\tvar ids = this.getGridSelectIdArray();\n\t\t\tdata.filter_data = Global.convertLayoutFilterToAPIFilter( this.select_layout );\n\t\t\tif ( ids.length > 0 ) {\n\t\t\t\tdata.filter_data.id = ids;\n\t\t\t}\n\t\t\tvar cells = this.api.getJob( data, { async: false } ).getResult();\n\t\t\tif ( !this.is_mass_editing ) {\n\t\t\t\tPromise.all(/* import() | leaflet-timetrex */[__webpack_require__.e(\"vendors-node_modules_leaflet_dist_images_marker-icon-2x_png-node_modules_leaflet_dist_images_-78d511\"), __webpack_require__.e(\"interface_html5_framework_leaflet_leaflet-timetrex_js\"), __webpack_require__.e(\"leaflet-timetrex\")]).then(__webpack_require__.bind(__webpack_require__, 6889)).then(( module )=>{\n\t\t\t\t\tvar processed_data_for_map = module.TTConvertMapData.processBasicFromGenericViewController( cells );\n\t\t\t\t\tIndexViewController.openEditView( this, 'Map', processed_data_for_map );\n\t\t\t\t}).catch( Global.importErrorHandler );\n\t\t\t}\n\t\t}\n\t}\n\n\tgetSelectEmployee( full_item ) {\n\t\tvar user;\n\t\tif ( full_item ) {\n\t\t\tuser = LocalCacheData.getLoginUser();\n\t\t} else {\n\t\t\tuser = LocalCacheData.getLoginUser().id;\n\t\t}\n\n\t\treturn user;\n\t}\n\n\tgeneratePDFReport() {\n\n\t\tvar $this = this;\n\n\t\tvar grid_selected_id_array;\n\n\t\tvar include_job_ids = [];\n\n\t\tif ( $this.edit_view && $this.current_edit_record.id ) {\n\t\t\tinclude_job_ids.push( $this.current_edit_record.id );\n\t\t} else {\n\t\t\tgrid_selected_id_array = this.getGridSelectIdArray();\n\t\t\t$.each( grid_selected_id_array, function( index, value ) {\n\t\t\t\tvar grid_selected_row = $this.getRecordFromGridById( value );\n\t\t\t\tinclude_job_ids.push( grid_selected_row.id );\n\t\t\t} );\n\t\t}\n\n\t\tif ( include_job_ids.length > 0 ) {\n\t\t\tif ( this.report_template ) {\n\t\t\t\tthis.report_template.include_job_id = include_job_ids;\n\t\t\t\tvar postData = [];\n\t\t\t\tpostData.push( this.report_template );\n\t\t\t\tpostData.push( 'pdf_job_detail' );\n\t\t\t\tthis.doFormIFrameCall( postData );\n\t\t\t}\n\t\t} else {\n\t\t\tTAlertManager.showAlert( $.i18n._( 'No selected record' ) );\n\t\t\tProgressBar.closeOverlay();\n\t\t\treturn;\n\t\t}\n\t}\n\n\tdoFormIFrameCall( postData ) {\n\t\tGlobal.APIFileDownload( 'APIJobDetailReport', 'getJobDetailReport', postData );\n\t}\n\n\tremoveEditView() {\n\t\tsuper.removeEditView();\n\t\tthis.sub_job_item_amendment_view_controller = null;\n\t}\n\n\tonOtherIconsClick( wizard_id ) {\n\t\tvar $this = this;\n\t\tIndexViewController.openWizard( wizard_id, null, function() {\n\t\t\t$this.search();\n\t\t} );\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_job': { 'label': $.i18n._( 'Job' ), 'is_multi_column': true },\n\t\t\t'tab_location': { 'label': $.i18n._( 'Location' ) },\n\t\t\t'tab_employee_criteria': { 'label': $.i18n._( 'Employee Criteria' ) },\n\t\t\t'tab_task_criteria': { 'label': $.i18n._( 'Task Criteria' ) },\n\t\t\t'tab_task_amendments': {\n\t\t\t\t'label': $.i18n._( 'Task Amendments' ),\n\t\t\t\t'init_callback': 'initSubJobItemAmendmentView',\n\t\t\t\t'display_on_mass_edit': false\n\t\t\t},\n\t\t\t'tab_attachment': true,\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.APIJob,\n\t\t\tid: this.script_name + '_navigation',\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_job',\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_job = this.edit_view_tab.find( '#tab_job' );\n\n\t\tvar tab_job_column1 = tab_job.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[0] = [];\n\n\t\tthis.edit_view_tabs[0].push( tab_job_column1 );\n\n\t\tvar form_item_input;\n\t\tvar widgetContainer;\n\t\tvar label;\n\n\t\t//Status\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'status_id' } );\n\t\tform_item_input.setSourceData( $this.status_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Status' ), form_item_input, tab_job_column1, '' );\n\n//\t\t Name\n\t\tform_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_job_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\n\t\tform_item_input.TTextInput( { field: 'description', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Description' ), form_item_input, tab_job_column1 );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t//Code\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'manual_id', width: 65 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Code' ), form_item_input, tab_job_column1 );\n\n\t\t//Group\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\ttree_mode: true,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_tree_column',\n\t\t\tset_empty: true,\n\t\t\tfield: 'group_id'\n\t\t} );\n\t\tform_item_input.setSourceData( $this.job_group_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Group' ), form_item_input, tab_job_column1 );\n\n\t\t// Client\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIClient,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_client',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'client_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Client' ), form_item_input, tab_job_column1 );\n\n\t\t//Branch\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIBranch,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_branch',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'branch_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Branch' ), form_item_input, tab_job_column1 );\n\n\t\t//Department\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIDepartment,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_department',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'department_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Department' ), form_item_input, tab_job_column1 );\n\n\t\t//Supervisor\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIUser,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_user',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'supervisor_user_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Supervisor' ), form_item_input, tab_job_column1 );\n\n\t\t//Default Task\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIJobItem,\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_job_item',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'default_item_id'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Default Task' ), form_item_input, tab_job_column1 );\n\n\t\t//Allowed GEO Fences\n\t\tif ( Global.getProductEdition() >= 20 ) {\n\t\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\t\tform_item_input.AComboBox( {\n\t\t\t\tapi_class: TTAPI.APIGEOFence,\n\t\t\t\tallow_multiple_selection: true,\n\t\t\t\tlayout_name: 'global_geo_fence',\n\t\t\t\tshow_search_inputs: true,\n\t\t\t\tset_empty: true,\n\t\t\t\tfield: 'geo_fence_ids'\n\t\t\t} );\n\t\t\tthis.addEditFieldToColumn( $.i18n._( 'Allowed GEO Fences' ), form_item_input, tab_job_column1 );\n\t\t}\n\n\t\t//Tags\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TAG_INPUT );\n\n\t\tform_item_input.TTagInput( { field: 'tag', object_type_id: 600 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Tags' ), form_item_input, tab_job_column1, '', null, null, true );\n\n\t\tvar tab_job_column2 = tab_job.find( '.second-column' );\n\n\t\tthis.edit_view_tabs[0].push( tab_job_column2 );\n\n\t\t//Start Date\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.DATE_PICKER );\n\n\t\tform_item_input.TDatePicker( { field: 'start_date' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Start Date' ), form_item_input, tab_job_column2 );\n\n\t\t//End Date\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.DATE_PICKER );\n\n\t\tform_item_input.TDatePicker( { field: 'end_date' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'End Date' ), form_item_input, tab_job_column2 );\n\n\t\t//Estimate Time\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'estimate_time', mode: 'time_unit', need_parser_sec: true } );\n\n\t\twidgetContainer = $( '
' );\n\n\t\tvar note = $( '' + $.i18n._( 'Set estimates to 0 to use Task Billable Amounts instead.' ) + ' ' );\n\t\twidgetContainer.append( note );\n\t\twidgetContainer.append( form_item_input );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Estimate Time' ), form_item_input, tab_job_column2, '', widgetContainer, true, false );\n\n\t\t//Billable Rate\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'billable_rate', width: 86 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Billable Rate' ), form_item_input, tab_job_column2 );\n\n\t\t//Minimum Time\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'minimum_time', mode: 'time_unit', need_parser_sec: true } );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Minimum Time' ), form_item_input, tab_job_column2, '', null );\n\n\t\t//Estimate Quantity\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'estimate_quantity', width: 150 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Estimate Quantity' ), form_item_input, tab_job_column2 );\n\n\t\t//Estimate Bad Quantity\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'estimate_bad_quantity', width: 150 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Estimate Bad Quantity' ), form_item_input, tab_job_column2 );\n\n\t\t//Bad Quantity Rate\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'bad_quantity_rate', width: 150 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Bad Quantity Rate' ), form_item_input, tab_job_column2 );\n\n\t\t//Note\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_AREA );\n\n\t\tform_item_input.TTextArea( { field: 'note', width: '100%' } );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Note' ), form_item_input, tab_job_column2, '', null, null, true );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Location\n\t\tvar tab_location = this.edit_view_tab.find( '#tab_location' );\n\t\tvar tab_location_column1 = tab_location.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[1] = [];\n\n\t\tthis.edit_view_tabs[1].push( tab_location_column1 );\n\n\t\t// Address1\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'address1', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Address (Line 1)' ), form_item_input, tab_location_column1 );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Address2\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'address2', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Address (Line 2)' ), form_item_input, tab_location_column1 );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// city\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'city', width: 149 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'City' ), form_item_input, tab_location_column1 );\n\n\t\t//Country\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'country', set_empty: true } );\n\t\tform_item_input.setSourceData( $this.country_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Country' ), form_item_input, tab_location_column1 );\n\n\t\t//Province / State\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\n\t\tform_item_input.TComboBox( { field: 'province' } );\n\t\tform_item_input.setSourceData( [] );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Province/State' ), form_item_input, tab_location_column1 );\n\n\t\t//Postal/ZIP Code\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\n\t\tform_item_input.TTextInput( { field: 'postal_code', width: 149 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Postal/ZIP Code' ), form_item_input, tab_location_column1 );\n\n\t\t//Location Note\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_AREA );\n\n\t\tform_item_input.TTextArea( { field: 'location_note', width: '100%' } );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Location Note' ), form_item_input, tab_location_column1, '', null, null, true );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\tvar tab_employee_criteria = this.edit_view_tab.find( '#tab_employee_criteria' );\n\n\t\tvar tab_employee_criteria_column1 = tab_employee_criteria.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[2] = [];\n\n\t\tthis.edit_view_tabs[2].push( tab_employee_criteria_column1 );\n\n\t\t// Employee Criteria\n\t\tvar v_box = $( '
' );\n\n\t\t//Selection Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'user_group_selection_type_id' } );\n\t\tform_item_input.setSourceData( $this.user_group_selection_type_array );\n\n\t\tvar form_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Selection Type' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Selection\n\t\tvar form_item_input_1 = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input_1.AComboBox( {\n\t\t\ttree_mode: true,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_tree_column',\n\t\t\tset_empty: true,\n\t\t\tfield: 'user_group_ids'\n\t\t} );\n\t\tform_item_input_1.setSourceData( $this.user_group_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Selection' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Employee Groups' ), [form_item_input, form_item_input_1], tab_employee_criteria_column1, '', v_box, false, true );\n\n\t\t// User Titles\n\t\tv_box = $( '
' );\n\n\t\t//Selection Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'user_title_selection_type_id', set_empty: false } );\n\t\tform_item_input.setSourceData( $this.user_title_selection_type_id_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Selection Type' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Selection\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.UserTitle,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_user_title',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'user_title_ids'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Selection' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Employee Titles' ), [form_item_input, form_item_input_1], tab_employee_criteria_column1, '', v_box, false, true );\n\n\t\t//Branches\n\t\tv_box = $( '
' );\n\t\t//Selection Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'user_branch_selection_type_id' } );\n\t\tform_item_input.setSourceData( $this.user_branch_selection_type_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Selection Type' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Selection\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.APIBranch,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_branch',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'user_branch_ids'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Selection' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Punch Branches' ), [form_item_input, form_item_input_1], tab_employee_criteria_column1, '', v_box, false, true );\n\n\t\t// Departments\n\t\tv_box = $( '
' );\n\t\t// Selection Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'user_department_selection_type_id' } );\n\t\tform_item_input.setSourceData( $this.user_department_selection_type_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Selection Type' ) );\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Selection\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.APIDepartment,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_department',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'user_department_ids'\n\t\t} );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Selection' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Punch Departments' ), [form_item_input, form_item_input_1], tab_employee_criteria_column1, '', v_box, false, true );\n\n\t\t// Include 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: 'include_user_ids'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Include Employees' ), form_item_input, tab_employee_criteria_column1 );\n\n\t\t// Exclude 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: 'exclude_user_ids'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Exclude Employees' ), form_item_input, tab_employee_criteria_column1, '' );\n\n\t\tvar tab_task_criteria = this.edit_view_tab.find( '#tab_task_criteria' );\n\n\t\tvar tab_task_criteria_column1 = tab_task_criteria.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[3] = [];\n\n\t\tthis.edit_view_tabs[3].push( tab_task_criteria_column1 );\n\n\t\t// Task Groups\n\t\tv_box = $( '
' );\n\n\t\t//Selection Type\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'job_item_group_selection_type_id' } );\n\t\tform_item_input.setSourceData( $this.job_item_group_selection_type_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input, $.i18n._( 'Selection Type' ) );\n\n\t\tv_box.append( form_item );\n\t\tv_box.append( '
' );\n\n\t\t//Selection\n\t\tform_item_input_1 = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\n\t\tform_item_input_1.AComboBox( {\n\t\t\ttree_mode: true,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_tree_column',\n\t\t\tset_empty: true,\n\t\t\tfield: 'job_item_group_ids'\n\t\t} );\n\t\tform_item_input_1.setSourceData( $this.job_item_group_array );\n\n\t\tform_item = this.putInputToInsideFormItem( form_item_input_1, $.i18n._( 'Selection' ) );\n\n\t\tv_box.append( form_item );\n\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Task Groups' ), [form_item_input, form_item_input_1], tab_task_criteria_column1, '', v_box, false, true );\n\n\t\t// Include Tasks\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIJobItem,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_job_item',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'include_job_item_ids'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Include Tasks' ), form_item_input, tab_task_criteria_column1 );\n\n\t\t// Exclude Tasks\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_BOX );\n\t\tform_item_input.AComboBox( {\n\t\t\tapi_class: TTAPI.APIJobItem,\n\t\t\tallow_multiple_selection: true,\n\t\t\tlayout_name: 'global_job_item',\n\t\t\tshow_search_inputs: true,\n\t\t\tset_empty: true,\n\t\t\tfield: 'exclude_job_item_ids'\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Exclude Tasks' ), form_item_input, tab_task_criteria_column1, '' );\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._( 'Status' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'status_id',\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_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._( 'Code' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'manual_id',\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_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._( '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: true,\n\t\t\t\tform_item_type: FormItemType.TEXT_INPUT\n\t\t\t} ),\n\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\tmultiple: true,\n\t\t\t\tbasic_search: false,\n\t\t\t\tadv_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._( 'Supervisor' ),\n\t\t\t\tin_column: 1,\n\t\t\t\tfield: 'supervisor',\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: false,\n\t\t\t\tadv_search: true,\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._( 'Tags' ),\n\t\t\t\tfield: 'tag',\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: true,\n\t\t\t\tin_column: 1,\n\t\t\t\tobject_type_id: 600,\n\t\t\t\tform_item_type: FormItemType.TAG_INPUT\n\t\t\t} ),\n\n\t\t\tnew SearchField( {\n\t\t\t\tlabel: $.i18n._( 'Group' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tmultiple: true,\n\t\t\t\tfield: 'group_id',\n\t\t\t\tlayout_name: 'global_tree_column',\n\t\t\t\ttree_mode: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: true,\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._( 'Branch' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tfield: 'branch_id',\n\t\t\t\tlayout_name: 'global_branch',\n\t\t\t\tapi_class: TTAPI.APIBranch,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: true,\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._( 'Department' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tfield: 'department_id',\n\t\t\t\tlayout_name: 'global_department',\n\t\t\t\tapi_class: TTAPI.APIDepartment,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: true,\n\t\t\t\tadv_search: true,\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._( 'Client' ),\n\t\t\t\tin_column: 2,\n\t\t\t\tfield: 'client_id',\n\t\t\t\tlayout_name: 'global_client',\n\t\t\t\tapi_class: TTAPI.APIClient,\n\t\t\t\tmultiple: true,\n\t\t\t\tbasic_search: false,\n\t\t\t\tadv_search: true,\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._( '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: false,\n\t\t\t\tadv_search: true,\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: false,\n\t\t\t\tadv_search: true,\n\t\t\t\tform_item_type: FormItemType.AWESOME_BOX\n\t\t\t} )\n\t\t];\n\t}\n\n\tcheckTabPermissions( tab ) {\n\t\tvar retval = false;\n\n\t\tswitch ( tab ) {\n\t\t\tcase 'tab_task_amendments':\n\t\t\t\tif ( PermissionManager.validate( 'job_item', 'edit' ) || PermissionManager.validate( 'job_item', 'edit_child' ) || PermissionManager.validate( 'job_item', 'edit_own' ) ) {\n\t\t\t\t\tretval = true;\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tretval = super.checkTabPermissions( tab );\n\t\t\t\tbreak;\n\t\t}\n\n\t\treturn retval;\n\t}\n\n\tinitSubJobItemAmendmentView() {\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_job_item_amendment_view_controller ) {\n\t\t\tthis.sub_job_item_amendment_view_controller.buildContextMenu( true );\n\t\t\tthis.sub_job_item_amendment_view_controller.setDefaultMenu();\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_key = 'job_id';\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_value = $this.current_edit_record.id;\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_edit_record = $this.current_edit_record;\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_view_controller = $this;\n\t\t\t$this.sub_job_item_amendment_view_controller.initData();\n\t\t\treturn;\n\t\t}\n\n\t\tGlobal.loadScript( 'views/attendance/job_item_amendment/JobItemAmendmentViewController.js', function() {\n\t\t\tvar tab_employee_criteria = $this.edit_view_tab.find( '#tab_task_amendments' );\n\t\t\tvar firstColumn = tab_employee_criteria.find( '.first-column-sub-view' );\n\t\t\tGlobal.trackView( 'Sub' + 'JobItemAmendment' + 'View' );\n\t\t\tJobItemAmendmentViewController.loadSubView( firstColumn, beforeLoadView, afterLoadView );\n\n\t\t} );\n\n\t\tfunction beforeLoadView() {\n\n\t\t}\n\n\t\tfunction afterLoadView( subViewController ) {\n\t\t\t$this.sub_job_item_amendment_view_controller = subViewController;\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_key = 'job_id';\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_value = $this.current_edit_record.id;\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_edit_record = $this.current_edit_record;\n\t\t\t$this.sub_job_item_amendment_view_controller.parent_view_controller = $this;\n\t\t\t$this.sub_job_item_amendment_view_controller.initData();\n\t\t}\n\t}\n\n\tsetCurrentEditRecordData() {\n\n\t\t// When mass editing, these fields may not be the common data, so their value will be undefined, so this will cause their change event cannot work properly.\n\t\tthis.setDefaultData( {\n\t\t\t'user_branch_selection_type_id': 10,\n\t\t\t'user_department_selection_type_id': 10,\n\t\t\t'user_group_selection_type_id': 10,\n\t\t\t'job_item_group_selection_type_id': 10\n\t\t} );\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\tcase 'country': //popular case\n\t\t\t\t\t\tif ( !this.current_edit_record[key] ) {\n\t\t\t\t\t\t\tthis.current_edit_record[key] = LocalCacheData.getCurrentCompany().country;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tthis.eSetProvince( this.current_edit_record[key] );\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\tcase 'province':\n\t\t\t\t\t\tif ( !this.current_edit_record[key] ) {\n\t\t\t\t\t\t\tthis.current_edit_record[key] = LocalCacheData.getCurrentCompany().province;\n\t\t\t\t\t\t}\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\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\t\t\t}\n\t\t}\n\n\t\tthis.collectUIDataToCurrentEditRecord();\n\t\tthis.setEditViewDataDone();\n\t}\n\n\tsetEditViewDataDone() {\n\t\tsuper.setEditViewDataDone();\n\t\tthis.onEmployeeGroupSelectionTypeChange();\n\t\tthis.onEmployeeTitleSelectionTypeChange();\n\t\tthis.onBranchSelectionTypeChange();\n\t\tthis.onDepartmentSelectionTypeChange();\n\t\tthis.isDisableIncludeEmployees();\n\t\tthis.onJobItemGroupSelectionTypeChange();\n\t\tthis.isDisableIncludeTasks();\n\t}\n\n\tonFormItemChange( target, doNotValidate ) {\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\tswitch ( key ) {\n\t\t\tcase 'country':\n\t\t\t\tvar widget = this.edit_view_ui_dic['province'];\n\t\t\t\twidget.setValue( null );\n\t\t\t\tbreak;\n\t\t}\n\n\t\tthis.current_edit_record[key] = c_value;\n\n\t\tif ( key === 'country' ) {\n\t\t\tthis.onCountryChange();\n\t\t}\n\t\tif ( key === 'user_group_selection_type_id' ) {\n\t\t\tthis.onEmployeeGroupSelectionTypeChange();\n\t\t}\n\t\tif ( key === 'user_title_selection_type_id' ) {\n\t\t\tthis.onEmployeeTitleSelectionTypeChange();\n\t\t}\n\t\tif ( key === 'user_branch_selection_type_id' ) {\n\t\t\tthis.onBranchSelectionTypeChange();\n\t\t}\n\t\tif ( key === 'user_department_selection_type_id' ) {\n\t\t\tthis.onDepartmentSelectionTypeChange();\n\t\t}\n\t\tif ( key === 'job_item_group_selection_type_id' ) {\n\t\t\tthis.onJobItemGroupSelectionTypeChange();\n\t\t}\n\t\tthis.isDisableIncludeEmployees();\n\t\tthis.isDisableIncludeTasks();\n\t\tif ( !doNotValidate ) {\n\t\t\tthis.validate();\n\t\t}\n\t}\n\n\teSetProvince( val, refresh ) {\n\t\tvar $this = this;\n\t\tvar province_widget = $this.edit_view_ui_dic['province'];\n\n\t\tif ( !val || val === '-1' || val === '0' ) {\n\t\t\t$this.e_province_array = [];\n\t\t\tprovince_widget.setSourceData( [] );\n\t\t} else {\n\t\t\tthis.company_api.getOptions( 'province', val, {\n\t\t\t\tonResult: function( res ) {\n\t\t\t\t\tres = res.getResult();\n\t\t\t\t\tif ( !res ) {\n\t\t\t\t\t\tres = [];\n\t\t\t\t\t}\n\t\t\t\t\t$this.e_province_array = Global.buildRecordArray( res );\n\t\t\t\t\tif ( refresh && $this.e_province_array.length > 0 ) {\n\t\t\t\t\t\t$this.current_edit_record.province = $this.e_province_array[0].value;\n\t\t\t\t\t\tprovince_widget.setValue( $this.current_edit_record.province );\n\t\t\t\t\t}\n\t\t\t\t\tprovince_widget.setSourceData( $this.e_province_array );\n\n\t\t\t\t}\n\t\t\t} );\n\t\t}\n\t}\n\n\tisDisableIncludeEmployees() {\n\t\tif ( this.edit_view_ui_dic['user_group_ids'].getEnabled() || this.edit_view_ui_dic['user_branch_ids'].getEnabled() || this.edit_view_ui_dic['user_department_ids'].getEnabled() ) {\n\t\t\tthis.edit_view_ui_dic['include_user_ids'].setEnabled( true );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['include_user_ids'].setEnabled( false );\n\t\t}\n\t}\n\n\tisDisableIncludeTasks() {\n\t\tif ( this.edit_view_ui_dic['job_item_group_ids'].getEnabled() ) {\n\t\t\tthis.edit_view_ui_dic['include_job_item_ids'].setEnabled( true );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['include_job_item_ids'].setEnabled( false );\n\t\t}\n\t}\n\n\tonEmployeeGroupSelectionTypeChange() {\n\t\tif ( this.current_edit_record['user_group_selection_type_id'] == 10 ) {\n\t\t\tthis.edit_view_ui_dic['user_group_ids'].setEnabled( false );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['user_group_ids'].setEnabled( true );\n\t\t}\n\t}\n\n\tonEmployeeTitleSelectionTypeChange() {\n\t\tif ( this.current_edit_record['user_title_selection_type_id'] == 10 ) {\n\t\t\tthis.edit_view_ui_dic['user_title_ids'].setEnabled( false );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['user_title_ids'].setEnabled( true );\n\t\t}\n\t}\n\n\tonBranchSelectionTypeChange() {\n\t\tif ( this.current_edit_record['user_branch_selection_type_id'] == 10 ) {\n\t\t\tthis.edit_view_ui_dic['user_branch_ids'].setEnabled( false );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['user_branch_ids'].setEnabled( true );\n\t\t}\n\t}\n\n\tonDepartmentSelectionTypeChange() {\n\t\tif ( this.current_edit_record['user_department_selection_type_id'] == 10 ) {\n\t\t\tthis.edit_view_ui_dic['user_department_ids'].setEnabled( false );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['user_department_ids'].setEnabled( true );\n\t\t}\n\t}\n\n\tonJobItemGroupSelectionTypeChange() {\n\t\tif ( this.current_edit_record['job_item_group_selection_type_id'] == 10 ) {\n\t\t\tthis.edit_view_ui_dic['job_item_group_ids'].setEnabled( false );\n\t\t} else {\n\t\t\tthis.edit_view_ui_dic['job_item_group_ids'].setEnabled( true );\n\t\t}\n\t}\n\n\tgetFilterColumnsFromDisplayColumns( column_filter, enable_system_columns ) {\n\t\tif ( column_filter == undefined ) {\n\t\t\tcolumn_filter = {};\n\t\t}\n\t\tcolumn_filter.latitude = true;\n\t\tcolumn_filter.longitude = true;\n\t\treturn this._getFilterColumnsFromDisplayColumns( column_filter, enable_system_columns );\n\t}\n\n}\n//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMTA4OC5qcyIsIm1hcHBpbmdzIjoiOzs7Ozs7QUFBTztBQUNQLDJCQUEyQjtBQUMzQixFQUFFLENBQUM7QUFDSDs7QUFFQTtBQUNBO0FBQ0EsT0FBTztBQUNQOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTs7QUFFQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBOztBQUVBOztBQUVBO0FBQ0EsSUFBSTs7QUFFSjtBQUNBOztBQUVBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsMkJBQTJCLENBQUM7QUFDNUIsMEJBQTBCLENBQUM7O0FBRTNCO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7Q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