USP_DATAFORMTEMPLATE_VIEW_DESIGNATIONLEVELGIFTFEE

The load procedure used by the view dataform template "Fundraising Purpose Gift Fee Option View Data Form"

Parameters

Parameter Parameter Type Mode Description
@ID uniqueidentifier IN The input ID parameter used to load the fields defined on the form.
@DATALOADED bit INOUT Output parameter indicating whether or not data was actually loaded.
@ENABLED bit INOUT Apply gift fees to revenue
@APPLICATIONTYPES xml INOUT Gift fees will be applied to the following application types

Definition

Copy


CREATE procedure dbo.USP_DATAFORMTEMPLATE_VIEW_DESIGNATIONLEVELGIFTFEE
(
    @ID uniqueidentifier,
    @DATALOADED bit = 0 output,
    @ENABLED bit = null output,
    @APPLICATIONTYPES xml = null output
)
as
    set nocount on;

    set @DATALOADED = 1;
    set @ENABLED = 0;

    select top 1
        @ENABLED = ENABLED,
        @APPLICATIONTYPES = dbo.UFN_DESIGNATIONLEVELGIFTFEE_GETAPPLICATIONTYPES_TOITEMLISTXML(@ID)
    from dbo.DESIGNATIONLEVELGIFTFEEOPTION
    where ID = @ID

    if @@ROWCOUNT = 0
        select top 1
            @ENABLED = ENABLED,
            @APPLICATIONTYPES = dbo.UFN_GIFTFEE_GETAPPLICATIONTYPES_TOITEMLISTXML()
        from dbo.GIFTFEEOPTION


    return 0;