{"id":23820098,"url":"https://github.com/claudiaslibrary/finance_manager","last_synced_at":"2025-06-23T03:39:39.602Z","repository":{"id":263413978,"uuid":"890314256","full_name":"ClaudiasLibrary/finance_manager","owner":"ClaudiasLibrary","description":"The Finance Manager application is a simple tool to track and manage your finances.","archived":false,"fork":false,"pushed_at":"2024-12-14T13:52:40.000Z","size":7,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-02T07:19:40.204Z","etag":null,"topics":["finance","finance-management","gui","python","tkinter"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ClaudiasLibrary.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-18T11:09:32.000Z","updated_at":"2024-12-30T22:03:12.000Z","dependencies_parsed_at":"2024-11-19T04:32:01.823Z","dependency_job_id":null,"html_url":"https://github.com/ClaudiasLibrary/finance_manager","commit_stats":null,"previous_names":["claudiaslibrary/finance_manager"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClaudiasLibrary%2Ffinance_manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClaudiasLibrary%2Ffinance_manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClaudiasLibrary%2Ffinance_manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ClaudiasLibrary%2Ffinance_manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ClaudiasLibrary","download_url":"https://codeload.github.com/ClaudiasLibrary/finance_manager/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240100516,"owners_count":19747683,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["finance","finance-management","gui","python","tkinter"],"created_at":"2025-01-02T07:19:41.720Z","updated_at":"2025-02-21T22:42:53.487Z","avatar_url":"https://github.com/ClaudiasLibrary.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Finance Manager\n\nThe **Finance Manager** application is a simple tool to track and manage your finances. This app allows you to record your income and expenses, edit entries, delete records, and view your balance in real-time. The data is stored in an SQLite database, which ensures that your financial records persist even after you close the application.\n\n## Features\n\n- **Add Transactions**: Record income or expenses with a description and date.\n- **Edit Transactions**: Modify existing records.\n- **Delete Transactions**: Remove unwanted entries.\n- **Balance Display**: View your balance, calculated as the total income minus expenses.\n- **Data Persistence**: Financial records are stored in an SQLite database (`finance_manager.db`).\n- **Transaction History**: View a detailed table of all transactions, sortable by date, amount, or type.\n- **Dynamic Updates**: The balance and transaction list update automatically after each operation.\n\n## Requirements\n\n- Python 3.x\n- `tkinter` (for the graphical user interface)\n- `sqlite3` (for database functionality)\n\nThese libraries are standard with Python, so you don't need to install anything extra.\n\n## How to Use\n\n### Adding a Transaction\n1. Select the transaction type (either `income` or `expense`) from the dropdown.\n2. Enter the amount in the \"Amount\" field.\n3. Provide a description for the transaction (optional).\n4. Enter a date (optional; defaults to today's date).\n5. Click the \"Add Transaction\" button to save the entry.\n\n### Editing a Transaction\n1. Click on a transaction in the transaction list (Treeview).\n2. Modify any of the fields (type, amount, description, date).\n3. Click the \"Edit Transaction\" button to save your changes.\n\n### Deleting a Transaction\n1. Select a transaction from the list.\n2. Click the \"Delete Transaction\" button.\n3. Confirm the deletion in the popup.\n\n### Viewing Balance\n- The balance is calculated automatically by subtracting total expenses from total income.\n- It is displayed at the top of the application window.\n\n### Transaction List\n- All transactions are displayed in a table (Treeview) with the following columns:\n  - **ID**: A unique identifier for each transaction.\n  - **Type**: Whether the transaction is `income` or `expense`.\n  - **Amount**: The amount of the transaction.\n  - **Description**: A brief description of the transaction (if provided).\n  - **Date**: The date when the transaction occurred.\n\n## Code Walkthrough\n\n### SQLite Database\n\nThe app uses SQLite to store the financial data in a database. A table called `transactions` is created with the following fields:\n- `id`: An auto-incrementing primary key.\n- `type`: The transaction type (`income` or `expense`).\n- `amount`: The amount of money involved in the transaction.\n- `description`: A description of the transaction.\n- `date`: The date when the transaction occurred.\n\nSQL queries are used to insert, update, delete, and select transactions.\n\n### Functions\n\n- **add_entry()**: Adds a new transaction (income or expense) to the database. It validates the input and updates the balance and transaction list after adding the transaction.\n- **clear_entries()**: Resets the input fields (transaction type, amount, description, date) to their default values.\n- **update_balance()**: Calculates and updates the balance by fetching the total income and total expenses from the database.\n- **refresh_transactions()**: Refreshes the Treeview widget to show the latest transactions from the database.\n- **load_selected_transaction()**: Loads the selected transaction from the Treeview into the input fields for editing.\n- **edit_entry()**: Edits an existing transaction based on the selected ID.\n- **delete_entry()**: Deletes the selected transaction from the database after a confirmation prompt.\n\n### UI Components\n\n- **Entry Fields**: For entering transaction details (amount, description, date).\n- **Buttons**: For adding, editing, and deleting transactions.\n- **Treeview**: Displays all transactions in a table format, allowing users to select and edit them.\n- **Balance Label**: Shows the current balance, which is updated automatically.\n\n### Treeview (Transaction List)\n- The Treeview is used to display the transactions in a tabular format with columns for **ID**, **Type**, **Amount**, **Description**, and **Date**.\n- You can select a row in the Treeview to edit or delete the corresponding transaction.\n\n## Installation\n\n1. Clone the repository or download the script.\n2. Ensure that Python 3.x is installed on your system.\n3. Run the script:\n\n```bash\npython finance_manager.py\n```\n\nThe app will automatically create a `finance_manager.db` database file if it does not already exist.\n\n## License\n\nThis project is open-source and available under the MIT License.\n\n## Acknowledgements\n\n- `tkinter` for the graphical user interface.\n- `sqlite3` for the database functionality.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaudiaslibrary%2Ffinance_manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclaudiaslibrary%2Ffinance_manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclaudiaslibrary%2Ffinance_manager/lists"}