mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Add dialog with options to allow downloading without history or data
Summary:
{F74398}
Refactored the 'radio checkboxes' in the modal for deleting a page and reused them here.
The option to download as a template already existed in the server code but wasn't being exercised by the frontend. Also added an option to remove just the history, which is the main motivation for this diff.
Test Plan: Expanded the existing nbrowser test.
Reviewers: paulfitz
Reviewed By: paulfitz
Differential Revision: https://phab.getgrist.com/D3999
This commit is contained in:
@@ -69,7 +69,7 @@ describe('Views.ntest', function() {
|
||||
assert.equal(await gu.actions.getActiveTab().text(), 'Table1');
|
||||
assert.deepEqual(await $(`.test-docpage-label`).array().text(), ['Table1', 'Table3']);
|
||||
await gu.actions.tableView('Table1').selectOption('Remove');
|
||||
await $(".test-removepage-option-page").click();
|
||||
await $(".test-option-page").click();
|
||||
await $(".test-modal-confirm").click();
|
||||
await gu.waitForServer();
|
||||
assert.equal(await gu.actions.getActiveTab().text(), 'Table3');
|
||||
|
||||
@@ -1144,7 +1144,7 @@ export async function removePage(name: string|RegExp, options: {
|
||||
const popupTables = await driver.findAll(".test-removepage-table", e => e.getText());
|
||||
assert.deepEqual(popupTables.sort(), options.tables.sort());
|
||||
}
|
||||
await popup.find(`.test-removepage-option-${options.withData ? 'data': 'page'}`).click();
|
||||
await popup.find(`.test-option-${options.withData ? 'data': 'page'}`).click();
|
||||
if (options.cancel) {
|
||||
await driver.find(".test-modal-cancel").click();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user