diff --git a/company_generic.svg b/company_generic.svg new file mode 100644 index 0000000..c935139 --- /dev/null +++ b/company_generic.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/stockingly-frontend/src/api/index.ts b/stockingly-frontend/src/api/index.ts index 2dbc27e..61298e2 100644 --- a/stockingly-frontend/src/api/index.ts +++ b/stockingly-frontend/src/api/index.ts @@ -13,7 +13,11 @@ export interface Company { tags: string[]; ticker: string; website: string; + logoSrc: string } export const getCompanies = (): Promise => - fetch(BACKEND_URL + '/companies').then(r => r.json()) \ No newline at end of file + fetch(BACKEND_URL + '/companies').then(r => r.json()).then(list => list.map((e: Company) => ({ + ...e, + logoSrc: `${BACKEND_URL}/companies/logos/${e.ticker}` + }))); \ No newline at end of file diff --git a/stockingly-frontend/src/views/Home.vue b/stockingly-frontend/src/views/Home.vue index 6f9bff1..789b8d3 100644 --- a/stockingly-frontend/src/views/Home.vue +++ b/stockingly-frontend/src/views/Home.vue @@ -9,10 +9,16 @@