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 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
| app.controller('ExoController', function () {
this.exercices = [];
this.init = function (idUser) {
this.exercices = _exercices;
/*jquery.ajax({
type: "GET",
url: "http://localhost:50922/Service.svc/getLstExercice",
contentType: "application/json",
data: "{\"idUser\" :\"" + idUser + "\"}",
dataType: "json",
success: function (result) {
alert('ok getListExercice');
//this.exercices = result;
},
error: function (textStatus) {
alert(textStatus + ' ' + result.status + ' | ' + result.statusText);
}
});*/
};
});
var _exercices = [
{
Series: [
{
"shortDate": "",
"idSerie": 1,
"idExercice": 14,
"nbRepet": 12,
"poids": 5,
"distance": 10.0,
"duree": "2015-08-07T00:15:00",
"dateInsert": "2015-08-08T00:00:00",
"DifferenceObjectif": null
}
],
IdExercice: 14,
Nom: "test1",
nbSeries: 1,
minOrRepet: 1,
idUser: 2,
Description: "deta",
ObjectifSerie: null
},
{
Series: [
{ "shortDate": "", "idSerie": 1, "idExercice": 14, "nbRepet": 12, "poids": 5, "distance": 10.0, "duree": "2015-08-07T00:15:00", "dateInsert": "2015-08-08T00:00:00", "DifferenceObjectif": null }
],
IdExercice: 14,
Nom: "test2",
nbSeries: 1,
minOrRepet: 1,
idUser: 2,
Description: "deta2",
ObjectifSerie: null
}] |
Partager