Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set deleted_by field when deleting XForms asynchronously #1798

Merged
merged 1 commit into from
Mar 13, 2020

Conversation

DavisRayM
Copy link
Contributor

Changes / Features implemented

  • Track users who initiate asynchronous deletion of XForms

Steps taken to verify this change does what is intended

  • Updated tests

Side effects of implementing this change

  • None

Closes #1797

Copy link
Contributor

@ivermac ivermac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added a single comment

xform.pk,
request.user.id).task_id,
u'time_async_triggered': datetime.now(),
u'triggered_by': request.user.username}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need triggered_by since we'll be saving the user who triggered the delete?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly kept it they're for information purposes (if that makes sense) wanted to be extra verbose. On the first async task status just in case.

TL;DR: We don't really need it

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool, let's remove it for now and may be add it when we need it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've removed the triggered_by field in the latest commits. Please have a look @ivermac

@DavisRayM DavisRayM force-pushed the 1797-track-user-xform-deletion branch from a05822b to 55a3bfa Compare March 13, 2020 02:06
Copy link
Contributor

@ivermac ivermac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me

@DavisRayM DavisRayM merged commit f63360f into master Mar 13, 2020
@DavisRayM DavisRayM deleted the 1797-track-user-xform-deletion branch March 13, 2020 11:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Track users who initiate asynchronous xform deletions
2 participants