REAPI/app/robot/view/product/setting.html

79 lines
3.6 KiB
HTML
Raw Normal View History

2024-09-29 15:43:18 +08:00
{extend name="../../admin/view/main"}
{block name="button"}
<button data-open='{:url("/merchant/merchant/index/")}' data-title="返回商户列表" class='layui-btn layui-btn-sm layui-btn-primary'>返回商户列表</button>
<button data-open='{:url("/merchant/percent/index/")}?mid={$vo.id}' data-title="折扣设置" class='layui-btn layui-btn-sm layui-btn-primary'>折扣设置</button>
{/block}
{block name="content"}
<div class="layui-tab layui-tab-card think-bg-white table-block">
<div class="layui-tab-content think-box-shadow table-block table-block">
<form class="layui-form" action="{:request()->url()}" data-auto="true" method="post" autocomplete="off">
<table class="layui-table margin-top-10" lay-skin="line">
{notempty name='product'}
<thead>
<tr>
<th class='text-left nowrap' width="100%">为商户 <span class="color-blue">{$vo.name}</span> 设置渠道产品</th>
<th class='text-left nowrap' width=""></th>
<th></th>
</tr>
</thead>
{/notempty}
<tbody>
{foreach $name as $key=>$vv}
<tr>
<td class='text-left nowrap' width="10%">
<span class="color-black" style="font-weight: bold;">【{$vv|default=''}】</span> <span class="color-desc">{$key|default=''}</span>
</td>
<td class='text-left nowrap' width="50%"></td>
<td class='text-left nowrap' width="20%"></td>
</tr>
{if isset($product[$key]) && $product[$key]}
{foreach $product[$key] as $k=>$v}
<tr>
<td class='text-left nowrap'>
<span class="color-blue"><label><input style="width: 42px;height: 20px;margin-top: 9px;" lay-skin="primary" class="list-check-box" value='{$v.id}|{$v.cid}' lay-ignore name="pid[]" type='checkbox' {if $v.select == 1}checked="checked"{/if}></label><span class="color-desc"> ├  </span>{$v.channel.name|default=''}</span> <span class="color-desc">{$v.channel.id|default=''}</span> </span>
</td>
<td class='text-left nowrap'>
<span class="color-desc">优选级(数字越大优先级越高):</span>
<input class="layui-input" type="number" placeholder="请输入数字,数字越大优先级越高" name="sort_{$v.id}" value="{$v.sort|default=''}"/>
</td>
<td class='text-left nowrap'>
{if $v.value}
<span class="color-desc">可选面值(未选择面值则所有面值可用):</span>
{foreach $v.value as $k1 => $v1}
<input type="checkbox" style="width: 42px;height: 20px;margin-top: 9px;" lay-skin="primary" lay-ignore name="cash_{$v.id}[]" value="{$v1}" title="{$v1}" {if $v.cash && in_array($v1, $v.cash)}checked="checked"{/if}><span class="color-green margin-right-10 font-w7">{$v1}</span>
{/foreach}
{/if}
</td>
</tr>
{/foreach}
{/if}
{/foreach}
</tbody>
</table>
<div class="hr-line-dashed"></div>
<input type='hidden' value='{$vo.id}' name='mid'>
<div class="layui-form-item text-center">
<button class="layui-btn" type='submit'>保存设置</button>
</div>
</form>
</div>
</div>
<script>
layui.use(['form','layer'], function(){
var form = layui.form;
var layer = layui.layer;
});
form.render();
</script>
{/block}