|
|
<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
|
|
|
|
|
|
<!--<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Course_sign_id')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-course_sign_id" data-rule="required" data-source="course/sign/index" class="form-control selectpage" name="row[course_sign_id]" type="text" value="">
|
|
|
</div>
|
|
|
</div>-->
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Course_star')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-course_star" class="form-control" step="0.1" name="row[course_star]" type="number">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Teacher_star')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-teacher_star" class="form-control" step="0.1" name="row[teacher_star]" type="number">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Service_star')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-service_star" class="form-control" step="0.1" name="row[service_star]" type="number">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Content')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-content" class="form-control" name="row[content]" type="number">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Pic')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<div class="input-group">
|
|
|
<input id="c-pic" class="form-control" size="50" name="row[pic]" type="text">
|
|
|
<div class="input-group-addon no-border no-padding">
|
|
|
<span><button type="button" id="plupload-files" class="btn btn-danger plupload" data-input-id="c-pic" data-mimetype="*" data-multiple="true" data-preview-id="p-files"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
|
|
<span><button type="button" id="fachoose-files" class="btn btn-primary fachoose" data-input-id="c-pic" data-mimetype="*" data-multiple="true"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
|
|
|
</div>
|
|
|
<span class="msg-box n-right" for="c-pic"></span>
|
|
|
</div>
|
|
|
|
|
|
<!--ul需要添加 data-template和data-name属性,并一一对应且唯一 -->
|
|
|
<ul class="row list-inline plupload-preview" id="p-files" data-template="introtpl" data-name="row[intro]"></ul>
|
|
|
|
|
|
<!--请注意 ul和textarea间不能存在其它任何元素,实际开发中textarea应该添加个hidden进行隐藏-->
|
|
|
|
|
|
<!--这里自定义图片预览的模板 开始-->
|
|
|
<script type="text/html" id="introtpl">
|
|
|
<li class="col-xs-3">
|
|
|
<a href="<%=fullurl%>" data-url="<%=url%>" target="_blank" class="thumbnail">
|
|
|
<img src="<%=fullurl%>" class="img-responsive">
|
|
|
</a>
|
|
|
<a href="javascript:;" class="btn btn-danger btn-xs btn-trash"><i class="fa fa-trash"></i></a>
|
|
|
</li>
|
|
|
</script>
|
|
|
<!--这里自定义图片预览的模板 结束-->
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Course_id')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-course_id" data-source="course/index" class="form-control selectpage" name="row[course_id]" type="text" value="">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Store_id')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-store_id" data-source="store/index" class="form-control selectpage" name="row[store_id]" type="text" value="">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('名字')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-username" class="form-control" name="row[username]" type="text" value="">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('头像')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<div class="input-group">
|
|
|
<input id="c-cover" data-rule="required" class="form-control" size="1" name="row[weChat_pic]"
|
|
|
type="text" value="">
|
|
|
<div class="input-group-addon no-border no-padding">
|
|
|
<span><button type="button" id="plupload-files-cover" class="btn btn-danger plupload"
|
|
|
data-input-id="c-cover" data-mimetype="*" data-multiple="false"
|
|
|
data-preview-id="p-files-cover"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
|
|
<span><button type="button" id="fachoose-files-cover" class="btn btn-primary fachoose"
|
|
|
data-input-id="c-cover" data-mimetype="*" data-multiple="false"><i
|
|
|
class="fa fa-list"></i> {:__('Choose')}</button></span>
|
|
|
</div>
|
|
|
<span class="msg-box n-right" for="c-cover"></span>
|
|
|
</div>
|
|
|
|
|
|
<!--ul需要添加 data-template和data-name属性,并一一对应且唯一 -->
|
|
|
<ul class="row list-inline plupload-preview" id="p-files-cover" data-template="introtpl-cover"
|
|
|
data-name="row[intro]"></ul>
|
|
|
|
|
|
<!--这里自定义图片预览的模板 开始-->
|
|
|
<script type="text/html" id="introtpl-cover">
|
|
|
<li class="col-xs-3">
|
|
|
<a href="<%=fullurl%>" data-url="<%=url%>" target="_blank" class="thumbnail">
|
|
|
<img src="<%=fullurl%>" class="img-responsive">
|
|
|
</a>
|
|
|
<a href="javascript:;" class="btn btn-danger btn-xs btn-trash"><i class="fa fa-trash"></i></a>
|
|
|
</li>
|
|
|
</script>
|
|
|
<!--这里自定义图片预览的模板 结束-->
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<div class="form-group">
|
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Create_time')}:</label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<input id="c-create_time" data-rule="required" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[create_time]" type="text" value="{:date('Y-m-d H:i:s')}">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="form-group layer-footer">
|
|
|
<label class="control-label col-xs-12 col-sm-2"></label>
|
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
<button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
|
|
|
<button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
|
|
|
</div>
|
|
|
</div>
|
|
|
</form> |
...
|
...
|
|