Merge pull request #49 from Pear-Trading/finn/endpointchange

changed customer dashboard endpoint
This commit is contained in:
Finn 2017-12-18 14:06:33 +00:00 committed by GitHub
commit b8fcedaf09
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View file

@ -114,7 +114,7 @@ export class DashboardCustomerComponent implements OnInit {
constructor(
private api: ApiService,
) {
this.api.basicStats().subscribe(
this.api.customerStats().subscribe(
result => {
this.setWeekPurchaseList(result.weeks);
this.setSectorList(result.sectors);

View file

@ -23,8 +23,8 @@
<thead>
<tr>
<th>Position</th>
<th>Value</th>
<th>Purchase Time</th>
<th>Name</th>
<th>Amount</th>
</tr>
</thead>
<tbody>

View file

@ -286,10 +286,10 @@ export class ApiService {
}
// Basic Customer User stats API
public basicStats() {
public customerStats() {
const key = this.sessionKey;
return this.http.post<any>(
this.apiUrl + '/stats',
this.apiUrl + '/stats/customer',
{
session_key : key,
}