Neither myself nor FitSmallBusiness is a legal or attorney service. However, there are some general tips to keep in mind.
You can help protect a business idea in a number of ways. You can, as you suggest, create a partnership agreement where you define the rights, responsibilities, and obligations of each partner and when each partner is entitled to a portion of company profits.
It may also be helpful to have a non-disclosure agreement, non-compete agreement, and/or a patent on the app design in your name.
Attorneys can be costly, but they are a wise investment when just starting out in business. At the very least, consider signing up for a service like LegalZoom or Rocket Lawyer. While these services are not a substitute for hiring an attorney, they can connect you with attorneys at a lower cost and have templates of legal contracts and documents.
Best of luck with your app development!