Git Product home page Git Product logo

openmf / community-app Goto Github PK

View Code? Open in Web Editor NEW
310.0 58.0 1.0K 52.07 MB

This was the former default web application built on top of the Apache Fineract platform. It's now deprecated and replaced by the the Mifos X Web App (https://github.com/openMF/web-app maintained by the Mifos Initiative as a reference solution for financial inclusion. It is a Single-Page App (SPA) written in web standard technologies.

Home Page: http://openmf.github.io/community-app/

License: Mozilla Public License 2.0

HTML 52.23% JavaScript 35.98% CSS 10.63% Shell 0.01% Ruby 0.01% Dockerfile 0.01% SCSS 1.14%
hacktoberfest

community-app's Introduction

MifosX Community App Join the chat at https://gitter.im/openMF/community-app Build Status Docker Hub Docker Build

This is the default web application built on top of the MifosX platform for the mifos user community. It is a Single-Page App (SPA) written in web standard technologies like JavaScript, CSS and HTML5. It leverages common popular frameworks/libraries such as AngularJS, Bootstrap and Font Awesome.

Getting started / Online Demo

The latest version of this UI is continuously re-deployed immediately (CI/CD) at openmf.github.io/community-app every time a Pull Request with a new feature or bugfix is merged. You should always specify the backend via baseApiUrl (see details below), so for example to access the https://www.fineract.dev online demo environment, use:

https://openmf.github.io/community-app?baseApiUrl=https://demo.fineract.dev&tenantIdentifier=default

Building from source

  1. Ensure you have

Note: On Ubuntu Linux you can use sudo apt-get install npm nodejs-legacy, which avoids the /usr/bin/env: node: No such file or directory problem.

Note that on Linux distributions you'll need to install the Ruby Development package (e.g. sudo dnf install ruby-devel on Fedora), and not just ruby, otherwise bundle install below will fail when it gets to installing ffi which uses native extensions.

  1. Clone this repository to your local filesystem (default branch is 'develop'):

     git clone https://github.com/openMF/community-app.git
    
  2. To download the dependencies, and be able to build, first install bower & grunt:

     npm install -g bower
     npm install -g grunt-cli
    

If this fails with npm WARN checkPermissions Missing write access to /usr/local/lib and npm ERR! code EACCES because you are not running npm with sudo as root (which you rightfully really shouldn't!) then use npm config set prefix ~ once before doing npm install. Note that in that case bower and grunt will be installed into ./bin/bower instead of /usr/local/bin, and so you need to prefix it in the usages below.

  1. Next pull the runtime and build time dependencies by running bower, npm, and gem commands on the project root folder:

     bower install
    

For Windows PC, before you run npm install check in the root folder if any package-lock.json is generated and delete it then you can run npm install other wise you will be faced with Npm ERR! code EPERM error errno -4048 error { Error: EPERM: operation not permitted, rename .... a permission error even if you are using administrator user

 npm install
 gem install bundler
 bundle install

If you used npm config set prefix ~, then you have to use ./bin/bower install instead of bower install.

  1. To preview the app, run the following command on the project root folder:

     grunt serve
    

    If you used npm config set prefix ~, then you have to use ./bin/grunt serve instead of grunt serve.

    or open the 'index.html' file in FIREFOX browser

    Note: If you see a warning similar to the one shown below on running grunt serve , try increasing the number of open files limit as per the suggestions at http://stackoverflow.com/questions/34588/how-do-i-change-the-number-of-open-files-limit-in-linux/

     Waiting...Warning: EMFILE, too many open files
    
    
  2. You can use these credentials to log in:

     Username: mifos
     Password: password
    

You are done.

Connecting to a MifosX Platform using OAuth 2 authentication:

Edit the value of property "security" in configurations.js to "oauth".

Connecting to a MifosX Platform running on a different host:

By default, when the app is running from the local filesystem, it will connect to the platform (fineract-provider REST API) deployed on demo.mifos.io, but that environment is no longer actively updated; we recommend using https://www.fineract.dev instead, as above.

The app connects to the platform running on the same host/port when deployed on a server.

If you want to connect to the Fineract API running elsewhere, then append the baseApiUrl and tenantIdentifier as query parameters, for example:

Adding dependencies

You can also add more dependencies on bower.json. You can search for them in http://sindresorhus.com/bower-components/ or even:

bower search <package>

Running grunt tasks

Grunt tasks are used to automate repetitive tasks like minification, compilation, unit testing, linting, production builds, etc

Following are the tasks integrated.

Validate JS and HTML files

Validate the JS files to detect errors and potential problems in JavaScript code. All errors output will be written to jshint-log.xml file which get created under project base directory. Checks the markup validity of HTML files. All errors output will be written to console.

grunt validate

Build

Build the code for production deployment.

grunt prod

Serve

Use this for development. Start a static server and open the project in the default browser. The application will hit the demo server.

grunt serve

Docker

This project publishes a Docker image (since #3112) available on https://hub.docker.com/r/openmf/community-app/. Our Dockerfile uses a Ruby and Node.JS base image to build the current repo and deploy the app on Nginx, which is exposed on port 80 within the container. It can be used like this to access the webapp on http://localhost:9090 in your browser:

docker run --name community-app -it -p 9090:80 openmf/community-app

To locally build this Docker image from source (after git clone this repo), run:

docker build -t mifos-community-app .

You can then run a Docker Container from the image above like this:

docker run --name mifos-ui -it -d -p 80:80 mifos-community-app

Access the webapp on http://localhost in your browser.

Compile sass to css

grunt compass:dev

Running the tests

Just open test/SpecRunner.html in the browser.

Getting Started doc

https://docs.google.com/document/d/1oXQ2mNojyDFkY_x4RBRPaqS-xhpnDE9coQnbmI3Pobw/edit#heading=h.vhgp8hu9moqn

Contribution guidelines

Please read the contribution guidelines

Note: This application will hit the demo server by default.

community-app's People

Contributors

abhaychawla avatar alexivanov avatar anh3h avatar ankit01ojha avatar botraunak avatar chandrikamohith avatar ckomlo avatar dancarl857 avatar gauravsaini03 avatar gkrishnan724 avatar goutham-m avatar hhartono avatar mauliksoneji avatar mbj36 avatar mifoscontributer avatar muddlebee avatar mykatz avatar nayan avatar nazeer1100126 avatar pramodn02 avatar rajuan avatar renovate[bot] avatar sachinkulkarni12 avatar safiyu avatar shruthirajaram avatar siebrand avatar smontanari avatar translatewiki avatar vishwasbabu avatar vorburger avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

community-app's Issues

Not able to create Datatable

Test Data:
Create datatable for client with the following datasets.
Datatable Name: Client_PI
Application Table Name: Client
Add Columns:
Column Name: City - String - with string length 15
Column Name: Gender - Dropdown - from dropdown select Gender.

Pre-Condition:
Create Gender in Code and add code value as Male, Female

Description:
Click on administration -> System -> Manage Datatable ->Create datatable -> In create datatable enver valid inputs and click on save button.

Expected Result:
Datatable should get created for defined application name

Actual Result:
Not able to save the created datatable since it is asking for the "Required field".
Uploading TC-204 -Sheet001 ON 13.11.2013.png . . .

In Center, Savings Reject - Cancel button is not working as expected

Data:

  1. Click on centers>Select center>Click on center savings application>Enter valid inputs & save.
  2. Click on Reject> Enter date of transaction> then click on cancel.

Expected result:
Savings application should not be rejected on clicking on cancel.

Actual
Savings application gets rejected on clicking on cancel button.

1
2
3

Center - Transfer funds not working

Expected result:
Should display Transfer funds page on clicking on should be open Transfer funds button.

Actual result
Transfer funds page not displayed on clicking on Transfer funds button.

1

Not able to approve Group Loan

  1. Submit a Group Loan application on 01 November 2013.
  2. Click on the Group Loan under pending approval state.

Expected Result:
Approve tab should be displayed and should be able to display.

Actual Result:
Approve tab is not displaying in Group loan page.
Similarly Not able to approve client Loan also.
tc-208 -sheet001 on 15 11 2013
tc-208 -sheet002 on 15 11 2013

Set up Travis.ci

See here for more information- https://travis-ci.org/

This would be a great tool to use for this project.

I'm happy to work on this in the next week- I don't personally experience setting this up, so if someone else does/wants to get started, please feel free.

In Group Savings - Not able to add charge on a specified due date

  1. Create a charge on a specified due date for savings.
  2. Click on Groups -> Group -> Select the created Group -> Click on the Group Savings application ->Select the product -> In New Savings appplication page fill all the required field and and add charge on specified due date
    Expected result:
    Charge on specified due date should get attached to the application and field of specified due date should get displayed.

Actual Result:
Not able to select the date because of that not able to submit the Group savings application.
tc-211 -sheet001on 15 11 2013

Issues related to loan

  1. Not able to add a loan charge with payment mode account transfer.
  2. waive and pay loan charge is missing in charges section of a active loan
  3. not able to add accounting rules to a loan product

Client closing is allowing for future dates

Test data:
Close client on future date

Pre-Conditions:
Create a Client with Activation date: present system date

Descriptions:
1.Click on the Clients -> Select the created Client -> Click on the Close button
2. In close page provide future date from the present system date,enter closure reason and click on save button.

Expected result:

  1. Client closings should not be allowed for future date.

Actual result:

  1. It is allowing client closings for future dates.

Unable to add a charge to active savings account

In the reference UI, we have the ability to added charges to active savings accounts.

This functionality seems to be missed on in the community app (maybe just the add savings charge button when the account is in active state, since the button to add charges is present before the account is activate)

Unable to upload client document

Pre-Conditions:
Create a Client.

Descriptions:
1.Click on the Clients >> Select the created Client >> Click on document tab >> click on upload button
2. In Upload Client Document page enter valid modifications, click on browse button to upload the document and click on save button.

Expected result:

  1. Selected Client document should get uploaded.

Actual result:
Unable to upload client document, and it results in "No connection. Verify application is running."

1

Mandatory field is not getting updated in edit datatable page

  1. Create a datatable for client with the following datasets.
    Field Name Column 1
    Type Length INTEGER
    Code 0
    Mandatory false.
  2. Click on the Edit button next to the created datatable and select the check box next to Mandatory and click on save button.
  3. The created datatable for client should get updated with the Mandatory - True

Actual Result:
In edit datatable the selecting/ Unselecting the checkbox is not getting updated for madatory field.
tc-207 -sheet001 on 15 11 2013
tc-207 -sheet002 on 15 11 2013

Client activation is accepting for future dates

Test data:
Create a client with activation for future dates.

Descriptions:
1.Click on the Clients -> Click on the create client button
2. In create client page provide future date from the present system date,enter valid inputs and click on save button.

Expected result:

  1. Client activation should not be allowed for future date.

Actual result:

  1. It is allowing client activation for future dates.

1

Unable to edit/update in edit client page

Test data:
Edit/update a created client under pending status with following data:
Client name: Mark
External ID: TEST@567

Pre-Conditions:
Create a Client (Pending).

Descriptions:
1.Click on the Clients -> Select the created Client (Pending) -> Click on the Edit button
2. In edit client page enter valid modifications and click on save button.

Expected result:

  1. Client (pending) should get updated with the modifications made.

Actual result:
Unable to save edit client page results in "validation.msg.invalid.date.format"

1

If alternate working date is far away from the holiday date then no proper error message is displaying

Click on Administration -> Organization -> Manage Holidays ->Create Holiday - In create Holiday page create General Holiday on 01 November 2013 and alternate working date 01 December 2013 and click on save button.

 Not able to save the created holiday as error message is displayed as "error.msg.holiday.repayments.rescheduled.to.must.be.within.range",

Not able to figureout what is the range, (No. of days)
tc-203 -sheet001 on 12 11 2013

In "Create Holiday" page alternate working date is accepting Holiday date created before.

Pre-Condition:
Create Holiday on 02 October 2013 as Gandhi Jayanthi,

Description:
Click on Administration -> Organization -> Manage Holidays- > Create Holiday -> In Create holiday page create holiday on October 01 2013 and alternate working date as 02 October 2013.

Expected Result:
Uploading TC-202 -Sheet001 ON 12.11.2013.png . . .

Should not allowed to select alternate working date as another holiday date.

Actual Result:
It is accepting the alternate working date as another holiday date.

More Object-Oriented, more testable approach

Now most of the code is in controllers objects. There are no additional models, nor additional services.

Putting behavior into 'models' and spreading responsibilities into 'services' is the main step toward a more Object-Oriented, more testable approach, leaving all the behavior in the Controllers sounds a lot more old school and "procedural", and usually harder to test and maintain

Add support for intro.js to community app

Add support for Intro.js to community app, so that newbies will find it easier to navigate and learn the UI.

This ticket is just around integrating Intro.Js, and writing a Wiki page on how to add Intro.Js Help navigation to screen, so that then we can decide which screens will need Intro.JS navigation, and what help we wish to provide.

More info on intro.js: http://usablica.github.io/intro.js/

test/SpecRunner.html 88 specs | 32 failing

Unless I'm doing something wrong, if one tries "running the tests" by "Just open test/SpecRunner.html in the browser." as the README suggests, there currently are 88 specs | 32 failing, which is not very nice.. ;-)

Sorry for only ranting (trying to help) and not actually proposing a concrete solution / sending a PR to fix this in this case... Maybe I'll try figuring this out when I have more some other night - if anybody gets to this before me - please do!

Collection sheet is not working

Actual result:

  1. 'Submit" button not displayed
  2. Unable to change/select "Date of transaction".
  3. On clicking on "collection sheet" button it doesn't execute.

1

Unable to transfer funds from one client to another client

Pre-Condition
Create two clients and create savings,loans for both.

Expected result
Mentioned savings amount/loan amount should get transferred to the mentioned client.

Actual result
Unable to transfer funds from one client to another client and it results in "No connection. Verify application is running."

1

Even Unable to transfer funds for loan account also:

1

In Edit Charge page "Charge Time Type" is not sorted with respect to "Charge Applies to"

Pre-Condition:
Create a charge "Application for Loan" in currency US Dollar of 100 on Disbursement time for Loan.

Description:
Click on Admin -> Product -> Charges/Penalties -> Select the created Charge -> Click on edit button -> In edit charge page click on drop down list next to "Charge time type".

Expected Result:
The "Charge time type" dropdown should display on the Loan related details since the charge is applied for Loan.

Actual Result:
It is displaying the Savings related details also.

Screen shot is attached for clarity.
tc-201 -sheet001 on 12 11 2013

baseApiUrl

Unless I'm missing / misunderstanding something, as far as I can see after looking at the current src, the URL for the back-end API is currently hard-coded to be ""/mifosng-provider/api/v1" - so same host & same port, absolute URL?

This is a shame - one would like to / should be able to easily work locally on the prototype-app without having to know anything about the back-end - we have a back-end running in the cloud - so I'd like to (have the option to) be able to just use that.

That's exactly what the "classic" UI allows with the baseApiUrl query parameter, of course. Could we have that on the prototype-app as well?

The few lines of util code to make this happen should probably be shared between AuthenticationService.js and ResourceFactoryProvider.js? Currently both have the hard-coded "/mifosng-provider/api/v1" String duplicated, which is not ideal. (ResourceFactoryProvider has a baseUrl, but that seems to be used in / built for demoTest.js only.)

I've temporarily locally hacked AuthenticationService and ResourceFactoryProvider and hard-coded 'https://demo.openmf.org/mifosng-provider/api/v1' in them, and that actually works. (I'm not entirely sure if that problem about havig to "ping" the API manually once before is relevant in this context? We should solve that too, somehow.)

Sorry for only ranting and not actually proposing a concrete solution / sending a PR in this case... the problem is I'm not entirely sure that the best way is to read a baseApiUrl-like parameter from the URL inside a service an AngularJS app? $location service? Does that work with the router? The $routeParams thing? Maybe I'll try figuring this out when I have more some other night - if anybody gets to this before me - please do!

Allowing to remove selected currency in currency configuration page after attaching with Loan/Saving product

Pre-Condition:
Create a Loan product with the currency US Doolar.

Discription:
Click on Administration -> Organization -> Currency Configuration -> Click on Edit button and remove the selected currency from the list and click on save button.

Expected Result:
Should not allowed to remove the selected currency from the list since it is attached with the Loan Product.

Actual Result:
It is allowing to remove the currency from the list after attaching to the loan product.

app/ should not have a dependency on test/

Something seems to have been set-up conceptually wrong, because:

If you run a local web-server serving (only) app, e.g.

cd ~/dev/M/prototype-app/app
python -m SimpleHTTPServer 9111

and then open http://localhost:9111/, nothing shows up in Browser, and Console shows error:

Failed to load resource: the server responded with a status of 404 (File not found) http://localhost:9111/test/functional/testInitializer.js
Uncaught Error: Script error for: test/testInitializer
http://requirejs.org/docs/errors.html#scripterror require.js:138

This seems to indicate a conceptual dependency bug - app/ should never have a dependency on test/ - agreed?

PS: It works of course if you run the local server in the parent/root directory (prototype-app) instead of in app/ - but with test/ not going to be available in prod later, it probably shouldn't stay like this forever.

"Attach a meeting" - Group is not working

Expected result:
Attached meeting should be able to attach meeting to the group.

Actual result:
"Attach a meeting" - Group is not working hence unable to attach to group.

1

Unable to upload loan documents

Pre-Conditions:
Create a Client, loan product.

Expected result:

  1. Selected loan document should get uploaded.

Actual result:
Unable to upload loan

1
document, and it results in "No connection. Verify application is running."

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.