<script type="text/html" template lay-done="layui.data.done(d);">
    <table class="layui-table layui-form" lay-filter="LAY-app-CoreCmsGoods-detailsForm" id="LAY-app-CoreCmsGoods-detailsForm">
        <colgroup>
            <col width="150">
            <col>
        </colgroup>
        <tbody>

            <tr>
                <td>
                    <label for="id">商品ID</label>
                </td>
                <td>
                    {{ d.params.data.id || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="bn">商品编码</label>
                </td>
                <td>
                    {{ d.params.data.bn || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="name">商品名称</label>
                </td>
                <td>
                    {{ d.params.data.name || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="brief">商品简介</label>
                </td>
                <td>
                    {{ d.params.data.brief || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="price">商品价格</label>
                </td>
                <td>
                    {{ d.params.data.price || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="costprice">成本价</label>
                </td>
                <td>
                    {{ d.params.data.costprice || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="mktprice">市场价</label>
                </td>
                <td>
                    {{ d.params.data.mktprice || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="imageIds">默认图片 图片id</label>
                </td>
                <td>
                    {{ d.params.data.imageIds || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="goodsCategoryId">商品分类ID 关联category.id</label>
                </td>
                <td>
                    {{ d.params.data.goodsCategoryId || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="goodsTypeId">商品类别ID 关联goods_type.id</label>
                </td>
                <td>
                    {{ d.params.data.goodsTypeId || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="brandId">品牌ID 关联brand.id</label>
                </td>
                <td>
                    {{ d.params.data.brandId || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="isNomalVirtual">是否虚拟商品</label>
                </td>
                <td>
                    <input type="checkbox" disabled name="isNomalVirtual" value="{{d.params.data.isNomalVirtual}}" lay-skin="switch" lay-text="开启|关闭" lay-filter="isNomalVirtual" {{ d.params.data.isNomalVirtual ? 'checked' : '' }}>
                </td>
            </tr>

            <tr>
                <td>
                    <label for="isMarketable">是否上架</label>
                </td>
                <td>
                    <input type="checkbox" disabled name="isMarketable" value="{{d.params.data.isMarketable}}" lay-skin="switch" lay-text="开启|关闭" lay-filter="isMarketable" {{ d.params.data.isMarketable ? 'checked' : '' }}>
                </td>
            </tr>

            <tr>
                <td>
                    <label for="stock">库存</label>
                </td>
                <td>
                    {{ d.params.data.stock || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="freezeStock">冻结库存</label>
                </td>
                <td>
                    {{ d.params.data.freezeStock || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="weight">重量</label>
                </td>
                <td>
                    {{ d.params.data.weight || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="unit">商品单位</label>
                </td>
                <td>
                    {{ d.params.data.unit || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="intro">商品详情</label>
                </td>
                <td>
                    {{ d.params.data.intro || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="spes_desc">商品规格序列号存储</label>
                </td>
                <td>
                    {{ d.params.data.spes_desc || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="parameters">参数序列化</label>
                </td>
                <td>
                    {{ d.params.data.parameters || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="commentsCount">评论次数</label>
                </td>
                <td>
                    {{ d.params.data.commentsCount || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="viewCount">浏览次数</label>
                </td>
                <td>
                    {{ d.params.data.viewCount || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="buyCount">购买次数</label>
                </td>
                <td>
                    {{ d.params.data.buyCount || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="uptime">上架时间</label>
                </td>
                <td>
                    {{ d.params.data.uptime || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="downtime">下架时间</label>
                </td>
                <td>
                    {{ d.params.data.downtime || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="sort">商品排序</label>
                </td>
                <td>
                    {{ d.params.data.sort || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="labelIds">标签id逗号分隔</label>
                </td>
                <td>
                    {{ d.params.data.labelIds || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="newSpec">自定义规格名称</label>
                </td>
                <td>
                    {{ d.params.data.newSpec || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="createTime">创建时间</label>
                </td>
                <td>
                    {{ d.params.data.createTime || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="updateTime">更新时间</label>
                </td>
                <td>
                    {{ d.params.data.updateTime || '' }}
                </td>
            </tr>

            <tr>
                <td>
                    <label for="isRecommend">是否推荐</label>
                </td>
                <td>
                    <input type="checkbox" disabled name="isRecommend" value="{{d.params.data.isRecommend}}" lay-skin="switch" lay-text="开启|关闭" lay-filter="isRecommend" {{ d.params.data.isRecommend ? 'checked' : '' }}>
                </td>
            </tr>

            <tr>
                <td>
                    <label for="isHot">是否热门</label>
                </td>
                <td>
                    <input type="checkbox" disabled name="isHot" value="{{d.params.data.isHot}}" lay-skin="switch" lay-text="开启|关闭" lay-filter="isHot" {{ d.params.data.isHot ? 'checked' : '' }}>
                </td>
            </tr>

            <tr>
                <td>
                    <label for="isDel">是否删除</label>
                </td>
                <td>
                    <input type="checkbox" disabled name="isDel" value="{{d.params.data.isDel}}" lay-skin="switch" lay-text="开启|关闭" lay-filter="isDel" {{ d.params.data.isDel ? 'checked' : '' }}>
                </td>
            </tr>
        </tbody>
    </table>
</script>
<script>
    layui.data.done = function (d) {
        layui.use(['admin', 'form', 'coreHelper'], function () {
            var $ = layui.$
                , setter = layui.setter
                , admin = layui.admin
                , coreHelper = layui.coreHelper
                , form = layui.form;
            form.render(null, 'LAY-app-CoreCmsGoods-detailsForm');
        });
    };
</script>