| 12345678910111213141516171819202122232425262728293031323334 |
- app.controller('uploadCtrl', function ($scope, $http,video,notify) {
- $scope.profesor="";
- $scope.texto1="";
- $scope.texto2="";
- $scope.video = video;
- $scope.profesores = [];
- function getProf(){
- $http.get("https://plataforma.especificosba.com.ar/back/getAllProfesores.php?auth_token=4b494d6c7ffc74d387d8cfdef8ca1691").then(
- function(data){
- $scope.profesores = data.data;
- },
- function(data){
- });
- }
- getProf();
- $scope.post = function() {
- var postdata = {
- prof: $scope.profesor,
- texto1: $scope.texto1,
- texto2: $scope.texto2,
- id: $scope.video._id,
- diapos: []
- };
- $http.post('/back/upload/', postdata).success(function(data,state) {
- notify({message:data.status,classes:"alert"});
- }).error(function(data) {
- notify({message:data.status,classes:"alert alert-danger"});
- });
- };
- });
|