Skip to content

Commit 522230e

Browse files
committed
#2177 update ValidateAntiForgeryToken in datastructure controller
1 parent 1c3e30e commit 522230e

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Console/BExIS.Web.Shell/Areas/RPM/BExIS.Modules.Rpm.UI/Controllers/DataStructureController.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public JsonResult DataStructures()
6363
return Json(tmp.ToArray(), JsonRequestBehavior.AllowGet);
6464
}
6565

66-
[HttpPost]
66+
[HttpPost, CustomValidateAntiForgeryToken]
6767
public JsonResult Upload()
6868
{
6969
if (Request.Files.Count > 0)
@@ -171,7 +171,7 @@ public ActionResult Edit(long structureId = 0)
171171

172172

173173
[JsonNetFilter]
174-
[HttpPost]
174+
[HttpPost, ValidateAntiForgeryToken]
175175
public JsonResult Create(DataStructureCreationModel model)
176176
{
177177
if (model == null) throw new ArgumentNullException(nameof(model));
@@ -264,7 +264,7 @@ public JsonResult Create(DataStructureCreationModel model)
264264
}
265265

266266
[JsonNetFilter]
267-
[HttpPost]
267+
[HttpPost, ValidateAntiForgeryToken]
268268
public JsonResult Save(DataStructureEditModel model)
269269
{
270270
if (model == null) throw new ArgumentNullException(nameof(model));
@@ -381,7 +381,7 @@ public JsonResult Save(DataStructureEditModel model)
381381

382382

383383
[JsonNetFilter]
384-
[HttpPost]
384+
[HttpPost, ValidateAntiForgeryToken]
385385
public JsonResult Generate(DataStructureCreationModel model)
386386
{
387387

@@ -613,7 +613,7 @@ public JsonResult Copy(long id)
613613
}
614614

615615
[JsonNetFilter]
616-
[HttpPost]
616+
[HttpPost, ValidateAntiForgeryToken]
617617
public JsonResult Delete(long id)
618618
{
619619
if (id <= 0) throw new NullReferenceException("id of the data structure should be greater then 0");
@@ -635,7 +635,7 @@ public JsonResult Delete(long id)
635635
}
636636

637637
[JsonNetFilter]
638-
[HttpPost]
638+
[HttpPost, ValidateAntiForgeryToken]
639639
public JsonResult CheckPrimaryKeySet(long id, long[] primaryKeys)
640640
{
641641
if (id <= 0) throw new ArgumentNullException("id");

0 commit comments

Comments
 (0)