예제 #1
0
 public ActionResult Verification()
 {
     var newVerification = new VerificationNew()
     {
         info = GlobalRes.VerificationInfo,
         proof = GlobalRes.VerificationProof
     };
     return View(newVerification);
 }
예제 #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);
 }
예제 #3
0
파일: DataBase.cs 프로젝트: kioltk/mvc
 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;
 }