Resolved Conflicts

This commit is contained in:
harish
2024-10-07 19:26:28 +05:30
16 changed files with 314 additions and 92 deletions

View File

@@ -9,8 +9,8 @@ spring.h2.console.enabled=true
base-url=http://bandi-api.gepafin.it
isVatCheckGloballyDisabled = false
fe.base.url=http://gepafin-production-fe.s3-website.eu-central-1.amazonaws.com
#fe.base.url=http://gepafin-production-fe.s3-website.eu-central-1.amazonaws.com
fe.base.url=http://bandi.gepafin.it
#SPID configuration
spid.ipd.base.url=https://login.regione.umbria.it
active.profile.folder=production

View File

@@ -539,7 +539,7 @@
<dropColumn tableName="FORM"
columnName="order_no" />
</changeSet>
<changeSet id="03-09-2024_1" author="Rajesh Khore">
<sql>
TRUNCATE TABLE FORM_FIELD RESTART IDENTITY;
@@ -696,7 +696,7 @@
path="classpath:db/dump/inserted_form_field_data_13_09_2024.sql" />
</changeSet>
<changeSet id="12-09-2024_1" author="Rajesh Khore">
<addColumn tableName="flow_edges">
<column name="tracking_id" type="VARCHAR(255)"></column>
@@ -710,6 +710,35 @@
<sqlFile dbms="postgresql"
path="classpath:db/dump/updated_form_field_data_16-09-2024.sql" />
</changeSet>
<changeSet id="23-09-2024_1" author="Harish Bagora" dbms="postgresql">
<!-- Procedure for automatically setting the updated_date -->
<createProcedure>
CREATE OR REPLACE FUNCTION gepafin_schema.clock_timestamp_updated_date_column()
RETURNS TRIGGER
LANGUAGE plpgsql
AS $$
BEGIN
NEW.updated_date = clock_timestamp();
RETURN NEW;
END;
$$;
</createProcedure>
<createProcedure>
CREATE OR REPLACE FUNCTION gepafin_schema.clock_timestamp_created_date_column()
RETURNS TRIGGER
LANGUAGE plpgsql
AS $$
BEGIN
IF NEW.created_date IS NULL THEN
NEW.created_date = clock_timestamp();
END IF;
NEW.updated_date = NEW.created_date;
RETURN NEW;
END;
$$;
</createProcedure>
</changeSet>
<changeSet id="23-09-2024_1" author="Rajesh Khore">
<createTable tableName="saml_response">
@@ -842,4 +871,13 @@
path="classpath:db/dump/updated_form_field_data_03-10-2024.sql" />
</changeSet>
<changeSet id="03-10-2024_2" author="Nisha Kashyap">
<sql>
TRUNCATE TABLE FORM_FIELD RESTART IDENTITY;
</sql>
<sqlFile dbms="postgresql"
path="classpath:db/dump/updated_form_field_data_03-10-2024_1.sql" />
</changeSet>
</databaseChangeLog>

View File

@@ -5,4 +5,5 @@
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.23.xsd">
<include file="db/changelog/db.changelog-1.0.0.xml"/>
<include file="db/changelog/dynamic-triggers.xml" />
</databaseChangeLog>

View File

@@ -0,0 +1,51 @@
<?xml version="1.1" encoding="UTF-8" standalone="no"?>
<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
xmlns:pro="http://www.liquibase.org/xml/ns/pro"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd http://www.liquibase.org/xml/ns/pro http://www.liquibase.org/xml/ns/pro/liquibase-pro-4.0.xsd http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.23.xsd">
<changeSet id="23-09-2024_3" author="Harish Bagora" runAlways="true">
<sql splitStatements="false">
DO $$
DECLARE
r RECORD;
BEGIN
-- Loop through all tables in the schema that have the 'updated_date' column
FOR r IN (
SELECT table_name
FROM information_schema.columns
WHERE column_name = 'updated_date'
AND table_schema = 'gepafin_schema'
)
LOOP
EXECUTE format(
'CREATE OR REPLACE TRIGGER tg_gepafin_schema_updated_at_%I
BEFORE UPDATE ON gepafin_schema.%I
FOR EACH ROW
EXECUTE FUNCTION gepafin_schema.clock_timestamp_updated_date_column()',
r.table_name, r.table_name
);
END LOOP;
-- Loop through all tables in the schema that have the 'created_date' column
FOR r IN (
SELECT table_name
FROM information_schema.columns
WHERE column_name = 'created_date'
AND table_schema = 'gepafin_schema'
)
LOOP
EXECUTE format(
'CREATE OR REPLACE TRIGGER tg_gepafin_schema_created_at_%I
BEFORE INSERT ON gepafin_schema.%I
FOR EACH ROW
EXECUTE FUNCTION gepafin_schema.clock_timestamp_created_date_column()',
r.table_name, r.table_name
);
END LOOP;
END;
$$ LANGUAGE plpgsql;
</sql>
</changeSet>
</databaseChangeLog>

View File

@@ -0,0 +1,101 @@
INSERT INTO FORM_FIELD (SORT_ORDER, NAME, LABEL, DESCRIPTION, SETTINGS, VALIDATORS, CREATED_DATE, UPDATED_DATE)
VALUES
(1, 'textinput', 'Testo Breve', 'Per risposte concise (nomi, titoli, brevi descrizioni)',
'[{"name": "label", "value": "Testo Breve"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": false, "minLength": null, "maxLength": null, "pattern": null, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(2, 'textarea', 'Testo Lungo', 'Campo di testo esteso per paragrafi, descrizioni, proposte',
'[{"name": "label", "value": "Testo Lungo"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": false, "minLength": null, "maxLength": null, "pattern": null, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(3, 'wysiwyg', 'Campo di Testo Formattato', 'Editor avanzato per testo con formattazione',
'[{"name": "label", "value": "Testo Formattato"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": false, "minLength": null, "maxLength": null, "pattern": null, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(4, 'numberinput', 'Campo Numerico', 'Per l''inserimento di valori numerici (quantità, importi, percentuali)',
'[{"name": "label", "value": "Numero"}, {"name": "placeholder", "value": "0"}, {"name": "step", "value": "0"}]',
'{"isRequired": false, "min": null, "max": null, "pattern": null, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(5, 'radio', 'Scelta Singola', 'Gruppo di opzioni per selezione singola',
'[{"name": "label", "value": "Scelta Singola"}, {"name": "options", "value": []}]',
'{"isRequired": false, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(6, 'select', 'Menu a Tendina', 'Selezione da opzioni predefinite',
'[{"name": "label", "value": "Menu a Tendina"}, {"name": "options", "value": []}]',
'{"isRequired": false, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(7, 'checkboxes', 'Scelta Multipla', 'Gruppo di opzioni per selezione singola o multipla',
'[{"name": "label", "value": "Scelta Multipla"}, {"name": "options", "value": []}]',
'{"isRequired": false, "min": null, "max": null, "custom": null}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(8, 'switch', 'Casella di Spunta', 'Per selezioni binarie, accettazioni, conferme',
'[{"name": "label", "value": "Casella di Spunta"}]',
'{"isRequired": false}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(9, 'datepicker', 'Data', 'Selezione di data',
'[{"name": "label", "value": "Data"}]',
'{"isRequired": false}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(10, 'fileupload', 'Caricamento File', 'Per l''upload di documenti o immagini',
'[{"name": "label", "value": "Caricamento File"}, {"name": "mime", "value": []}]',
'{"isRequired": false, "maxSize": 100000}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(11, 'textinput', 'Campo Partita IVA', 'Specifico per l''inserimento del numero di Partita IVA',
'[{"name": "label", "value": "Partita IVA"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": true, "custom": "isPIVA"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(12, 'textinput', 'Campo Codice Fiscale','Specifico per l''inserimento del Codice Fiscale italiano per persone fisiche e giuridiche',
'[{"name": "label", "value": "Codice Fiscale"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": true, "custom": "isCodiceFiscale"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(13, 'textinput', 'Campo CAP','Per l''inserimento del Codice di Avviamento Postale',
'[{"name": "label", "value": "CAP"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": true, "custom": "isCAP"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(14, 'textinput', 'Campo IBAN', 'Per l''inserimento del codice IBAN',
'[{"name": "label", "value": "IBAN"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": true, "custom": "isIBAN"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(15, 'textinput', 'Campo Email', 'Per l''inserimento di indirizzi email standard (non PEC)',
'[{"name": "label", "value": "Campo Email"}, {"name": "placeholder", "value": "nome@esempio.it"}]',
'{"isRequired": false, "custom": "isEmail"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(16, 'textinput', 'Campo PEC', 'Specifico per l''inserimento di un indirizzo di Posta Elettronica Certificata',
'[{"name": "label", "value": "Campo PEC"}, {"name": "placeholder", "value": "nome@pec.it"}]',
'{"isRequired": false, "custom": "isEmailPEC"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(17, 'textinput', 'Campo URL', 'Per l''inserimento di indirizzi web',
'[{"name": "label", "value": "Indirizzo URL"}, {"name": "placeholder", "value": ""}]',
'{"isRequired": false, "custom": "isUrl"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(18, 'textinput', 'Marca da bollo', 'Per inserire codice di marca da bollo',
'[{"name": "label", "value": "Marca da bollo"}, {"name": "placeholder", "value": "Numero identificativo"}]',
'{"isRequired": false, "custom": "isMarcaDaBollo"}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(19, 'paragraph', 'Paragrafo', 'Semplice testo formattato',
'[{"name": "text", "value": ""}]',
'{}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP),
(20, 'table', 'Tabella', 'Tabella',
'[{"name": "label", "value": "Tabella"}, {"name": "table_columns", "value": []}]',
'{}',
CURRENT_TIMESTAMP, CURRENT_TIMESTAMP);

View File

@@ -209,3 +209,5 @@ user.already.connected.to.company=The user is already connected to this company.
call.not.started.yet = The call has not started yet. Please wait until the specified start date and time.
call.already.ended = The call has already ended. You cannot submit the application after the deadline.
status.updated.successfully=Status updated successfully.
application.status.updated.successfully = Application status updated successfully.

View File

@@ -9,7 +9,7 @@ get_user_success_msg=Utente recuperato con successo.
get_user_error_msg=Si <20> verificato un errore durante il recupero dell'utente.
user.not.active=Utente non attivo. Si prega di contattare il supporto.
user.already.exist.msg=L'utente esiste gi<67> per questo codice fiscale.
validate.email=L'email è obbligatoria e deve essere nel formato corretto. Si prega di verificare e riprovare.
validate.email=L'email <EFBFBD> obbligatoria e deve essere nel formato corretto. Si prega di verificare e riprovare.
validate.password=La password e confPassword sono obbligatorie. Verifica e riprova.
# Role-related messages
role.created.success=Ruolo creato con successo.
@@ -20,7 +20,7 @@ create.role.error=Errore durante la creazione del ruolo.
update.role.error=Errore durante l'aggiornamento del ruolo.
role.fetch.success=Ruolo recuperato con successo.
delete.role.error=Errore durante l'eliminazione del ruolo.
role.id.mandatory=L'ID del ruolo è obbligatorio.
role.id.mandatory=L'ID del ruolo <EFBFBD> obbligatorio.
# Region-related messages
region.created.success=Regione creata con successo.
@@ -194,10 +194,12 @@ company.get.success=Azienda recuperata con successo.
company.not.found=Azienda non trovata.
check.vatnumber.success=Numero di partita IVA verificato con successo.
invalid.vatnumber=Numero di partita IVA non valido.
vatnumber.mandatory=Il numero di partita IVA è obbligatorio.
vatnumber.already.exists=Il numero di partita IVA esiste già.
vatnumber.mandatory=Il numero di partita IVA <EFBFBD> obbligatorio.
vatnumber.already.exists=Il numero di partita IVA esiste gi<EFBFBD>.
invalid.email=Email non valida.
company.id.mandatory=L'ID dell'azienda è obbligatorio.
user.already.connected.to.company=L'utente è già collegato a questa azienda.
call.not.started.yet = La chiamata non è ancora iniziata. Attendere fino alla data e all'ora di inizio specificate.
call.already.ended = La chiamata è già terminata. Non è possibile inviare l'applicazione dopo la scadenza.
company.id.mandatory=L'ID dell'azienda <EFBFBD> obbligatorio.
user.already.connected.to.company=L'utente <EFBFBD> gi<EFBFBD> collegato a questa azienda.
call.not.started.yet = La chiamata non <EFBFBD> ancora iniziata. Attendere fino alla data e all'ora di inizio specificate.
call.already.ended = La chiamata <EFBFBD> gi<EFBFBD> terminata. Non <EFBFBD> possibile inviare l'applicazione dopo la scadenza.
status.updated.successfully=Stato aggiornato con successo.
application.status.updated.successfully = Stato dell'applicazione aggiornato con successo.