mirror of
https://github.com/docusealco/docuseal
synced 2026-11-05 22:52:32 -05:00
allow to remove template permanently
This commit is contained in:
1 parent
bbe3942056
commit
ccc06fcc3d
1 file changed
+5
-1
@@ -38,7 +38,11 @@ module Api
|
|||||||
end
|
end
|
||||||
|
|
||||||
def destroy
|
def destroy
|
||||||
@template.update!(archived_at: Time.current)
|
if params[:permanently] == 'true' && !Docuseal.multitenant?
|
||||||
|
@template.destroy!
|
||||||
|
else
|
||||||
|
@template.update!(archived_at: Time.current)
|
||||||
|
end
|
||||||
|
|
||||||
render json: @template.as_json(only: %i[id archived_at])
|
render json: @template.as_json(only: %i[id archived_at])
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in new issue
Block a user