title: Prestashop 1.6.1.0 backoffice - Uncaught ReferenceError: jQuery is not defined
body: <p>I have a problem with <code>prestashop 1.6.1.0</code>. In backoffice when i open developer console, it gives me following error <code>Uncaught ReferenceError: jQuery is not defined</code>. I know this is happening because <code>admin.js</code> loading before <code>jQuery</code>.</p>
  
  <p>I've spent some time to change script hierarchy on <code>Prestashop Backofffice</code>, but i couldn't find where are the scripts files located the end of bottom of document.</p>
  
  <p>Here is the screenshot of my javascript hierarachy;</p>
  
  <p><a href="https://i.stack.imgur.com/yNJZS.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yNJZS.png" alt="enter image description here"></a></p>
  
  <p>Does anyone knows where can i change included <code>scripts</code> <b>hierarchy?</b></p>
  
  <p>Thx in advance.</p>
  
  <p><strong>### EDIT &amp; UPDATE ###</strong></p>
  
  <p>After @Sergii P 's answer and comments, i begin to search in my new theme's modules for solution. My theme added some new <code>modules</code> to my <code>backoffice</code>. So i've found this <code>override method</code> in my theme <code>controller</code>;</p>
  
  <pre><code>public function hookDisplayBackOfficeHeader() {
          if (Tools::getValue('configure') == $this-&gt;name){
              $this-&gt;context-&gt;controller-&gt;addJquery();
          }
          $this-&gt;context-&gt;controller-&gt;addCSS($this-&gt;_path.'assets/css/admin.css');
          $this-&gt;context-&gt;controller-&gt;addJS($this-&gt;_path.'assets/js/admin.js');
      }
  </code></pre>
  
  <p>How should i change this method?</p>
  
  <p>And Here is the header.tpl for backoffice;</p>
  
  <pre><code>{if isset($css_files)}
  {foreach from=$css_files key=css_uri item=media}
      &lt;link href="{$css_uri|escape:'html':'UTF-8'}" rel="stylesheet" type="text/css"/&gt;
  {/foreach}
  {/if}
      {if (isset($js_def) &amp;&amp; count($js_def) || isset($js_files) &amp;&amp; count($js_files))}
          {include file=$smarty.const._PS_ALL_THEMES_DIR_|cat:"javascript.tpl"}
      {/if}
  
      {if isset($displayBackOfficeHeader)}
          {$displayBackOfficeHeader}
      {/if}
      {if isset($brightness)}
      &lt;!--
          // @todo: multishop color
          &lt;style type="text/css"&gt;
              div#header_infos, div#header_infos a#header_shopname, div#header_infos a#header_logout, div#header_infos a#header_foaccess {ldelim}color:{$brightness}{rdelim}
          &lt;/style&gt;
      --&gt;
      {/if}
  </code></pre>