Skip to content
This repository was archived by the owner on Aug 15, 2023. It is now read-only.

Commit d34f666

Browse files
authored
- fixed showing of drawing progress dialog when no drawing available (#320)
- changed button from Done to Ok
1 parent f2d255a commit d34f666

File tree

6 files changed

+15
-15
lines changed

6 files changed

+15
-15
lines changed

WebApplication/ClientApp/src/components/drawing.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ export class Drawing extends Component {
6565
{!empty &&
6666
<ForgePdfView/>
6767
}
68-
{this.props.drawingProgressShowing &&
68+
{!empty && this.props.drawingProgressShowing &&
6969
<ModalProgress
7070
open={true}
7171
title="Generating Drawing"

WebApplication/ClientApp/src/components/modalProgress.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,9 @@ export class ModalProgress extends Component {
7171
<div id="modalDone">
7272
<Button className="button" style={
7373
{ width: '116px', height: '36px', borderRadius: '2px', marginLeft: '12px'}}
74-
type="secondary"
74+
type="primary"
7575
size="small"
76-
title="Done"
76+
title="Ok"
7777
onClick={this.props.onClose}
7878
/>
7979
</div>

WebApplication/ClientApp/src/ui-tests/drawing_test.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ Scenario('should check that Drawing tab shows drawing for an Assembly', async (I
3939
I.waitForForgeViewerToPreventItFromCrashing(30);
4040
I.goToDrawingTab();
4141

42-
// check the dialog will appear with Done button
42+
// check the dialog will appear with Ok button
4343
const drawingProgress = '//p[text()="Generating Drawing"]';
4444
I.waitForVisible(drawingProgress, 10);
45-
I.waitForVisible(locators.xpButtonDone, locators.FDAActionTimeout);
46-
I.click(locators.xpButtonDone);
45+
I.waitForVisible(locators.xpButtonOk, locators.FDAActionTimeout);
46+
I.click(locators.xpButtonOk);
4747

4848
// wait for drawing to be displayed
4949
I.waitForVisible(viewCubeElement, locators.FDAActionTimeout);
@@ -78,11 +78,11 @@ Scenario('should check id a drawing has more sheet is will show arrow buttons',
7878
I.waitForForgeViewerToPreventItFromCrashing(30);
7979
I.goToDrawingTab();
8080

81-
// check the dialog will appear with Done button
81+
// check the dialog will appear with Ok button
8282
const drawingProgress = '//p[text()="Generating Drawing"]';
8383
I.waitForVisible(drawingProgress, 10);
84-
I.waitForVisible(locators.xpButtonDone, locators.FDAActionTimeout);
85-
I.click(locators.xpButtonDone);
84+
I.waitForVisible(locators.xpButtonOk, locators.FDAActionTimeout);
85+
I.click(locators.xpButtonOk);
8686

8787
// wait for drawing page to be displayed with extra arrow buttons
8888
const customDrwToolbar = '//div[@id="custom-drawing-toolbar"]';

WebApplication/ClientApp/src/ui-tests/elements_definition.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
module.exports = {
2727
xpButtonReset : locate('button').find('span').withText('Reset'),
2828
xpButtonUpdate : locate('button').find('span').withText('Update'),
29-
xpButtonDone: locate('button').find('span').withText('Done'),
29+
xpButtonOk: locate('button').find('span').withText('Ok'),
3030
ForgeViewer : '#ForgeViewer',
3131
xpLinkAdskForge : '//a[@href="https://forge.autodesk.com"]',
3232
xpComboProjects : '//div[@role="button"] //*[local-name()="svg"]',

WebApplication/ClientApp/src/ui-tests/tabs_test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,11 +61,11 @@ Scenario('should check if all Tabs are loaded after click', async (I) => {
6161
// click on Drawing tab
6262
I.click( locators.drawingTab);
6363

64-
// check the dialog will appear with Done button
64+
// check the dialog will appear with Ok button
6565
const drawingProgress = '//p[text()="Generating Drawing"]';
6666
I.waitForVisible(drawingProgress, 10);
67-
I.waitForVisible(locators.xpButtonDone, locators.FDAActionTimeout);
68-
I.click(locators.xpButtonDone);
67+
I.waitForVisible(locators.xpButtonOk, locators.FDAActionTimeout);
68+
I.click(locators.xpButtonOk);
6969

7070
// check that Drawing tab has correct content
7171
I.waitForVisible( locators.DrawingContainer, 10);

WebApplication/ClientApp/steps_file.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -229,8 +229,8 @@ module.exports = function() {
229229
// wait for progress bar shows and disappears
230230
const updatingProjectProgress = '//p[text()="Updating Project"]';
231231
this.waitForVisible(updatingProjectProgress, 10);
232-
this.waitForVisible(locators.xpButtonDone, locators.FDAActionTimeout);
233-
this.click(locators.xpButtonDone);
232+
this.waitForVisible(locators.xpButtonOk, locators.FDAActionTimeout);
233+
this.click(locators.xpButtonOk);
234234
this.waitForInvisible(updatingProjectProgress, 10);
235235
},
236236
waitForForgeViewerToPreventItFromCrashing(timeout)

0 commit comments

Comments
 (0)