Skip to content
Snippets Groups Projects
Commit 53c3fc2d authored by pabois's avatar pabois
Browse files

fix organization translation

parent 84b1cc4c
No related branches found
No related tags found
No related merge requests found
......@@ -74,7 +74,7 @@ class University::Organization < ApplicationRecord
has_one_attached_deletable :logo_on_dark_background
validates_presence_of :name
validates_uniqueness_of :name, scope: :university_id
validates_uniqueness_of :name, scope: [:university_id, :language_id]
validates :logo, size: { less_than: 1.megabytes }
validates :logo_on_dark_background, size: { less_than: 1.megabytes }
# Organization can be created from extranet with only their name. Be careful for future validators.
......
......@@ -105,8 +105,8 @@ ActiveRecord::Schema[7.0].define(version: 2023_07_05_103400) do
t.datetime "updated_at", null: false
t.string "title"
t.boolean "published", default: true
t.uuid "heading_id"
t.uuid "communication_website_id"
t.uuid "heading_id"
t.index ["about_type", "about_id"], name: "index_communication_website_blocks_on_about"
t.index ["communication_website_id"], name: "index_communication_blocks_on_communication_website_id"
t.index ["heading_id"], name: "index_communication_blocks_on_heading_id"
......@@ -223,6 +223,7 @@ ActiveRecord::Schema[7.0].define(version: 2023_07_05_103400) do
t.text "home_sentence"
t.text "sass"
t.text "css"
t.boolean "allow_experiences_modification", default: true
t.index ["about_type", "about_id"], name: "index_communication_extranets_on_about"
t.index ["university_id"], name: "index_communication_extranets_on_university_id"
end
......@@ -461,7 +462,7 @@ ActiveRecord::Schema[7.0].define(version: 2023_07_05_103400) do
t.index ["university_id"], name: "index_communication_website_pages_on_university_id"
end
create_table "communication_website_permalinks", id: :uuid, default: -> { "public.gen_random_uuid()" }, force: :cascade do |t|
create_table "communication_website_permalinks", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.uuid "university_id", null: false
t.uuid "website_id", null: false
t.string "about_type", null: false
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment