Commit c7b2c934bf6bc6d710ee3a40cc1b18437acaa43c

Authored by unknown
1 parent e030dd5f

Implemented three condition in email sending

400-SOURCECODE/AIAHTML5.Web/app/controllers/LabExercController.js
... ... @@ -1372,7 +1372,7 @@ function ($scope, $rootScope, pages, log, $http, $timeout, DataService, $filter,
1372 1372 // for closing email popup
1373 1373 $rootScope.closeLabExEmailModel();
1374 1374  
1375   - document.getElementById('labExEmailSentModalID').style.display = "block";
  1375 + //document.getElementById('labExEmailSentModalID').style.display = "block";
1376 1376 document.getElementById('labExModalbackground').style.display = "block";
1377 1377 }
1378 1378 $rootScope.closeLabExEmailModel = function () {
... ...
400-SOURCECODE/AIAHTML5.Web/app/services/LabExerciseService.js
... ... @@ -68,11 +68,22 @@
68 68  
69 69 .success(function (data, status, headers, config) {
70 70  
71   - console.log('success')
  71 + console.log('success');
  72 +
  73 + document.getElementById('notificationTitle').innerText = "Email Your Performance Report";
  74 + if (reportCopyStatus == true) {
  75 + document.getElementById('notificationMessage').innerText = "Your report has been sent. A copy has been emailed to you for your records.";
  76 + }
  77 + else {
  78 + document.getElementById('notificationMessage').innerText = "Your report has been sent.";
  79 + }
  80 + document.getElementById('labExEmailSentModalID').style.display = "block";
72 81 deferred.resolve(data);
73 82 }).error(function (data, status, headers, config) {
74   -
75   - console.log('error')
  83 + console.log('error');
  84 + document.getElementById('notificationTitle').innerText = "Alert";
  85 + document.getElementById('notificationMessage').innerText = "Invalid email Id";
  86 + document.getElementById('labExEmailSentModalID').style.display = "block";
76 87 deferred.reject(data);
77 88 });
78 89 return deferred.promise;
... ...
400-SOURCECODE/AIAHTML5.Web/app/views/LabExerc/lab-exercises-detail.html
... ... @@ -132,11 +132,11 @@
132 132 <div class="modal-content">
133 133 <div class="modal-header">
134 134  
135   - <h4 class="modal-title" id="myModalLabel">Email Your Performance Report</h4>
  135 + <h4 class="modal-title" id="notificationTitle"></h4>
136 136 </div>
137 137 <div class="modal-body ">
138   - <div class="modal-body" style="padding:10px;font-size:15px;">
139   - Your report has been sent. A copy has been emailed to you for your records.
  138 + <div class="modal-body" id="notificationMessage" style="padding:10px;font-size:15px;">
  139 +
140 140 </div>
141 141 </div>
142 142 <div class="modal-footer">
... ...