gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-merchant] 07/14: small update of the styling


From: gnunet
Subject: [taler-merchant] 07/14: small update of the styling
Date: Sun, 08 Dec 2024 14:18:16 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository merchant.

commit e1c8683890a309c1be83e41adcc5205d83f69950
Author: bohdan-potuzhnyi <bohdan.potuzhnyi@gmail.com>
AuthorDate: Sat Nov 30 17:37:14 2024 +0100

    small update of the styling
---
 src/backenddb/merchant-0013.sql | 262 ++++++++++++++++++++++++++++++----------
 1 file changed, 199 insertions(+), 63 deletions(-)

diff --git a/src/backenddb/merchant-0013.sql b/src/backenddb/merchant-0013.sql
index b1981731..ef3efbb4 100644
--- a/src/backenddb/merchant-0013.sql
+++ b/src/backenddb/merchant-0013.sql
@@ -63,10 +63,18 @@ BEGIN
     LOOP
       -- Resolve placeholders for the current webhook
       resolved_body := webhook.body_template;
-      resolved_body := replace_placeholder(resolved_body, 'webhook_type', 
'category_added');
-      resolved_body := replace_placeholder(resolved_body, 'category_serial', 
NEW.category_serial::TEXT);
-      resolved_body := replace_placeholder(resolved_body, 'category_name', 
NEW.category_name);
-      resolved_body := replace_placeholder(resolved_body, 'merchant_serial', 
my_merchant_serial::TEXT);
+      resolved_body := replace_placeholder(resolved_body,
+                                           'webhook_type',
+                                           'category_added');
+      resolved_body := replace_placeholder(resolved_body,
+                                           'category_serial',
+                                           NEW.category_serial::TEXT);
+      resolved_body := replace_placeholder(resolved_body,
+                                           'category_name',
+                                           NEW.category_name);
+      resolved_body := replace_placeholder(resolved_body,
+                                           'merchant_serial',
+                                           my_merchant_serial::TEXT);
 
       -- Insert into pending webhooks for this webhook
       INSERT INTO merchant_pending_webhooks
@@ -106,10 +114,12 @@ BEGIN
                                            NEW.category_name);
       resolved_body := replace_placeholder(resolved_body,
                                            'category_name_i18n',
-                                           encode(NEW.category_name_i18n, 
'escape'));
+                                           encode(NEW.category_name_i18n,
+                                                  'escape'));
       resolved_body := replace_placeholder(resolved_body,
                                            'old_category_name_i18n',
-                                           encode(OLD.category_name_i18n, 
'escape'));
+                                           encode(OLD.category_name_i18n,
+                                                  'escape'));
 
       -- Insert into pending webhooks for this webhook
       INSERT INTO merchant_pending_webhooks
@@ -191,21 +201,54 @@ BEGIN
       LOOP
         -- Resolve placeholders for the current webhook
         resolved_body := webhook.body_template;
-        resolved_body := replace_placeholder(resolved_body, 'webhook_type', 
'inventory_added');
-        resolved_body := replace_placeholder(resolved_body, 'product_serial', 
NEW.product_serial::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'product_id', 
NEW.product_id);
-        resolved_body := replace_placeholder(resolved_body, 'description', 
NEW.description);
-        resolved_body := replace_placeholder(resolved_body, 
'description_i18n', encode(NEW.description_i18n, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'unit', NEW.unit);
-        resolved_body := replace_placeholder(resolved_body, 'image', 
NEW.image);
-        resolved_body := replace_placeholder(resolved_body, 'taxes', 
encode(NEW.taxes, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'price', 
NEW.price::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_stock', 
NEW.total_stock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_sold', 
NEW.total_sold::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_lost', 
NEW.total_lost::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'address', 
encode(NEW.address, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'next_restock', 
NEW.next_restock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'minimum_age', 
NEW.minimum_age::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'webhook_type',
+                                             'inventory_added');
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_serial',
+                                             NEW.product_serial::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_id',
+                                             NEW.product_id);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description',
+                                             NEW.description);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description_i18n',
+                                             encode(NEW.description_i18n,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'unit',
+                                             NEW.unit);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'image',
+                                             NEW.image);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'taxes',
+                                             encode(NEW.taxes,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'price',
+                                             NEW.price::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_stock',
+                                             NEW.total_stock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_sold',
+                                             NEW.total_sold::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_lost',
+                                             NEW.total_lost::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'address',
+                                             encode(NEW.address,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'next_restock',
+                                             NEW.next_restock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'minimum_age',
+                                             NEW.minimum_age::TEXT);
 
         -- Insert into pending webhooks for this webhook
         INSERT INTO merchant_pending_webhooks
@@ -231,33 +274,93 @@ BEGIN
       LOOP
         -- Resolve placeholders for the current webhook
         resolved_body := webhook.body_template;
-        resolved_body := replace_placeholder(resolved_body, 'webhook_type', 
'inventory_updated');
-        resolved_body := replace_placeholder(resolved_body, 'product_serial', 
NEW.product_serial::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'product_id', 
NEW.product_id);
-        resolved_body := replace_placeholder(resolved_body, 'old_description', 
OLD.description);
-        resolved_body := replace_placeholder(resolved_body, 'description', 
NEW.description);
-        resolved_body := replace_placeholder(resolved_body, 
'old_description_i18n', encode(OLD.description_i18n, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 
'description_i18n', encode(NEW.description_i18n, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'old_unit', 
OLD.unit);
-        resolved_body := replace_placeholder(resolved_body, 'unit', NEW.unit);
-        resolved_body := replace_placeholder(resolved_body, 'old_image', 
OLD.image);
-        resolved_body := replace_placeholder(resolved_body, 'image', 
NEW.image);
-        resolved_body := replace_placeholder(resolved_body, 'old_taxes', 
encode(OLD.taxes, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'taxes', 
encode(NEW.taxes, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'old_price', 
OLD.price::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'price', 
NEW.price::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'old_total_stock', 
OLD.total_stock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_stock', 
NEW.total_stock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'old_total_sold', 
OLD.total_sold::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_sold', 
NEW.total_sold::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'old_total_lost', 
OLD.total_lost::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_lost', 
NEW.total_lost::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'old_address', 
encode(OLD.address, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'address', 
encode(NEW.address, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 
'old_next_restock', OLD.next_restock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'next_restock', 
NEW.next_restock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'old_minimum_age', 
OLD.minimum_age::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'minimum_age', 
NEW.minimum_age::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'webhook_type',
+                                             'inventory_updated');
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_serial',
+                                             NEW.product_serial::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_id',
+                                             NEW.product_id);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_description',
+                                             OLD.description);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description',
+                                             NEW.description);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_description_i18n',
+                                             encode(OLD.description_i18n,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description_i18n',
+                                             encode(NEW.description_i18n,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_unit',
+                                             OLD.unit);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'unit',
+                                             NEW.unit);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_image',
+                                             OLD.image);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'image',
+                                             NEW.image);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_taxes',
+                                             encode(OLD.taxes,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'taxes',
+                                             encode(NEW.taxes,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_price',
+                                             OLD.price::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'price',
+                                             NEW.price::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_total_stock',
+                                             OLD.total_stock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_stock',
+                                             NEW.total_stock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_total_sold',
+                                             OLD.total_sold::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_sold',
+                                             NEW.total_sold::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_total_lost',
+                                             OLD.total_lost::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_lost',
+                                             NEW.total_lost::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_address',
+                                             encode(OLD.address,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'address',
+                                             encode(NEW.address,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_next_restock',
+                                             OLD.next_restock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'next_restock',
+                                             NEW.next_restock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'old_minimum_age',
+                                             OLD.minimum_age::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'minimum_age',
+                                             NEW.minimum_age::TEXT);
 
         -- Insert into pending webhooks for this webhook
         INSERT INTO merchant_pending_webhooks
@@ -283,21 +386,54 @@ BEGIN
       LOOP
         -- Resolve placeholders for the current webhook
         resolved_body := webhook.body_template;
-        resolved_body := replace_placeholder(resolved_body, 'webhook_type', 
'inventory_deleted');
-        resolved_body := replace_placeholder(resolved_body, 'product_serial', 
OLD.product_serial::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'product_id', 
OLD.product_id);
-        resolved_body := replace_placeholder(resolved_body, 'description', 
OLD.description);
-        resolved_body := replace_placeholder(resolved_body, 
'description_i18n', encode(OLD.description_i18n, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'unit', OLD.unit);
-        resolved_body := replace_placeholder(resolved_body, 'image', 
OLD.image);
-        resolved_body := replace_placeholder(resolved_body, 'taxes', 
encode(OLD.taxes, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'price', 
OLD.price::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_stock', 
OLD.total_stock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_sold', 
OLD.total_sold::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'total_lost', 
OLD.total_lost::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'address', 
encode(OLD.address, 'escape'));
-        resolved_body := replace_placeholder(resolved_body, 'next_restock', 
OLD.next_restock::TEXT);
-        resolved_body := replace_placeholder(resolved_body, 'minimum_age', 
OLD.minimum_age::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'webhook_type',
+                                             'inventory_deleted');
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_serial',
+                                             OLD.product_serial::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'product_id',
+                                             OLD.product_id);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description',
+                                             OLD.description);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'description_i18n',
+                                             encode(OLD.description_i18n,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'unit',
+                                             OLD.unit);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'image',
+                                             OLD.image);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'taxes',
+                                             encode(OLD.taxes,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'price',
+                                             OLD.price::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_stock',
+                                             OLD.total_stock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_sold',
+                                             OLD.total_sold::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'total_lost',
+                                             OLD.total_lost::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'address',
+                                             encode(OLD.address,
+                                                    'escape'));
+        resolved_body := replace_placeholder(resolved_body,
+                                             'next_restock',
+                                             OLD.next_restock::TEXT);
+        resolved_body := replace_placeholder(resolved_body,
+                                             'minimum_age',
+                                             OLD.minimum_age::TEXT);
 
         -- Insert into pending webhooks for this webhook
         INSERT INTO merchant_pending_webhooks

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]