Index: openacs-4/packages/assessment/www/asm-admin/item-add.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/assessment/www/asm-admin/item-add.xql,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/assessment/www/asm-admin/item-add.xql 15 Apr 2005 17:26:46 -0000 1.2 +++ openacs-4/packages/assessment/www/asm-admin/item-add.xql 29 Jun 2007 22:39:39 -0000 1.2.6.1 @@ -30,4 +30,40 @@ + + + + select distinct title, revision_id from (select substr(title,1,50) as title, revision_id + from cr_items i, cr_revisions r + where + i.parent_id = :folder_id + and r.title is not NULL + and r.revision_id = i.latest_revision + and i.content_type = 'as_item_type_mc') c + + + + + + + select r.target_rev_id as as_item_type_id, o.object_type + from as_item_rels r, acs_objects o + where r.item_rev_id = :as_item_id + and r.rel_type = 'as_item_type_rel' + and o.object_id = r.target_rev_id + + + + + + + + update as_item_rels + set target_rev_id = :add_existing_mc_id + where item_rev_id = :as_item_id + and rel_type = 'as_item_type_rel' + + + +