241 lines
18 KiB
HTML
241 lines
18 KiB
HTML
<style>
|
|
.star {
|
|
color: red;
|
|
}
|
|
</style>
|
|
<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">用户信息:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class="input-group">
|
|
<input id="c-user" readonly class="form-control" size="50" name="user" type="text">
|
|
<input id="c-uid" readonly name="row[wechat_id]" type="hidden">
|
|
<div class="input-group-addon no-border no-padding">
|
|
<span><button type="button" id="select-user" class="btn btn-info" ><i class="fa fa-user-plus"></i> 选择用户</button></span>
|
|
|
|
</div>
|
|
<span class="msg-box n-right" for="c-user"></span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{volist name="person_fieldset" id="vo"}
|
|
|
|
{if $vo['type'] == 'text' && $vo['field'] != 'address'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'number'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-contacts" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" name="row[custom_content][{$vo['field']}]" type="number" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['field'] == 'member_level_id'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-{$vo['label']}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} data-source="wdsxh/member/level/index" data-order-by="weigh" class="form-control selectpage" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['field'] == 'industry_category_id'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-{$vo['label']}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} data-source="wdsxh/member/industry_category/index" data-order-by="weigh" class="form-control selectpage" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['field'] == 'native_place'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{:__('Native_place')}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class='control-relative'><input id="c-native_place" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" data-level="area" data-toggle="city-picker" name="row[custom_content][{$vo['field']}]" type="text" value=""></div>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['field'] == 'address'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{:__('Address')}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class="input-group">
|
|
<input id="c-address" class="form-control" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} name="row[custom_content][address][address]" type="text" value="">
|
|
<input id="c-lat" name="row[custom_content][address][latitude]" type="hidden" value="">
|
|
<input id="c-lng" name="row[custom_content][address][longitude]" type="hidden" value="">
|
|
<div class="input-group-addon no-border no-padding">
|
|
<span><button type="button" class="btn btn-danger" data-input-id="c-address" data-lat-id="c-lat" data-lng-id="c-lng" data-toggle="addresspicker"><i class="fa fa-location-arrow"></i> 选择位置</button></span>
|
|
</div>
|
|
<span class="msg-box n-right" for="c-images"></span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'radio'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<?php $radio_array = explode(',',$vo['option']);?>
|
|
<div class="radio">
|
|
{foreach name="radio_array" item="vv"}
|
|
<label for="row[{$vo['field']}]-{$key|htmlentities}"><input id="row[{$vo['field']}]-{$key|htmlentities}" name="row[custom_content][{$vo['field']}]" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="checked"{/if} type="radio" value="{$vv|htmlentities}" /> {$vv|htmlentities}</label>
|
|
{/foreach}
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'checkbox'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<?php $check_array = explode(',',$vo['option']);
|
|
?>
|
|
<div class="checkbox">
|
|
{foreach name="check_array" item="vv"}
|
|
<label for="row[{$vo['field']}][]-{$key|htmlentities}"><input {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="checked"{/if} id="row[{$vo['field']}][]-{$key|htmlentities}" name="row[custom_content][{$vo['field']}][]" type="checkbox" value="{$vv|htmlentities}" /> {$vv|htmlentities}</label>
|
|
{/foreach}
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'select' && $vo['field'] != 'member_level_id' && $vo['field'] != 'industry_category_id' && $vo['field'] != 'native_place'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<?php $select_array = explode(',',$vo['option']);?>
|
|
<select id="c-{$vo['field']}}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control selectpicker" name="row[custom_content][{$vo['field']}]">
|
|
<option value="">请选择</option>
|
|
{foreach name="select_array" item="vv"}
|
|
<option value="{$vv|htmlentities}">{$vv|htmlentities}</option>
|
|
{/foreach}
|
|
</select>
|
|
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'date'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-startdate" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control datetimepicker" data-date-format="YYYY-MM-DD" data-use-current="true" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'time'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-{$vo['field']}}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control datetimepicker" data-date-format="HH:mm" data-use-current="true" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'datetime'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-{$vo['field']}}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'image'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class="input-group">
|
|
<input id="c-{$vo['label']}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" size="50" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
<div class="input-group-addon no-border no-padding">
|
|
<span><button type="button" id="faupload-{$vo['label']}" class="btn btn-danger faupload" data-input-id="c-{$vo['label']}" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="{if $vo['field'] == 'avatar'}false{else /}true{/if}" data-preview-id="p-{$vo['label']}"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
|
<span><button type="button" id="fachoose-{$vo['label']}" class="btn btn-primary fachoose" data-input-id="c-{$vo['label']}" data-mimetype="image/*" data-multiple="{if $vo['field'] == 'avatar'}false{else /}true{/if}"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
|
|
</div>
|
|
<span class="msg-box n-right" for="c-{$vo['label']}"></span>
|
|
</div>
|
|
<ul class="row list-inline faupload-preview" id="p-{$vo['label']}"></ul>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'video'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class="input-group">
|
|
<input id="c-{$vo['label']}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" size="50" name="row[custom_content][{$vo['field']}]" type="text" value="">
|
|
<div class="input-group-addon no-border no-padding">
|
|
<span><button type="button" id="faupload-{$vo['label']}" class="btn btn-danger faupload" data-input-id="c-{$vo['label']}" data-mimetype="video/*" data-multiple="false" data-preview-id="p-{$vo['label']}"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
|
<span><button type="button" id="fachoose-{$vo['label']}" class="btn btn-primary fachoose" data-input-id="c-{$vo['label']}" data-mimetype="video/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
|
|
</div>
|
|
<span class="msg-box n-right" for="c-{$vo['label']}"></span>
|
|
</div>
|
|
<ul class="row list-inline faupload-preview" id="p-{$vo['label']}"></ul>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'textarea'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}{$vo['label']}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<textarea class="form-control {if $vo['field'] == 'introduce_content'}editor{/if}" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} rows="5" name="row[custom_content][{$vo['field']}]" cols="50"></textarea>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{if $vo['type'] == 'cert'}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}姓名:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" name="row[custom_content][{$vo.field|htmlentities}][name]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}证书编号:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" name="row[custom_content][{$vo.field|htmlentities}][number]" type="text" value="">
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}<span class="star">*</span>{/if}证书图片:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<div class="input-group">
|
|
<input id="c-{$vo['field']}_image" {if ((isset($vo['apply_show']) && $vo['apply_show'] == 1) || !isset($vo['apply_show'])) && $vo['required'] == '1'}data-rule="required"{/if} class="form-control" size="50" name="row[custom_content][{$vo.field|htmlentities}][image]" type="text" value="">
|
|
<div class="input-group-addon no-border no-padding">
|
|
<span><button type="button" id="faupload-{$vo['field']}_image" class="btn btn-danger faupload" data-input-id="c-{$vo['field']}_image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp,image/webp" data-multiple="false" data-preview-id="p-{$vo['field']}_image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
|
<span><button type="button" id="fachoose-{$vo['field']}_image" class="btn btn-primary fachoose" data-input-id="c-{$vo['field']}_image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
|
|
</div>
|
|
<span class="msg-box n-right" for="c-{$vo['field']}_image"></span>
|
|
</div>
|
|
<ul class="row list-inline faupload-preview" id="p-{$vo['field']}_image"></ul>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{/volist}
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Join_time')}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
<input id="c-join_time" data-rule="required" class="form-control datetimepicker" data-date-format="YYYY-MM-DD" data-use-current="true" name="row[join_time]" type="text" value="{:date('Y-m-d')}">
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
|
|
<div class="col-xs-12 col-sm-8">
|
|
|
|
<div class="radio">
|
|
{foreach name="statusList" item="vo"}
|
|
<label for="row[status]-{$key|htmlentities}"><input id="row[status]-{$key|htmlentities}" name="row[status]" type="radio" value="{$key|htmlentities}" {in name="key" value="normal"}checked{/in} /> {$vo|htmlentities}</label>
|
|
{/foreach}
|
|
</div>
|
|
|
|
</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-primary btn-embossed disabled">{:__('OK')}</button>
|
|
</div>
|
|
</div>
|
|
</form>
|