Skip to content

Commit

Permalink
feat: enable download analyze script (microsoft#304)
Browse files Browse the repository at this point in the history
  • Loading branch information
stew-ro authored Jun 4, 2020
1 parent 61dba02 commit 9c97ed0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/react/components/pages/predict/predictPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ export default class PredictPage extends React.Component<IPredictPageProps, IPre
<span>Analyze</span>
</h6>
<div className="p-3">
{/* <h5>
<h5>
{strings.predict.downloadScript}
</h5>
<PrimaryButton
Expand All @@ -193,7 +193,7 @@ export default class PredictPage extends React.Component<IPredictPageProps, IPre
<div className="seperator"/>
or
<div className="seperator"/>
</div> */}
</div>
<h5>
{strings.predict.uploadFile}
</h5>
Expand Down Expand Up @@ -601,8 +601,8 @@ export default class PredictPage extends React.Component<IPredictPageProps, IPre
const fileURL = window.URL.createObjectURL(
new Blob([analyzeScript]));
const fileLink = document.createElement("a");
const fileBaseName = "analysis";
const downloadFileName = fileBaseName + modelID.substring(0, 4) + ".py";
const fileBaseName = "analyze";
const downloadFileName = fileBaseName + "-" + modelID.substring(0, 4) + ".py";

fileLink.href = fileURL;
fileLink.setAttribute("download", downloadFileName);
Expand Down

0 comments on commit 9c97ed0

Please sign in to comment.