add item match permission
This commit is contained in:
parent
0438eb0b6a
commit
6abf3af6c0
2 changed files with 20 additions and 1 deletions
17
core/inventory/migrations/0003_alter_item_options.py
Normal file
17
core/inventory/migrations/0003_alter_item_options.py
Normal file
|
@ -0,0 +1,17 @@
|
|||
# Generated by Django 4.2.7 on 2024-01-07 18:46
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('inventory', '0002_container_deleted_at_container_is_deleted_and_more'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterModelOptions(
|
||||
name='item',
|
||||
options={'permissions': [('match_item', 'Can match item')]},
|
||||
),
|
||||
]
|
|
@ -29,7 +29,9 @@ class Item(SoftDeleteModel):
|
|||
|
||||
class Meta:
|
||||
unique_together = (('uid', 'event'),)
|
||||
|
||||
permissions = [
|
||||
('match_item', 'Can match item')
|
||||
]
|
||||
|
||||
class Container(SoftDeleteModel):
|
||||
cid = models.AutoField(primary_key=True)
|
||||
|
|
Loading…
Reference in a new issue