Skip to content

Instantly share code, notes, and snippets.

View qmateub's full-sized avatar
🏐
Balling

Quique Mateu qmateub

🏐
Balling
View GitHub Profile
@qmateub
qmateub / conversions.js
Last active January 14, 2019 11:09
Form conversions
{
[group]: { // group is products, categories, customers (each collapsible panel in the designs contains a group data)
auxiliaryValues: { // this values are just for the form behaviours that's why is called auxiliar
enabled: Boolean, // Computed if in the permissions object you have `manage${group}` or `view${group}`
viewOnly: Boolean, // you check for `manage${group}` false and `view${group}` true
viewAndEdit: Boolean, // you check only form `manage${group}` true
},
actionRights: {
// publishProducts, unpublishProducts,etc. All the stuff computed from `allSupportedActionRights` and the data from the CORE API.
}
@qmateub
qmateub / curl.hbs
Last active June 8, 2018 10:51
Usage examples
curl {{authUrl}} \
--basic --user "{{clientId}}:{{clientSecret}}" \
-X POST \
-d "grant_type=client_credentials&scope={{scope}}:{{projectKey}}"