Feature: bootstrapping an app to show a modal for address details and showing it inside twig address's render box

Feature: showing map and link to external map, and address details inside address details modal

Feature: AddressDetailsMap show a warning if the address is incomplete
This commit is contained in:
2023-03-14 22:12:30 +01:00
parent c56ae08fae
commit b740a88ae3
16 changed files with 283 additions and 11 deletions

View File

@@ -0,0 +1,14 @@
import {Address} from "../../types";
export const getAddressById = async (address_id: number): Promise<Address> =>
{
const url = `/api/1.0/main/address/${address_id}.json`;
const response = await fetch(url);
if (response.ok) {
return response.json();
}
throw Error('Error with request resource response');
};