Commit 752c72e9a73bf9be32cf65bf1b32d8c7d4bb451d
Merge branch 'UserModulesOrder-2' into Develop
Showing
5 changed files
with
96 additions
and
93 deletions
150-DOCUMENTATION/Testing Data/UserDetails.xlsx
0 → 100644
No preview for this file type
400-SOURCECODE/AIAHTML5.API/Models/DBModel.cs
@@ -67,6 +67,7 @@ namespace AIAHTML5.API.Models | @@ -67,6 +67,7 @@ namespace AIAHTML5.API.Models | ||
67 | foreach (DataRow drModule in dt.Rows) | 67 | foreach (DataRow drModule in dt.Rows) |
68 | { | 68 | { |
69 | userModuleHash = new Hashtable(); | 69 | userModuleHash = new Hashtable(); |
70 | + userModuleHash.Add(AIAConstants.KEY_ID, drModule["Id"]); | ||
70 | userModuleHash.Add(AIAConstants.KEY_NAME, drModule["Name"]); | 71 | userModuleHash.Add(AIAConstants.KEY_NAME, drModule["Name"]); |
71 | userModuleHash.Add(AIAConstants.KEY_SLUG, drModule["Slug"]); | 72 | userModuleHash.Add(AIAConstants.KEY_SLUG, drModule["Slug"]); |
72 | arrUserModules.Add(userModuleHash); | 73 | arrUserModules.Add(userModuleHash); |
@@ -207,6 +208,7 @@ namespace AIAHTML5.API.Models | @@ -207,6 +208,7 @@ namespace AIAHTML5.API.Models | ||
207 | foreach (DataRow dr in dt.Rows) | 208 | foreach (DataRow dr in dt.Rows) |
208 | { | 209 | { |
209 | modulesHash = new Hashtable(); | 210 | modulesHash = new Hashtable(); |
211 | + modulesHash.Add(AIAConstants.KEY_ID, dr["Id"]); | ||
210 | modulesHash.Add(AIAConstants.KEY_NAME, dr["Title"]); | 212 | modulesHash.Add(AIAConstants.KEY_NAME, dr["Title"]); |
211 | modulesHash.Add(AIAConstants.KEY_SLUG, dr["Slug"]); | 213 | modulesHash.Add(AIAConstants.KEY_SLUG, dr["Slug"]); |
212 | userModulelist.Add(modulesHash); | 214 | userModulelist.Add(modulesHash); |
400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -272,16 +272,17 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic | @@ -272,16 +272,17 @@ function ($rootScope, Modules, $log, $location, $timeout, DataService, Authentic | ||
272 | 272 | ||
273 | function ShowAssignedModulesPopup(userModules) { | 273 | function ShowAssignedModulesPopup(userModules) { |
274 | var allModules = Modules; | 274 | var allModules = Modules; |
275 | - var elemId = 0; | ||
276 | - for (var module = 0; module <= allModules.length; module++) { | ||
277 | - elemId = module + 1; // Id starts from 1 | ||
278 | - $('#moduleDiv' + elemId).hide(); | 275 | + for (var module = 1; module <= allModules.length; module++) { |
276 | + $('#moduleDiv' + module).hide(); | ||
279 | } | 277 | } |
278 | + if (('#moduleDiv1017').length > 0) { | ||
279 | + $('#moduleDiv1017').hide(); | ||
280 | + } | ||
281 | + | ||
280 | for (var count = 0; count < userModules.length; count++) { | 282 | for (var count = 0; count < userModules.length; count++) { |
281 | for (var module = 0; module < allModules.length; module++) { | 283 | for (var module = 0; module < allModules.length; module++) { |
282 | - if (userModules[count].name.trim() == allModules[module].Name.trim()) { | ||
283 | - elemId = count + 1; // Id starts from 1 | ||
284 | - $('#moduleDiv' + elemId).show(); | 284 | + if (userModules[count].id == allModules[module].Id) { |
285 | + $('#moduleDiv' + userModules[count].id).show(); | ||
285 | break; | 286 | break; |
286 | } | 287 | } |
287 | } | 288 | } |
400-SOURCECODE/AIAHTML5.Web/app/main/AIA.js
@@ -204,7 +204,7 @@ AIA.constant('DA', [ | @@ -204,7 +204,7 @@ AIA.constant('DA', [ | ||
204 | }, | 204 | }, |
205 | ]); | 205 | ]); |
206 | 206 | ||
207 | - | 207 | +// These constants are same as in Database table ResourceModule, we have to maintain the module order and module id mention in the same order |
208 | AIA.constant('Modules', [ | 208 | AIA.constant('Modules', [ |
209 | { | 209 | { |
210 | Id: 1, | 210 | Id: 1, |
@@ -226,56 +226,56 @@ AIA.constant('Modules', [ | @@ -226,56 +226,56 @@ AIA.constant('Modules', [ | ||
226 | Id: 5, | 226 | Id: 5, |
227 | Name: 'Clinical Animations', | 227 | Name: 'Clinical Animations', |
228 | }, | 228 | }, |
229 | - { | ||
230 | - Id: 6, | ||
231 | - Name: 'Curriculum Builder', | ||
232 | - }, | 229 | + { |
230 | + Id: 6, | ||
231 | + Name: 'Encyclopedia', | ||
232 | + | ||
233 | + }, | ||
233 | { | 234 | { |
234 | Id: 7, | 235 | Id: 7, |
235 | - Name: 'Anatomy Test', | 236 | + Name: 'Curriculum Builder', |
236 | }, | 237 | }, |
237 | { | 238 | { |
238 | Id: 8, | 239 | Id: 8, |
239 | - Name: 'Lab Exercises', | ||
240 | - }, | ||
241 | - { | ||
242 | - Id: 9, | ||
243 | - Name: 'A.D.A.M. Images', | 240 | + Name: 'Anatomy Test', |
244 | }, | 241 | }, |
242 | + { | ||
243 | + Id: 9, | ||
244 | + Name: 'IP 10', | ||
245 | + }, | ||
245 | { | 246 | { |
246 | Id: 10, | 247 | Id: 10, |
247 | - Name: 'A.D.A.M. OnDemand', | ||
248 | - }, | ||
249 | - { | ||
250 | - Id: 11, | ||
251 | - Name: 'Encyclopedia', | ||
252 | - | 248 | + Name: 'Lab Exercises', |
253 | }, | 249 | }, |
250 | + { | ||
251 | + Id: 11, | ||
252 | + Name: 'In-Depth Reports', | ||
253 | + }, | ||
254 | { | 254 | { |
255 | Id: 12, | 255 | Id: 12, |
256 | - Name: 'IP 10', | 256 | + Name: 'CAM', //Complementary and Alternative Medicine' |
257 | }, | 257 | }, |
258 | - | ||
259 | { | 258 | { |
260 | Id: 13, | 259 | Id: 13, |
261 | - Name: 'In-Depth Reports', | ||
262 | - }, | ||
263 | - { | ||
264 | - Id: 14, | ||
265 | - Name: 'CAM', //Complementary and Alternative Medicine' | 260 | + Name: 'A.D.A.M. Images', |
266 | }, | 261 | }, |
262 | + { | ||
263 | + Id: 14, | ||
264 | + Name: 'Body Guide', | ||
265 | + }, | ||
267 | { | 266 | { |
268 | Id: 15, | 267 | Id: 15, |
269 | - Name: 'Body Guide', | 268 | + Name: 'Symptom Navigator', //Health Navigator', |
270 | }, | 269 | }, |
271 | { | 270 | { |
272 | Id: 16, | 271 | Id: 16, |
273 | - Name: 'Symptom Navigator', //Health Navigator', | 272 | + Name: 'The Wellness Tools', |
274 | }, | 273 | }, |
275 | { | 274 | { |
276 | - Id: 17, | ||
277 | - Name: 'The Wellness Tools', | 275 | + Id: 1017, // Updated from 17 to 1017 to match with database Id |
276 | + Name: 'A.D.A.M. OnDemand', | ||
278 | }, | 277 | }, |
278 | + | ||
279 | 279 | ||
280 | ]); | 280 | ]); |
281 | AIA.constant('BodyViewws', [ | 281 | AIA.constant('BodyViewws', [ |
@@ -308,59 +308,59 @@ AIA.constant("LoginConstants", { | @@ -308,59 +308,59 @@ AIA.constant("LoginConstants", { | ||
308 | "MAIL_SENT": "Mail sent.", | 308 | "MAIL_SENT": "Mail sent.", |
309 | "SQL_CONNECTION_ERROR": "We are unable to connect with database. Please contact customer support", | 309 | "SQL_CONNECTION_ERROR": "We are unable to connect with database. Please contact customer support", |
310 | "EXCEPTION_OCCURED": "We are facing some issue. Please try to login after sometime.", | 310 | "EXCEPTION_OCCURED": "We are facing some issue. Please try to login after sometime.", |
311 | - "E_NO_ERROR": "0", | ||
312 | - "E_USER_NOT_EXIST": "1", | ||
313 | - "E_PASSWORD_NOT_MATCH": "2", | ||
314 | - "E_USER_ID_BLOCKED_24_HRS": "3", | ||
315 | - "E_USER_NOT_ACTIVE": "4", | ||
316 | - "E_USER_ID_WILL_BLOCKED": "5", | ||
317 | - "E_EMAIL_ID_NOT_EXIT": "6", | ||
318 | - "E_LICENCE_IS_INACTIVE": "7", | ||
319 | - "E_USER_NOT_MAP_TO_LICENCE_EDITION": "8", | ||
320 | - "E_NO_ROW_FOUND_LICENCE_TO_EDITION_TABLE": "9", | ||
321 | - "E_NO_ROW_FOUND_LICENCE_TABLE": "10", | ||
322 | - "E_SECURITY_QUEST_NOT_MATCH": "11", | ||
323 | - "E_SEQURITY_ANSWER_NOT_MATCH": "12", | ||
324 | - "E_FORGOT_USER_ID_EMAIL_ID_NOT_EXIT": "13", | ||
325 | - "E_TOTAL_NUMBER_LOGIN_EXCEED": "14", | ||
326 | - "E_FORGOT_PASSWORD_EMAIL_ID_NOT_EXIST": "15", | ||
327 | - "E_TEST_SETUP_ACCOUNT_USER_NAME_EXIST": "16", | ||
328 | - "E_TEST_SETUP_ACCOUNT_EMAILID_EXIST": "17", | ||
329 | - "E_SP_ERROR": "18", | ||
330 | - "E_ACCOUNT_NUMBER_NOT_EXIST": "19", | ||
331 | - "E_ACCOUNT_NUMBER_ALREADY_EXIST": "20", | ||
332 | - "E_TEST_ACCOUNT_CREATED_MAIL_COULD_NOT_SENT": "21", | ||
333 | - "E_MAIL_COULD_NOT_SENT": "22", | ||
334 | - "E_RESELLER_ACCOUNT_CREATED_MAIL_COULD_NOT_SENT": "23", | ||
335 | - "E_LICENSE_TERM_CONDITION": "24", | ||
336 | - "E_EDITION_NOT_LINKED_WITH_SITE": "25", | ||
337 | - "E_LOGIN_SESSION_EXPIRE": "26", | ||
338 | - "E_DISCOUNT_CODE_NOT_EXIST": "27", | ||
339 | - "E_DISCOUNT_CODE_ALREADY_EXIST": "28", | ||
340 | - | ||
341 | - "E_SITE_IP_NOT_NULL": "29", | ||
342 | - "E_EDITION_ID_NOT_NULL": "30", | ||
343 | - "E_MASTER_SITEIP_NOT_EXIST": "31", | ||
344 | - "EDITION_ID_NOT_EXIST": "32", | ||
345 | - "E_ERROR_LOG": "33", | ||
346 | - "E_MASTER_SITE_ALREADY_EXIST": "34", | ||
347 | - "E_ACCOUNT_NUMBER_NOT_NULL": "35", | ||
348 | - "E_SITE_IP_ALREADY_EXIST": "36", | ||
349 | - | ||
350 | - | ||
351 | - "E_LICENCE_IS_EXPIRED": "37", | ||
352 | - "E_SINGLEACCOUNT_IS_BEING_USED": "38", | ||
353 | - | ||
354 | - | ||
355 | - "E_DATA_BASE_CONNECTION": "4060", | ||
356 | - | ||
357 | - | ||
358 | - //login failure error constant | ||
359 | - "ACCOUNT_NUMBER_NOT_NULL": "4", | ||
360 | - "EDITION_ID_NOT_NULL": "5", | ||
361 | - "ACCOUNT_NUMBER_NOT_EXIST": "1", | ||
362 | - "EDITION_NOT_EXIST": "3", | ||
363 | - "MASTER_SITEIP_NOT_EXIST": "2", | 311 | + "E_NO_ERROR": "0", |
312 | + "E_USER_NOT_EXIST": "1", | ||
313 | + "E_PASSWORD_NOT_MATCH": "2", | ||
314 | + "E_USER_ID_BLOCKED_24_HRS": "3", | ||
315 | + "E_USER_NOT_ACTIVE": "4", | ||
316 | + "E_USER_ID_WILL_BLOCKED": "5", | ||
317 | + "E_EMAIL_ID_NOT_EXIT": "6", | ||
318 | + "E_LICENCE_IS_INACTIVE": "7", | ||
319 | + "E_USER_NOT_MAP_TO_LICENCE_EDITION": "8", | ||
320 | + "E_NO_ROW_FOUND_LICENCE_TO_EDITION_TABLE": "9", | ||
321 | + "E_NO_ROW_FOUND_LICENCE_TABLE": "10", | ||
322 | + "E_SECURITY_QUEST_NOT_MATCH": "11", | ||
323 | + "E_SEQURITY_ANSWER_NOT_MATCH": "12", | ||
324 | + "E_FORGOT_USER_ID_EMAIL_ID_NOT_EXIT": "13", | ||
325 | + "E_TOTAL_NUMBER_LOGIN_EXCEED": "14", | ||
326 | + "E_FORGOT_PASSWORD_EMAIL_ID_NOT_EXIST": "15", | ||
327 | + "E_TEST_SETUP_ACCOUNT_USER_NAME_EXIST": "16", | ||
328 | + "E_TEST_SETUP_ACCOUNT_EMAILID_EXIST": "17", | ||
329 | + "E_SP_ERROR": "18", | ||
330 | + "E_ACCOUNT_NUMBER_NOT_EXIST": "19", | ||
331 | + "E_ACCOUNT_NUMBER_ALREADY_EXIST": "20", | ||
332 | + "E_TEST_ACCOUNT_CREATED_MAIL_COULD_NOT_SENT": "21", | ||
333 | + "E_MAIL_COULD_NOT_SENT": "22", | ||
334 | + "E_RESELLER_ACCOUNT_CREATED_MAIL_COULD_NOT_SENT": "23", | ||
335 | + "E_LICENSE_TERM_CONDITION": "24", | ||
336 | + "E_EDITION_NOT_LINKED_WITH_SITE": "25", | ||
337 | + "E_LOGIN_SESSION_EXPIRE": "26", | ||
338 | + "E_DISCOUNT_CODE_NOT_EXIST": "27", | ||
339 | + "E_DISCOUNT_CODE_ALREADY_EXIST": "28", | ||
340 | + | ||
341 | + "E_SITE_IP_NOT_NULL": "29", | ||
342 | + "E_EDITION_ID_NOT_NULL": "30", | ||
343 | + "E_MASTER_SITEIP_NOT_EXIST": "31", | ||
344 | + "EDITION_ID_NOT_EXIST": "32", | ||
345 | + "E_ERROR_LOG": "33", | ||
346 | + "E_MASTER_SITE_ALREADY_EXIST": "34", | ||
347 | + "E_ACCOUNT_NUMBER_NOT_NULL": "35", | ||
348 | + "E_SITE_IP_ALREADY_EXIST": "36", | ||
349 | + | ||
350 | + | ||
351 | + "E_LICENCE_IS_EXPIRED": "37", | ||
352 | + "E_SINGLEACCOUNT_IS_BEING_USED": "38", | ||
353 | + | ||
354 | + | ||
355 | + "E_DATA_BASE_CONNECTION": "4060", | ||
356 | + | ||
357 | + | ||
358 | + //login failure error constant | ||
359 | + "ACCOUNT_NUMBER_NOT_NULL": "4", | ||
360 | + "EDITION_ID_NOT_NULL": "5", | ||
361 | + "ACCOUNT_NUMBER_NOT_EXIST": "1", | ||
362 | + "EDITION_NOT_EXIST": "3", | ||
363 | + "MASTER_SITEIP_NOT_EXIST": "2", | ||
364 | "LICENSE_INACTIVE": "6" | 364 | "LICENSE_INACTIVE": "6" |
365 | }); | 365 | }); |
366 | 366 |
400-SOURCECODE/AIAHTML5.Web/index.html
@@ -1254,10 +1254,10 @@ | @@ -1254,10 +1254,10 @@ | ||
1254 | <div class="col-sm-8">• 3D Anatomy</div> | 1254 | <div class="col-sm-8">• 3D Anatomy</div> |
1255 | </div> | 1255 | </div> |
1256 | <div class="form-group" id="moduleDiv4"> | 1256 | <div class="form-group" id="moduleDiv4"> |
1257 | - <div class="col-sm-8">• Clinical Illustration</div> | 1257 | + <div class="col-sm-8">• Clinical Illustrations</div> |
1258 | </div> | 1258 | </div> |
1259 | <div class="form-group" id="moduleDiv5"> | 1259 | <div class="form-group" id="moduleDiv5"> |
1260 | - <div class="col-sm-8">• Clinical Animation</div> | 1260 | + <div class="col-sm-8">• Clinical Animations</div> |
1261 | </div> | 1261 | </div> |
1262 | <div class="form-group" id="moduleDiv6"> | 1262 | <div class="form-group" id="moduleDiv6"> |
1263 | <div class="col-sm-8">• Encyclopedia</div> | 1263 | <div class="col-sm-8">• Encyclopedia</div> |
@@ -1272,7 +1272,7 @@ | @@ -1272,7 +1272,7 @@ | ||
1272 | <div class="col-sm-8">• IP 10</div> | 1272 | <div class="col-sm-8">• IP 10</div> |
1273 | </div> | 1273 | </div> |
1274 | <div class="form-group" id="moduleDiv10"> | 1274 | <div class="form-group" id="moduleDiv10"> |
1275 | - <div class="col-sm-8"><i>• Lab Exercise (To be available by 08/16/2017)</i></div> | 1275 | + <div class="col-sm-8"><i>• Lab Exercises (To be available by 08/16/2017)</i></div> |
1276 | </div> | 1276 | </div> |
1277 | <div class="form-group" id="moduleDiv11"> | 1277 | <div class="form-group" id="moduleDiv11"> |
1278 | <div class="col-sm-8">• In - Depth Reports</div> | 1278 | <div class="col-sm-8">• In - Depth Reports</div> |
@@ -1290,9 +1290,9 @@ | @@ -1290,9 +1290,9 @@ | ||
1290 | <div class="col-sm-8">• Symptom Navigator</div> <!--Health--> | 1290 | <div class="col-sm-8">• Symptom Navigator</div> <!--Health--> |
1291 | </div> | 1291 | </div> |
1292 | <div class="form-group" id="moduleDiv16"> | 1292 | <div class="form-group" id="moduleDiv16"> |
1293 | - <div class="col-sm-8">• The Wellness Tool</div> | 1293 | + <div class="col-sm-8">• The Wellness Tools</div> |
1294 | </div> | 1294 | </div> |
1295 | - <div class="form-group" id="moduleDiv17"> | 1295 | + <div class="form-group" id="moduleDiv1017"> |
1296 | <div class="col-sm-8">• A.D.A.M on Demand</div> | 1296 | <div class="col-sm-8">• A.D.A.M on Demand</div> |
1297 | </div> | 1297 | </div> |
1298 | <div class="form-group"> | 1298 | <div class="form-group"> |