UFN_CAMPAIGN_USERHASSITEACCESS
Validates that the application user has access to the campaign based on site permissions.
Return
Return Type |
---|
bit |
Parameters
Parameter | Parameter Type | Mode | Description |
---|---|---|---|
@APPUSERID | uniqueidentifier | IN | |
@CAMPAIGNID | uniqueidentifier | IN |
Definition
Copy
CREATE function dbo.UFN_CAMPAIGN_USERHASSITEACCESS
(
@APPUSERID uniqueidentifier,
@CAMPAIGNID uniqueidentifier
)
returns bit with execute as caller
as
begin
if exists(select SITEID from dbo.UFN_SITEID_MAPFROM_CAMPAIGNID(@CAMPAIGNID) as CAMPAIGNSITES where dbo.UFN_SITEALLOWEDFORUSER(@APPUSERID, CAMPAIGNSITES.SITEID) = 1)
return 1
else
return 0
return 0
end