Fix permission bug when adding row in mobile receiving

This commit is contained in:
Lance Edgar 2018-01-29 17:56:36 -06:00
parent beadc08002
commit 024f09dbd4

View file

@ -277,7 +277,7 @@ class ReceivingBatchView(PurchasingBatchView):
'form': form, 'form': form,
} }
if self.request.has_perm('{}.edit'.format(self.get_row_permission_prefix())): if self.request.has_perm('{}.create_row'.format(self.get_permission_prefix())):
update_form = forms.SimpleForm(self.request, schema=ReceivingForm) update_form = forms.SimpleForm(self.request, schema=ReceivingForm)
if update_form.validate(): if update_form.validate():
row = update_form.data['row'] row = update_form.data['row']