src/CoreBundle/Resources/views/Areas/LogaAd/view.html.twig line 1

Open in your IDE?
  1. {% if editmode %}
  2.     <div class="flex-col offset-bottom-single">
  3.         <div class="col xs-12 m-6 l-3">
  4.             <span class="hint">{{ 'Loga API Url' |trans }}</span>
  5.             {{ pimcore_input("api_url") }}
  6.         </div>
  7.         <div class="col xs-12 m-6 l-3">
  8.             <span class="hint">{{ 'Job details button text' |trans }}</span>
  9.             {{ pimcore_input("details_button_text") }}
  10.         </div>
  11.     </div>
  12.     <div class="flex-col offset-bottom-single">
  13.         <div class="col xs-12 m-6 l-3">
  14.             <span class="hint">{{ 'Header Image 1 mapping' |trans }}</span>
  15.             {{ pimcore_input("loga_header_image_1_mapping") }}
  16.         </div>
  17.         <div class="col xs-12 m-6 l-3">
  18.             <span class="hint">{{ 'Header Image 1' |trans }}</span>
  19.             {{ pimcore_image("loga_header_image_1", {
  20.                 "title": "Drag your image here",
  21.                 "thumbnail": "jobDetailHeader"~ bundleName,
  22.                 "reload": true
  23.             }) }}
  24.         </div>
  25.     </div>
  26.     <div class="flex-col offset-bottom-single">
  27.         <div class="col xs-12 m-6 l-3">
  28.             <span class="hint">{{ 'Header Image 2 mapping' |trans }}</span>
  29.             {{ pimcore_input("loga_header_image_2_mapping") }}
  30.         </div>
  31.         <div class="col xs-12 m-6 l-3">
  32.             <span class="hint">{{ 'Header Image 2' |trans }}</span>
  33.             {{ pimcore_image("loga_header_image_2", {
  34.                 "title": "Drag your image here",
  35.                 "thumbnail": "jobDetailHeader"~ bundleName,
  36.                 "reload": true
  37.             }) }}
  38.         </div>
  39.     </div>
  40. {% else %}
  41.     {% if status == true %}
  42.         {% if(detailsButtonText is not empty) %}
  43.             {% set buttonText = detailsButtonText %}
  44.         {% else %}
  45.             {% set buttonText = 'Job Details' |trans %}
  46.         {% endif %}
  47.         <div class="section">
  48.             <div class="main-content">
  49.                 <div class="filters">
  50.                     <div class="form-field label">
  51.                         <span>{{ "job.filter.currently_looking_for"|trans }}</span>
  52.                     </div>
  53.                     <div class="form-field">
  54.                         <select id="titleFilter" name="titleFilter">
  55.                             <option value="">{{ "job.filter.title"|trans }}</option>
  56.                         </select>
  57.                     </div>
  58.                     <div class="form-field">
  59.                         <select id="rangeFilter" name="rangeFilter">
  60.                             <option value="">{{ "job.filter.range"|trans }}</option>
  61.                         </select>
  62.                     </div>
  63.                     <div class="form-field">
  64.                         <select id="departmentFilter" name="departmentFilter">
  65.                             <option value="">{{ "job.filter.department"|trans }}</option>
  66.                         </select>
  67.                     </div>
  68.                     <div class="form-field">
  69.                         <select id="locationFilter" name="locationFilter">
  70.                             <option value="">{{ "job.filter.location"|trans }}</option>
  71.                         </select>
  72.                     </div>
  73.                     <div class="form-field">
  74.                         <select id="careerLevelFilter" name="careerLevelFilter">
  75.                             <option value="">{{ "job.filter.careerLevel"|trans }}</option>
  76.                         </select>
  77.                     </div>
  78.                 </div>
  79.                 <table class="table-jobs" class="display" width="100%" id="jobstable-{{ info.index }}">
  80.                     <thead>
  81.                     <tr>
  82.                         <th>{{ 'Job Title' |trans }}</th>
  83.                         <th>{{ 'Contract type' |trans }}</th>
  84.                         <th>{{ 'Location' |trans }}</th>
  85.                         <th>{{ 'Fields of working' |trans }}</th>
  86.                         <th></th>
  87.                         <th style="display:none;"></th>
  88.                     </tr>
  89.                     </thead>
  90.                     <tbody>
  91.                     {% for job in jobs %}
  92.                         <tr>
  93.                             <td class="job-title">{{ job.title }}</td>
  94.                             <td class="job-range">{{ job.range }}</td>
  95.                             <td class="job-location">{{ job.location }}</td>
  96.                             <td class="job-department">{{ job.department }}</td>
  97.                             <td class="job-link"><a href="{{ job.url }}" class="button btn-default" target="_blank">{{ buttonText }}</a></td>
  98.                             <td style="display:none;" class="job-career-level">{{ job.careerLevel }}</td>
  99.                         </tr>
  100.                     {% endfor %}
  101.                     </tbody>
  102.                 </table>
  103.             </div>
  104.         </div>
  105.         <script>
  106.             document.onreadystatechange = function () {
  107.                 if (document.readyState == "complete") {
  108.                     var table{{ info.index }} = $('#jobstable-{{ info.index }}').DataTable(
  109.                         {
  110.                             "paging": false,
  111.                             "language": {
  112.                                 "url": "//cdn.datatables.net/plug-ins/9dcbecd42ad/i18n/German.json"
  113.                             },
  114.                             initComplete: function () {
  115.                                 this.api().columns().every(function () {
  116.                                     var mapping = {
  117.                                         0: "#titleFilter",
  118.                                         1: "#rangeFilter",
  119.                                         3: "#departmentFilter",
  120.                                         2: "#locationFilter",
  121.                                         5: "#careerLevelFilter"
  122.                                     }
  123.                                     var column = this;
  124.                                     if (mapping[column.index()] !== undefined) {
  125.                                         var select = $(mapping[column.index()])
  126.                                             .on('change', function () {
  127.                                                 var val = $.fn.dataTable.util.escapeRegex(
  128.                                                     $(this).val()
  129.                                                 );
  130.                                                 column
  131.                                                     .search(val ? '^' + val + '$' : '', true, false)
  132.                                                     .draw();
  133.                                             });
  134.                                         column.data().unique().sort().each(function (d, j) {
  135.                                             select.append('<option value="' + d + '">' + d + '</option>')
  136.                                         });
  137.                                     }
  138.                                 });
  139.                             }
  140.                         });
  141.                 }
  142.             };
  143.         </script>
  144.     {% else %}
  145.         <p>{{ 'Job service currrently unavailable. Please refresh.' |trans }}</p>
  146.     {% endif %}
  147. {% endif %}