Files
simple-shop/Simple-Shop/Models/Models.md
T
Nate VanBuskirk c9e3374d5d Changes:
----------
VS Solutions are setup. Additions made to web project. Directory cleanup and movement completed. Updated with publish settings for website project (password NOT inlucded). Pub settings with password are saved in a localized file set that will be stored somewhere and backedup somewhere safe and private to avoid intrusions to webhosting rss.

New:
------
Added Basic Models, SQL, EDMX, T4 Text Gen Files, and Auto-Gen'd the backing CS/SQL files. There is a database file added (not tested). There's also a backup of the sql files and other necessary tidbits included.

Not Included:
---------------
We do not yet have capacity for Scaffolding with current EF version and VS2017 because the backing database either is missing the table(s) OR because there's another issue caused by weirdness with the auto-gen process. No controllers/views/etc exist beyond the default template/wizard junk and the model system employed above.

Expectations:
---------------
Will need to test further once we've had a chance to back this up and walk through the manual steps to see what got missed by the auto-magic.

Next Steps:
-------------
Next step(s)/commit(s)/push(es) should include getting the datasbase populated with data-less tables, verifying the entity associations, scaffolding a very basic controller for each major entity, and testing basic add-update-view-delete logic (limited due to the tight relationships between certain tables/entities).

More Info:
------------
Once we have the basic skeleton up and working, we can either dig into the Web side OR one of the front-end sides for devices (desktop.winforms, desktop.uwp.touch, mobile.xamarin, etc)...
2019-11-13 10:06:24 -06:00

1 line
4.5 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// Models.edmx
# Models.edmx
## TOC
1. Models
1. Pricing
1. PricePoint
1. PriceCategory
1. Currency
1. CurrencyCategory
1. Items
1. Items
1. ItemCategories
1. ItemImages
1. Deals
1. Deals
1. DealItems
## Models
### Pricing
#### PricePoint
Each PricePoint is a marker with a Qty value and ONE Currency. To represent an item that consists of multiple currencies (in this scenario, a single currency could be represented by something like a penny, nickle, dime, quarter, or dollar; a PriceCategory represents say the American currency), you would need to utilize a PriceCategory.
For example, one PriceCategory could be represented as follows:
1q 1d 1n 1p or when aggregated, would look like: 41c. I drew this out because for a simple store for a toddler, you may want to utilize nickels and pennies not as an aggregate, but as separate currencies.
For the normal currency system, you wouldn't care if someone used nickels, pennies, etc; but for a small child's money-teaching tool or a system that powers a vending machine limited to specific currency pieces, you DO care about the intricate systems at play within a single IRL currency.
That is the system at play here.
#### PriceCategory
Represents a plurality of PricePoints. If a single price point could be 1q, 1d, 1n, or 1p, a PriceCategory could represent an aggregate of those PricePoints. You do NOT have to separate the coins from eachother OR even from dollars, should you choose to combine them into Dollars while utilizing the decimal notation to represent cents. This merely provides an avenue for being specific while allowing general use as well.
#### Currency
Not to beat a dead horse here, but a currency can either be represented:
1. **in the most aggregate sense** _(such as American Dollars to represent the entirety of the USA currency system)_
1. **OR in the specific/system sense** _(such as red tokens, blue tokens, green tokens, 5-dollar-bills, 1-dollar-bills, quarters, dimes, nickels, and pennies)_ .
#### CurrencyCategory
Represents an amalgamation or system of Currencies.
For example, in the systems mentioned above, where each piece of a currency set is specified (a quarter is treated as separate from a dime and a nickel and a penny), then the CurrencyCategory represents the whole system of all Currencies within it. In this instance, you might name it "American Coins" or something similar, distinct from "American Dollar" or whatever you use to represent the entire American currency system.
In the example of poker chips of different colors, _"Poker Chip"_ could be the resounding CurrencyCategory.
In the case of the American currency system (dollars are the trading currency, but it also includes coins and dollar bills of differing values in relation to the Dollar), _"American $$$"_ or _"American Dollar"_ could be the actual CurrencyCategory.
This, too, allows you to have multiple differing systems with similar parts. You could have _"American $$$"_ for one shop, child, or system; then _"American Dollar (Coins)"_ for another; then _"Poker Chip"_ for yet another. The sky, your imagination, and the boxes you create are your only limitation.
### Items
#### Items
Any item is represented as an objectified representation of some kind which can be either tangible (a toy, a board game, or a consumable such as a piece of candy) OR something intangible such as a visit to the park, a happy meal and visit to McDonalds, getting to stay up an hour later one evening, or getting to spend X minutes/hours on a digital device … to name a few examples.
#### ItemCategories
ItemCategories are definitions of similarities between items. Use this to help categorize your shop items in a way that they can be filtered by your young consumers-in-training that makes sense to them. You may even want to include a sprite, icon, or image to represent your category such that even those learning to read, or those not quite there yet, can still recognize and take advantage of them. This also will help with future features such as logging, stats, notifications for getting low in stock of certain things (tangible or intangible) that you might need to prioritize.
##### Examples:
1. **Toys** _(tangible)_
1. **Board Games** _(tangible)_
1. **Outside Adventures** _(intangible)_
1. **Visits to the Museum** _(intangible)_
1. **Fast Food Visits** _(intangible)_
1. **Consumables** (such as treats, food, stickers, markers, etc) _(tangible)_
#### ItemImages
### Deals
#### Deals
#### DealItems