123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- {extend name="common/common2" /}
- {block name="main"}
- <div class="row">
- <div class="col-sm-12">
- <div class="ibox float-e-margins">
- <div class="ibox-content">
- <form method="post" action="{:url('add')}" class="form-horizontal">
- <input type="hidden" name="parent_id" value="{$pid}">
- <input type="hidden" name="type" value="{$t}">
- <div class="form-group">
- <label class="col-sm-2 control-label">名称 <span class="text-danger">*</span></label>
- <div class="col-sm-6">
- <input type="text" class="form-control" name="name" value="{$info.name|default=''}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label">排序</label>
- <div class="col-sm-6">
- <input type="number" class="form-control" name="sort" value="{$info.sort|default='100'}">
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label">备注</label>
- <div class="col-sm-6">
- <textarea name="content" class="form-control" rows="3">{$info.content|default=''}</textarea>
- </div>
- </div>
- <div class="form-group">
- <label class="col-sm-2 control-label">状态</label>
- <div class="col-sm-6">
- <label class="cr-inline">
- <input type="radio" value="1" name="enable">启用
- </label>
- <label class="cr-inline">
- <input type="radio" value="0" name="enable">禁用
- </label>
- </div>
- </div>
- {if condition="$t == 2"}
- <div class="form-group">
- <label class="col-sm-2 control-label">地图标注</label>
- <div class="col-sm-6">
- {:widget_view('common/gdmap',['name'=>'location', 'val' => isset($info['location'])?$info['location']:''])}
- </div>
- </div>
- {/if}
- {if isset($infotype) && $infotype == 1}
- <div class="form-group">
- <label class="col-sm-2 control-label">城市</label>
- <div class="col-sm-6">
- <select name="city_id" class="form-control">
- <option value="0">选择城市</option>
- {foreach $city as $k=>$v}
- <option value="{$v.id}">{$v.title}</option>
- {/foreach}
- </select>
- </div>
- </div>
- {/if}
- <div class="hr-line-dashed"></div>
- <div class="form-group">
- <div class="col-sm-6 col-sm-offset-2">
- <button class="btn btn-primary ajax-post" data-layer="1" target-form="form-horizontal" type="submit">确 定</button>
- </div>
- </div>
- </form>
- </div>
- </div>
- </div>
- </div>
- {/block}
- {block name="script"}
- <script>
- $(document).ready(function(){
- formSetValue("enable", {$info.enable|default=1});
- });
- </script>
- {/block}
|