1 line
44 KiB
JavaScript
1 line
44 KiB
JavaScript
"use strict";(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["company-permission_control-PermissionControlViewController"],{5448:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"PermissionControlViewController\": () => (/* binding */ PermissionControlViewController)\n/* harmony export */ });\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\nclass PermissionControlViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#permission_control_view_container',\n\n\n\n\t\t\tlevel_array: null,\n\t\t\tuser_api: null,\n\t\t\tpermission_array: null,\n\n\t\t\tquick_search_dic: {},\n\n\t\t\t//Save multi key typed when quick search\n\t\t\tquick_search_typed_keys: '',\n\n\t\t\t//use to juedge if need to clear quick_search_this.quick_search_typed_keyss\n\t\t\tquick_search_timer: 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 = 'PermissionControlEditView.html';\n\t\tthis.permission_id = 'permission';\n\t\tthis.viewId = 'PermissionControl';\n\t\tthis.script_name = 'PermissionControlView';\n\t\tthis.table_name_key = 'permission_control';\n\t\tthis.context_menu_name = $.i18n._( 'Permission Group' );\n\t\tthis.navigation_label = $.i18n._( 'Permission Group' );\n\t\tthis.api = TTAPI.APIPermissionControl;\n\t\tthis.user_api = TTAPI.APIUser;\n\n\t\tthis.render();\n\t\tthis.buildContextMenu();\n\n\t\tthis.initData();\n\t}\n\n\tonKeyDown( e ) {\n\t\tvar focus = $( ':focus' );\n\t\tvar $this = this;\n\n\t\tif ( this.edit_view_tab_selected_index === 0 && !LocalCacheData.openAwesomeBox &&\n\t\t\t( focus.length < 1 || focus[0].localName !== 'input' ) ) {\n\t\t\tvar a_dropdown = this.edit_view_ui_dic.permission;\n\n\t\t\tif ( e.keyCode === 39 ) { //right\n\n\t\t\t\te.preventDefault();\n\n\t\t\t\tif ( a_dropdown.getAllowMultipleSelection() ) {\n\n\t\t\t\t\ta_dropdown.onUnSelectGridDoubleClick();\n\t\t\t\t}\n\t\t\t} else if ( e.keyCode === 37 ) { //left\n\n\t\t\t\te.preventDefault();\n\n\t\t\t\tif ( a_dropdown.getAllowMultipleSelection() ) {\n\n\t\t\t\t\ta_dropdown.onSelectGridDoubleClick();\n\t\t\t\t}\n\t\t\t} else {\n\n\t\t\t\tif ( e.keyCode === 16 ||\n\t\t\t\t\te.keyCode === 17 ||\n\t\t\t\t\te.keyCode === 91 ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tif ( this.quick_search_timer ) {\n\t\t\t\t\tclearTimeout( this.quick_search_timer );\n\t\t\t\t}\n\n\t\t\t\tthis.quick_search_timer = setTimeout( function() {\n\t\t\t\t\t$this.quick_search_typed_keys = '';\n\t\t\t\t}, 200 );\n\n\t\t\t\te.preventDefault();\n\t\t\t\tvar target_grid;\n\t\t\t\tvar next_index;\n\t\t\t\tvar next_select_item;\n\t\t\t\tthis.quick_search_typed_keys = this.quick_search_typed_keys + Global.KEYCODES[e.which];\n\n\t\t\t\tif ( a_dropdown.getAllowMultipleSelection() || a_dropdown.getTreeMode() ) {\n\t\t\t\t\tif ( this.quick_search_typed_keys ) {\n\t\t\t\t\t\ttarget_grid = a_dropdown.getFocusInSeletGrid() ? a_dropdown.getSelectGrid() : a_dropdown.getUnSelectGrid();\n\t\t\t\t\t\tvar search_index = this.quick_search_dic[this.quick_search_typed_keys] ? this.quick_search_dic[this.quick_search_typed_keys] : 0;\n\t\t\t\t\t\tvar tds = $( target_grid.grid.find( 'tr' ).find( 'td:eq(1)' ).filter( function() {\n\t\t\t\t\t\t\treturn $.text( [this] ).toLowerCase().indexOf( $this.quick_search_typed_keys ) == 0;\n\t\t\t\t\t\t} ) );\n\n\t\t\t\t\t\tvar td;\n\t\t\t\t\t\tif ( search_index > 0 && search_index < tds.length ) {\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsearch_index = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\ttd = $( tds[search_index] );\n\n\t\t\t\t\t\ta_dropdown.unSelectAll( target_grid, true );\n\n\t\t\t\t\t\tnext_index = td.parent().index() - 1;\n\t\t\t\t\t\tnext_select_item = target_grid.grid.jqGrid( 'getGridParam', 'data' )[next_index];\n\t\t\t\t\t\ta_dropdown.setSelectItem( next_select_item, target_grid );\n\t\t\t\t\t\tthis.quick_search_dic = {};\n\t\t\t\t\t\tthis.quick_search_dic[this.quick_search_typed_keys] = search_index + 1;\n\t\t\t\t\t}\n\n\t\t\t\t} else {\n\t\t\t\t\tif ( this.quick_search_typed_keys ) {\n\t\t\t\t\t\tsearch_index = this.quick_search_dic[this.quick_search_typed_keys] ? this.quick_search_dic[this.quick_search_typed_keys] : 0;\n\t\t\t\t\t\ttds = $( a_dropdown.getUnSelectGrid().find( 'tr' ).find( 'td:first' ).filter( function() {\n\t\t\t\t\t\t\treturn $.text( [this] ).toLowerCase().indexOf( $this.quick_search_typed_keys ) == 0;\n\t\t\t\t\t\t} ) );\n\t\t\t\t\t\tif ( search_index > 0 && search_index < tds.length ) {\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsearch_index = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\ttd = $( tds[search_index] );\n\n\t\t\t\t\t\tnext_index = td.parent().index() - 1;\n\t\t\t\t\t\tnext_select_item = this.getItemByIndex( next_index );\n\t\t\t\t\t\ta_dropdown.setSelectItem( next_select_item );\n\n\t\t\t\t\t\tthis.quick_search_dic = {};\n\t\t\t\t\t\tthis.quick_search_dic[this.quick_search_typed_keys] = search_index + 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t}\n\n\tsetSubLogViewFilter() {\n\t\tif ( !this.sub_log_view_controller ) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis.sub_log_view_controller.getSubViewFilter = function( filter ) {\n\t\t\tfilter['table_name_object_id'] = {\n\t\t\t\t'permission_user': [this.parent_edit_record.id],\n\t\t\t\t'permission': [this.parent_edit_record.id],\n\t\t\t\t'permission_control': [this.parent_edit_record.id]\n\t\t\t};\n\n\t\t\treturn filter;\n\t\t};\n\n\t\treturn true;\n\t}\n\n\tgetCustomContextMenuModel() {\n\t\tvar context_menu_model = {\n\t\t\texclude: ['mass_edit'],\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: '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._( 'Permission Wizard' ),\n\t\t\t\t\tid: 'permission_wizard',\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\tsetEditViewTabHeight() {\n\t\tsuper.setEditViewTabHeight();\n\n\t\tvar permission_grid = this.edit_view_ui_dic.permission;\n\n\t\tpermission_grid.setHeight( ( this.edit_view_tab.find( '.context-border' ).height() - permission_grid[0].getBoundingClientRect().top ) - 80 );\n\t}\n\n\tonCustomContextClick( context_menu_id ) {\n\n\t\tvar $this = this;\n\n\t\t$this.current_edit_record.permission = this.buildAPIFormPermissionResult();\n\n\t\tif ( $.type( $this.current_edit_record.permission ) !== 'array' ) {\n\t\t\t$this.current_edit_record.permission = [];\n\t\t}\n\n\t\tswitch ( context_menu_id ) {\n\t\t\tcase 'permission_wizard':\n\t\t\t\tIndexViewController.openWizard( 'PermissionWizard', null, function( result, action ) {\n\t\t\t\t\tif ( result ) {\n\n\t\t\t\t\t\tswitch ( action ) {\n\t\t\t\t\t\t\tcase 'allow':\n\t\t\t\t\t\t\t\tvar new_permission_array = $this.convertPermissionData( result );\n\t\t\t\t\t\t\t\t//Issue #2954 - Attempt to fix: Uncaught TypeError: i.current_edit_record.permission.concat is not a function\n\t\t\t\t\t\t\t\tif ( !Array.isArray( $this.current_edit_record.permission ) ) {\n\t\t\t\t\t\t\t\t\t$this.current_edit_record.permission = [];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$this.current_edit_record.permission = $this.current_edit_record.permission.concat( new_permission_array );\n\t\t\t\t\t\t\t\t$this.removeDuplicatePermission();\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setValue( $this.current_edit_record.permission );\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setSelectGridHighlight( new_permission_array );\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'highlight':\n\t\t\t\t\t\t\t\tnew_permission_array = $this.convertPermissionData( result );\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setSelectGridHighlight( new_permission_array );\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setUnSelectGridHighlight( new_permission_array );\n\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'deny':\n\t\t\t\t\t\t\t\tnew_permission_array = $this.convertPermissionData( result );\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setSelectGridHighlight( new_permission_array );\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.moveItems( false, new_permission_array );\n\n\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.permission.setUnSelectGridHighlight( new_permission_array );\n\n\t\t\t\t\t\t\t\t$this.current_edit_record.permission = $this.edit_view_ui_dic.permission.getValue();\n\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\t\t\t\t} );\n\t\t}\n\t}\n\n\tremoveDuplicatePermission() {\n\t\tvar new_array = [];\n\t\t$.each( this.current_edit_record.permission, function( i, el ) {\n\t\t\tif ( $.inArray( el, new_array ) === -1 ) {\n\t\t\t\tnew_array.push( el );\n\t\t\t}\n\t\t} );\n\n\t\tthis.current_edit_record.permission = new_array;\n\t}\n\n\tbuildPermissionArray( result, valueOnly ) {\n\n\t\tvar arr = [];\n\t\tvar val_array = [];\n\t\tvar id = 1000;\n\t\tfor ( var key in result ) {\n\t\t\tvar sArr = [];\n\t\t\tfor ( var cKey in result[key] ) {\n\t\t\t\tvar item = result[key];\n\t\t\t\tvar resItem = {};\n\t\t\t\tresItem.value = key + '->' + cKey;\n\t\t\t\tval_array.push( resItem.value );\n\t\t\t\tresItem.sortKey = key;\n\t\t\t\tresItem.label = item[cKey];\n\t\t\t\tresItem.id = resItem.value;\n\t\t\t\tsArr.push( resItem );\n\t\t\t\tid++;\n\t\t\t}\n\n\t\t\tarr = arr.concat( sArr );\n\t\t}\n\n\t\tarr.sort( function( a, b ) {\n\t\t\treturn Global.compare( a, b, 'label' );\n\t\t} );\n\n\t\tif ( !valueOnly ) {\n\t\t\treturn arr;\n\t\t} else {\n\t\t\treturn val_array;\n\t\t}\n\t}\n\n\tinitOptions() {\n\t\tvar $this = this;\n\n\t\tthis.initDropDownOption( 'level', 'level' );\n\t\tthis.api.getPermissionOptions( {\n\t\t\tonResult: function( res ) {\n\t\t\t\tres = res.getResult();\n\t\t\t\tres = $this.buildPermissionArray( res );\n\t\t\t\t$this.permission_array = res;\n\n\t\t\t}\n\t\t} );\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\tcase 'permission':\n\t\t\t\t\t\tif ( this.current_edit_record.permission ) {\n\t\t\t\t\t\t\tthis.current_edit_record.permission = this.convertPermissionData( this.current_edit_record.permission );\n\t\t\t\t\t\t\twidget.setValue( this.current_edit_record.permission );\n\t\t\t\t\t\t}\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\t\tthis.collectUIDataToCurrentEditRecord();\n\t\tthis.edit_view_ui_dic.permission.setGridColumnsWidths();\n\t\tthis.setEditViewDataDone();\n\t}\n\n\tconvertPermissionData( permission ) {\n\n\t\tvar result = [];\n\t\tfor ( var key in permission ) {\n\t\t\tvar ar = [];\n\t\t\tfor ( var cKey in permission[key] ) {\n\t\t\t\tif ( permission[key][cKey] === true ) {\n\t\t\t\t\tar.push( key + '->' + cKey );\n\t\t\t\t}\n\t\t\t}\n\t\t\tresult = result.concat( ar );\n\t\t}\n\n\t\treturn result;\n\t}\n\n\tbuildSelectItems() {\n\n\t\tvar items = [];\n\t\tvar len = this.permission_array.length;\n\n\t\tfor ( var key in this.current_edit_record.permission ) {\n\t\t\tvar select_value = this.current_edit_record.permission[key];\n\t\t\tfor ( var i = 0; i < len; i++ ) {\n\t\t\t\tvar item = this.permission_array[i];\n\t\t\t\tif ( select_value === item.value ) {\n\t\t\t\t\titems.push( item );\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn items;\n\t}\n\n\tbuildEditViewUI() {\n\n\t\tsuper.buildEditViewUI();\n\n\t\tvar $this = this;\n\n\t\tthis.edit_view.children().eq( 0 ).css( 'min-width', 1170 );\n\n\t\tvar tab_model = {\n\t\t\t'tab_permission_group': {\n\t\t\t\t'label': $.i18n._( 'Permission Group' )\n\t\t\t},\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.APIPermissionControl,\n\t\t\tid: this.script_name + '_navigation',\n\t\t\tallow_multiple_selection: false,\n\t\t\tlayout_name: 'global_permission_control',\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_permission_group = this.edit_view_tab.find( '#tab_permission_group' );\n\n\t\tvar tab_permission_group_column1 = tab_permission_group.find( '.first-column' );\n\n\t\tthis.edit_view_tabs[0] = [];\n\n\t\tthis.edit_view_tabs[0].push( tab_permission_group_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_permission_group_column1, '' );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Description\n\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_permission_group_column1 );\n\n\t\tform_item_input.parent().width( '45%' );\n\n\t\t// Level\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COMBO_BOX );\n\t\tform_item_input.TComboBox( { field: 'level' } );\n\t\tform_item_input.setSourceData( $this.level_array );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Level' ), form_item_input, tab_permission_group_column1 );\n\n\t\t//Employee\n\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_permission_group_column1, '' );\n\n\t\t//Permissions\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.AWESOME_DROPDOWN );\n\n\t\tvar display_columns = ALayoutCache.getDefaultColumn( 'global_option_column' ); //Get Default columns base on different layout name\n\t\tdisplay_columns = Global.convertColumnsTojGridFormat( display_columns, 'global_option_column' ); //Convert to jQgrid format\n\n\t\tform_item_input.ADropDown( {\n\t\t\tfield: 'permission',\n\t\t\tdisplay_show_all: false,\n\t\t\tid: 'permission_dropdown',\n\t\t\tkey: 'value',\n\t\t\tallow_drag_to_order: false,\n\t\t\tdisplay_close_btn: false,\n\t\t\tauto_sort: true,\n\t\t\tdisplay_column_settings: false,\n\t\t\tdefault_height: ( this.edit_view_tab.height() - 325 ),\n\t\t\tshow_search_inputs: true\n\t\t} );\n\t\tform_item_input.addClass( 'splayed-adropdown' );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'Permissions' ), form_item_input, tab_permission_group_column1, '', null, true, true );\n\n\t\tform_item_input.setColumns( display_columns );\n\t\tform_item_input.setUnselectedGridData( this.permission_array );\n\t}\n\n\t_continueDoCopyAsNew() {\n\t\t//Issue #3206 - Copy as new causes selected permissions to be lost\n\t\t//Overriding this function to make sure uniformVariable is called, otherwise permission data will be\n\t\t//in the wrong format when setCurrentEditRecord is called. onSaveAndNew() calls uniformVariable() however copyAsNew() does not.\n\t\tif ( this.is_viewing || this.is_edit ) {\n\t\t\tthis.uniformVariable( this.current_edit_record );\n\t\t}\n\t\tsuper._continueDoCopyAsNew();\n\t}\n\n\tonSaveDone( result ) {\n\t\tif ( Array.isArray( this.current_edit_record.user ) && this.current_edit_record.user.includes( LocalCacheData.getLoginUser().id ) ) {\n\t\t\tGlobal.refreshPermissions();\n\t\t}\n\t\tsuper.onSaveDone( result );\n\t}\n\n\tuniformVariable( records ) {\n\n\t\trecords.permission = this.buildAPIFormPermissionResult();\n\t\treturn records;\n\t}\n\n\tbuildAPIFormPermissionResult() {\n\n\t\tvar val = this.edit_view_ui_dic.permission.getValue();\n\t\tvar permission = {};\n\n\t\tvar key = '';\n\t\tfor ( var i = 0; i < val.length; i++ ) {\n\t\t\tvar item = val[i].value;\n\t\t\tkey = item.split( '->' )[0];\n\n\t\t\tif ( !permission[key] ) {\n\t\t\t\tpermission[key] = {};\n\t\t\t}\n\n\t\t\tpermission[key][item.split( '->' )[1]] = true;\n\n\t\t}\n\n\t\treturn permission;\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\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._( '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\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._( '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\tsetDefaultMenuPermissionWizardIcon( context_btn, pId ) {\n\t\tContextMenuManager.hideMenuItem( this.determineCont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