Commit ea6bbcd4 authored by Robert Lyon's avatar Robert Lyon
Browse files

Bug 1952359: Delete institution and progress completion collection



Allow one to delete an institution and delete all it's pages and
colelctions correctly

Change-Id: I939339d0f10cfb5e01feac2c14062a259d30597c
Signed-off-by: default avatarRobert Lyon <robertl@catalyst.net.nz>
parent 22881152
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -96,7 +96,9 @@ if ($institution || $add) {

            $authinstanceids = get_column('auth_instance', 'id', 'institution', $values['i']);
            $collectionids = get_column('collection', 'id', 'institution', $values['i']);
            $viewids = get_column('view', 'id', 'institution', $values['i']);
            // progress page types will be deleted as part of the collection so we don't want to try and delete them again as a view
            $viewids = get_column_sql("SELECT id FROM {view} WHERE institution = ? AND type != ?", array($values['i'], 'progress'));

            $artefactids = get_column('artefact', 'id', 'institution', $values['i']);
            $regdataids = get_column('institution_registration', 'id', 'institution', $values['i']);
            $host = get_field('host', 'wwwroot', 'institution', $values['i']);