(get-attach-map record attachments)
Helper function for integrate attachments; returns a function from
a filename to a url-obj
(see specs in url-obj
function).
Helper function for integrate attachments; returns a function from a filename to a `url-obj` (see specs in `url-obj` function).
(get-matching-name fname fnames)
Gets and returns matching name for an attachment that was renamed by appending a hash on the S3 server to avoid duplicating names. e.g. if 1478203839187.jpg was renamed to 1478203839187_wijUzUf.jpg, it returns 1478203839187_wijUzUf.jpg.
Gets and returns matching name for an attachment that was renamed by appending a hash on the S3 server to avoid duplicating names. e.g. if 1478203839187.jpg was renamed to 1478203839187_wijUzUf.jpg, it returns 1478203839187_wijUzUf.jpg.
(integrate-attachments flat-form data & {:keys [attachments]})
Inlines media data from within _attachments into each record. Coll Coll -> Coll
Inlines media data from within _attachments into each record. Coll Coll -> Coll
(integrate-attachments! app-state
flat-form
&
{:keys [app-data-keys] :or {app-data-keys [:data]}})
Inlines data from within _attachments into each record within app-state.
Inlines data from within _attachments into each record within app-state.
(integrate-attachments-in-repeats flat-form data)
Inlines data from within _attachments into each datapoint within repeats.
Inlines data from within _attachments into each datapoint within repeats.
(integrate-osm-data! app-state form osm-xml app-state-keys)
Given some data post-processed from the ona server (ie, containing _id, _rank), and a string of osm-xml, produce a version with relevant osm data injected in.
Given some data post-processed from the ona server (ie, containing _id, _rank), and a string of osm-xml, produce a version with relevant osm data injected in.
(ona-osm-link data form)
Given some data in Ona format, builds a data structure that we will use to link osm data to Ona data.
Given some data in Ona format, builds a data structure that we will use to link osm data to Ona data.
(osm-id->osm-data data form osm-xml)
Given some data in OSM format, an Ona Form, and osm xml string, return a map from OSM ID to each osm feature. The map contains: :osm-id, :name, :tags from osm xml, :type, :geom from osm feature's geojson equivalent.
Given some data in OSM format, an Ona Form, and osm xml string, return a map from OSM ID to each osm feature. The map contains: :osm-id, :name, :tags from osm xml, :type, :geom from osm feature's geojson equivalent.
(osm-xml->geojson osm-xml-string)
Takes OSM XML in string form, and returns cljs geojson.
Takes OSM XML in string form, and returns cljs geojson.
(url-obj media-obj)
Calculate full image and thumbnail urls given attachment information.
Calculate full image and thumbnail urls given attachment information.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close