[racktables-users] Re: DB structure

  • From: Alexey Andriyanov <alan@xxxxxxxxxx>
  • To: Yury Soldatov <yury.soldatov@xxxxxxxxxx>
  • Date: Thu, 07 Feb 2013 20:10:00 +0400

You can examine how web operations work.

Each modification through web causes HTTP POST request being sent with at least these base parameters: 'page', 'tab', 'op'. There is the $ophandler array in wwwroot/inc/navigation.php filled with function names for each triplet of base web operation parameters.

Then, when you determine the handler function name for you operation (like object creating), you could examine its code in wwwroot/inc/ophandlers.php. It usually calls appropriate functions from database.php.

Also, there are some trivial operations which have no special ophandler function. Then the universal database wrapper called tableHandler takes place. It makes direct SQL queries, building them by $opspec_list array data.

Hope this information will help you.

07.02.2013 14:56, Yury Soldatov пишет:

I need import data from another database.
Could you give two examples of how to add some parameters to the object and how create object.

As I understood I needed functions are in the ../wwwroot/inc/database.php
What function can add data to the object? What function create object?

How, for example, knowing the name of the object, add to it the serial number and place it in the rack and unite?

May be i may use Ian's API, but i need simple examples of how it use.


--
Best regards,
Alexey


Other related posts: