How to not show merchant fields in Customer Receipt
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
How to not show merchant fields in Customer Receipt
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
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
Edit the ConLib/Utility/OrderItemDetails.ascx file and locate the following code
and make it look like
Code: Select all
<asp:DataList ID="InputList" runat="server">
Code: Select all
<asp:DataList ID="InputList" runat="server" Visible="false">
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
Re: How to not show merchant fields in Customer Receipt
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
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
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
Re: How to not show merchant fields in Customer Receipt
Addendum:
Specifically we wish to eliminate the "More Details" but leave or own added fields.
Thanks
Mark
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
Yes its possible. Edit the BasketItemDetail.ascx file and locate the following code
and make it look like as below
Replace the First Field Name and Second Field Name values with your actual two fields name which you want to display.
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>
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>
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
Re: How to not show merchant fields in Customer Receipt
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 !
I tried what you suggested but it did not work

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
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.ascxHello 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 !
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
-
- Ensign (ENS)
- Posts: 19
- Joined: Sun Dec 21, 2008 2:15 am
Re: How to not show merchant fields in Customer Receipt
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
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

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
Make sure that you spelled the fields same as in merchant module and in code.