File: /www/wwwroot/www.kvrdp.com/runtime/temp/fb415e0e9b3ea443cff5580a2a727ac9.php
<?php /*a:7:{s:61:"/www/wwwroot/www.kvrdp.com/application/cms/view/cms/edit.html";i:1665207834;s:67:"/www/wwwroot/www.kvrdp.com/application/admin/view/index_layout.html";i:1665207834;s:67:"/www/wwwroot/www.kvrdp.com/application/admin/view/inputItemExt.html";i:1665207834;s:89:"/www/wwwroot/www.kvrdp.com/application/cms/view/../../../addons/editormd/editormdExt.html";i:1665207834;s:64:"/www/wwwroot/www.kvrdp.com/application/admin/view/inputItem.html";i:1665207834;s:64:"/www/wwwroot/www.kvrdp.com/application/cms/view/cms/cmsItem.html";i:1665207834;s:60:"/www/wwwroot/www.kvrdp.com/application/admin/view/layui.html";i:1665207834;}*/ ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<title><?php echo config('system_name'); ?>后台管理系统</title>
<meta name="author" content="<?php echo config('system_name'); ?>">
<meta name="csrf-token" content="<?php echo think\facade\Request::token('__token__'); ?>">
<link rel="stylesheet" href="/static/libs/layui/css/layui.css">
<link rel="stylesheet" href="/static/admin/css/admin.css?v=<?php echo htmlentities(app('config')->get('version.yzncms_release')); ?>">
<link rel="stylesheet" href="/static/common/font/iconfont.css?v=<?php echo htmlentities(app('config')->get('version.yzncms_release')); ?>">
<link rel="stylesheet" href="/static/admin/css/my.css">
<script src="/static/libs/layui/layui.js"></script>
<script src="/static/libs/jquery/jquery.min.js"></script>
<script type="text/javascript">
//全局变量
var GV = {
'site':<?php echo json_encode($site); ?>,
'image_upload_url': '<?php echo !empty($image_upload_url) ? htmlentities($image_upload_url) : url("attachment/upload/upload", ["dir" => "images"]); ?>',
'file_upload_url': '<?php echo !empty($file_upload_url) ? htmlentities($file_upload_url) : url("attachment/upload/upload", ["dir" => "files"]); ?>',
'ueditor_upload_url': '<?php echo !empty($ueditor_upload_url) ? htmlentities($ueditor_upload_url) : url("attachment/upload/upload", ["dir" => "images","from"=>"ueditor"]); ?>',
'attachment_select_url': '<?php echo !empty($attachment_select_url) ? htmlentities($attachment_select_url) : url("attachment/attachments/select"); ?>',
};
</script>
</head>
<body class="childrenBody <?php echo defined('IS_DIALOG') && IS_DIALOG ? 'is-dialog' : ''; ?>">
<link rel="stylesheet" href="/static/admin/css/cms.css">
<div class="layui-card">
<div class="layui-card-body layui-form-pane">
<form class="layui-form" method="post">
<div class="layui-col-md8">
<div class="layui-card">
<div class="layui-tab">
<ul class="layui-tab-title">
<?php if(is_array($sites) || $sites instanceof \think\Collection || $sites instanceof \think\Paginator): $i = 0; $__LIST__ = $sites;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$site): $mod = ($i % 2 );++$i;?>
<li <?php if($i==1): ?>class="layui-this"<?php endif; ?>> <?php if($site['mark']): ?> <img src="/static/lang/image/<?php echo htmlentities($site['mark']); ?>.png" title="<?php echo htmlentities($site['name']); ?>"><?php endif; ?> <?php echo htmlentities($site['name']); ?></li>
<?php endforeach; endif; else: echo "" ;endif; ?>
</ul>
<div class="layui-tab-content">
<?php if(is_array($extra_data) || $extra_data instanceof \think\Collection || $extra_data instanceof \think\Paginator): $k = 0; $__LIST__ = $extra_data;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$s): $mod = ($k % 2 );++$k;?>
<div class="layui-tab-item <?php if($k==1): ?>layui-show<?php endif; ?>">
<input type="hidden" name="extra_data[<?php echo htmlentities($k); ?>][site_id]" value="<?php echo htmlentities($s['site_id']); ?>" />
<input type="hidden" name="extra_data[<?php echo htmlentities($k); ?>][id]" value="<?php echo htmlentities($s['id']); ?>" />
<?php if(is_array($extraFieldList) || $extraFieldList instanceof \think\Collection || $extraFieldList instanceof \think\Paginator): $i = 0; $__LIST__ = $extraFieldList;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i; $value = '';
if(!empty($s[$vo['name']])){
$value= $s[$vo['name']];
}
switch($vo['type']): case "hidden": if($vo['value']): ?><input type="hidden" class="form-control" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>"><?php endif; break; case "text": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>" title="<?php echo getSiteName($k); ?><?php echo htmlentities($vo['title']); ?>"><?php echo getSiteName($k); ?><?php echo htmlentities($vo['title']); ?> </label>
<div class="layui-input-block">
<input type="text" id="<?php echo htmlentities($vo['name']); ?>" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "tags": ?>
<div class="layui-form-item">
<label class="layui-form-label"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" class="layui-input form-tags tags-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>" data-remark="<?php echo htmlentities((isset($vo['remark']) && ($vo['remark'] !== '')?$vo['remark']:'输入回车确认')); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "number": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="number" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "switch": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="checkbox" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" lay-skin="switch" lay-text="ON|OFF" value="<?php echo htmlentities($vo['value']); ?>" <?php if(1==$vo['value']): ?>checked=''<?php endif; ?>> </div> <?php if($vo['remark']): ?><div
class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "array": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<dl class="layui-input-block fieldlist border-none" data-name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" data-id="<?php echo htmlentities($vo['name']); ?>">
<dd><ins>键名</ins><ins>键值</ins></dd>
<dd class="border-none"><button type="button" class="layui-btn btn-append">追加</button></dd>
<textarea name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" class="layui-textarea layui-hide"><?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?></textarea>
</dl>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<script type="text/html" id="<?php echo htmlentities($vo['name']); ?>Tpl">
<dd class="layui-form-item rules-item">
{{# layui.each(d.lists, function(index, item) { }}
<input type="text" class="layui-input" name="{{item.name}}[{{item.index}}][key]" placeholder="键" value="{{item.key|| ''}}" />
<input type="text" class="layui-input" name="{{item.name}}[{{item.index}}][value]" placeholder="值" value="{{item.value|| ''}}" />
<button type="button" class="layui-btn layui-btn-danger btn-remove layui-btn-xs"><i class="iconfont icon-close"></i></button>
<button type="button" class="layui-btn btn-dragsort layui-btn-xs"><i class="iconfont icon-yidong"></i></button>
{{# }); }}
</dd>
</script>
<?php break; case "checkbox": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<input type="checkbox" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>][]" lay-skin="primary" title="<?php echo htmlentities($v); ?>" value="<?php echo htmlentities($key); ?>" <?php if(in_array($key,$vo['value'])): ?>checked<?php endif; ?>>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "radio": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<input type="radio" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities($key); ?>" title="<?php echo htmlentities($v); ?>" <?php if($key==$vo['value']): ?>checked=''<?php endif; ?>>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "select": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<select name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]">
<option value=""></option>
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<option value="<?php echo htmlentities($key); ?>" <?php if($key==$vo['value']): ?>selected=""<?php endif; ?>><?php echo htmlentities($v); ?> </option>
<?php endforeach; endif; else: echo "" ;endif; ?>
</select>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "selects": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<div class="form-selects" data-name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" data-id="<?php echo htmlentities($vo['name']); ?>" data-value="<?php echo htmlentities($vo['value']); ?>" data-list="<?php echo htmlentities(json_encode($vo['options'])); ?>"></div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "selectpage": ?>
<div class="layui-form-item form-group">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input class="form-control layui-input selectpage" type="text" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" data-source="<?php echo htmlentities(url($vo['options']['url'])); ?>" data-multiple="<?php echo htmlentities((isset($vo['options']['multiple']) && ($vo['options']['multiple'] !== '')?$vo['options']['multiple']:'false')); ?>" data-field="<?php echo htmlentities((isset($vo['options']['field']) && ($vo['options']['field'] !== '')?$vo['options']['field']:'name')); ?>" data-primary-key="<?php echo htmlentities((isset($vo['options']['key']) && ($vo['options']['key'] !== '')?$vo['options']['key']:'id')); ?>" data-max-select-limit="<?php echo htmlentities((isset($vo['options']['max']) && ($vo['options']['max'] !== '')?$vo['options']['max']:'20')); ?>" data-pagination="<?php echo htmlentities((isset($vo['options']['pagination']) && ($vo['options']['pagination'] !== '')?$vo['options']['pagination']:'true')); ?>" data-page-size="<?php echo htmlentities((isset($vo['options']['limit']) && ($vo['options']['limit'] !== '')?$vo['options']['limit']:'10')); ?>" data-order-by="<?php echo htmlentities((isset($vo['options']['order']) && ($vo['options']['order'] !== '')?$vo['options']['order']:'id')); ?>" value="<?php echo htmlentities($value); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "color": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<div class="layui-input-inline" style="width: 120px;">
<input type="text" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>" placeholder="请选择颜色" class="layui-input test-form-input" id="c-<?php echo htmlentities($vo['name']); ?>">
</div>
<div class="layui-inline" style="left: -11px;">
<div class="colorpicker" data-input-id="c-<?php echo htmlentities($vo['name']); ?>"></div>
</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "datetime": ?>
<div class="layui-form">
<div class="layui-form-item">
<label class="layui-form-label"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" class="layui-input datetime" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
</div>
<?php break; case "textarea": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<textarea placeholder="请输入<?php echo htmlentities($vo['title']); ?>" class="layui-textarea" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]"><?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?></textarea>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "image": case "images": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block layui-upload">
<div class="layui-col-xs4">
<input type="text" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" id="c-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>" class="layui-input">
</div>
<div class="webUpload" id="picker_<?php echo htmlentities($vo['name']); ?>" data-multiple="<?php echo $vo['type']=='image' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" data-preview-id="p-<?php echo htmlentities($vo['name']); ?>" data-type="image"><i class="layui-icon layui-icon-upload"></i> 上传</div>
<button type="button" class="layui-btn fachoose" data-multiple="<?php echo $vo['type']=='image' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" id="fachoose-c-<?php echo htmlentities($vo['name']); ?>"><i class="iconfont icon-other"></i> 选择</button>
<ul class="layui-row list-inline plupload-preview" id="p-<?php echo htmlentities($vo['name']); ?>"></ul>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "file": case "files": ?>
<div class="layui-form-item">
<div class="layui-input-block layui-upload">
<div class="layui-col-xs4">
<input type="text" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]" id="c-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities((isset($value) && ($value !== '')?$value:'')); ?>" class="layui-input">
</div>
<div class="webUpload" id="picker_<?php echo htmlentities($vo['name']); ?>" data-multiple="<?php echo $vo['type']=='file' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" data-preview-id="p-<?php echo htmlentities($vo['name']); ?>" data-type="file"><i class="layui-icon layui-icon-upload"></i> 上传</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "Ueditor": ?>
<div class="layui-form-item">
<div class="layui-input-block editor">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="edit">
<script type="text/plain" class="js-ueditor" id="<?php echo htmlentities($vo['name']); ?><?php echo htmlentities($k); ?>" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]"> <?php echo (isset($value) && ($value !== '')?$value:''); ?></script>
</div>
<div class="<?php echo htmlentities($vo['name']); ?>_attr editor_tool">
<a class="layui-btn layui-btn-sm" id="<?php echo htmlentities($vo['name']); ?><?php echo htmlentities($k); ?>grabimg" style="margin-top: 4px;">图片本地化</a>
<a class="layui-btn layui-btn-sm" id="<?php echo htmlentities($vo['name']); ?><?php echo htmlentities($k); ?>filterword" style="margin-top: 4px;">检测违禁词</a>
</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "city": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" autocomplete="on" class="layui-input" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" id="<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities($vo['value']); ?>" data-toggle="city-picker" placeholder="请选择"/>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "custom": ?>
<?php echo $vo['options']; break; case "markdown": ?>
<link rel="stylesheet" href="/static/addons/editormd/css/editormd.min.css">
<script type="text/javascript" src="/static/addons/editormd/editormd.min.js"></script>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<div class="js-editormd" id="<?php echo htmlentities($vo['name']); ?><?php echo htmlentities($k); ?>">
<textarea style="display:none;" name="extra_data[<?php echo htmlentities($k); ?>][<?php echo htmlentities($vo['name']); ?>]"><?php echo htmlentities($value); ?></textarea>
</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<script type="text/javascript">
GV.editormd_upload_url='<?php echo !empty($editormd_upload_url) ? htmlentities($editormd_upload_url) : url("attachment/upload/upload", ["dir" => "images", "from" => "editormd", "module" => request()->module()]); ?>';
GV.editormd_mudule_path='/static/addons/editormd/lib/';
$(function() {
var editormds = {};
if ($(".js-editormd").size() > 0) {
$('.js-editormd').each(function() {
var editormd_name = $(this).attr('id');
editormds[editormd_name] = editormd(editormd_name, {
height: 500, // 高度
watch: true,
searchReplace: true,
toolbarAutoFixed: false, // 取消工具栏固定
path: GV.editormd_mudule_path, // 用于自动加载其他模块
codeFold: true, // 开启代码折叠
dialogLockScreen: false, // 设置弹出层对话框不锁屏
imageUpload: true, // 开启图片上传
imageUploadURL: GV.editormd_upload_url,
});
});
}
});
</script>
<?php break; ?>
<?php endswitch; ?>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
</div>
</div>
</div>
<div class="layui-col-md4">
<div class="layui-card">
<div class="layui-card-header"><i class="layui-icon layui-icon-form layui-red"></i> 基本信息</div>
<div class="layui-card-body layui-row">
<?php if(is_array($fieldList) || $fieldList instanceof \think\Collection || $fieldList instanceof \think\Paginator): $i = 0; $__LIST__ = $fieldList;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;switch($vo['type']): case "hidden": if($vo['value']): ?><input type="hidden" class="form-control" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities($vo['value']); ?>"><?php endif; break; case "link": ?>
<div class="layui-form-item web_link">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-inline w300">
<input type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" id="link" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<div class="layui-input-inline">
<select lay-filter="fasttype">
<option data-url="">内部链接</option>
<option data-url="cms/index/index">首页</option>
<?php if(isset(cache("Cms_Config")['site_url_mode']) && 1==cache("Cms_Config")['site_url_mode']): ?>
<option data-url="cms/index/lists?catid=2">列表/单页</option>
<option data-url="cms/index/shows?catid=2&id=1">详情页</option>
<?php else: ?>
<option data-url="cms/index/lists?catdir=Introduction">列表/单页</option>
<option data-url="cms/index/shows?catdir=Introduction&id=1">详情页</option>
<?php endif; if(isModuleInstall('formguide')): ?>
<option data-url="formguide/index/index?id=2">表单页</option>
<?php endif; ?>
</select>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "text": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" id="<?php echo htmlentities($vo['name']); ?>" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "password": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="password" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "tags": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" class="layui-input form-tags tags-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities($vo['value']); ?>" data-remark="<?php echo htmlentities((isset($vo['remark']) && ($vo['remark'] !== '')?$vo['remark']:'输入回车键确认')); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "number": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="number" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" autocomplete="off" class="layui-input" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "switch": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="checkbox" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" lay-skin="switch" lay-text="ON|OFF" value="<?php echo htmlentities($vo['value']); ?>" <?php if(1==$vo['value']): ?>checked='' <?php endif; ?>> </div> <?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "array": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<dl class="layui-input-block fieldlist border-none" data-name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" data-id="<?php echo htmlentities($vo['name']); ?>">
<dd>
<ins>键名</ins>
<ins>键值</ins>
</dd>
<dd><button type="button" class="layui-btn btn-append">追加</button></dd>
<textarea name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" class="layui-textarea layui-hide"><?php echo htmlentities($vo['value']); ?></textarea>
</dl>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<script type="text/html" id="<?php echo htmlentities($vo['name']); ?>Tpl">
<dd class="layui-form-item rules-item">
{{# layui.each(d.lists, function(index, item) { }}
<input type="text" class="layui-input" name="{{item.name}}[{{item.index}}][key]" placeholder="键" value="{{item.key|| ''}}" />
<input type="text" class="layui-input" name="{{item.name}}[{{item.index}}][value]" placeholder="值" value="{{item.value|| ''}}" />
<button type="button" class="layui-btn layui-btn-danger btn-remove layui-btn-xs"><i class="iconfont icon-close"></i></button>
<button type="button" class="layui-btn btn-dragsort layui-btn-xs"><i class="iconfont icon-yidong"></i></button>
{{# }); }}
</dd>
</script>
<?php break; case "checkbox": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<input type="checkbox" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>][]" lay-skin="primary" title="<?php echo htmlentities($v); ?>" value="<?php echo htmlentities($key); ?>" <?php if(in_array($key,$vo[ 'value' ])): ?>checked<?php endif; ?>>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "radio": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<input type="radio" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities($key); ?>" title="<?php echo htmlentities($v); ?>" <?php if($key==$vo ['value']): ?>checked='' <?php endif; ?>>
<?php endforeach; endif; else: echo "" ;endif; ?>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "select": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<select name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]">
<option value=""></option>
<?php if(is_array($vo['options']) || $vo['options'] instanceof \think\Collection || $vo['options'] instanceof \think\Paginator): $i = 0; $__LIST__ = $vo['options'];if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$v): $mod = ($i % 2 );++$i;?>
<option value="<?php echo htmlentities($key); ?>" <?php if($key==$vo[ 'value' ]): ?>selected="" <?php endif; ?>><?php echo htmlentities($v); ?></option>
<?php endforeach; endif; else: echo "" ;endif; ?>
</select>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "selects": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<div class="form-selects" data-name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" data-id="<?php echo htmlentities($vo['name']); ?>" data-value="<?php echo htmlentities($vo['value']); ?>" data-list="<?php echo htmlentities(json_encode($vo['options'])); ?>"></div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "selectpage": ?>
<div class="layui-form-item form-group">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input class="form-control layui-input selectpage <?php echo htmlentities($vo['name']); ?>" type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" data-source="<?php echo htmlentities(url($vo['options']['url'])); ?>" data-multiple="<?php echo htmlentities((isset($vo['options']['multiple']) && ($vo['options']['multiple'] !== '')?$vo['options']['multiple']:'false')); ?>" data-field="<?php echo htmlentities((isset($vo['options']['field']) && ($vo['options']['field'] !== '')?$vo['options']['field']:'name')); ?>" data-primary-key="<?php echo htmlentities((isset($vo['options']['key']) && ($vo['options']['key'] !== '')?$vo['options']['key']:'id')); ?>" data-max-select-limit="<?php echo htmlentities((isset($vo['options']['max']) && ($vo['options']['max'] !== '')?$vo['options']['max']:'20')); ?>" data-pagination="<?php echo htmlentities((isset($vo['options']['pagination']) && ($vo['options']['pagination'] !== '')?$vo['options']['pagination']:'true')); ?>" data-page-size="<?php echo htmlentities((isset($vo['options']['limit']) && ($vo['options']['limit'] !== '')?$vo['options']['limit']:'10')); ?>" data-order-by="<?php echo htmlentities((isset($vo['options']['order']) && ($vo['options']['order'] !== '')?$vo['options']['order']:'id')); ?>" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "color": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<div class="layui-input-inline" style="width: 120px;">
<input type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" value="<?php echo htmlentities($vo['value']); ?>" placeholder="请选择颜色" class="layui-input test-form-input" id="c-<?php echo htmlentities($vo['name']); ?>">
</div>
<div class="layui-inline" style="left: -11px;">
<div class="colorpicker" data-input-id="c-<?php echo htmlentities($vo['name']); ?>"></div>
</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "datetime": ?>
<div class="layui-form">
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" class="layui-input datetime" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" placeholder="请输入<?php echo htmlentities($vo['title']); ?>" value="<?php echo htmlentities($vo['value']); ?>">
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
</div>
<?php break; case "textarea": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<textarea placeholder="请输入<?php echo htmlentities($vo['title']); ?>" class="layui-textarea" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]"><?php echo htmlentities($vo['value']); ?></textarea>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "image": case "images": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block layui-upload">
<div class="layui-col-xs4">
<input type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" id="c-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities((isset($vo['value']) && ($vo['value'] !== '')?$vo['value']:'')); ?>" class="layui-input">
</div>
<div class="webUpload" id="picker_<?php echo htmlentities($vo['name']); ?>" data-multiple="<?php echo $vo['type']=='image' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" data-preview-id="p-<?php echo htmlentities($vo['name']); ?>" data-type="image"><i class="layui-icon layui-icon-upload"></i> 上传</div>
<button type="button" class="layui-btn fachoose" data-multiple="<?php echo $vo['type']=='image' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" id="fachoose-c-<?php echo htmlentities($vo['name']); ?>"><i class="iconfont icon-other"></i> 选择</button>
<ul class="layui-row list-inline plupload-preview" id="p-<?php echo htmlentities($vo['name']); ?>"></ul>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "file": case "files": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block layui-upload">
<div class="layui-col-xs4">
<input type="text" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" id="c-<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities((isset($vo['value']) && ($vo['value'] !== '')?$vo['value']:'')); ?>" class="layui-input">
</div>
<div class="webUpload" id="picker_<?php echo htmlentities($vo['name']); ?>" data-multiple="<?php echo $vo['type']=='file' ? 'false' : 'true'; ?>" data-input-id="c-<?php echo htmlentities($vo['name']); ?>" data-preview-id="p-<?php echo htmlentities($vo['name']); ?>" data-type="file"><i class="layui-icon layui-icon-upload"></i> 上传</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "Ueditor": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block border-none">
<script type="text/plain" class="js-ueditor" id="<?php echo htmlentities($vo['name']); ?>" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]"><?php echo $vo['value']; ?></script>
<div class="<?php echo htmlentities($vo['name']); ?>_attr editor_tool">
<a class="layui-btn layui-btn-sm" id="<?php echo htmlentities($vo['name']); ?>grabimg" style="margin-top: 4px;">图片本地化</a>
<a class="layui-btn layui-btn-sm" id="<?php echo htmlentities($vo['name']); ?>filterword" style="margin-top: 4px;">检测违禁词</a>
</div>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "city": ?>
<div class="layui-form-item">
<label class="layui-form-label <?php if(isset($vo['ifrequire']) AND $vo['ifrequire']): ?>layui-form-item-required<?php endif; ?>"><?php echo htmlentities($vo['title']); ?></label>
<div class="layui-input-block">
<input type="text" autocomplete="on" class="layui-input" name="<?php echo htmlentities($vo['fieldArr']); ?>[<?php echo htmlentities($vo['name']); ?>]" id="<?php echo htmlentities($vo['name']); ?>" value="<?php echo htmlentities($vo['value']); ?>" data-toggle="city-picker" placeholder="请选择"/>
</div>
<?php if($vo['remark']): ?><div class="layui-form-mid2 layui-word-aux"><?php echo $vo['remark']; ?></div><?php endif; ?>
</div>
<?php break; case "custom": ?>
<?php echo $vo['options']; break; case "markdown": ?>
<?php echo hook('markdown',$vo); break; ?>
<?php endswitch; ?>
<?php endforeach; endif; else: echo "" ;endif; if(isModuleInstall('comment')): ?>
<div class="layui-form-item">
<label class="layui-form-label">允许评论</label>
<div class="layui-input-inline" title="允许评论">
<input type="radio" name="modelField[comment]" value="1" title="允许" <?php if(!$fieldList['comment']['value']): ?>checked<?php endif; if($fieldList['comment']['value']==1): ?>checked<?php endif; ?>>
<input type="radio" name="modelField[comment]" value="0" title="禁止" <?php if($fieldList['comment']['value']==0): ?>checked<?php endif; ?>>
</div>
</div>
<?php endif; if($modelType==3): ?>
<div class="layui-form-item">
<label class="layui-form-label">章节状态</label>
<div class="layui-input-inline" title="章节状态">
<input type="radio" name="modelField[writing]" value="1" title="完成" <?php if(!$fieldList['writing']['value']): ?>checked<?php endif; if($fieldList['writing']['value']==1): ?>checked<?php endif; ?>>
<input type="radio" name="modelField[writing]" value="0" title="连载" <?php if($fieldList['writing']['value']==0): ?>checked<?php endif; ?>>
</div>
</div>
<?php endif; ?>
<div class="layui-form-item">
<label class="layui-form-label">自定义URL</label>
<div class="layui-input-block" title="自定义URL">
<input type="text" id="diyurl" class="layui-input" name="modelField[diyurl]" placeholder="自定义URL" value="<?php echo htmlentities((isset($fieldList['diyurl']['value']) && ($fieldList['diyurl']['value'] !== '')?$fieldList['diyurl']['value']:'')); ?>">
<?php if((isset(cache("Cms_Config")['show_url_mode']) && 0 == cache("Cms_Config")['show_url_mode'])): ?>
<button type="button" class="layui-btn layui-btn-sm btn-box btn-get-pinyin">获取标识</button>
<?php endif; ?>
</div>
<div class="layui-form-mid layui-word-aux">如果所有文章需要自定义URL,请在CMS配置中将URL模式设置为“自定义”,部分需要可手动获取</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label">支付数量</label>
<div class="layui-input-inline" title="支付数量">
<input type="text" class="layui-input input-min-width" name="modelField[readpoint]" placeholder="支付数量" value="<?php echo htmlentities((isset($fieldList['readpoint']['value']) && ($fieldList['readpoint']['value'] !== '')?$fieldList['readpoint']['value']:'0')); ?>">
<input type="radio" name="modelField[paytype]" value="1" title="积分" <?php if(!$fieldList['paytype']['value']): ?>checked<?php endif; if($fieldList['paytype']['value']==1): ?>checked<?php endif; ?>>
<input type="radio" name="modelField[paytype]" value="0" title="金额" <?php if($fieldList['paytype']['value']==0): ?>checked<?php endif; ?>>
</div>
</div>
<div class="layui-form-item">
<div class="layui-inline layui-col-md6">
<label class="layui-form-label">点赞数</label>
<div class="layui-input-inline" title="点赞数">
<input type="text" class="layui-input" name="modelField[likes]" placeholder="点赞数" value="<?php echo htmlentities((isset($fieldList['likes']['value']) && ($fieldList['likes']['value'] !== '')?$fieldList['likes']['value']:'0')); ?>">
</div>
</div>
<div class="layui-inline layui-col-md6">
<label class="layui-form-label">点踩数</label>
<div class="layui-input-inline" title="点踩数">
<input type="text" class="layui-input" name="modelField[dislikes]" placeholder="点踩数" value="<?php echo htmlentities((isset($fieldList['dislikes']['value']) && ($fieldList['dislikes']['value'] !== '')?$fieldList['dislikes']['value']:'0')); ?>">
</div>
</div>
</div>
<div class="layui-form-item">
<div class="layui-inline layui-col-md6">
<label class="layui-form-label">点击量</label>
<div class="layui-input-inline" title="点击量">
<input type="text" class="layui-input" name="modelField[hits]" placeholder="点击量" value="<?php echo htmlentities((isset($fieldList['hits']['value']) && ($fieldList['hits']['value'] !== '')?$fieldList['hits']['value']:'0')); ?>">
</div>
</div>
<div class="layui-inline layui-col-md6">
<label class="layui-form-label">排序</label>
<div class="layui-input-inline" title="排序">
<input type="text" class="layui-input" name="modelField[listorder]" placeholder="排序" value="<?php echo htmlentities((isset($fieldList['listorder']['value']) && ($fieldList['listorder']['value'] !== '')?$fieldList['listorder']['value']:'0')); ?>">
</div>
</div>
</div>
</div>
</div>
</div>
<?php if(count($fieldList)): ?>
<div class="layui-form-item layer-footer">
<div class="layui-input-block">
<?php if((isset(cache("Cms_Config")['data_import']) && 1 == cache("Cms_Config")['data_import'] && 1 != cache("Cms_Config")['site'])): ?>
<button class="layui-btn layui-btn-danger btn-import iconfont icon-dibu" type="button" title="一键同步主站数据,然后修改再提交!">数据同步</button>
<?php endif; ?>
<button class="layui-btn iconfont icon-send" lay-submit> 立即提交</button>
<button type="reset" class="layui-btn layui-btn-primary iconfont icon-trash"> 重置</button>
</div>
</div>
<?php endif; ?>
</form>
</div>
</div>
<script type="text/javascript">
layui.config({
version: '<?php echo htmlentities(app('config')->get('version.yzncms_release')); ?>',
base: '/static/libs/layui_exts/'
}).extend({
yzn: 'yzn/yzn',
yznForm: 'yznForm/yznForm',
yznTable: 'yznTable/yznTable',
treeGrid: 'treeGrid/treeGrid',
clipboard: 'clipboard/clipboard.min',
notice: 'notice/notice.min',
iconPicker: 'iconPicker/iconPicker.min',
ztree: 'ztree/ztree',
dragsort: 'dragsort/dragsort.min',
tagsinput: 'tagsinput/tagsinput',
xmSelect: 'xmSelect/xm-select',
selectPage: 'selectPage/selectpage.min',
echarts: 'echarts/echarts',
echartsTheme: 'echarts/echartsTheme',
citypicker: 'citypicker/city-picker',
webuploader: 'webuploader/webuploader',
ueditor: 'ueditor/ueditor.min',
addons: 'addons',
}).use('yznForm');
</script>
<script type="text/javascript">
$(document).on("fa.event.appendfieldlist", ".btn-append", function (e, obj) {
layui.use('yznForm', function() {
var yznForm = layui.yznForm;
yznForm.events.faselect(obj);
});
});
layui.use(['form', 'layer','yznForm'], function() {
var form = layui.form,
yznForm = layui.yznForm;
<?php if(!(empty($cmsConfig['web_site_getwords']) || (($cmsConfig['web_site_getwords'] instanceof \think\Collection || $cmsConfig['web_site_getwords'] instanceof \think\Paginator ) && $cmsConfig['web_site_getwords']->isEmpty()))): ?>
GV.ueditor_getwords_url="<?php echo url('addons/getwords/getkeywords',['isadmin'=>1]); ?>";
$(".content_attr").append('<a class="layui-btn layui-btn-sm" id="getwords" style="margin-top: 4px;">提取关键词</a> ');
<?php endif; ?>
$(".content_attr").append("<input type='checkbox' name='modelField[get_introduce]' title='是否截取到内容摘要' checked> <input type='checkbox' name='modelField[auto_thumb]' title='是否提取到缩略图' checked>");
form.render();
var input =$("input[name='modelField[theme]']");
input.after("<button type='button' class='layui-btn layui-btn-sm btn-repeat'>重复检测</button>");
$('.btn-repeat').on('click', function(e) {
$.get("<?php echo url('check_title'); ?>", {'catid':<?php echo htmlentities($catid); ?>,'id':<?php echo htmlentities($id); ?>,'data':input.val()}, function(res) {
if(res.code==1){
layer.msg(res.msg,{icon: 1});
}else{
layer.msg(res.msg,{icon: 0});
}
})
});
yznForm.listen('');
//同步数据
$('.btn-import').on('click', function(e) {
layer.msg("同步成功!",{icon: 1});
$(window).scrollTop(0);
location.href = '<?php echo url("edit",["catid"=>$catid]); ?>?id=<?php echo htmlentities($id); ?>&dialog=1&import=1';
});
form.on('select(fasttype)', function(data) {
$('#link').val($(data.elem).find("option:selected").attr("data-url"));
});
});
</script>
</body>
</html>