diff options
author | prashantsinalkar | 2020-02-27 17:12:00 +0530 |
---|---|---|
committer | prashantsinalkar | 2020-02-27 17:12:00 +0530 |
commit | bb1f7457f90f51a531bca2dfc3527432898b0b09 (patch) | |
tree | 2aafd4e11c5b81c26031c2c85b6a65a691b397cc /arduino_blog/static/admin/js/autocomplete.js | |
parent | 3fb61ed2b017bfcc2fe663e15d21ff924ee750a6 (diff) | |
download | arduino_projects_website-bb1f7457f90f51a531bca2dfc3527432898b0b09.tar.gz arduino_projects_website-bb1f7457f90f51a531bca2dfc3527432898b0b09.tar.bz2 arduino_projects_website-bb1f7457f90f51a531bca2dfc3527432898b0b09.zip |
updated ui and fixed code
Diffstat (limited to 'arduino_blog/static/admin/js/autocomplete.js')
l---------[-rw-r--r--] | arduino_blog/static/admin/js/autocomplete.js | 38 |
1 files changed, 1 insertions, 37 deletions
diff --git a/arduino_blog/static/admin/js/autocomplete.js b/arduino_blog/static/admin/js/autocomplete.js index 65c0702..d641e00 100644..120000 --- a/arduino_blog/static/admin/js/autocomplete.js +++ b/arduino_blog/static/admin/js/autocomplete.js @@ -1,37 +1 @@ -(function($) { - 'use strict'; - var init = function($element, options) { - var settings = $.extend({ - ajax: { - data: function(params) { - return { - term: params.term, - page: params.page - }; - } - } - }, options); - $element.select2(settings); - }; - - $.fn.djangoAdminSelect2 = function(options) { - var settings = $.extend({}, options); - $.each(this, function(i, element) { - var $element = $(element); - init($element, settings); - }); - return this; - }; - - $(function() { - // Initialize all autocomplete widgets except the one in the template - // form used when a new formset is added. - $('.admin-autocomplete').not('[name*=__prefix__]').djangoAdminSelect2(); - }); - - $(document).on('formset:added', (function() { - return function(event, $newFormset) { - return $newFormset.find('.admin-autocomplete').djangoAdminSelect2(); - }; - })(this)); -}(django.jQuery)); +/home/prashant/www/html/python/python_3.x/arduino-hosting/env-arduino/lib/python3.6/site-packages/django/contrib/admin/static/admin/js/autocomplete.js
\ No newline at end of file |