mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-02-06 06:56:54 +08:00
Add editable field to task in tasks tree API call [GIOT-44]
This commit is contained in:
parent
c44c5b37bb
commit
f8334b3d5b
1 changed files with 1 additions and 0 deletions
|
@ -20,6 +20,7 @@ module Api
|
||||||
exp.my_modules.find_each do |tk|
|
exp.my_modules.find_each do |tk|
|
||||||
task = tk.as_json(only: %i(name description archived))
|
task = tk.as_json(only: %i(name description archived))
|
||||||
task['task_id'] = tk.id.to_s
|
task['task_id'] = tk.id.to_s
|
||||||
|
task['editable'] = can_edit_module(tk)
|
||||||
tasks << task
|
tasks << task
|
||||||
end
|
end
|
||||||
experiment['tasks'] = tasks
|
experiment['tasks'] = tasks
|
||||||
|
|
Loading…
Reference in a new issue