How to use the admin-bro.BaseRecord function in admin-bro

To help you get started, we’ve selected a few admin-bro examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github SoftwareBrothers / admin-bro-dev / examples / rest / postcode.js View on Github external
    return rest.data.results.map(obj => new BaseRecord(obj, this))
  }
github SoftwareBrothers / admin-bro-dev / examples / rest / postcode.js View on Github external
async findOne(id) {
    const rest = await axios.get(`https://api.shopjam.com.au/api/v4/locations/postcodes/${id}`)
    return new BaseRecord(rest.data.postcode, this)
  }
}