mirror of
https://github.com/grocy/grocy.git
synced 2025-10-12 16:44:55 +00:00
Fixed a problem with newer SQLite versions (references and fixes #133)
This commit is contained in:
@@ -29,6 +29,15 @@ FROM recipes_pos_old;
|
||||
|
||||
DROP TABLE recipes_pos_old;
|
||||
|
||||
DROP TRIGGER cascade_change_qu_id_stock;
|
||||
CREATE TRIGGER cascade_change_qu_id_stock AFTER UPDATE ON products
|
||||
BEGIN
|
||||
UPDATE recipes_pos
|
||||
SET qu_id = (SELECT qu_id_stock FROM products WHERE id = NEW.id)
|
||||
WHERE product_id IN (SELECT id FROM products WHERE id = NEW.id)
|
||||
AND only_check_single_unit_in_stock = 0;
|
||||
END;
|
||||
|
||||
DROP VIEW recipes_fulfillment;
|
||||
CREATE VIEW recipes_fulfillment
|
||||
AS
|
||||
|
Reference in New Issue
Block a user