Skip to content
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

Parts in use improvements #406

Closed
wants to merge 7 commits into from

Conversation

kipstafoo
Copy link
Collaborator

Overhauled the 'Parts In Use' sub tab under 'Overview'. Major changes:

  • The buttons for each part were removed in favor of a single set of buttons and multiple selection
  • List now allows multiple non-contiguous range selection
  • List can be filtered by:
    -- Type of part (groups match the warehouse)
    -- Whether the part is in use or not
    -- Whether the part is purchasable or not
    -- The name of the part

When buying a 'single' part, the system will buy a single item, ton of ammo, or 5 tons of armor at one time. When buying multiple parts, you can determine if you want to simply buy the specified amount for each selected part, enough to reach a minimum level for each selected part, or a percentage of the currently 'in use' count for each selected part.

Multiple range selections
2017-06-26 3

Bulk buy dialog:
2017-06-26 4

Results of bulk buy:
2017-06-26 5

Cord Awtry added 5 commits June 25, 2017 07:59
- Remove the wall of buttons
- Add a single button for each action up at the top of the tab
- Add filtering by part type, whether or not in use, and name
- Add multi-select to allow buying multiple parts at once
- Change bulk purchasing from a simple number to an exact number to buy,
a minimum number to have on hand, or a percentage of parts in use.
- 'Purchasable' was mispelled in multiple places
- Do not limit 'GM' actions because the part isn't currently purchasable
-- If an admin wants to add it, then add it.
- Change part name filter to filter on the full description [Foot
Actuator (20 tons)] instead of just the base part name [Foot Actuator]
- Change several of the 'type' filters to be more specific to the actual
type, i.e., weapons are also equipment but we don't want to show them in
the 'Equipment' filter, only the 'Weapons' filter.
The problem is that parts with the same name are all, incorrectly,
lumped into one item on the Parts In Use tab. This means parts like
gyros, which have different tonnages, are listed as which ever tonnage
comes up last. If you were to buy one of these parts, you would only get
the one which is in the map. This change cleans that up to properly
display variable tonnage parts of the same type.

- [Campaign.java] Don't store BA parts
- [PartsStore.java] Update storage of 'by name' map. Previously this
didn't not handle parts with duplicate names very well. Instead of
storing a single part for a given name, it stores all parts in a list
keyed off the name.
- [Part.java] Add method for generating the long description. We
generate names in various ways in multiple places which will hopefully
all eventually be replaced by this long description.
- [PartInUse.java] Remove all code for generating the description and
fall back to new method in Part.java
@kipstafoo
Copy link
Collaborator Author

2017-07-23

Fix conflicts preior to merge
@kipstafoo
Copy link
Collaborator Author

Ok, this is in a happier place now. The code now properly handles parts with the same name that belong to different tech bases or have variable tonnage.

This'll be merged in soon, unless someone has additional comments.

- Do not track AmmoBins as parts in use
- Refactor how the 'long' description is generated and override where
necessary on subclasses
- Change name of sub-tab to 'Parts In Use & Storage"
@Bonepart
Copy link
Contributor

Bonepart commented Sep 6, 2017

Curious what the status of this is. Seems like it would be an amazing addition.

@kipstafoo
Copy link
Collaborator Author

it's in process... in a slow death spiral of a process. ;)

@Dylan-M
Copy link
Contributor

Dylan-M commented Feb 11, 2018

@kipstafoo If you want to bring this up to date, I'll get it in immediately post-stable.

@Dylan-M
Copy link
Contributor

Dylan-M commented Mar 6, 2018

Nudge... you should bring this up to date ;)

@sixlettervariables
Copy link
Contributor

Closed as stale.

@Faltsu
Copy link

Faltsu commented May 7, 2020

This would be so helpful when starting new campaign :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants