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

Deleting attachments on an AR fails when returning to "To be verified" state from "Verified" state. #2164

Open
witekdev opened this issue Aug 6, 2017 · 0 comments
Milestone

Comments

@witekdev
Copy link

witekdev commented Aug 6, 2017

Steps to reproduce

Using the master branch I created an instance with bika.lims test setup data loaded.
I create an AR. I am able to add and delete attachments on the AR without a problem until I reach the Verified State (where I cannot delete attachments by design), so I return to the "To be verified" state and attempt to delete an attachment, which then fails.

Current behavior

Attachment is not deleted. Traceback:

Traceback (innermost last):
  Module ZPublisher.Publish, line 138, in publish
  Module ZPublisher.mapply, line 77, in mapply
  Module ZPublisher.Publish, line 48, in call_object
  Module bika.lims.browser.attachment, line 81, in __call__
  Module bika.lims.browser.attachment, line 100, in action_update
  Module bika.lims.browser.attachment, line 188, in delete_attachment
AttributeError: 'NoneType' object has no attribute 'getAttachment'

Expected behavior

Attachment is deleted

@ramonski ramonski added this to the 3.3.0 milestone Aug 7, 2017
@ramonski ramonski self-assigned this Aug 7, 2017
@ramonski ramonski removed their assignment Dec 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants