From 19cd9f7a8d888302d8637af897d407fc34bab522 Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Sun, 16 Jul 2023 23:01:23 +0200 Subject: account: add a list of sent follow requests --- lib/Travelynx/Command/database.pm | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'lib/Travelynx/Command') diff --git a/lib/Travelynx/Command/database.pm b/lib/Travelynx/Command/database.pm index a0dea45..022614b 100644 --- a/lib/Travelynx/Command/database.pm +++ b/lib/Travelynx/Command/database.pm @@ -1761,6 +1761,25 @@ my @migrations = ( } ); }, + + # v42 -> v43 + # list sent and received follow requests + sub { + my ($db) = @_; + $db->query( + qq{ + alter view follow_requests rename to rx_follow_requests; + create view tx_follow_requests as select + relations.subject_id as self_id, + users.id as id, + users.name as name + from relations + join users on relations.object_id = users.id + where predicate = 2; + update schema_version set version = 43; + } + ); + }, ); # TODO add 'hafas' column to in_transit (and maybe journeys? undo/redo needs something to work with...) -- cgit v1.2.3