Commit c9b8af6e authored by Vipul Basapati's avatar Vipul Basapati

Added Flash component in frontend app #219

parent d8218f5f
......@@ -743,7 +743,7 @@ function _init() {
* or customize the JavaScript scaffolding to fit your unique needs.
*/
Vue.component('flash', require('../components/backend/Flash.vue'));
Vue.component('flash', require('../components/Flash.vue'));
Vue.component('export-component', require('../components/backend/Export.vue'));
const app = new Vue({
......
......@@ -29,11 +29,16 @@ export default {
methods: {
flash(message, type) {
this.body = message;
this.typeClass = "alert alert-" + type;
this.show = true;
if (! type) {
type = "info";
}
this.hide();
this.body = message;
this.typeClass = "alert alert-" + type;
this.show = true;
this.hide();
},
hide() {
......
......@@ -13,6 +13,7 @@ require('../bootstrap');
* or customize the JavaScript scaffolding to fit your unique needs.
*/
Vue.component('flash', require('../components/Flash.vue'));
Vue.component('example', require('../components/frontend/Example.vue'));
const app = new Vue({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment