[eluser]toopay[/eluser]
Hey ToddyBoy, dont make it sound like "PROGRAMMING MAKE YOUR BRAIN MUSH"
Don't be desperate... :lol:
I will do that this way :
1. Grab a glass of cold beer.
2. While starting smoked,
First, i'll make a database tables for handle that.
a. 'city' or 'location' table, containing city/location id, city/location code, city/location name.
b. 'rates' table, containing id, base currency (for converting stuff), rates based by weight, tax.
c. some pivot table, named it 'city_rates' or whatever you like, which contain id, from(city/location id), to(city/location id), rate_id. If you have 15 city or location, and the rates from, let say 'city/location A' -> 'city/location B' rates equal with 'city/location A' <- 'city/location B' rates, then based by 'variation algorithm'
Code:
15!/(15-2)!(2)! = 105
you will have : 105 rates id(at least).
3. Ok, the database part should be fine now. i'll create a model to handle above tables, writes several SOAP API of it, then... hey i'm running out my cigarete(i'll buy it first!).
4. Database is ok, model is ok, soap api is ok... Now i should be start write a controller, to retrieve database data, load validation class, building a rules and output all of this in view file.
5. i'll create unit testing, just for make sure everything is ok.
6. Done. The company should pay me for create an courier rates calculator apps right now, and i'll be buy a bunch of cold beer, cigarete and start other project...