Skip navigation
Currently Being Moderated

Release Initials on edit action page

Aug 9, 2012 11:53 AM

Hi,

    I have an edit page that I'm trying to update all the info. in my database. I have multiple tables with all this info. and am having a problem getting the Release Approval Initials from the Approvals table to display on an action page.

        I was able to figure out how to  get the Release Approval Initials to display on the edit_all_ec_number_action.cfm page, but I’m having a problem getting them to display on the docs_to_be_removed_all_action.cfm page. This is one page further past the original action page.

      Basically, on the edit page, if “i” is chosen for the Docs to be removed from P Drive drop down menu, it will go to the action page and display the info. entered, but I have some code that intercepts this first, to enter the Docs to be removed. Then, once you click update on this page, it goes to the docs_to_be_removed_all_action.cfm page. This is the page where I’m having a problem getting the Release Approval Initials to display.  How am I supposed to pass them from the edit_all_ec_number_action.cfm page to this action page? This is what I have on the edit page:

 

<CFQUERY NAME="DisplayApprovalItem" Datasource="#application.DataSource#">

        SELECT *

        FROM Approval

         WHERE Approval.APV_ItemID = #url.ItemID#

    </cfquery>

 

<CFQUERY NAME="ShowItem" Datasource="#application.DataSource#">

SELECT ECID, Requested_By_Initials, EC_Completion_Initials, EC_Completion_Date, Flag_Comments, Comments, ItemID, ECID_SPEC, ECO_Start_Date, Date_Requested, Requested_By_Initials, Part_Number, Description, CN_Entry, P_Drive_Docs, Dismiss_Part_Number, Release_Status, Validation_ItemID, Validation_ECID, Validation_Qty, Docs_to_remove, SW_Model_Only, PNR_BOM_Change_Only, Doc_Changes_Only, Doc_Removal_Date,

 

Approval_Release.Approval_Initials as Release_Initials

 

FROM ECO_Master LEFT JOIN ECO_Items ON ECO_Master.ECID = ECO_Items.ECID_SPEC

LEFT JOIN Validation_Records ON ECO_Items.ItemID = Validation_Records.Validation_ItemID

LEFT JOIN Approval ON ECO_Items.ItemID = Approval.APV_ItemID

 

LEFT JOIN Approval as Approval_Release ON ECO_Items.ItemID = Approval_Release.APV_ItemID AND Approval_Release.Document_Type = 'Release'

 

Where    ItemID=#url.ItemID#

 

ORDER BY ItemID

</CFQUERY>

 

 

<tr>

<td class="edit" align="right">Release Initials:</td>

<td colspan="2">

<cfif DisplayApprovalItem.recordcount>

<cfset ReleaseInitials = ShowItem.Release_Initials>

 

            <select name="Release_Approval_Initials#ItemID#" id="Release_Approval_Initials#ItemID#">

                <option value=""></option>

                <cfloop query="ShowDataEntryInitials">

                    <option value="#Initials#"

                    <cfif Initials EQ ReleaseInitials>selected

                    </cfif>>#Initials#</option>

                </cfloop>

            </select>

           

<cfelse>

<font color = "red">The Approval for this has not been filled out.</font>

</cfif>

</td>

</tr>

 

 

 

This is what I have on the edit_all_ec_number_action.cfm page to get the initials to pass to the next action page:

 

<cfif isDefined ("form.Release_Approval_Initials")>

<input type="hidden" name="Release_Approval_Initials" value="#Release_Approval_Initials#">

</cfif>

 

<input type="hidden" name="listofids" id="listofids" value="#ValueList(ShowItem.ItemID)#">

 

 

 

Then on the docs_to_be_removed_all_action.cfm page, I have this to output the Initials, but it doesn’t display anything. It says the Variable ID is undefined.

 

<cfif isDefined ("form.Release_Approval_Initials#id#") and

"form.Release_Approval_Initials#id#" neq "">

#Evaluate("form.Release_Approval_Initials#id#")#

<cfelse>

 

</cfif>

 

    Does anyone have any ideas what I can try? Thanks.

 

  Andy

 
Replies

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points