diff options
| author | FIN-IT_AndriFP <andrifebriyadiputra@gmail.com> | 2025-12-03 09:35:16 +0700 |
|---|---|---|
| committer | FIN-IT_AndriFP <andrifebriyadiputra@gmail.com> | 2025-12-03 09:35:16 +0700 |
| commit | a6ce141542392888f8191e0e0dd4ccd6abf1b334 (patch) | |
| tree | 342e368823dcce3f83297c9cd359244ede337709 /indoteknik_custom/models/stock_inventory.py | |
| parent | 0a5376fe987ca2a6656d9b63c52b939c33150a21 (diff) | |
| parent | 015269c0268f2cd9a38ad708c8e26bf85a79fcf3 (diff) | |
Merge branch 'odoo-backup' of https://bitbucket.org/altafixco/indoteknik-addons into odoo-backup
Diffstat (limited to 'indoteknik_custom/models/stock_inventory.py')
| -rw-r--r-- | indoteknik_custom/models/stock_inventory.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/indoteknik_custom/models/stock_inventory.py b/indoteknik_custom/models/stock_inventory.py index 69cca5bc..432d9225 100644 --- a/indoteknik_custom/models/stock_inventory.py +++ b/indoteknik_custom/models/stock_inventory.py @@ -52,6 +52,11 @@ class StockInventory(models.Model): return "00001" # Jika format tidak valid, mulai dari 00001 return "00001" # Jika belum ada data, mulai dari 00001 + def action_start(self): + if self.env.user.id not in [21, 17, 6277]: + raise UserError("Hanya Rafly, denise, dan faisal yang bisa start inventory") + return super(StockInventory, self).action_start() + @api.model def create(self, vals): """Pastikan nomor hanya dibuat saat penyimpanan.""" |
