コード例 #1
0
 public IActionResult OnManageRecord(EntityRecord record, Entity entity, RecordManagePageModel pageModel)
 {
     pageModel.TempData.Put("ScreenMessage", new ScreenMessage()
     {
         Message = "Hook on manage record was executed. This is hooks test and nothing is update."
     });
     return(null);
 }
コード例 #2
0
 public IActionResult OnPostManageRecord(EntityRecord record, Entity entity, RecordManagePageModel pageModel)
 {
     pageModel.TempData.Put("ScreenMessage", new ScreenMessage()
     {
         Message = "Record is updated successfully"
     });
     return(null);
 }
コード例 #3
0
 public IActionResult OnPreManageRecord(EntityRecord record, Entity entity, RecordManagePageModel pageModel, List <ValidationError> validationErrors)
 {
     if (record.Properties.ContainsKey("text"))
     {
         if (record["text"] as string == "123")
         {
             validationErrors.Add(new ValidationError("text", "123 value is not permitted"));
         }
     }
     return(null);
 }