Made reopen button for completed tasks
This commit is contained in:
+10
-4
@@ -407,7 +407,7 @@ function Modal({ children, onClose, title, eyebrow, wide = false }) {
|
||||
);
|
||||
}
|
||||
|
||||
function TaskDetail({ task, allAudit = [], onClose, onMove, onPriority, onComplete }) {
|
||||
function TaskDetail({ task, allAudit = [], onClose, onMove, onPriority, onComplete, onReopen }) {
|
||||
if (!task) return null;
|
||||
const assignee = findUser(task.assignee);
|
||||
const author = findUser(task.addedBy);
|
||||
@@ -487,9 +487,15 @@ function TaskDetail({ task, allAudit = [], onClose, onMove, onPriority, onComple
|
||||
</div>
|
||||
|
||||
<aside className="detail__side">
|
||||
<button className="btn btn--primary btn--full" style={{ marginBottom: '1.5rem' }} onClick={onComplete}>
|
||||
<Icon.Check /> Mark as completed
|
||||
</button>
|
||||
{task.status === 'closed' ? (
|
||||
<button className="btn btn--ghost btn--full" style={{ marginBottom: '1.5rem' }} onClick={onReopen}>
|
||||
<Icon.Arrow /> Reopen task
|
||||
</button>
|
||||
) : (
|
||||
<button className="btn btn--primary btn--full" style={{ marginBottom: '1.5rem' }} onClick={onComplete}>
|
||||
<Icon.Check /> Mark as completed
|
||||
</button>
|
||||
)}
|
||||
|
||||
<Field label="Assigned to">
|
||||
<div className="picker">
|
||||
|
||||
Reference in New Issue
Block a user