Support

picturepicture

Home | Solutions | Forums | Webinars | Contact

Log inUsernamePassword
Log me on automatically each visit    
Register
Register
Search
Search


Forum Index » Templates

Post new topic   Reply to topic
Templates for Small Businesses --- Lets Share Goto page 1, 2, 3  Next
View previous topic :: View next topic  
Author Message
johnwalls



Joined: 14 Dec 2005
Posts: 18

PostPosted: Thu Feb 23, 2006 3:35 pm    Post subject: Templates for Small Businesses --- Lets Share Reply with quote

OK guys, from what I can tell, most of us here are small businesses. I use markerts works OMS in conjunction with eBay.

Heres my proposition, lets share our templates. I'm sure more than one of us has worked to accomplish a template that many of us could use. Maybe the great forum people here will sticky this or something.

Lets keep it structured. Make sure you say what the template does, in deatil, and what you are using it in conjuntion with, Like eBay, MIVA, etc. Try not to ask for editing info here, pm the author, to try to keep the thread clean.

I'll start with my 2 babies:

First off I have 2 Templates that are printed automatically whenever I download the order, one is a Private template, in other words --safe to be mailed, and the other is a template that stays in house and is filed when the order is complete.

Heres the Private Template Based off of Elegant:
It onyl shows the neccesary invoicing information.

Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

<!--
    Start off with the Base Template
-->
<xsl:import href="System\Base Order Template" />
 
<xsl:output method="html" encoding="utf-8" />

<sw:settings>
    <sw:preview>
        <sw:count>1</sw:count>
    </sw:preview>
    <sw:general>
        <sw:type>standard</sw:type>
        <sw:context>order</sw:context>
    </sw:general>
</sw:settings>

<!--
      The following override the xsl:template's in the base to provide
      image headers for each of the sections.
-->

<xsl:template name="outputPageHeader">
   <div align="center"><img id="imgInvoice" src="http://www.thenewcold.com/header.jpg" /></div>
</xsl:template>



<xsl:template name="outputShipBillHeader">
    <div align="center"><img id="imgBillShip" src="images/billshipping.jpg" /></div>
    <br></br><font size="5"><b>Order Notes:</b></font><br /><xsl:value-of select="//Order/Notes" /><br><br></br></br>
    <font size="5">Shipping Method: </font><strong><xsl:value-of select="//Order/RequestedShipping" /></strong>
   
</xsl:template>

<xsl:template name="outputOrderDetailsHeader">
        <div align="center"><img id="imgOrderInfo" src="images/orderinfo.jpg" /></div>
</xsl:template>

<xsl:template name="outputOrderDetailsFooter">
  <strong>Weight:</strong><br></br> <xsl:value-of select="sum(//Order/Item/Weight)" /> Pounds<br></br><br></br>
  <br></br>
<xsl:value-of select="Label" /><xsl:value-of select="Value" />



<xsl:if test="$templateType != 'invoice'">
        <div class="divider" />
    </xsl:if>
</xsl:template>

<xsl:template name="outputOrderTotalsHeader">
    <div align="center"><img id="imgOrderTotals" src="images/ordertotals.jpg" /></div>
</xsl:template>



</xsl:stylesheet>



Heres the one for in house that shows the paypal transaction ID , credit card information, etc:

Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

<!--
    Start off with the Base Template
-->
<xsl:import href="System\Base Order Template" />
 
<xsl:output method="html" encoding="utf-8" />

<sw:settings>
    <sw:preview>
        <sw:count>1</sw:count>
    </sw:preview>
    <sw:general>
        <sw:type>standard</sw:type>
        <sw:context>order</sw:context>
    </sw:general>
</sw:settings>

<!--
      The following override the xsl:template's in the base to provide
      image headers for each of the sections.
-->

<xsl:template name="outputPageHeader">
   <div align="center"><img id="imgInvoice" src="http://www.thenewcold.com/header.jpg" /></div>
</xsl:template>



<xsl:template name="outputShipBillHeader">
    <div align="center"><img id="imgBillShip" src="images/billshipping.jpg" /></div>
    <br></br><font size="5"><b>Order Notes:</b></font><br /><xsl:value-of select="//Order/Notes" /><br><br></br></br>
    <font size="5">Shipping Method: </font><strong><xsl:value-of select="//Order/RequestedShipping" /></strong>
   
</xsl:template>

<xsl:template name="outputOrderDetailsHeader">
        <div align="center"><img id="imgOrderInfo" src="images/orderinfo.jpg" /></div>
</xsl:template>

<xsl:template name="outputOrderDetailsFooter">
  <strong>Weight:</strong><br></br> <xsl:value-of select="sum(//Order/Item/Weight)" /> Pounds<br></br><br></br>
  <stong>Payment Details:</stong><br></br>
<xsl:for-each select="//Order/Payment/Detail"> <br></br>
<xsl:value-of select="Label" />:<xsl:value-of select="Value" />
</xsl:for-each>

<xsl:if test="$templateType != 'invoice'">
        <div class="divider" />
    </xsl:if>
</xsl:template>

<xsl:template name="outputOrderTotalsHeader">
    <div align="center"><img id="imgOrderTotals" src="images/ordertotals.jpg" /></div>
</xsl:template>



</xsl:stylesheet>






And my final contribution, is our picklist. This picklist shows The order number, the date of the order, the auction and auction title, the part number, and the Payment Method such as Credit Card, Money Order, Etc.

Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

<sw:settings>
    <sw:page-setup>
        <sw:height>8.5</sw:height>
        <sw:width>11</sw:width>
    </sw:page-setup>
    <sw:preview>
        <sw:filter>Not Shipped</sw:filter>
        <sw:count>3</sw:count>
    </sw:preview>
    <sw:general>
        <sw:type>report</sw:type>
    </sw:general>
</sw:settings>

<!-- Import core functions from Common -->
<xsl:import href="System\Common" />

<xsl:output method="html" encoding="utf-8" indent="yes" />

<!--                                                            -->
<!-- Start of processing                                        -->
<!--                                                            -->
<xsl:template match="/">

<html>
     
<head>
<title>
  Deal4u2 Pick List
</title>

<!-- Output all the CSS required for this template -->
<xsl:call-template name="outputStandardCss" />

<style>
   h1
   {
      font-size: 14pt;
   }

</style>

</head>

   <body>
   
        <h1> <xsl:value-of select="//Store/StoreName" /> -- <xsl:value-of select="sw:ToShortDate(//Generated)" /></h1>
       
        <table id="orderdetails" cellspacing="0" cellpadding="0">
       
            <tr class="header">
                <td>Order</td>
                <td>Date</td>
                <td>Name</td>
                <td>Auction</td>
                <td>Inv. Num</td>
                <td>Payment Method</td>
          </tr>       
           
            <!-- Group by item code -->
          <xsl:for-each select="//Order/Item">
                <xsl:sort select="../Number" order="descending" data-type="number" />
               
                <xsl:variable name="address" select="../Address[@type='bill']" />
                                           
                <tr class="orderitem">
                <td><xsl:value-of select="../Number" /></td>
                <td><xsl:value-of select="sw:ToShortDate(../Date)" /></td>
                <td><xsl:value-of select="$address/FirstName" /> - <xsl:value-of select="$address/LastName" /></td>
                <td><xsl:value-of select="Name" /></td>
                <td><xsl:value-of select="Code" /></td>
                <td><xsl:for-each select="../Payment/Detail[Label='Method']"><xsl:value-of select="Value" /></xsl:for-each></td>
              </tr>
                                               
          </xsl:for-each>
           
         </table>
       
   </body>
</html>

</xsl:template>

</xsl:stylesheet>
Back to top
View user's profile
Wes
Site Admin


Joined: 07 Oct 2002
Posts: 7431

PostPosted: Thu Feb 23, 2006 4:20 pm    Post subject: Reply with quote

Hello,

I went ahead and 'stickied' this thread, per Johnwall's suggestion. One thing we are planning on adding to our site is a section devoted to templates that allows users to share templates with the ShipWorks community. Until we have this in place, please feel free to post your shared templates to this forum/thread.

Thanks,

Wes
Interapptive, Inc.
Back to top
View user's profile Visit poster's website
asher02



Joined: 06 Nov 2005
Posts: 33

PostPosted: Thu Mar 16, 2006 1:48 am    Post subject: Reply with quote

Hello, Joining the effort Smile

This is an all in one invoice / order data for Miva
Basically it gathers all info on the order.

Fields that were added beside the normal invoice data:

1.Order status
2.full credit card details, name on card , number, expiration, cvv2 code
3.Customer Gifts cards/Additional check out data field or order notes
4.Shipping status and service used + tracking number etc if available.
5.Cutomer data that was entered on the customer not on a specific order (very handy cause you can have a message on every new order the customer made like returning customer, fraud etc.)


Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

<sw:settings>
    <sw:page-setup>
        <sw:margins>
            <sw:right>0.6</sw:right>
            <sw:left>0.2</sw:left>
        </sw:margins>
        <sw:height>11.7</sw:height>
        <sw:width>8.27</sw:width>
    </sw:page-setup>
    <sw:preview>
        <sw:count>1</sw:count>
        <sw:zoom>100%</sw:zoom>
    </sw:preview>
    <sw:email>
        <sw:store id="1">
            <sw:includeInMenu>False</sw:includeInMenu>
            <sw:subject>Shipment Notification</sw:subject>
        </sw:store>
    </sw:email>

</sw:settings>

<!-- Use the base Standard Template -->
<xsl:import href="System\Standard Order Template" />
 
<!-- Specify the template properties -->
<xsl:variable name="templateType" select="'invoice'" />
<xsl:variable name="showThumbnails" select="true()" />

<xsl:template name="outputBaseTemplateContent">

    <!-- If there is not just a single order its an error -->
    <xsl:if test="count(//Order) != 1">
        <p>
            This template is designed to be per-order.  There are currently
            <xsl:value-of select="count(//Order)" /> orders in the XML input source.
        </p>
        <p>
            Please adjust the template settings to be processed per-order.
        </p>
    </xsl:if>

    <!-- Continue if there is only a single order as input -->
    <xsl:if test="count(//Order) = 1">
   
    <xsl:variable name="order" select="//Order[1]" />

   <xsl:call-template name="outputPageHeader" />
   
    <table id="headerInfo">
        <tr><td><tr><td><img src="http://www.yourdomain/logo.gif" width="310" height="90" /></td></tr></td></tr>
        <tr>
       
            <xsl:call-template name="outputHeaderPreAddress" />       
       
            <td id="storeAddress">
                <xsl:call-template name="formatAddress">
                    <xsl:with-param name="address" select="//Store/Address" />
                </xsl:call-template>

             
             <xsl:if test="//Store/Address/Phone != ''">   
             Phone: <xsl:value-of select="//Store/Address/Phone" /><br />
            </xsl:if>
            <xsl:if test="//Store/Address/Fax != ''"> 
             Fax: <xsl:value-of select="//Store/Address/Fax" /><br />
            </xsl:if>
           
            <xsl:if test="//Store/Address/Email != ''">
                 <xsl:value-of select="//Store/Address/Email" /><br />
            </xsl:if>   
           
            <xsl:if test="//Store/Address/Website != ''">
                    <xsl:value-of select="//Store/Address/Website" /><br />
                </xsl:if>
            </td>
         
            <td id="orderinfo">
                <div> <!-- This div is used only to provide a border -->
                    <table cellspacing="0">
                        <tr><td class="label">Order:</td><td class="value"><xsl:value-of select="$order/Number" /></td></tr>
                       <tr><td class="label">Placed:</td><td class="value"><xsl:value-of select="sw:ToShortDate($order/Date)" /></td></tr>
                        <xsl:if test="$order/Status !=''">
                        <tr><td class="label">Status:</td><td class="value"><font color="red"><xsl:value-of select="$order/Status" /></font></td></tr>
                       </xsl:if>
                    </table>
                </div>
            </td>
        </tr>
    </table>

   <xsl:call-template name="outputShipBillHeader" />
   
    <xsl:call-template name="outputShipToBillTo">
        <xsl:with-param name="order" select="$order" />
    </xsl:call-template>
   
   <xsl:call-template name="outputOrderDetailsHeader" />
   
    <xsl:call-template name="outputOrderDetails">
        <xsl:with-param name="order" select="$order" />
       
        <xsl:with-param name="showAmounts" select="$templateType = 'invoice'" />
    </xsl:call-template>
   
    <xsl:call-template name="outputOrderDetailsFooter" />
   
    <xsl:if test="$templateType = 'invoice'">
   
       <xsl:call-template name="outputOrderTotalsHeader" />
   
        <xsl:call-template name="outputOrderTotals">
            <xsl:with-param name="order" select="$order" />
        </xsl:call-template>
       
    </xsl:if>
   
    <div style="width: {//ContentWidth} in;">
        <xsl:call-template name="outputPageFooter" />
    </div>
   
    <!-- This is the end of the test ensuring a single order -->
    </xsl:if>
       
</xsl:template>




<xsl:template name="outputPageFooter">




        <!-- test to see if there is a credit card payment -->
        <!-- if credit card number exists, output cc info -->
        <xsl:if test="//Order/Payment/CreditCard/Number != '' ">
        <table id="orderdetails">
        <tr class="header">
        <td id="storeAddress" colspan="3">Credit Card Information</td><br></br>
        </tr></table>
           </xsl:if>
         
<xsl:for-each select="//Order/Payment/Detail">
<xsl:value-of select="Label" /> - <xsl:value-of select="Value" /><br />
</xsl:for-each> 
       

   
       

 <br></br>


        <!-- test to see if there are any shipments -->
        <!-- if shipments exist output tracking links -->
        <xsl:if test="count(//Order/Shipment[IsProcessed = 'true']) &gt; 0">
        <table id="orderdetails">
        <tr class="header">
        <td id="storeAddress" colspan="3">Shipment Information</td>
        </tr>
         <tr>
        <tr class="orderitem">
            <td><b><u>Shipping Status</u></b></td>
            <td><b><u>Postal Service Used</u></b></td>
            <td><b><u>Tracking Number</u></b></td>
        </tr>
        </tr>   
        <xsl:for-each select="//Order/Shipment[IsProcessed = 'true']">
            <tr class="orderitem">
                <td>Shipped on <xsl:value-of select="sw:ToShortDate(ShippedDate)" /></td>
                <td><xsl:value-of select="ServiceUsed" /></td>
                <td><xsl:call-template name="outputTrackingLink" /></td>
            </tr>   
        </xsl:for-each>   
        </table>
        </xsl:if>
        <br></br><br></br>
<table id="orderdetails">
<tr class="header">
<td id="storeAddress" colspan="3">Gift Cards / Instruction</td>
        </tr>
        <tr class="orderitem">
        <td><xsl:value-of select="//Order/Notes" /></td>
       
</tr>
</table><table id="orderdetails">
<tr class="header">
<td id="storeAddress" colspan="3">Customer Information</td>
        </tr>
        <tr class="orderitem">
       
        <td><xsl:value-of select="//Customer/Notes" /></td>
       
       
</tr>
</table>

</xsl:template>




</xsl:stylesheet>
Back to top
View user's profile
MattK



Joined: 10 Nov 2005
Posts: 40

PostPosted: Tue Mar 21, 2006 3:43 pm    Post subject: Reply with quote

Just made this and thought I'd share -would welcome any improvements/input as well.

This template is for a Yahoo store but could easily be used for eBay as well with some modifications.

The template is a reminder email to send a PayPal payment. My store has a custom PayPal integration (that takes users to PayPal with all the data filled in) but for reasons unknown some customs fail at this so we have to send tham an email

Best,

/MattK

Here's what it generates:

Dear xx,
Your order #xx has been recieved but we haven't recieved the PayPal payment you indicated you were going to send.

In order to send your payment to us via PayPal please follow these instructions:
1)Log into Your PayPal account.
2)Click on the Send Money tab.
3)Enter the required information:
    Recipient's Email - paypal@xx.com
    Amount - Your Order Total of: $118.80 (including shipping)
    Type - Goods (other)
    Subject - xx.com Order# 4531
    Note - You can leave this field blank unless you need to add additional information


4)Click Continue
5)Review the information on the confirmation page and click Send Money to complete your transaction

As soon as we receive and validate this information your order will be immediately released and processed.

If you believe you've received this message in error, please reply with the PayPal transaction ID from your sent payment.

Thanks for your business and for your prompt attention to this matter.

Sincerely,
The xx.com Customer Service Team

Here's the code:

Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">
<xsl:import href="System\Common" />

<xsl:output method="html" encoding="utf-8" />

<sw:settings>
<sw:preview>
<sw:filter>5 On Hold - PAYPAL PENDING</sw:filter>
<sw:count>15</sw:count>
</sw:preview>
<sw:email>
<sw:store id="2">
<sw:bcc>admin@xxx.com</sw:bcc>
<sw:account>4</sw:account>
<sw:subject>Your xx.com Order {//Order/Number} needs immediate attention.</sw:subject>
</sw:store>
<sw:default>
<sw:includeInMenu>True</sw:includeInMenu>
<sw:subject>Your Order {//Order/Number} Has Shipped</sw:subject>
</sw:default>
</sw:email>
<sw:general>
<sw:context>order</sw:context>
</sw:general>
</sw:settings>

<xsl:template match="/">
<html>

<head>
<title>Shipment Notification</title>

<style>
body, td, table, div { font: 10pt Arial;}
</style>
</head>

<body>
<xsl:variable name="order" select="//Order[1]" />
<xsl:variable name="address" select="$order/Address[@type='bill']" />

Dear <xsl:value-of select="$address/FirstName" />,

<p>
Your order #<xsl:value-of select="$order/Number" /> has been recieved but we haven't recieved the PayPal payment you indicated you were going to send.
</p>

In order to send your payment to us via PayPal please follow these instructions:
<br> 1)Log into Your PayPal account. </br>
<br> 2)Click on the Send Money tab. </br>
<br> 3)Enter the required information: </br>
<ul> Recipient's Email - paypal@xx.com </ul>
<ul> Amount - Your <tr id="orderTotal">
<td class="name">Order Total of: $</td>
<td class="value"><xsl:value-of select="format-number($order/Total, '#,##0.00')" /></td>
</tr> (including shipping) </ul>
<ul> Type - Goods (other)</ul>
<ul> Subject - xxxx.com Order# <xsl:value-of select="$order/Number" /> </ul>
<ul> Note - You can leave this field blank unless you need to add additional information</ul>
<br> 4)Click Continue </br>
<br> 5)Review the information on the confirmation page and click Send Money to complete your transaction</br>
<br></br>

<p>As soon as we receive and validate this information your order will be immediately released and processed.</p>
<p>If you believe you've received this message in error, please reply with the PayPal transaction ID from your sent payment.</p>
<p>Thanks for your business and for your prompt attention to this matter.</p>


Sincerely,<br />

The <xsl:value-of select="//Store/StoreName" /> Customer Service Team

</body>

</html>

</xsl:template>
</xsl:stylesheet>
    Back to top
    View user's profile
    MattK



    Joined: 10 Nov 2005
    Posts: 40

    PostPosted: Tue Mar 21, 2006 3:56 pm    Post subject: Reply with quote

    Here's a Yahoo store shipment notification email that does a few things the included templates do not:
    - shows all of the available address lines that have been used - including country
    - shows item quantity purchased and links to the item in the website
    -reports shipping method by carrier only - not by service actually utlized
    Best,

    /MattK

    Here's what it sends:

    Howard,
    Your order #4789 has shipped and the tracking information is below. Thank you for your business!

    Quantity: 6 - XXX ITEM NAME LINKED XXX
    Quantity: 1 - XXX ITEM NAME LINKED XXX
    Quantity: 4 - XXX ITEM NAME LINKED XXX


    Shipped To:

    John Smith
    Smith's Smithy
    123 Hammer Hwy
    Suite 123
    PO# XXXXXX
    Jupiter, FL 123456
    United States

    Date Shipped: 3/21/2006
    Service Used: UPS
    Tracking Link: 1ZYE7886783857348549

    Thank you for your purchase.
    If you have any questions please don't hesitate to contact us using the Customer Service link on the right and be sure to reference the order number listed above: Customer Service
    Please do not reply to this email.




    Code:
    <?xml version="1.0" encoding="utf-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">
    <xsl:import href="System\Common" />

    <xsl:output method="html" encoding="utf-8" />

    <sw:settings>

    <sw:preview>
    <sw:count>15</sw:count>
    <sw:filter></sw:filter>

    <sw:zoom>100%</sw:zoom>

    </sw:preview>

    <sw:email>
    <sw:store id="2">
        <sw:subject>Your xx.com Order {//Order/Number} Has Shipped</sw:subject>
        <sw:bcc>sales@xx.com</sw:bcc>
    </sw:store>

    <sw:default>

    <sw:includeInMenu>True</sw:includeInMenu>

    <sw:subject>Your Order {//Order/Number} Has Shipped</sw:subject>

    </sw:default>

    </sw:email>

    <sw:general>

    <sw:context>order</sw:context>

    </sw:general>

    </sw:settings>

    <xsl:template match="/">

    <html>

    <head>

    <title>Shipment Notification</title>


    <style>

    body, td, table, div { font: 10pt Arial;}

    </style>

    </head>

    <body>
        <xsl:variable name="order" select="//Order[1]" />
        <xsl:variable name="address" select="$order/Address[@type='bill']" />
       
        <xsl:value-of select="$address/FirstName" />,
       
        <p>
        Your order #<xsl:value-of select="$order/Number" /> has shipped and the tracking information is below.  Thank you for your business!
        </p>

    <xsl:for-each select="//Order/Item"> Quantity: <xsl:value-of select="Quantity" />
     -
     
    <a href="http://www.batteryjunction.com/{Yahoo/ProductID}.html"><xsl:value-of select="Name" /></a><BR />
    </xsl:for-each>
     
    <BR /><BR />

    <!-- test to see if there are any shipments -->
    <!-- if shipments exist output tracking links -->
    <xsl:if test="count(//Order/Shipment[IsProcessed = 'true']) &gt; 0">


    <xsl:for-each select="//Order/Shipment[IsProcessed = 'true']">

    Shipped To:<BR /><BR />

    <xsl:value-of select="Address[@type='ship']/FirstName" /><xsl:text> </xsl:text><xsl:value-of select="Address[@type='ship']/LastName" /><BR />

        <xsl:if test="Address[@type='ship']/Company != ''">
            <xsl:value-of select="Address[@type='ship']/Company" /><BR />
        </xsl:if> 

        <xsl:if test="Address[@type='ship']/Line1 != ''">
            <xsl:value-of select="Address[@type='ship']/Line1" /><BR />
        </xsl:if>   
       
        <xsl:if test="Address[@type='ship']/Line2 != ''">
            <xsl:value-of select="Address[@type='ship']/Line2" /><BR />
        </xsl:if>
       
        <xsl:if test="Address[@type='ship']/Line3 != ''">
            <xsl:value-of select="Address[@type='ship']/Line3" /><BR />
        </xsl:if>   

    <xsl:value-of select="Address[@type='ship']/City" />, <xsl:value-of select="Address[@type='ship']/StateCode" /><xsl:text> </xsl:text> <xsl:value-of select="Address[@type='ship']/PostalCode" /> <xsl:text> </xsl:text><br></br>
    <xsl:value-of select="Address[@type='ship']/CountryName" /><br></br>

    <BR />
    Date Shipped: <xsl:value-of select="sw:ToShortDate(ShippedDate)" /><BR />
    Service Used:  <xsl:if test="//Order/Shipment/ShipmentType = 'Endicia DAZzle'">USPS</xsl:if> <xsl:if test="//Order/Shipment/ShipmentType = 'UPS OnLine Tools'">UPS</xsl:if> <br></br>
    Tracking Link: <xsl:call-template name="outputTrackingLink" /><BR />

    </xsl:for-each>
    </xsl:if>


    <xsl:if test="count(//Order/Shipment[IsProcessed = 'true']) = 0">

    <i>(No shipments)</i>

    </xsl:if>









    <p>

    Thank you for your purchase.<BR></BR>

    If you have any questions please don't hesitate to contact us using the Customer Service link on the right and be sure to reference the order number listed above:  <a href="mailto:customerservice@xx.com?subject=Question regarding my order that has already shipped:">Customer Service</a>

    <br><b>Please do not reply to this email.</b></br>
    </p>

    </body>

    </html>

    </xsl:template>

    </xsl:stylesheet>
    Back to top
    View user's profile
    ejbantz



    Joined: 06 Jan 2006
    Posts: 14

    PostPosted: Mon Aug 28, 2006 6:47 pm    Post subject: Green Customs Form 2976 Reply with quote

    You will probably need to tweak the Left and Top locations of some of the items for your printer. This will only use the first 3 Items in the order. Long items titles will probably not fit correctly.

    What is odd for me is that even though I tell Shipworks the page is 7.25x4.00, it still tells the printer to use 8.5x11. This causes two issues for me.... the printer tells me Page Size mismatch (which I can get by) but it also prints in the upper left corner of the page instead of in the center.

    E. J. Bantz
    http://stores.ebay.com/bengalone
    --




    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE xsl:stylesheet[ <!ENTITY nbsp " "> ]>

    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">
    <xsl:import href="System\Common" />

    <xsl:output method="html" encoding="utf-8" />

    <sw:settings>
    <sw:email>
    <sw:store id="1">
    <sw:to>{//Order/Address[@type='bill']/Email}</sw:to>
    <sw:subject>{//Reference}</sw:subject>
    </sw:store>
    </sw:email>
    <sw:general>
    <sw:type>standard</sw:type>
    <sw:context>order</sw:context>
    </sw:general>
    <sw:printing>
    <sw:client id="2">
    <sw:source>4</sw:source>
    <sw:printer>\\gameserver1\OKI C5150n</sw:printer>
    </sw:client>
    <sw:client id="1">
    <sw:source>261</sw:source>
    </sw:client>
    <sw:client id="4">
    <sw:source>257</sw:source>
    </sw:client>
    </sw:printing>
    <sw:page-setup>
    <sw:margins>
    <sw:bottom>0.125</sw:bottom>
    <sw:top>0.785</sw:top>
    <sw:right>0.125</sw:right>
    <sw:left>0.25</sw:left>
    </sw:margins>
    <sw:height>4</sw:height>
    <sw:width>7.5</sw:width>
    </sw:page-setup>
    <sw:saving>
    <sw:filename>Customs Form {//Order/Number}</sw:filename>
    <sw:filetype>html</sw:filetype>
    </sw:saving>
    <sw:preview>
    <sw:count>8</sw:count>
    <sw:filter>New Filter</sw:filter>
    </sw:preview>
    </sw:settings>

    <xsl:template match="/">
    <html>
    <head>
    <title>Customs Form</title>

    <style media="all">
    body {
    font-family: Tahoma;
    font-size: 7pt;
    height: 4in;
    width: 7.25in;
    }
    * {
    font-family: Tahoma;
    font-size: 7pt;
    margin: 0;
    padding: 0;
    }

    div#SendersAddress, div#ShipToAddress {
    text-transform: capitalize;
    text-align: left;

    }
    div#leftSideContainer {
    clear: both;
    float: left;
    position: relative;
    width: 2.875in;
    height: 2.9in;
    }
    div#rightSideContainer {
    float: right;
    position: relative;
    width: 3.775in;
    height: 2.9in;
    }

    <!-- System/Common Styles -->
    .contactName {
    font-weight: bold;
    }

    <!-- All spacings go here -->
    div#DeclarationMarker {
    left: 1.29in;
    top: .7in;
    position: absolute;
    font-size: 12pt;
    }
    div#DeclarationDescript1 {
    left: 0.0in;
    top: 1.20in;
    position: absolute;
    width: 1.5in;
    }
    div#DeclarationDescript2 {
    left: 0.0in;
    top: 1.35in;
    position: absolute;
    width: 1.5in;
    }
    div#DeclarationDescript3 {
    left: 0.0in;
    top: 1.50in;
    position: absolute;
    width: 1.5in;
    }
    div#DeclarationWeightLb1 {
    left: 1.7in;
    top: 1.20in;
    position: absolute;
    }
    div#DeclarationWeightLb2 {
    left: 1.7in;
    top: 1.35in;
    position: absolute;
    }
    div#DeclarationWeightLb3 {
    left: 1.7in;
    top: 1.50in;
    position: absolute;
    }

    div#DeclarationWeightLbTotal {
    left: 1.7in;
    top: 2.00in;
    position: absolute;
    }

    div#DeclarationWeightOz1 {
    left: 1.97in;
    top: 1.20in;
    position: absolute;
    }
    div#DeclarationWeightOz2 {
    left: 1.97in;
    top: 1.35in;
    position: absolute;
    }
    div#DeclarationWeightOz3 {
    left: 1.97in;
    top: 1.50in;
    position: absolute;
    }

    div#DeclarationWeightOzTotal {
    left: 1.97in;
    top: 2.0in;
    position: absolute;
    }



    div#DeclarationValue1 {
    left: 2.25in;
    top: 1.20in;
    position: absolute;
    }
    div#DeclarationValue2 {
    left: 2.25in;
    top: 1.35in;
    position: absolute;
    }
    div#DeclarationValue3 {
    left: 2.25in;
    top: 1.50in;
    position: absolute;
    }


    div#DeclarationValueTotal {
    left: 2.25in;
    top: 2.0in;
    position: absolute;
    }


    div#SendersAddress {
    top: 0.85in;
    left: 0.5in;
    width: 3.5in;
    position: absolute;
    }
    div#ShipToAddress {
    top: 1.85in;
    left: 0.5in;
    width: 3.5in;
    position: absolute;
    }
    div#DateLeft {
    top: 2.86in;
    position: absolute;
    text-align: left;
    }
    div#DateRight {
    top: 2.86in;
    left: .25in;
    position: absolute;
    text-align: right;
    }
    </style>
    </head>
    <body>

    <xsl:variable name="totalWeight">
    <xsl:choose>
    <xsl:when test="count(//Order/Item)=1">
    <xsl:value-of select="number(//Order/Item[1]/Weight)*number(//Order/Item[1]/Quantity)" />
    </xsl:when>
    <xsl:when test="count(//Order/Item)=2">
    <xsl:value-of select="number(//Order/Item[1]/Weight)*number(//Order/Item[1]/Quantity)+number(//Order/Item[2]/Weight)*number(//Order/Item[2]/Quantity)" />
    </xsl:when>
    <xsl:when test="count(//Order/Item)=3">
    <xsl:value-of select="number(//Order/Item[1]/Weight)*number(//Order/Item[1]/Quantity)+number(//Order/Item[2]/Weight)*number(//Order/Item[2]/Quantity)+number(//Order/Item[3]/Weight)*number(//Order/Item[3]/Quantity)" />
    </xsl:when>
    <xsl:otherwise>
    0
    </xsl:otherwise>
    </xsl:choose>
    </xsl:variable>

    <xsl:variable name="totalValue">
    <xsl:choose>
    <xsl:when test="count(//Order/Item)=1">
    <xsl:value-of select="number(//Order/Item[1]/Total)" />
    </xsl:when>
    <xsl:when test="count(//Order/Item)=2">
    <xsl:value-of select="number(//Order/Item[1]/Total)+number(//Order/Item[2]/Total)" />
    </xsl:when>
    <xsl:when test="count(//Order/Item)=3">
    <xsl:value-of select="number(//Order/Item[1]/Total)+number(//Order/Item[2]/Total)+number(//Order/Item[3]/Total)" />
    </xsl:when>
    <xsl:otherwise>
    0
    </xsl:otherwise>
    </xsl:choose>
    </xsl:variable>


    <table cellpadding="0" cellspacing="0" border="0">
    <tr>
    <td>
    <!-- Marker for Contents Declaration -->
    <div id="leftSideContainer">
    <div id="DeclarationMarker">
    <b>X</b>
    </div>

    <!-- Description of Contents -->
    <div id="DeclarationDescript1">
    (<xsl:value-of select="//Order/Item[1]/Quantity" />) <xsl:value-of select="//Order/Item[1]/Name" />
    </div>
    <div id="DeclarationWeightLb1">
    <xsl:value-of select="floor(//Order/Item[1]/Weight)" />
    </div>
    <div id="DeclarationWeightOz1">
    <xsl:value-of select="16*(number(//Order/Item[1]/Weight)-floor(//Order/Item[1]/Weight))" />
    </div>
    <div id="DeclarationValue1">
    <xsl:value-of select="format-number(//Order/Item[1]/UnitPrice, '#,##0.00')" />
    </div>
    <div id="DeclarationWeightLbTotal">
    <xsl:value-of select="floor($totalWeight)" />
    </div>
    <div id="DeclarationWeightOzTotal">
    <xsl:value-of select="16*(number($totalWeight)-floor($totalWeight))" />
    </div>
    <div id="DeclarationValueTotal">
    <xsl:value-of select="format-number($totalValue, '#,##0.00')" />
    </div>

    <xsl:if test="//Order/Item[2]/Name != ''">
    <div id="DeclarationDescript2">
    (<xsl:value-of select="//Order/Item[2]/Quantity" />)<xsl:value-of select="//Order/Item[2]/Name" />
    </div>
    <div id="DeclarationWeightLb2">
    <xsl:value-of select="floor(//Order/Item[2]/Weight)" />
    </div>
    <div id="DeclarationWeightOz2">
    <xsl:value-of select="16*(number(//Order/Item[2]/Weight)-floor(//Order/Item[2]/Weight))" />
    </div>
    <div id="DeclarationValue2">
    <xsl:value-of select="format-number(//Order/Item[2]/UnitPrice, '#,##0.00')" />
    </div>
    </xsl:if>


    <xsl:if test="//Order/Item[3]/Name != ''">
    <div id="DeclarationDescript3">
    (<xsl:value-of select="//Order/Item[3]/Quantity" />)<xsl:value-of select="//Order/Item[3]/Name" />
    </div>
    <div id="DeclarationWeightLb3">
    <xsl:value-of select="floor(//Order/Item[3]/Weight)" />
    </div>
    <div id="DeclarationWeightOz3">
    <xsl:value-of select="16*(number(//Order/Item[3]/Weight)-floor(//Order/Item[3]/Weight))" />
    </div>
    <div id="DeclarationValue3">
    <xsl:value-of select="format-number(//Order/Item[3]/UnitPrice, '#,##0.00')" />
    </div>
    </xsl:if>

    <!-- Date on Left side of form -->
    <div id="DateLeft">
    <xsl:value-of select="sw:ToShortDate(//Generated)" />
    </div>
    </div>

    <div id="rightSideContainer">
    <!-- Sender's Name and Address :: formatAddress requires System/Common -->
    <div id="SendersAddress">
    <xsl:call-template name="formatAddress">
    <xsl:with-param name="address" select="//Store/Address" />
    </xsl:call-template>
    </div>

    <!-- Addressee's Name and Address :: formatAddress requires System/Common -->
    <div id="ShipToAddress">
    <xsl:call-template name="formatAddress">
    <xsl:with-param name="address" select="//Order/Address[@type='ship']" />
    </xsl:call-template>
    </div>

    <!-- Date on Right side of form -->
    <div id="DateRight">
    <xsl:value-of select="sw:ToShortDate(//Generated)" />
    </div>
    </div>
    </td>
    </tr>
    </table>

    </body>
    </html>

    </xsl:template>
    </xsl:stylesheet>
    Back to top
    View user's profile Visit poster's website
    kellystee



    Joined: 10 Oct 2005
    Posts: 243

    PostPosted: Fri Sep 01, 2006 9:03 am    Post subject: Reply with quote

    Great job on that, EJ! That's helped me a ton. I also saw the post on the "Support" forum and was struggling with pieces of the template, so you saved me a lot of time and effort. BTW, I was able to get the printing to work correctly. See this thread for details: http://www.interapptive.com/support/viewtopic.php?t=2254.

    My only two comments on the template are:
    1. The current template is pulling the weight from an "estimated weight" field (at least that's the case for MW users). My weight for my packages is typically close to this value but not always the same. So I would rather pull the weight field from the same field that is used to print postage, which is sum(//Shipment/TotalWeight). Then users just need to be sure they print the form only after the postage has been printed.

    2. I saved my signature as an image file and placed the image at the following path: \Shipworks\Application Data\Templates\My Templates\Customs Form
    and then embedded the image in the customs form code so that I don't ever have to sign the forms again (hooray hooray hooray). I have updated your code with this change.

    [code]
    <?xml version="1.0" encoding="utf-8"?>
    <!DOCTYPE xsl:stylesheet[ <!ENTITY nbsp " "> ]>

    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">
    <xsl:import href="System\Common" />

    <xsl:output method="html" encoding="utf-8" />

    <sw:settings>
    <sw:printing>
    <sw:client id="1">
    <sw:source>15</sw:source>
    </sw:client>
    <sw:client id="4">
    <sw:source>15</sw:source>
    </sw:client>
    </sw:printing>
    <sw:page-setup>
    <sw:margins>
    <sw:bottom>0</sw:bottom>
    <sw:top>0</sw:top>
    <sw:right>0</sw:right>
    <sw:left>0</sw:left>
    </sw:margins>
    <sw:height>8.5</sw:height>
    <sw:width>11</sw:width>
    </sw:page-setup>
    <sw:saving>
    <sw:filename>Customs Form {//Order/Number}</sw:filename>
    <sw:filetype>html</sw:filetype>
    </sw:saving>
    <sw:preview>
    <sw:count>1</sw:count>
    <sw:filter>Help Find Filter</sw:filter>
    </sw:preview>
    </sw:settings>

    <xsl:template match="/">
    <html>
    <head>
    <title>Customs Form</title>

    <style media="all">
    body {
    font-family: Tahoma;
    font-size: 10pt;
    }
    * {
    margin: 0;
    padding: 0;
    }
    div#SendersAddress, div#ShipToAddress {
    font-weight: bold;
    text-align: left;
    width: 100%;
    }

    <!-- System/Common Styles -->
    .contactName {
    font-weight: bold;
    }

    <!-- All spacings go here -->
    div#DeclarationMarker {
    font-weight: bold;
    left: 1.5625in;
    top: 1.48in;
    position: absolute;
    font-size: 12pt;
    }
    div#DeclarationDescript {
    font-weight: bold;
    left: 0.3125in;
    top: 2in;
    position: absolute
    }
    div#DeclarationWeightlb {
    font-weight: bold;
    left: 2in;
    top: 2in;
    position: absolute
    }
    div#DeclarationWeightoz {
    font-weight: bold;
    left: 2.3125in;
    top: 2in;
    position: absolute
    }
    div#DeclarationValue {
    font-weight: bold;
    left: 2.5625in;
    top: 2in;
    position: absolute;
    }
    div#DeclarationWeightTotallb {
    font-weight: bold;
    left: 2in;
    top: 2.78in;
    position: absolute
    }
    div#DeclarationWeightTotaloz {
    font-weight: bold;
    left: 2.3125in;
    top: 2.78in;
    position: absolute
    }
    div#DeclarationValueTotal {
    font-weight: bold;
    left: 2.5625in;
    top: 2.78in;
    position: absolute;
    }
    div#DateLeft {
    font-weight: bold;
    top: 3.53125in;
    left: .3125in;
    position: absolute;
    }
    div#SignatureLeft {
    font-weight: bold;
    top: 3.30125in;
    left: 1.1875in;
    position: absolute;
    }
    div#SendersAddress {
    font-weight: bold;
    top: 1.5625in;
    left: 3.125in;
    position: absolute;
    }
    div#ShipToAddress {
    font-weight: bold;
    top: 2.59375in;
    left: 3.125in;
    position: absolute;
    }
    div#DateRight {
    font-weight: bold;
    top: 3.53125in;
    left: 3.125in;
    position: absolute;
    }
    div#SignatureRight {
    font-weight: bold;
    top: 3.30125in;
    left: 4.0in;
    position: absolute;
    }
    </style>
    </head>
    <body>
    <xsl:variable name="dateMonth" select="substring-before(sw:ToShortDate(//Generated),'/')" />
    <xsl:variable name="dateYear" select="substring-after(substring-after(sw:ToShortDate(//Generated),'/'),'/')" />

    <!-- Marker for Contents Declaration -->
    <!-- "XX" Marker for "Other" Category -->
    <div id="DeclarationMarker">
    X
    </div>

    <!-- Weight of Contents (Pounds) -->
    <div id="DeclarationWeightlb">
    <td height="8">
    <xsl:choose>
    <xsl:when test="sum(//Shipment/TotalWeight) = 0">
    0
    </xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="floor(sum(//Shipment/TotalWeight))" />
    </xsl:otherwise>
    </xsl:choose>
    </td>
    </div>

    <!-- Weight of Contents (Ounces) -->
    <div id="DeclarationWeightoz">
    <td height="8">
    <xsl:choose>
    <xsl:when test="sum(//Shipment/TotalWeight) - floor(sum(//Shipment/TotalWeight)) = 0">
    0
    </xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="format-number((number(sum(//Shipment/TotalWeight)) - floor(number(sum(//Shipment/TotalWeight)))) * 16, '#')" />
    </xsl:otherwise>
    </xsl:choose>
    </td>
    </div>

    <!-- Value of Contents -->
    <div id="DeclarationValue">
    $2.99
    </div>

    <!-- Total Weight of Contents (Pounds) -->
    <div id="DeclarationWeightTotallb">
    <xsl:choose>
    <xsl:when test="sum(//Shipment/TotalWeight) = 0">
    0
    </xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="floor(sum(//Shipment/TotalWeight))" />
    </xsl:otherwise>
    </xsl:choose>
    </div>

    <!-- Total Weight of Contents (Ounces) -->
    <div id="DeclarationWeightTotaloz">
    <xsl:choose>
    <xsl:when test="sum(//Shipment/TotalWeight) - floor(sum(//Shipment/TotalWeight)) = 0">
    0
    </xsl:when>
    <xsl:otherwise>
    <xsl:value-of select="format-number((number(sum(//Shipment/TotalWeight)) - floor(number(sum(//Shipment/TotalWeight)))) * 16, '#')" />
    </xsl:otherwise>
    </xsl:choose>
    </div>

    <!-- Total Value of Contents -->
    <div id="DeclarationValueTotal">
    $2.99
    </div>

    <!-- Description of Contents -->
    <div id="DeclarationDescript">
    Computer Accessories
    </div>

    <!-- Date on Left Side of Form -->
    <div id="DateLeft">
    <xsl:value-of select="sw:ToShortDate(//Generated)" />
    </div>

    <!-- Signature on Left Side of Form -->
    <div id="SignatureLeft">
    <img src="images/signature.jpg" width="150" />
    </div>

    <!-- Sender's Name and Address :: formatAddress requires System/Common -->
    <div id="SendersAddress">
    Kelly Steensma<br />
    www.lasermods.com<br />
    <xsl:value-of select="//Store/Address/Line1" /><br />
    <xsl:value-of select="//Store/Address/City" /><xsl:text>, </xsl:text>
    Illinois
    <xsl:value-of select="//Store/Address/PostalCode" /><br />
    </div>

    <!-- Addressee's Name and Address :: formatAddress requires System/Common -->
    <div id="ShipToAddress">
    <xsl:call-template name="formatAddress">
    <xsl:with-param name="address" select="//Order/Address[@type='ship']" />
    </xsl:call-template>
    </div>

    <!-- Date on Right Side of Form -->
    <div id="DateRight">
    <xsl:value-of select="sw:ToShortDate(//Generated)" />
    </div>

    <!-- Signature on Right Side of Form -->
    <div id="SignatureRight">
    <img src="images/signature.jpg" width="150" />
    </div>
    </body>
    </html>

    </xsl:template>
    </xsl:stylesheet>
    [/code]
    Back to top
    View user's profile
    great-vacs



    Joined: 21 Sep 2006
    Posts: 4

    PostPosted: Thu Sep 21, 2006 12:20 pm    Post subject: I am looking for a daily sales report Reply with quote

    Yes I am looking for a daily sales report. I wonder if somone already has one made up that they would not mind sharing? After I process my shipping for the day I need to be able to generate a report with the following info for each sale.

    1. Order Number
    2. Customer Email Adress
    3. Customer Name and Adress
    4. Item Title
    5. Ebay item number
    6. Shipping Cost
    7. Tracking number
    8. Date
    9. Sale Amount
    10. Shipping amount


    If it does not have shipping cost and tracking number that is OK but it would be nice.

    Thanks Dustin
    Back to top
    View user's profile Visit poster's website
    pacmats



    Joined: 20 Nov 2006
    Posts: 17

    PostPosted: Tue Nov 21, 2006 6:34 pm    Post subject: Reply with quote

    Wes, you mentioned having a section of the site for members to post their templates. Has that happened yet, or are we still just using this thread?

    Thanks,
    Jason
    Back to top
    View user's profile Visit poster's website
    pacmats



    Joined: 20 Nov 2006
    Posts: 17

    PostPosted: Sat Dec 02, 2006 9:54 am    Post subject: Reply with quote

    I too would really like to get the code for a Daily Sales Report as described by "great-vacs" above. If anyone can provide this code, it would really be appreciated.
    Back to top
    View user's profile Visit poster's website
    tkeela



    Joined: 18 Jan 2006
    Posts: 160

    PostPosted: Sun Jan 07, 2007 6:19 pm    Post subject: Reply with quote

    Wes,

    What is the status of this ?

    Quote:
    One thing we are planning on adding to our site is a section devoted to templates that allows users to share templates with the ShipWorks community.
    Back to top
    View user's profile Visit poster's website
    Wes
    Site Admin


    Joined: 07 Oct 2002
    Posts: 7431

    PostPosted: Mon Jan 08, 2007 8:26 am    Post subject: Reply with quote

    Nothing to announce yet on this. For now, this thread can be used for any template contributions from the ShipWorks community.

    Thanks,

    Wes
    Interapptive, Inc.
    Back to top
    View user's profile Visit poster's website
    Xennus



    Joined: 21 Sep 2006
    Posts: 13

    PostPosted: Mon Jan 08, 2007 2:15 pm    Post subject: Re: I am looking for a daily sales report Reply with quote

    great-vacs wrote:
    Yes I am looking for a daily sales report. I wonder if somone already has one made up that they would not mind sharing? After I process my shipping for the day I need to be able to generate a report with the following info for each sale.

    1. Order Number
    2. Customer Email Adress
    3. Customer Name and Adress
    4. Item Title
    5. Ebay item number
    6. Shipping Cost
    7. Tracking number
    8. Date
    9. Sale Amount
    10. Shipping amount


    If it does not have shipping cost and tracking number that is OK but it would be nice.

    Thanks Dustin


    Anyone come up with something yet? This would be extremely helpful

    Thanks

    Tommy
    Back to top
    View user's profile
    nhasian



    Joined: 27 Feb 2007
    Posts: 44

    PostPosted: Thu Mar 01, 2007 2:29 pm    Post subject: Wiki Shipworks Reply with quote

    Have you considered using Wiki to allow users to post templates, tips, faqs, how-to's etc?

    Wes wrote:
    One thing we are planning on adding to our site is a section devoted to templates that allows users to share templates with the ShipWorks community. Until we have this in place, please feel free to post your shared templates to this forum/thread.
    Back to top
    View user's profile
    Wes
    Site Admin


    Joined: 07 Oct 2002
    Posts: 7431

    PostPosted: Thu Mar 01, 2007 8:15 pm    Post subject: Reply with quote

    Interesting suggestion. Thanks!

    Wes
    Interapptive, Inc.
    Back to top
    View user's profile Visit poster's website
    nhasian



    Joined: 27 Feb 2007
    Posts: 44

    PostPosted: Mon Mar 05, 2007 2:35 am    Post subject: Printing PS Form 2976 Reply with quote

    Hello,

    I'm trying to use the code you have posted, but i cant get the image to appear. I cant figure out where the heck to place it i guess. I saved my signature here:
    C:\Program Files\ShipWorks\Application Data\Templates\My Templates\Customs Form\images\signature.jpg but its not pulling up the image in the template preview page.

    Also I'm not sure how to go about getting Shipworks to print this customs form out when printing an order.


    kellystee wrote:

    2. I saved my signature as an image file and placed the image at the following path: \Shipworks\Application Data\Templates\My Templates\Customs Form
    and then embedded the image in the customs form code so that I don't ever have to sign the forms again (hooray hooray hooray). I have updated your code with this change.
    Back to top
    View user's profile
    pahnub



    Joined: 09 Feb 2007
    Posts: 13

    PostPosted: Fri Mar 16, 2007 1:49 pm    Post subject: Reply with quote

    Here is the code I just modified generate monthly, daily, weekly, (whatever type you want), sales reports. This is my first attempt at xsl its a pretty simple language I enjoyed using it.

    Code:

    <?xml version="1.0" encoding="utf-8"?>

    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

    <sw:settings>
    <sw:page-setup>
        <sw:height>8.5</sw:height>
        <sw:width>11</sw:width>
    </sw:page-setup>
    <sw:preview>
    <sw:count>8</sw:count>
    <sw:zoom>116%</sw:zoom>
    </sw:preview>
    <sw:email>
    <sw:store id="4">
    <sw:to>{//Order/Address[@type='bill']/Email}</sw:to>
    <sw:subject>{//Reference}</sw:subject>
    </sw:store>
    </sw:email>
    <sw:saving>
    <sw:filename>{//Reference}</sw:filename>
    </sw:saving>
    <sw:general>
    <sw:type>report</sw:type>
    </sw:general>
    </sw:settings>

    <!-- Import core functions from Common -->
    <xsl:import href="System\Common" />

    <xsl:output method="html" encoding="utf-8" indent="yes" />

    <!--                                                            -->
    <!-- Start of processing                                        -->
    <!--                                                            -->
    <xsl:template match="/">
    <xsl:param name="order" />
    <html>
         
    <head>
    <title>
        Monthly Order Totals
    </title>

    <!-- Output all the CSS required for this template -->
    <xsl:call-template name="outputStandardCss" />


    <style>
       h1
       {
          font-size: 12pt;
       }

    </style>

    </head>

       <body>
       
            <h1> <xsl:value-of select="//Store/StoreName" /> - Monthly Order Totals</h1>
           
            <table id="orderdetails" cellspacing="0" cellpadding="0">
           
               <tr class="header">
                    <td>Sold</td>
                    <td>Order</td>
                    <td>Name</td>
                    <td>Gross Amount</td>
                    <td>Shipping</td>
                    <td>Shipping Charge</td>
                    <td>Tax</td>
                    <td>Net</td>
                    <td>Carrier</td>
                    <td>State</td>
              </tr>           
               
               
                <!-- Print out details of each order on a seperate row -->
              <xsl:for-each select="//Order/Item">
             
                    <xsl:sort select="../Number" order="descending" data-type="number" />
                    <xsl:variable name="address" select="../Address[@type='bill']" />
                                               
                 <tr class="orderitem">
                    <td><xsl:value-of select="sw:ToShortDate(../Date)" /></td>
                    <td><xsl:value-of select="../Number" /></td>
                    <td><xsl:value-of select="Name" /></td>
                        <xsl:variable name="orderGrs" select="Total" />
                        <xsl:variable name="orderTax" select="sum(../Charge[starts-with(Description, 'Sales Tax')]/Amount)" />
                        <xsl:variable name="orderShp" select="sum(../Charge[starts-with(Description, 'Shipping')]/Amount)" />
                        <xsl:variable name="orderCst" select="../Shipment/TotalCharges" />
                    <td><xsl:value-of select="format-number($orderGrs, '$#,##0.00')" /></td><!--gross amount -->
                    <td><xsl:value-of select="format-number($orderShp, '$#,##0.00')" /></td><!--shipping amount -->
                    <td><xsl:value-of select="format-number($orderCst, '$#,##0.00')" /></td><!--shipping cost -->
                    <td><xsl:value-of select="format-number($orderTax, '$#,##0.00')" /></td> <!--tax amount -->
                    <td><xsl:value-of select="format-number($orderGrs + $orderShp, '$#,##0.00')" /></td><!--Total including shipping-->   
                    <td><xsl:value-of select="../Shipment/ServiceUsed" /></td> 
                    <td><xsl:value-of select="../Address/StateCode" /></td>
                    </tr>
                                   
              </xsl:for-each>
             
                       
            </table>
            <br></br>
            <br></br>
            <table id="footer" cellspacing="2" cellpadding="2" width="740">
                <tr class="totalOutputTitles">
                    <td align="center"><b>Number of orders</b></td>
                    <td align="center"><b>Total Sales</b></td>
                    <td align="center"><b>Total Shipping</b></td>
                    <td align="center"><b>Total Shipping Cost</b></td>
                    <td align="center"><b>Total Ship Profit</b></td>
                    <td align="center"><b>Total Gross Sales</b></td>
                    <td align="center"><b>Total Tax</b></td>
                </tr>
                <tr class="totalOutputValues">
                    <td align="center"><xsl:value-of select="count(//Order)" /></td>  <!-- number of orders -->
                    <xsl:variable name="totalTax" select="sum(//Order/Charge[starts-with(Description, 'Sales Tax')]/Amount)" />
                    <xsl:variable name="totalShipping" select="sum(//Order/Charge[starts-with(Description, 'Shipping')]/Amount)" />
                    <xsl:variable name="totalGross" select="sum(//Order/Total)" />
                    <xsl:variable name="totalCost" select="sum(//Order/Shipment[IsProcessed = 'true']/TotalCharges)" />
                    <td align="center"><xsl:value-of select="format-number($totalGross, '$#,##0.00')" /></td> <!-- gross amount -->
                    <td align="center"><xsl:value-of select="format-number($totalShipping, '$#,##0.00')" /></td> <!-- shipping -->
                    <td align="center"><xsl:value-of select="format-number($totalCost, '$#,##0.00')" /></td><!-- total cost of shipping-->
                    <td align="center"><xsl:value-of select="format-number($totalShipping - $totalCost, '$#,##0.00')" /></td> <!-- total shipping profit -->
                    <td align="center"><xsl:value-of select="format-number($totalGross + $totalShipping, '$#,##0.00')" /></td> <!-- total sales with shipping (no tax) -->
                    <td align="center"><xsl:value-of select="format-number($totalTax, '$#,##0.00')" /></td> <!-- tax -->
                               
                </tr>
            </table>
           
       </body>
    </html>

    </xsl:template>

    </xsl:stylesheet>


    a good portion of the code I borrowed from someone else's post here about generating a daily status report. I fixed a few things in the old code and added a bunch of new columns. Lastly, you should print this in landscape view, so be sure to change that setting.
    Back to top
    View user's profile
    PiranhaGear



    Joined: 19 Feb 2007
    Posts: 166

    PostPosted: Tue Mar 20, 2007 1:21 am    Post subject: eBay Check-off Report (hacks and all) but want 1 more piece? Reply with quote

    I took pahnub's Daily Summary and altered it to give a "daily detail" - bear with me as I'm just learning what the program can do...

    I wanted something that would list each line item of every order on it's own so I can find and promote the eBay "need to ship" items for the day. It's useful for me and I thought others might like it?

    This is pretty wide, so I use it in Landscape so the eBay Item Name doesn't wrap like crazy.

    I'm using it as is, but I had to put a couple of embarrasing hacks in to make it work (so be warned)...

    1) I couldn't get the buyer's name to stop word-wrapping so I put a "." between the names.

    2) The Sales Tax hack is hardcoded in and so embarassing that I almost didn't post this at all... <g> That also meant the totals for the report wouldn't work, but I don't need totals on this.

    If someone wanted to add something (Wes the Wizard???), it would be great to have the eBay Buyer's ID instead of their email address. I just couldn't get that to work. It would also be nice to the have eBay transaction ID instead of (or with) the item's name.

    A report date/time stamp would be nice too, but I didn't find that in the docs and don't really need it for me.

    I hope this saves someone else some time...

    Bill

    <?xml version="1.0" encoding="utf-8"?>

    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:sw="http://www.interapptive.com/shipworks" extension-element-prefixes="sw">

    <sw:settings>
    <sw:label-sheet>
    <sw:name>Plain Paper - 2 Up</sw:name>
    <sw:brand>USPS</sw:brand>
    </sw:label-sheet>
    <sw:page-setup>
    <sw:margins>
    <sw:right>0.15</sw:right>
    <sw:left>0.15</sw:left>
    </sw:margins>
    <sw:height>8.5</sw:height>
    <sw:width>11</sw:width>
    </sw:page-setup>
    <sw:preview>
    <sw:count>16</sw:count>
    <sw:zoom>116%</sw:zoom>
    </sw:preview>
    <sw:email>
    <sw:store id="1">
    <sw:to>{//Order/Address[@type='bill']/Email}</sw:to>
    <sw:subject>New Dailyt Number two</sw:subject>
    </sw:store>
    <sw:store id="4">
    <sw:to>{//Order/Address[@type='bill']/Email}</sw:to>
    <sw:subject>{//Reference}</sw:subject>
    </sw:store>
    </sw:email>
    <sw:saving>
    <sw:filename>{//Reference}</sw:filename>
    </sw:saving>
    <sw:general>
    <sw:type>report</sw:type>
    </sw:general>
    </sw:settings>

    <!-- Import core functions from Common -->
    <xsl:import href="System\Common" />

    <xsl:output method="html" encoding="utf-8" indent="yes" />

    <!-- -->
    <!-- Start of processing -->
    <!-- -->
    <xsl:template match="/">
    <xsl:param name="order" />
    <html>

    <head>
    <title>
    Daily Sales Report for eBay check-off
    </title>

    <!-- Output all the CSS required for this template -->
    <xsl:call-template name="outputStandardCss" />


    <style>
    h1
    {
    font-size: 12pt;
    }

    </style>

    </head>

    <body>

    <h1> <xsl:value-of select="//Store/StoreName" /> - eBay "Need to Ship" check-off </h1>

    <table id="orderdetails" cellspacing="0" cellpadding="0">

    <tr class="header">
    <td>Sold</td>
    <td>Buyer'sName</td>
    <td>e-mail addr</td>
    <td>ShippingCity</td>
    <td>State</td>
    <td>Cnty</td>
    <td>eBay Item Name</td>
    <td>Unit</td>
    <td>TotAmt</td>
    </tr>


    <!-- Print out details of each order on a seperate row -->
    <xsl:for-each select="//Order/Item">

    <xsl:sort select="../Number" order="ascending" data-type="number" />
    <xsl:variable name="address" select="../Address[@type='bill']" />
    <xsl:variable name="eBay" select="../Address[@type='bill']" />

    <tr class="orderitem">
    <td><xsl:value-of select="sw:ToShortDate(../Date)" /></td>
    <td><xsl:value-of select="$address/FirstName" />.<xsl:value-of select="$address/LastName" /></td>
    <td><xsl:value-of select="$address/Email" /></td>
    <td><xsl:value-of select="$address/City" /></td>
    <td><xsl:value-of select="$address/StateCode" /></td>
    <td><xsl:value-of select="$address/CountryCode" /></td>
    <td><xsl:value-of select="Name" /></td>
    <td><xsl:value-of select="format-number(UnitPrice, '#,##0.00')" /></td>
    <xsl:variable name="orderGrs" select="Total" />
    <xsl:variable name="orderShp" select="sum(../Charge[starts-with(Description, 'Shipping')]/Amount)" />
    <xsl:variable name="orderCst" select="../Shipment/TotalCharges" />
    <xsl:choose>
    <xsl:when test="$address/CountryCode = 'US' and $address/StateCode = 'CA' ">
    <td><xsl:value-of select="format-number($orderGrs + $orderShp + (UnitPrice * 0.0825), '#,##0.00')" /></td><!--gross amount -->
    </xsl:when>
    <xsl:otherwise>
    <td><xsl:value-of select="format-number($orderGrs + $orderShp, '#,##0.00')" /></td><!--gross amount -->
    </xsl:otherwise>
    </xsl:choose>
    </tr>

    </xsl:for-each>


    </table>
    </body>
    </html>

    </xsl:template>

    </xsl:stylesheet>
    Back to top
    View user's profile Visit poster's website
    Brandon



    Joined: 14 Nov 2005
    Posts: 1152

    PostPosted: Tue Mar 20, 2007 9:35 am    Post subject: Reply with quote

    I'm sure this is a useful template for ebay stores, so I'll help you clean it up a little.
    Code:
    <td><xsl:value-of select="$address/FirstName" />.<xsl:value-of select="$address/LastName" /></td>

    Can become:
    Code:
    <td nowrap="nowrap"><xsl:value-of select="$address/FirstName" /><xsl:text> </xsl:text><xsl:value-of select="$address/LastName" /></td>
    (adding the nowrap attribute will force this cell to never wrap the text inside)

    To access the customer's eBay Buyer's ID, use
    Code:
    <xsl:value-of select="//Customer/eBay/BuyerID" />


    To access the customer's eBay Transaction ID, use
    Code:
    <xsl:value-of select="//Order/Item/eBay/TransactionID" />


    and for a quick time stamp:
    Code:
    <xsl:value-of select="sw:ToShortDate(//Generated)" />

    or
    Code:
    <xsl:value-of select="sw:FormatDateTime(//Generated, 'MMM. dd, yyyy hh:mm:ss tt')" />


    Unfortunately, I don't have access to an eBay store so I don't know how tax is handled.
    Back to top
    View user's profile
    PiranhaGear



    Joined: 19 Feb 2007
    Posts: 166

    PostPosted: Tue Mar 20, 2007 11:10 am    Post subject: Reply with quote

    Thanks so much Brandon for the clean-up. I also noticed last night that there's a bug with the quantity and the tax amount...

    I know the eBay ID and transaction number SHOULD be printed with that code, but for some resaon I just get a blank (which tells me I either miss-typed a field name or I'm addressing it at the wrong level). Just putting

    <xsl:value-of select="//Order/Item/eBay/TransactionID" />

    in the detail of the report won't work for me... I haven't figured out why.

    Including Brandon's changes, the detail for each line works better with this... (I also added a Quantity column, but that's pretty easy to do and won't fill the post with that).

    (I feel kind of bad posting stuff that's not hammered out yet and filling up the thread - I hope you guys don't mind)

    Bill

    <!-- Print out details of each order on a seperate row -->
    <xsl:for-each select="//Order/Item">

    <xsl:sort select="../Number" order="ascending" data-type="number" />
    <xsl:variable name="address" select="../Address[@type='ship']" />

    <tr class="orderitem">
    <td><xsl:value-of select="sw:ToShortDate(../Date)" /></td>
    <td nowrap="nowrap"><xsl:value-of select="$address/FirstName" /><xsl:text> </xsl:text><xsl:value-of select="$address/LastName" /></td>
    <td><xsl:value-of select="$address/Email" /></td>
    <td><xsl:value-of select="$address/City" /></td>
    <td><xsl:value-of select="$address/StateCode" /></td>
    <td><xsl:value-of select="$address/CountryCode" /></td>
    <td><xsl:value-of select="Name" /></td>
    <td><xsl:value-of select="Quantity" /></td>
    <td><xsl:value-of select="format-number(UnitPrice, '#,##0.00')" /></td>
    <xsl:variable name="orderGrs" select="Total" />
    <xsl:variable name="orderShp" select="sum(../Charge[starts-with(Description, 'Shipping')]/Amount)" />
    <xsl:variable name="orderCst" select="../Shipment/TotalCharges" />
    <xsl:choose>
    <xsl:when test="$address/CountryCode = 'US' and $address/StateCode = 'CA' ">
    <td><xsl:value-of select="format-number($orderGrs + $orderShp + (Quantity * UnitPrice * 0.0825), '#,##0.00')" /></td><!--gross amount WITH tax-->
    </xsl:when>
    <xsl:otherwise>
    <td><xsl:value-of select="format-number($orderGrs + $orderShp, '#,##0.00')" /></td><!--gross amount without tax-->
    </xsl:otherwise>
    </xsl:choose>
    </tr>

    </xsl:for-each>
    Back to top
    View user's profile Visit poster's website
    pahnub



    Joined: 09 Feb 2007
    Posts: 13

    PostPosted: Tue Mar 20, 2007 12:50 pm    Post subject: Reply with quote

    Just real quick about your tax code, in my code above I used the following:

    Code:
    <xsl:variable name="orderTax" select="sum(../Charge[starts-with(Description, 'Sales Tax')]/Amount)" />


    This grabs all of the tax information which ShipWorks imports with the description of Sales Tax. This way you won't need to have the code calculate it for you, and instead you will actually be capturing the sales tax you charged your customers. If you need to capture it in manual orders as well, just put Sales Tax in the description of the charges field when you manually enter the order.

    As for your problem with the transaction ID try using the following code instead:

    Code:
    <xsl:value-of select="../Item/eBay/TransactionID" />


    That should fix the problem for you.
    Back to top
    View user's profile
    Brandon



    Joined: 14 Nov 2005
    Posts: 1152

    PostPosted: Tue Mar 20, 2007 1:24 pm    Post subject: Reply with quote

    PiranhaGear wrote:
    Thanks so much Brandon for the clean-up. I also noticed last night that there's a bug with the quantity and the tax amount...

    I know the eBay ID and transaction number SHOULD be printed with that code, but for some resaon I just get a blank (which tells me I either miss-typed a field name or I'm addressing it at the wrong level). Just putting

    <xsl:value-of select="//Order/Item/eBay/TransactionID" />

    in the detail of the report won't work for me... I haven't figured out why.

    sorry, I wasn't clear enough about that. That is simple the path to the TransactionID. It has to be in reference to an actual Item node (either by specifying the Item ID as an attribute or inside of a loop of all items).
    Back to top
    View user's profile
    PiranhaGear



    Joined: 19 Feb 2007
    Posts: 166

    PostPosted: Thu Mar 22, 2007 1:09 am    Post subject: Reply with quote

    I can see how the eBay TransactionID and sales tax fix would work, but they don't seem to run for me. I'm sure it's something to do with nesting the detail and the orders. I just keep getting a "blank" for the item instead of any numbers... (and I didn't want to turn this into a debugging thread)... I'll just have to try it again when I have "extra time"

    I hope someone else can find this report useful as is - it's working for me right now... It could just be better... Maybe someone else can take it on as a project... in their "extra time"...

    Thanks,
    Bill
    Back to top
    View user's profile Visit poster's website
    vipfashions



    Joined: 21 Mar 2007
    Posts: 32

    PostPosted: Thu Mar 22, 2007 10:45 am    Post subject: need help with putting ups or endica label on invoice. Reply with quote

    I am very new to shipworks and I want to know if it is possible to print the invoice from ship works with the ups or usps endicia label on the bottom so i can pull the item box it peel the label and put the invoice in the box and ship it. If anyone can help me out I would greatly appreciate it. Thank you
    Back to top
    View user's profile
    onestopfanshop



    Joined: 04 Apr 2007
    Posts: 56

    PostPosted: Wed Apr 04, 2007 5:06 pm    Post subject: Please Help, I need a basic email Template Reply with quote

    Hello everyone,
    I'm a new customer and needing help right away to keep my business going until I figure out this crazy code. I dropship some of my orders and have to send a order form to other warehouses to place the order. My idea was to right click on each order one at a time and send a template by email to the fulfillment warehouse. I have filters set up to filter by distribution locations into each folder, so this function can be done by each folder as well. Once a template is sent, the item is removed from the folder so the order isn't places twice. If someone can help me out that would be great. These are the fields that I will need

    Title at the top to show a image or my company name "onestopfanshop, inc" and the date of the email.

    Invoice # "PO #"

    Fields for the "shipping" side, not the billing fields
    First name
    Last name
    company
    Address 1-3
    City, state, zip
    Email address
    Phone


    QTY
    Code
    Item Title


    I would love for it to only do one item at a time. I want to be able to right click on a item and send a Template with the information listed above only one at a time. Please, Please, Please someone help me out. I know this is really simple but the code is way over my head at this point.
    Thanks in advance, Mike
    Back to top
    View user's profile
    Display posts from previous:   
    Post new topic   Reply to topic     Forum Index » Templates All times are GMT - 7 Hours
    Goto page 1, 2, 3  Next
    Page 1 of 3

     
    Jump to:  

    Powered by phpBB © 2001, 2002 phpBB Group