共用方式為


PageConventionCollectionExtensions.AuthorizeAreaPage 方法

定義

多載

AuthorizeAreaPage(PageConventionCollection, String, String)

需要指定區域頁面的授權。

AuthorizeAreaPage(PageConventionCollection, String, String, String)

需要具有指定原則之指定區域頁面的授權。

AuthorizeAreaPage(PageConventionCollection, String, String)

來源:
PageConventionCollectionExtensions.cs
來源:
PageConventionCollectionExtensions.cs
來源:
PageConventionCollectionExtensions.cs

需要指定區域頁面的授權。

public static Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection AuthorizeAreaPage (this Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection conventions, string areaName, string pageName);
static member AuthorizeAreaPage : Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection * string * string -> Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection
<Extension()>
Public Function AuthorizeAreaPage (conventions As PageConventionCollection, areaName As String, pageName As String) As PageConventionCollection

參數

areaName
String

區功能變數名稱稱。

pageName
String

頁面名稱,例如 /Users/List

頁面名稱是沒有副檔名的檔案路徑,相對於指定區域的分頁根目錄。 例如,Areas/Identity/Pages/Manage/Accounts.cshtml 檔案的頁面名稱為 /Manage/Accounts

傳回

PageConventionCollection

適用於

AuthorizeAreaPage(PageConventionCollection, String, String, String)

來源:
PageConventionCollectionExtensions.cs
來源:
PageConventionCollectionExtensions.cs
來源:
PageConventionCollectionExtensions.cs

需要具有指定原則之指定區域頁面的授權。

public static Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection AuthorizeAreaPage (this Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection conventions, string areaName, string pageName, string policy);
static member AuthorizeAreaPage : Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection * string * string * string -> Microsoft.AspNetCore.Mvc.ApplicationModels.PageConventionCollection
<Extension()>
Public Function AuthorizeAreaPage (conventions As PageConventionCollection, areaName As String, pageName As String, policy As String) As PageConventionCollection

參數

areaName
String

區功能變數名稱稱。

pageName
String

頁面名稱,例如 /Users/List

頁面名稱是沒有副檔名的檔案路徑,相對於指定區域的分頁根目錄。 例如,Areas/Identity/Pages/Manage/Accounts.cshtml 檔案的頁面名稱為 /Manage/Accounts

policy
String

授權原則。

傳回

PageConventionCollection

適用於