Developer forum

Forum » Templates » Ecom:Order:OrderLine.Type

Ecom:Order:OrderLine.Type


Reply

What are the possible values from this tag:

<!--@Ecom:Order:OrderLine.Type-->

- and what are the definitions/meanings of the values?

EG: 0 = normal order line etc.


Replies

 
Reply

It represents the type of product in that orderline:

 

0 = Stock

1 = Service

2 = BOM

 
Reply
Sorensen wrote:

It represents the type of product in that orderline:

 

0 = Stock

1 = Service

2 = BOM

Thanks. But I would like a complete list. This is in general a problem with DW - the documentation is often note very useful!
 

 

I've noticed that 3 is also a possible value - why didn't you mention that?

 
Reply

I just checked the - and get this - documentation, at I found that I was writing rubbish earlier: http://templates.net.dynamicweb.dk/eCommerce/Dynamicweb-eCommerce-template-tags/Shopping-Cart/Order/Cart/Loops/Orderlines/EcomOrderOrderLine.Type.aspx

 

I was messing it up with Product Type.

 

Apparently the documentation also contains a complete list (0 and 1). In which cases have you noticed it to be 3?

 
Reply
Sorensen wrote:

I just checked the - and get this - documentation, at I found that I was writing rubbish earlier: http://templates.net.dynamicweb.dk/eCommerce/Dynamicweb-eCommerce-template-tags/Shopping-Cart/Order/Cart/Loops/Orderlines/EcomOrderOrderLine.Type.aspx

 

I was messing it up with Product Type.

 

Apparently the documentation also contains a complete list (0 and 1). In which cases have you noticed it to be 3?


Discountcodes

 
Reply

Could you be more specific?

 
Reply
Sorensen wrote:

Could you be more specific?


Sorry, I got it wrong the value 3 comes from a product with a product group discount.

 

Example:

The cart contains two items.

One without discount

One with a product group discount of 50%

The customer entered a discount coupon code in a custom order field, which results in an overall discount of 20%.

 

Values from the cart item loop:

---

productlinetype: 0
ProductNumber: 52046-1_deep
Quantity: 1
Orderline totalprice: kr. 129,00
Discount price without VAT: 103,20
 

---

productlinetype: 0
ProductNumber: LA62045_118_74
Quantity: 1
Orderline totalprice: kr. 99,00
Discount price without VAT: 39,60

---

productlinetype: 3
ProductNumber:
Quantity: 1
Orderline totalprice: kr. -49,50
Discount price without VAT:  0,00

---

productlinetype: 1
ProductNumber:
Quantity: 1
Orderline totalprice: kr. -35,70
Discount price without VAT: 0,00

--- 

I hope this clarifies the issues?

I believe that I have now made it clear that the tag in question can contain the values 0,1,3 - this makes me wonder: can it be 2 as well? are there more codes above 3?

 

That is what I mean when I claim that the documentation is somewhat useless in certain situations. The bottomline is that developing templates for DW can be a very time consuming process.

 
Reply

I just did a bit of researching, and the tag is bound to the ProductLineType enum which has the following entries:

 

 - Product = 0

 - Discount = 1 (percentage or fixed price)
 - Fixed = 2

 - ProductDiscount = 3 (product you get extra or discount granted based on specific products in the basket)

 

So yes, there is a 2 also, but I'm not sure that it is intended for use in an order besides during the price calculation inside ecom.

 
Reply

Btw, if you have any suggestions on how we can make working with templates less time consuming, please let us know.

 
Reply
Sorensen wrote:

Btw, if you have any suggestions on how we can make working with templates less time consuming, please let us know.


1. Make better, and more detailed documentations for template tags.

2. Make the links from DwTemplateTags to corresponding documentation work.

Example: this URL - produced by clicking a link in the list of template tags - doesn't work as intended:

 

http://templates.net.dynamicweb.dk/Default.aspx?ID=1611&q=Ecom:Order:OrderLine.Type

 

 

You must be logged in to post in the forum