Commit 3ee68787 authored by Daniel Thonon's avatar Daniel Thonon

Merge branch 'master' into 'develop'

Wrong key for form comments

See merge request !56
parents 7cc681ae a2ffbcf9
......@@ -325,7 +325,7 @@ CREATE OR REPLACE FUNCTION update_forms() RETURNS TRIGGER AS \$\$
coord_lon = CAST(NEW.item->>'lon' AS FLOAT),
coord_x_local = CAST(NEW.item->>'coord_x_local' AS FLOAT),
coord_y_local = CAST(NEW.item->>'coord_y_local' AS FLOAT),
comments = NEW.item->>'comments',
comments = NEW.item->>'comment',
protocol_name = NEW.item #>>'{protocol,protocol_name}',
protocol = CAST(NEW.item->>'protocol' AS JSONB)
WHERE id = OLD.id AND site = OLD.site ;
......@@ -350,7 +350,7 @@ CREATE OR REPLACE FUNCTION update_forms() RETURNS TRIGGER AS \$\$
CAST(NEW.item->>'lon' AS FLOAT),
CAST(NEW.item->>'coord_x_local' AS FLOAT),
CAST(NEW.item->>'coord_y_local' AS FLOAT),
NEW.item->>'comments',
NEW.item->>'comment',
NEW.item #>>'{protocol,protocol_name}',
CAST(NEW.item->>'protocol' AS JSONB)
);
......@@ -378,7 +378,7 @@ CREATE OR REPLACE FUNCTION update_forms() RETURNS TRIGGER AS \$\$
CAST(NEW.item->>'lon' AS FLOAT),
CAST(NEW.item->>'coord_x_local' AS FLOAT),
CAST(NEW.item->>'coord_y_local' AS FLOAT),
NEW.item->>'comments',
NEW.item->>'comment',
NEW.item #>>'{protocol,protocol_name}',
CAST(NEW.item->>'protocol' AS JSONB)
);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment