(function ($) {
    $.field_event_type = function (element, options) {
        var defaults = {
        }
        var plugin = this;
        plugin.settings = {}
        var $element = $(element), 
            element = element;    
        
        plugin.init = function () {
            plugin.settings = $.extend({}, defaults, options);
            $element.find('.list-event-type').select2();
            $element.find('.select2-selection__arrow').html('<i class="icon-nb-arrow-down"></i>')
        };
        plugin.example_function = function () {
        };
        plugin.init();
    }
    
    $.fn.field_event_type = function (options) {
        
        return this.each(function () {
            
            if (undefined == $(this).data('field_event_type')) {
                var plugin = new $.field_event_type(this, options);
                $(this).data('field_event_type', plugin);
            }
        });
    }
})(jQuery);