Skip to content

Commit

Permalink
The setting for Page Range in Print Now is not reset after printing
Browse files Browse the repository at this point in the history
  • Loading branch information
tp-teman committed Mar 7, 2024
1 parent 205c861 commit 5f7e5e2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ export class EzpPrinterSelection {
case 'paper_ranges':
this.selectedProperties.PageRanges = eventDetails.value;
this.pageRangeInvalid = !validatePageRange(this.selectedProperties.PageRanges);

localStorage.setItem('pageRanges', JSON.stringify(this.selectedProperties.PageRanges));
// console.log(this.selectedProperties.PageRanges)
break
case 'duplex':
Expand Down Expand Up @@ -848,7 +848,7 @@ export class EzpPrinterSelection {
icon="paper_range"
suffix=""
placeholder="1-2,4-5,8"
value={this.selectedProperties.PageRanges}
value={localStorage.getItem('pageRanges') ? this.selectedProperties.PageRanges : ''}
eventType="paper_ranges"
type="text"
label={i18next.t('printer_selection.page_ranges')}
Expand Down
1 change: 1 addition & 0 deletions src/components/ezp-upload/ezp-upload.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ export class EzpUpload {
private handleInput = () => {
this.filename = this.input.files[0].name
this.uploadFile.emit(this.input.files)
localStorage.removeItem('pageRanges');
}

/**
Expand Down

0 comments on commit 5f7e5e2

Please sign in to comment.