diff --git a/app/.io-config.json b/app/.io-config.json
new file mode 100644
index 0000000..4626f88
--- /dev/null
+++ b/app/.io-config.json
@@ -0,0 +1 @@
+{"app_id":"0f46f512"}
\ No newline at end of file
diff --git a/app/comandesUtils.txt b/app/comandesUtils.txt
new file mode 100644
index 0000000..428ea6e
--- /dev/null
+++ b/app/comandesUtils.txt
@@ -0,0 +1,12 @@
+
+export ANDROID_HOME=~/Android/Sdk/
+PATH=$PATH:$ANDROID_HOME/tools
+PATH=$PATH:$ANDROID_HOME/platform-tools
+
+
+cd /home/nau/Android/Sdk/tools
+./android
+
+
+ionic serve
+ionic build android
diff --git a/app/config.xml b/app/config.xml
index 3c2b1b4..b85343f 100644
--- a/app/config.xml
+++ b/app/config.xml
@@ -16,7 +16,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/ionic.config.json b/app/ionic.config.json
new file mode 100644
index 0000000..40090e1
--- /dev/null
+++ b/app/ionic.config.json
@@ -0,0 +1,4 @@
+{
+ "name": "app",
+ "app_id": "0f46f512"
+}
diff --git a/app/ionic.project b/app/ionic.project
index d9c3a36..40090e1 100644
--- a/app/ionic.project
+++ b/app/ionic.project
@@ -1,4 +1,4 @@
{
"name": "app",
- "app_id": ""
+ "app_id": "0f46f512"
}
diff --git a/app/package.json b/app/package.json
index 1472391..8f7d886 100644
--- a/app/package.json
+++ b/app/package.json
@@ -1,7 +1,7 @@
{
- "name": "app",
+ "name": "collectivecar",
"version": "1.1.1",
- "description": "app: An Ionic project",
+ "description": "app: collectivecar",
"dependencies": {
"gulp": "^3.5.6",
"gulp-sass": "^2.0.4",
@@ -23,4 +23,4 @@
"ionic-plugin-keyboard"
],
"cordovaPlatforms": []
-}
\ No newline at end of file
+}
diff --git a/app/resources/android/icon/drawable-hdpi-icon.png b/app/resources/android/icon/drawable-hdpi-icon.png
new file mode 100644
index 0000000..b910093
Binary files /dev/null and b/app/resources/android/icon/drawable-hdpi-icon.png differ
diff --git a/app/resources/android/icon/drawable-ldpi-icon.png b/app/resources/android/icon/drawable-ldpi-icon.png
new file mode 100644
index 0000000..16cd5db
Binary files /dev/null and b/app/resources/android/icon/drawable-ldpi-icon.png differ
diff --git a/app/resources/android/icon/drawable-mdpi-icon.png b/app/resources/android/icon/drawable-mdpi-icon.png
new file mode 100644
index 0000000..64a6cbc
Binary files /dev/null and b/app/resources/android/icon/drawable-mdpi-icon.png differ
diff --git a/app/resources/android/icon/drawable-xhdpi-icon.png b/app/resources/android/icon/drawable-xhdpi-icon.png
new file mode 100644
index 0000000..1605f69
Binary files /dev/null and b/app/resources/android/icon/drawable-xhdpi-icon.png differ
diff --git a/app/resources/android/icon/drawable-xxhdpi-icon.png b/app/resources/android/icon/drawable-xxhdpi-icon.png
new file mode 100644
index 0000000..56fb29e
Binary files /dev/null and b/app/resources/android/icon/drawable-xxhdpi-icon.png differ
diff --git a/app/resources/android/icon/drawable-xxxhdpi-icon.png b/app/resources/android/icon/drawable-xxxhdpi-icon.png
new file mode 100644
index 0000000..e4a9152
Binary files /dev/null and b/app/resources/android/icon/drawable-xxxhdpi-icon.png differ
diff --git a/app/resources/android/splash/drawable-land-hdpi-screen.png b/app/resources/android/splash/drawable-land-hdpi-screen.png
new file mode 100644
index 0000000..66b12fe
Binary files /dev/null and b/app/resources/android/splash/drawable-land-hdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-land-ldpi-screen.png b/app/resources/android/splash/drawable-land-ldpi-screen.png
new file mode 100644
index 0000000..7dceec7
Binary files /dev/null and b/app/resources/android/splash/drawable-land-ldpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-land-mdpi-screen.png b/app/resources/android/splash/drawable-land-mdpi-screen.png
new file mode 100644
index 0000000..0dc2ba7
Binary files /dev/null and b/app/resources/android/splash/drawable-land-mdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-land-xhdpi-screen.png b/app/resources/android/splash/drawable-land-xhdpi-screen.png
new file mode 100644
index 0000000..39ae00c
Binary files /dev/null and b/app/resources/android/splash/drawable-land-xhdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-land-xxhdpi-screen.png b/app/resources/android/splash/drawable-land-xxhdpi-screen.png
new file mode 100644
index 0000000..3f591b1
Binary files /dev/null and b/app/resources/android/splash/drawable-land-xxhdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-land-xxxhdpi-screen.png b/app/resources/android/splash/drawable-land-xxxhdpi-screen.png
new file mode 100644
index 0000000..253e6f1
Binary files /dev/null and b/app/resources/android/splash/drawable-land-xxxhdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-hdpi-screen.png b/app/resources/android/splash/drawable-port-hdpi-screen.png
new file mode 100644
index 0000000..e0dbb62
Binary files /dev/null and b/app/resources/android/splash/drawable-port-hdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-ldpi-screen.png b/app/resources/android/splash/drawable-port-ldpi-screen.png
new file mode 100644
index 0000000..8e93c2d
Binary files /dev/null and b/app/resources/android/splash/drawable-port-ldpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-mdpi-screen.png b/app/resources/android/splash/drawable-port-mdpi-screen.png
new file mode 100644
index 0000000..0aaad62
Binary files /dev/null and b/app/resources/android/splash/drawable-port-mdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-xhdpi-screen.png b/app/resources/android/splash/drawable-port-xhdpi-screen.png
new file mode 100644
index 0000000..64c27f8
Binary files /dev/null and b/app/resources/android/splash/drawable-port-xhdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-xxhdpi-screen.png b/app/resources/android/splash/drawable-port-xxhdpi-screen.png
new file mode 100644
index 0000000..f605e6a
Binary files /dev/null and b/app/resources/android/splash/drawable-port-xxhdpi-screen.png differ
diff --git a/app/resources/android/splash/drawable-port-xxxhdpi-screen.png b/app/resources/android/splash/drawable-port-xxxhdpi-screen.png
new file mode 100644
index 0000000..2b993cf
Binary files /dev/null and b/app/resources/android/splash/drawable-port-xxxhdpi-screen.png differ
diff --git a/app/resources/icon.png b/app/resources/icon.png
new file mode 100644
index 0000000..bee7766
Binary files /dev/null and b/app/resources/icon.png differ
diff --git a/app/resources/ios/icon/icon-40.png b/app/resources/ios/icon/icon-40.png
new file mode 100644
index 0000000..76cc53c
Binary files /dev/null and b/app/resources/ios/icon/icon-40.png differ
diff --git a/app/resources/ios/icon/icon-40@2x.png b/app/resources/ios/icon/icon-40@2x.png
new file mode 100644
index 0000000..64b4906
Binary files /dev/null and b/app/resources/ios/icon/icon-40@2x.png differ
diff --git a/app/resources/ios/icon/icon-50.png b/app/resources/ios/icon/icon-50.png
new file mode 100644
index 0000000..8bd51df
Binary files /dev/null and b/app/resources/ios/icon/icon-50.png differ
diff --git a/app/resources/ios/icon/icon-50@2x.png b/app/resources/ios/icon/icon-50@2x.png
new file mode 100644
index 0000000..2676f8f
Binary files /dev/null and b/app/resources/ios/icon/icon-50@2x.png differ
diff --git a/app/resources/ios/icon/icon-60.png b/app/resources/ios/icon/icon-60.png
new file mode 100644
index 0000000..11f3912
Binary files /dev/null and b/app/resources/ios/icon/icon-60.png differ
diff --git a/app/resources/ios/icon/icon-60@2x.png b/app/resources/ios/icon/icon-60@2x.png
new file mode 100644
index 0000000..b521048
Binary files /dev/null and b/app/resources/ios/icon/icon-60@2x.png differ
diff --git a/app/resources/ios/icon/icon-60@3x.png b/app/resources/ios/icon/icon-60@3x.png
new file mode 100644
index 0000000..dbc8303
Binary files /dev/null and b/app/resources/ios/icon/icon-60@3x.png differ
diff --git a/app/resources/ios/icon/icon-72.png b/app/resources/ios/icon/icon-72.png
new file mode 100644
index 0000000..4e5a827
Binary files /dev/null and b/app/resources/ios/icon/icon-72.png differ
diff --git a/app/resources/ios/icon/icon-72@2x.png b/app/resources/ios/icon/icon-72@2x.png
new file mode 100644
index 0000000..56fb29e
Binary files /dev/null and b/app/resources/ios/icon/icon-72@2x.png differ
diff --git a/app/resources/ios/icon/icon-76.png b/app/resources/ios/icon/icon-76.png
new file mode 100644
index 0000000..e66a90e
Binary files /dev/null and b/app/resources/ios/icon/icon-76.png differ
diff --git a/app/resources/ios/icon/icon-76@2x.png b/app/resources/ios/icon/icon-76@2x.png
new file mode 100644
index 0000000..3f5c942
Binary files /dev/null and b/app/resources/ios/icon/icon-76@2x.png differ
diff --git a/app/resources/ios/icon/icon-small.png b/app/resources/ios/icon/icon-small.png
new file mode 100644
index 0000000..de3146d
Binary files /dev/null and b/app/resources/ios/icon/icon-small.png differ
diff --git a/app/resources/ios/icon/icon-small@2x.png b/app/resources/ios/icon/icon-small@2x.png
new file mode 100644
index 0000000..916a02e
Binary files /dev/null and b/app/resources/ios/icon/icon-small@2x.png differ
diff --git a/app/resources/ios/icon/icon-small@3x.png b/app/resources/ios/icon/icon-small@3x.png
new file mode 100644
index 0000000..0efa99d
Binary files /dev/null and b/app/resources/ios/icon/icon-small@3x.png differ
diff --git a/app/resources/ios/icon/icon.png b/app/resources/ios/icon/icon.png
new file mode 100644
index 0000000..89f8c00
Binary files /dev/null and b/app/resources/ios/icon/icon.png differ
diff --git a/app/resources/ios/icon/icon@2x.png b/app/resources/ios/icon/icon@2x.png
new file mode 100644
index 0000000..a6687a1
Binary files /dev/null and b/app/resources/ios/icon/icon@2x.png differ
diff --git a/app/resources/ios/splash/Default-568h@2x~iphone.png b/app/resources/ios/splash/Default-568h@2x~iphone.png
new file mode 100644
index 0000000..d2128a6
Binary files /dev/null and b/app/resources/ios/splash/Default-568h@2x~iphone.png differ
diff --git a/app/resources/ios/splash/Default-667h.png b/app/resources/ios/splash/Default-667h.png
new file mode 100644
index 0000000..fc23e64
Binary files /dev/null and b/app/resources/ios/splash/Default-667h.png differ
diff --git a/app/resources/ios/splash/Default-736h.png b/app/resources/ios/splash/Default-736h.png
new file mode 100644
index 0000000..71b16ca
Binary files /dev/null and b/app/resources/ios/splash/Default-736h.png differ
diff --git a/app/resources/ios/splash/Default-Landscape-736h.png b/app/resources/ios/splash/Default-Landscape-736h.png
new file mode 100644
index 0000000..aaff74a
Binary files /dev/null and b/app/resources/ios/splash/Default-Landscape-736h.png differ
diff --git a/app/resources/ios/splash/Default-Landscape@2x~ipad.png b/app/resources/ios/splash/Default-Landscape@2x~ipad.png
new file mode 100644
index 0000000..19770a2
Binary files /dev/null and b/app/resources/ios/splash/Default-Landscape@2x~ipad.png differ
diff --git a/app/resources/ios/splash/Default-Landscape~ipad.png b/app/resources/ios/splash/Default-Landscape~ipad.png
new file mode 100644
index 0000000..6fe8925
Binary files /dev/null and b/app/resources/ios/splash/Default-Landscape~ipad.png differ
diff --git a/app/resources/ios/splash/Default-Portrait@2x~ipad.png b/app/resources/ios/splash/Default-Portrait@2x~ipad.png
new file mode 100644
index 0000000..3d06d86
Binary files /dev/null and b/app/resources/ios/splash/Default-Portrait@2x~ipad.png differ
diff --git a/app/resources/ios/splash/Default-Portrait~ipad.png b/app/resources/ios/splash/Default-Portrait~ipad.png
new file mode 100644
index 0000000..53ad4c4
Binary files /dev/null and b/app/resources/ios/splash/Default-Portrait~ipad.png differ
diff --git a/app/resources/ios/splash/Default@2x~iphone.png b/app/resources/ios/splash/Default@2x~iphone.png
new file mode 100644
index 0000000..6a13316
Binary files /dev/null and b/app/resources/ios/splash/Default@2x~iphone.png differ
diff --git a/app/resources/ios/splash/Default~iphone.png b/app/resources/ios/splash/Default~iphone.png
new file mode 100644
index 0000000..0aaad62
Binary files /dev/null and b/app/resources/ios/splash/Default~iphone.png differ
diff --git a/app/resources/splash.png b/app/resources/splash.png
new file mode 100644
index 0000000..cbddba0
Binary files /dev/null and b/app/resources/splash.png differ
diff --git a/app/www/js/controllers.js b/app/www/js/controllers.js
index d9a02ee..2c43a3c 100644
--- a/app/www/js/controllers.js
+++ b/app/www/js/controllers.js
@@ -42,8 +42,8 @@ angular.module('starter.controllers', [])
})
-.controller('TravelsCtrl', function($scope) {
- $scope.travels = [
+.controller('TravelsCtrl', function($scope, $http) {
+ /*$scope.travels = [
{ id: 1, title: 'Travel1', description: "description for travel 1", owner: "user1", icon: "car" },
{ id: 2, title: 'Travel2', description: "description for travel 2", owner: "user2", icon: "station-wagon" },
{ id: 3, title: 'Travel3', description: "description for travel 3", owner: "user3", icon: "van" },
@@ -52,7 +52,20 @@ angular.module('starter.controllers', [])
{ id: 6, title: 'Travel6', description: "description for travel 6", owner: "user3", icon: "lorry" },
{ id: 7, title: 'Travel7', description: "description for travel 7", owner: "user1", icon: "sport-car" },
{ id: 8, title: 'Travel8', description: "description for travel 8", owner: "user2", icon: "jeep" }
- ];
+];*/
+ $scope.travels="";
+ $http.get('http://localhost:3000/api/travels')
+ .success(function(data, status, headers,config){
+ console.log('data success');
+ console.log(data); // for browser console
+ $scope.travels = data; // for UI
+ })
+ .error(function(data, status, headers,config){
+ console.log('data error');
+ })
+ .then(function(result){
+ travels = result.data;
+ });
})
.controller('TravelCtrl', function($scope, $stateParams) {
//$scope.travel=travels.get($stateParams.travelId);
diff --git a/app/www/templates/menu.html b/app/www/templates/menu.html
index 4e10856..1972f03 100644
--- a/app/www/templates/menu.html
+++ b/app/www/templates/menu.html
@@ -24,6 +24,9 @@
Travels
+
+ Transport material
+
Available cars
diff --git a/server/controllers/travelController.js b/server/controllers/travelController.js
index 882e102..26f6223 100644
--- a/server/controllers/travelController.js
+++ b/server/controllers/travelController.js
@@ -58,7 +58,8 @@ exports.addTravel = function(req, res) {
to: req.body.to,
date: req.body.date,
generateddate: req.body.generateddate,
- seats: req.body.seats
+ seats: req.body.seats,
+ icon: req.body.icon
});
travel.save(function(err, travel) {
diff --git a/server/models/travelModel.js b/server/models/travelModel.js
index 96fa635..b234dad 100644
--- a/server/models/travelModel.js
+++ b/server/models/travelModel.js
@@ -10,6 +10,7 @@ var travelSchema = new Schema({
to: { type: String },
date: { type: Date },
generateddate: { type: Date },
- seats: { type: Number }
+ seats: { type: Number },
+ icon: { type: String }
})
module.exports = mongoose.model('travelModel', travelSchema);