![]() |
|
|||
|
Hi all,
I have complex problem(I think!!). It is like this... My database table name: Subjects Columns: Id int subject varchar(30) sortorder int parent_id So there will be many subjects which are primary parents and many children and grand children as well. Now I need to 1) change the sort order of the existing subjects while editing the records 2) insert a new record with existing sort order In eother of the above cases sort order of rest of the subjects should change accordingly, Can some one help me with coding this requirement please. Thank u |
|
|||
|
This doesnt seem like a ZF issue but more of your application requirement. Humm
So just to have it make sense in my head. Is this what you want done? 1. Record can be updated with a NEW sort order. A. If the sort order is updated, all the other records will update accordingly. 2. Add a new record A. When adding a new record a sort order is provided for the record by the system and NOT by the user? For the updating, if you want it "as you edit" youll need Ajax and an OnChange call the Oncahnge call will be on the form field that contains the 'sortorder field" The real problem your going to encoutner and im not sure if your this far in the code, is the fact that as your database grows so does the time it takes to update these records on the fly thats IF my assumptions are correct. Depending on how you resort the sort orders this might be an issue. Armando Padilla |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
| Designed by: Miner Skinz |
Powered by vBulletin® Version 3.8.4 Copyright ©2000 - 2010, Jelsoft Enterprises Ltd. Search Engine Friendly URLs by vBSEO 3.1.0 |
![]() |