Commit 729befc6029266dcb246bef0148a12d7091202ce

Authored by Birendra
2 parents 7ab40d3d c36d7e0f

Merge branch 'AIA_Develop' into AOD_Change

Showing 21 changed files with 295 additions and 188 deletions
400-SOURCECODE/AIAHTML5.ADMIN.API/Controllers/LicenseController.cs
@@ -312,16 +312,18 @@ namespace AIAHTML5.ADMIN.API.Controllers @@ -312,16 +312,18 @@ namespace AIAHTML5.ADMIN.API.Controllers
312 public HttpResponseMessage UpdateLicenseModestySettings(JObject jsonData) 312 public HttpResponseMessage UpdateLicenseModestySettings(JObject jsonData)
313 { 313 {
314 bool Status = false; 314 bool Status = false;
315 - List<Tuple<int, int, bool>> LicenseModestyList = new List<Tuple<int, int, bool>>();  
316 - Tuple<int, int, bool> LicenseModesty; 315 + List<Tuple<int, int, bool,bool>> LicenseModestyList = new List<Tuple<int, int, bool,bool>>();
  316 + Tuple<int, int, bool,bool> LicenseModesty;
317 for (int i = 0; i < jsonData["obj"].Count(); i++) 317 for (int i = 0; i < jsonData["obj"].Count(); i++)
318 { 318 {
319 - LicenseModesty = new Tuple<int, int, bool>( 319 + LicenseModesty = new Tuple<int, int, bool,bool>(
320 ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["licenseEditionId"])).Value<int>(), 320 ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["licenseEditionId"])).Value<int>(),
321 ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["siteId"])).Value<int>(), 321 ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["siteId"])).Value<int>(),
322 - ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["isModesty"])).Value<bool>()); 322 + ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["isModesty"])).Value<bool>(),
  323 + ((Newtonsoft.Json.Linq.JValue)(jsonData["obj"][i]["isSiteUser"])).Value<bool>());
323 LicenseModestyList.Add(LicenseModesty); 324 LicenseModestyList.Add(LicenseModesty);
324 } 325 }
  326 +
325 try 327 try
326 { 328 {
327 Status = LicenseModel.UpdateLicenseModestySettings(dbContext, LicenseModestyList); 329 Status = LicenseModel.UpdateLicenseModestySettings(dbContext, LicenseModestyList);
400-SOURCECODE/AIAHTML5.ADMIN.API/Entity/AIADBEntity.Context.cs
@@ -3528,7 +3528,7 @@ namespace AIAHTML5.ADMIN.API.Entity @@ -3528,7 +3528,7 @@ namespace AIAHTML5.ADMIN.API.Entity
3528 return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction("usp_UpdateLicenseBasicSettings", iLicenseIdParameter, sLicenseeFnameParameter, sLicenseeLnameParameter, sInstitutionNameParameter, sAddress1Parameter, sAddress2Parameter, sCityParameter, sZipParameter, iStateIdParameter, iCountryIdParameter, sPhoneParameter, sEmailIdParameter, status); 3528 return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction("usp_UpdateLicenseBasicSettings", iLicenseIdParameter, sLicenseeFnameParameter, sLicenseeLnameParameter, sInstitutionNameParameter, sAddress1Parameter, sAddress2Parameter, sCityParameter, sZipParameter, iStateIdParameter, iCountryIdParameter, sPhoneParameter, sEmailIdParameter, status);
3529 } 3529 }
3530 3530
3531 - public virtual int usp_UpdateLicenseModestySettings(Nullable<int> licenseEditionId, Nullable<int> siteId, Nullable<bool> isModesty, ObjectParameter status) 3531 + public virtual int usp_UpdateLicenseModestySettings(Nullable<int> licenseEditionId, Nullable<int> siteId, Nullable<bool> isModesty, Nullable<bool> isSiteUser, ObjectParameter status)
3532 { 3532 {
3533 var licenseEditionIdParameter = licenseEditionId.HasValue ? 3533 var licenseEditionIdParameter = licenseEditionId.HasValue ?
3534 new ObjectParameter("LicenseEditionId", licenseEditionId) : 3534 new ObjectParameter("LicenseEditionId", licenseEditionId) :
@@ -3542,7 +3542,11 @@ namespace AIAHTML5.ADMIN.API.Entity @@ -3542,7 +3542,11 @@ namespace AIAHTML5.ADMIN.API.Entity
3542 new ObjectParameter("IsModesty", isModesty) : 3542 new ObjectParameter("IsModesty", isModesty) :
3543 new ObjectParameter("IsModesty", typeof(bool)); 3543 new ObjectParameter("IsModesty", typeof(bool));
3544 3544
3545 - return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction("usp_UpdateLicenseModestySettings", licenseEditionIdParameter, siteIdParameter, isModestyParameter, status); 3545 + var isSiteUserParameter = isSiteUser.HasValue ?
  3546 + new ObjectParameter("isSiteUser", isSiteUser) :
  3547 + new ObjectParameter("isSiteUser", typeof(bool));
  3548 +
  3549 + return ((IObjectContextAdapter)this).ObjectContext.ExecuteFunction("usp_UpdateLicenseModestySettings", licenseEditionIdParameter, siteIdParameter, isModestyParameter, isSiteUserParameter, status);
3546 } 3550 }
3547 3551
3548 public virtual int usp_UpdateLicenseModuleStatus(Nullable<int> licenseId, string moduleStatusText, ObjectParameter status) 3552 public virtual int usp_UpdateLicenseModuleStatus(Nullable<int> licenseId, string moduleStatusText, ObjectParameter status)
400-SOURCECODE/AIAHTML5.ADMIN.API/Entity/AIADBEntity.edmx
@@ -1495,6 +1495,7 @@ @@ -1495,6 +1495,7 @@
1495 <Parameter Name="LicenseEditionId" Type="int" Mode="In" /> 1495 <Parameter Name="LicenseEditionId" Type="int" Mode="In" />
1496 <Parameter Name="SiteId" Type="int" Mode="In" /> 1496 <Parameter Name="SiteId" Type="int" Mode="In" />
1497 <Parameter Name="IsModesty" Type="bit" Mode="In" /> 1497 <Parameter Name="IsModesty" Type="bit" Mode="In" />
  1498 + <Parameter Name="isSiteUser" Type="bit" Mode="In" />
1498 <Parameter Name="Status" Type="bit" Mode="InOut" /> 1499 <Parameter Name="Status" Type="bit" Mode="InOut" />
1499 </Function> 1500 </Function>
1500 <Function Name="usp_UpdateLicenseModuleStatus" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo"> 1501 <Function Name="usp_UpdateLicenseModuleStatus" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
@@ -2572,6 +2573,7 @@ @@ -2572,6 +2573,7 @@
2572 <Parameter Name="LicenseEditionId" Mode="In" Type="Int32" /> 2573 <Parameter Name="LicenseEditionId" Mode="In" Type="Int32" />
2573 <Parameter Name="SiteId" Mode="In" Type="Int32" /> 2574 <Parameter Name="SiteId" Mode="In" Type="Int32" />
2574 <Parameter Name="IsModesty" Mode="In" Type="Boolean" /> 2575 <Parameter Name="IsModesty" Mode="In" Type="Boolean" />
  2576 + <Parameter Name="isSiteUser" Mode="In" Type="Boolean" />
2575 <Parameter Name="Status" Mode="InOut" Type="Boolean" /> 2577 <Parameter Name="Status" Mode="InOut" Type="Boolean" />
2576 </FunctionImport> 2578 </FunctionImport>
2577 <FunctionImport Name="usp_UpdateLicenseModuleStatus"> 2579 <FunctionImport Name="usp_UpdateLicenseModuleStatus">
400-SOURCECODE/AIAHTML5.ADMIN.API/Models/LicenseModel.cs
@@ -395,14 +395,14 @@ namespace AIAHTML5.ADMIN.API.Models @@ -395,14 +395,14 @@ namespace AIAHTML5.ADMIN.API.Models
395 } 395 }
396 } 396 }
397 397
398 - public static bool UpdateLicenseModestySettings(AIADatabaseV5Entities dbContext, List<Tuple<int, int, bool>> LicenseModestyList) 398 + public static bool UpdateLicenseModestySettings(AIADatabaseV5Entities dbContext, List<Tuple<int, int, bool,bool>> LicenseModestyList)
399 { 399 {
400 var spStatus = new System.Data.Objects.ObjectParameter("Status", 0); 400 var spStatus = new System.Data.Objects.ObjectParameter("Status", 0);
401 try 401 try
402 { 402 {
403 foreach (var item in LicenseModestyList) 403 foreach (var item in LicenseModestyList)
404 { 404 {
405 - dbContext.usp_UpdateLicenseModestySettings(item.Item1, item.Item2, item.Item3, spStatus); 405 + dbContext.usp_UpdateLicenseModestySettings(item.Item1, item.Item2, item.Item3, item.Item4, spStatus);
406 if (!(bool)spStatus.Value) break; 406 if (!(bool)spStatus.Value) break;
407 } 407 }
408 return (bool)spStatus.Value; 408 return (bool)spStatus.Value;
400-SOURCECODE/AIAHTML5.API/Controllers/AuthenticateController.cs
@@ -241,11 +241,13 @@ namespace AIAHTML5.API.Controllers @@ -241,11 +241,13 @@ namespace AIAHTML5.API.Controllers
241 { 241 {
242 //based on old .net code(AIA flex), we get modules based on licenseId if licenseid>0. 242 //based on old .net code(AIA flex), we get modules based on licenseId if licenseid>0.
243 //we verified in database that only superadmin has no licenseid so getting all modules for supeadmin 243 //we verified in database that only superadmin has no licenseid so getting all modules for supeadmin
244 - int licenseId, editionId;  
245 - AIAHTML5.API.Models.Users.getLicenseIdForThisUser(userInfo.Id, out licenseId, out editionId); 244 + int licenseId, editionId, LicenseEditionId;
  245 + AIAHTML5.API.Models.Users.getLicenseIdForThisUser(userInfo.Id, out licenseId, out editionId,out LicenseEditionId);
246 246
247 userInfo.LicenseId = licenseId; 247 userInfo.LicenseId = licenseId;
248 userInfo.EditionId = editionId; 248 userInfo.EditionId = editionId;
  249 + userInfo.LicenseEditionId = LicenseEditionId;
  250 + userInfo.isSiteUser = false;
249 251
250 //if (userInfo.UserType == AIAHTML5.API.Models.User.SUPER_ADMIN) 252 //if (userInfo.UserType == AIAHTML5.API.Models.User.SUPER_ADMIN)
251 if (userInfo.LicenseId == 0) 253 if (userInfo.LicenseId == 0)
@@ -271,7 +273,7 @@ namespace AIAHTML5.API.Controllers @@ -271,7 +273,7 @@ namespace AIAHTML5.API.Controllers
271 //get use settings 273 //get use settings
272 string skintone; 274 string skintone;
273 string modesty; 275 string modesty;
274 - User us = AIAHTML5.API.Models.Users.GetUserSelectedSettings(userInfo.Id, out skintone, out modesty); 276 + User us = AIAHTML5.API.Models.Users.GetUserSelectedSettings(userInfo.Id, false, out skintone, out modesty);
275 if (us != null) 277 if (us != null)
276 { 278 {
277 userInfo.userselectedModesty = modesty; 279 userInfo.userselectedModesty = modesty;
@@ -437,9 +439,13 @@ namespace AIAHTML5.API.Controllers @@ -437,9 +439,13 @@ namespace AIAHTML5.API.Controllers
437 settings.userSelectedSkintone = jsonData["skintone"].Value<string>(); 439 settings.userSelectedSkintone = jsonData["skintone"].Value<string>();
438 settings.userSelectedFont = null; 440 settings.userSelectedFont = null;
439 settings.Id= jsonData["userId"].Value<int>(); 441 settings.Id= jsonData["userId"].Value<int>();
  442 + settings.LicenseEditionId = jsonData["LicenseEditionId"].Value<int>();
  443 + settings.isSiteUser = jsonData["isSiteUser"].Value<bool>();
  444 +
440 userLexicon.primaryid= jsonData["primaryid"].Value<string>(); 445 userLexicon.primaryid= jsonData["primaryid"].Value<string>();
441 userLexicon.secondryids = jsonData["secondryids"].Value<string>(); 446 userLexicon.secondryids = jsonData["secondryids"].Value<string>();
442 settings.userLexicon= userLexicon; 447 settings.userLexicon= userLexicon;
  448 +
443 449
444 Status = AIAHTML5.API.Models.Users.SaveUserSelectedSettings(settings); 450 Status = AIAHTML5.API.Models.Users.SaveUserSelectedSettings(settings);
445 if (Status == 1) 451 if (Status == 1)
400-SOURCECODE/AIAHTML5.API/Models/DBModel.cs
@@ -157,6 +157,8 @@ namespace AIAHTML5.API.Models @@ -157,6 +157,8 @@ namespace AIAHTML5.API.Models
157 { 157 {
158 hash.Add(AIAConstants.LICENSE_KEY_ID, ds.Tables[0].Rows[0][0]); 158 hash.Add(AIAConstants.LICENSE_KEY_ID, ds.Tables[0].Rows[0][0]);
159 hash.Add(AIAConstants.EDITION_KEY_ID, ds.Tables[0].Rows[0][1]); 159 hash.Add(AIAConstants.EDITION_KEY_ID, ds.Tables[0].Rows[0][1]);
  160 + // LicenseEditionId use to update modesty in LicenseToEdition table
  161 + hash.Add("LicenseEditionId", ds.Tables[0].Rows[0][2]);
160 } 162 }
161 } 163 }
162 164
@@ -384,7 +386,7 @@ namespace AIAHTML5.API.Models @@ -384,7 +386,7 @@ namespace AIAHTML5.API.Models
384 return status; 386 return status;
385 } 387 }
386 388
387 - internal User GetSelectedSettings(int userId) 389 + internal User GetSelectedSettings(int userId,bool isSiteUser)
388 { 390 {
389 logger.Debug(" Inside GetSelectedSettings for userId = " + userId); 391 logger.Debug(" Inside GetSelectedSettings for userId = " + userId);
390 UserLexicon objlexicon = null; 392 UserLexicon objlexicon = null;
@@ -394,18 +396,16 @@ namespace AIAHTML5.API.Models @@ -394,18 +396,16 @@ namespace AIAHTML5.API.Models
394 SqlConnection conn = new SqlConnection(dbConnectionString); 396 SqlConnection conn = new SqlConnection(dbConnectionString);
395 SqlCommand cmd = new SqlCommand(); 397 SqlCommand cmd = new SqlCommand();
396 SqlDataAdapter adapter; 398 SqlDataAdapter adapter;
397 - SqlParameter param; 399 +
398 DataSet ds = new DataSet(); 400 DataSet ds = new DataSet();
399 401
400 cmd.Connection = conn; 402 cmd.Connection = conn;
401 cmd.CommandText = DBConstants.GET_SETTINGS; 403 cmd.CommandText = DBConstants.GET_SETTINGS;
402 cmd.CommandType = CommandType.StoredProcedure; 404 cmd.CommandType = CommandType.StoredProcedure;
403 405
404 - param = new SqlParameter("@iUserId", userId);  
405 - param.Direction = ParameterDirection.Input;  
406 - param.DbType = DbType.Int32;  
407 - cmd.Parameters.Add(param);  
408 - 406 + cmd.Parameters.AddWithValue("@iUserId", userId);
  407 + cmd.Parameters.AddWithValue("@isSiteUser", isSiteUser);
  408 +
409 adapter = new SqlDataAdapter(cmd); 409 adapter = new SqlDataAdapter(cmd);
410 adapter.Fill(ds); 410 adapter.Fill(ds);
411 411
@@ -784,6 +784,8 @@ namespace AIAHTML5.API.Models @@ -784,6 +784,8 @@ namespace AIAHTML5.API.Models
784 cmd.Parameters.AddWithValue("@ifont","" ); 784 cmd.Parameters.AddWithValue("@ifont","" );
785 cmd.Parameters.AddWithValue("@pLexicon", settings.userLexicon.primaryid); 785 cmd.Parameters.AddWithValue("@pLexicon", settings.userLexicon.primaryid);
786 cmd.Parameters.AddWithValue("@sLexicon", settings.userLexicon.secondryids); 786 cmd.Parameters.AddWithValue("@sLexicon", settings.userLexicon.secondryids);
  787 + cmd.Parameters.AddWithValue("@isSiteUser", settings.isSiteUser);
  788 + cmd.Parameters.AddWithValue("@LicenseEditionId", settings.LicenseEditionId);
787 789
788 790
789 result = cmd.ExecuteNonQuery(); 791 result = cmd.ExecuteNonQuery();
@@ -1249,7 +1251,7 @@ namespace AIAHTML5.API.Models @@ -1249,7 +1251,7 @@ namespace AIAHTML5.API.Models
1249 return dt; 1251 return dt;
1250 } 1252 }
1251 1253
1252 - internal DataTable GetLicenseBySiteId(int siteId) 1254 + internal DataTable GetLicenseBySiteId(int siteId, int editionId)
1253 { 1255 {
1254 logger.Debug(" inside GetLicenseBySiteId for siteId= " + siteId); 1256 logger.Debug(" inside GetLicenseBySiteId for siteId= " + siteId);
1255 1257
@@ -1262,7 +1264,8 @@ namespace AIAHTML5.API.Models @@ -1262,7 +1264,8 @@ namespace AIAHTML5.API.Models
1262 cmd.CommandText = DBConstants.GET_LICENSE_BY_SITE_ID; 1264 cmd.CommandText = DBConstants.GET_LICENSE_BY_SITE_ID;
1263 cmd.CommandType = CommandType.StoredProcedure; 1265 cmd.CommandType = CommandType.StoredProcedure;
1264 cmd.Parameters.AddWithValue("@sSiteId", siteId); 1266 cmd.Parameters.AddWithValue("@sSiteId", siteId);
1265 - 1267 + cmd.Parameters.AddWithValue("@sEditionId", editionId);
  1268 +
1266 SqlDataAdapter da = new SqlDataAdapter(); 1269 SqlDataAdapter da = new SqlDataAdapter();
1267 da.SelectCommand = cmd; 1270 da.SelectCommand = cmd;
1268 dt = new DataTable(); 1271 dt = new DataTable();
400-SOURCECODE/AIAHTML5.API/Models/User.cs
@@ -34,6 +34,8 @@ namespace AIAHTML5.API.Models @@ -34,6 +34,8 @@ namespace AIAHTML5.API.Models
34 public bool IsBlocked { get; set; } 34 public bool IsBlocked { get; set; }
35 public int LicenseId { get; set; } 35 public int LicenseId { get; set; }
36 public int EditionId { get; set; } 36 public int EditionId { get; set; }
  37 + public int LicenseEditionId { get; set; }
  38 + public bool isSiteUser { get; set; }
37 public Int16 LoginFailureCauseId { get; set; } 39 public Int16 LoginFailureCauseId { get; set; }
38 public bool IsModestyOn { get; set; } 40 public bool IsModestyOn { get; set; }
39 public ArrayList Modules { get; set; } 41 public ArrayList Modules { get; set; }
400-SOURCECODE/AIAHTML5.API/Models/Users.cs
@@ -114,13 +114,14 @@ namespace AIAHTML5.API.Models @@ -114,13 +114,14 @@ namespace AIAHTML5.API.Models
114 return userDetails; 114 return userDetails;
115 } 115 }
116 116
117 - internal static void getLicenseIdForThisUser(int userId, out int licenseId, out int editionId) 117 + internal static void getLicenseIdForThisUser(int userId, out int licenseId, out int editionId, out int LicenseEditionId)
118 { 118 {
119 logger.Debug("inside getLicenseIdForThisUser for UserId =" + userId); 119 logger.Debug("inside getLicenseIdForThisUser for UserId =" + userId);
120 120
121 //assigning below variable to avoid compiler error for unassignd out params 121 //assigning below variable to avoid compiler error for unassignd out params
122 licenseId = 0; 122 licenseId = 0;
123 editionId = 0; 123 editionId = 0;
  124 + LicenseEditionId = 0;
124 125
125 126
126 127
@@ -133,6 +134,9 @@ namespace AIAHTML5.API.Models @@ -133,6 +134,9 @@ namespace AIAHTML5.API.Models
133 if (licenseEditionHash.ContainsKey(AIAConstants.EDITION_KEY_ID)) 134 if (licenseEditionHash.ContainsKey(AIAConstants.EDITION_KEY_ID))
134 editionId = Convert.ToInt32(licenseEditionHash[AIAConstants.EDITION_KEY_ID]); 135 editionId = Convert.ToInt32(licenseEditionHash[AIAConstants.EDITION_KEY_ID]);
135 136
  137 + if (licenseEditionHash.ContainsKey("LicenseEditionId"))
  138 + LicenseEditionId = Convert.ToInt32(licenseEditionHash["LicenseEditionId"]);
  139 +
136 140
137 } 141 }
138 142
@@ -356,14 +360,14 @@ namespace AIAHTML5.API.Models @@ -356,14 +360,14 @@ namespace AIAHTML5.API.Models
356 return result; 360 return result;
357 } 361 }
358 362
359 - internal static User GetUserSelectedSettings(int userId,out string skintone, out string modesty) 363 + internal static User GetUserSelectedSettings(int userId,bool isSiteUser, out string skintone, out string modesty)
360 { 364 {
361 logger.Debug("inside GetUserSelectedSettings for userid =" + userId); 365 logger.Debug("inside GetUserSelectedSettings for userid =" + userId);
362 366
363 skintone = null; 367 skintone = null;
364 modesty = null; 368 modesty = null;
365 DBModel objModel = new DBModel(); 369 DBModel objModel = new DBModel();
366 - User result = objModel.GetSelectedSettings(userId); 370 + User result = objModel.GetSelectedSettings(userId, isSiteUser);
367 if (result != null) 371 if (result != null)
368 { 372 {
369 skintone = result.userSelectedSkintone; 373 skintone = result.userSelectedSkintone;
@@ -538,8 +542,7 @@ namespace AIAHTML5.API.Models @@ -538,8 +542,7 @@ namespace AIAHTML5.API.Models
538 bool isSubscriptionNotStart = false; 542 bool isSubscriptionNotStart = false;
539 543
540 int intLicenseId = 0; 544 int intLicenseId = 0;
541 - int intEditionId = Convert.ToInt16(strEdition);  
542 - 545 +
543 DateTime dtLogDate = DateTime.Now; 546 DateTime dtLogDate = DateTime.Now;
544 547
545 if (string.IsNullOrEmpty(strAcccountNumber)) 548 if (string.IsNullOrEmpty(strAcccountNumber))
@@ -554,8 +557,10 @@ namespace AIAHTML5.API.Models @@ -554,8 +557,10 @@ namespace AIAHTML5.API.Models
554 } 557 }
555 else 558 else
556 { 559 {
  560 + int intEditionId = Convert.ToInt16(strEdition);
  561 +
557 DBModel objDBModel = new DBModel(); 562 DBModel objDBModel = new DBModel();
558 - DataTable dtLicense = objDBModel.GetLicenseBySiteId(intSiteId); 563 + DataTable dtLicense = objDBModel.GetLicenseBySiteId(intSiteId, intEditionId);
559 if (dtLicense.Rows.Count > 0) 564 if (dtLicense.Rows.Count > 0)
560 { 565 {
561 566
@@ -597,6 +602,8 @@ namespace AIAHTML5.API.Models @@ -597,6 +602,8 @@ namespace AIAHTML5.API.Models
597 { 602 {
598 //User objUserContext = new User(); 603 //User objUserContext = new User();
599 userInfo.Id = 0; 604 userInfo.Id = 0;
  605 + userInfo.siteId = intSiteId;
  606 + userInfo.isSiteUser = true;
600 userInfo.FirstName = licRow["LicenseeFirstName"].ToString(); 607 userInfo.FirstName = licRow["LicenseeFirstName"].ToString();
601 userInfo.LastName = licRow["LicenseeLastName"].ToString(); 608 userInfo.LastName = licRow["LicenseeLastName"].ToString();
602 userInfo.UserTypeId = AIAConstants.SITE_USER; 609 userInfo.UserTypeId = AIAConstants.SITE_USER;
@@ -612,6 +619,7 @@ namespace AIAHTML5.API.Models @@ -612,6 +619,7 @@ namespace AIAHTML5.API.Models
612 userInfo.EditionId = (Byte)intEditionId; 619 userInfo.EditionId = (Byte)intEditionId;
613 userInfo.LicenseTypeId = (byte)licRow["LicenseTypeId"]; 620 userInfo.LicenseTypeId = (byte)licRow["LicenseTypeId"];
614 userInfo.LicenseId = Convert.ToInt32(licRow["Id"]); 621 userInfo.LicenseId = Convert.ToInt32(licRow["Id"]);
  622 + userInfo.LicenseEditionId = Convert.ToInt32(licRow["LicenseEditionId"]);
615 userInfo.LoginId = ""; 623 userInfo.LoginId = "";
616 userInfo.Modesty = (bool)licRow["IsModesty"]; 624 userInfo.Modesty = (bool)licRow["IsModesty"];
617 //Retreive ModestyMode 625 //Retreive ModestyMode
@@ -631,8 +639,25 @@ namespace AIAHTML5.API.Models @@ -631,8 +639,25 @@ namespace AIAHTML5.API.Models
631 } 639 }
632 } 640 }
633 641
634 - // get edition features details  
635 - userInfo.objEditionFeatures = objDBModel.GetEditionFeatures((Byte)intEditionId); 642 + string skintone;
  643 + string modesty;
  644 + User us =GetUserSelectedSettings(userInfo.siteId,true, out skintone, out modesty);
  645 + if (us != null)
  646 + {
  647 + userInfo.userselectedModesty = modesty;
  648 + userInfo.userSelectedSkintone = skintone;
  649 + userInfo.userLexicon = us.userLexicon;
  650 + }
  651 + else
  652 + {
  653 + userInfo.userselectedModesty = null;
  654 + userInfo.userSelectedSkintone = null;
  655 + userInfo.userLexicon = null;
  656 +
  657 + }
  658 +
  659 + // get edition features details
  660 + userInfo.objEditionFeatures = objDBModel.GetEditionFeatures((Byte)intEditionId);
636 661
637 if (intLicenseId > 0) 662 if (intLicenseId > 0)
638 userInfo.Modules = getModuleListByLicenseId(intLicenseId); 663 userInfo.Modules = getModuleListByLicenseId(intLicenseId);
400-SOURCECODE/AIAHTML5.Web/app/controllers/HomeController.js
@@ -31,20 +31,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -31,20 +31,7 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
31 $rootScope.shapeType; 31 $rootScope.shapeType;
32 $rootScope.canvasLayerNameCollection=[]; 32 $rootScope.canvasLayerNameCollection=[];
33 $rootScope.islaxicanlanguageChange=false; 33 $rootScope.islaxicanlanguageChange=false;
34 - $rootScope.globalSetting = {  
35 - ethnicity: 'W',  
36 - modesty: 'Y',  
37 - };  
38 - $rootScope.formsetting = {  
39 - ethnicity: null,  
40 - modesty: null  
41 - };  
42 - $rootScope.lexicons = {  
43 - primaryid:1,  
44 - secondryids:[]  
45 - };  
46 -  
47 - 34 +
48 // on refersh this variable will also get null that is why we are only checking this variable on initialize that if it is null that means page gets refershed. 35 // on refersh this variable will also get null that is why we are only checking this variable on initialize that if it is null that means page gets refershed.
49 $rootScope.refreshcheck = null; 36 $rootScope.refreshcheck = null;
50 var isCommingSoonModel = true; 37 var isCommingSoonModel = true;
@@ -1647,45 +1634,90 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -1647,45 +1634,90 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
1647 if (typeof result.FirstName != undefined || result.FirstName != "" || result.FirstName != null) { 1634 if (typeof result.FirstName != undefined || result.FirstName != "" || result.FirstName != null) {
1648 //code for modesty setting 1635 //code for modesty setting
1649 if (result.LicenseInfo != null) { 1636 if (result.LicenseInfo != null) {
1650 - if (result.Modesty) {  
1651 - $rootScope.isModestyOn = true;  
1652 - $rootScope.isModestyOff = false;  
1653 - localStorage.setItem("globalModesty", "Y");  
1654 - $rootScope.formsetting = {  
1655 - ethnicity: "W",  
1656 - modesty: "Y" 1637 + if (result.userselectedModesty == undefined || result.userselectedModesty == null ||
  1638 + result.userSelectedSkintone == undefined || result.userSelectedSkintone == null) {
  1639 + if (result.Modesty) {
  1640 + $rootScope.isModestyOn = true;
  1641 + $rootScope.isModestyOff = false;
  1642 + localStorage.setItem("globalModesty", "Y");
  1643 + $rootScope.formsetting = {
  1644 + ethnicity: "W",
  1645 + modesty: "Y"
  1646 + }
  1647 +
  1648 + $rootScope.UpdateSetting($rootScope.formsetting)
  1649 + }
  1650 + else {
  1651 + $rootScope.isModestyOn = false;
  1652 + $rootScope.isModestyOff = true;
  1653 + localStorage.setItem("globalModesty", "N");
  1654 + $rootScope.formsetting = {
  1655 + ethnicity: "W",
  1656 + modesty: "N"
  1657 + }
  1658 +
  1659 + $rootScope.UpdateSetting($rootScope.formsetting)
1657 } 1660 }
1658 - $rootScope.UpdateSetting($rootScope.formsetting)  
1659 } 1661 }
1660 - else {  
1661 - $rootScope.isModestyOn = false;  
1662 - $rootScope.isModestyOff = true;  
1663 - localStorage.setItem("globalModesty", "N"); 1662 + else
  1663 + {
  1664 + localStorage.setItem("globalModesty", result.userselectedModesty);
  1665 + localStorage.setItem("globalEthnicity", result.userSelectedSkintone);
  1666 +
1664 $rootScope.formsetting = { 1667 $rootScope.formsetting = {
1665 - ethnicity: "W",  
1666 - modesty: "N" 1668 + ethnicity: result.userSelectedSkintone,
  1669 + modesty: result.userselectedModesty
1667 } 1670 }
1668 - $rootScope.UpdateSetting($rootScope.formsetting) 1671 +
  1672 + $rootScope.UpdateSetting($rootScope.formsetting);
  1673 +
1669 } 1674 }
  1675 +
  1676 + $rootScope.lexicons = {
  1677 + primaryid:result.userLexicon!=null && result.userLexicon.primaryid!=""?result.userLexicon.primaryid:"1",
  1678 + secondryids:result.userLexicon!=null && result.userLexicon.secondryids!="" ?result.userLexicon.secondryids:""
  1679 + };
  1680 +
  1681 + $rootScope.InitiateLexicon( $rootScope.lexicons.primaryid, $rootScope.lexicons.secondryids)
  1682 +
1670 } 1683 }
1671 - else {  
1672 - $rootScope.isModestyOn = true;  
1673 - $rootScope.isModestyOff = false;  
1674 - localStorage.setItem("globalModesty", "Y");  
1675 - $rootScope.formsetting = {  
1676 - ethnicity: "W",  
1677 - modesty: "Y" 1684 + else
  1685 + {
  1686 + if (result.userselectedModesty == undefined || result.userselectedModesty == null ||
  1687 + result.userSelectedSkintone == undefined || result.userSelectedSkintone == null) {
  1688 +
  1689 + $rootScope.isModestyOn = true;
  1690 + $rootScope.isModestyOff = false;
  1691 + localStorage.setItem("globalModesty", "Y");
  1692 + $rootScope.formsetting = {
  1693 + ethnicity: "W",
  1694 + modesty: "Y"
  1695 + }
  1696 + $rootScope.UpdateSetting($rootScope.formsetting);
  1697 + }
  1698 + else
  1699 + {
  1700 + localStorage.setItem("globalModesty", result.userselectedModesty);
  1701 + localStorage.setItem("globalEthnicity", result.userSelectedSkintone);
  1702 +
  1703 + $rootScope.formsetting = {
  1704 + ethnicity: result.userSelectedSkintone,
  1705 + modesty: result.userselectedModesty
  1706 + }
  1707 + $rootScope.UpdateSetting($rootScope.formsetting)
  1708 +
1678 } 1709 }
1679 - $rootScope.UpdateSetting($rootScope.formsetting) 1710 +
  1711 + $rootScope.lexicons = {
  1712 + primaryid:result.userLexicon!=null && result.userLexicon.primaryid!=""?result.userLexicon.primaryid:"1",
  1713 + secondryids:result.userLexicon!=null && result.userLexicon.secondryids!="" ?result.userLexicon.secondryids:""
  1714 + };
  1715 +
  1716 + $rootScope.InitiateLexicon( $rootScope.lexicons.primaryid, $rootScope.lexicons.secondryids)
  1717 +
1680 } 1718 }
1681 1719
1682 - //for site user set default lexicon  
1683 - $rootScope.lexicons = {  
1684 - primaryid:"1",  
1685 - secondryids:""  
1686 - };  
1687 1720
1688 - $rootScope.InitiateLexicon( $rootScope.lexicons.primaryid, $rootScope.lexicons.secondryids)  
1689 //code for modesty setting 1721 //code for modesty setting
1690 $rootScope.aiaModesty = $rootScope.formsetting.modesty; 1722 $rootScope.aiaModesty = $rootScope.formsetting.modesty;
1691 1723
@@ -8134,6 +8166,20 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -8134,6 +8166,20 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
8134 8166
8135 $rootScope.loadsettings = function () { 8167 $rootScope.loadsettings = function () {
8136 8168
  8169 + //applcation reload blank these value after assign
  8170 + $rootScope.globalSetting = {
  8171 + ethnicity: 'W',
  8172 + modesty: 'Y',
  8173 + };
  8174 + $rootScope.formsetting = {
  8175 + ethnicity: null,
  8176 + modesty: null
  8177 + };
  8178 + $rootScope.lexicons = {
  8179 + primaryid:1,
  8180 + secondryids:[]
  8181 + };
  8182 +
8137 //1. For now we are by default opening DA settings tab 8183 //1. For now we are by default opening DA settings tab
8138 $rootScope.SettingsTab = 3; 8184 $rootScope.SettingsTab = 3;
8139 8185
@@ -8256,7 +8302,23 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -8256,7 +8302,23 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
8256 var setting={}; 8302 var setting={};
8257 setting.modesty =Formatsetting.modesty ; 8303 setting.modesty =Formatsetting.modesty ;
8258 setting.skintone = Formatsetting.ethnicity; 8304 setting.skintone = Formatsetting.ethnicity;
8259 - setting.userId = $rootScope.userData.Id; 8305 +
  8306 + // var isallowToChange=false;
  8307 + if($rootScope.userData.isSiteUser)
  8308 + {
  8309 + // send as user id
  8310 + setting.userId = $rootScope.userData.siteId;
  8311 + //isallowToChange=$rootScope.userData.EditionId<3;
  8312 + }
  8313 + else
  8314 + {
  8315 + setting.userId = $rootScope.userData.Id;
  8316 + //concurrent license
  8317 + // only instructor
  8318 + //if($rootScope.userData.LicenseId!=0)
  8319 + // isallowToChange=$rootScope.userData.EditionId<3;
  8320 +
  8321 + }
8260 8322
8261 var secondLan=[] 8323 var secondLan=[]
8262 8324
@@ -8267,54 +8329,57 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data @@ -8267,54 +8329,57 @@ function ($rootScope, $scope, Modules, $log, $location, $compile, $timeout, Data
8267 8329
8268 setting.primaryid = $('#primarylaxican').attr("name"); 8330 setting.primaryid = $('#primarylaxican').attr("name");
8269 setting.secondryids = secondLan.join(","); 8331 setting.secondryids = secondLan.join(",");
8270 -  
8271 - if($rootScope.userData.Id!=0)  
8272 - { 8332 +
  8333 + setting.isSiteUser=$rootScope.userData.isSiteUser;
  8334 + setting.LicenseEditionId=$rootScope.userData.LicenseEditionId;
  8335 +
  8336 + // if(isallowToChange ||$rootScope.userData.LicenseId==0)
  8337 + // {
8273 AuthenticationService.saveSetings(setting) 8338 AuthenticationService.saveSetings(setting)
8274 - .then(  
8275 - function (result) {  
8276 - if(result==1)  
8277 - { 8339 + .then(
  8340 + function (result) {
  8341 + if(result==1)
  8342 + {
8278 $timeout(function () { 8343 $timeout(function () {
8279 - $('#setting-spinner').css('visibility', 'hidden');  
8280 - $('#modal-settings').css("display", "none");  
8281 - $('#modelsettingsbackground').css('z-index', '12000000');  
8282 - $("#modelsettingsbackground").css("display", "none");  
8283 - $rootScope.UpdateSetting(Formatsetting);  
8284 - 8344 + $('#setting-spinner').css('visibility', 'hidden');
  8345 + $('#modal-settings').css("display", "none");
  8346 + $('#modelsettingsbackground').css('z-index', '12000000');
  8347 + $("#modelsettingsbackground").css("display", "none");
  8348 + $rootScope.UpdateSetting(Formatsetting);
  8349 +
8285 }, 500); 8350 }, 500);
8286 8351
8287 - }  
8288 - else  
8289 - {  
8290 - $rootScope.errorMessage =AIAConstants.SETTING_SAVE_ERROR;  
8291 - $("#messageModal").modal('show');  
8292 - }  
8293 -  
8294 - }), 8352 + }
  8353 + else
  8354 + {
  8355 + $rootScope.errorMessage =AIAConstants.SETTING_SAVE_ERROR;
  8356 + $("#messageModal").modal('show');
  8357 + }
  8358 +
  8359 + }),
8295 function (error) { 8360 function (error) {
8296 console.log(' Error in Saving settings = ' + error.statusText); 8361 console.log(' Error in Saving settings = ' + error.statusText);
8297 $rootScope.isVisibleLogin = true; 8362 $rootScope.isVisibleLogin = true;
8298 $('#setting-spinner').css('visibility', 'hidden'); 8363 $('#setting-spinner').css('visibility', 'hidden');
8299 $('#modal-settings').css("display", "none"); 8364 $('#modal-settings').css("display", "none");
8300 - $('#modelsettingsbackground').css('zIndex', '12000000'); 8365 + $('#modelsettingsbackground').css('z-index', '12000000');
8301 $("#modelsettingsbackground").css("display", "none"); 8366 $("#modelsettingsbackground").css("display", "none");
8302 $rootScope.errorMessage = error; 8367 $rootScope.errorMessage = error;
8303 $("#messageModal").modal('show'); 8368 $("#messageModal").modal('show');
8304 } 8369 }
8305 -  
8306 - }  
8307 - else  
8308 - {  
8309 - // for site user. no user id for site license  
8310 - $('#setting-spinner').css('visibility', 'hidden');  
8311 - $('#modal-settings').css("display", "none");  
8312 - $('#modelsettingsbackground').css('zIndex', '12000000');  
8313 - $("#modelsettingsbackground").css("display", "none");  
8314 - $rootScope.UpdateSetting(setting);  
8315 -  
8316 - }  
8317 - 8370 + // }
  8371 + // else
  8372 + // {
  8373 + // $timeout(function () {
  8374 + // $('#setting-spinner').css('visibility', 'hidden');
  8375 + // $('#modal-settings').css("display", "none");
  8376 + // $('#modelsettingsbackground').css('z-index', '12000000');
  8377 + // $("#modelsettingsbackground").css("display", "none");
  8378 + // $rootScope.UpdateSetting(Formatsetting);
  8379 +
  8380 + // }, 500);
  8381 +
  8382 + // }
8318 8383
8319 }; 8384 };
8320 8385
400-SOURCECODE/Admin/src/app/components/LicenseEntity/addlicense.component.html
@@ -118,8 +118,8 @@ @@ -118,8 +118,8 @@
118 <div class="form-group marginTop5"> 118 <div class="form-group marginTop5">
119 <label for="AccountNo" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Account No <span class="red">*</span> : </label> 119 <label for="AccountNo" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Account No <span class="red">*</span> : </label>
120 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 120 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
121 - <input type="text" class="form-control input-sm" id="AccountNo" formControlName="accountNumber" maxlength="16" *ngIf="license.LicenseId > 0" [attr.disabled]="license.LicenseId > 0" (blur)="OnAccountNoBlur($event.target.value)">  
122 - <input type="text" class="form-control input-sm" id="AccountNo" formControlName="accountNumber" maxlength="16" *ngIf="license.LicenseId == 0" (blur)="OnAccountNoBlur($event.target.value)"> 121 + <input type="text" class="form-control input-sm" id="AccountNo" formControlName="accountNumber" maxlength="16" *ngIf="license.LicenseId > 0" [attr.disabled]="license.LicenseId > 0" (blur)="OnAccountNoBlur($event.target.value)" (keydown.space)="$event.preventDefault();">
  122 + <input type="text" class="form-control input-sm" id="AccountNo" formControlName="accountNumber" maxlength="16" *ngIf="license.LicenseId == 0" (blur)="OnAccountNoBlur($event.target.value)" (keydown.space)="$event.preventDefault();">
123 <div *ngIf="insertUpdateLicenseFrm.controls.accountNumber.hasError('required') && insertUpdateLicenseFrm.controls.accountNumber.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Account number is required</div> 123 <div *ngIf="insertUpdateLicenseFrm.controls.accountNumber.hasError('required') && insertUpdateLicenseFrm.controls.accountNumber.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Account number is required</div>
124 </div> 124 </div>
125 </div> 125 </div>
@@ -267,7 +267,7 @@ @@ -267,7 +267,7 @@
267 <div class="form-group marginTop5"> 267 <div class="form-group marginTop5">
268 <label for="Zip" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Zip <span class="red">*</span> : </label> 268 <label for="Zip" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Zip <span class="red">*</span> : </label>
269 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 269 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
270 - <input type="text" class="form-control input-sm" id="Zip" formControlName="zip" maxlength="20"> 270 + <input type="text" class="form-control input-sm" id="Zip" formControlName="zip" maxlength="20" (keydown.space)="$event.preventDefault();">
271 <div *ngIf="insertUpdateLicenseFrm.controls.zip.hasError('required') && insertUpdateLicenseFrm.controls.zip.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Zip is required</div> 271 <div *ngIf="insertUpdateLicenseFrm.controls.zip.hasError('required') && insertUpdateLicenseFrm.controls.zip.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Zip is required</div>
272 </div> 272 </div>
273 </div> 273 </div>
@@ -276,7 +276,7 @@ @@ -276,7 +276,7 @@
276 <div class="form-group marginTop5"> 276 <div class="form-group marginTop5">
277 <label for="Phone" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Phone <span class="red">*</span> : </label> 277 <label for="Phone" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Phone <span class="red">*</span> : </label>
278 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 278 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
279 - <input type="text" class="form-control input-sm" id="Phone" formControlName="phone" maxlength="30" (keyup)="onKeyUp($event)"> 279 + <input type="text" class="form-control input-sm" id="Phone" formControlName="phone" maxlength="30" (keyup)="onKeyUp($event)" (keydown.space)="$event.preventDefault();">
280 <span class="help-block">(xxx-xxx-xxxx)</span> 280 <span class="help-block">(xxx-xxx-xxxx)</span>
281 <div *ngIf="insertUpdateLicenseFrm.controls.phone.hasError('required') && insertUpdateLicenseFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is required</div> 281 <div *ngIf="insertUpdateLicenseFrm.controls.phone.hasError('required') && insertUpdateLicenseFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is required</div>
282 <div *ngIf="insertUpdateLicenseFrm.controls.phone.hasError('pattern') && (insertUpdateLicenseFrm.controls.phone.dirty || license.LicenseId > 0)" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is invalid</div> 282 <div *ngIf="insertUpdateLicenseFrm.controls.phone.hasError('pattern') && (insertUpdateLicenseFrm.controls.phone.dirty || license.LicenseId > 0)" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is invalid</div>
@@ -292,7 +292,7 @@ @@ -292,7 +292,7 @@
292 <div class="form-group marginTop5"> 292 <div class="form-group marginTop5">
293 <label for="Email" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Email ID <span class="red">*</span> : </label> 293 <label for="Email" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Email ID <span class="red">*</span> : </label>
294 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 294 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
295 - <input type="text" class="form-control input-sm" id="Email" formControlName="emailId" maxlength="50" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$"> 295 + <input type="text" class="form-control input-sm" id="Email" formControlName="emailId" maxlength="50" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$" (keydown.space)="$event.preventDefault();">
296 <div *ngIf="insertUpdateLicenseFrm.controls.emailId.hasError('required') && !insertUpdateLicenseFrm.controls.emailId.value && insertUpdateLicenseFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is required</div> 296 <div *ngIf="insertUpdateLicenseFrm.controls.emailId.hasError('required') && !insertUpdateLicenseFrm.controls.emailId.value && insertUpdateLicenseFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is required</div>
297 <div *ngIf="insertUpdateLicenseFrm.controls.emailId.invalid && insertUpdateLicenseFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is invalid</div> 297 <div *ngIf="insertUpdateLicenseFrm.controls.emailId.invalid && insertUpdateLicenseFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is invalid</div>
298 </div> 298 </div>
@@ -311,7 +311,7 @@ @@ -311,7 +311,7 @@
311 <label for="SubscriptionStartDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Subscription Start Date<span class="red">*</span>:</label> 311 <label for="SubscriptionStartDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Subscription Start Date<span class="red">*</span>:</label>
312 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 312 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
313 <div id="datetimepicker1" class="input-group input-group-sm input-append date"> 313 <div id="datetimepicker1" class="input-group input-group-sm input-append date">
314 - <input type="text" class="form-control" id="SubscriptionStartDate" formControlName="subscriptionStartDate" 314 + <input type="text" class="form-control" id="SubscriptionStartDate" formControlName="subscriptionStartDate" (keydown.space)="$event.preventDefault();"
315 #dp1="bsDatepicker" bsDatepicker [(bsValue)]="bsValue1" 315 #dp1="bsDatepicker" bsDatepicker [(bsValue)]="bsValue1"
316 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig" 316 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig"
317 (bsValueChange)="DateChange(dp1)" (change)="DateChange(dp1)"> 317 (bsValueChange)="DateChange(dp1)" (change)="DateChange(dp1)">
@@ -331,7 +331,7 @@ @@ -331,7 +331,7 @@
331 <label for="SubscriptionEndDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Subscription End Date<span class="red">*</span>:</label> 331 <label for="SubscriptionEndDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Subscription End Date<span class="red">*</span>:</label>
332 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 332 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
333 <div id="datetimepicker2" class="input-group input-group-sm input-append date"> 333 <div id="datetimepicker2" class="input-group input-group-sm input-append date">
334 - <input type="text" class="form-control" id="SubscriptionEndDate" formControlName="subscriptionEndDate" 334 + <input type="text" class="form-control" id="SubscriptionEndDate" formControlName="subscriptionEndDate" (keydown.space)="$event.preventDefault();"
335 #dp2="bsDatepicker" bsDatepicker [(bsValue)]="bsValue2" 335 #dp2="bsDatepicker" bsDatepicker [(bsValue)]="bsValue2"
336 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig" 336 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig"
337 (bsValueChange)="DateChange(dp2)" (change)="DateChange(dp2)"> 337 (bsValueChange)="DateChange(dp2)" (change)="DateChange(dp2)">
@@ -351,7 +351,7 @@ @@ -351,7 +351,7 @@
351 <label for="RenewDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Renew Date <span class="red">*</span> :</label> 351 <label for="RenewDate" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0">Renew Date <span class="red">*</span> :</label>
352 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 352 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
353 <div id="datetimepicker3" class="input-group input-group-sm input-append date"> 353 <div id="datetimepicker3" class="input-group input-group-sm input-append date">
354 - <input type="text" class="form-control" id="RenewDate" formControlName="renewDate" 354 + <input type="text" class="form-control" id="RenewDate" formControlName="renewDate" (keydown.space)="$event.preventDefault();"
355 #dp3="bsDatepicker" bsDatepicker [(bsValue)]="bsValue3" 355 #dp3="bsDatepicker" bsDatepicker [(bsValue)]="bsValue3"
356 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig" 356 [minDate]="minDate" [maxDate]="maxDate" [bsConfig]="bsConfig"
357 (bsValueChange)="DateChange(dp3)" (change)="DateChange(dp3)"> 357 (bsValueChange)="DateChange(dp3)" (change)="DateChange(dp3)">
@@ -370,7 +370,7 @@ @@ -370,7 +370,7 @@
370 <div class="form-group marginTop5"> 370 <div class="form-group marginTop5">
371 <label for="SubscriptionPrice" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Subscription Price <span class="red">*</span> : </label> 371 <label for="SubscriptionPrice" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Subscription Price <span class="red">*</span> : </label>
372 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 372 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
373 - <input type="text" class="form-control input-sm" id="SubscriptionPrice" formControlName="subscriptionPrice" maxlength="11" (blur)="SubscriptionPriceBlur()" (keyup)="onKeyPress($event)"> 373 + <input type="text" class="form-control input-sm" id="SubscriptionPrice" formControlName="subscriptionPrice" maxlength="11" (blur)="SubscriptionPriceBlur()" (keyup)="onKeyPress($event)" (keydown.space)="$event.preventDefault();">
374 <div *ngIf="insertUpdateLicenseFrm.controls.subscriptionPrice.hasError('required') && insertUpdateLicenseFrm.controls.subscriptionPrice.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Subscription price is required</div> 374 <div *ngIf="insertUpdateLicenseFrm.controls.subscriptionPrice.hasError('required') && insertUpdateLicenseFrm.controls.subscriptionPrice.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Subscription price is required</div>
375 <div *ngIf="insertUpdateLicenseFrm.controls.subscriptionPrice.hasError('pattern') && insertUpdateLicenseFrm.controls.subscriptionPrice.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Subscription price must be numeric</div> 375 <div *ngIf="insertUpdateLicenseFrm.controls.subscriptionPrice.hasError('pattern') && insertUpdateLicenseFrm.controls.subscriptionPrice.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Subscription price must be numeric</div>
376 </div> 376 </div>
@@ -381,7 +381,7 @@ @@ -381,7 +381,7 @@
381 <div class="form-group marginTop5"> 381 <div class="form-group marginTop5">
382 <label for="ExportImages" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">No. of Export Images <span class="red">*</span> : </label> 382 <label for="ExportImages" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">No. of Export Images <span class="red">*</span> : </label>
383 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 383 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
384 - <input type="text" class="form-control input-sm" id="ExportImages" formControlName="noOfImages" maxlength="5"> 384 + <input type="text" class="form-control input-sm" id="ExportImages" formControlName="noOfImages" maxlength="5" (keydown.space)="$event.preventDefault();">
385 <div *ngIf="insertUpdateLicenseFrm.controls.noOfImages.hasError('required') && insertUpdateLicenseFrm.controls.noOfImages.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Number of export images is required</div> 385 <div *ngIf="insertUpdateLicenseFrm.controls.noOfImages.hasError('required') && insertUpdateLicenseFrm.controls.noOfImages.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Number of export images is required</div>
386 <div *ngIf="insertUpdateLicenseFrm.controls.noOfImages.hasError('pattern') && insertUpdateLicenseFrm.controls.noOfImages.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Number of export images must be numeric</div> 386 <div *ngIf="insertUpdateLicenseFrm.controls.noOfImages.hasError('pattern') && insertUpdateLicenseFrm.controls.noOfImages.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Number of export images must be numeric</div>
387 </div> 387 </div>
@@ -392,7 +392,7 @@ @@ -392,7 +392,7 @@
392 <div class="form-group marginTop5"> 392 <div class="form-group marginTop5">
393 <label for="MasterSiteURL" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Master Site URL <span class="red">*</span> : </label> 393 <label for="MasterSiteURL" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Master Site URL <span class="red">*</span> : </label>
394 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 394 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
395 - <input type="text" class="form-control input-sm" id="MasterSiteURL" formControlName="masterSiteUrl"> 395 + <input type="text" class="form-control input-sm" id="MasterSiteURL" formControlName="masterSiteUrl" (keydown.space)="$event.preventDefault();">
396 </div> 396 </div>
397 </div> 397 </div>
398 </div> 398 </div>
@@ -419,7 +419,7 @@ @@ -419,7 +419,7 @@
419 <div class="form-group marginTop5"> 419 <div class="form-group marginTop5">
420 <label for="UserName1" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">User Name <span class="red">*</span> : </label> 420 <label for="UserName1" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">User Name <span class="red">*</span> : </label>
421 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 421 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
422 - <input type="text" class="form-control input-sm" id="UserName" formControlName="login" maxlength="50"> 422 + <input type="text" class="form-control input-sm" id="UserName" formControlName="login" maxlength="50" (keydown.space)="$event.preventDefault();">
423 <span class="help-block">(Minimum 8 characters)</span> 423 <span class="help-block">(Minimum 8 characters)</span>
424 <div *ngIf="!insertUpdateLicenseFrm.controls.login.valid && insertUpdateLicenseFrm.controls.login.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required.</div> 424 <div *ngIf="!insertUpdateLicenseFrm.controls.login.valid && insertUpdateLicenseFrm.controls.login.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required.</div>
425 </div> 425 </div>
@@ -430,7 +430,7 @@ @@ -430,7 +430,7 @@
430 <div class="form-group marginTop5"> 430 <div class="form-group marginTop5">
431 <label for="Password" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Password <span class="red">*</span> : </label> 431 <label for="Password" class="col-sm-12 col-lg-6 control-label text-right-lg paddTop7 padd-left0" title="">Password <span class="red">*</span> : </label>
432 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0"> 432 <div class="col-sm-12 col-lg-6 padd-left0 padd-right0">
433 - <input type="password" class="form-control input-sm" id="Password" formControlName="password" maxlength="50"> 433 + <input type="password" class="form-control input-sm" id="Password" formControlName="password" maxlength="50" (keydown.space)="$event.preventDefault();">
434 <span class="help-block">(Minimum 8 characters)</span> 434 <span class="help-block">(Minimum 8 characters)</span>
435 <div *ngIf="!insertUpdateLicenseFrm.controls.password.valid && insertUpdateLicenseFrm.controls.password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required.</div> 435 <div *ngIf="!insertUpdateLicenseFrm.controls.password.valid && insertUpdateLicenseFrm.controls.password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required.</div>
436 </div> 436 </div>
400-SOURCECODE/Admin/src/app/components/LicenseEntity/addlicense.component.ts
@@ -66,7 +66,7 @@ export class AddLicense implements OnInit { @@ -66,7 +66,7 @@ export class AddLicense implements OnInit {
66 this.editionLoginsText = ''; 66 this.editionLoginsText = '';
67 this.insertUpdateLicenseFrm = this.fb.group({ 67 this.insertUpdateLicenseFrm = this.fb.group({
68 licenseId: [0], 68 licenseId: [0],
69 - accountNumber: ['', [Validators.required,this.ClearWhitespaceValidator]], 69 + accountNumber: ['', [Validators.required]],
70 accountTypeId: [0, Validators.min(1)], 70 accountTypeId: [0, Validators.min(1)],
71 productId: [''], 71 productId: [''],
72 licenseeFirstName: ['', [Validators.required,this.noWhitespaceValidator]], 72 licenseeFirstName: ['', [Validators.required,this.noWhitespaceValidator]],
@@ -78,21 +78,21 @@ export class AddLicense implements OnInit { @@ -78,21 +78,21 @@ export class AddLicense implements OnInit {
78 city: ['', [Validators.required,this.noWhitespaceValidator]], 78 city: ['', [Validators.required,this.noWhitespaceValidator]],
79 stateId: [0, Validators.min(1)], 79 stateId: [0, Validators.min(1)],
80 countryId: [0, Validators.min(1)], 80 countryId: [0, Validators.min(1)],
81 - zip: ['', [Validators.required,this.noWhitespaceValidator]],  
82 - emailId: ['', [Validators.required,this.ClearWhitespaceValidator]],  
83 - phone: ['', [Validators.required, Validators.pattern('^([0-9]{3})-([0-9]{3})-([0-9]{4})$'),this.noWhitespaceValidator]], 81 + zip: ['', [Validators.required]],
  82 + emailId: ['', [Validators.required]],
  83 + phone: ['', [Validators.required, Validators.pattern('^([0-9]{3})-([0-9]{3})-([0-9]{4})$')]],
84 editionLoginArr: this.fb.array([]), 84 editionLoginArr: this.fb.array([]),
85 editionLogins: [''], 85 editionLogins: [''],
86 totalLogins: [0], 86 totalLogins: [0],
87 - subscriptionPrice: [0, [Validators.required, Validators.pattern('[0-9.]*'),this.noWhitespaceValidator]], 87 + subscriptionPrice: [0, [Validators.required, Validators.pattern('[0-9.]*')]],
88 subscriptionStartDate: [this.startDate, Validators.required], 88 subscriptionStartDate: [this.startDate, Validators.required],
89 subscriptionEndDate: ['', Validators.required], 89 subscriptionEndDate: ['', Validators.required],
90 - noOfImages: ['', [Validators.required, Validators.pattern('[0-9]*'),this.noWhitespaceValidator]],  
91 - masterSiteUrl: ['a', [Validators.required,this.noWhitespaceValidator]], 90 + noOfImages: ['', [Validators.required, Validators.pattern('[0-9]*')]],
  91 + masterSiteUrl: ['a', [Validators.required]],
92 siteUrlFrom: [''], 92 siteUrlFrom: [''],
93 siteUrlTo: [''], 93 siteUrlTo: [''],
94 - login: ['a', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]],  
95 - password: ['a', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]], 94 + login: ['a', [Validators.required, Validators.minLength(8)]],
  95 + password: ['a', [Validators.required, Validators.minLength(8)]],
96 securityQuestionId: [0, Validators.min(1)], 96 securityQuestionId: [0, Validators.min(1)],
97 answer: ['a', [Validators.required,this.noWhitespaceValidator]], 97 answer: ['a', [Validators.required,this.noWhitespaceValidator]],
98 testLicenseEditionId: [1], 98 testLicenseEditionId: [1],
400-SOURCECODE/Admin/src/app/components/LicenseEntity/editlicensebasicsettings.component.html
@@ -76,7 +76,7 @@ @@ -76,7 +76,7 @@
76 <div class="form-group"> 76 <div class="form-group">
77 <label for="inputEmail3" class="col-sm-4 control-label">Email ID <span class="red">*</span> :</label> 77 <label for="inputEmail3" class="col-sm-4 control-label">Email ID <span class="red">*</span> :</label>
78 <div class="col-sm-7"> 78 <div class="col-sm-7">
79 - <input type="text" class="form-control input-sm" id="Email" formControlName="emailId" maxlength="50" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$"> 79 + <input type="text" class="form-control input-sm" id="Email" formControlName="emailId" maxlength="50" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$" (keydown.space)="$event.preventDefault();">
80 <div *ngIf="updateLicenseBasicSettingsFrm.controls.emailId.hasError('required') && !updateLicenseBasicSettingsFrm.controls.emailId.value && updateLicenseBasicSettingsFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is required</div> 80 <div *ngIf="updateLicenseBasicSettingsFrm.controls.emailId.hasError('required') && !updateLicenseBasicSettingsFrm.controls.emailId.value && updateLicenseBasicSettingsFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is required</div>
81 <div *ngIf="updateLicenseBasicSettingsFrm.controls.emailId.invalid && updateLicenseBasicSettingsFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is invalid</div> 81 <div *ngIf="updateLicenseBasicSettingsFrm.controls.emailId.invalid && updateLicenseBasicSettingsFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email is invalid</div>
82 </div> 82 </div>
@@ -108,7 +108,7 @@ @@ -108,7 +108,7 @@
108 <div class="form-group"> 108 <div class="form-group">
109 <label for="inputEmail3" class="col-sm-4 control-label">Zip <span class="red">*</span> :</label> 109 <label for="inputEmail3" class="col-sm-4 control-label">Zip <span class="red">*</span> :</label>
110 <div class="col-sm-7"> 110 <div class="col-sm-7">
111 - <input type="text" class="form-control input-sm" id="Zip" formControlName="zip" maxlength="20"> 111 + <input type="text" class="form-control input-sm" id="Zip" formControlName="zip" maxlength="20" (keydown.space)="$event.preventDefault();">
112 <div *ngIf="updateLicenseBasicSettingsFrm.controls.zip.hasError('required') && updateLicenseBasicSettingsFrm.controls.zip.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Zip is required</div> 112 <div *ngIf="updateLicenseBasicSettingsFrm.controls.zip.hasError('required') && updateLicenseBasicSettingsFrm.controls.zip.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Zip is required</div>
113 </div> 113 </div>
114 </div> 114 </div>
@@ -140,7 +140,7 @@ @@ -140,7 +140,7 @@
140 <div class="form-group"> 140 <div class="form-group">
141 <label for="inputEmail3" class="col-sm-4 control-label">Phone <span class="red">*</span> :</label> 141 <label for="inputEmail3" class="col-sm-4 control-label">Phone <span class="red">*</span> :</label>
142 <div class="col-sm-7"> 142 <div class="col-sm-7">
143 - <input type="text" class="form-control input-sm" id="Phone" formControlName="phone" maxlength="30" (keyup)="onKeyUp($event)"> 143 + <input type="text" class="form-control input-sm" id="Phone" formControlName="phone" maxlength="30" (keyup)="onKeyUp($event)" (keydown.space)="$event.preventDefault();">
144 <span class="help-block">(xxx-xxx-xxxx)</span> 144 <span class="help-block">(xxx-xxx-xxxx)</span>
145 <div *ngIf="updateLicenseBasicSettingsFrm.controls.phone.hasError('required') && updateLicenseBasicSettingsFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is required</div> 145 <div *ngIf="updateLicenseBasicSettingsFrm.controls.phone.hasError('required') && updateLicenseBasicSettingsFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is required</div>
146 <div *ngIf="updateLicenseBasicSettingsFrm.controls.phone.hasError('pattern') && updateLicenseBasicSettingsFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is invalid</div> 146 <div *ngIf="updateLicenseBasicSettingsFrm.controls.phone.hasError('pattern') && updateLicenseBasicSettingsFrm.controls.phone.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Phone is invalid</div>
400-SOURCECODE/Admin/src/app/components/LicenseEntity/editlicensebasicsettings.component.ts
@@ -55,9 +55,9 @@ export class EditLicenseBasicSettings implements OnInit { @@ -55,9 +55,9 @@ export class EditLicenseBasicSettings implements OnInit {
55 city: ['', [Validators.required,this.noWhitespaceValidator]], 55 city: ['', [Validators.required,this.noWhitespaceValidator]],
56 stateId: [0], 56 stateId: [0],
57 countryId: [0], 57 countryId: [0],
58 - zip: ['', [Validators.required,this.noWhitespaceValidator]],  
59 - emailId: ['', [Validators.required,this.noWhitespaceValidator]],  
60 - phone: ['', [Validators.required, Validators.pattern('^([0-9]{3})-([0-9]{3})-([0-9]{4})$'),this.noWhitespaceValidator]], 58 + zip: ['', [Validators.required]],
  59 + emailId: ['', [Validators.required]],
  60 + phone: ['', [Validators.required, Validators.pattern('^([0-9]{3})-([0-9]{3})-([0-9]{4})$')]],
61 }); 61 });
62 this.GetCountry(); 62 this.GetCountry();
63 this.GetState(); 63 this.GetState();
400-SOURCECODE/Admin/src/app/components/LicenseEntity/license.service.ts
@@ -250,7 +250,8 @@ export class LicenseService{ @@ -250,7 +250,8 @@ export class LicenseService{
250 { 250 {
251 'siteId': jsonObj.siteId, 251 'siteId': jsonObj.siteId,
252 'licenseEditionId': element.m_Item1, 252 'licenseEditionId': element.m_Item1,
253 - 'isModesty': element.m_Item2 253 + 'isModesty': element.m_Item2,
  254 + 'isSiteUser': jsonObj.isSiteUser
254 } 255 }
255 ); 256 );
256 }); 257 });
@@ -258,6 +259,7 @@ export class LicenseService{ @@ -258,6 +259,7 @@ export class LicenseService{
258 var headers = new Headers({ 259 var headers = new Headers({
259 'Content-Type': 'application/json' 260 'Content-Type': 'application/json'
260 }); 261 });
  262 +
261 return this.http.post(this.commonService.resourceBaseUrl + "License/UpdateLicenseModestySettings", 263 return this.http.post(this.commonService.resourceBaseUrl + "License/UpdateLicenseModestySettings",
262 JSON.stringify(jsonData), {headers: headers}) 264 JSON.stringify(jsonData), {headers: headers})
263 .map(this.extractData) 265 .map(this.extractData)
400-SOURCECODE/Admin/src/app/components/LicenseEntity/licensemodestysettings.component.ts
@@ -29,7 +29,7 @@ export class LicenseModestySettings implements OnInit { @@ -29,7 +29,7 @@ export class LicenseModestySettings implements OnInit {
29 isBuildingLevel: boolean = false; 29 isBuildingLevel: boolean = false;
30 LicenseId:number=0; 30 LicenseId:number=0;
31 AccountNumber:string=''; 31 AccountNumber:string='';
32 - 32 +
33 constructor(private _loadingService: LoadingService,private licenseService: LicenseService, public globalService: GlobalService, private router: Router, private activeRoute: ActivatedRoute, private fb: FormBuilder, 33 constructor(private _loadingService: LoadingService,private licenseService: LicenseService, public globalService: GlobalService, private router: Router, private activeRoute: ActivatedRoute, private fb: FormBuilder,
34 private modalService: BsModalService, private _confirmService: ConfirmService) { 34 private modalService: BsModalService, private _confirmService: ConfirmService) {
35 } 35 }
@@ -42,6 +42,7 @@ export class LicenseModestySettings implements OnInit { @@ -42,6 +42,7 @@ export class LicenseModestySettings implements OnInit {
42 licenseId: [0], 42 licenseId: [0],
43 accountNumber: ['', Validators.required], 43 accountNumber: ['', Validators.required],
44 siteId: [0], 44 siteId: [0],
  45 + isSiteUser:[false],
45 lstModesty: [this.fb.array([])], 46 lstModesty: [this.fb.array([])],
46 }); 47 });
47 $('#AccountNumber').prop('disabled', true); 48 $('#AccountNumber').prop('disabled', true);
@@ -94,6 +95,7 @@ export class LicenseModestySettings implements OnInit { @@ -94,6 +95,7 @@ export class LicenseModestySettings implements OnInit {
94 this.lstLicenseEditionModesty = null; 95 this.lstLicenseEditionModesty = null;
95 this.lstLicenseSites = null; 96 this.lstLicenseSites = null;
96 this.selectedSiteId = 0; 97 this.selectedSiteId = 0;
  98 + this.updateModestySettingsFrm.controls['siteId'].setValue(0);
97 if (!this.isBuildingLevel) { 99 if (!this.isBuildingLevel) {
98 this.GetLicenseEditionModesty(); 100 this.GetLicenseEditionModesty();
99 } 101 }
@@ -109,6 +111,27 @@ export class LicenseModestySettings implements OnInit { @@ -109,6 +111,27 @@ export class LicenseModestySettings implements OnInit {
109 }, error => this.error = <any>error); 111 }, error => this.error = <any>error);
110 } 112 }
111 } 113 }
  114 +
  115 + GetLicenseById() {
  116 + //use for to check is siteuser or not
  117 + if (this.LicenseId != 0) {
  118 + this._loadingService.ShowLoading("global-loading");
  119 + this.licenseService.GetLicenseById(this.LicenseId)
  120 + .subscribe(st => {
  121 + if (st.LicenseId > 0) {
  122 + if(st.LicenseTypeId==3)
  123 + {
  124 + this.updateModestySettingsFrm.controls['isSiteUser'].setValue(true);
  125 + }
  126 + else
  127 + {
  128 + this.updateModestySettingsFrm.controls['isSiteUser'].setValue(false);
  129 + }
  130 + this._loadingService.HideLoading("global-loading");
  131 + }
  132 + }, error => this.error = <any>error);
  133 + }
  134 + }
112 135
113 GetLicenseEditionModesty() { 136 GetLicenseEditionModesty() {
114 this.licenseService.GetLicenseModestySettings(this.LicenseId, this.selectedSiteId) 137 this.licenseService.GetLicenseModestySettings(this.LicenseId, this.selectedSiteId)
@@ -139,6 +162,7 @@ export class LicenseModestySettings implements OnInit { @@ -139,6 +162,7 @@ export class LicenseModestySettings implements OnInit {
139 162
140 this.updateModestySettingsFrm.controls['licenseId'].setValue(LicenseId); 163 this.updateModestySettingsFrm.controls['licenseId'].setValue(LicenseId);
141 this.updateModestySettingsFrm.controls['accountNumber'].setValue(AccountNumber); 164 this.updateModestySettingsFrm.controls['accountNumber'].setValue(AccountNumber);
  165 + this.GetLicenseById()
142 } 166 }
143 167
144 168
400-SOURCECODE/Admin/src/app/components/UserEntity/adduser.component.html
@@ -22,7 +22,7 @@ @@ -22,7 +22,7 @@
22 <div class="form-group"> 22 <div class="form-group">
23 <label for="inputEmail3" class="col-sm-4 control-label">User Name <span class="red">*</span> :</label> 23 <label for="inputEmail3" class="col-sm-4 control-label">User Name <span class="red">*</span> :</label>
24 <div class="col-sm-7"> 24 <div class="col-sm-7">
25 - <input type="text" class="form-control input-sm" id="name" placeholder="User Name" formControlName="UserName"> 25 + <input type="text" class="form-control input-sm" id="name" placeholder="User Name" formControlName="UserName" (keydown.space)="$event.preventDefault();">
26 <span class="help-block">(Minimum 8 characters)</span> 26 <span class="help-block">(Minimum 8 characters)</span>
27 <div *ngIf="!adduserFrm.controls.UserName.valid && adduserFrm.controls.UserName.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required.</div> 27 <div *ngIf="!adduserFrm.controls.UserName.valid && adduserFrm.controls.UserName.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required.</div>
28 </div> 28 </div>
@@ -30,7 +30,7 @@ @@ -30,7 +30,7 @@
30 <div class="form-group"> 30 <div class="form-group">
31 <label for="inputPassword3" class="col-sm-4 control-label">Password <span class="red">*</span> :</label> 31 <label for="inputPassword3" class="col-sm-4 control-label">Password <span class="red">*</span> :</label>
32 <div class="col-sm-7"> 32 <div class="col-sm-7">
33 - <input type="password" class="form-control input-sm" id="password" placeholder="" formControlName="Password"> 33 + <input type="password" class="form-control input-sm" id="password" placeholder="" formControlName="Password" (keydown.space)="$event.preventDefault();">
34 <span class="help-block">(Minimum 8 characters)</span> 34 <span class="help-block">(Minimum 8 characters)</span>
35 <div *ngIf="!adduserFrm.controls.Password.valid && adduserFrm.controls.Password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required</div> 35 <div *ngIf="!adduserFrm.controls.Password.valid && adduserFrm.controls.Password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required</div>
36 </div> 36 </div>
@@ -38,7 +38,7 @@ @@ -38,7 +38,7 @@
38 <div class="form-group"> 38 <div class="form-group">
39 <label for="inputPassword3" class="col-sm-4 control-label">Confirm Password <span class="red">*</span> :</label> 39 <label for="inputPassword3" class="col-sm-4 control-label">Confirm Password <span class="red">*</span> :</label>
40 <div class="col-sm-7"> 40 <div class="col-sm-7">
41 - <input type="password" class="form-control input-sm" id="cpassword" placeholder="" formControlName="ConfirmPassword"> 41 + <input type="password" class="form-control input-sm" id="cpassword" placeholder="" formControlName="ConfirmPassword" (keydown.space)="$event.preventDefault();">
42 <div *ngIf="!adduserFrm.controls.ConfirmPassword.valid && !adduserFrm.controls.ConfirmPassword.value && adduserFrm.controls.ConfirmPassword.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Confirm Password is required</div> 42 <div *ngIf="!adduserFrm.controls.ConfirmPassword.valid && !adduserFrm.controls.ConfirmPassword.value && adduserFrm.controls.ConfirmPassword.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Confirm Password is required</div>
43 43
44 <div *ngIf="adduserFrm.controls.ConfirmPassword.value!=adduserFrm.controls.Password.value && adduserFrm.controls.ConfirmPassword.valid" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> 44 <div *ngIf="adduserFrm.controls.ConfirmPassword.value!=adduserFrm.controls.Password.value && adduserFrm.controls.ConfirmPassword.valid" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">
@@ -49,7 +49,7 @@ @@ -49,7 +49,7 @@
49 <div class="form-group"> 49 <div class="form-group">
50 <label for="inputPassword3" class="col-sm-4 control-label">Email Id <span class="red">*</span> :</label> 50 <label for="inputPassword3" class="col-sm-4 control-label">Email Id <span class="red">*</span> :</label>
51 <div class="col-sm-7"> 51 <div class="col-sm-7">
52 - <input type="text" class="form-control" id="inputPassword3" placeholder="Email Id" formControlName="EmailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$"> 52 + <input type="text" class="form-control" id="inputPassword3" placeholder="Email Id" formControlName="EmailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$" (keydown.space)="$event.preventDefault();">
53 <div *ngIf="adduserFrm.controls.EmailId.invalid && !adduserFrm.controls.EmailId.value && adduserFrm.controls.EmailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div> 53 <div *ngIf="adduserFrm.controls.EmailId.invalid && !adduserFrm.controls.EmailId.value && adduserFrm.controls.EmailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div>
54 54
55 <div *ngIf="adduserFrm.controls.EmailId.invalid && adduserFrm.controls.EmailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> 55 <div *ngIf="adduserFrm.controls.EmailId.invalid && adduserFrm.controls.EmailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">
400-SOURCECODE/Admin/src/app/components/UserEntity/adduser.component.ts
@@ -47,12 +47,12 @@ export class AddUser implements OnInit { @@ -47,12 +47,12 @@ export class AddUser implements OnInit {
47 this.alerts = ''; 47 this.alerts = '';
48 this.adduserFrm = this.fb.group({ 48 this.adduserFrm = this.fb.group({
49 id: [''], 49 id: [''],
50 - UserName: ['', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]],  
51 - Password: ['', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]],  
52 - ConfirmPassword: ['', [Validators.required,this.ClearWhitespaceValidator]], 50 + UserName: ['', [Validators.required, Validators.minLength(8)]],
  51 + Password: ['', [Validators.required, Validators.minLength(8)]],
  52 + ConfirmPassword: ['', [Validators.required]],
53 FirstName: ['', [Validators.required,this.noWhitespaceValidator]], 53 FirstName: ['', [Validators.required,this.noWhitespaceValidator]],
54 LastName: ['', [Validators.required,this.noWhitespaceValidator]], 54 LastName: ['', [Validators.required,this.noWhitespaceValidator]],
55 - EmailId: ['', [Validators.required,this.ClearWhitespaceValidator]], 55 + EmailId: ['', [Validators.required]],
56 AccountNumberId: ['', Validators.required], 56 AccountNumberId: ['', Validators.required],
57 UserTypeId: ['', Validators.required], 57 UserTypeId: ['', Validators.required],
58 ProductEditionId: ['', Validators.required] 58 ProductEditionId: ['', Validators.required]
@@ -87,35 +87,7 @@ export class AddUser implements OnInit { @@ -87,35 +87,7 @@ export class AddUser implements OnInit {
87 redirect() { 87 redirect() {
88 this.router.navigate(['/']); 88 this.router.navigate(['/']);
89 } 89 }
90 - public ClearWhitespaceValidator(control: FormControl) {  
91 - // new validation for intial whaite space  
92 - //****Birendra *****/  
93 - var isValid=false;  
94 - if(control.value!=null)  
95 - {  
96 - var inputvalue=control.value;  
97 - var controlLen=inputvalue.length;  
98 - if(controlLen==undefined)//undefined for integer value  
99 - {  
100 - isValid=true;  
101 - }  
102 - else if(controlLen!=0)  
103 - {  
104 - const isWhitespace = controlLen!=inputvalue.trim().length;  
105 - isValid = !isWhitespace;  
106 - if(!isValid)  
107 - {  
108 - control.setValue(inputvalue.trim());  
109 -  
110 - }  
111 -  
112 - }  
113 - }  
114 - // can use also on page of input control  
115 - //  
116 - return isValid ? null: { 'whitespace': true };  
117 -  
118 - } 90 +
119 public noWhitespaceValidator(control: FormControl) { 91 public noWhitespaceValidator(control: FormControl) {
120 // new validation for intial whaite space 92 // new validation for intial whaite space
121 //****Birendra *****/ 93 //****Birendra *****/
@@ -263,12 +235,12 @@ export class AddUser implements OnInit { @@ -263,12 +235,12 @@ export class AddUser implements OnInit {
263 _buildForm(lcid) { 235 _buildForm(lcid) {
264 this.adduserFrm = this.fb.group({ 236 this.adduserFrm = this.fb.group({
265 id: [''], 237 id: [''],
266 - UserName: ['', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]],  
267 - Password: ['', [Validators.required, Validators.minLength(8),this.ClearWhitespaceValidator]],  
268 - ConfirmPassword: ['', [Validators.required,this.ClearWhitespaceValidator]], 238 + UserName: ['', [Validators.required, Validators.minLength(8)]],
  239 + Password: ['', [Validators.required, Validators.minLength(8)]],
  240 + ConfirmPassword: ['', [Validators.required]],
269 FirstName: ['', [Validators.required,this.noWhitespaceValidator]], 241 FirstName: ['', [Validators.required,this.noWhitespaceValidator]],
270 LastName: ['', [Validators.required,this.noWhitespaceValidator]], 242 LastName: ['', [Validators.required,this.noWhitespaceValidator]],
271 - EmailId: ['', [Validators.required,this.ClearWhitespaceValidator]], 243 + EmailId: ['', [Validators.required]],
272 AccountNumberId: ['', Validators.required], 244 AccountNumberId: ['', Validators.required],
273 UserTypeId: ['', Validators.required], 245 UserTypeId: ['', Validators.required],
274 ProductEditionId: ['', Validators.required] 246 ProductEditionId: ['', Validators.required]
400-SOURCECODE/Admin/src/app/components/UserEntity/updateuserprofile.component.html
@@ -37,7 +37,7 @@ @@ -37,7 +37,7 @@
37 <div class="form-group"> 37 <div class="form-group">
38 <label for="emailId" class="col-sm-4 control-label">Email Id <span class="red">*</span> :</label> 38 <label for="emailId" class="col-sm-4 control-label">Email Id <span class="red">*</span> :</label>
39 <div class="col-sm-7"> 39 <div class="col-sm-7">
40 - <input type="text" class="form-control" id="emailId" formControlName="emailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$"> 40 + <input type="text" class="form-control" id="emailId" formControlName="emailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$" (keydown.space)="$event.preventDefault();">
41 <div *ngIf="userFrm.controls.emailId.invalid && !userFrm.controls.emailId.value && userFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div> 41 <div *ngIf="userFrm.controls.emailId.invalid && !userFrm.controls.emailId.value && userFrm.controls.emailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div>
42 42
43 <div *ngIf="userFrm.controls.emailId.invalid && userFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> Email is Invalid. </div> 43 <div *ngIf="userFrm.controls.emailId.invalid && userFrm.controls.emailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> Email is Invalid. </div>
400-SOURCECODE/Admin/src/app/components/UserEntity/updateuserprofile.component.ts
@@ -48,7 +48,7 @@ export class UpdateUserProfile implements OnInit { @@ -48,7 +48,7 @@ export class UpdateUserProfile implements OnInit {
48 id: [''], 48 id: [''],
49 firstName: ['', [Validators.required,this.noWhitespaceValidator]], 49 firstName: ['', [Validators.required,this.noWhitespaceValidator]],
50 lastName: ['', [Validators.required,this.noWhitespaceValidator]], 50 lastName: ['', [Validators.required,this.noWhitespaceValidator]],
51 - emailId: ['', [Validators.required,this.noWhitespaceValidator]] 51 + emailId: ['', [Validators.required]]
52 52
53 }); 53 });
54 54
400-SOURCECODE/Admin/src/app/components/UserEntity/users.component.html
@@ -203,7 +203,7 @@ @@ -203,7 +203,7 @@
203 <div class="form-group"> 203 <div class="form-group">
204 <label for="inputEmail3" class="col-sm-5 control-label">User Name <span class="red">*</span> :</label> 204 <label for="inputEmail3" class="col-sm-5 control-label">User Name <span class="red">*</span> :</label>
205 <div class="col-sm-7"> 205 <div class="col-sm-7">
206 - <input type="text" class="form-control input-sm" id="name" placeholder="User Name" formControlName="UserName"> 206 + <input type="text" class="form-control input-sm" id="name" placeholder="User Name" formControlName="UserName" (keydown.space)="$event.preventDefault();">
207 <span class="help-block">(Minimum 8 characters)</span> 207 <span class="help-block">(Minimum 8 characters)</span>
208 <div *ngIf="!adduserFrm.controls.UserName.valid && adduserFrm.controls.UserName.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required</div> 208 <div *ngIf="!adduserFrm.controls.UserName.valid && adduserFrm.controls.UserName.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">User Name of minimum 8 characters is required</div>
209 </div> 209 </div>
@@ -211,7 +211,7 @@ @@ -211,7 +211,7 @@
211 <div class="form-group"> 211 <div class="form-group">
212 <label for="inputPassword3" class="col-sm-5 control-label">Password <span class="red">*</span> :</label> 212 <label for="inputPassword3" class="col-sm-5 control-label">Password <span class="red">*</span> :</label>
213 <div class="col-sm-7"> 213 <div class="col-sm-7">
214 - <input type="password" class="form-control input-sm" id="password" placeholder="" formControlName="Password"> 214 + <input type="password" class="form-control input-sm" id="password" placeholder="" formControlName="Password" (keydown.space)="$event.preventDefault();">
215 <span class="help-block">(Minimum 8 characters)</span> 215 <span class="help-block">(Minimum 8 characters)</span>
216 <div *ngIf="!adduserFrm.controls.Password.valid && adduserFrm.controls.Password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required</div> 216 <div *ngIf="!adduserFrm.controls.Password.valid && adduserFrm.controls.Password.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Password of minimum 8 characters is required</div>
217 </div> 217 </div>
@@ -219,7 +219,7 @@ @@ -219,7 +219,7 @@
219 <div class="form-group"> 219 <div class="form-group">
220 <label for="inputPassword3" class="col-sm-5 control-label">Confirm Password <span class="red">*</span> :</label> 220 <label for="inputPassword3" class="col-sm-5 control-label">Confirm Password <span class="red">*</span> :</label>
221 <div class="col-sm-7"> 221 <div class="col-sm-7">
222 - <input type="password" class="form-control input-sm" id="cpassword" placeholder="" formControlName="ConfirmPassword"> 222 + <input type="password" class="form-control input-sm" id="cpassword" placeholder="" formControlName="ConfirmPassword"(keydown.space)="$event.preventDefault();">
223 <div *ngIf="!adduserFrm.controls.ConfirmPassword.valid && !adduserFrm.controls.ConfirmPassword.value && adduserFrm.controls.ConfirmPassword.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Confirm Password is required</div> 223 <div *ngIf="!adduserFrm.controls.ConfirmPassword.valid && !adduserFrm.controls.ConfirmPassword.value && adduserFrm.controls.ConfirmPassword.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Confirm Password is required</div>
224 <div *ngIf="adduserFrm.controls.ConfirmPassword.value!=adduserFrm.controls.Password.value && adduserFrm.controls.ConfirmPassword.valid" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> 224 <div *ngIf="adduserFrm.controls.ConfirmPassword.value!=adduserFrm.controls.Password.value && adduserFrm.controls.ConfirmPassword.valid" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">
225 Password not match. 225 Password not match.
@@ -229,7 +229,7 @@ @@ -229,7 +229,7 @@
229 <div class="form-group"> 229 <div class="form-group">
230 <label for="inputPassword3" class="col-sm-5 control-label">Email Id <span class="red">*</span> :</label> 230 <label for="inputPassword3" class="col-sm-5 control-label">Email Id <span class="red">*</span> :</label>
231 <div class="col-sm-7"> 231 <div class="col-sm-7">
232 - <input type="text" class="form-control" id="inputPassword3" placeholder="Email Id" formControlName="EmailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$"> 232 + <input type="text" class="form-control" id="inputPassword3" placeholder="Email Id" formControlName="EmailId" pattern="[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,3}$" (keydown.space)="$event.preventDefault();">
233 <div *ngIf="adduserFrm.controls.EmailId.invalid && !adduserFrm.controls.EmailId.value && adduserFrm.controls.EmailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div> 233 <div *ngIf="adduserFrm.controls.EmailId.invalid && !adduserFrm.controls.EmailId.value && adduserFrm.controls.EmailId.dirty" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">Email Id is required</div>
234 234
235 <div *ngIf="adduserFrm.controls.EmailId.invalid && adduserFrm.controls.EmailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;"> 235 <div *ngIf="adduserFrm.controls.EmailId.invalid && adduserFrm.controls.EmailId.value" class="alert alert-danger" style="padding: 2px; margin-bottom: 2px;">
400-SOURCECODE/Admin/src/app/components/UserEntity/users.component.ts
@@ -105,12 +105,12 @@ export class UsersList implements OnInit, AfterViewChecked { @@ -105,12 +105,12 @@ export class UsersList implements OnInit, AfterViewChecked {
105 }); 105 });
106 this.adduserFrm = this.fb.group({ 106 this.adduserFrm = this.fb.group({
107 id: [''], 107 id: [''],
108 - UserName: ['', [Validators.required, Validators.minLength(8),this.noWhitespaceValidator]],  
109 - Password: ['', [Validators.required, Validators.minLength(8),this.noWhitespaceValidator]],  
110 - ConfirmPassword: ['', [Validators.required,this.noWhitespaceValidator]], 108 + UserName: ['', [Validators.required, Validators.minLength(8)]],
  109 + Password: ['', [Validators.required, Validators.minLength(8)]],
  110 + ConfirmPassword: ['', [Validators.required]],
111 FirstName: ['', [Validators.required,this.noWhitespaceValidator]], 111 FirstName: ['', [Validators.required,this.noWhitespaceValidator]],
112 LastName: ['', [Validators.required,this.noWhitespaceValidator]], 112 LastName: ['', [Validators.required,this.noWhitespaceValidator]],
113 - EmailId: ['', [Validators.required,this.noWhitespaceValidator]], 113 + EmailId: ['', [Validators.required]],
114 AccountNumber: [''], 114 AccountNumber: [''],
115 UserTypeTitle: [''], 115 UserTypeTitle: [''],
116 AccountTypeTitle: [''], 116 AccountTypeTitle: [''],