From 9f7be0dbbe5e482ef8f3c18784f4f1f3def81a0f Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Tue, 18 Oct 2016 10:36:16 +0200 Subject: [PATCH] Errores al generar rutas solucionados --- @salix/app/dependencies.js | 4 ++++ @salix/app/src/app.js | 2 +- @salix/app/src/{routes.js => configroutes.js} | 0 @salix/crud/src/customer/routes.js | 4 ++-- gulpfile.js | 4 ++-- 5 files changed, 9 insertions(+), 5 deletions(-) create mode 100644 @salix/app/dependencies.js rename @salix/app/src/{routes.js => configroutes.js} (100%) diff --git a/@salix/app/dependencies.js b/@salix/app/dependencies.js new file mode 100644 index 000000000..65b9c87bf --- /dev/null +++ b/@salix/app/dependencies.js @@ -0,0 +1,4 @@ +{ + compras: ["crud"], + crud: [] +} diff --git a/@salix/app/src/app.js b/@salix/app/src/app.js index b3ac02fdd..833374e39 100644 --- a/@salix/app/src/app.js +++ b/@salix/app/src/app.js @@ -1,5 +1,5 @@ import {bootstrap} from './bootstrap'; import * as spliting from './spliting'; -import * as routes from './routes'; +import * as routes from './configroutes'; bootstrap(); diff --git a/@salix/app/src/routes.js b/@salix/app/src/configroutes.js similarity index 100% rename from @salix/app/src/routes.js rename to @salix/app/src/configroutes.js diff --git a/@salix/crud/src/customer/routes.js b/@salix/crud/src/customer/routes.js index d5158a39b..d68ceeac3 100644 --- a/@salix/crud/src/customer/routes.js +++ b/@salix/crud/src/customer/routes.js @@ -1,8 +1,8 @@ -{ +[{ url: '/index', state: 'index', template: '', module: 'crud', description: '', image: '', -} +}] diff --git a/gulpfile.js b/gulpfile.js index d2286aca0..901302888 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -5,7 +5,7 @@ var insert = require ('gulp-insert'); var babel = require ('gulp-babel'); var wrap = require("gulp-wrap"); -var template = '"<%=file.path%>": <%=contents%>'; +var template = '\n"<%=file.path%>": <%=contents%>'; gulp.task ('default', function () { @@ -13,7 +13,7 @@ gulp.task ('default', function () .pipe (wrap (template)) .pipe (concat ('salix.routes.js', {newLine: ','})) .pipe (insert.prepend ('var routes = {')) - .pipe (insert.append ('};')) + .pipe (insert.append ('\n};')) .pipe (babel ({presets: ['es2015']})) .pipe (gulp.dest ('./build/private')); });