Index.cshtml 3.91 KB
@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers
@{
    Layout = "~/Views/Shared/_LayoutSys.cshtml";
}
@section header
{
    <style type="text/css">
        .footer {
            position: relative;
            top: 180px;
            width: 500px;
            text-align: right;
        }

        .footer-btn {
            margin-right: 40px;
        }
    </style>
}
<blockquote class="layui-elem-quote toolList" id="menus"></blockquote>

<div class="layui-row">
    <div class="layui-col-xs2">
        <ul id="tree" class="ztree" style="padding: 2px; border: 1px solid #ddd; overflow: auto;"></ul>
    </div>
    <div class="layui-col-xs10">
        <table class="layui-table" lay-data="{height: 'full-60', page:true, id:'mainList',limit:50}" lay-filter="list" lay-size="sm">
            <thead>
                <tr>
                    <th lay-data="{checkbox:true, fixed: true}"></th>
                    <th lay-data="{field:'id', width:80,  hide: false}">Id</th>
                    <th lay-data="{field:'code', minWidth:150, fixed: false}">设备组编号</th>
                    <th lay-data="{field:'name', minWidth:150, fixed: false}">设备组名称</th>
                    <th lay-data="{field:'parentId', width:135}">父节点Id</th>
                    <th lay-data="{field:'parentName', width:135}">父节点名称</th>
                    <th lay-data="{field:'remark', minWidth:150}">备注</th>
                </tr>
            </thead>
        </table>
    </div>
</div>

<!--用户添加/编辑窗口-->
<div id="divEdit" style="display: none">
    <form class="layui-form layui-form-pane" action="" id="formEdit">
        <div class="layui-form-item">
            <label class="layui-form-label">设备组编号</label>
            <div class="layui-input-block">
                <input type="text" name="code" v-model="code" required lay-verify="required"
                       placeholder="请输入设备组编号" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">设备组名称</label>
            <div class="layui-input-block">
                <input type="text" name="name" v-model="name" required lay-verify="required"
                       placeholder="请输入设备组名称" autocomplete="off" class="layui-input">
            </div>
        </div>
        @*         <div class="layui-form-item">
            <label class="layui-form-label">排序号</label>
            <div class="layui-input-block">
                <input type="text" name="SortNo" v-model="SortNo" required lay-verify="required" placeholder="请输入排序号" autocomplete="off" class="layui-input">
            </div>
        </div> *@

        <div class="layui-form-item">
            <label class="layui-form-label">父级节点</label>
            <div class="layui-input-block">
                <input id="ParentName" name="parentName" v-model="parentName" class="layui-input" readonly />
                <input id="ParentId" name="parentId" v-model="parentId" type="hidden" />
                <div id="menuContent" class="menuContent" style="display: none;">
                    <ul id="org" class="ztree"></ul>
                </div>
            </div>
        </div>
        <div class="layui-form-item footer">
            <div class="layui-input-block footer-btn">
                <button class="layui-btn layui-btn-normal" lay-submit lay-filter="formSubmit">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
        <div hidden>
            <input name="id" v-model="id" class="layui-input" style="background-color:#eee;" disabled="disabled" type="text" autocomplete="off" lay-verify="">
        </div>
    </form>
</div>


@section Scripts
{
    <script type="text/javascript" src="/productjs/equipment/BaseEquipmentGroup.js" asp-append-version="true"></script>
}