-
Notifications
You must be signed in to change notification settings - Fork 11
Home
PM-POS is a POS system developed to solve operational issues of retail, restaurant or similar businesses. When multiple terminals used on the physical business environment, real time communication between these terminals is essential. So a stable local network or Internet connection infrastructure is needed. In practice having such stable network connection is not always possible. Especially while using mobile terminals operator may walk out of wireless coverage and temporary network connection breaks may lead to serious issues. PM-POS solves such issues by using distributed application development principles for terminal communication. PM-POS terminals works primarily offline without depending on a remote server access and syncs with other terminals through a P2P network when the network connection is available. To achieve this we designed a simple financial transaction model that can be customized for any type of businesses.
We're using Cards to store data. A Card may store properties of a business entity, asset or financial transaction. Cards may have a tree like structure to allow building document type (like invoices or restaurant tickets) transactions. Cards that have no parent are called as Root Cards
. Cards we create under root cards are called as Sub Cards
.
All root cards must have a specific card type. Cards types are useful to group cards. For example Cards we crate to record our customers may have Customers
Card Type.
Tags are useful to set values of a Card. Tagging is the only way to change data stored inside a Card.
Actions are used create cards or tag them. We basically have 3 actions to mutate Cards.
- Create Card: This action creates root cards or sub cards.
- Set Card Tag: This action updates a tag value of a card.
- Close Card: This action closes a card. That means no further updates are expected for this card.
PM-POS basically stores only the history of actions.
All actions executed during a single operation are grouped under a Commit. For example if two actions executed under a single operation both actions stored under a single commit. This means we'll submit both actions or nothing. Splitting these actions is not possible. All commits relates with a single Root Card. What we basically share between terminals are commits. When a terminal receives a new commit it adds the commit to the card's commit history and replays all commits from start to rebuild the card.
Rules are useful to build custom operations based on executed actions. PM-POS monitors all action executions and trigger related rules to apply customizations. For example we may want to execute actions to add discount when a specific customer is selected for a ticket.