diff --git a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js
index 71444c4..0f8ea8f 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js
@@ -1290,7 +1290,8 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter,
}
$scope.reportCopyStatus = false;
$scope.SendLabEXMailToUser = function (User) {
- console.log(User);
+
+
// html2canvas($("#submitResultHtml"), {
// onrendered: function (canvas) {
// var dataURL = canvas.toDataURL("image/jpeg");
@@ -1316,10 +1317,12 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter,
htm += '';
$scope.reportImage = "
"+$("#submitResultHtml .panel-heading .row div:nth-child(1)").text()+" | Performance Report | " + $("#submitResultHtml .panel-heading .row div:nth-child(3)").text() + " |
Total Question | Correct Answers | Incorrect Answers | " + $("#questionStatus tbody tr td:nth-child(1)").text() + " | " + $("#questionStatus tbody tr td:nth-child(2)").text() + " | " + $("#questionStatus tbody tr td:nth-child(3)").text() + " |
" + htm + "";
$scope.reportTitle = "Lab Exercise Report for " + $("#submitResultHtml .panel-heading .row div:nth-child(1)").text();
- // }
+ $scope.senderEmails = $("#emailTo").val();
+
+ // }
// });
- LabExerciseService.LabExerciseReport(User, $scope.reportImage, $scope.reportTitle, $scope.reportCopyStatus).then(
+ LabExerciseService.LabExerciseReport(User, $scope.reportImage, $scope.reportTitle, $scope.reportCopyStatus, $scope.senderEmails).then(
function (result) {
console.log(result);
diff --git a/400-SOURCECODE/AIAHTML5.Web/app/services/LabExerciseService.js b/400-SOURCECODE/AIAHTML5.Web/app/services/LabExerciseService.js
index 03ea8da..32bc076 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/services/LabExerciseService.js
+++ b/400-SOURCECODE/AIAHTML5.Web/app/services/LabExerciseService.js
@@ -51,10 +51,11 @@
},
// code of email report
- LabExerciseReport: function (User, reportImage, reportTitle, reportCopyStatus) {
+ LabExerciseReport: function (User, reportImage, reportTitle, reportCopyStatus, senderEmail) {
User.reportImage = reportImage;
User.reportTitle = reportTitle;
User.ReportCheck = reportCopyStatus;
+ User.EmailTo = senderEmail;
var deferred = $q.defer();
// var jsonData = { 'EmailTo': User.EmailTo, 'EmailAdd': User.EmailAdd };
$http.post('http://192.168.90.19:91/API/api/LabExercise/SendEmail', JSON.stringify(User), {
@@ -66,11 +67,11 @@
})
.success(function (data, status, headers, config) {
- debugger;
+
console.log('success')
deferred.resolve(data);
}).error(function (data, status, headers, config) {
- debugger;
+
console.log('error')
deferred.reject(data);
});
diff --git a/400-SOURCECODE/AIAHTML5.Web/app/views/LabExerc/lab-exercises-detail.html b/400-SOURCECODE/AIAHTML5.Web/app/views/LabExerc/lab-exercises-detail.html
index a921b46..2106c46 100644
--- a/400-SOURCECODE/AIAHTML5.Web/app/views/LabExerc/lab-exercises-detail.html
+++ b/400-SOURCECODE/AIAHTML5.Web/app/views/LabExerc/lab-exercises-detail.html
@@ -30,24 +30,26 @@
@@ -69,7 +73,7 @@
-
+