/// <summary>
 /// Generates the matrix for A new user.
 /// </summary>
 /// <param name="userID">The user ID.</param>
 public void GenerateMatrixForANewUser(int userID)
 {
     BLL.Activity store = new Activity();
     store.LoadAll();
     while (!store.EOF)
     {
         BLL.UserActivity usrStore = new UserActivity();
         usrStore.AddNew();
         usrStore.UserID = userID;
         usrStore.ActivityID = store.ID;
         usrStore.CanAccess = false;
         usrStore.IsDefault = false;
         usrStore.Save();
         store.MoveNext();
     }
 }
示例#2
0
 /// <summary>
 /// Generates the matrix for A new user.
 /// </summary>
 /// <param name="userID">The user ID.</param>
 public void GenerateMatrixForANewUser(int userID)
 {
     BLL.Activity store = new Activity();
     store.LoadAll();
     while (!store.EOF)
     {
         BLL.UserActivity usrStore = new UserActivity();
         usrStore.AddNew();
         usrStore.UserID     = userID;
         usrStore.ActivityID = store.ID;
         usrStore.CanAccess  = false;
         usrStore.IsDefault  = false;
         usrStore.Save();
         store.MoveNext();
     }
 }
示例#3
0
 /// <summary>
 /// Renews the matrix for A user.
 /// </summary>
 /// <param name="userID">The user ID.</param>
 public void RenewMatrixForAUser(int userID)
 {
     BLL.Activity store = new Activity();
     store.LoadAll();
     while (!store.EOF)
     {
         BLL.UserActivity usrStore = new UserActivity();
         this.LoadByUserAndStoreID(userID, store.ID);
         if (this.RowCount == 0)
         {
             usrStore.AddNew();
             usrStore.UserID     = userID;
             usrStore.ActivityID = store.ID;
             usrStore.CanAccess  = false;
             usrStore.IsDefault  = false;
             usrStore.Save();
         }
         store.MoveNext();
     }
 }
 /// <summary>
 /// Renews the matrix for A user.
 /// </summary>
 /// <param name="userID">The user ID.</param>
 public void RenewMatrixForAUser(int userID)
 {
     BLL.Activity store = new Activity();
     store.LoadAll();
     while (!store.EOF)
     {
         BLL.UserActivity usrStore = new UserActivity();
         this.LoadByUserAndStoreID(userID,store.ID);
         if (this.RowCount == 0)
         {
             usrStore.AddNew();
             usrStore.UserID = userID;
             usrStore.ActivityID = store.ID;
             usrStore.CanAccess = false;
             usrStore.IsDefault = false;
             usrStore.Save();
         }
         store.MoveNext();
     }
 }