(self.webpackChunktimetrex=self.webpackChunktimetrex||[]).push([["developer_tools-WidgetTestViewController","filebrowser-TImage","filebrowser-TImageAdvBrowser","switch_button-SwitchButton"],{1469:(__unused_webpack_module,__unused_webpack_exports,__webpack_require__)=>{eval("/* provided dependency */ var jQuery = __webpack_require__(9755);\n( function( $ ) {\n\n\t$.fn.TImage = function( options ) {\n\n\t\tGlobal.addCss( 'global/widgets/filebrowser/TImageBrowser.css' );\n\t\tvar opts = $.extend( {}, $.fn.TImage.defaults, options );\n\n\t\tvar $this = this;\n\t\tvar field;\n\n\t\tthis.clearErrorStyle = function() {\n\n\t\t};\n\n\t\tthis.getField = function() {\n\t\t\treturn field;\n\t\t};\n\n\t\tthis.getValue = function() {\n\t\t\treturn null;\n\t\t};\n\n\t\tthis.setValue = function( val ) {\n\t\t\tif ( !val ) {\n\t\t\t\tthis.attr( 'src', '' );\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tvar d = new Date();\n\t\t\tthis.attr( 'src', val + '&t=' + d.getTime() );\n\n\t\t};\n\n\t\tthis.each( function() {\n\n\t\t\tvar o = $.meta ? $.extend( {}, opts, $( this ).data() ) : opts;\n\n\t\t\tfield = o.field;\n\n\t\t} );\n\n\t\treturn this;\n\n\t};\n\n\t$.fn.TImage.defaults = {};\n\n\t$( document ).on( 'mouseover', '.file-browser img', function( e ) {\n\t\tvar $this_image_widget = $( e.target ).parents( '.file-browser' );\n\n\t\tif ( !$( '.file_browser_overlay' )[0] && $( e.target ).attr( 'enable-delete' ) == 1 ) {\n\t\t\tvar height = $( e.target ).height();\n\t\t\tvar top = ( height - 32 ) / 2;\n\t\t\tvar left = top;\n\n\t\t\tvar file_browser_overlay = $( '
' );\n\t\t\tfile_browser_overlay.css( 'position', 'absolute' );\n\t\t\tfile_browser_overlay.css( 'top', '0px' );\n\t\t\tfile_browser_overlay.css( 'left', '0' );\n\t\t\tfile_browser_overlay.css( 'cursor', 'pointer' );\n\t\t\tfile_browser_overlay.css( 'height', height + 'px' );\n\t\t\tfile_browser_overlay.css( 'width', '100%' );\n\t\t\tfile_browser_overlay.css( 'background', 'rgba(255,255,255,0.85)' );\n\n\t\t\t$( e.target ).parents( '.file-browser' ).append( file_browser_overlay );\n\n\t\t\t$( document ).on( 'click', '.file_browser_overlay', function( e ) {\n\t\t\t\tvar img_src = $( e.target ).parent().find( 'img' ).attr( 'src' );\n\t\t\t\tTAlertManager.showConfirmAlert( $.i18n._( 'This will permanently delete the image. Are you sure?' ), '', function( flag ) {\n\t\t\t\t\tif ( flag ) {\n\t\t\t\t\t\tvar e = { type: 'deleteClick', message: 'Delete image clicked.', time: new Date() };\n\t\t\t\t\t\t$this_image_widget.trigger( e );\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t} );\n\n\t\t\t$( document ).on( 'mouseleave', '.file-browser', function() {\n\t\t\t\t$( document ).off( 'click', '.file_browser_overlay' );\n\t\t\t\tif ( $( '.file_browser_overlay' )[0] ) {\n\t\t\t\t\tvar file_browser_overlay = $( this ).find( '.file_browser_overlay' );\n\t\t\t\t\tfile_browser_overlay.off().remove();\n\t\t\t\t}\n\t\t\t} );\n\t\t}\n\t} );\n\n} )( jQuery );//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMTQ2OS5qcyIsIm1hcHBpbmdzIjoiO0FBQUE7O0FBRUE7O0FBRUE7QUFDQSx5QkFBeUI7O0FBRXpCO0FBQ0E7O0FBRUE7O0FBRUE7O0FBRUE7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTs7QUFFQSxnQ0FBZ0M7O0FBRWhDOztBQUVBLElBQUk7O0FBRUo7O0FBRUE7O0FBRUE7O0FBRUE7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQSw0SUFBNEksV0FBVyxZQUFZLGtCQ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RlIHRoZSBpbWFnZS4gQXJlIHlvdSBzdXJlPycgKSwgJycsIGZ1bmN0aW9uKCBmbGFnICkge1xuXHRcdFx0XHRcdGlmICggZmxhZyApIHtcblx0XHRcdFx0XHRcdHZhciBlID0geyB0eXBlOiAnZGVsZXRlQ2xpY2snLCBtZXNzYWdlOiAnRGVsZXRlIGltYWdlIGNsaWNrZWQuJywgdGltZTogbmV3IERhdGUoKSB9O1xuXHRcdFx0XHRcdFx0JHRoaXNfaW1hZ2Vfd2lkZ2V0LnRyaWdnZXIoIGUgKTtcblx0XHRcdFx0XHR9XG5cdFx0XHRcdH0gKTtcblx0XHRcdH0gKTtcblxuXHRcdFx0JCggZG9jdW1lbnQgKS5vbiggJ21vdXNlbGVhdmUnLCAnLmZpbGUtYnJvd3NlcicsIGZ1bmN0aW9uKCkge1xuXHRcdFx0XHQkKCBkb2N1bWVudCApLm9mZiggJ2NsaWNrJywgJy5maWxlX2Jyb3dzZXJfb3ZlcmxheScgKTtcblx0XHRcdFx0aWYgKCAkKCAnLmZpbGVfYnJvd3Nlcl9vdmVybGF5JyApWzBdICkge1xuXHRcdFx0XHRcdHZhciBmaWxlX2Jyb3dzZXJfb3ZlcmxheSA9ICQoIHRoaXMgKS5maW5kKCAnLmZpbGVfYnJvd3Nlcl9vdmVybGF5JyApO1xuXHRcdFx0XHRcdGZpbGVfYnJvd3Nlcl9vdmVybGF5Lm9mZigpLnJlbW92ZSgpO1xuXHRcdFx0XHR9XG5cdFx0XHR9ICk7XG5cdFx0fVxuXHR9ICk7XG5cbn0gKSggalF1ZXJ5ICk7Il0sIm5hbWVzIjpbXSwic291cmNlUm9vdCI6IiJ9\n//# sourceURL=webpack-internal:///1469\n")},8243:(__unused_webpack_module,__unused_webpack_exports,__webpack_require__)=>{eval("/* provided dependency */ var jQuery = __webpack_require__(9755);\n( function( $ ) {\n\n\t$.fn.TImageAdvBrowser = function( options ) {\n\n\t\tGlobal.addCss( 'global/widgets/filebrowser/TImageBrowser.css' );\n\t\tvar opts = $.extend( {}, $.fn.TImageAdvBrowser.defaults, options );\n\n\t\tvar $this = this;\n\t\tvar field;\n\t\tvar name = 'filedata';\n\n\t\tvar accept_filter = '';\n\n\t\tvar default_width = 177;\n\t\tvar default_height = 42;\n\n\t\tvar callBack = null;\n\n\t\tvar enabled = true;\n\n\t\tvar image;\n\n\t\tvar result_form_data;\n\n\t\tthis.setEnable = function( val ) {\n\t\t\tenabled = val;\n\n\t\t\tvar btn = this.children().eq( 1 );\n\t\t\tif ( !val ) {\n\t\t\t\tbtn.hide();\n\t\t\t} else {\n\t\t\t\tbtn.show();\n\t\t\t}\n\n\t\t};\n\n\t\tthis.clearErrorStyle = function() {\n\n\t\t};\n\n\t\tthis.getField = function() {\n\t\t\treturn field;\n\t\t};\n\n\t\tthis.getValue = function() {\n\t\t\treturn result_form_data;\n\t\t};\n\n\t\tthis.setImage = function( val ) {\n\t\t\tif ( !val ) {\n\t\t\t\timage.attr( 'src', '' );\n\t\t\t\timage.hide();\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tvar d = new Date();\n\t\t\timage.hide();\n\t\t\timage.attr( 'src', val + '&t=' + d.getTime() + '&X-CSRF-Token=' + getCookie( 'CSRF-Token' ) );\n\t\t\timage.css( 'height', 'auto' );\n\t\t\timage.css( 'width', 'auto' );\n\n\t\t};\n\n\t\tthis.onImageLoad = function( image ) {\n\n\t\t\tvar image_height = $( image ).height() > 0 ? $( image ).height() : image.naturalHeight;\n\t\t\tvar image_width = $( image ).width() > 0 ? $( image ).width() : image.naturalWidth;\n\n\t\t\tif ( image_height > default_height ) {\n\t\t\t\t$( image ).css( 'height', default_height );\n\n\t\t\t}\n\n\t\t\tif ( image_width > default_width ) {\n\t\t\t\t$( image ).css( 'width', default_width );\n\t\t\t\t$( image ).css( 'height', 'auto' );\n\t\t\t}\n\n\t\t\t$this.trigger( 'setSize' );\n\n\t\t\tif ( image_height < 5 ) {\n\t\t\t\t$( image ).hide();\n\t\t\t} else {\n\t\t\t\t$( image ).show();\n\t\t\t}\n\n\t\t};\n\n\t\tthis.setValue = function( val ) {\n\n\t\t\tif ( !val ) {\n\t\t\t\tval = '';\n\t\t\t}\n\n\t\t};\n\n\t\tthis.setEnableDelete = function( val ) {\n\t\t\tvar image = $this.find( '.image' );\n\t\t\tif ( !val ) {\n\t\t\t\timage.removeAttr( 'enable-delete' );\n\t\t\t\treturn;\n\t\t\t} else {\n\t\t\t\timage.attr( 'enable-delete', 1 );\n\t\t\t}\n\t\t};\n\n\t\tthis.each( function() {\n\n\t\t\tvar o = $.meta ? $.extend( {}, opts, $( this ).data() ) : opts;\n\n\t\t\tfield = o.field;\n\n\t\t\tvar $$this = this;\n\n\t\t\t$( this ).find( '#upload_image' ).text( $.i18n._( 'Upload Image' ) );\n\n\t\t\tif ( o.callBack ) {\n\t\t\t\tcallBack = o.callBack;\n\t\t\t}\n\n\t\t\tif ( o.show_browser === false ) {\n\t\t\t\t$( this ).children().eq( 1 ).hide();\n\t\t\t}\n\n\t\t\tif ( o.default_width > 0 ) {\n\t\t\t\tdefault_width = o.default_width;\n\t\t\t}\n\n\t\t\tif ( o.default_height > 0 ) {\n\t\t\t\tdefault_height = o.default_height;\n\t\t\t}\n\n\t\t\tif ( Global.isSet( o.name ) ) {\n\t\t\t\tname = o.name;\n\t\t\t}\n\n\t\t\tif ( Global.isSet( accept_filter ) ) {\n\t\t\t\taccept_filter = o.accept_filter;\n\t\t\t}\n\n\t\t\tif ( Global.isSet( o.deleteImageHandler ) ) {\n\t\t\t\t$this.find( '.file-browser' ).on( 'deleteClick', function() {\n\t\t\t\t\to.deleteImageHandler();\n\t\t\t\t} );\n\n\t\t\t}\n\n\t\t\tvar browser = $( this ).children().eq( 1 );\n\t\t\tbrowser.bind( 'click', function() {\n\t\t\t\tIndexViewController.openWizard( 'UserPhotoWizard', null, function( form_data ) {\n\n\t\t\t\t\tif ( callBack ) {\n\t\t\t\t\t\tcallBack( form_data );\n\t\t\t\t\t}\n\n\t\t\t\t\tresult_form_data = form_data;\n\n\t\t\t\t} );\n\t\t\t} );\n\n\t\t\timage = $( this ).children().eq( 0 );\n\t\t\timage.on( 'load', function() {\n\t\t\t\t$this.onImageLoad( this );\n\t\t\t} );\n\n\t\t\timage.hide();\n\n\t\t} );\n\n\t\treturn this;\n\n\t};\n\n\t$.fn.TImageAdvBrowser.defaults = {};\n\t$.fn.TImageAdvBrowser.html_template = `\n\t\n\t\t
\n\t\t
\n\t
\n\t`;\n\n} )( jQuery );//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiODI0My5qcyIsIm1hcHBpbmdzIjoiO0FBQUE7O0FBRUE7O0FBRUE7QUFDQSx5QkFBeUI7O0FBRXpCO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTtBQUNBOztBQUVBOztBQUVBOztBQUVBOztBQUVBOztBQUVBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMO0FBQ0E7O0FBRUE7O0FBRUE7O0FBRUE7O0FBRUE7QUFDQTtBQUNBOztBQUVBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTs7QUFFQTtBQUNBOztBQUVBO0FBQ0E7O0FBRUE7O0FBRUE7QUFDQTtBQUNBO0FBQ0E7O0FBRUE7O0FBRUE7QUFDQTtBQUNBLEtBQUs7QUFDTDtBQUNBOztBQUVBOztBQUVBOztBQUVBO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EsS0FBSztBQUNMO0FBQ0E7QUFDQTs7QUFFQTs7QUFFQSxnQ0FBZ0M7O0FBRWhDOztBQUVBOztBQUVBOztBQUVBO0FBQ0E7QUFDQTs7QUFFQTtBQUNBO0FBQ0E7O0FBRUE7QUFDQTtBQU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XHQkdGhpcy5vbkltYWdlTG9hZCggdGhpcyApO1xuXHRcdFx0fSApO1xuXG5cdFx0XHRpbWFnZS5oaWRlKCk7XG5cblx0XHR9ICk7XG5cblx0XHRyZXR1cm4gdGhpcztcblxuXHR9O1xuXG5cdCQuZm4uVEltYWdlQWR2QnJvd3Nlci5kZWZhdWx0cyA9IHt9O1xuXHQkLmZuLlRJbWFnZUFkdkJyb3dzZXIuaHRtbF90ZW1wbGF0ZSA9IGBcblx0PGRpdiBjbGFzcz1cImZpbGUtYnJvd3NlclwiPlxuXHRcdDxpbWcgY2xhc3M9XCJpbWFnZVwiPlxuXHRcdDxidXR0b24gaWQ9XCJ1cGxvYWRfaW1hZ2VcIiBjbGFzcz1cInQtYnV0dG9uIGZpbGUtYnJvd3Nlci1idG5cIiBzdHlsZT1cImRpc3BsYXk6IGJsb2NrXCI+PC9idXR0b24+XG5cdDwvZGl2PlxuXHRgO1xuXG59ICkoIGpRdWVyeSApOyJdLCJuYW1lcyI6W10sInNvdXJjZVJvb3QiOiIifQ==\n//# sourceURL=webpack-internal:///8243\n")},6618:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{"use strict";eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"SwitchButtonIcon\": () => (/* binding */ SwitchButtonIcon)\n/* harmony export */ });\n/* provided dependency */ var jQuery = __webpack_require__(9755);\n( function( $ ) {\n\n\t$.fn.SwitchButton = function( options ) {\n\n\t\tGlobal.addCss( 'global/widgets/switch_button/SwitchButton.css' );\n\t\tvar opts = $.extend( {}, $.fn.SwitchButton.defaults, options );\n\n\t\tvar $this = this;\n\n\t\tvar btn = null;\n\n\t\tvar enabled = true;\n\n\t\tthis.getEnabled = function() {\n\t\t\treturn enabled;\n\t\t};\n\n\t\tthis.setEnable = function( val ) {\n\t\t\tenabled = val;\n\n\t\t\tif ( !val ) {\n\t\t\t\tthis.removeClass( 'disable-element' ).addClass( 'disable-element' );\n\t\t\t} else {\n\t\t\t\tthis.removeClass( 'disable-element' );\n\t\t\t}\n\n\t\t};\n\n\t\t//Error: TypeError: btn is null in /interface/html5/global/widgets/switch_button/SwitchButton.js?v=9.0.0-20150822-212724 line 31\n\t\tthis.getValue = function( return_number ) {\n\t\t\tif ( return_number ) {\n\t\t\t\treturn ( btn && btn.hasClass( 'selected' ) ) ? 1 : 0;\n\t\t\t} else {\n\t\t\t\treturn ( btn && btn.hasClass( 'selected' ) ) ? true : false;\n\t\t\t}\n\t\t};\n\n\t\tthis.setValue = function( val ) {\n\n\t\t\t//Error: TypeError: btn is null in /interface/html5/global/widgets/switch_button/SwitchButton.js?v=8.0.0-20141230-130626 line 35\n\t\t\tif ( !btn ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tbtn.removeClass( 'selected' );\n\n\t\t\tif ( val ) {\n\t\t\t\tbtn.addClass( 'selected' );\n\t\t\t}\n\t\t};\n\n\t\tthis.setIcon = function( val ) {\n\t\t\tbtn.addClass( val );\n\t\t};\n\n\t\tthis.each( function() {\n\n\t\t\tvar o = $.meta ? $.extend( {}, opts, $( this ).data() ) : opts;\n\n\t\t\tbtn = $( '' );\n\n\t\t\t$this.append( btn );\n\n\t\t\tif ( o.tooltip ) {\n\t\t\t\tbtn.attr( 'title', o.tooltip );\n\t\t\t}\n\n\t\t\t$this.setIcon( o.icon );\n\n\t\t\tbtn.click( function( e ) {\n\n\t\t\t\tif ( !enabled ) {\n\t\t\t\t\te.stopImmediatePropagation();\n\t\t\t\t\te.stopPropagation();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t$this.setValue( !$this.getValue() );\n\t\t\t} );\n\n\t\t} );\n\n\t\treturn this;\n\n\t};\n\n\t$.fn.SwitchButton.defaults = {};\n\n} )( jQuery );\n\nvar SwitchButtonIcon = function() {\n\n};\n\nSwitchButtonIcon.daily_total = 'daily';\nSwitchButtonIcon.weekly_total = 'weekly';\nSwitchButtonIcon.all_employee = 'all-employee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cblx0XHRcdFx0XHRlLnN0b3BJbW1lZGlhdGVQcm9wYWdhdGlvbigpO1xuXHRcdFx0XHRcdGUuc3RvcFByb3BhZ2F0aW9uKCk7XG5cdFx0XHRcdFx0cmV0dXJuO1xuXHRcdFx0XHR9XG5cblx0XHRcdFx0JHRoaXMuc2V0VmFsdWUoICEkdGhpcy5nZXRWYWx1ZSgpICk7XG5cdFx0XHR9ICk7XG5cblx0XHR9ICk7XG5cblx0XHRyZXR1cm4gdGhpcztcblxuXHR9O1xuXG5cdCQuZm4uU3dpdGNoQnV0dG9uLmRlZmF1bHRzID0ge307XG5cbn0gKSggalF1ZXJ5ICk7XG5cbmV4cG9ydCB2YXIgU3dpdGNoQnV0dG9uSWNvbiA9IGZ1bmN0aW9uKCkge1xuXG59O1xuXG5Td2l0Y2hCdXR0b25JY29uLmRhaWx5X3RvdGFsID0gJ2RhaWx5JztcblN3aXRjaEJ1dHRvbkljb24ud2Vla2x5X3RvdGFsID0gJ3dlZWtseSc7XG5Td2l0Y2hCdXR0b25JY29uLmFsbF9lbXBsb3llZSA9ICdhbGwtZW1wbG95ZWUnO1xuU3dpdGNoQnV0dG9uSWNvbi5zdHJpY3RfcmFuZ2UgPSAnc3RyaWN0LXJhbmdlJztcblN3aXRjaEJ1dHRvbkljb24ud2FnZXMgPSAnc3RyaWN0LXJhbmdlJzsiXSwibmFtZXMiOltdLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///6618\n")},2911:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{"use strict";eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"WidgetTestViewController\": () => (/* binding */ WidgetTestViewController)\n/* harmony export */ });\n/* harmony import */ var _global_widgets_filebrowser_TImage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1469);\n/* harmony import */ var _global_widgets_filebrowser_TImage__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_global_widgets_filebrowser_TImage__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _global_widgets_filebrowser_TImageAdvBrowser__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8243);\n/* harmony import */ var _global_widgets_filebrowser_TImageAdvBrowser__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_global_widgets_filebrowser_TImageAdvBrowser__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _global_widgets_color_picker_TColorPicker__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3161);\n/* harmony import */ var _global_widgets_switch_button_SwitchButton__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6618);\n/* provided dependency */ var _ = __webpack_require__(9050);\n/* provided dependency */ var $ = __webpack_require__(9755);\n\n\n\n\n\nclass WidgetTestViewController extends BaseViewController {\n\tconstructor( options = {} ) {\n\t\t_.defaults( options, {\n\t\t\tel: '#awesomebox_test_view_container',\n\n\t\t\t// _required_files: [\n\t\t\t// \t'TColorPicker',\n\t\t\t// \t'TImage',\n\t\t\t// \t'TImageAdvBrowser'\n\t\t\t// ],\n\n\t\t\tuser_api: null,\n\t\t\tuser_group_api: null,\n\t\t\tcompany_api: null,\n\t\t\tuser_id_array: null\n\t\t} );\n\n\t\tsuper( options );\n\t}\n\n\tinit( options ) {\n\t\tthis.edit_view_tpl = 'WidgetTestEditView.html';\n\t\tthis.permission_id = 'user';\n\t\tthis.viewId = 'WidgetTest';\n\t\tthis.script_name = 'WidgetTest';\n\t\tthis.table_name_key = 'awesomebox_test';\n\t\tthis.context_menu_name = $.i18n._( 'Widget Test' );\n\t\tthis.navigation_label = $.i18n._( 'Widget Test' );\n\t\tthis.api = TTAPI.APIUser;\n\t\tthis.select_company_id = LocalCacheData.getCurrentCompany().id;\n\t\tthis.user_group_api = TTAPI.APIUserGroup;\n\t\tthis.company_api = TTAPI.APICompany;\n\t\tthis.user_id_array = [];\n\n\t\tthis.render();\n\t\tthis.buildContextMenu();\n\t\tthis.initData();\n\t}\n\n\tsetCurrentEditRecordData() {\n\t\tthis.collectUIDataToCurrentEditRecord();\n\t\tthis.setEditViewDataDone();\n\t}\n\n\tclearEditViewData() {\n\t\treturn false;\n\t}\n\n\tbuildEditViewUI() {\n\t\tvar $this = this;\n\n\t\tif( ContextMenuManager.getMenu( this.determineContextMenuMountAttributes().id ) === undefined ) {\n\t\t\tthis.buildContextMenu();\n\t\t} else {\n\t\t\tDebug.Warn( 'Context Menu ('+ this.determineContextMenuMountAttributes().id +') already exists for: '+ this.viewId, 'AwesomeBoxTestView.js', 'AwesomeBoxTestView', 'buildEditViewUI', 10 );\n\t\t}\n\n\t\tvar tab_model = {\n\t\t\t'tab_employee': { 'label': $.i18n._( 'Employee' ) },\n\t\t};\n\t\tthis.setTabModel( tab_model );\n\n\t\t//Tab 0 start\n\n\t\tvar tab_employee = this.edit_view_tab.find( '#tab_employee' );\n\n\t\tvar tab_employee_column1 = tab_employee.find( '.first-column' );\n\t\tvar tab_employee_column2 = tab_employee.find( '.second-column' );\n\n\t\tthis.edit_view_tabs[0] = [];\n\t\tthis.edit_view_tabs[0].push( tab_employee_column1 );\n\n\t\tvar form_item_input = Global.loadWidgetByName( FormItemType.SEPARATED_BOX );\n\t\tform_item_input.SeparatedBox( { label: $.i18n._( 'Separated_box: if you see this, the test is passing.' ) } );\n\t\tthis.addEditFieldToColumn( null, form_item_input, tab_employee_column1 );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.CHECKBOX );\n\t\tform_item_input.TCheckbox( { field: 'checkbox' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TCheckbox' ), form_item_input, tab_employee_column1, '' );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.COLOR_PICKER );\n\t\tform_item_input.TColorPicker( { field: 'color_picker' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TColorPicker' ), form_item_input, tab_employee_column1 );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.DATE_PICKER );\n\t\tform_item_input.TDatePicker( { field: 'datepicker' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TDatePicker' ), form_item_input, tab_employee_column1, '', null );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.DATE_PICKER );\n\t\tform_item_input.TRangePicker( { field: 'daterange', validation_field: 'date_stamp' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TDateRange' ), form_item_input, tab_employee_column1, '', null, true );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TIME_PICKER );\n\t\tform_item_input.TTimePicker( { field: 'timepicker' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TTimePicker' ), form_item_input, tab_employee_column1 );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.IMAGE_AVD_BROWSER );\n\t\tthis.file_browser = form_item_input.TImageAdvBrowser( {\n\t\t\tfield: 'imagebrowser',\n\t\t\tdefault_width: 128,\n\t\t\tdefault_height: 128,\n\t\t\tenable_delete: true,\n\t\t\tcallBack: function( form_data ) {\n\t\t\t\tnew ServiceCaller().uploadFile( form_data, 'object_type=user_photo&object_id=' + $this.current_edit_record.id, {\n\t\t\t\t\tonResult: function( result ) {\n\n\t\t\t\t\t\tif ( result.toLowerCase() === 'true' ) {\n\t\t\t\t\t\t\t$this.file_browser.setImage( ServiceCaller.getURLByObjectType( 'user_photo' ) + '&object_id=' + $this.current_edit_record.id );\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tTAlertManager.showAlert( result, 'Error' );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} );\n\n\t\t\t},\n\t\t\tdeleteImageHandler: function( e ) {\n\t\t\t\t$this.onDeleteImage();\n\t\t\t}\n\t\t} );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TImageAdvBrowser' ), this.file_browser, tab_employee_column1, '', null, false, true );\n\n\t\tGlobal.loadScript( 'global/widgets/formula_builder/FormulaBuilder.js', function() {\n\t\t\t// Dynamic Field 11\n\t\t\tform_item_input = Global.loadWidgetByName( FormItemType.FORMULA_BUILDER );\n\t\t\tform_item_input.FormulaBuilder( {\n\t\t\t\tfield: 'formula', width: '100%', onFormulaBtnClick: function() {\n\n\t\t\t\t\tvar custom_column_api = TTAPI.APIReportCustomColumn;\n\n\t\t\t\t\tcustom_column_api.getOptions( 'formula_functions', {\n\t\t\t\t\t\tonResult: function( fun_result ) {\n\t\t\t\t\t\t\tvar fun_res_data = fun_result.getResult();\n\n\t\t\t\t\t\t\t$this.api.getOptions( 'formula_variables', { onResult: onColumnsResult } );\n\n\t\t\t\t\t\t\tfunction onColumnsResult( col_result ) {\n\t\t\t\t\t\t\t\tvar col_res_data = col_result.getResult();\n\n\t\t\t\t\t\t\t\tvar default_args = {};\n\t\t\t\t\t\t\t\tdefault_args.functions = Global.buildRecordArray( fun_res_data );\n\t\t\t\t\t\t\t\tdefault_args.variables = Global.buildRecordArray( col_res_data );\n\t\t\t\t\t\t\t\tdefault_args.formula = $this.current_edit_record.company_value1;\n\t\t\t\t\t\t\t\tdefault_args.current_edit_record = Global.clone( $this.current_edit_record );\n\t\t\t\t\t\t\t\tdefault_args.api = $this.api;\n\n\t\t\t\t\t\t\t\tIndexViewController.openWizard( 'FormulaBuilderWizard', default_args, function( val ) {\n\t\t\t\t\t\t\t\t\t$this.current_edit_record.company_value1 = val;\n\t\t\t\t\t\t\t\t\t$this.edit_view_ui_dic.df_11.setValue( val );\n\t\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t}\n\t\t\t\t\t} );\n\t\t\t\t}\n\t\t\t} );\n\t\t\t$this.detachElement( 'df_11' );\n\t\t\t$this.addEditFieldToColumn( 'FormulaBuilder', form_item_input, tab_employee_column1, '', null, true );\n\t\t\tform_item_input.parent().width( '45%' );\n\t\t} );\n\n\t\t//NO INSTANCES OF TList\n\n\t\t//Create action switch buttons\n\t\tvar action_chooser_div = $( '.control-bar .action-chooser-div' );\n\t\tthis.all_employee_btn = action_chooser_div.find( '#all_employee' );\n\t\tthis.daily_totals_btn = action_chooser_div.find( '#daily_totals' );\n\t\tthis.weekly_totals_btn = action_chooser_div.find( '#weekly_totals' );\n\t\tthis.strict_range_btn = action_chooser_div.find( '#strict_range' );\n\t\tthis.all_employee_btn = this.all_employee_btn.SwitchButton( {\n\t\t\ticon: _global_widgets_switch_button_SwitchButton__WEBPACK_IMPORTED_MODULE_3__.SwitchButtonIcon.all_employee,\n\t\t\ttooltip: $.i18n._( 'Show Unscheduled Employees' )\n\t\t} );\n\t\tthis.daily_totals_btn = this.daily_totals_btn.SwitchButton( {\n\t\t\ticon: _global_widgets_switch_button_SwitchButton__WEBPACK_IMPORTED_MODULE_3__.SwitchButtonIcon.daily_total,\n\t\t\ttooltip: $.i18n._( 'Daily Totals' )\n\t\t} );\n\t\tthis.weekly_totals_btn = this.weekly_totals_btn.SwitchButton( {\n\t\t\ticon: _global_widgets_switch_button_SwitchButton__WEBPACK_IMPORTED_MODULE_3__.SwitchButtonIcon.weekly_total,\n\t\t\ttooltip: $.i18n._( 'Weekly Totals' )\n\t\t} );\n\t\tthis.strict_range_btn = this.strict_range_btn.SwitchButton( {\n\t\t\ticon: _global_widgets_switch_button_SwitchButton__WEBPACK_IMPORTED_MODULE_3__.SwitchButtonIcon.strict_range,\n\t\t\ttooltip: $.i18n._( 'Strict Range' )\n\t\t} );\n\t\tthis.all_employee_btn.click( function() {\n\t\t\t// $this.onShowEmployeeClick();\n\t\t} );\n\t\tthis.daily_totals_btn.click( function() {\n\t\t\t// $this.onDailyTotalsClick();\n\t\t} );\n\t\tthis.weekly_totals_btn.click( function() {\n\t\t\t// $this.onWeeklyTotalClick();\n\t\t} );\n\t\tthis.strict_range_btn.setValue( true );\n\t\tthis.strict_range_btn.click( function() {\n\t\t\t// $this.onStrictRangeClick();\n\t\t} );\n\t\tthis.toggle_button = $( this.el ).find( '.toggle-button-div' );\n\t\tvar data_provider = [\n\t\t\t{ label: $.i18n._( 'Day' ), value: 'day' },\n\t\t\t{ label: $.i18n._( 'Week' ), value: 'week' },\n\t\t\t{ label: $.i18n._( 'Month' ), value: 'month' },\n\t\t\t{ label: $.i18n._( 'Year' ), value: 'year' }\n\t\t];\n\n\t\tthis.toggle_button = this.toggle_button.TToggleButton( { data_provider: data_provider } );\n\t\tthis.toggle_button.bind( 'change', function( e, result ) {\n\t\t\t$this.scroll_position = 0;\n\t\t\t$this.select_all_shifts_array = [];\n\t\t\t$this.select_shifts_array = [];\n\t\t\t$this.select_recurring_shifts_array = [];\n\t\t} );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TAG_INPUT );\n\t\tform_item_input.TTagInput( { field: 'tags', object_type_id: 930 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TTagInput' ), form_item_input, tab_employee_column2, '', null, null, true );\n\n\t\t//requires width manipulation or intermittently won't show.\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_INPUT );\n\t\tform_item_input.TTextInput( { field: 'text', width: '100%' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TText' ), form_item_input, tab_employee_column2 );\n\t\tform_item_input.parent().width( '45%' );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.PASSWORD_INPUT );\n\t\tform_item_input.TPasswordInput( { field: 'password', width: 200 } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TPasswordInput' ), form_item_input, tab_employee_column2 );\n\n\t\tform_item_input = Global.loadWidgetByName( FormItemType.TEXT_AREA );\n\t\tform_item_input.TTextArea( { field: 'textarea' } );\n\t\tthis.addEditFieldToColumn( $.i18n._( 'TTextArea' ), form_item_input, tab_employee_column2, '', null, null, true );\n\t}\n\n\tbuildSearchFields() {\n\t\tsuper.buildSearchFields();\n\t\tvar $this = this;\n\t\tthis.search_fields = [];\n\t}\n\n\tgetCustomContextMenuModel() {\n\t\tvar context_menu_model = {\n\t\t\texclude: ['default'],\n\t\t\tinclude: [\n\t\t\t\t'edit',\n\t\t\t\t'cancel'\n\t\t\t]\n\t\t};\n\n\t\treturn context_menu_model;\n\t}\n\n\t//override that forces same data to grid at all times.\n\tsearch() {\n\t\tvar $this = this;\n\t\tthis.api.getUser( {}, true, {\n\t\t\tonResult: function( r ) {\n\t\t\t\tvar result_data = r.getResult();\n\t\t\t\t$this.user_id_array = result_data;\n\t\t\t\tresult_data = $this.processResultData( result_data );\n\t\t\t\t$this.grid.setData( result_data );\n\t\t\t\t$this.grid.setGridColumnsWidth();\n\t\t\t\t$this.onEditClick( result_data[0].id );\n\t\t\t}\n\t\t} );\n\t}\n\n\tsetEditViewDataDone() {\n\t\tvar $this = this;\n\t\tsetTimeout( function() {\n\t\t\tTAlertManager.showConfirmAlert( $.i18n._( 'Run tests?' ), null, function( result ) {\n\t\t\t\tif ( result == true ) {\n\t\t\t\t\t$this.runTests();\n\t\t\t\t}\n\t\t\t} );\n\t\t\t$this.setTabOVisibility( true );\n\t\t\t$( '.edit-view-tab-bar' ).css( 'opacity', 1 );\n\t\t\tTTPromise.resolve( 'init', 'init' );\n\t\t}, 2500 );\n\n\t\tsuper.setEditViewDataDone();\n\t}\n\n\trunTests() {\n\t\tvar $this = this;\n\t\tif ( $( '#qunit_script' ).length == 0 ) {\n\t\t\t$( '