Пример #1
0
 /// <summary>
 /// Create a new UpcmomingSurveyor object.
 /// </summary>
 /// <param name="surApp_Id">Initial value of the SurApp_Id property.</param>
 public static UpcmomingSurveyor CreateUpcmomingSurveyor(global::System.Int32 surApp_Id)
 {
     UpcmomingSurveyor upcmomingSurveyor = new UpcmomingSurveyor();
     upcmomingSurveyor.SurApp_Id = surApp_Id;
     return upcmomingSurveyor;
 }
Пример #2
0
 public void UpdateRecord(string FirstName, string Lastname, int applyAsrole, string password, string emailId)
 {
     // int result = 0;
     using (ROPAEntities context = new ROPAEntities())
     {
         UpcmomingSurveyor obj = new UpcmomingSurveyor();
         obj.FirstName = FirstName;
         obj.LastName = Lastname;
         obj.ApplyAsRole = applyAsrole;
         obj.Password = password;
         obj.EMAILID = emailId;
         obj.ModifedDate = DateTime.Now;
         obj.AppId = 2;
        // context.AddToUpcmomingSurveyors(obj);
        // result=
             context.SaveChanges();
        // return result;
     }
 }
Пример #3
0
 /// <summary>
 /// Deprecated Method for adding a new object to the UpcmomingSurveyors EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToUpcmomingSurveyors(UpcmomingSurveyor upcmomingSurveyor)
 {
     base.AddObject("UpcmomingSurveyors", upcmomingSurveyor);
 }
Пример #4
0
 public int InsertRecord(string FirstName, string Lastname, int applyAsrole, string password, string emailId, List<UploadFile> L)
 {
     int result = 0;
      using (ROPAEntities context = new ROPAEntities())
     {
         UpcmomingSurveyor obj = new UpcmomingSurveyor();
         obj.FirstName = FirstName;
         obj.LastName = Lastname;
         obj.ApplyAsRole = applyAsrole;
         obj.Password = password;
         obj.AppId = 1;
         obj.ModifedDate = DateTime.Now;
         obj.EMAILID = emailId;
         context.AddToUpcmomingSurveyors(obj);
         foreach (UploadFile G in L)
         {
             UploadFiles  Upld = new UploadFiles();
             string s = G.GUID;
             var Q = (from u in context.UploadFiles where u.GUID ==s  select u).FirstOrDefault();
             Q.SurApp_Id = obj.SurApp_Id;
         }
        context.SaveChanges();
        return result;
     }
 }