|
@@ -0,0 +1,37 @@
|
|
|
|
|
+var empresa = {
|
|
|
|
|
+ template: '#empresa',
|
|
|
|
|
+ data: function () {
|
|
|
|
|
+ return {
|
|
|
|
|
+ title: 'Empresa'
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+var productos = {
|
|
|
|
|
+ template: '#productos',
|
|
|
|
|
+ data: function () {
|
|
|
|
|
+ return {
|
|
|
|
|
+ title: 'Productos'
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+ Vue.component('empresa', empresa);
|
|
|
|
|
+ Vue.component('productos', productos);
|
|
|
|
|
+
|
|
|
|
|
+var routes = [
|
|
|
|
|
+ { path: '/empresa', component: empresa, text: 'Empresa' },
|
|
|
|
|
+ { path: '/productos', component: productos, text: 'Productos' }
|
|
|
|
|
+]
|
|
|
|
|
+
|
|
|
|
|
+var router = new VueRouter({
|
|
|
|
|
+ routes: routes
|
|
|
|
|
+})
|
|
|
|
|
+
|
|
|
|
|
+new Vue({
|
|
|
|
|
+ el: '#app',
|
|
|
|
|
+ router: router,
|
|
|
|
|
+ data: {
|
|
|
|
|
+ routes: routes
|
|
|
|
|
+ }
|
|
|
|
|
+})
|