I am working on a web app (Angular2 front end, Laravel Lumen back end) that
will be used by a paint shop to display information for different orders. A
painter will scan multiple bar codes and for each bar code scanned a new
page needs to be created (or added to a queue of some sort) with new
information to be displayed. The layout of the page will stay the same and
the painters will navigate back or forward from page to page with buttons
One thing to keep in mind is that they may scan 5 bar codes in at first,
and 5 more in 3 hours but they all need to be in the same queue. I dont
think I even need to create new web pages it just needs to display the info
for each bar code scan in order when the next or previous page button is
pressed.
How can I dynamically create multiple pages based on the template below and
set up the buttons so they know which page to go to
// The buttons to go back and forth
<div class="btn-toolbar">
<a routerLink="" class="glyphicon glyphicon-arrow-right btn pull-right"></a
>
<a routerLink="" class="glyphicon glyphicon-arrow-left btn pull-right"></a>
</div>
<div class="info col-sm-3">
<div class="row">
<h1>PCode: </h1>
<p> {{ pCode }} </p>
</div>
<div class="row">
<h1>CCode: </h1>
<p> {{ cCode }}</p>
</div>
<div class="row">
<h1>Gema Pset: </h1>
<p> {{ pset }} </p>
</div>
infoService.ts
getInfo(profCode: string): Observable<any> {
return this.http.get('http://paintAPI.app/getInformation/' + pCode)
.map(
(response: Response) => {
return response.json().info;
}
);
}
info.component.ts
dInfo: DInfoInterface[] = [];
ngOnInit() {
this.infoService.getInfo(this.pCode)
.subscribe(
(dInfo: DInfoInterface[]) => {
this.dInfo = dInfo;
},
(error: Response) => console.log(error)
);
}
DInfoInterface.ts
export interface DieInfoInterface {
pCode: string;
cCode: string;
pset: string
}
--
You received this message because you are subscribed to the Google Groups
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.