#IF(#INPUT.Page)
#ENDIF#IF(#INPUT.PageSize)
#ENDIF#IF(#INPUT.OrderBy)
#ENDIF#IF(#INPUT.OrderDesc)
#ENDIF
#IF(#FormError)
{InputError}
#IF(#FormErrors.Reason.ERROR_INVALIDPRODUCT)
{InvalidProduct}
#ELSE
{PleaseCorrectErrors}
#ENDIF
#REM #ENDREM
#ENDIF
#LOCAL("LocalCategoryProductMaps", #CategoryProductMaps)
#LOCAL("CountCategoryProductMaps",#COUNT(#LocalCategoryProductMaps))
#IF(#Class.Alias EQ "Category" AND #CountCategoryProductMaps AND #System.Child.Groups.Child.Everyone.ID != #ReadPermissionFor)
#REM #ENDREM
#LOCAL("GroupName","")
#WITH(#System.Child.Groups.Child.Registered)
#IF(#ReadPermissionFor EQ #ID)#SET("GroupName","{RegisteredUsersOnly}")#ENDIF
#ENDWITH
#WITH(#Shop.Child.Groups.Child.Merchants)
#IF(#ReadPermissionFor EQ #ID)#SET("GroupName","{AdministratorsOnly}")#ENDIF
#ENDWITH
#LOCAL("UserGroups", #GREP(#Shop.Child.Groups.ChildObjects, "Alias", "Merchants", "NE"))
#IF(#COUNT(#UserGroups) > 0)
#LOOP(#UserGroups)
#IF(#ReadPermissionFor EQ #ID)#SET("GroupName","{UserGroup}: ".#NameOrAlias)#ENDIF
#ENDLOOP
#ENDIF
#ENDLOCAL
{LimitedAccessToCategory} ({ReadPermissionFor}: "#GroupName")
{ProductAccessNotLimited}
#ENDLOCAL
#ENDIF
#BLOCK("PagerProducts", #LocalCategoryProductMaps)
#SNIPPET("INC-PagerHeader", "ContextObjects", "{Products}")
#IF(NOT #DELETE)
#SNIPPET("INC-BatchActions", "BatchActions", "BatchActions")
#REM #ENDREM
#ENDIF
#IF(NOT #CountCategoryProductMaps)
|
#ELSE
|
{SKU}
{BubbleHelpChangeNumberFormat}
{BubbleHelpNumberFormatsLinkText}
|
{Name} #INCLUDE("INC-I18n-Tooltip") |
{ListPrice} |
{StockLevel} |
|
{Position} |
#ENDIF
|
#IF(NOT #CountCategoryProductMaps)
{NoCategoryProducts} |
#ELSE
#LOCAL("CurrencyID",#Shop.CurrencyID)
#LOCAL("ItemIndex", 0)
#LOOP(#Pager.Items)
#LOCAL("PagerItem", #_)
#WITH(#Product)
#LOCAL("ListPrice", #LISTPRICE(#Object, #Shop.CurrencyID, #Shop.InputTaxModel, 1))
|
#INCLUDE("INC-ProductIcon")
#Alias[slice:30,html] #INCLUDE("ProductAdditionalListInfo")
|
#LOCAL("IsNewStatus",0)
#IF(#IsNew OR #DefaultSubProduct.IsNew)
#SET("IsNewStatus",1)
#ENDIF
#ENDLOCAL
|
|
#IF(#SuperProduct)#Name[0] (#JOIN(", ",#SuperProduct.VariationTypeValues)#LOCAL("AttributeValue",#GET(#Attribute.Alias))#AttributeValue.ValueOrAlias#ENDLOCAL#ENDJOIN)#ELSE#Name[0]#ENDIF |
#LOCAL("DisplayPrice",#ListPrice[money])
#LOCAL("PriceRange",#PRICERANGEFORVARIATIONS(#Object, #CurrencyID, #Shop.InputTaxModel))
#IF(#IsMaster AND #PriceRange.LowestPrice)
#IF(#PriceRange.HighestPrice NNE #PriceRange.LowestPrice)
#SET("DisplayPrice",#PriceRange.LowestPrice[money] . " - " . #PriceRange.HighestPrice[money])
#ELSE
#SET("DisplayPrice",#PriceRange.LowestPrice[money])
#ENDIF
#ENDIF
#DisplayPrice |
#ENDLOCAL
#ENDLOCAL
#IF((NOT #IsMaster) AND #DEFINED(#StockLevel))#IF(#StockLevel NE "")#StockLevel[float]#ELSE #ENDIF#ENDIF
|
#LOCAL("IsNotVisibleStatus",0)
#IF(NOT #IsVisible)
#SET("IsNotVisibleStatus",1)
#ENDIF
#SNIPPET("INC-Status", "New,IsNotVisible",#IsNewStatus,#IsNotVisibleStatus)
#ENDLOCAL
|
#BLOCK("WITH_FORM_ERROR", #FormError)
#ENDBLOCK
|
#ENDLOCAL
#ENDWITH
#ENDLOCAL
#SET("ItemIndex", #ItemIndex + 1)
#ENDLOOP
#ENDLOCAL #REM#ENDREM
#ENDLOCAL
#ENDIF
#IF(NOT #DELETE)
#SNIPPET("Pager", "ContextObjects", "{Products}")
#ENDIF
#MENU("SNIPPET-CategoryProducts-Script")
#INCLUDE(#Template)
#ENDMENU
#ENDBLOCK
#ENDLOCAL
#ENDLOCAL