QloApps Forums
    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    How to display build files

    Technical Help
    2
    2
    597
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      daicie last edited by

      I am building an angular feature that I want to extend using a QloApps module. I have added the build files to the module's folder and written a hook that points to the files.

      public function hookDashboardTop()
      {
      if ('AdminDashboard' == Tools::getValue('controller')) {
      $calendarContent = $this->context->smarty->fetch($this->local_path . 'views/templates/hook/qloAngular_calendar.tpl');

              $this->context->smarty->assign(array('calendar_content' => $appContent));
      
              return $this->display(__FILE__, 'qloAngular_calendar.tpl');
          }
      }
      

      I however am not able to see the calendar, even after installing the module successfully. Please help me out with this.

      1 Reply Last reply Reply Quote 0
      • S
        shreesh Global Moderator last edited by

        @daicie

        We cannot confirm the exact issue but in your current code snippet we found the following errors

        • $appContent is not defined anywhere in the hook.
        • qloAngular_calendar.tpl template is called multiple times which is not required, also the variable $calendarContent is not used anywhere.
        // The following code is not required as $this->display() function fetches and returns the passed template by default.
        $calendarContent = $this->context->smarty->fetch($this->local_path . 'views/templates/hook/qloAngular_calendar.tpl');
        

        Please enable debug mode which will help in further debugging the issue
        https://devdocs.qloapps.com/introduction/configuration.html#debug-mode-error-reporting

        1 Reply Last reply Reply Quote 0
        • First post
          Last post