daothanh / taxonomy
Manage taxonomy
Installs: 176
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
Type:asgard-module
pkg:composer/daothanh/taxonomy
Requires
- php: >=7.0.0
 - composer/installers: ~1.0
 - idavoll/core-module: ~3.0
 
Requires (Dev)
- orchestra/testbench: 3.5.*
 - phpunit/phpunit: ~6.0
 
README
Simple module that help you to manage your taxonomy (category)
Installation
Module Download
Using AsgardCMS's module download command:
php artisan asgard:download:module daothanh/taxonomy --migrations
This will download the module, run its migrations.
Composer
composer require daothanh/taxonomy php artisan module:migrate Taxonomy
Add Routes
Go to  reosources/assets/js/app.js
- Import Routes: 
import TaxonomyRoutes from '../../../Modules/Taxonomy/Assets/js/TaxonomyRoutes'; - Add 
TaxonomyRoutesto router:...TaxonomyRoutes, - Build webpack by 
npm run dev 
Add the category to form
To show the category box in your form . You must use the TermsBox (a vuejs component) or taxonomyChooseTerms directive (with blade)
Example for page form:
<template>
<TermsBox vocabularyId="1" entity="Modules\Page\Entities\Page"/>
</template>
<script>
import TermsBox from '../../../../Taxonomy/Assets/js/components/TermsBox';`
export default {
        components: {TermsBox}
}
</script>