296 lines
13 KiB
XML
296 lines
13 KiB
XML
<?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="14-08-2024_1" author="Harish Bagora">
|
|
<createTable tableName="region">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="region_pkey"/>
|
|
</column>
|
|
<column name="region_name" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="description" type="TEXT">
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="country" type="VARCHAR(100)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="status" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="priority_area" type="VARCHAR(255)">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="population" type="INTEGER">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="area_size" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="gdp" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="unemployment_rate" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="infrastructure_score" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="education_level" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="healthcare_access" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="environmental_score" type="numeric">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
</createTable>
|
|
</changeSet>
|
|
|
|
<changeSet id="14-08-2024_2" author="Harish Bagora">
|
|
<createTable tableName="role">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="role_pkey"/>
|
|
</column>
|
|
<column name="role_name" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="description" type="VARCHAR(255)">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="permissions" type="TEXT">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="region_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_role_region" references="region(id)"/>
|
|
</column>
|
|
</createTable>
|
|
</changeSet>
|
|
|
|
<changeSet id="14-08-2024_3" author="Harish Bagora">
|
|
<createTable tableName="gepafin_user">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="gepafin_user_pkey"/>
|
|
</column>
|
|
<column name="password" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="email" type="varchar(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="first_name" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="last_name" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="phone_number" type="VARCHAR(255)"/>
|
|
<column name="role_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_gepafin_user_role" references="role(id)"/>
|
|
</column>
|
|
<column name="status" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="last_login" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="organization" type="TEXT">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="address" type="TEXT">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="city" type="TEXT">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="country" type="TEXT">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
</createTable>
|
|
</changeSet>
|
|
|
|
<changeSet id="21-08-2024_1" author="Rajesh Khore">
|
|
<createTable tableName="call">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="call_pkey"/>
|
|
</column>
|
|
<column name="name" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="description_short" type="TEXT"/>
|
|
<column name="description_long" type="TEXT"/>
|
|
<column name="start_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="end_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="status" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="region_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_region_call" references="region(id)"/>
|
|
</column>
|
|
<column name="amount" type="numeric">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="amount_max" type="numeric">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="documentation_requested" type="TEXT"/>
|
|
<column name="contact_info" type="TEXT"/>
|
|
<column name="submission_method" type="TEXT">
|
|
</column>
|
|
<column name="threshold" type="INTEGER">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="priority_area" type="TEXT"/>
|
|
<column name="confidi" type="BOOLEAN"/>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
</createTable>
|
|
|
|
<createTable tableName="evaluation_criteria">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="evaluation_criteria_pkey"/>
|
|
</column>
|
|
<column name="call_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_call_evaluation_criteria" references="call(id)"/>
|
|
</column>
|
|
<column name="name" type="TEXT">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="description" type="TEXT"/>
|
|
<column name="score" type="INTEGER">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
</createTable>
|
|
|
|
<createTable tableName="faq">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="faq_pkey"/>
|
|
</column>
|
|
<column name="call_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_call_faq" references="call(id)"/>
|
|
</column>
|
|
<column name="user_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_gepafin_user_faq" references="gepafin_user(id)"/>
|
|
</column>
|
|
<column name="is_visible" type="BOOLEAN">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="question_short" type="VARCHAR(255)"/>
|
|
<column name="question" type="TEXT"/>
|
|
<column name="response_short" type="VARCHAR(255)"/>
|
|
<column name="response" type="TEXT"/>
|
|
<column name="response_date" type="TIMESTAMP WITHOUT TIME ZONE"/>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
</createTable>
|
|
|
|
<createTable tableName="document">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="document_pkey"/>
|
|
</column>
|
|
<column name="file_name" type="VARCHAR(255)">
|
|
</column>
|
|
<column name="file_path" type="TEXT"/>
|
|
<column name="call_id" type="INTEGER">
|
|
<constraints foreignKeyName="fk_call_document" references="call(id)"/>
|
|
</column>
|
|
<column name="description" type="TEXT"/>
|
|
<column name="type" type="VARCHAR(255)">
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/></column>
|
|
</createTable>
|
|
|
|
<createTable tableName="lookup_data">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="lookup_data_pkey"/>
|
|
</column>
|
|
<column name="title" type="VARCHAR(255)">
|
|
<constraints nullable="true"/>
|
|
</column>
|
|
<column name="type" type="VARCHAR(255)">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="value" type="TEXT">
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/></column>
|
|
</createTable>
|
|
|
|
<createTable tableName="call_target_audience_checklist">
|
|
<column autoIncrement="true" name="id" type="INTEGER">
|
|
<constraints nullable="false" primaryKey="true"
|
|
primaryKeyName="call_target_audience_checklist_pkey"/>
|
|
</column>
|
|
<column name="call_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_call_call_target_audience_checklist" references="call(id)"/>
|
|
</column>
|
|
<column name="lookup_data_id" type="INTEGER">
|
|
<constraints nullable="false" foreignKeyName="fk_lookup_data_call_target_audience_checklist" references="lookup_data(id)"/>
|
|
</column>
|
|
<column name="is_validated" type="BOOLEAN">
|
|
</column>
|
|
<column name="created_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="false"/>
|
|
</column>
|
|
<column name="updated_date" type="TIMESTAMP WITHOUT TIME ZONE">
|
|
<constraints nullable="true"/></column>
|
|
</createTable>
|
|
</changeSet>
|
|
|
|
</databaseChangeLog>
|