forked from e621ng/e621ng
Add link to artist note changes to history
This commit is contained in:
parent
1d68c438df
commit
df2c76226b
@ -279,7 +279,8 @@ class Artist < ApplicationRecord
|
||||
:is_active => is_active,
|
||||
:is_banned => is_banned,
|
||||
:other_names => other_names,
|
||||
:group_name => group_name
|
||||
:group_name => group_name,
|
||||
:notes_changed => saved_change_to_notes?
|
||||
)
|
||||
end
|
||||
|
||||
@ -291,7 +292,8 @@ class Artist < ApplicationRecord
|
||||
:is_active => is_active,
|
||||
:is_banned => is_banned,
|
||||
:other_names => other_names,
|
||||
:group_name => group_name
|
||||
:group_name => group_name,
|
||||
:notes_changed => saved_change_to_notes?
|
||||
)
|
||||
end
|
||||
|
||||
|
@ -5,6 +5,7 @@
|
||||
<th>Name</th>
|
||||
<th>Other Names</th>
|
||||
<th>URLs</th>
|
||||
<th>Notes</th>
|
||||
<th>Updated</th>
|
||||
<% if artist_versions_listing_type == :revert %>
|
||||
<th></th>
|
||||
@ -35,6 +36,13 @@
|
||||
<td class="col-expand">
|
||||
<%= artist_version_urls_diff(artist_version) if artist_version.visible? %>
|
||||
</td>
|
||||
<td>
|
||||
<% if artist_version.notes_changed %>
|
||||
<%= link_to "Note Changes", wiki_page_versions_path(search: {wiki_page_id: artist_version.artist.wiki_page})%>
|
||||
<% else %>
|
||||
(No Changes)
|
||||
<% end %>
|
||||
</td>
|
||||
<td>
|
||||
<%= link_to_user artist_version.updater %>
|
||||
<%= link_to "»", artist_versions_path(search: { updater_name: artist_version.updater_name }) %>
|
||||
|
@ -0,0 +1,5 @@
|
||||
class AddNotesChangedToArtistVersion < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
add_column :artist_versions, :notes_changed, :boolean, default: false
|
||||
end
|
||||
end
|
@ -436,7 +436,8 @@ CREATE TABLE public.artist_versions (
|
||||
created_at timestamp without time zone,
|
||||
updated_at timestamp without time zone,
|
||||
other_names text[] DEFAULT '{}'::text[] NOT NULL,
|
||||
urls text[] DEFAULT '{}'::text[] NOT NULL
|
||||
urls text[] DEFAULT '{}'::text[] NOT NULL,
|
||||
notes_changed boolean DEFAULT false
|
||||
);
|
||||
|
||||
|
||||
@ -3695,6 +3696,8 @@ ALTER TABLE ONLY public.post_sets
|
||||
ALTER TABLE ONLY public.post_versions
|
||||
ADD CONSTRAINT post_versions_pkey PRIMARY KEY (id);
|
||||
|
||||
ALTER TABLE public.post_versions CLUSTER ON post_versions_pkey;
|
||||
|
||||
|
||||
--
|
||||
-- Name: post_votes post_votes_pkey; Type: CONSTRAINT; Schema: public; Owner: -
|
||||
@ -5330,6 +5333,7 @@ INSERT INTO "schema_migrations" (version) VALUES
|
||||
('20190924233432'),
|
||||
('20191003070653'),
|
||||
('20191006073950'),
|
||||
('20191006143246');
|
||||
('20191006143246'),
|
||||
('20191013233447');
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user