You are here

greggles's blog

Code Update - Buying/Selling a Portfolio, Transaction support, Initial Refactoring

Submitted by greggles on Mon, 12/24/2007 - 13:38

In today's update there are a few additions:

Complete Buying a Portfolio

You can buy/sell an entire portfolio. I keep doing it just for fun. This will record a purchase of 1 of every contract in the portfolio. This has removed a lot of my previous TODO entries from the hook_nodeapi which feels great. I even added in some more comments.

Transaction Support

One concept that I knew I would have to include was transactions. When you buy or sell something 2-4 things have to happen

<

ol>

  • Credit/Debit your bank account
  • Initial Drawings and Musings

    Submitted by greggles on Fri, 12/21/2007 - 10:33

    So, the first post. I'm going to use the blog here to document progress on the module and design decisions. The goal is to allow others to provide input and to make this module building exercise an open learning situation for people who are interested. The first step is to lay out the initial set of requirements. For the first iteration, my goal is to implement the bank accounts, objects and facility to store the purchasing/trading of contract groups, and the "happy path" through the purchase/sale of a contract group as a whole. "Happy path" means no validation just yet. I've also mentioned (here and in //TODO comments in the code) some things I know I will need to do but that I don't want to worry about now.

    Attached is a diagram of some of the initial thoughts - a sort of object/relational map and also a tiny workflow. If you like pictures, maybe that will help more than my descriptions.

    object relational and workflow diagram for a simplified prediction market

    Pages

    Subscribe to RSS - greggles's blog