Yii Framework Forum: How to make calculation with persistent parameters - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

How to make calculation with persistent parameters Rate Topic: -----

#1 User is offline   Mirko 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 1
  • Joined: 17-May 10

Posted 21 June 2010 - 10:02 AM

I need web application to calculate some values - prices. Few parameters should be defined by administrator and few should depend on customer. Calculation should not be saved but application should enable multiple users to make calaculation at same time.

Example:

Price = A1*(A2+A3+A4)+C1*C2

where Ax are administrator values (same for all customers) and Cx are customer values (depend on customer).

It is needed that administrator could change Ax and Cx values and that they are saved in some tables.

Is it possible to make such application with yii fw and could somebody please give me some clues how to do it?

Tnx
0

#2 User is offline   zaccaria 

  • Elite Member
  • PipPipPipPipPip
  • Yii
  • Group: Members
  • Posts: 2,232
  • Joined: 04-October 09
  • Location:Moscow

Posted 21 June 2010 - 01:35 PM

Is possible to do this application.

You should create the tables in db, one for save Ax Values and another for save Cx values (and customer ID, I guess).

Later you can use Gii for generate the models for the table and the CRUD for manage the table.

As last point you can create a controller with an action that display the final result.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users