Page 1 of 1
How to not show merchant fields in Customer Receipt
Posted: Thu Jan 15, 2009 4:13 am
by ocf@rme-w.com
We have some extended merchant fields in our product template which we wish to show in the store but not on the customer receipt (we wish to show only the item name). See attached .jpg Highlighted area is all we want on receipt.
My guess is that we need to alter receipt.aspx, but being not so experienced at asp I am not sure how to alter the following to eliminate the merchant fields.
<asp:TemplateField HeaderText="Item">
<ItemTemplate>
<uc:OrderItemDetail ID="OrderItemDetail1" runat="server" OrderItem='<%#(OrderItem)Container.DataItem%>' ShowAssets="False" LinkProducts="False" />
</ItemTemplate>
</asp:TemplateField>
Many thanks
Re: How to not show merchant fields in Customer Receipt
Posted: Thu Jan 15, 2009 8:08 am
by mazhar
Edit the ConLib/Utility/OrderItemDetails.ascx file and locate the following code
Code: Select all
<asp:DataList ID="InputList" runat="server">
and make it look like
Code: Select all
<asp:DataList ID="InputList" runat="server" Visible="false">
Re: How to not show merchant fields in Customer Receipt
Posted: Sun Jan 25, 2009 10:44 pm
by ocf@rme-w.com
Many Thanks
Re: How to not show merchant fields in Customer Receipt
Posted: Wed Feb 11, 2009 10:58 am
by ocf@rme-w.com
Hi Mazar
Is there a way of showing only specific fields from the input list in the admin/orders, printing packing list, etc. ? Without showing the additional product data. IE: we have two specific fields for delivery date and special requirements which do not show in the admin order details when we eliminate the InputList <asp:DataList ID="InputList" runat="server" visible="false">
I've tried a variety, but have not come up with the answer yet.
Best Regards
Mark E-W
Re: How to not show merchant fields in Customer Receipt
Posted: Wed Feb 11, 2009 11:10 am
by ocf@rme-w.com
Addendum:
Specifically we wish to eliminate the "More Details" but leave or own added fields.
Thanks
Mark
Re: How to not show merchant fields in Customer Receipt
Posted: Wed Feb 11, 2009 11:17 am
by mazhar
Yes its possible. Edit the BasketItemDetail.ascx file and locate the following code
Code: Select all
<asp:DataList ID="InputList" runat="server">
<HeaderTemplate><br /></HeaderTemplate>
<ItemTemplate>
<b><asp:Literal ID="InputName" Runat="server" Text='<%#Eval("InputField.Name", "{0}:")%>'></asp:Literal></b>
<asp:Literal ID="InputValue" Runat="server" Text='<%#Eval("InputValue")%>'></asp:Literal><br />
</ItemTemplate>
</asp:DataList>
and make it look like as below
Code: Select all
<asp:DataList ID="InputList" runat="server">
<HeaderTemplate><br /></HeaderTemplate>
<ItemTemplate>
<b><asp:Literal ID="InputName" Runat="server" Text='<%#Eval("InputField.Name", "{0}:")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "First Field Name") || ( Eval("InputField.Name").ToString() == "Second Field Name")) %>'></asp:Literal></b>
<asp:Literal ID="InputValue" Runat="server" Text='<%#Eval("InputValue")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "First Field Name") || ( Eval("InputField.Name").ToString() == "Secnond Field Name")) %>'></asp:Literal><br />
</ItemTemplate>
</asp:DataList>
Replace the
First Field Name and
Second Field Name values with your actual two fields name which you want to display.
Re: How to not show merchant fields in Customer Receipt
Posted: Wed Feb 11, 2009 12:33 pm
by ocf@rme-w.com
Hello Mazhar
I tried what you suggested but it did not work

... no change
It seems that the file that affects what is displayed is OrderItemDetail.ascx
Also, let me be more specific ... In the store we wish to display fields from EditProductTemplate.aspx, but we do not wish them displayed in the customer basket, view orders or packing slip
We do wish to display "customer prompts" in view orders and packing slip.
I've attached two .jpg files to show what I mean.
Many thank !
Re: How to not show merchant fields in Customer Receipt
Posted: Thu Feb 12, 2009 7:20 am
by mazhar
Hello Mazhar
I tried what you suggested but it did not work

... no change
It seems that the file that affects what is displayed is OrderItemDetail.ascx
Also, let me be more specific ... In the store we wish to display fields from EditProductTemplate.aspx, but we do not wish them displayed in the customer basket, view orders or packing slip
We do wish to display "customer prompts" in view orders and packing slip.
I've attached two .jpg files to show what I mean.
Many thank !
In order to hide the fields in Basket just use the visible=false trick discussed in the very beginning of this thread in ConLib/Utility/BasketItemDetails.ascx. If you want some fileds to be shown in basket then you can use the second trick ConLib/Utility/BasketItemDetails.ascx
For view orders page and pack slips yes you are right the change will be required in Admin/UserControls/OrderItemDetails.ascx. If you want to hide all fields then you just need to set visible =false or if you want to show some fields then it will be same as we discussed above for the ConLib/Utility/BasketItemDetails.ascx
Re: How to not show merchant fields in Customer Receipt
Posted: Tue Feb 17, 2009 4:39 pm
by ocf@rme-w.com
Hello again Mahzar
Being the neophyte in asp (better at CF but still not a programmer), I am still having trouble with this.
The three fields which we want to include are:
InputField_23
InputField_26
InputField_149
I have tried substituting First Field Name, Second Field Name and Third Field Name to no avail

I have tried in code both as "InputField_23" and also as "23" etc
original (your code):
<asp:DataList ID="InputList" runat="server">
<HeaderTemplate><br /></HeaderTemplate>
<ItemTemplate>
<b><asp:Literal ID="InputName" Runat="server" Text='<%#Eval("InputField.Name", "{0}:")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "First Field Name") || ( Eval("InputField.Name").ToString() == "Second Field Name")) %>'></asp:Literal></b>
<asp:Literal ID="InputValue" Runat="server" Text='<%#Eval("InputValue")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "First Field Name") || ( Eval("InputField.Name").ToString() == "Secnond Field Name")) %>'></asp:Literal><br />
</ItemTemplate>
</asp:DataList>
for
<asp:DataList ID="InputList" runat="server">
<HeaderTemplate><br /></HeaderTemplate>
<ItemTemplate>
<b><asp:Literal ID="InputName" Runat="server" Text='<%#Eval("InputField.Name", "{0}:")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "23") || ( Eval("InputField.Name").ToString() == "26") || ( Eval("InputField.Name").ToString() == "149")) %>'></asp:Literal></b>
<asp:Literal ID="InputValue" Runat="server" Text='<%#Eval("InputValue")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "23") || ( Eval("InputField.Name").ToString() == "26") || ( Eval("InputField.Name").ToString() == "149")) %>'></asp:Literal><br />
</ItemTemplate>
</asp:DataList>
and also tried
<asp:DataList ID="InputList" runat="server">
<HeaderTemplate><br /></HeaderTemplate>
<ItemTemplate>
<b><asp:Literal ID="InputName" Runat="server" Text='<%#Eval("InputField.Name", "{0}:")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "InputField_23") || ( Eval("InputField.Name").ToString() == "InputField_26") || ( Eval("InputField.Name").ToString() == "InputField_149")) %>'></asp:Literal></b>
<asp:Literal ID="InputValue" Runat="server" Text='<%#Eval("InputValue")%>' Visible='<%#(( Eval("InputField.Name").ToString() == "InputField_23") || ( Eval("InputField.Name").ToString() == "InputField_26") || ( Eval("InputField.Name").ToString() == "InputField_149")) %>'></asp:Literal><br />
</ItemTemplate> </asp:DataList>
Again your suggestions are greatly appreciated.
Mark
Re: How to not show merchant fields in Customer Receipt
Posted: Fri Feb 20, 2009 12:22 pm
by mazhar
Make sure that you spelled the fields same as in merchant module and in code.