Skip to content

Commit

Permalink
reverted schema.db
Browse files Browse the repository at this point in the history
  • Loading branch information
sarala committed Feb 5, 2020
1 parent 28d5f37 commit c663784
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 36 deletions.
4 changes: 1 addition & 3 deletions app/serializers/activity_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@ class ActivitySerializer

attribute "prov:wasAttributedTo" do |object|
url = Rails.env.production? ? "https://api.datacite.org" : "https://api.test.datacite.org"
if object.username.present?
object.username.to_s.include?(".") ? url + "/clients/" + object.username : url + "/providers/" + object.username
end
object.username.include?(".") ? url + "/clients/" + object.username : url + "/providers/" + object.username
end

attribute "prov:wasGeneratedBy" do |object|
Expand Down
37 changes: 4 additions & 33 deletions db/schema.rb
Original file line number Diff line number Diff line change
Expand Up @@ -251,44 +251,15 @@
t.string "source_relation_type_id", limit: 191
t.string "target_relation_type_id", limit: 191
t.index ["created_at", "indexed_at", "updated_at"], name: "index_events_on_created_indexed_updated"
t.index ["doi_id", "relation_type_id"], name: "index_events_on_doi_id", length: { doi_id: 100 }
t.index ["created_at"], name: "index_events_on_source_id_created_at"
t.index ["relation_type_id"], name: "index_events_on_doi_id"
t.index ["source_doi", "source_relation_type_id"], name: "index_events_on_source_doi", length: { source_doi: 100 }
t.index ["source_id", "created_at"], name: "index_events_on_source_id_created_at"
t.index ["subj_id", "obj_id", "source_id", "relation_type_id"], name: "index_events_on_multiple_columns", unique: true, length: { subj_id: 191, obj_id: 191 }
t.index ["subj_id", "obj_id", "relation_type_id"], name: "index_events_on_multiple_columns", unique: true, length: { subj_id: 191, obj_id: 191 }
t.index ["target_doi", "target_relation_type_id"], name: "index_events_on_target_doi", length: { target_doi: 100 }
t.index ["updated_at"], name: "index_events_on_updated_at"
t.index ["uuid"], name: "index_events_on_uuid", unique: true, length: 36
end

create_table "lhma_2020_02_03_11_33_29_151_events", options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4", force: :cascade do |t|
t.text "uuid", null: false
t.text "subj_id", null: false
t.text "obj_id"
t.string "source_id", limit: 191
t.string "aasm_state"
t.string "state_event"
t.text "callback"
t.text "error_messages"
t.text "source_token"
t.datetime "created_at", precision: 3, null: false
t.datetime "updated_at", precision: 3, null: false
t.datetime "indexed_at", default: "1970-01-01 00:00:00", null: false
t.datetime "occurred_at"
t.string "message_action", limit: 191, default: "create", null: false
t.string "relation_type_id", limit: 191
t.text "subj", limit: 16777215
t.text "obj", limit: 16777215
t.integer "total", default: 1
t.string "license", limit: 191
t.text "doi_id"
t.index ["created_at", "indexed_at", "updated_at"], name: "index_events_on_created_indexed_updated"
t.index ["relation_type_id"], name: "index_events_on_doi_id"
t.index ["source_id", "created_at"], name: "index_events_on_source_id_created_at"
t.index ["subj_id", "obj_id", "source_id", "relation_type_id"], name: "index_events_on_multiple_columns", unique: true, length: { subj_id: 191, obj_id: 191 }
t.index ["updated_at"], name: "index_events_on_updated_at"
t.index ["uuid"], name: "index_events_on_uuid", unique: true, length: 36
end

create_table "media", options: "ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=COMPACT", force: :cascade do |t|
t.datetime "created"
t.string "media_type", limit: 80
Expand Down Expand Up @@ -359,4 +330,4 @@
add_foreign_key "dataset", "datacentre", column: "datacentre", name: "FK5605B47847B5F5FF"
add_foreign_key "media", "dataset", column: "dataset", name: "FK62F6FE44D3D6B1B"
add_foreign_key "metadata", "dataset", column: "dataset", name: "FKE52D7B2F4D3D6B1B"
end
end

0 comments on commit c663784

Please sign in to comment.