add copy page functionality to control panel
This commit is contained in:
@@ -71,6 +71,15 @@ namespace Oqtane.Services
|
||||
/// <param name="pageId"></param>
|
||||
/// <returns></returns>
|
||||
Task DeletePageAsync(int pageId);
|
||||
|
||||
/// <summary>
|
||||
/// Copies the modules from one page to another
|
||||
/// </summary>
|
||||
/// <param name="fromPageId"></param>
|
||||
/// <param name="toPageId"></param>
|
||||
/// <param name="usePagePermissions"></param>
|
||||
/// <returns></returns>
|
||||
Task CopyPageAsync(int fromPageId, int toPageId, bool usePagePermissions);
|
||||
}
|
||||
|
||||
[PrivateApi("Don't show in the documentation, as everything should use the Interface")]
|
||||
@@ -129,5 +138,10 @@ namespace Oqtane.Services
|
||||
{
|
||||
await DeleteAsync($"{Apiurl}/{pageId}");
|
||||
}
|
||||
|
||||
public async Task CopyPageAsync(int fromPageId, int toPageId, bool usePagePermissions)
|
||||
{
|
||||
await PostAsync($"{Apiurl}/{fromPageId}/{toPageId}/{usePagePermissions}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user