Esempio n. 1
0
 public ActionResult Verification()
 {
     var newVerification = new VerificationNew()
     {
         info = GlobalRes.VerificationInfo,
         proof = GlobalRes.VerificationProof
     };
     return View(newVerification);
 }
Esempio n. 2
0
 public ActionResult Verification(VerificationNew newVerification)
 {
     if (ModelState.IsValid)
     {
         newVerification.owner = DataBase.Account.Get(Request.Cookies["access_token"].Value).ID;
         if (DataBase.Verifications.create(newVerification))
             return View("VerificationSended");
     }
     return View("Verification", newVerification);
 }
Esempio n. 3
0
 public static bool create(VerificationNew newVerification)
 {
     var newDBVerification = new verifications()
     {
         info = newVerification.info,
         proof = newVerification.proof,
         photo = newVerification.photo,
         owner = newVerification.owner,
         status = "new",
         type = newVerification.type,
         date = Time.UNIXNow()
     };
     try
     {
         context.verifications.InsertOnSubmit(newDBVerification);
         return Save();
     }
     catch (Exception exp)
     {
     }
     return false;
 }