dadi / web

Web is a drop in front end for websites and web apps. Consumes data from DADI API and others
https://dadi.cloud/en/web/
Other
48 stars 16 forks source link

Several modifications #488

Closed jimlambie closed 5 years ago

jimlambie commented 5 years ago

Allow flattened datasource specification files, to match the page specification files. This is backwards compatible, the datasource property is added internally.

{
    key: 'car_makes',
    name: 'Makes datasource',
    source: [Object],
    paginate: true,
    compose: "all",
    count: 20,
    search: {},
    filter: {}
}

Allow page specification files without the "page" block, using the filename as the page name internally.

Both the following examples will work:

{
  "page": {
    "name": "index"
  },
  "routes": [
    {
      "path": "/"
    }
  ]
}
{
  "routes": [
    {
      "path": "/"
    }
  ]
}

Allow "composed" option in datasources. The value will be added to the API endpoint.

{
  datasource: {
    key: 'car_makes',
    name: 'Makes datasource',
    source: [Object],
    paginate: true,
    compose: "all",
    count: 20,
    search: {},
    filter: {}
  }
}

Close #263 Close #438 Close #479