diff --git a/index.html b/index.html index 048fed7..8c36c5a 100644 --- a/index.html +++ b/index.html @@ -2042,7 +2042,8 @@ `; }, - assignedInternCard(internFloId, taskId) { + assignedInternCard(internFloId, taskId, options = {}) { + const { shouldShowOptions = false } = options const { hasDeadlinePassed, elapsedPercentage, taskDeadline } = getTaskDeadline(taskId, internFloId) const taskCompleted = RIBC.getInternRecord(internFloId).completedTasks.hasOwnProperty(taskId) let taskStatus = 'In Progress'; @@ -2056,7 +2057,7 @@ } let isInProgress = !taskCompleted && !hasDeadlinePassed let optionsButton - if (taskId && !taskCompleted) { + if (shouldShowOptions && taskId && !taskCompleted) { optionsButton = html` `; @@ -2115,7 +2116,7 @@ const assignedInterns = RIBC.getAssignedInterns(appState.params.id, appState.params.branch, task) const status = RIBC.getTaskStatus(appState.params.id, appState.params.branch, task) const { title, description, category, maxSlots, duration, durationType, reward } = RIBC.getTaskDetails(appState.params.id, appState.params.branch, task) - let assignedInternsCards = assignedInterns.map(internFloId => render.assignedInternCard(internFloId, `${appState.params.id}_${appState.params.branch}_${task}`)) + let assignedInternsCards = assignedInterns.map(internFloId => render.assignedInternCard(internFloId, `${appState.params.id}_${appState.params.branch}_${task}`, { showOptions: true })) const branches = getAllBranches(appState.params.id) const branchesButtons = filterMap(branches, (branch) => { const { branchName, parentBranch, startPoint, endPoint } = branch