hi i am trying to insert a row in mi table but always obtain this problem:
POST URL/api/presentaciones/[object%20Object] 404 (Not Found)
Well I have a form and the ng-submit="savePresentacion" inthe controller:
.controller('newPresentacionController', function ($scope, Presentacion, Categoria) {
$scope.categorias ={};
var vm = this;
var presentacionData = {};
$scope.savePresentacion = function() {
presentacionData = {
nombre : $scope.nombre,
descripcion : $scope.descripcion,
tipo_presentacion : $scope.tipo_presentacion,
usuarios_id : $scope.usuarios_id,
categorias_id: $scope.categorias_id,
longitude: self.myMarker.position.lng(),
latitud: self.myMarker.position.lat(),
zoom: 13
};
Presentacion.crearPresentacion(presentacionData).success(function (datos) {
});
};
}
in the presentacionService have this:
(function () {
angular.module('presentacionService', [])
.factory('Presentacion', function ($http) {
var presentacionFactory = {};
presentacionFactory.crearPresentacion = function(presenData) {
console.log(presenData);
return $http.post('/api/presentaciones/' + presenData);
};
return presentacionFactory;
});
})();
after of this give the problem. I did the same with 2 tables more and dont have problem just have problem with this part.