New changes.

main
nataly 1 year ago
parent 29d7a73520
commit 7994b1d8bd

Binary file not shown.

@ -317,6 +317,15 @@ def createtask_project(request, project_id):
return render(request, 'add_pages/createtask-project.html', context) return render(request, 'add_pages/createtask-project.html', context)
@login_required
def create_user_story_task(request):
context = {
}
return render(request, 'add_pages/create-user-story-task.html', context)
@login_required @login_required
def create_project(request): def create_project(request):
staffs = StaffProfile.objects.all().order_by('-id') staffs = StaffProfile.objects.all().order_by('-id')

@ -42,6 +42,7 @@ urlpatterns = [
path('createepic/<str:project_id>/', views.create_epic, name='createepic'), path('createepic/<str:project_id>/', views.create_epic, name='createepic'),
path('createtask/', views.create_task, name='createtask'), path('createtask/', views.create_task, name='createtask'),
path('createtask/<str:project_id>/', views.createtask_project, name='createtaskproject'), path('createtask/<str:project_id>/', views.createtask_project, name='createtaskproject'),
path('createuserstorytask/', views.create_user_story_task, name='createuserstorytask'),
path('createtaskepic/', views.createtask_epic, name='createtaskepic'), path('createtaskepic/', views.createtask_epic, name='createtaskepic'),
path('projecttypes/', views.project_types, name='projecttypes'), path('projecttypes/', views.project_types, name='projecttypes'),
path('businesstypes/', views.business_types, name='businesstypes'), path('businesstypes/', views.business_types, name='businesstypes'),

@ -774,6 +774,10 @@ video {
margin-left: 0px; margin-left: 0px;
} }
.ml-4 {
margin-left: 1rem;
}
.ml-\[300px\] { .ml-\[300px\] {
margin-left: 300px; margin-left: 300px;
} }
@ -866,6 +870,10 @@ video {
height: 3.5rem; height: 3.5rem;
} }
.h-5 {
height: 1.25rem;
}
.h-\[100px\] { .h-\[100px\] {
height: 100px; height: 100px;
} }
@ -874,6 +882,10 @@ video {
height: 10px; height: 10px;
} }
.h-\[1283px\] {
height: 1283px;
}
.h-\[13px\] { .h-\[13px\] {
height: 13px; height: 13px;
} }
@ -930,18 +942,10 @@ video {
height: 60px; height: 60px;
} }
.h-\[630px\] {
height: 630px;
}
.h-\[70px\] { .h-\[70px\] {
height: 70px; height: 70px;
} }
.h-\[80px\] {
height: 80px;
}
.h-fit { .h-fit {
height: -moz-fit-content; height: -moz-fit-content;
height: fit-content; height: fit-content;
@ -963,6 +967,10 @@ video {
width: 12rem; width: 12rem;
} }
.w-5 {
width: 1.25rem;
}
.w-\[120px\] { .w-\[120px\] {
width: 120px; width: 120px;
} }
@ -1051,10 +1059,6 @@ video {
width: 80%; width: 80%;
} }
.w-\[80px\] {
width: 80px;
}
.w-\[90\%\] { .w-\[90\%\] {
width: 90%; width: 90%;
} }
@ -2317,6 +2321,11 @@ video {
color: rgb(59 130 246 / var(--tw-text-opacity)); color: rgb(59 130 246 / var(--tw-text-opacity));
} }
.hover\:text-gray-700:hover {
--tw-text-opacity: 1;
color: rgb(55 65 81 / var(--tw-text-opacity));
}
.hover\:text-green-700:hover { .hover\:text-green-700:hover {
--tw-text-opacity: 1; --tw-text-opacity: 1;
color: rgb(21 128 61 / var(--tw-text-opacity)); color: rgb(21 128 61 / var(--tw-text-opacity));

@ -0,0 +1,18 @@
const addReqButton = document.getElementById("addReqButton");
const addReqContainerTemplate = document.getElementById("addReqContainerTemplate");
const addReqContainer = document.getElementById("addReqContainer");
addReqButton.addEventListener("click", function () {
// Clone the template and remove the "hidden" class
const newContainer = addReqContainerTemplate.cloneNode(true);
newContainer.classList.remove("hidden");
// Add an event listener to the new container's remove button
const removeReqButton = newContainer.querySelector("#removeReqButton");
removeReqButton.addEventListener("click", function () {
// Remove the clicked container when the remove button is clicked
newContainer.remove();
});
addReqContainer.appendChild(newContainer);
});

@ -0,0 +1,33 @@
// WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN AND THE UPLOADED IMAGE WILL APPEAR IN THE USER PROFILE IMAGE CONTAINER
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
const imageContainer = document.getElementById('image-container');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const file = selectedFiles[0];
const fileReader = new FileReader();
fileReader.onload = function () {
const imgElement = document.createElement('img');
imgElement.src = fileReader.result;
imgElement.alt = 'Uploaded Image';
imgElement.classList.add('w-full', 'h-full', 'rounded-full', 'object-cover');
// Clear any previous images and append the new one
imageContainer.innerHTML = '';
imageContainer.appendChild(imgElement);
// Update the text in the file input
fileNameSpan.textContent = file.name;
};
// Read the selected file as a data URL
fileReader.readAsDataURL(file);
} else {
fileNameSpan.textContent = 'Upload Profile Picture';
imageContainer.innerHTML = ''; // Clear the container if no file is selected
}
});

@ -0,0 +1,26 @@
// WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN
document.addEventListener('DOMContentLoaded', function() {
const fileInputs = document.querySelectorAll('.file-input');
fileInputs.forEach(fileInput => {
const fileNameSpan = fileInput.parentElement.querySelector('.file-name');
const fileLabel = fileInput.parentElement.querySelector('.file-label');
// Event listener to the label "file-label", which triggers a click on the hidden file input "file-input"
fileLabel.addEventListener('click', () => {
fileInput.click();
});
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
});
});

@ -12,79 +12,91 @@
<form method="POST" action="{% url 'save_business' %}" enctype="multipart/form-data"> <form method="POST" action="{% url 'save_business' %}" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<input name="name" type="text" placeholder="Name" <div class="w-full flex flex-col gap-5">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <div class="w-full">
<label class="text-gray-500">Name:</label>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md mt-4"> <input name="name" type="text"
<div class="flex items-center justify-between"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
<input name="logo" required type="file" id="actual-btn" accept="image/*" hidden /> </div>
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload Business
Logo</span>
<label for="actual-btn"
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
class="fa fa-upload"></i></label>
<div class="w-full">
<label class="text-gray-500">Business Logo:</label>
<div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<div class="flex items-center justify-between">
<input name="logo" required type="file" class="file-input" accept="image/*" hidden />
<span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
Logo</span>
<label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div>
</div> </div>
</div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN -->
<script>
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
</script>
<input name="email" type="email" placeholder="Email" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <label class="text-gray-500">Email:</label>
<input name="email" type="email"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="financial_number" type="number" placeholder="Financial Number" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <label class="text-gray-500">Financial Number:</label>
<input name="financial_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<div class="w-full flex justify-start items-center gap-2 mt-1">
<input name="vat" type="checkbox" id="vatCheckbox" onchange="updateVatValue(this.checked)">
<label class="text-slate-800">Vat</label>
</div>
<div class="w-full flex justify-start items-center gap-2 mt-4">
<input name="vat" type="checkbox" id="vatCheckbox" onchange="updateVatValue(this.checked)">
<label class="text-slate-800">Vat</label>
</div>
<script>
function updateVatValue(checked) {
const vatInput = document.querySelector('input[name="vat"]');
vatInput.value = checked ? "true" : "false";
}
</script>
<script> <div class="w-full">
function updateVatValue(checked) { <label class="text-gray-500">Commercial Registration:</label>
const vatInput = document.querySelector('input[name="vat"]'); <input name="commercial_registration" type="commercial_registration"
vatInput.value = checked ? "true" : "false"; class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
} </div>
</script>
<input name="commercial_registration" type="commercial_registration" placeholder="Commercial registration"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required>
<input name="phone_number" type="number" placeholder="Mobile Number" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <label class="text-gray-500">Mobile Number:</label>
<input name="phone_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="website" type="text" placeholder="Website" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4"> <label class="text-gray-500">Website:</label>
<input name="website" type="url"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<select name="type" id="business_type" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-4"> <label class="text-gray-500">Business Type:</label>
<option value="" selected disabled>Business Type</option> <select name="type" id="business_type"
{% for business_type in business_types %} class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="{{ business_type.id }}">{{ business_type.name }}</option> {% for business_type in business_types %}
{% endfor %} <option value="{{ business_type.id }}">{{ business_type.name }}</option>
</select> {% endfor %}
</select>
</div>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button type="submit" <button type="submit"
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add
Business</button> Business</button>
</div>
</div> </div>
</form> </form>
</div> </div>
</div> </div>
@ -100,7 +112,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -9,46 +9,68 @@
</h1> </h1>
<form method="POST" action="{% url 'save_customer' %}"> <form method="POST" action="{% url 'save_customer' %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<input name="first_name" type="text" placeholder="First Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">First Name:</label>
<input name="first_name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="last_name" type="text" placeholder="Last Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Last Name:</label>
<input name="last_name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="email" type="email" placeholder="Email" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Email:</label>
<input name="email" type="email"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="mobile_number" type="number" placeholder="Mobile Number" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Mobile Number:</label>
<input name="mobile_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<div class="w-full">
<label class="text-gray-500">Personal Website:</label>
<input name="personal_website" type="url"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<input name="personal_website" type="url" placeholder="Personal Website" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md"> <label class="text-gray-500">Status:</label>
<select name="status" <select name="status"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
required> required>
<option value="" selected disabled>Status</option> <option value="Active">Active</option>
<option value="Active">Active</option> <option value="Suspended">Suspended</option>
<option value="Suspended">Suspended</option> <option value="Terminated">Terminated</option>
<option value="Terminated">Terminated</option> </select>
</select> </div>
<select name="referenceid" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500" <label class="text-gray-500">Reference:</label>
required> <select name="referenceid"
<option value="" selected disabled>Reference</option> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
{% for reference in references %} required>
<option value="{{reference.id}}">{{reference.name}}</option> {% for reference in references %}
{% endfor %} <option value="{{reference.id}}">{{reference.name}}</option>
</select> {% endfor %}
</select>
<select id="businessTypeSelect" </div>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Type</option> <div class="w-full">
<option value="business">Business</option> <label class="text-gray-500">Type:</label>
<option value="personal">Personal</option> <select id="businessTypeSelect"
</select> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="personal">Personal</option>
<option value="business">Business</option>
</select>
</div>
<div class="w-[80%] mx-auto border border-gray-300 rounded-md py-5 px-3 bg-white hidden" <div class="w-[80%] mx-auto border border-gray-300 rounded-md py-5 px-3 bg-white hidden"
id="addBusinessContainer"> id="addBusinessContainer">
@ -64,10 +86,10 @@
</button> </button>
</div> </div>
<div class="w-full mt-2"> <div class="w-full">
<label class="text-gray-500">Business Name:</label>
<select name="business" id="businessSelect" <select name="business" id="businessSelect"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" selected disabled>Business Name</option>
{% for business in businesses %} {% for business in businesses %}
<option value="{{business.id}}">{{business.name}}</option> <option value="{{business.id}}">{{business.name}}</option>
{% endfor %} {% endfor %}
@ -89,7 +111,6 @@
addBusinessContainer.style.display = 'none'; addBusinessContainer.style.display = 'none';
} }
}); });
</script> </script>
<input name="password1" type="password" placeholder="Password" <input name="password1" type="password" placeholder="Password"
@ -112,83 +133,99 @@
<form method="POST" action="{% url 'save_business_modal' %}" id="addBusinessFormModal" <form method="POST" action="{% url 'save_business_modal' %}" id="addBusinessFormModal"
enctype="multipart/form-data"> enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<input name="name" type="text" placeholder="Name"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md mt-4">
<div class="flex items-center justify-between">
<input name="logo" required type="file" id="actual-btn" accept="image/*" hidden />
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload
Business
Logo</span>
<label for="actual-btn"
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
class="fa fa-upload"></i></label>
<div class="w-full flex flex-col gap-5">
<div class="w-full">
<label class="text-gray-500">Name:</label>
<input name="name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
required>
</div> </div>
</div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN -->
<script>
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
</script>
<input name="email" type="email" placeholder="Email" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <label class="text-gray-500">Business Logo:</label>
<div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<div class="flex items-center justify-between">
<input name="logo" required type="file" class="file-input" accept="image/*" hidden />
<span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
Logo</span>
<label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div>
</div>
<input name="financial_number" type="number" placeholder="Financial Number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required>
<div class="w-full flex justify-start items-center gap-2 mt-4"> <div class="w-full">
<input name="vat" type="checkbox" id="vatCheckbox" onchange="updateVatValue(this.checked)"> <label class="text-gray-500">Email:</label>
<label class="text-slate-800">Vat</label> <input name="email" type="email"
</div> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
required>
</div>
<div class="w-full">
<label class="text-gray-500">Financial Number:</label>
<input name="financial_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
required>
</div>
<div class="w-full flex justify-start items-center gap-2 mt-1">
<input name="vat" type="checkbox" id="vatCheckbox" onchange="updateVatValue(this.checked)">
<label class="text-slate-800">Vat</label>
</div>
<script>
function updateVatValue(checked) {
const vatInput = document.querySelector('input[name="vat"]');
vatInput.value = checked ? "true" : "false";
}
</script>
<input name="commercial_registration" type="commercial_registration" <script>
placeholder="Commercial registration" function updateVatValue(checked) {
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> const vatInput = document.querySelector('input[name="vat"]');
vatInput.value = checked ? "true" : "false";
}
</script>
<div class="w-full">
<label class="text-gray-500">Commercial Registration:</label>
<input name="commercial_registration" type="commercial_registration"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
required>
</div>
<input name="phone_number" type="number" placeholder="Mobile Number" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4" required> <label class="text-gray-500">Mobile Number:</label>
<input name="phone_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
required>
</div>
<input name="website" type="text" placeholder="Website" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-4"> <label class="text-gray-500">Website:</label>
<input name="website" type="url"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<select name="type" id="business_type" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-4"> <label class="text-gray-500">Business Type:</label>
<option value="" selected disabled>Business Type</option> <select name="type" id="business_type"
{% for business_type in business_types %} class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="{{ business_type.id }}">{{ business_type.name }}</option> {% for business_type in business_types %}
{% endfor %} <option value="{{ business_type.id }}">{{ business_type.name }}</option>
</select> {% endfor %}
</select>
</div>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button type="submit" <button type="submit"
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500" class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500"
id="addBusinessFormButton">Add id="addBusinessFormButton">Add
Business</button> Business</button>
</div>
</div> </div>
</form> </form>
</div> </div>
@ -281,7 +318,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -9,91 +9,66 @@
<h1 class="text-3xl text-slate-800 text-center font-semibold"> <h1 class="text-3xl text-slate-800 text-center font-semibold">
Add Staff Add Staff
</h1> </h1>
<!-- <div class="w-[80px] h-[80px] rounded-full border border-gray-200" id="image-container">
<img src="{% static 'images/avatar.svg' %}" alt="" srcset="" id="" class="rounded-full w-full h-full">
</div> -->
</div> </div>
<form method="POST" action="{% url 'save_staff' %}" enctype="multipart/form-data"> <form method="POST" action="{% url 'save_staff' %}" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200" id="image-container"> <div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200"
id="image-container">
<img src="{% static 'images/default-user.png' %}" alt="" srcset="" id="" <img src="{% static 'images/default-user.png' %}" alt="" srcset="" id=""
class="rounded-full w-full h-full"> class="rounded-full w-full h-full">
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md"> <div class="w-full">
<div class="flex items-center justify-between"> <label class="text-gray-500">Profile Picture:</label>
<input name="image" type="file" id="actual-btn" accept="image/*" hidden /> <div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md mt-1">
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <div class="flex items-center justify-between">
Profile Picture</span> <input name="image" type="file" id="actual-btn" accept="image/*" hidden />
<label for="actual-btn" <span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i Picture</span>
class="fa fa-upload" style="font-size: 20px;"></i></label> <label for="actual-btn"
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
class="fa fa-upload" style="font-size: 20px;"></i></label>
</div>
</div> </div>
</div> </div>
<div class="w-full">
<label class="text-gray-500">First Name:</label>
<input name="first_name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN AND THE UPLOADED IMAGE WILL APPEAR IN THE USER PROFILE IMAGE CONTAINER --> <div class="w-full">
<script> <label class="text-gray-500">Last Name:</label>
const fileInput = document.getElementById('actual-btn'); <input name="last_name" type="text"
const fileNameSpan = document.getElementById('file-name'); class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
const imageContainer = document.getElementById('image-container'); </div>
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const file = selectedFiles[0];
const fileReader = new FileReader();
fileReader.onload = function () {
const imgElement = document.createElement('img');
imgElement.src = fileReader.result;
imgElement.alt = 'Uploaded Image';
imgElement.classList.add('w-full', 'h-full', 'rounded-full', 'object-cover');
// Clear any previous images and append the new one
imageContainer.innerHTML = '';
imageContainer.appendChild(imgElement);
// Update the text in the file input
fileNameSpan.textContent = file.name;
};
// Read the selected file as a data URL
fileReader.readAsDataURL(file);
} else {
fileNameSpan.textContent = 'Upload Profile Picture';
imageContainer.innerHTML = ''; // Clear the container if no file is selected
}
});
</script>
<input name="first_name" type="text" placeholder="First Name"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required>
<input name="last_name" type="text" placeholder="Last Name"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required>
<input name="email" type="email" placeholder="Email" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Email:</label>
<input name="email" type="email"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="mobile_number" type="number" placeholder="Mobile Number" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Mobile Number:</label>
<input name="mobile_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<!-- <input name="position" type="text" placeholder="Position"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> -->
<select name="staff_position" id="" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <label class="text-gray-500">Position:</label>
<option value="" selected disabled>Position</option> <select name="staff_position"
{% for position in staffpositions %} class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="{{position.id}}">{{position.name}}</option> {% for position in staffpositions %}
{% endfor %} <option value="{{position.id}}">{{position.name}}</option>
</select> {% endfor %}
</select>
</div>
<div class="w-full flex justify-start items-center gap-2"> <div class="w-full flex justify-start items-center gap-2">
<input name="active" type="checkbox" id="activeCheckbox" <input name="active" type="checkbox" id="activeCheckbox"
@ -119,12 +94,17 @@
} }
</script> </script>
<div class="w-full">
<label class="text-gray-500">Password:</label>
<input name="password1" type="password"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div>
<input name="password1" type="password" placeholder="Password" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> <label class="text-gray-500">Password Confirmation:</label>
<input name="password2" type="password"
<input name="password2" type="password" placeholder="Password" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md" required> </div>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button type="submit" <button type="submit"
@ -149,7 +129,12 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-image-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -7,26 +7,34 @@
<h1 class="text-3xl text-slate-800 text-center font-semibold"> <h1 class="text-3xl text-slate-800 text-center font-semibold">
Create Epic For {{project.name}} Create Epic For {{project.name}}
</h1> </h1>
<form class="mx-auto w-full flex flex-col gap-3 justify-center items-center mt-5" method="POST" action="{% url 'save_epic' %}"> <form class="mx-auto w-full flex flex-col gap-5 justify-center items-center mt-5" method="POST"
action="{% url 'save_epic' %}">
{% csrf_token %} {% csrf_token %}
<input required name="title" type="text" placeholder="Epic Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md"> <label class="text-gray-500">Epic Name:</label>
<input required name="title" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<select required name="project" id="project" class="hidden w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <select required name="project" id="project"
<option value="{{ project.id }}" selected>{{ project.name }}</option> class="hidden w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="{{ project.id }}" selected>{{ project.name }}</option>
</select> </select>
<textarea required name="description" type="text" placeholder="Epic Description" rows="5" cols="5" <div class="w-full">
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea> <label class="text-gray-500">Epic Description:</label>
<textarea required name="description" type="text" placeholder="Description..." rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1"></textarea>
</div>
<select required name="status" id="" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <label class="text-gray-500">Status:</label>
<option value="" selected disabled>Select Status</option> <select required name="status" id=""
<option value="Open">Open</option> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="Closed">Closed</option> <option value="Open">Open</option>
</select> <option value="Closed">Closed</option>
</select>
</div>
<div class="w-full"> <div class="w-full">
<label class="text-gray-500">Start Date:</label> <label class="text-gray-500">Start Date:</label>

@ -8,104 +8,104 @@
Create Project Create Project
</h1> </h1>
<form class="w-full flex flex-col gap-3 justify-center items-center mt-5" method="POST" <form class="w-full flex flex-col gap-5 justify-center items-center mt-5" method="POST"
action="{% url 'save_project' %}"> action="{% url 'save_project' %}">
{% csrf_token %} {% csrf_token %}
<input required name="name" type="text" placeholder="Project Name"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md">
<select required name="customer" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Clients</option>
{% for customer in customers %}
<option value="{{customer.user.username}}">{{customer.user.first_name}} {{customer.user.last_name}}</option>
{% endfor %}
</select>
<select required name="manager" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Project Manager</option>
{% for staff in staffs %}
<option value="{{staff.user.username}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
{% endfor %}
</select>
<select required name="members" id=""
class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"
multiple>
<option value="" selected disabled>Member(s)</option>
{% for staff in staffs %}
<option value="{{staff.user.username}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
{% endfor %}
</select>
<select required name="status" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Status</option>
<option value="Pending">Pending</option>
<option value="Active">Active</option>
<option value="Completed">Completed</option>
<option value="Cancelled">Cancelled</option>
</select>
<select required name="project_type" id=""
class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"
multiple>
<option value="" selected disabled>Project Type</option>
{%for type in project_types %}
<option value="{{type.id}}">{{type.name}}</option>
{% endfor %}
</select>
<textarea required name="details" type="text" placeholder="Project Details" rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea>
<div class="w-full p-3 border border-gray-300 mt-4 rounded-md">
<div class="w-full mt-2" id="addReqContainer">
<input name="requirements" type="text" placeholder="Requirement"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none">
</div>
<!-- THE CLONED CONTAINER --> <div class="w-full">
<div class="mt-2 hidden" id="addReqContainerTemplate"> <label class="text-gray-500">Project Name:</label>
<div class="w-full flex flex-col gap-2"> <input required name="name" type="text"
<input name="requirements" type="text" placeholder="Requirement" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none"> </div>
<button
class="w-full h-[40px] s:h-[55px] rounded-md bg-gray-300 border-none outline-none shadow-md text-white text-xl cursor-pointer py-2" <div class="w-full">
id="removeReqButton" type="button"> <label class="text-gray-500">Clients:</label>
<i class="fa fa-minus"></i> <select required name="customer"
</button> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
</div> {% for customer in customers %}
</div> <option value="{{customer.user.username}}">{{customer.user.first_name}} {{customer.user.last_name}}
</option>
{% endfor %}
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Project Manager:</label>
<select required name="manager" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
{% for staff in staffs %}
<option value="{{staff.user.username}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
{% endfor %}
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Member(s):</label>
<select required name="members" id=""
class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
multiple>
{% for staff in staffs %}
<option value="{{staff.user.username}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
{% endfor %}
</select>
</div>
<button <div class="w-full">
class="w-full h-[40px] s:h-[55px] rounded-md bg-gray-400 border-none outline-none shadow-md text-white text-xl cursor-pointer py-2 mt-2" <label class="text-gray-500">Status:</label>
id="addReqButton" type="button"> <select required name="status" id=""
<i class="fa fa-plus"></i> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
</button> <option value="Pending">Pending</option>
<option value="Active">Active</option>
<option value="Completed">Completed</option>
<option value="Cancelled">Cancelled</option>
</select>
</div> </div>
<script> <div class="w-full">
const addReqButton = document.getElementById("addReqButton"); <label class="text-gray-500">Project Type:</label>
const addReqContainerTemplate = document.getElementById("addReqContainerTemplate"); <select required name="project_type"
const addReqContainer = document.getElementById("addReqContainer"); class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
multiple>
{%for type in project_types %}
<option value="{{type.id}}">{{type.name}}</option>
{% endfor %}
</select>
</div>
addReqButton.addEventListener("click", function () { <div class="w-full">
// Clone the template and remove the "hidden" class <label class="text-gray-500">Project Details:</label>
const newContainer = addReqContainerTemplate.cloneNode(true); <textarea required name="details" type="text" rows="5" cols="5"
newContainer.classList.remove("hidden"); class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1"></textarea>
</div>
// Add an event listener to the new container's remove button <div class="w-full">
const removeReqButton = newContainer.querySelector("#removeReqButton"); <label class="text-gray-500">Requirement(s):</label>
removeReqButton.addEventListener("click", function () { <div class="w-full p-3 border border-gray-300 mt-1 rounded-md">
// Remove the clicked container when the remove button is clicked <div class="w-full mt-2" id="addReqContainer">
newContainer.remove(); <input name="requirements" type="text" placeholder="Requirement"
}); class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none">
</div>
addReqContainer.appendChild(newContainer); <!-- THE CLONED CONTAINER -->
}); <div class="mt-2 hidden" id="addReqContainerTemplate">
</script> <div class="w-full flex flex-col gap-2">
<input name="requirements" type="text" placeholder="Requirement"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none">
<button
class="w-full h-[40px] s:h-[55px] rounded-md bg-gray-300 border-none outline-none shadow-md text-white text-xl cursor-pointer py-2"
id="removeReqButton" type="button">
<i class="fa fa-minus"></i>
</button>
</div>
</div>
<button
class="w-full h-[40px] s:h-[55px] rounded-md bg-gray-400 border-none outline-none shadow-md text-white text-xl cursor-pointer py-2 mt-2"
id="addReqButton" type="button">
<i class="fa fa-plus"></i>
</button>
</div>
</div>
<div class="w-full"> <div class="w-full">
<label class="text-gray-500">Start Date:</label> <label class="text-gray-500">Start Date:</label>
@ -140,6 +140,9 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/add-project.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>

@ -10,43 +10,57 @@
Create Task Create Task
</h1> </h1>
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<input type="text" placeholder="Task Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md"> <label class="text-gray-500">Task Name:</label>
<input type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
<select id="" </div>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Select Project</option> <div class="w-full">
<option value="">Cars & Classics</option> <label class="text-gray-500">Project:</label>
<option value="">Osina</option> <select
</select> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="">Cars & Classics</option>
<select id="" <option value="">Osina</option>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> </select>
<option value="" selected disabled>Select Epic</option> </div>
<option value="">Epic 1</option>
<option value="">Epic 2</option> <div class="w-full">
<option value="">Epic 3</option> <label class="text-gray-500">Epic:</label>
</select> <select
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<select id="" <option value="" selected disabled>Select Epic</option>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <option value="">Epic 1</option>
<option value="" selected disabled>Status</option> <option value="">Epic 2</option>
<option value="">Open</option> <option value="">Epic 3</option>
<option value="">Working On</option> </select>
<option value="">Closed</option> </div>
</select>
<div class="w-full">
<select required id="" <label class="text-gray-500">Status:</label>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <select
<option value="" selected disabled>Assigned To</option> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="Pending">Nataly</option> <option value="">Open</option>
<option value="Active">Salim</option> <option value="">Working On</option>
</select> <option value="">Closed</option>
</select>
<textarea type="text" placeholder="Task Description" rows="5" cols="5" </div>
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea>
<div class="w-full">
<label class="text-gray-500">Assigned To:</label>
<select required
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="Pending">Nataly</option>
<option value="Active">Salim</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Description:</label>
<textarea type="text" placeholder="Description.." rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea>
</div>
<div class="w-full"> <div class="w-full">
<label class="text-gray-500">Extra:</label> <label class="text-gray-500">Extra:</label>
@ -69,34 +83,21 @@
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md"> <div class="w-full">
<div class="flex items-center justify-between"> <label class="text-gray-500">Documents:</label>
<input required name="cv" type="file" id="actual-btn" accept=".pdf,.docx" hidden multiple /> <div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <div class="flex items-center justify-between">
Document(s)</span> <input name="" required type="file" class="file-input" accept=".pdf,.docx" hidden multiple />
<label for="actual-btn" <span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i Document(s)</span>
class="fa fa-upload"></i></label> <label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div> </div>
</div> </div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN -->
<script>
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
</script>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button <button
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add
@ -119,7 +120,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -0,0 +1,135 @@
{% extends "main.html" %}
{%load static%}
{% block content %}
<!-- THIS TASK BELONGS TO A USER STORY ADDED FROM PROJECT DETAILS PAGE -->
<div class="w-full px-5 s:px-9 mb-4">
<div class="w-full h-full shadow-md rounded-md mt-5 py-5 px-3 bg-white">
<h1 class="text-3xl text-slate-800 text-center font-semibold">
Create Task
</h1>
<div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<div class="w-full">
<label class="text-gray-500 text-base">Name:</label>
<input type="text" placeholder="Name"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<div class="w-full">
<label class="text-gray-500 text-base">User Story:</label>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" selected>Predifined</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500 text-base">Epic:</label>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" selected>Select Epic</option>
<option value="">Epic 1</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500 text-base">Project:</label>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" selected>Predifined</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500 text-base">Status:</label>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="">Open</option>
<option value="">Working On</option>
<option value="">Closed</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500 text-base">Assigned To:</label>
<select required id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="">Nataly</option>
<option value="">Salim</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500 text-base">Task Description:</label>
<textarea type="text" placeholder="Description..." rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1"></textarea>
</div>
<div class="w-full">
<label class="text-gray-500">Extra:</label>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" selected>No</option>
<option value="">Yes</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Start Date:</label>
<input type="date" id="date" name="date"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div>
<div class="w-full">
<label class="text-gray-500">End Date:</label>
<input type="date" id="date" name="date"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div>
<div class="w-full">
<label class="text-gray-500">Documents:</label>
<div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<div class="flex items-center justify-between">
<input name="" required type="file" class="file-input" accept=".pdf,.docx" hidden multiple />
<span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
Document(s)</span>
<label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div>
</div>
</div>
<div class="w-full flex justify-center items-center mt-3">
<button
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add
Task</button>
</div>
</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" 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>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div>
{% endblock content %}

@ -10,39 +10,56 @@
Create Task Create Task
</h1> </h1>
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<input type="text" placeholder="Task Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md"> <label class="text-gray-500">Task Name:</label>
<input type="text"
<select id="" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 cursor-not-allowed" </div>
disabled>
<option value="">Test 1</option>
</select> <div class="w-full">
<label class="text-gray-500">Project Name:</label>
<select id="" <select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 cursor-not-allowed" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 cursor-not-allowed mt-1"
disabled> disabled>
<option value="">Epic</option> <option value="">Test 1</option>
</select> </select>
</div>
<select id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <div class="w-full">
<option value="" selected disabled>Status</option> <label class="text-gray-500">Epic:</label>
<option value="">Open</option> <select id=""
<option value="">Working On</option> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 cursor-not-allowed mt-1"
<option value="">Closed</option> disabled>
</select> <option value="">Epic</option>
</select>
<select required id="" </div>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="" selected disabled>Assigned To</option> <div class="w-full">
<option value="Pending">Nataly</option> <label class="text-gray-500">Status:</label>
<option value="Active">Salim</option> <select id=""
</select> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="">Open</option>
<textarea type="text" placeholder="Task Description" rows="5" cols="5" <option value="">Working On</option>
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea> <option value="">Closed</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Assigned To:</label>
<select required
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="Pending">Nataly</option>
<option value="Active">Salim</option>
</select>
</div>
<div class="w-full">
<label class="text-gray-500">Task Description:</label>
<textarea type="text" placeholder="Description..." rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1"></textarea>
</div>
<div class="w-full"> <div class="w-full">
<label class="text-gray-500">Extra:</label> <label class="text-gray-500">Extra:</label>
@ -65,34 +82,21 @@
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md"> <div class="w-full">
<div class="flex items-center justify-between"> <label class="text-gray-500">Documents:</label>
<input required name="cv" type="file" id="actual-btn" accept=".pdf,.docx" hidden multiple /> <div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <div class="flex items-center justify-between">
Document(s)</span> <input name="" required type="file" class="file-input" accept=".pdf,.docx" hidden multiple />
<label for="actual-btn" <span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i Document(s)</span>
class="fa fa-upload"></i></label> <label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div> </div>
</div> </div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN -->
<script>
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
</script>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button <button
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add
@ -102,6 +106,8 @@
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">
@ -113,7 +119,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -10,45 +10,55 @@
Create Task For {{project.name}} Create Task For {{project.name}}
</h1> </h1>
<form class="w-full flex flex-col gap-3 justify-center items-center mt-5" method="POST" <form class="w-full flex flex-col gap-5 justify-center items-center mt-5" method="POST"
action="{% url 'save_task' %}"> action="{% url 'save_task' %}">
{% csrf_token %} {% csrf_token %}
<input required name="name" type="text" placeholder="Task Name" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md"> <label class="text-gray-500">Task Name:</label>
<input required name="name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<select required name="project" id="" <select required name="project" id=""
class="hidden w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> class="hidden w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500">
<option value="{{project.id}}">{{project.name}}</option> <option value="{{project.id}}">{{project.name}}</option>
</select> </select>
<select required name="epic" id="" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <label class="text-gray-500">Epic:</label>
<option value="" selected disabled>Select Epic</option> <select required name="epic"
{% for epic in epics_of_my_project %} class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="{{epic.id}}">{{epic.title}}</option> {% for epic in epics_of_my_project %}
{% endfor %} <option value="{{epic.id}}">{{epic.title}}</option>
</select> {% endfor %}
</select>
</div>
<select required name="status" id="" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <label class="text-gray-500">Status:</label>
<option value="" selected disabled>Status</option> <select required name="status"
<option value="Open">Open</option> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="Working On">Working On</option> <option value="Open">Open</option>
<option value="Closed">Closed</option> <option value="Working On">Working On</option>
</select> <option value="Closed">Closed</option>
</select>
</div>
<select name="assigned_to" required id="" <div class="w-full">
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500"> <label class="text-gray-500">Assigned To:</label>
<option value="" selected disabled>Assigned To</option> <select name="assigned_to" required
{% for staff in staffs %} class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="{{staff.id}}">{{staff.user.first_name}} {{staff.user.last_name}}</option> {% for staff in staffs %}
{% endfor %} <option value="{{staff.id}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
</select> {% endfor %}
</select>
</div>
<textarea required name="description" type="text" placeholder="Task Description" rows="5" cols="5" <div class="w-full">
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none"></textarea> <label class="text-gray-500">Task Description:</label>
<textarea required name="description" type="text" placeholder="Description..." rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1"></textarea>
</div>
<div class="w-full"> <div class="w-full">
<label class="text-gray-500">Extra:</label> <label class="text-gray-500">Extra:</label>
@ -71,34 +81,21 @@
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md"> <div class="w-full">
<div class="flex items-center justify-between"> <label class="text-gray-500">Documents:</label>
<input name="cv" type="file" id="actual-btn" accept=".pdf,.docx" hidden multiple /> <div class="inbox-box border border-gray-300 w-full rounded-md px-3 mt-1">
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <div class="flex items-center justify-between">
Document(s)</span> <input name="" type="file" class="file-input" accept=".pdf,.docx" hidden multiple />
<label for="actual-btn" <span class="file-name text-gray-500 text-base focus:outline-none outline-none">Upload
class="bg-transparent text-gray-500 border border-white py-2 h-14 cursor-pointer flex items-center"><i Document(s)</span>
class="fa fa-upload"></i></label> <label
class="file-label bg-transparent text-gray-500 border border-white h-14 cursor-pointer flex items-center">
<i class="fa fa-upload" style="font-size: 25px;"></i>
</label>
</div>
</div> </div>
</div> </div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN -->
<script>
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const fileNames = Array.from(selectedFiles).map(file => file.name).join(', ');
fileNameSpan.textContent = fileNames;
} else {
fileNameSpan.textContent = 'Upload Documents (PDF, docx)';
}
});
</script>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button type="submit" <button type="submit"
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Add
@ -119,7 +116,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-input-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -181,7 +181,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -276,7 +276,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -303,10 +303,12 @@
<td class="px-6 py-4 text-center text-sm"> <td class="px-6 py-4 text-center text-sm">
<div class="w-full flex justify-center items-center gap-3"> <div class="w-full flex justify-center items-center gap-3">
<a href="{% url 'createuserstorytask' %}">
<button <button
class="w-fit py-2 px-3 bg-green-700 border border-green-700 text-white rounded-md cursor-pointer hover:bg-white hover:text-green-700">Add class="w-fit py-2 px-3 bg-green-700 border border-green-700 text-white rounded-md cursor-pointer hover:bg-white hover:text-green-700">Add
Task</button> Task</button>
</a>
<a href=""> <a href="">
<div class="text-[15px] text-blue-500 cursor-pointer"> <div class="text-[15px] text-blue-500 cursor-pointer">
<i class="fa fa-edit"></i> <i class="fa fa-edit"></i>
@ -616,7 +618,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -166,7 +166,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -104,17 +104,17 @@
<!-- LEFT SIDE / TASK DETAIL SECTION --> <!-- LEFT SIDE / TASK DETAIL SECTION -->
<div class="w-full xxlg1:w-[75%] bg-white h-fit rounded-md shadow-md p-5"> <div class="w-full xxlg1:w-[75%] bg-white h-fit rounded-md shadow-md p-5">
{% if task.status == 'Open' %} {% if task.status == 'Open' %}
<div class="w-full bg-green-700 rounded-t-md flex flex-col justify-center items-center py-3"> <div class="w-full bg-red-500 rounded-t-md flex flex-col justify-center items-center py-3">
<h1 class="text-3xl text-white font-semibold">{{task.name}}</h1> <h1 class="text-3xl text-white font-semibold">{{task.name}}</h1>
</div> </div>
{% endif %} {% endif %}
{% if task.status == 'Working On' %} {% if task.status == 'Working On' %}
<div class="w-full bg-yellow-400 rounded-t-md flex flex-col justify-center items-center py-3"> <div class="w-full bg-orange-500 rounded-t-md flex flex-col justify-center items-center py-3">
<h1 class="text-3xl text-white font-semibold">{{task.name}}</h1> <h1 class="text-3xl text-white font-semibold">{{task.name}}</h1>
</div> </div>
{% endif %} {% endif %}
{% if task.status == 'Closed' %} {% if task.status == 'Closed' %}
<div class="w-full bg-red-500 rounded-t-md flex flex-col justify-center items-center py-3"> <div class="w-full bg-green-700 rounded-t-md flex flex-col justify-center items-center py-3">
<h1 class="text-3xl text-white font-semibold">{{task.name}}</h1> <h1 class="text-3xl text-white font-semibold">{{task.name}}</h1>
</div> </div>
{% endif %} {% endif %}
@ -385,7 +385,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -11,11 +11,14 @@
<form id="hiddenContent" method="POST" action="{% url 'editbusinesstype' businesstype.id %}"> <form id="hiddenContent" method="POST" action="{% url 'editbusinesstype' businesstype.id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex justify-center items-center"> <div class="w-full flex flex-col justify-center items-center mt-2">
<input name="name" type="text" placeholder="Business Type Name" <div class="w-full">
value="{{businesstype.name}}" <label class="text-gray-500">Business Type:</label>
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4" <input name="name" type="text"
required> value="{{businesstype.name}}"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1"
required>
</div>
</div> </div>
<div class="w-full flex justify-center items-center mt-4"> <div class="w-full flex justify-center items-center mt-4">

@ -11,161 +11,127 @@
<form method="POST" action="{% url 'editbusiness' business.business_id %}" enctype="multipart/form-data"> <form method="POST" action="{% url 'editbusiness' business.business_id %}" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200 mt-2" id="image-container"> <div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200 mt-2"
{% if business.logo %} id="image-container">
{% if business.logo %}
<img src="{{business.logo.url}}" alt="" srcset="" id="" class="rounded-full w-full h-full"> <img src="{{business.logo.url}}" alt="" srcset="" id="" class="rounded-full w-full h-full">
{% else %} {% else %}
<img src="{% static 'images/default-user.png' %}" alt="" srcset="" id="" class="rounded-full w-full h-full"> <img src="{% static 'images/default-user.png' %}" alt="" srcset="" id=""
{% endif %} class="rounded-full w-full h-full">
</div> {% endif %}
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md mt-2"> <div class="w-full flex flex-col gap-3">
<div class="flex items-center justify-between"> <div>
<input name="logo" type="file" id="actual-btn" accept="image/*" hidden /> <label class="text-gray-500">Current Logo:
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <a href="{{business.logo.url}}" class="text-gray-400 cursor-pointer hover:text-slate-800"
New Logo</span> style="word-wrap: break-word;" target="_blank">{{business.logo.url}}</a>
<label for="actual-btn" </label>
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i </div>
class="fa fa-upload" style="font-size: 20px;"></i></label>
</div> <div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md">
</div> <div class="flex items-center justify-between">
<input name="logo" type="file" id="actual-btn" accept="image/*" hidden />
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> New Logo</span>
<div class="w-full mt-4"> <label for="actual-btn"
<label class="text-gray-500 text-xl">Name:</label> class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
<input name="name" type="text" placeholder="Name" class="fa fa-upload" style="font-size: 20px;"></i></label>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" </div>
value="{{business.name}}" </div>
required> </div>
</div>
<div class="w-full">
<label class="text-gray-500 text-xl">Name:</label>
<input name="name" type="text"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
value="{{business.name}}" required>
</div>
<div class="w-full">
<label class="text-gray-500">Email:</label>
<input name="email" type="email"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
value="{{business.email}}" required>
</div>
<div class="w-full">
<label class="text-gray-500 text-xl">Financial Number:</label>
<input name="financial_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
value="{{business.financial_number}}" required>
</div>
<div class="w-full">
<label class="text-gray-500">Commercial Registration:</label>
<input name="commercial_registration" type="commercial_registration"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
value="{{business.commercial_registration}}" required>
</div>
<div class="w-full">
<label class="text-gray-500">Phone Number:</label>
<input name="phone_number" type="number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1"
value="{{business.phone_number}}" required>
</div>
<div class="w-full">
<label class="text-gray-500">Website:</label>
<input name="website" type="text" value="{{business.website}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div>
<div class="w-full">
<label class="text-gray-500">Type</label>
<select name="business_type" id="business_type_select"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
{% if not business.type %}
<option value="" selected>Select Business Type</option>
{% endif %}
{% for type in business_types %}
<option value="{{ type.id }}"
{% if current_business_type and current_business_type.id == type.id %}selected{% endif %}>
{{ type.name }}
</option>
{% endfor %}
</select>
</div>
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN AND THE UPLOADED IMAGE WILL APPEAR IN THE USER PROFILE IMAGE CONTAINER --> <div class="w-full flex justify-start items-center gap-2 mt-1">
<script> <input {% if business.vat %} checked {% endif %} type="checkbox" id="vatCheckbox"
const fileInput = document.getElementById('actual-btn'); onchange="updateVatValue(this.checked)">
const fileNameSpan = document.getElementById('file-name'); <label class="text-gray-500 text-xl" for="vatCheckbox">VAT</label>
const imageContainer = document.getElementById('image-container'); <input type="hidden" name="vat" value="False">
</div>
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const file = selectedFiles[0];
const fileReader = new FileReader();
fileReader.onload = function () {
const imgElement = document.createElement('img');
imgElement.src = fileReader.result;
imgElement.alt = 'Uploaded Image';
imgElement.classList.add('w-full', 'h-full', 'rounded-full', 'object-cover');
// Clear any previous images and append the new one
imageContainer.innerHTML = '';
imageContainer.appendChild(imgElement);
// Update the text in the file input
fileNameSpan.textContent = file.name;
};
// Read the selected file as a data URL
fileReader.readAsDataURL(file);
} else {
fileNameSpan.textContent = 'Upload Profile Picture';
imageContainer.innerHTML = ''; // Clear the container if no file is selected
}
});
<script>
function updateVatValue(checked) {
const vatInput = document.querySelector('input[name="vat"]');
vatInput.value = checked ? 'True' : 'False';
}
</script> </script>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Email:</label>
<input name="email" type="email" placeholder="Email"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"
value="{{business.email}}"
required>
</div>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Financial Number:</label>
<input name="financial_number" type="number" placeholder="Financial Number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"
value="{{business.financial_number}}"
required>
</div>
<div class="w-full mt-4"> <div class="w-full flex justify-center items-center mt-3">
<label class="text-gray-500 text-xl">Commercial Registration:</label> <button type="submit"
<input name="commercial_registration" type="commercial_registration" placeholder="Commercial Registration" class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Save</button>
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" </div>
value="{{business.commercial_registration}}"
required>
</div>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Phone Number:</label>
<input name="phone_number" type="number" placeholder="Phone Number"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"
value="{{business.phone_number}}"
required>
</div> </div>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Website:</label>
<input name="website" type="text" placeholder="Website"
value="{{business.website}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2">
</div>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Type</label>
<select name="business_type" id="business_type_select"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2">
{% if not business.type %}
<option value="" selected>Select Business Type</option>
{% endif %}
{% for type in business_types %}
<option value="{{ type.id }}"
{% if current_business_type and current_business_type.id == type.id %}selected{% endif %}>
{{ type.name }}
</option>
{% endfor %}
</select>
</div>
<div class="w-full flex justify-start items-center gap-2 mt-4">
<input {% if business.vat %} checked {% endif %} type="checkbox" id="vatCheckbox" onchange="updateVatValue(this.checked)">
<label class="text-gray-500 text-xl" for="vatCheckbox">VAT</label>
<input type="hidden" name="vat" value="False">
</div>
<script>
function updateVatValue(checked) {
const vatInput = document.querySelector('input[name="vat"]');
vatInput.value = checked ? 'True' : 'False';
}
</script>
<div class="w-full flex justify-center items-center mt-3">
<button type="submit"
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Save</button>
</div>
</div>
</form> </form>
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">
@ -177,6 +143,10 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-image-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>

@ -10,50 +10,50 @@
<form method="POST" action="{% url 'editcustomer' customer.customer_id %}"> <form method="POST" action="{% url 'editcustomer' customer.customer_id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">First Name:</label> <label class="text-gray-500">First Name:</label>
<input name="first_name" type="text" placeholder="First Name" <input name="first_name" type="text"
value="{{customer.user.first_name}}" value="{{customer.user.first_name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Last Name:</label> <label class="text-gray-500">Last Name:</label>
<input name="last_name" type="text" placeholder="Last Name" <input name="last_name" type="text"
value="{{customer.user.last_name}}" value="{{customer.user.last_name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Email:</label> <label class="text-gray-500">Email:</label>
<input name="email" type="email" placeholder="Email" <input name="email" type="email"
value="{{customer.user.email}}" value="{{customer.user.email}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Mobile Number:</label> <label class="text-gray-500">Mobile Number:</label>
<input name="mobile_number" type="number" placeholder="Mobile Number" <input name="mobile_number" type="number"
value="{{customer.mobile_number}}" value="{{customer.mobile_number}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Personal Website:</label> <label class="text-gray-500">Personal Website:</label>
<input name="personal_website" type="url" placeholder="Personal Website" <input name="personal_website" type="url"
value="{{customer.personal_website}}" value="{{customer.personal_website}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Status:</label> <label class="text-gray-500">Status:</label>
<select name="status" <select name="status"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
required> required>
<option value="" disabled>Status</option> <option value="" disabled>Status</option>
<option value="Active"{% if customer_status == 'Active' %} selected {% endif %}>Active</option> <option value="Active"{% if customer_status == 'Active' %} selected {% endif %}>Active</option>
@ -62,10 +62,10 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Reference:</label> <label class="text-gray-500">Reference:</label>
<select name="reference" <select name="reference"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
required> required>
{% for reference in references %} {% for reference in references %}
<option value="{{ reference.id }}" {% if reference.id == customer_reference.id %} selected {% endif %}> <option value="{{ reference.id }}" {% if reference.id == customer_reference.id %} selected {% endif %}>
@ -76,10 +76,10 @@
</div> </div>
{% if not customer_business %} {% if not customer_business %}
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Type:</label> <label class="text-gray-500">Type:</label>
<select id="businessTypeSelect" <select id="businessTypeSelect"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Type</option> <option value="" disabled>Type</option>
<option value="business" {% if customer.business %} selected {% endif %} >Business</option> <option value="business" {% if customer.business %} selected {% endif %} >Business</option>
<option value="personal" {% if not customer.business %} selected {% endif %}>Personal</option> <option value="personal" {% if not customer.business %} selected {% endif %}>Personal</option>
@ -89,10 +89,10 @@
{% if customer_business %} {% if customer_business %}
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Business:</label> <label class="text-gray-500">Business:</label>
<select name="business" <select name="business"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2" class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
required> required>
{% for business in businesses %} {% for business in businesses %}
<option value="{{ business.id }}" {% if business.id == customer_business.id %} selected {% endif %}> <option value="{{ business.id }}" {% if business.id == customer_business.id %} selected {% endif %}>
@ -148,6 +148,7 @@
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">

@ -8,16 +8,17 @@
Edit Project Type Edit Project Type
</h1> </h1>
<form id="hiddenContent" method="POST" action="{% url 'editprojecttype' projecttype.id %}"> <form id="hiddenContent" method="POST" action="{% url 'editprojecttype' projecttype.id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex justify-center items-center"> <div class="w-full flex flex-col justify-center items-center mt-2">
<input name="name" type="text" placeholder="Project Type Name" <div class="w-full">
value="{{projecttype.name}}" <label class="text-gray-500">Business Type:</label>
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4" <input name="name" type="text" placeholder="Project Type Name" value="{{projecttype.name}}"
required> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1" required>
</div>
</div> </div>
<div class="w-full flex justify-center items-center mt-4"> <div class="w-full flex justify-center items-center mt-4">
<button type="submit" <button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button> class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button>
@ -27,6 +28,8 @@
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">

@ -8,21 +8,20 @@
Edit Project Edit Project
</h1> </h1>
<form class="w-full flex flex-col gap-3 justify-center items-center" method="POST" <form class="w-full flex flex-col gap-5 justify-center items-center" method="POST"
action="{% url 'editproject' project.project_id %}"> action="{% url 'editproject' project.project_id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full">
<div class="w-full mt-4"> <label class="text-gray-500">Name:</label>
<label class="text-gray-500 text-xl">Name:</label> <input required name="name" type="text"
<input required name="name" type="text" placeholder="Name"
value="{{project.name}}" value="{{project.name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Client:</label> <label class="text-gray-500">Client:</label>
<select required name="customer" id="" <select required name="customer"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Clients</option> <option value="" disabled>Clients</option>
{% for customer in customers %} {% for customer in customers %}
<option value="{{customer.id}}" {% if customer.id == current_client.id %} selected {%endif%}>{{customer.user.first_name}} {{customer.user.last_name}}</option> <option value="{{customer.id}}" {% if customer.id == current_client.id %} selected {%endif%}>{{customer.user.first_name}} {{customer.user.last_name}}</option>
@ -30,10 +29,10 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Project Manager:</label> <label class="text-gray-500">Project Manager:</label>
<select required name="manager" id="" <select required name="manager"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Project Manager</option> <option value="" disabled>Project Manager</option>
{% for staff in staffs %} {% for staff in staffs %}
<option value="{{staff.id}}" {% if staff.id == current_manager.id %} selected {%endif%}>{{staff.user.first_name}} {{staff.user.last_name}}</option> <option value="{{staff.id}}" {% if staff.id == current_manager.id %} selected {%endif%}>{{staff.user.first_name}} {{staff.user.last_name}}</option>
@ -42,10 +41,10 @@
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Member(s):</label> <label class="text-gray-500">Member(s):</label>
<select required name="members" id="" <select required name="members" id=""
class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2" class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
multiple> multiple>
{% for staff in staffs %} {% for staff in staffs %}
{% if staff in project.members.all %} {% if staff in project.members.all %}
@ -57,10 +56,10 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Status:</label> <label class="text-gray-500">Status:</label>
<select required name="status" id="" <select required name="status"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Select Status</option> <option value="" disabled>Select Status</option>
<option value="Pending" {% if project.status == 'Pending' %} selected {%endif%}>Pending</option> <option value="Pending" {% if project.status == 'Pending' %} selected {%endif%}>Pending</option>
<option value="Active" {% if project.status == 'Active' %} selected {%endif%}>Active</option> <option value="Active" {% if project.status == 'Active' %} selected {%endif%}>Active</option>
@ -69,10 +68,10 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Type(s):</label> <label class="text-gray-500">Type(s):</label>
<select required name="types" id="" <select required name="types" id=""
class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2" class="w-full h-[100px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1"
multiple> multiple>
{%for type in types %} {%for type in types %}
{% if type in project.project_type.all %} {% if type in project.project_type.all %}
@ -84,25 +83,23 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Description:</label> <label class="text-gray-500">Description:</label>
<textarea required name="details" type="text" placeholder="Project Details" rows="5" cols="5" <textarea required name="details" type="text" rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-2">Lorem ipsum dolor sit amet consectetur adipisicing elit. Illum magnam ea temporibus commodi aspernatur culpa totam similique voluptate veritatis? Odit, excepturi? Itaque suscipit libero iure corrupti consequatur soluta expedita quod? class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1">Lorem ipsum dolor sit amet consectetur adipisicing elit. Illum magnam ea temporibus commodi aspernatur culpa totam similique voluptate veritatis? Odit, excepturi? Itaque suscipit libero iure corrupti consequatur soluta expedita quod?
</textarea> </textarea>
</div> </div>
</div> <div class="w-full">
<label class="text-gray-500">Start Date:</label>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Start Date:</label>
<input required name="start_date" type="date" id="date" name="date" <input required name="start_date" type="date" id="date" name="date"
value="2023-09-22" value="2023-09-22"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-2"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">End Date:</label> <label class="text-gray-500">End Date:</label>
<input required name="end_date" type="date" id="date" name="date" <input required name="end_date" type="date" id="date" name="date"
value="2023-10-22" value="2023-10-22"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-2"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-2">

@ -10,27 +10,31 @@
<form id="hiddenContent" method="POST" action="{% url 'editreference' reference.id %}"> <form id="hiddenContent" method="POST" action="{% url 'editreference' reference.id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col justify-center items-center"> <div class="w-full flex flex-col gap-5 justify-center items-center">
<input name="name" type="text" placeholder="Reference Name" <div class="w-full">
value="{{reference.name}}" <label class="text-gray-500">Reference:</label>
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4" <input name="name" type="text" value="{{reference.name}}"
required> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1" required>
</div>
<input name="date" type="date" id="date"
value="2023-09-22" <div class="w-full">
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4"> <label class="text-gray-500">Date:</label>
</div> <input name="date" type="date" id="date" value="2023-09-22"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
<div class="w-full flex justify-center items-center mt-4"> </div>
<button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button> <div class="w-full flex justify-center items-center mt-4">
<button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button>
</div>
</div> </div>
</form> </form>
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">

@ -10,22 +10,23 @@
<form id="hiddenContent" method="POST"> <form id="hiddenContent" method="POST">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex justify-center items-center"> <div class="w-full flex flex-col gap-5 justify-center items-center">
<input name="name" type="text" placeholder="Staff Position Name" <div class="w-full">
value="one" <label class="text-gray-500">Staff Position:</label>
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4" <input name="name" type="text" value="one"
required> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1" required>
</div>
<div class="w-full flex justify-center items-center mt-4">
<button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button>
</div>
</form>
<div class="w-full flex justify-center items-center mt-4">
<button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button>
</div>
</div>
</form>
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">

@ -10,7 +10,7 @@
<form method="POST" action="{% url 'editstaff' staff.staff_id %}" enctype="multipart/form-data"> <form method="POST" action="{% url 'editstaff' staff.staff_id %}" enctype="multipart/form-data">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex flex-col gap-3 justify-center items-center mt-5"> <div class="w-full flex flex-col gap-5 justify-center items-center mt-5">
<div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200 mt-2" id="image-container"> <div class="w-[70px] s:w-[100px] h-[70px] s:h-[100px] rounded-full border border-gray-200 mt-2" id="image-container">
{% if staff.image %} {% if staff.image %}
<img src="{{staff.image.url}}" alt="" srcset="" id="" class="rounded-full w-full h-full"> <img src="{{staff.image.url}}" alt="" srcset="" id="" class="rounded-full w-full h-full">
@ -19,112 +19,83 @@
{% endif %} {% endif %}
</div> </div>
<div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md"> <div class="w-full flex flex-col gap-3">
<div class="flex items-center justify-between"> <div>
<input name="image" type="file" id="actual-btn" accept="image/*" hidden /> <label class="text-gray-500">Current Image:
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload <a href="{{staff.image.url}}" class="text-gray-400 cursor-pointer hover:text-slate-800" style="word-wrap: break-word;" target="_blank">{{staff.image.url}}</a>
New Profile Picture</span> </label>
<label for="actual-btn" </div>
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
class="fa fa-upload" style="font-size: 20px;"></i></label> <div class="inbox-box border border-gray-300 py-1 px-3 w-full rounded-md">
<div class="flex items-center justify-between">
<input name="image" type="file" id="actual-btn" accept="image/*" hidden />
<span id="file-name" class="text-gray-500 text-base focus:outline-none outline-none">Upload
New Picture</span>
<label for="actual-btn"
class="bg-transparent text-gray-500 border border-white px-4 py-2 h-14 cursor-pointer flex items-center"><i
class="fa fa-upload" style="font-size: 20px;"></i></label>
</div>
</div> </div>
</div> </div>
<div class="w-full">
<!-- WHEN THE USER CHOOSE A FILE THE NAME OF THE FILE WILL APPEAR IN THE SPAN AND THE UPLOADED IMAGE WILL APPEAR IN THE USER PROFILE IMAGE CONTAINER --> <label class="text-gray-500">First Name:</label>
<script> <input name="first_name" type="text"
const fileInput = document.getElementById('actual-btn');
const fileNameSpan = document.getElementById('file-name');
const imageContainer = document.getElementById('image-container');
fileInput.addEventListener('change', (event) => {
const selectedFiles = event.target.files;
if (selectedFiles.length > 0) {
const file = selectedFiles[0];
const fileReader = new FileReader();
fileReader.onload = function () {
const imgElement = document.createElement('img');
imgElement.src = fileReader.result;
imgElement.alt = 'Uploaded Image';
imgElement.classList.add('w-full', 'h-full', 'rounded-full', 'object-cover');
// Clear any previous images and append the new one
imageContainer.innerHTML = '';
imageContainer.appendChild(imgElement);
// Update the text in the file input
fileNameSpan.textContent = file.name;
};
// Read the selected file as a data URL
fileReader.readAsDataURL(file);
} else {
fileNameSpan.textContent = 'Upload Profile Picture';
imageContainer.innerHTML = ''; // Clear the container if no file is selected
}
});
</script>
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">First Name:</label>
<input name="first_name" type="text" placeholder="First Name"
value="{{staff.user.first_name}}" value="{{staff.user.first_name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Last Name:</label> <label class="text-gray-500">Last Name:</label>
<input name="last_name" type="text" placeholder="Last Name" <input name="last_name" type="text"
value="{{staff.user.last_name}}" value="{{staff.user.last_name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Email:</label> <label class="text-gray-500">Email:</label>
<input name="email" type="email" placeholder="Email" <input name="email" type="email"
value="{{staff.user.email}}" value="{{staff.user.email}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Mobile Number:</label> <label class="text-gray-500">Mobile Number:</label>
<input name="mobile_number" type="number" placeholder="Mobile Number" <input name="mobile_number" type="number"
value="{{staff.mobile_number}}" value="{{staff.mobile_number}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2" required> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1" required>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Position:</label> <label class="text-gray-500">Position:</label>
<select name="staff_position" id="" <select name="staff_position" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
{% for position in positions %} {% for position in positions %}
<option {% if current_position and current_position.id == position.id %}selected{% endif %} value="{{position.id}}"> {{position.name}}</option> <option {% if current_position and current_position.id == position.id %}selected{% endif %} value="{{position.id}}"> {{position.name}}</option>
{% endfor %} {% endfor %}
</select> </select>
</div> </div>
{% if staff.active %} {% if staff.active %}
<div class="w-full flex justify-start items-center gap-2 mt-2"> <div class="w-full flex justify-start items-center gap-2">
<input checked type="checkbox" name="active"> <input checked type="checkbox" name="active">
<p class="text-gray-500 text-xl">Active</p> <p class="text-gray-500 text-xl">Active</p>
</div> </div>
{% else %} {% else %}
<div class="w-full flex justify-start items-center gap-2 mt-2"> <div class="w-full flex justify-start items-center gap-2">
<input type="checkbox" name="active"> <input type="checkbox" name="active">
<p class="text-gray-500 text-xl">Active</p> <p class="text-gray-500 text-xl">Active</p>
</div> </div>
{% endif %} {% endif %}
{% if staff.intern %} {% if staff.intern %}
<div class="w-full flex justify-start items-center gap-2 mt-2"> <div class="w-full flex justify-start items-center gap-2">
<input checked type="checkbox" name="intern"> <input checked type="checkbox" name="intern">
<p class="text-gray-500 text-xl">Intern</p> <p class="text-gray-500 text-xl">Intern</p>
</div> </div>
{% else %} {% else %}
<div class="w-full flex justify-start items-center gap-2 mt-2"> <div class="w-full flex justify-start items-center gap-2">
<input type="checkbox" name="intern"> <input type="checkbox" name="intern">
<p class="text-gray-500 text-xl">Intern</p> <p class="text-gray-500 text-xl">Intern</p>
</div> </div>
@ -140,6 +111,7 @@
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">
@ -151,7 +123,11 @@
</div> </div>
</div> </div>
<!-------------- JS SCRIPTS --------------->
<script type="text/javascript" src='{% static "js/upload-image-tag.js" %}'></script>
<script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script> <script type="text/javascript" src='{% static "js/pop-modals.js" %}'></script>
</div> </div>
{% endblock content %} {% endblock content %}

@ -10,23 +10,26 @@
<form id="hiddenContent" method="POST" action="{% url 'edittag' tag.id %}"> <form id="hiddenContent" method="POST" action="{% url 'edittag' tag.id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full flex justify-center items-center"> <div class="w-full flex flex-col gap-5 justify-center items-center">
<input name="name" type="text" placeholder="Tag Name" <div class="w-full">
value="{{tag.name}}" <label class="text-gray-500">Tag Name:</label>
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-4" <input name="name" type="text" value="{{tag.name}}"
required> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1" required>
</div> </div>
<div class="w-full flex justify-center items-center mt-4"> <div class="w-full flex justify-center items-center mt-4">
<button type="submit" <button type="submit"
class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button> class="w-fit bg-blue-500 border border-blue-500 rounded-md text-white text-xl px-3 py-2 hover:bg-white hover:text-blue-500">Save</button>
</div>
</div> </div>
</form> </form>
</div> </div>
</div> </div>
</div> </div>
<!-- POPUP MODAL --> <!-- POPUP MODAL -->
<div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal"> <div class="w-full h-full bg-black bg-opacity-40 z-20 fixed justify-center items-center hidden" id="popUpModal">
<div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative"> <div class="w-[95%] md:w-fit h-fit bg-white rounded-md p-9 relative">

@ -8,53 +8,51 @@
Edit Task Edit Task
</h1> </h1>
<form class="w-full flex flex-col gap-3 justify-center items-center mt-5" method="POST" <form class="w-full flex flex-col gap-5 justify-center items-center mt-5" method="POST"
action="{% url 'edittask' task.task_id %}"> action="{% url 'edittask' task.task_id %}">
{% csrf_token %} {% csrf_token %}
<div class="w-full mt-4">
<label class="text-gray-500 text-xl">Name:</label> <div class="w-full">
<input required name="name" type="text" placeholder="Task Name" <label class="text-gray-500">Name:</label>
<input required name="name" type="text"
value="{{task.name}}" value="{{task.name}}"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md mt-1">
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Project:</label> <label class="text-gray-500">Project:</label>
<select required name="project" id="projectDropdown" <select required name="project" id="projectDropdown"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
{% for project in projects %} {% for project in projects %}
<option value="{{project.id}}" {% if project.id == task.project.id %} selected {% endif %}>{{project.name}}</option> <option value="{{project.id}}" {% if project.id == task.project.id %} selected {% endif %}>{{project.name}}</option>
{% endfor %} {% endfor %}
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Epic:</label> <label class="text-gray-500">Epic:</label>
<select required name="epic" id="epicDropdown" <select required name="epic" id="epicDropdown"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Select Epic</option>
{% for epic in epics_of_my_project %} {% for epic in epics_of_my_project %}
<option value="{{epic.id}}" {% if epic.id == task.epic.id %} selected {% endif %}>{{epic.title}}</option> <option value="{{epic.id}}" {% if epic.id == task.epic.id %} selected {% endif %}>{{epic.title}}</option>
{% endfor %} {% endfor %}
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Status:</label> <label class="text-gray-500">Status:</label>
<select required name="status" id="" <select required name="status"
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Select Status</option>
<option value="Open" selected>Open</option> <option value="Open" selected>Open</option>
<option value="Working On">Working On</option> <option value="Working On">Working On</option>
<option value="Closed">Closed</option> <option value="Closed">Closed</option>
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Assigned To:</label> <label class="text-gray-500">Assigned To:</label>
<select name="assigned_to" required id="" <select name="assigned_to" required id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="" disabled>Assigned To</option>
<option value="{{task.staff.id}}" selected>{{task.staff.user.first_name}} {{task.staff.user.last_name}}</option> <option value="{{task.staff.id}}" selected>{{task.staff.user.first_name}} {{task.staff.user.last_name}}</option>
{% for staff in staffs %} {% for staff in staffs %}
<option value="{{staff.id}}">{{staff.user.first_name}} {{staff.user.last_name}}</option> <option value="{{staff.id}}">{{staff.user.first_name}} {{staff.user.last_name}}</option>
@ -62,38 +60,36 @@
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Description:</label> <label class="text-gray-500">Description:</label>
<textarea required name="description" type="text" placeholder="Task Description" rows="5" cols="5" <textarea required name="description" type="text" rows="5" cols="5"
class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-2">Lorem ipsum dolor sit amet consectetur adipisicing elit. Ab laboriosam cum temporibus itaque vel atque, obcaecati voluptates porro dolorem, magnam quidem nemo corrupti ullam dicta excepturi pariatur inventore voluptatem beatae! class="w-full py-3 px-3 border border-gray-300 outline-none rounded-md resize-none mt-1">Lorem ipsum dolor sit amet consectetur adipisicing elit. Ab laboriosam cum temporibus itaque vel atque, obcaecati voluptates porro dolorem, magnam quidem nemo corrupti ullam dicta excepturi pariatur inventore voluptatem beatae!
</textarea> </textarea>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Extra:</label> <label class="text-gray-500">Extra:</label>
<select required name="extra" id="" <select required name="extra" id=""
class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-2"> class="w-full h-[50px] py-1 px-3 border border-gray-300 outline-none rounded-md text-gray-500 mt-1">
<option value="True">Yes</option> <option value="True">Yes</option>
<option value="False" selected>No</option> <option value="False" selected>No</option>
</select> </select>
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">Start Date:</label> <label class="text-gray-500">Start Date:</label>
<input required name="start_date" type="date" id="date" name="date" <input required name="start_date" type="date" id="date" name="date"
value="2023-09-22" value="2023-09-22"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-2"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="w-full mt-4"> <div class="w-full">
<label class="text-gray-500 text-xl">End Date:</label> <label class="text-gray-500">End Date:</label>
<input required name="end_date" type="date" id="date" name="date" <input required name="end_date" type="date" id="date" name="date"
value="2023-09-22" value="2023-09-22"
class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-2"> class="w-full p-3 border border-gray-300 rounded-md bg-transparent outline-none mt-1">
</div> </div>
<div class="w-full flex justify-center items-center mt-3"> <div class="w-full flex justify-center items-center mt-3">
<button type="submit" <button type="submit"
class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Save</button> class="w-fit py-1 px-3 bg-blue-500 rounded-md outline-none text-white border border-blue-500 text-xl cursor-pointer hover:bg-white hover:text-blue-500">Save</button>
@ -103,6 +99,7 @@
</div> </div>
</div> </div>
<!---------------------- JS SCRIPTS --------------------> <!---------------------- JS SCRIPTS -------------------->
<script src="https://code.jquery.com/jquery-3.6.4.min.js"></script> <script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>

@ -3,7 +3,7 @@
{% block content %} {% block content %}
<style> <style>
/* .bread{ /* .bread{
height:40px; height:40px;
background:red; background:red;
color:#fff; color:#fff;
@ -24,7 +24,7 @@
border-left: 20px solid red; border-left: 20px solid red;
} */ } */
/* .nextbread { /* .nextbread {
height:40px; height:40px;
background:red; background:red;
color:#fff; color:#fff;
@ -43,7 +43,6 @@
border:20px solid transparent; border:20px solid transparent;
border-left: 20px solid red; border-left: 20px solid red;
} */ } */
</style> </style>
@ -144,8 +143,8 @@
</div> </div>
</div> </div>
<!-- <div class="w-full px-5 s:px-9 pb-5"> <div class="w-full px-5 s:px-9 pb-5">
<div class="w-full px-3 py-5 flex items-center bg-white shadow-md rounded-md text-gray-500 font-light"> <!-- <div class="w-full px-3 py-5 flex items-center bg-white shadow-md rounded-md text-gray-500 font-light">
<div <div
class="bread "> class="bread ">
<p>Home</p> <p>Home</p>
@ -155,8 +154,23 @@
class="nextbread "> class="nextbread ">
<p>Home</p> <p>Home</p>
</div> </div>
</div> -->
<div class="flex items-center px-6 py-3 bg-white border-b rounded-md shadow-md">
<a href="#" class="text-sm text-gray-500 hover:text-gray-700">Home</a>
<svg class="w-5 h-5 ml-4 text-gray-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7"></path>
</svg>
<span class="ml-4 text-sm text-gray-500">Previous Page</span>
<svg class="w-5 h-5 ml-4 text-gray-400" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 5l7 7-7 7"></path>
</svg>
<span class="ml-4 text-sm text-gray-500">Current Page</span>
</div> </div>
</div> -->
</div>
<!-- TASKS AND USERS ACTIVITY SECTION --> <!-- TASKS AND USERS ACTIVITY SECTION -->
<div class="w-full flex justify-between gap-5 px-5 s:px-9 pb-5"> <div class="w-full flex justify-between gap-5 px-5 s:px-9 pb-5">
@ -581,7 +595,8 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div
class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -171,7 +171,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -201,7 +201,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -220,7 +220,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -170,7 +170,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -143,7 +143,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -171,7 +171,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -234,7 +234,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -180,7 +180,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -173,7 +173,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -194,7 +194,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -173,7 +173,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

@ -490,7 +490,7 @@
<!-- RIGHT SIDE / USERS ACTIVITY --> <!-- RIGHT SIDE / USERS ACTIVITY -->
{% if latest_statuses_time_ago %} {% if latest_statuses_time_ago %}
<div class="hidden xxlg1:block w-[25%] bg-white h-[630px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5"> <div class="hidden xxlg1:block w-[25%] bg-white h-[1283px] overflow-y-auto overflow-hidden rounded-md shadow-md p-5">
<h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1> <h1 class="text-2xl text-slate-700 text-center font-semibold">USERS ACTIVITY</h1>
<div class="w-full h-fit mt-2" id="activitiesContainer"> <div class="w-full h-fit mt-2" id="activitiesContainer">

Loading…
Cancel
Save