-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added Pay Distribution Template to Goal-templates #3078
Added Pay Distribution Template to Goal-templates #3078
Conversation
…ted instead of replacing. Added + to the syntax for goal-template. When put before the value and after the priority will prevent ProcessTemplate() from clearing the value from budgeted, so the template can add its amount instead. This feature will be useful for people who do their budgets weekly or by paycheck. EXAMPLE: #template +$50 Note: This functionality was not applied to all template types; schedule was skipped.
✅ Deploy Preview for actualbudget ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Bundle Stats — desktop-clientHey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle. As this PR is updated, I'll keep you updated on how the bundle size is impacted. Total
Changeset
View detailed bundle breakdownAdded No assets were added Removed No assets were removed Bigger
Smaller
Unchanged
|
Bundle Stats — loot-coreHey there, this message comes from a GitHub action that helps you and reviewers to understand how these changes affect the size of this project's bundle. As this PR is updated, I'll keep you updated on how the bundle size is impacted. Total
Changeset
View detailed bundle breakdownAdded No assets were added Removed No assets were removed Bigger
Smaller No assets were smaller Unchanged No assets were unchanged |
If you are ready to get this reviewed remove the [WIP] label. Also to fix the lint error run |
Fixed a mistake I made with not removing the test code.
I haven't tried it yet, but I don't think this makes sense to add to the remainder template |
You're probably right, i haven't played with the remainder feature and originally i didn't have it. But before pushing in my mind I thought someone may like the remainder of their paycheck to be added to a 'budgeted' like savings. |
Im wondering if it would be better to keep the number of templates that can do this low. Some of the more involved templates could just get confusing with this option. I think we need to figure something out as well for the what goal gets set. Right now the goal is set like normal, but the budget amount likely is higher than that goal. |
Okay so what i'll do is, reduce the templates down to simple and percentage i think that's a good middle ground, I Still think having the remainder is a good idea But i trust someone who has done this for a while. When you mention about the 'goal is normal, but budget amount likely is higher', not quite sure what you mean. If your referring to the 'up to' syntax then i'll do some testing and if that does not work correctly i'll see what i can do about it. I do have another idea of implementation of this that could help with that issue. Let me know if i need to change this back to [WIP]. Again this is my first time contributing to a project and using Git. Thanks a lot for your time. |
I mean the part of the processing that sets the goal in the database. Thats what informs the green/yellow coloring in the budget table. Those aren't getting changed to match that the new amount that the template wants is greater than a single template run asks for. This makes it so you could remove funds and still be in the green even though the budgeted amount is less than what the templates budgeted. |
Okay thanks, I'm going to move this back to work in progress and test for these things, and prob do some rework of code. I'll move it back to review when I think I have corrected the issues and maybe a draft for documentation, explaining the feature better. I appreciate your input. |
The new code will allow users to distribute each pay without effecting goals.
Made a mistake in merging, first time with github
Still fixing merging issues
This should make branch the same, before own changes can be added. [Still fixing merging mistake]
New Pay Distribution code. Merge errors fixed.
Pay Distribution Template has been added. This adds the + directive and can only be used as "#template +$" for a set amount to be taken from the available budget, or "#template +%" to use a percentage of the available amount. This new template will not set a goal but be used to add to the current budgeted amount for that month. Additionally, all other templates active on that category will till register to a goal but will not add their amounts to the budgeted. The mindset behind this template is for people who budget by paycheck or don't have the funds to budget for a whole month but want to work towards a goal. Also if a secondary template has the 'up to' and 'hold' flags active the new Pay Distribution template will respect those rules. |
THIS PR HAS BEEN REPLACED WITH PR #3176. Please read here for comments and explanation. And review code at 3176.
Added a new Template type called Pay Distribution, which is designed to be triggered every time the apply template is clicked. if a Pay Distribution template is applied to a category then instead of adding to the goal the distribution template will just add its value to the currently budgeted amount. if a normal template is applied to the category as well, then that template will add to the goal but will not change the value of the budgeted column.
The purpose of this new template is for people who budget by paycheck which may not be monthly, or for those who are still working on building up their funds to have enough to budget for a month.
The pay Distribution Template has two operations either a set amount OR a percentage of the remaining available funds.
Additionally, if the pay distribution template is added to the same category as the remainder template, then the remaining budget will be added to that category also. Otherwise, the remainder template will retain its normal functionality.