-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcontrollerPost.js
More file actions
32 lines (29 loc) · 813 Bytes
/
controllerPost.js
File metadata and controls
32 lines (29 loc) · 813 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
function Controller($scope,$http){
$scope.sede = "CUETZALAN";
$scope.postData = function(data2){
//console.log(data);
/* for(i in data)
console.log(i + '->' + data[i]);
return;
*/
console.log(data2.area);
$http.post('http://127.0.0.1:55556/?action=postData', data2)
.success(function (data) {
console.log(data);
}).error(function (data,status, headers,config){
console.log(status) ;
console.log(data) ;
console.log(headers) ;
});
}
/*
saveArea = function(){
$scope.data2.area = $scope.data2.data2.SARADAP_PROGRAM_1;
console.log($scope.data2.area);
}
$scope.check = function(){
console.log($scope.data2.area);
$scope.watch('data2.SARADAP_PROGRAM_1',saveArea);
}
*/
}