🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
## 代码 ``` <!doctype html> <html> <head> <meta charset="utf-8"> <link href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"> </head> <body> <form class="form-horizontal js-ajax-form margin-top-20" action="{:url('rbac/roleeditpost')}" method="post"> <div class="form-group"> <label for="input-name" class="col-sm-2 control-label"><span class="form-required">*</span>角色名称</label> <div class="col-md-6 col-sm-10"> <input type="text" class="form-control" id="input-name" name="name" value="{$data.name}"> </div> </div> <div class="form-group"> <label for="input-remark" class="col-sm-2 control-label">角色描述</label> <div class="col-md-6 col-sm-10"> <textarea type="text" class="form-control" id="input-remark" name="remark">{$data.remark}</textarea> </div> </div> <div class="form-group"> <label class="col-sm-2 control-label">状态</label> <div class="col-md-6 col-sm-10"> <label class="radio-inline"> <php>$active_true_checked=($data['status']==1)?"checked":"";</php> <input type="radio" name="status" value="1" {$active_true_checked}> 开启 </label> <label class="radio-inline"> <php>$active_false_checked=($data['status']==0)?"checked":"";</php> <input type="radio" name="status" value="0" {$active_false_checked}> 禁用 </label> </div> </div> <div class="form-group"> <div class="col-sm-offset-2 col-sm-10"> <input type="hidden" name="id" value="{$data.id}"/> <button type="submit" class="btn btn-primary js-ajax-submit">保存</button> <a class="btn btn-default" href="{:url('admin/rbac/index')}">返回</a> </div> </div> </form> </div> </body> </html> ```