You cannot select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
	
	
		
			254 lines
		
	
	
		
			13 KiB
		
	
	
	
		
			HTML
		
	
			
		
		
	
	
			254 lines
		
	
	
		
			13 KiB
		
	
	
	
		
			HTML
		
	
| {% extends "main.html" %}
 | |
| {%load static%}
 | |
| {% block content %}
 | |
| 
 | |
| 
 | |
| <div class="w-full xxlg1:w-[75%] bg-white h-fit rounded-md shadow-md p-5">
 | |
| 
 | |
|     <div class="w-full rounded-t-md flex flex-col justify-center items-center py-3  {% if task.status == 'Open' %} bg-osiblue {% endif %}  {% if task.status == 'Working On' %} bg-yellow-500 {% endif %}  {% if task.status == 'Closed' %} bg-green-700 {% endif %}">
 | |
|         <h1 class="text-xl md:text-3xl text-white font-semibold text-center">{{task.name}}</h1>
 | |
|     </div>
 | |
| 
 | |
|     <div class="w-full h-fit flex justify-between items-center bg-gray-100 shadow-md rounded-md px-3 py-3 mt-4">
 | |
|         <div class="flex justify-start items-center gap-2">
 | |
|             <img src="{% static 'images/back-in-time.png' %}" class="w-[35px]">
 | |
|             <p class="text-secondosiblue">Total Time: <span class="font-poppinsBold">{{ task.total_task_time.0 }}{% if task.total_task_time.0 == 1 %}hr{% else %}hrs{% endif %} {{ task.total_task_time.1 }}{% if task.total_task_time.1 == 1 %}min{% else %}mins{% endif %} {{ task.total_task_time.2 }}{% if task.total_task_time.2 == 1 %}sec{% else %}secs{% endif %}</span></p>
 | |
| 
 | |
|         </div>
 | |
| 
 | |
|         <div class="w-full s:w-fit flex flex-col s:flex-row justify-end items-center gap-3">
 | |
|             <button
 | |
|                 class="w-full s:w-fit text-base px-3 py-2 bg-red-500 text-white outline-none border border-red-500 rounded-md cursor-pointer hover:bg-white hover:text-red-500 duration-300 deleteTaskButton"
 | |
|                 data-modal-url="{% url 'deletetaskmodal' task.id %}">Delete
 | |
|                 Task</button>
 | |
|             <a href="{% url 'edittask' task.task_id %}" class="w-full s:w-fit">
 | |
|                 <button
 | |
|                     class="w-full s:w-fit text-base px-3 py-2 bg-secondosiblue text-white outline-none border border-secondosiblue rounded-md cursor-pointer hover:bg-white hover:text-secondosiblue duration-300">Edit
 | |
|                     Task</button>
 | |
|             </a>
 | |
|         </div>
 | |
|     </div>
 | |
| 
 | |
| 
 | |
|     <div class="w-full flex flex-col gap-4 mt-5">
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Description: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.description}}</span></p>
 | |
|         </div>
 | |
| 
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Project: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.project.name}}</span></p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Epic: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.epic.title}}</span></p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Start Date: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.start_date}}</span></p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">End Date: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.end_date}}</span></p>
 | |
|         </div>
 | |
| 
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Assigned To: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.assigned_to.user.first_name}}
 | |
|                     {{task.assigned_to.user.last_name}}</span></p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Extra: <span
 | |
|                     class="text-slate-800 text-xl font-semibold">{{task.extra}}</span></p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Status:
 | |
|                 {% if task.status == 'Closed' %}
 | |
|                 <span class="text-green-700 text-xl font-semibold">{{task.status}}</span>
 | |
|                 {% endif %}
 | |
|                 {% if task.status == 'Open' %}
 | |
|                 <span class="text-osiblue text-xl font-semibold">{{task.status}}</span>
 | |
|                 {% endif %}
 | |
|                 {% if task.status == 'Working On' %}
 | |
|                 <span class="text-yellow-500 text-xl font-semibold">{{task.status}}</span>
 | |
|                 {% endif %}
 | |
|             </p>
 | |
|         </div>
 | |
| 
 | |
|         <div>
 | |
|             <p class="text-gray-500 text-xl">Related Files: <span class="text-slate-800 text-xl">Documentation.pdf,
 | |
|                     Project.doc</span>
 | |
|             </p>
 | |
|         </div>
 | |
| 
 | |
| 
 | |
|         <!-- POINTS -->
 | |
|         <div class="mt-5 relative">
 | |
|             <div
 | |
|                 class=" bg-osiblue rounded-t-md flex justify-between items-center text-white text-xl font-bold h-[50px]">
 | |
|                 <div class="px-3">
 | |
|                     <p class="text-white uppercase font-bold">Points</p>
 | |
|                 </div>
 | |
| 
 | |
|                 <button
 | |
|                     class="h-full rounded-tr-md px-4 bg-gray-300 text-osiblue text-[18px] outline-none border-none cursor-pointer flex justify-center items-center addPointButton"
 | |
|                     data-modal-url="{% url 'addpointmodal' task.task_id %}">
 | |
|                     <i class="fa fa-plus"></i>
 | |
|                 </button>
 | |
|             </div>
 | |
| 
 | |
|             <div class="overflow-x-auto">
 | |
|                         {% if points %}
 | |
|                         {% for point in points %}
 | |
|                         <p class="pointId" data-point-id="{{ point.id }}" style="display: none;">{{ point.id }}</p>
 | |
|                         <div class="w-full flex flex-col gap-1 
 | |
|                         {% if point.status == 'Completed' %}
 | |
|                             bg-green-700
 | |
|                         {% elif point.status == 'Working On' %}
 | |
|                                 bg-orange-500
 | |
|                         {% elif point.status == 'Paused' %}
 | |
|                                 bg-red-500
 | |
|                         {% else %}
 | |
|                                 bg-slate-700
 | |
|                         {% endif %}
 | |
|                          bg-opacity-50 rounded-md shadow-md p-3 mt-4">
 | |
|                             <div class="w-full flex justify-between items-end pb-2 border-b border-gray-200">
 | |
|                                 <div class="w-[380px]">
 | |
|                                     {% if point.status == 'Completed' %}
 | |
|                                     <p class="text-white line-through">{{point.text}}</p>
 | |
|                                     {% else %}
 | |
|                                     <p class="text-white">{{point.text}}</p>
 | |
|                                     {% endif %}
 | |
|                                 </div>
 | |
|                                 <div class="flex justify-end items-center gap-2">
 | |
|                                     {% if point.status == 'Not Completed' or point.status == 'Paused' and not point.status == 'Completed' %}
 | |
|                                     <a href="{% url 'mark_point_working_on_task_page' point.id task.id %}">
 | |
|                                         <button
 | |
|                                             class="w-[40px] h-[40px] rounded-full bg-transparent shadow-md text-white border border-white flex justify-center items-center hover:scale-105 transition-transform duration-300"
 | |
|                                             id="startPointButton">
 | |
|                                             <i class="fa fa-play"></i>
 | |
|                                         </button>
 | |
|                                     </a> 
 | |
|                                     {% endif %}
 | |
|             
 | |
|                                     {% if point.status == 'Working On' and not point.status == 'Completed'  %}
 | |
|                                     <a href="{% url 'mark_point_paused_task_page' point.id task.id %}">
 | |
|                                         <button
 | |
|                                             class="w-[40px] h-[40px] rounded-full bg-transparent shadow-md text-white border border-white justify-center items-center hover:scale-105 transition-transform duration-300"
 | |
|                                             id="pausePointButton">
 | |
|                                             <i class="fa fa-pause"></i>
 | |
|                                         </button>
 | |
|                                     </a>
 | |
|                                     {% endif %}
 | |
|             
 | |
|                                     {% if not point.status == 'Completed' and not point.status == 'Paused' %}
 | |
|                                     <a href="{% url 'mark_point_completed_task_page' point.id task.id %}">
 | |
|                                         <button
 | |
|                                             class="w-[40px] h-[40px] rounded-full bg-transparent shadow-md text-white border border-white flex justify-center items-center hover:scale-105 transition-transform duration-300">
 | |
|                                             <i class="fa fa-check"></i>
 | |
|                                         </button>
 | |
|                                     </a>
 | |
|                                     {% endif %}
 | |
|             
 | |
|             
 | |
|                                     {% if point.status == 'Completed' %}
 | |
|                                     <button
 | |
|                                         class="w-[40px] h-[40px] rounded-full bg-transparent shadow-md text-white border border-white flex justify-center items-center opacity-30 cursor-default">
 | |
|                                         <i class="fa fa-check"></i>
 | |
|                                     </button>
 | |
|                                     {% endif %} 
 | |
|             
 | |
|                                     {% if not point.status == 'Completed' %}
 | |
|                                     <form method="post" action="{% url 'deletepointmodal' point.id task.id %}">
 | |
|                                         {% csrf_token %}
 | |
|                                         <button type="submit"
 | |
|                                             class="w-[40px] h-[40px] bg-transparent border border-white rounded-full text-white flex justify-center items-center shadow-md hover:scale-105 transition-transform duration-300">
 | |
|                                             <i class="fa fa-trash"></i>
 | |
|                                         </button>
 | |
|                                     </form>
 | |
|                                     {% endif %}
 | |
|                                 </div>
 | |
|                             </div>
 | |
|             
 | |
|                             <div class="flex justify-between items-center gap-3 pt-2">
 | |
|                                 <div class="text-white text-sm">
 | |
|                                     <p>Total Time:
 | |
|                                         <span class="font-semibold pointTotalTime">
 | |
|                                             <span class="hours">{{ point.total_activity_time.0 }}</span> hours,
 | |
|                                             <span class="minutes">{{ point.total_activity_time.1 }}</span> minutes,
 | |
|                                             <span class="seconds">{{ point.total_activity_time.2 }}</span> seconds
 | |
|                                         </span>
 | |
|                                     </p>
 | |
|                                 </div>
 | |
|             
 | |
|                                 <div class="w-fit py-1 px-2 bg-white text-slate-700 text-xs rounded-md shadow-md">
 | |
|                                     {% if point.status == 'Completed' %}
 | |
|                                     <p class="text-green-700 opacity-50">Completed</p>
 | |
|                                     {% elif point.status == 'Working On' %}
 | |
|                                     <p class="text-orange-500 opacity-50">Working On</p>
 | |
|                                     {% elif point.status == 'Paused' %}
 | |
|                                     <p class="text-red-500 opacity-50">Paused</p>
 | |
|                                     {% else %}
 | |
|                                     <p class="text-slate-700 opacity-50">Created</p>
 | |
|                                     {% endif %}
 | |
|                                 </div>
 | |
|                             </div>
 | |
|                         </div>            
 | |
|                         {% endfor %}
 | |
|                         {% else %}
 | |
|                         <tr>
 | |
|                             <td colspan="3" class="px-6 py-4 text-center text-sm text-slate-800">
 | |
|                                 No Available Points
 | |
|                             </td>
 | |
|                         </tr>
 | |
|                         {% endif %}
 | |
|                     </tbody>
 | |
|                 </table>
 | |
|             </div>
 | |
|         </div>
 | |
| 
 | |
| 
 | |
|         <!-- TAGS -->
 | |
|         <div class="mt-5">
 | |
|             <p class="text-gray-500 text-xl">Tags:</p>
 | |
|             <div class="w-full h-fit mt-3 flex flex-wrap justify-start items-center gap-3">
 | |
|                 <button
 | |
|                     class="text-sm text-gray-400 border border-gray-400 rounded-md w-fit py-2 px-3 outline-none cursor-pointer">Media
 | |
|                     Streaming</button>
 | |
| 
 | |
|                 <button
 | |
|                     class="text-sm text-gray-400 border border-gray-400 rounded-md w-fit py-2 px-3 outline-none cursor-pointer">Live
 | |
|                     Streaming</button>
 | |
| 
 | |
|                 <button
 | |
|                     class="text-sm text-gray-400 border border-gray-400 rounded-md w-fit py-2 px-3 outline-none cursor-pointer">Audio
 | |
|                     On Demand</button>
 | |
|             </div>
 | |
|         </div>
 | |
|     </div>
 | |
| </div>
 | |
| 
 | |
| 
 | |
| <!-- POPUP MODAL -->
 | |
| <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden inset-0" id="popUpModal">
 | |
|     <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">
 | |
|         <button class="absolute top-3 right-5 text-slate-800 text-xl cursor-pointer outline-none border-none"
 | |
|             id="closeModalButton">
 | |
|             <i class="fa fa-close"></i>
 | |
|         </button>
 | |
|         <iframe id="popupModalFrame" frameborder="0"></iframe>
 | |
|     </div>
 | |
| </div>
 | |
| <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
 | |
| 
 | |
| 
 | |
| {% endblock content %} |