fnUserRightsPerPart
Return
| Return Type |
|---|
| bit |
Parameters
| Parameter | Parameter Type | Mode | Description |
|---|---|---|---|
| @SiteContentID | int | IN | |
| @ClientUsersID | int | IN | |
| @ClientsID | int | IN |
Definition
Copy
CREATE FUNCTION [dbo].[fnUserRightsPerPart]
(
@SiteContentID int,
@ClientUsersID int,
@ClientsID int
)
RETURNS bit
AS
BEGIN
DECLARE @canView bit
IF exists (
SELECT * FROM dbo.sitecontent sc
inner join dbo.fnUserPrivs(@ClientUsersID,@ClientsID,1) up on up.ObjectGuid = sc.Guid
and sc.ID = @SiteContentID
and up.canView = 1) SET @canView = 1
ELSE SET @canView = 0
RETURN @canView
END