[
https://issues.apache.org/jira/browse/FINERACT-618?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16704350#comment-16704350
]
ASF GitHub Bot commented on FINERACT-618:
-----------------------------------------
ShruthiRajaram closed pull request #494: FINERACT-618 Allow for Submitted On
Date to be Edited for Groups
URL: https://github.com/apache/fineract/pull/494
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git
a/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/domain/Group.java
b/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/domain/Group.java
index b0874ce7d..1ef191105 100644
---
a/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/domain/Group.java
+++
b/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/domain/Group.java
@@ -345,6 +345,18 @@ public boolean isPending() {
this.accountNumber = StringUtils.defaultIfEmpty(newValue, null);
}
+ if
(command.isChangeInLocalDateParameterNamed(GroupingTypesApiConstants.submittedOnDateParamName,
getSubmittedOnDate())) {
+ final String valueAsInput =
command.stringValueOfParameterNamed(GroupingTypesApiConstants.submittedOnDateParamName);
+
actualChanges.put(GroupingTypesApiConstants.submittedOnDateParamName,
valueAsInput);
+ actualChanges.put(GroupingTypesApiConstants.dateFormatParamName,
dateFormatAsInput);
+ actualChanges.put(GroupingTypesApiConstants.localeParamName,
localeAsInput);
+
+ final LocalDate newValue =
command.localDateValueOfParameterNamed(GroupingTypesApiConstants.submittedOnDateParamName);
+ if (newValue != null) {
+ this.submittedOnDate = newValue.toDate();
+ }
+ }
+
return actualChanges;
}
diff --git
a/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/serialization/GroupingTypesDataValidator.java
b/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/serialization/GroupingTypesDataValidator.java
index a3184f254..af0686066 100755
---
a/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/serialization/GroupingTypesDataValidator.java
+++
b/fineract-provider/src/main/java/org/apache/fineract/portfolio/group/serialization/GroupingTypesDataValidator.java
@@ -374,6 +374,12 @@ public void validateForUpdateGroup(final JsonCommand
command) {
}
}
+ if
(this.fromApiJsonHelper.parameterExists(GroupingTypesApiConstants.submittedOnDateParamName,
element)) {
+ final LocalDate submittedOnDate =
this.fromApiJsonHelper.extractLocalDateNamed(
+ GroupingTypesApiConstants.submittedOnDateParamName,
element);
+
baseDataValidator.reset().parameter(GroupingTypesApiConstants.submittedOnDateParamName).value(submittedOnDate).notNull();
+ }
+
throwExceptionIfValidationWarningsExist(dataValidationErrors);
}
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Allow for Submitted On Date to be Edited for Groups
> ---------------------------------------------------
>
> Key: FINERACT-618
> URL: https://issues.apache.org/jira/browse/FINERACT-618
> Project: Apache Fineract
> Issue Type: Improvement
> Components: Groups
> Affects Versions: 1.1.0
> Reporter: Edward Cable
> Assignee: Shruthi M R
> Priority: Minor
> Labels: GCI, Newbie, Volunteer, beginner, gsoc, p1
> Fix For: 1.3.0
>
>
> Just as one can edit the submitted on date for a client after it's been
> created, so should a user be able to edit the submitted on date for a group
> after it's been created.
> Corresponding UI ticket on Github Issues for Mifos X Web App.
> As requested by Diane on the mailing list at
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)