<!DOCTYPE html>
<html lang="pl">
  <head>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta http-equiv="content-type" content="text/html; charset=utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>crmPro</title>
    <meta name="keywords" content="">
    <meta name="description" content="">
    <meta name="robots" content="all">
    <link href="/layout/favicon.png" rel="icon" type="image/x-icon">
    <link rel="preconnect" href="https://fonts.googleapis.com">
    <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
    <link href="https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap" rel="stylesheet">
    <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.18.1/moment.min.js"></script>
    <script src="https://cdn.datatables.net/2.1.7/js/dataTables.min.js"></script>
    <script src="https://cdn.datatables.net/2.1.7/js/dataTables.bootstrap5.min.js"></script>
    <script src="https://code.highcharts.com/highcharts.js"></script>
    <script src="/libraries/framework/vendor/jquery/jquery_ui/jquery-ui.min.js"></script>
    <script src="/libraries/framework/vendor/plugins/moment/moment.js"></script>
    <script src="/libraries/framework/vendor/plugins/moment/pl.js"></script>
    <script src="/libraries/framework/vendor/plugins/datepicker/js/bootstrap-datetimepicker.js"></script>
    <script src="/libraries/framework/vendor/plugins/daterange/daterangepicker.js"></script>
    <script src="/libraries/jquery-confirm/jquery-confirm.min.js"></script>
    <script src="/libraries/select2/js/select2.full.min.js"></script>
    <script src="/libraries/functions.js"></script>
    <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/2.1.7/css/dataTables.bootstrap5.min.css">
    <link rel="Stylesheet" type="text/css" href="/libraries/framework/skin/default_skin/css/theme.css">
    <link rel="stylesheet" type="text/css" href="/libraries/framework/vendor/plugins/datepicker/css/bootstrap-datetimepicker.css">
    <link rel="Stylesheet" type="text/css" href="/libraries/framework/vendor/plugins/daterange/daterangepicker.css">
    <link rel="Stylesheet" type="text/css" href="/libraries/framework/admin-tools/admin-forms/css/admin-forms.css">
    <link rel="stylesheet" type="text/css" href="/libraries/jquery-confirm/jquery-confirm.min.css">
    <link rel="stylesheet" type="text/css" href="/libraries/select2/css/select2.min.css">
    <link rel="stylesheet" type="text/css" href="/libraries/select2/css/select2-bootstrap-5-theme.min.css">
    <link rel="stylesheet" type="text/css" href="/layout/style.css">
  </head>
  <body class="logged">
    <div class="top">
      <div class="logo">
        <a href="/">crm<span>Pro</span></a>
      </div>
      <div class="user-nav">
        <div class="trigger">
          <i class="fa fa-user"></i> <span><?= $this -> user[ 'email' ];?></span>
        </div>
        <ul>
          <li>
            <a href="/users/settings/">Ustawienia</a>
          </li>
          <li id="divider"></li>
          <li>
            <a href="/users/logout/">Wyloguj się</a>
          </li>
        </ul>
      </div>
    </div>
    <div class="main-menu">
      <ul>
        <li>
          <a href="/campaigns/main_view/">Kampanie</a>
        </li>
        <li>
          <a href="/products/main_view/">Produkty</a>
        </li>
        <li>
          <a href="/allegro/main_view/">Allegro import</a>
        </li>
      </ul>
    </div>
    <div class="main">
      <? if ( $this -> alert ):?>
        <div class="alert"><?= $this -> alert;?></div>
      <? endif;?>
      <?= $this -> content;?>
    </div>
    <div class="default_popup">
      <div class="popup_content">
        <div class="popup_header">
          <div class="title"></div>
          <div class="close"><i class="fa fa-times"></i></div>
        </div>
        <div class="popup_body"></div>
      </div>
    </div>
    <script type="text/javascript">$
      $( function() {
        $( 'input.date' ).datepicker({
          language: 'pl',
          autoClose: true
        });
      });

      $( 'body' ).on( 'click', '.default_popup .close', function(e) {
        e.preventDefault();
        $( '.default_popup .popup_body' ).empty();
        $( '.default_popup' ).hide();
        return false;
      });

      function show_default_popup( content ) {
        $( '.default_popup .popup_body' ).html( content );
        $( '.default_popup' ).fadeIn();
      }
    </script>
  </body>
</html>
