1 # Copyright (C) The Arvados Authors. All rights reserved.
3 # SPDX-License-Identifier: AGPL-3.0
5 class WriteViaAllUsers < ActiveRecord::Migration[5.2]
6 include CurrentApiClient
8 changelinks(from: "can_read", to: "can_write")
11 changelinks(from: "can_write", to: "can_read")
13 def changelinks(from:, to:)
14 ActiveRecord::Base.connection.exec_query(
15 "update links set name=$1 where link_class=$2 and name=$3 and tail_uuid like $4 and head_uuid = $5",
20 [nil, "_____-tpzed-_______________"],
21 [nil, all_users_group_uuid],