diff --git a/build.gradle b/build.gradle index c21075fcd6b..aa541da18d1 100644 --- a/build.gradle +++ b/build.gradle @@ -51,7 +51,8 @@ buildscript { 'fineract-e2e-tests-core', 'fineract-e2e-tests-runner', 'fineract-progressive-loan', - 'fineract-progressive-loan-embeddable-schedule-generator' + 'fineract-progressive-loan-embeddable-schedule-generator', + 'fineract-working-capital-loan' ].contains(it.name) } fineractPublishProjects = subprojects.findAll{ @@ -77,7 +78,8 @@ buildscript { 'fineract-branch', 'fineract-document', 'fineract-progressive-loan', - 'fineract-progressive-loan-embeddable-schedule-generator' + 'fineract-progressive-loan-embeddable-schedule-generator', + 'fineract-working-capital-loan' ].contains(it.name) } npmRepository = 'https://npm.pkg.github.com' diff --git a/fineract-progressive-loan/src/main/resources/jpa/static-weaving/module/fineract-progressive-loan/persistence.xml b/fineract-progressive-loan/src/main/resources/jpa/static-weaving/module/fineract-progressive-loan/persistence.xml index f3d4b2ed2b6..b62846adc3a 100644 --- a/fineract-progressive-loan/src/main/resources/jpa/static-weaving/module/fineract-progressive-loan/persistence.xml +++ b/fineract-progressive-loan/src/main/resources/jpa/static-weaving/module/fineract-progressive-loan/persistence.xml @@ -145,9 +145,7 @@ org.apache.fineract.portfolio.floatingrates.domain.FloatingRatePeriod - org.apache.fineract.portfolio.loanaccount.domain.LoanBuyDownFeeBalance - org.apache.fineract.portfolio.loanaccount.domain.LoanCapitalizedIncomeBalance - org.apache.fineract.portfolio.loanaccount.domain.ProgressiveLoanModel + false diff --git a/fineract-provider/dependencies.gradle b/fineract-provider/dependencies.gradle index 08cf0a95cff..35b5daee841 100644 --- a/fineract-provider/dependencies.gradle +++ b/fineract-provider/dependencies.gradle @@ -41,6 +41,7 @@ dependencies { implementation(project(path: ':fineract-tax')) implementation(project(path: ':fineract-loan-origination')) implementation(project(path: ':fineract-security')) + implementation(project(path: ':fineract-working-capital-loan')) providedRuntime("org.springframework.boot:spring-boot-starter-tomcat") diff --git a/fineract-provider/src/main/resources/db/changelog/db.changelog-master.xml b/fineract-provider/src/main/resources/db/changelog/db.changelog-master.xml index d83add9c8ee..abdad7398a1 100644 --- a/fineract-provider/src/main/resources/db/changelog/db.changelog-master.xml +++ b/fineract-provider/src/main/resources/db/changelog/db.changelog-master.xml @@ -39,6 +39,7 @@ + diff --git a/fineract-war/build.gradle b/fineract-war/build.gradle index da34c147c2e..bd98f88280d 100644 --- a/fineract-war/build.gradle +++ b/fineract-war/build.gradle @@ -90,6 +90,7 @@ dependencies { implementation project(':fineract-progressive-loan') implementation project(':fineract-savings') implementation project(':fineract-provider') + implementation project(':fineract-working-capital-loan') } tasks.withType(Tar) { diff --git a/fineract-working-capital-loan/build.gradle b/fineract-working-capital-loan/build.gradle new file mode 100644 index 00000000000..677a52909e6 --- /dev/null +++ b/fineract-working-capital-loan/build.gradle @@ -0,0 +1,83 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +description = 'Fineract Working Capital Loan' + +apply plugin: 'java' +apply plugin: 'eclipse' + +compileJava { + dependsOn ':fineract-avro-schemas:buildJavaSdk' +} + +configurations { + providedRuntime // needed for Spring Boot executable WAR + providedCompile + compile() { + exclude module: 'hibernate-entitymanager' + exclude module: 'hibernate-validator' + exclude module: 'activation' + exclude module: 'bcmail-jdk14' + exclude module: 'bcprov-jdk14' + exclude module: 'bctsp-jdk14' + exclude module: 'c3p0' + exclude module: 'stax-api' + exclude module: 'jaxb-api' + exclude module: 'jaxb-impl' + exclude module: 'jboss-logging' + exclude module: 'itext-rtf' + exclude module: 'classworlds' + } + runtime +} + +apply from: 'dependencies.gradle' + +// Configuration for the modernizer plugin +// https://github.com/andygoossens/gradle-modernizer-plugin +modernizer { + ignoreClassNamePatterns = [ + '.*AbstractPersistableCustom', + '.*EntityTables', + '.*domain.*' + ] +} + +// If we are running Gradle within Eclipse to enhance classes with OpenJPA, +// set the classes directory to point to Eclipse's default build directory +if (project.hasProperty('env') && project.getProperty('env') == 'eclipse') { + sourceSets.main.java.outputDir = new File(rootProject.projectDir, "fineract-working-capital-loan/bin/main") +} + +eclipse { + project { + buildCommand([ LaunchConfigHandle: "/.externalToolBuilders/OpenJPA Enhance Builder.launch" ], 'org.eclipse.ui.externaltools.ExternalToolBuilder') + } +} + +if (!(project.hasProperty('env') && project.getProperty('env') == 'dev')) { + sourceSets { + test { + java { + exclude '**/core/boot/tests/**' + } + } + } +} + + diff --git a/fineract-working-capital-loan/dependencies.gradle b/fineract-working-capital-loan/dependencies.gradle new file mode 100644 index 00000000000..35563ba3059 --- /dev/null +++ b/fineract-working-capital-loan/dependencies.gradle @@ -0,0 +1,28 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +dependencies { + implementation('org.apache.avro:avro') + implementation( + project(path: ':fineract-avro-schemas') + ) + implementation('org.eclipse.persistence:org.eclipse.persistence.jpa') { + exclude group: 'org.eclipse.persistence', module: 'jakarta.persistence' + } +} diff --git a/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoan.java b/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoan.java new file mode 100644 index 00000000000..8c454b97e2c --- /dev/null +++ b/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoan.java @@ -0,0 +1,23 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.fineract.portfolio.workingcapitalloanproduct.domain; + +public class WorkingCapitalLoan { + +} diff --git a/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoanProduct.java b/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoanProduct.java new file mode 100644 index 00000000000..be69c6990fe --- /dev/null +++ b/fineract-working-capital-loan/src/main/java/org/apache/fineract/portfolio/workingcapitalloanproduct/domain/WorkingCapitalLoanProduct.java @@ -0,0 +1,23 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.fineract.portfolio.workingcapitalloanproduct.domain; + +public class WorkingCapitalLoanProduct { + +} diff --git a/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/module-changelog-master.xml b/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/module-changelog-master.xml new file mode 100644 index 00000000000..6bc107ecab9 --- /dev/null +++ b/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/module-changelog-master.xml @@ -0,0 +1,26 @@ + + + + + diff --git a/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/parts/0001_initial_schema.xml b/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/parts/0001_initial_schema.xml new file mode 100644 index 00000000000..b85a3489f4e --- /dev/null +++ b/fineract-working-capital-loan/src/main/resources/db/changelog/tenant/module/workingcapitalloan/parts/0001_initial_schema.xml @@ -0,0 +1,26 @@ + + + + + diff --git a/fineract-working-capital-loan/src/main/resources/jpa/static-weaving/module/fineract-working-capital-loan/persistence.xml b/fineract-working-capital-loan/src/main/resources/jpa/static-weaving/module/fineract-working-capital-loan/persistence.xml new file mode 100644 index 00000000000..3ee3dd86491 --- /dev/null +++ b/fineract-working-capital-loan/src/main/resources/jpa/static-weaving/module/fineract-working-capital-loan/persistence.xml @@ -0,0 +1,41 @@ + + + + + + + + + + org.eclipse.persistence.jpa.PersistenceProvider + + + + false + + + + + diff --git a/settings.gradle b/settings.gradle index 892be9e67f4..07151345a06 100644 --- a/settings.gradle +++ b/settings.gradle @@ -76,6 +76,7 @@ include ':fineract-e2e-tests-core' include ':fineract-e2e-tests-runner' include 'fineract-progressive-loan' include 'fineract-progressive-loan-embeddable-schedule-generator' +include 'fineract-working-capital-loan' // NOTE: custom Docker image with all custom modules included include ':custom:docker' // NOTE: dynamically load custom modules with pattern "custom -> company -> category -> module"