mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
19 lines
397 B
JavaScript
19 lines
397 B
JavaScript
import uuid from 'uuid/v4'
|
|
|
|
export default function create() {
|
|
return {
|
|
factory: async ({ args, neodeInstance }) => {
|
|
const defaults = {
|
|
id: uuid(),
|
|
icon: 'img/badges/fundraisingbox_de_airship.svg',
|
|
name: 'Some category name',
|
|
}
|
|
args = {
|
|
...defaults,
|
|
...args,
|
|
}
|
|
return neodeInstance.create('Category', args)
|
|
},
|
|
}
|
|
}
|