{echo:JS::import('dialog?skin=tinysimple');} {echo:JS::import('dialogtools');}
{widget:name=distribution action=menu}

# 热销商品推荐：

{query:name=goods where= is_online eq 0 and id in (select goods_id from tiny_order_goods group by goods_id order by count(goods_nums) desc) order=(sell_price-cost_price) desc limit=12}

- {echo:TString::msubstr($item['name'],0,12)}
- {!$price=($item['sell_price'] - $item['cost_price'])}分销利润：{!=$price*$min/100}~{!=$price}{$currency_unit}

{/list}

# 所有商品：

{query:name=goods where= is_online eq 0 page=1 pagesize=12 id=$promotion}

- {echo:TString::msubstr($item['name'],0,12)}
- {!$price=($item['sell_price'] - $item['cost_price'])}分销利润：{!=$price*$min/100}~{!=$price}{$currency_unit}

{/list}