diff --git a/app/admin/service/curd/BuildCurdService.php b/app/admin/service/curd/BuildCurdService.php index 73e6205..f818145 100644 --- a/app/admin/service/curd/BuildCurdService.php +++ b/app/admin/service/curd/BuildCurdService.php @@ -279,7 +279,7 @@ class BuildCurdService } // 获取表名注释 - $tableSchema = Db::query("SELECT table_name,table_comment FROM information_schema.TABLES WHERE table_schema = 'easyadmin' AND table_name = '{$this->tablePrefix}{$this->table}'"); + $tableSchema = Db::query("SELECT table_name,table_comment FROM information_schema.TABLES WHERE table_schema = 'ulthon_admin' AND table_name = '{$this->tablePrefix}{$this->table}'"); $this->tableComment = (isset($tableSchema[0]['table_comment']) && !empty($tableSchema[0]['table_comment'])) ? $tableSchema[0]['table_comment'] : $this->table; } catch (\Exception $e) { throw new TableException($e->getMessage()); diff --git a/app/admin/service/curd/templates/view/module/file.code b/app/admin/service/curd/templates/view/module/file.code index ddd903a..b6f5acc 100644 --- a/app/admin/service/curd/templates/view/module/file.code +++ b/app/admin/service/curd/templates/view/module/file.code @@ -4,7 +4,7 @@
diff --git a/app/admin/service/curd/templates/view/module/files.code b/app/admin/service/curd/templates/view/module/files.code index fe65d0e..383200b 100644 --- a/app/admin/service/curd/templates/view/module/files.code +++ b/app/admin/service/curd/templates/view/module/files.code @@ -4,7 +4,7 @@ diff --git a/public/static/plugs/easy-admin/easy-admin.js b/public/static/plugs/easy-admin/easy-admin.js index 7416f0e..6fa4422 100644 --- a/public/static/plugs/easy-admin/easy-admin.js +++ b/public/static/plugs/easy-admin/easy-admin.js @@ -983,9 +983,9 @@ define(["jquery", "tableSelect", "ckeditor"], function ($, tableSelect, undefine if (col.templet == admin.table.image) { imageFields.push(col.field) } - + if (col.selectList instanceof Object) { - if(Object.keys(col.selectList).length > 0){ + if (Object.keys(col.selectList).length > 0) { selectFields[col.field] = col.selectList; } @@ -1495,6 +1495,7 @@ define(["jquery", "tableSelect", "ckeditor"], function ($, tableSelect, undefine uploadSign = $(this).attr('data-upload-sign') || '|', uploadAccept = $(this).attr('data-upload-accept') || 'file', uploadAcceptMime = $(this).attr('data-upload-mimetype') || '', + disablePreview = $(this).attr('data-disable-preview') || '', elem = "input[name='" + uploadName + "']", uploadElem = this; @@ -1530,28 +1531,31 @@ define(["jquery", "tableSelect", "ckeditor"], function ($, tableSelect, undefine } }); - // 监听上传input值变化 - $(elem).bind("input propertychange", function (event) { - var urlString = $(this).val(), - urlArray = urlString.split(uploadSign), - uploadIcon = $(uploadElem).attr('data-upload-icon') || "file"; + if (disablePreview == 0) { + // 监听上传input值变化 + $(elem).bind("input propertychange", function (event) { + var urlString = $(this).val(), + urlArray = urlString.split(uploadSign), + uploadIcon = $(uploadElem).attr('data-upload-icon') || "file"; - $('#bing-' + uploadName).remove(); - if (urlString.length > 0) { - var parant = $(this).parent('div'); - var liHtml = ''; - $.each(urlArray, function (i, v) { - liHtml += '