File tree 2 files changed +9
-0
lines changed
2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ export default class ProjectsController extends Controller {
18
18
@tracked selectedCustomer ;
19
19
@tracked selectedProject ;
20
20
@tracked selectedTask ;
21
+ @tracked hideArchivedTasks = false ;
21
22
22
23
@lastValue ( "fetchProjectsByUser" ) projects ;
23
24
Original file line number Diff line number Diff line change 101
101
>Add Task</button >
102
102
</span >
103
103
</h3 >
104
+ <SyCheckbox
105
+ data-test-show-archived
106
+ @checked ={{ this.hideArchivedTasks }}
107
+ @value ={{ this.hideArchivedTasks }}
108
+ @onChange ={{ fn (mut this.hideArchivedTasks )}}
109
+ >Hide Archived Tasks</SyCheckbox >
104
110
<ScrollContainer >
105
111
<table
106
112
class =" table table--striped table--projects"
128
134
</thead >
129
135
<tbody >
130
136
{{ #each this.tasks as |task |}}
137
+ {{ #unless (and this.hideArchivedTasks task.archived )}}
131
138
<tr
132
139
class =" pointer {{ if (eq this.selectedTask task ) ' selected' }} "
133
140
{{! template-lint-disable }}
158
165
@checked ={{ task.archived }}
159
166
/></td >
160
167
</tr >
168
+ {{ /unless }}
161
169
{{ /each }}
162
170
</tbody >
163
171
</table >
You can’t perform that action at this time.
0 commit comments