calendar::item_type_delete (public)

 calendar::item_type_delete -calendar_id calendar_id \
    -item_type_id item_type_id

Defined in packages/calendar/tcl/calendar-procs.tcl

Delete an item type

Switches:
-calendar_id (required)
-item_type_id (required)

Partial Call Graph (max 5 caller/called nodes):
%3 test_calendar_basic_api calendar_basic_api (test calendar) calendar::item_type_delete calendar::item_type_delete test_calendar_basic_api->calendar::item_type_delete db_dml db_dml (public) calendar::item_type_delete->db_dml db_transaction db_transaction (public) calendar::item_type_delete->db_transaction calendar::apm::before_uninstantiate calendar::apm::before_uninstantiate (private) calendar::apm::before_uninstantiate->calendar::item_type_delete packages/calendar/www/item-type-delete.tcl packages/calendar/ www/item-type-delete.tcl packages/calendar/www/item-type-delete.tcl->calendar::item_type_delete

Testcases:
calendar_basic_api
Source code:
    db_transaction {
        # Remove the mappings for all events
        db_dml reset_item_types {}

        # Remove the item type
        db_dml delete_item_type {}
    }
Generic XQL file:
<fullquery name="calendar::item_type_delete.reset_item_types">
    <querytext>
	update cal_items
	set item_type_id= NULL
	where item_type_id = :item_type_id
	and on_which_calendar= :calendar_id
    </querytext>
</fullquery>

<fullquery name="calendar::item_type_delete.delete_item_type">
    <querytext>
	delete from cal_item_types where item_type_id= :item_type_id
	and calendar_id= :calendar_id
    </querytext>
</fullquery>
packages/calendar/tcl/calendar-procs.xql

PostgreSQL XQL file:
packages/calendar/tcl/calendar-procs-postgresql.xql

Oracle XQL file:
packages/calendar/tcl/calendar-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: