IframeConsultant, (yes, IFRAME), contains
function to select a firm, after select a firm you may choose a consultant.
rather than store a consultant rate with the consultant information,
store the rate with the chosen consultant in an intersection (cross) table along with the orderid.
You can choose multiple consultants and assign each one a rate
Currently there's an array setup to grab the consultant id, already stored in tables and pass this info
to a function that updates the intersect table with orderid, consultantid.
All help appreciated - it's late so please ask questions I'm sure this sounds jumbled as it is.
I've added an input box to the looped array so there's a input field next to each new consultant selected for "rates".
as you choose a consultant a temparray is updated but nothing is "saved" to the table until you hit the save button.
The action on the save button is where I want to pass along my rates (in the looped array known as rate_#i#).
I need to pass the rates data to the "save" action(method) which is a looping tempArray populated if another function finds a
consultantid and since my "rates" data is not a part of the array, (ok... time for some psuedo-code)
--- CFC that sends data to the CFC that populates the cross table
--- This is the last function
<cfif arrayLen( tempArray )>
<cfloop from="1" to="#arrayLen(tempArray)#" index="i">
<cfset updateOrder(arguments.orderid.getID(), tempArray[i], rate) />
The form stores all data into request scope so I end up with rate_1, rate_2, rate_3
which corresponds to consultant1, consultant2, ...
until I submit the page. All form vars are converted to request vars.
but how to get the rate form data to the last function and in proper order so it updates the proper consultantid/orderid/rates
row in the table.