84 lines
		
	
	
		
			5.5 KiB
		
	
	
	
		
			HTML
		
	
	
	
			
		
		
	
	
			84 lines
		
	
	
		
			5.5 KiB
		
	
	
	
		
			HTML
		
	
	
	
{% extends "base.html" %}
 | 
						|
 | 
						|
{% block title %}Главная{% endblock %}
 | 
						|
 | 
						|
{% block content %}
 | 
						|
 | 
						|
 <div class="intro-y flex flex-col sm:flex-row items-center mt-8">
 | 
						|
                    <h2 class="text-lg font-medium mr-auto">
 | 
						|
                        Tasks
 | 
						|
                    </h2>
 | 
						|
                    <button class="button text-white bg-red-500 hover:bg-red-700 shadow-md mr-2" onclick="window.location.href='/productuj'">Unasigned Jobs</button>
 | 
						|
                <button class="button text-white bg-theme-1 shadow-md mr-2" onclick="window.location.href='/productmj'">My Jobs</button>
 | 
						|
 | 
						|
                <button class="button text-white bg-theme-1 shadow-md mr-2" onclick="window.location.href='/product'">All Jobs</button>
 | 
						|
                <button class="button text-white bg-theme-1 shadow-md mr-2" onclick="window.location.href='/productoj'">Outstanding Jobs</button>
 | 
						|
                </div>
 | 
						|
                <!-- BEGIN: Datatable -->
 | 
						|
                <div class="intro-y datatable-wrapper box p-5 mt-5">
 | 
						|
                    <table class="table table-report table-report--bordered display datatable w-full">
 | 
						|
                        <thead>
 | 
						|
                            <tr>
 | 
						|
                                <th class="border-b-2 whitespace-no-wrap">TITLE ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">COMPANY ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">CLIENT ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">Requested on ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">Posted on ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">STATUS ⨈</th>
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">Assignee ⨈</th>
 | 
						|
 | 
						|
 | 
						|
                                <th class="border-b-2 text-center whitespace-no-wrap">Applied on</th>
 | 
						|
                            </tr>
 | 
						|
                        </thead>
 | 
						|
                        <tbody>
 | 
						|
                            {% for job in jobs %}
 | 
						|
                            <tr>
 | 
						|
                                <td class="border-b">
 | 
						|
                                    <a href="{{ job.job.link }}" target="_blank" class="font-medium whitespace-no-wrap">{{ job.job.job_title [:50] }}</a>
 | 
						|
                                    <div class="text-gray-600 text-xs whitespace-no-wrap">{{ job.job.job_id  }}</div>
 | 
						|
                                </td>
 | 
						|
                                <td class="text-center border-b">{{job.job.job_company}}</td>
 | 
						|
                                <td class="text-center border-b">
 | 
						|
                                    
 | 
						|
                                <a href="#" class="client-link text-blue-500" data-client-id="{{ job.client.id }}">{{ job.client.user_nicename }}</a>
 | 
						|
            
 | 
						|
                                </td>
 | 
						|
 | 
						|
                                <td class="text-center border-b">{{job.job.data_requested}}</td>
 | 
						|
                                <td class="text-center border-b">{{job.job.date_posted}}</td>
 | 
						|
                                <td class="text-center border-b">
 | 
						|
                                    <select class="select2" onchange="updateStatus(this, '{{ job.id }}')">
 | 
						|
                                        <option value="" {% if job.status is none %}selected{% endif %}>— Not selected —</option>
 | 
						|
                                        <option value="Scheduled" {% if job.status == "Scheduled" %}selected{% endif %}>Scheduled</option>
 | 
						|
                                        <option value="Requested" {% if job.status == "Requested" %}selected{% endif %}>Requested</option>
 | 
						|
                                        <option value="In-Progress" {% if job.status == "In-Progress" %}selected{% endif %}>In-Progress</option>
 | 
						|
                                        <option value="Applied" {% if job.status == "Applied" %}selected{% endif %}>Applied</option>
 | 
						|
                                        <option value="Issues Applying" {% if job.status == "Issues Applying" %}selected{% endif %}>Issues Applying</option>
 | 
						|
                                        <option value="Cancelled" {% if job.status == "Cancelled" %}selected{% endif %}>Cancelled</option>
 | 
						|
                                    </select>
 | 
						|
                                
 | 
						|
                                </td>
 | 
						|
                               <td class="text-center border-b">
 | 
						|
                                    <select class="select2" onchange="updateAssignee(this, '{{ job.id }}')">
 | 
						|
                                        <option value="" {% if job.assignee is none %}selected{% endif %}>— Not selected —</option>
 | 
						|
                                        {% for user in users %}
 | 
						|
                                            <option value="{{ user.id }}" {% if job.assignee == user.id %}selected{% endif %}>
 | 
						|
                                                {{ user.username }}
 | 
						|
                                            </option>
 | 
						|
                                        {% endfor %}
 | 
						|
                                    </select>
 | 
						|
                                </td>
 | 
						|
                                <td class="text-center border-b">-</td>
 | 
						|
                            </tr>
 | 
						|
                         {% endfor %}
 | 
						|
                        </tbody>
 | 
						|
                    </table>
 | 
						|
                </div>
 | 
						|
                <!-- END: Datatable -->
 | 
						|
<!-- Включаем модалку -->
 | 
						|
<!-- Модальное окно -->
 | 
						|
{% include "modal.html" %}
 | 
						|
<script src="/static/dist/js/prod.js"></script>
 | 
						|
 | 
						|
{% endblock %} |