Commit e3062666 authored by D’jalmar Gutierrez Titirico's avatar D’jalmar Gutierrez Titirico 🚲
Browse files

Merge branch 'release-0.3.0' into 'master'

Release 0.3.0



See merge request !3
parents 27b954c4 6afe8da0
......@@ -37,12 +37,12 @@ module.exports = function (grunt) {
},
express: {
options: {
port: process.env.PORT || 9000
port: process.env.PORT || 9001
},
dev: {
options: {
script: '<%= yeoman.server %>',
debug: true
debug: 5859
}
},
prod: {
......@@ -102,14 +102,14 @@ module.exports = function (grunt) {
'<%= yeoman.client %>/assets/images/{,*//*}*.{png,jpg,jpeg,gif,webp,svg}'
],
options: {
livereload: true
livereload: 35728,
}
},
express: {
files: ['<%= yeoman.server %>/**/*.{js,json}'],
tasks: ['express:dev', 'wait'],
options: {
livereload: true,
livereload: 35728,
spawn: false //Without this option specified express won't be reloaded
}
},
......@@ -193,7 +193,8 @@ module.exports = function (grunt) {
'node-inspector': {
custom: {
options: {
'web-host': 'localhost'
'web-host': 'localhost',
'debug-port': 5859
}
}
},
......@@ -205,7 +206,7 @@ module.exports = function (grunt) {
options: {
nodeArgs: ['--debug-brk'],
env: {
PORT: process.env.PORT || 9000
PORT: process.env.PORT || 9001
},
callback: function (nodemon) {
nodemon.on('log', function (event) {
......@@ -215,7 +216,7 @@ module.exports = function (grunt) {
// opens browser on initial server start
nodemon.on('config:update', function () {
setTimeout(function () {
require('open')('http://localhost:8080/debug?port=5858');
require('open')('http://localhost:8080/debug?port=5859');
}, 500);
});
}
......@@ -602,11 +603,11 @@ module.exports = function (grunt) {
},
files: {
'<%= yeoman.client %>/index.html': [
[
'<%= yeoman.client %>/{app,components}/**/!(*.spec|*.mock).js',
'!{.tmp,<%= yeoman.client %>}/app/app.{js,ts}'
]
[
'<%= yeoman.client %>/{app,components}/**/!(*.spec|*.mock).js',
'!{.tmp,<%= yeoman.client %>}/app/app.{js,ts}'
]
]
}
},
......@@ -668,22 +669,22 @@ module.exports = function (grunt) {
});
grunt.registerTask('serve', function (target) {
if (target === 'dist') {
return grunt.task.run(['build', 'env:all', 'env:prod', 'express:prod', 'wait', 'open', 'express-keepalive']);
}
if (target === 'debug') {
return grunt.task.run([
'clean:server',
'env:all',
'concurrent:pre',
'concurrent:server',
'injector',
'wiredep:client',
'postcss',
'concurrent:debug'
]);
}
// if (target === 'dist') {
// return grunt.task.run(['build', 'env:all', 'env:prod', 'express:prod', 'wait', 'open', 'express-keepalive']);
// }
//
// if (target === 'debug') {
// return grunt.task.run([
// 'clean:server',
// 'env:all',
// 'concurrent:pre',
// 'concurrent:server',
// 'injector',
// 'wiredep:client',
// 'postcss',
// 'concurrent:debug'
// ]);
// }
grunt.task.run([
'clean:server',
......@@ -706,95 +707,95 @@ module.exports = function (grunt) {
});
grunt.registerTask('test', function(target, option) {
if (target === 'server') {
return grunt.task.run([
'env:all',
'env:test',
'mochaTest:unit',
'mochaTest:integration'
]);
}
else if (target === 'client') {
return grunt.task.run([
'clean:server',
'env:all',
'concurrent:pre',
'concurrent:test',
'injector',
'postcss',
'wiredep:test',
'karma'
]);
}
else if (target === 'e2e') {
if (option === 'prod') {
return grunt.task.run([
'build',
'env:all',
'env:prod',
'express:prod',
'protractor'
]);
}
else {
return grunt.task.run([
'clean:server',
'env:all',
'env:test',
'concurrent:pre',
'concurrent:test',
'injector',
'wiredep:client',
'postcss',
'express:dev',
'protractor'
]);
}
}
else if (target === 'coverage') {
if (option === 'unit') {
return grunt.task.run([
'env:all',
'env:test',
'mocha_istanbul:unit'
]);
}
else if (option === 'integration') {
return grunt.task.run([
'env:all',
'env:test',
'mocha_istanbul:integration'
]);
}
else if (option === 'check') {
return grunt.task.run([
'istanbul_check_coverage'
]);
}
else {
return grunt.task.run([
'env:all',
'env:test',
'mocha_istanbul',
'istanbul_check_coverage'
]);
}
}
else grunt.task.run([
'test:server',
'test:client'
// if (target === 'server') {
// return grunt.task.run([
// 'env:all',
// 'env:test',
// 'mochaTest:unit',
// 'mochaTest:integration'
// ]);
// }
//
// else if (target === 'client') {
return grunt.task.run([
'clean:server',
'env:all',
'concurrent:pre',
'concurrent:test',
'injector',
'postcss',
'wiredep:test',
'karma'
]);
//}
//
// else if (target === 'e2e') {
//
// if (option === 'prod') {
// return grunt.task.run([
// 'build',
// 'env:all',
// 'env:prod',
// 'express:prod',
// 'protractor'
// ]);
// }
//
// else {
// return grunt.task.run([
// 'clean:server',
// 'env:all',
// 'env:test',
// 'concurrent:pre',
// 'concurrent:test',
// 'injector',
// 'wiredep:client',
// 'postcss',
// 'express:dev',
// 'protractor'
// ]);
// }
// }
//
// else if (target === 'coverage') {
//
// if (option === 'unit') {
// return grunt.task.run([
// 'env:all',
// 'env:test',
// 'mocha_istanbul:unit'
// ]);
// }
//
// else if (option === 'integration') {
// return grunt.task.run([
// 'env:all',
// 'env:test',
// 'mocha_istanbul:integration'
// ]);
// }
//
// else if (option === 'check') {
// return grunt.task.run([
// 'istanbul_check_coverage'
// ]);
// }
//
// else {
// return grunt.task.run([
// 'env:all',
// 'env:test',
// 'mocha_istanbul',
// 'istanbul_check_coverage'
// ]);
// }
//
// }
//
// else grunt.task.run([
// 'test:server',
// 'test:client'
// ]);
});
grunt.registerTask('build', [
......
......@@ -3,7 +3,7 @@
angular.module('moduloPersonalApp.constants', [])
.constant('appConfig', {userRoles:['guest','user','ADMINISTRATOR']})
.constant('appConfig', {userRoles:['guest','user','ADMINISTRATOR'],serverAddress:'http://localhost:9000',clientAddress:'http:localhost:9000'})
;
})(angular);
\ No newline at end of file
$brand-primary: #0275d8;
$brand-success: #5cb85c;
$brand-info: #5bc0de;
$brand-warning: #f0ad4e;
$brand-danger: #d9534f;
$gray-dark: #373a3c !default;
$btn-secondary-color: $gray-dark !default;
$btn-secondary-bg: #fff !default;
$btn-secondary-border: #ccc !default;
$icon-font-path: "../bower_components/bootstrap-sass-official/vendor/assets/fonts/bootstrap/";
@import '../bower_components/bootstrap-sass-official/vendor/assets/stylesheets/bootstrap';
$fa-font-path: "../bower_components/font-awesome/fonts";
@import '../bower_components/font-awesome/scss/font-awesome';
$enable-hover-media-query: false !default;
@mixin hover {
@if $enable-hover-media-query {
// See Media Queries Level 4: http://drafts.csswg.org/mediaqueries/#hover
// Currently shimmed by https://github.com/twbs/mq4-hover-shim
@media (hover: hover) {
&:hover {
@content
}
}
} @else {
&:hover {
@content
}
}
}
@mixin button-outline-variant($color) {
color: $color;
background-image: none;
background-color: transparent;
border-color: $color;
&:focus,
&.focus,
&:active,
&.active,
.open > &.dropdown-toggle {
color: #fff;
background-color: $color;
border-color: $color;
}
@include hover {
color: #fff;
background-color: $color;
border-color: $color;
}
&.disabled,
&:disabled {
&:focus,
&.focus {
border-color: lighten($color, 20%);
}
@include hover {
border-color: lighten($color, 20%);
}
}
}
/**
* App-wide Styles
*/
$femenino-color: #ff81e3;
$masculino-color: #57b6ff;
// Remove all backgrounds
.btn-primary-outline {
@include button-outline-variant($btn-primary-bg);
}
.btn-secondary-outline {
@include button-outline-variant($btn-secondary-border);
}
.btn-info-outline {
@include button-outline-variant($btn-info-bg);
}
.btn-success-outline {
@include button-outline-variant($btn-success-bg);
}
.btn-warning-outline {
@include button-outline-variant($btn-warning-bg);
}
.btn-danger-outline {
@include button-outline-variant($btn-danger-bg);
}
blockquote.blockquote-primary {
border-left-color: $brand-primary;
font-size: 14px;
p {
text-align: justify;
}
p.fecha {
text-align: right;
}
}
//tags
tags-input.primary .tags .tag-item {
color: #fff;
background: $brand-primary;
border: 1px solid $brand-primary;
border-radius: 4px;
}
//titulos
h4.color-primary {
color: $brand-primary;
}
.browserupgrade {
margin: 0.2em 0;
......@@ -15,15 +123,18 @@ $masculino-color: #57b6ff;
color: #000;
padding: 0.2em 0;
}
.sub-header {
padding-bottom: 10px;
border-bottom: 1px solid #eee;
}
.input-group {
margin-bottom: 10px;
}
.header-button{
margin-top: 20px;
.header-button {
margin-top: 14px;
margin-bottom: 10px;
}
......
......@@ -8,7 +8,7 @@
</div>
<div class="col-sm-3 col-sm-offset-5">
<div class="pull-right">
<button class="btn btn-success header-button" ng-click="vm.crearCargos()">
<button class="btn btn-success-outline header-button" ng-click="vm.crearCargos()">
<i class="fa fa-plus"></i> Crear Cargo
</button>
</div>
......@@ -30,7 +30,7 @@
<tr ng-repeat="cargo in vm.cargos">
<td>{{cargo.nombre}}</td>
<td width="150">
<a class="btn btn-info btn-xs" href="#" role="button" ng-click="vm.editar(cargo._id)"><i
<a class="btn btn-info-outline btn-xs" href="#" role="button" ng-click="vm.editar(cargo._id)"><i
class="fa fa-edit fa-lg"></i></a>
</td>
<!--Mostrar un dialogo de eliminar-->
......
......@@ -2,8 +2,8 @@
'use strict';
class CargoService {
constructor($resource) {
this.resource = $resource('/api/cargos/:id', {id: '@_id'}, {
constructor($resource, appConfig) {
this.resource = $resource(appConfig.serverAddress + '/api/cargos/:id', {id: '@_id'}, {
update: {method: 'PUT'},
query: {isArray: false}
})
......
......@@ -18,7 +18,7 @@
<input type="text" name="nombre" class="form-control" ng-model="vm.cargo.nombre"
placeholder="Nombre de cargo" required>
<span class="input-group-btn">
<button type="button" class="btn btn-primary" ng-click="vm.guardarCargo(form,'nombre')"
<button type="button" class="btn btn-primary-outline" ng-click="vm.guardarCargo(form,'nombre')"
ng-disabled="!form.nombre.$dirty"><i class="fa fa-save"></i></button>
</span>
</p>
......@@ -53,7 +53,7 @@
<td>{{postulante.apellidos}}</td>
<td>{{postulante.ci}}</td>
<td>
<button type="button" class="btn btn-danger" ng-click="vm.eliminarPostulacion(postulante)"><i
<button type="button" class="btn btn-danger-outline" ng-click="vm.eliminarPostulacion(postulante)"><i
class="fa fa-trash" title="Eliminar postulación"></i></button>
</td>
</tr>
......@@ -65,7 +65,7 @@
<div class="row">
<div class="col-md-10">
<div class="pull-right">
<button class="btn btn-success" ng-click="vm.crearPostulanteACargo()" type="button"><i
<button class="btn btn-success-outline" ng-click="vm.crearPostulanteACargo()" type="button"><i
class="fa fa-plus"></i>
Nueva Postulación
</button>
......
......@@ -18,7 +18,7 @@
</div>
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="submit" ng-disabled="!(form.nombre.$dirty) || form.$invalid">
<button class="btn btn-primary-outline" type="submit" ng-disabled="!(form.nombre.$dirty) || form.$invalid">
Guardar
</button>
<button class="btn btn-default" type="button" ng-click="vm.modal.dismiss()">Cancelar</button>
......
......@@ -2,8 +2,8 @@
'use strict';
class ComentarioService {
constructor($resource) {
this.resource = $resource('/api/comentarios/:id', {id: '@_id'}, {
constructor($resource, appConfig) {
this.resource = $resource(appConfig.serverAddress +'/api/comentarios/:id', {id: '@_id'}, {
update: {method: 'PUT'},
query: {isArray: false}
})
......
......@@ -30,7 +30,7 @@
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="submit" ng-disabled="!form.contenido.$dirty">
<button class="btn btn-primary-outline" type="submit" ng-disabled="!form.contenido.$dirty">
Guardar
</button>
<button class="btn btn-default" type="button" ng-click="vm.modal.dismiss()">Cancelar</button>
......
......@@ -2,8 +2,8 @@
'use strict';
class DatoPostulanteService {
constructor($resource) {
this.resource = $resource('/api/datosPostulantes/:id', {id: '@_id'}, {
constructor($resource, appConfig) {
this.resource = $resource(appConfig.serverAddress + '/api/datosPostulantes/:id', {id: '@_id'}, {
update: {method: 'PUT'},
query: {isArray: false}
})
......
......@@ -32,7 +32,7 @@
</div>
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="submit" ng-disabled="!(form.tiposDato.$dirty ||form.valor.$dirty)">
<button class="btn btn-primary-outline" type="submit" ng-disabled="!(form.tiposDato.$dirty ||form.valor.$dirty)">
Guardar
</button>
<button class="btn btn-default" type="button" ng-click="vm.modal.dismiss()">Cancelar</button>
......
<header class="hero-unit" id="banner">
<header class="hero-unit" id="banner">
<div class="container">
<h1>Modulo Personal</h1>
</div>
......@@ -7,9 +7,7 @@
<div class="container">
<div class="row">
<div class="col-lg-10">
<h1 class="page-header">Descripción:</h1>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Amet architecto aut consectetur consequatur dolores
eaque eum iure, labore, laudantium magnam maxime porro quam rerum sequi sunt totam vel voluptatibus. Eos.</p>
</div>
</div>
</div>
......@@ -50,7 +50,7 @@
</div>
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="submit" ng-disabled="!(form.postulante.$dirty || form.presentacion.$dirty) || form.$invalid">
<button class="btn btn-primary-outline" type="submit" ng-disabled="!(form.postulante.$dirty || form.presentacion.$dirty) || form.$invalid">
Guardar
</button>
<button class="btn btn-default" type="button" ng-click="vm.modal.dismiss()">Cancelar</button>
......
......@@ -32,7 +32,7 @@
</div>
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="submit" ng-disabled="!(form.cargos.$dirty ||form.presentacion.$dirty)">
<button class="btn btn-primary-outline" type="submit" ng-disabled="!(form.cargos.$dirty ||form.presentacion.$dirty)">
Guardar
</button>
<button class="btn btn-default" type="button" ng-click="vm.modal.dismiss()">Cancelar</button>
......
(()=> {
'use strict';
class PostulacionService {
constructor($resource) {
this.resource = $resource('/api/postulaciones/:id', {id: '@_id', postulanteId: '@_id', cargoId: '@_id'}, {
constructor($resource, appConfig) {
this.resource = $resource(appConfig.serverAddress + '/api/postulaciones/:id', {
id: '@_id',
postulanteId: '@_id',
cargoId: '@_id'
}, {
update: {method: 'PUT'},
query: {isArray: false},
postulacionesPostulante: {
......
<div ng-controller="PostulantesEditarCtrl">
<h2 class="sub-header">Editar Postulante
<small class="pull-right">
<a class