Announcement

Collapse
No announcement yet.

Date Info Question, Hide the Date from the Receipt and Invoice

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Date Info Question, Hide the Date from the Receipt and Invoice

    Hi all,

    I hope someone can help me with this one.

    I want to use the Date Info Question as a message that carries over into the shopping cart showing the date a product is available from (I am not able to use the "Other Info Question" as this is used as a confirmation checkbox on another item), I have hidden the Date picker using css display:none, however this still shows in the receipt email and is confusing for customers. I am guessing this is being controlled by .pl files somewhere, would anyone know of a way to hide this from the email and packing slip/invoices so it only shows the message written in the "Date Info Prompt" please?
    Many Thanks
    Lee
    www.mdnsupplies.co.uk
    www.hookandloopfasteners.co.uk

    #2
    Hi Lee

    Does this help?

    https://www.drillpine.biz/forums/viewtopic.php?t=1073
    Jonathan Chappell
    Website Designer
    SellerDeck Website Designer
    Actinic to SellerDeck upgrades
    Graphicz Limited - www.graphicz.co.uk

    Comment


      #3
      Hi Jonathan,

      Thanks for your help, sadly not, the layout I am using is from one of the prompts in the product details, I am only using that as I cant get a variable to show in the basket and the post here has gone. I'll have to have a re-think.

      *edit, sorry I see this was for the prompt. Unfortunately not a solution, I have hidden the date from showing so online and during the order process it all shows fine, the problem is that a date bearing no relation to the message is then shown on the customers email receipt and packing slip:
      Click image for larger version

Name:	Screenshot 2024-08-18 at 10-31-02 Roundcube Webmail Inbox.png
Views:	54
Size:	5.6 KB
ID:	557450
      The "18 August 2015" must be generated somewhere in the scripts and would like to hide it if anyone has a work around.
      Many Thanks
      Lee
      www.mdnsupplies.co.uk
      www.hookandloopfasteners.co.uk

      Comment


        #4
        Guessing you have customised your Customer Email HTML layout.

        There is this in that layout:

        Code:
        <actinic:variable name="ShipSalutationOnlineXML"/><actinic:variable name="ShipNameOnlineXML"/><actinic:variable name="ShipNameSepOnlineXML"/><actinic:variable name="ShipTitleOnlineXML"/><actinic:variable name="ShipTitleSepOnlineXML"/><actinic:variable name="ShipCompanyOnlineXML"/><actinic:variable name="ShipCompanySepOnlineXML"/><actinic:variable name="ShipAddress1OnlineXML"/><actinic:variable name="ShipAddress1SepOnlineXML"/><actinic:variable name="ShipAddress2OnlineXML"/><actinic:variable name="ShipAddress2SepOnlineXML"/><actinic:variable name="ShipAddress3OnlineXML"/><actinic:variable name="ShipAddress3SepOnlineXML"/><actinic:variable name="ShipAddress4OnlineXML"/><actinic:variable name="ShipAddress4SepOnlineXML"/><actinic:variable name="ShipPostCodeOnlineXML"/><actinic:variable name="ShipPostCodeSepOnlineXML"/><actinic:variable name="ShipCountryOnlineXML"/><actinic:variable name="ShipCountrySepOnlineXML"/><actinic:variable name="ShipPhoneOnlineXML"/><actinic:variable name="ShipPhoneSepOnlineXML"/><actinic:variable name="ShipFaxOnlineXML"/><actinic:variable name="ShipFaxSepOnlineXML"/><actinic:variable name="ShipEmailOnlineXML"/><actinic:variable name="ShipEmailSepOnlineXML"/><actinic:variable name="ShipUserDefinedOnlineXML"/><actinic:variable name="ShipUserDefinedSepOnlineXML"/>
        <actinic:variable name="BillLabelOnlineXML"/>
        <actinic:variable name="BillSalutationOnlineXML"/><actinic:variable name="BillNameOnlineXML"/><actinic:variable name="BillNameSepOnlineXML"/><actinic:variable name="BillTitleOnlineXML"/><actinic:variable name="BillTitleSepOnlineXML"/><actinic:variable name="BillCompanyOnlineXML"/><actinic:variable name="BillCompanySepOnlineXML"/><actinic:variable name="BillAddress1OnlineXML"/><actinic:variable name="BillAddress1SepOnlineXML"/><actinic:variable name="BillAddress2OnlineXML"/><actinic:variable name="BillAddress2SepOnlineXML"/><actinic:variable name="BillAddress3OnlineXML"/><actinic:variable name="BillAddress3SepOnlineXML"/><actinic:variable name="BillAddress4OnlineXML"/><actinic:variable name="BillAddress4SepOnlineXML"/><actinic:variable name="BillPostCodeOnlineXML"/><actinic:variable name="BillPostCodeSepOnlineXML"/><actinic:variable name="BillCountryOnlineXML"/><actinic:variable name="BillCountrySepOnlineXML"/><actinic:variable name="BillPhoneOnlineXML"/><actinic:variable name="BillPhoneSepOnlineXML"/><actinic:variable name="BillFaxOnlineXML"/><actinic:variable name="BillFaxSepOnlineXML"/><actinic:variable name="BillEmailOnlineXML"/><actinic:variable name="BillEmailSepOnlineXML"/><actinic:variable name="BillUserDefinedOnlineXML"/><actinic:variable name="BillUserDefinedSepOnlineXML"/>
        <actinic:variable name="CartOnlineXML"/>
        Try commenting out one of these maybe:
        Code:
        <actinic:variable name="ShipUserDefinedOnlineXML"/>
        <actinic:variable name="ShipUserDefinedSepOnlineXML"/>
        Please can you refund me by the way Order Number: TT12CD10028267?
        Jonathan Chappell
        Website Designer
        SellerDeck Website Designer
        Actinic to SellerDeck upgrades
        Graphicz Limited - www.graphicz.co.uk

        Comment


          #5
          Hi Jonathan,

          Thanks very much for taking a look, really appreciated. I have refunded the order just now.

          Unfortunately the info is all being populated by <actinic:variable name="CartOnlineXML"/>

          I may have to abandon this idea, and try to find a way of adding a custom variable in the shopping cart, if you have any idea on how that can be done I'd be more than happy to pay.
          Many Thanks
          Lee
          www.mdnsupplies.co.uk
          www.hookandloopfasteners.co.uk

          Comment


            #6
            Have a look at Cart.pm around line 665 and see if there is anything you can edit there - backup first!
            Jonathan Chappell
            Website Designer
            SellerDeck Website Designer
            Actinic to SellerDeck upgrades
            Graphicz Limited - www.graphicz.co.uk

            Comment


              #7
              Hi Jonathan,

              Thanks again, I have found a way to remove the date from the order email, it does put a '0 0000' in place but at least it wont confuse the customer, to achieve I changed the following in the cart.pm from:

              Code:
              if ($pCartItem->{'DATE'}) # if Date prompt is given
              {
              my $sDate = $pCartItem->{'DATE'}; # temporal storage of date
              if ($sDate =~ /([0-9]{4})\/([0-9]{2})\/([0-9]{2})/) # parse the date, which is in yyyy/mm/dd format
              {
              my $pXmlDate = new Element(); # create the info child node object
              $pXmlDate->SetTag('Date'); # set the name of node
              $pXmlDate->SetAttributes({ 'Day' => $3, # set the day attribute
              'Month' => $2, # set the month attribute
              'Year' => $1}); # set the year attribute
              $pXmlCartItem->SetChildNode($pXmlDate); # add the info child node to the item node
              }
              }
              with:

              Code:
              if ($pCartItem->{'DATE'}) # if Date prompt is given
              {
              my $sDate = $pCartItem->{'DATE'}; # temporal storage of date
              
              if ($sDate =~ /([0-9]{4})\/([0-9]{2})\/([0-9]{2})/) # parse the date, which is in yyyy/mm/dd format
              {
              # Create the XML node with placeholder values
              my $pXmlDate = new Element();
              $pXmlDate->SetTag('Date');
              $pXmlDate->SetAttributes({
              'Day' => "00", # Set to a neutral or placeholder value
              'Month' => "00", # Set to a neutral or placeholder value
              'Year' => "0000" # Set to a neutral or placeholder value
              });
              $pXmlCartItem->SetChildNode($pXmlDate); # Add the node, so the process continues
              }
              else
              {
              die "The entire date must be specified in the correct format (yyyy/mm/dd)";
              }
              }
              in the shopping basket and pages where the date picker would show, I wrapped a hideme div with a display:none (possibly a messy option but the best I can come up with!).

              EDIT

              So the above is a massive over complication! I will leave the code up as it may help with something else in the future, however, in order to hide the date generated by the .pm file and then passed to the customer email, once you have hidden the date via css or any other means in the shopping basket and checkout steps, navigate to the Design/Library/Layouts/Shopping Cart Order Line Lists and open Email Order Line List, there are 2 instances of PromptLabel and PromptValue on the second comment out PromptValue, save and upload.

              The edit above means no script changes and just hides it from the email.
              Last edited by MDN; 18-Aug-2024, 02:10 PM. Reason: Easier way to hide date
              Many Thanks
              Lee
              www.mdnsupplies.co.uk
              www.hookandloopfasteners.co.uk

              Comment


                #8
                Genius - well done Lee
                Jonathan Chappell
                Website Designer
                SellerDeck Website Designer
                Actinic to SellerDeck upgrades
                Graphicz Limited - www.graphicz.co.uk

                Comment


                  #9
                  Thanks Jonathan, appreciate your help
                  Many Thanks
                  Lee
                  www.mdnsupplies.co.uk
                  www.hookandloopfasteners.co.uk

                  Comment

                  Working...
                  X