Post by madorangepanda » Mon Nov 07, 2011 6:14 am

Hello,

None of the autocomplete fields are working for me in my admin interface. For instance in adding related products.

The following errors are showing though I am unsure as to what steps I should take next to correct this.

index.php:876 Uncaught TypeError: Object [object Object] has no method 'autocomplete'
index.php:933 Uncaught TypeError: Cannot read property 'autocomplete' of undefined
index.php:983 Uncaught TypeError: Object [object Object] has no method 'catcomplete'
index.php:1240 Uncaught TypeError: Object [object Object] has no method 'datepicker'
index.php:950 Uncaught TypeError: Object [object Object] has no method 'catcomplete'

Thanks in advance for any help.

Edit:Version 1.5.1.3 and it is upgraded not a clean install.


Posts

Joined
Thu Nov 03, 2011 8:10 pm


Post by madorangepanda » Mon Nov 07, 2011 7:07 am

Solved, for some reason my header.tpl was pointing to
view/javascript/jquery/ui/jquery-ui-1.8.9.custom.min.js
view/javascript/jquery/ui/themes/ui-lightness/jquery-ui-1.8.9.custom.css

When it should of been
view/javascript/jquery/ui/jquery-ui-1.8.16.custom.min.js
view/javascript/jquery/ui/themes/ui-lightness/jquery-ui-1.8.16.custom.css


Posts

Joined
Thu Nov 03, 2011 8:10 pm


Post by milky » Wed Jan 25, 2012 7:46 am

Thanks for coming back and posting the solution. Worked for me.

New member

Posts

Joined
Sat Jan 21, 2012 2:04 am

Post by platypuspuzzles » Mon May 14, 2012 3:37 pm

Any other suggests? This didn't work for me as my header.tpl already contains 1.8.16

Active Member

Posts

Joined
Sun Jan 23, 2011 8:11 pm

Post by lmw1 » Mon Jun 11, 2012 12:44 pm

Mine says 1.8.16 and isn't working either. Does anyone have any advice on how to get autocomplete to working, it's halting my progress.

Respectfully,
Len

New member

Posts

Joined
Mon Jun 04, 2012 1:44 pm

Post by futurestudios » Thu Jul 12, 2012 7:04 pm

Hey Len,

Did you get this sorted I have the same and its bugging me to death .. I assume its a clash of js somewhere from an installed module .. I will keep looking .. maybe if we both list what mods we are using we might find some clues ?

Richie

Newbie

Posts

Joined
Thu Jun 21, 2012 3:48 am

Post by futurestudios » Thu Jul 12, 2012 7:30 pm

Len,

Sometimes I miss the simple things looking for the really complex things ..

I now find when I imported my CSV of products (client supplied) into opencart ALL their product names had a space in front of them .. if I type [space] in the autocomplete field ... BOOM all my products are there.

I hope this post helps !!

All the Best

Richie

Newbie

Posts

Joined
Thu Jun 21, 2012 3:48 am

Post by fabiobesouro » Fri Aug 31, 2012 4:29 am

Hi! First sorry for my english! I will try to comunicate!

The solution made here don´t work with me. No space or theme problems!
I have de 1.5.2.1 version.

In a moment they work on my cellphone, but now don´t work in any device or browser! :/

Newbie

Posts

Joined
Fri Aug 31, 2012 1:07 am

Post by carbon-uk » Thu Nov 08, 2012 7:07 pm

Same problem here opencart 1.5.1.3

Firebug Info this happens on every kepresss:

Code: Select all

Uncaught TypeError: Cannot read property 'length' of null jquery-1.6.1.min.js:16
e.extend.map jquery-1.6.1.min.js:16
jQuery.ajax.success index.php:704
e.resolveWith jquery-1.6.1.min.js:16
w jquery-1.6.1.min.js:18
d
header.tpl

Code: Select all

<script type="text/javascript" src="view/javascript/jquery/ui/jquery-ui-1.8.16.custom.min.js"></script>
<script type="text/javascript" src="view/javascript/jquery/jquery-1.6.1.min.js"></script>

<link rel="stylesheet" type="text/css" href="view/javascript/jquery/ui/themes/ui-lightness/jquery-ui-1.8.16.custom.css" />
<script type="text/javascript" src="view/javascript/jquery/ui/external/jquery.bgiframe-2.1.2.js"></script>
<script type="text/javascript" src="view/javascript/jquery/tabs.js"></script>
<script type="text/javascript" src="view/javascript/jquery/superfish/js/superfish.js"></script>
<?php foreach ($scripts as $script) { ?>
<script type="text/javascript" src="<?php echo $script; ?>"></script>
<?php } ?>
<script type="text/javascript">
Products will not autocomplete throughout site. I'm guess this is a jquery conflict but any help would be appreciated.

Thanks.

New member

Posts

Joined
Wed Jul 04, 2012 4:42 pm

Post by carbon-uk » Tue Nov 13, 2012 4:20 pm

Further to this I found a solution for my problem although I haven't sorted the root of the problem yet.

The problem is in admin/controller/catalog/product/product.php

The problem is loading the json library so if you change the end of the file to this:

Code: Select all

                }
		
          
                echo json_encode($json);
                
		//$this->load->library('json');

		//$this->response->setOutput(Json::encode($json));
	}
}
?>
The json is returned and the feature works.

Hope this helps somebody and if anybody can help why the json library is not working that would be great.

New member

Posts

Joined
Wed Jul 04, 2012 4:42 pm

Post by subdivide » Fri Dec 21, 2012 5:48 am

You should set this to:

Code: Select all

$this->response->setOutput(json_encode($json));

User avatar
New member

Posts

Joined
Sun Jan 01, 2012 9:47 am

Post by storyresources » Thu Jun 13, 2013 1:17 pm

I have 1.5.5.1 installed and having the same trouble I have checked and do have the code above, so any other ideas would be great please
Carolyn


Posts

Joined
Thu Jun 13, 2013 10:48 am

Post by iNuxx » Mon Oct 28, 2013 3:38 pm

my autocomplete did not work in admin and fronted. hope to get some help.
Have gone through the above.

Newbie

Posts

Joined
Mon Sep 24, 2012 6:39 pm

Post by RNRF » Sat Dec 28, 2013 3:38 am

Someone ? Im on 1.5.1.3.1 :S

Newbie

Posts

Joined
Mon Apr 16, 2012 12:34 am

Post by redsushi » Fri Feb 28, 2014 12:01 pm

The trouble is that the limit of items displayed in the autocomplete box is 20. You can change that value to whatever you want by edit the following php file :

/ admin / controller / catalog / category.php

Change the 20 value to whatever you need (E.G. 30)

public function autocomplete() {
$json = array();

if (isset($this->request->get['filter_name'])) {
$this->load->model('catalog/category');

$data = array(
'filter_name' => $this->request->get['filter_name'],
'start' => 0,
'limit' => 30

Newbie

Posts

Joined
Fri Feb 28, 2014 11:55 am

Post by tomjy » Tue Mar 11, 2014 6:19 am

When i try to classify some products to their categories in Links, my problem is some categories can not be auto-completed and filtered out when entering the first character, but some can.

Firstly, I think maybe it's caused by too small 'limit', but it's helpless when i changed it to be bigger as 130.

At last, I came to know it's caused by there is one blank space at the beginning of the Category name.

Once I remove this blank space, all categories can be auto completed.

cheers

tom

Newbie

Posts

Joined
Tue Mar 11, 2014 6:03 am

Post by motion2082 » Mon May 21, 2018 12:39 pm

Thank you you're a superstar O0

Active Member

Posts

Joined
Tue May 12, 2015 8:48 pm
Who is online

Users browsing this forum: Google [Bot] and 19 guests