-ActiveRecord::Schema.define(version: 2022_06_07_034505) do
+ActiveRecord::Schema.define(version: 2022_06_14_235034) do
@@ -26,2 +26,15 @@ create_table "access_tokens", id: :serial, force: :cascade do |t|
+ create_table "action_plan_templates", force: :cascade do |t|
+ t.string "name"
+ t.datetime "created_at", null: false
+ t.datetime "updated_at", null: false
+ end
+
+ create_table "action_plan_templates_goals", id: false, force: :cascade do |t|
+ t.bigint "action_plan_template_id"
+ t.bigint "goal_id"
+ t.index ["action_plan_template_id"], name: "index_action_plan_templates_goals_on_action_plan_template_id"
+ t.index ["goal_id"], name: "index_action_plan_templates_goals_on_goal_id"
+ end
+
create_table "activities", id: :serial, force: :cascade do |t|
@@ -791,2 +804,3 @@ create_table "document_library_files", force: :cascade do |t|
t.string "type", default: "DocumentLibraryFile", null: false
+ t.boolean "landscape"
t.index ["deleted_at"], name: "index_document_library_files_on_deleted_at"
@@ -839,5 +853,8 @@ create_table "emails", id: :serial, force: :cascade do |t|
t.string "marketo_guid"
+ t.integer "thread_id"
t.index ["emailable_id"], name: "index_emails_on_emailable_id"
t.index ["emailable_type"], name: "index_emails_on_emailable_type"
+ t.index ["message_id"], name: "index_emails_on_message_id"
t.index ["reminder_id"], name: "index_emails_on_reminder_id"
+ t.index ["thread_id"], name: "index_emails_on_thread_id"
t.index ["user_id"], name: "index_emails_on_user_id"
@@ -938,2 +955,4 @@ create_table "entity_programmes", id: :serial, force: :cascade do |t|
t.string "programme", null: false
+ t.datetime "deleted_at"
+ t.index ["deleted_at"], name: "index_entity_programmes_on_deleted_at"
t.index ["entity_type", "entity_id"], name: "index_entity_programmes_on_entity_type_and_entity_id"
@@ -1038,2 +1057,9 @@ create_table "expense_exports", id: :serial, force: :cascade do |t|
+ create_table "expense_finance_statuses", force: :cascade do |t|
+ t.string "name"
+ t.boolean "system", default: false
+ t.datetime "created_at", null: false
+ t.datetime "updated_at", null: false
+ end
+
create_table "expense_imports", id: :serial, force: :cascade do |t|
@@ -1086,3 +1112,3 @@ create_table "expenses", id: :serial, force: :cascade do |t|
t.string "export_state", default: "waiting_for_approval"
- t.string "finance_status", default: "in_progress"
+ t.string "legacy_finance_status", default: "in_progress"
t.boolean "gst_applied", default: true
@@ -1150,2 +1176,3 @@ create_table "expenses", id: :serial, force: :cascade do |t|
t.datetime "goods_received_confirmation_requested_at"
+ t.integer "finance_status_id", default: 2, null: false
t.index ["approver_id"], name: "index_expenses_on_approver_id"
@@ -2755,2 +2782,3 @@ create_table "smtp_settings", force: :cascade do |t|
t.string "imap_email"
+ t.json "imap_fetch_progress_tracking", default: {}, null: false
end
@@ -3107,2 +3135,3 @@ create_table "users", id: :serial, force: :cascade do |t|
t.boolean "can_update_supplier_paid_date", default: false, null: false
+ t.boolean "can_create_wfa_placement", default: false, null: false
t.index ["active"], name: "index_users_on_active"
@@ -3371,2 +3400,3 @@ create_table "wage_subsidy_requests", force: :cascade do |t|
t.string "previous_system_identifier"
+ t.bigint "suggested_contact_id"
t.index "((id)::text) text_pattern_ops", name: "index_wage_subsidy_requests_on_cast_id_as_text"
@@ -3381,2 +3411,3 @@ create_table "wage_subsidy_requests", force: :cascade do |t|
t.index ["second_approved_by_id"], name: "index_wage_subsidy_requests_on_second_approved_by_id"
+ t.index ["suggested_contact_id"], name: "index_wage_subsidy_requests_on_suggested_contact_id"
t.index ["wage_subsidy_agreement_id"], name: "index_wage_subsidy_requests_on_wage_subsidy_agreement_id"