antoniop
committed
on 20 Sep 22
Make service contract implementation private and replace foreign occurrences
/tcl/apm-callback-procs.tcl (+16 -1)
140 140                 shaded_p:config_required,configured f
141 141                 hideable_p:config_required,configured t
142 142                 user_editable_p:config_required,configured f
143 143                 link_hideable_p:config_required,configured t
144 144                 folder_id:config_required {}
145 145                 package_id:config_required {}
146 146              }
147 147              aliases {
148 148                  GetMyName dotlrn_homework_admin_portlet::get_my_name
149 149                  GetPrettyName dotlrn_homework_admin_portlet::get_pretty_name
150 150                  Link dotlrn_homework_admin_portlet::link
151 151                  AddSelfToPage dotlrn_homework_admin_portlet::add_self_to_page
152 152                  Show dotlrn_homework_admin_portlet::show
153 153                  Edit dotlrn_homework_admin_portlet::edit
154 154                  RemoveSelfFromPage dotlrn_homework_admin_portlet::remove_self_from_page
155 155             }
156 156         }
157 157     }
158 158 }
159 159
  160 ad_proc -private dotlrn_homework::apm_callbacks::after_instantiate {
  161     -package_id:required
  162 } {
  163
  164     Post package instantiation procedure to insert a package_id,
  165     folder_id pair in fs_root_folders.   The homework package wants its own root folder
  166     because we don't want it to be visible to any mounted instance of file storage.
  167
  168     This proc is automatically called by the APM whenever an instance of dotlrn_homework
  169     is mounted.
  170
  171 } {
  172     return [fs::new_root_folder -package_id $package_id]
  173 }
  174
160 175 ad_proc -private dotlrn_homework::apm_callbacks::package_uninstall {} {
161 176
162 177     Delete dotLRN stuff defined in package_install above
163 178
164 179     @author Don Baccus (dhogaza@pacifier.com)
165 180
166 181 } {
167 182     db_transaction {
168 183         notification::type::delete -short_name homework_upload
169 184         acs_sc::impl::delete -contract_name NotificationType -impl_name homework_file_upload
170 185         notification::type::delete -short_name correction_upload
171 186         acs_sc::impl::delete -contract_name NotificationType -impl_name correction_file_upload
172 187         acs_sc::impl::delete -contract_name dotlrn_applet -impl_name dotlrn_homework_applet
173 188         portal::datasource::delete -name dotlrn_homework_portlet
174 189         portal::datasource::delete -name dotlrn_homework_admin_portlet
175 190
176 191         db_dml delete_relation {
177 192               delete from cr_type_relations
178 193               where content_type = 'file-storage-object' and
179 194               target_type = 'file-storage-object' and