From 29af2d5999a91214f5eee5b40373dc6b96e1683c Mon Sep 17 00:00:00 2001 From: John Woodlock Date: Wed, 9 Jan 2013 18:15:06 +0000 Subject: [PATCH] ensure datatables update/delete has the url put into the audit table --- .../commands/service/CommandWrapperBuilder.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/mifosng-provider/src/main/java/org/mifosplatform/commands/service/CommandWrapperBuilder.java b/mifosng-provider/src/main/java/org/mifosplatform/commands/service/CommandWrapperBuilder.java index 45f9d76dd..d68aea744 100644 --- a/mifosng-provider/src/main/java/org/mifosplatform/commands/service/CommandWrapperBuilder.java +++ b/mifosng-provider/src/main/java/org/mifosplatform/commands/service/CommandWrapperBuilder.java @@ -316,6 +316,11 @@ public class CommandWrapperBuilder { this.datatableId = datatableId; this.actionName = "UPDATE"; this.entityName = datatable; + if (datatableId == null) { + this.href = "/datatables/" + datatable + "/" + apptableId; + } else { + this.href = "/datatables/" + datatable + "/" + apptableId + "/" + datatableId; + } return this; } @@ -324,6 +329,11 @@ public class CommandWrapperBuilder { this.datatableId = datatableId; this.actionName = "DELETE"; this.entityName = datatable; + if (datatableId == null) { + this.href = "/datatables/" + datatable + "/" + apptableId; + } else { + this.href = "/datatables/" + datatable + "/" + apptableId + "/" + datatableId; + } return this; }