+
@@ -84,15 +84,25 @@
page: 1,
limit: 15,
show: false,
- $btn: null,
keys: '',
- items: [],
+ list: [],
},
created: function () {
this.$btn = $('#{$get.id|default=""}');
this.loadPage();
},
methods: {
+ // 搜索刷新数据
+ search: function () {
+ this.page = 1;
+ this.loadPage();
+ },
+ // 设置选择数据
+ setValue: function (url) {
+ this.$btn.trigger('choose', url);
+ if (this.$btn.data('input')) $(this.$btn.data('input')).val(url).trigger('change', url);
+ $('#ImageDialog').parents('.layui-layer-content').next().find('.layui-layer-close').trigger('click');
+ },
// 创建分页工具条
addPage: function (count) {
var that = this;
@@ -105,27 +115,16 @@
},
});
},
- // 搜索刷新数据
- search: function () {
- this.page = 1;
- this.loadPage();
- },
- // 设置选择数据
- setValue: function (url) {
- this.$btn.trigger('choose', url);
- if (this.$btn.data('input')) $(this.$btn.data('input')).val(url).trigger('change', url);
- $('#ImageDialog').parents('.layui-layer-content').next().find('.layui-layer-close').trigger('click');
- },
// 加载页面数据
loadPage: function () {
var that = this;
this.params = {page: this.page, limit: this.limit, output: 'layui.table', name: this.keys || ''};
$.form.load('{:url("image")}', this.params, 'get', function (ret) {
- that.addPage(ret.count);
- that.items = ret.data;
- that.items.forEach(function (item) {
+ that.list = ret.data;
+ that.list.forEach(function (item) {
item.style = 'background-image:url(' + item.xurl + ')';
});
+ that.addPage(ret.count);
return false;
});
},
diff --git a/app/admin/view/file/form.html b/app/admin/view/file/form.html
new file mode 100644
index 000000000..79ea76eeb
--- /dev/null
+++ b/app/admin/view/file/form.html
@@ -0,0 +1,114 @@
+
\ No newline at end of file
diff --git a/app/admin/view/file/index.html b/app/admin/view/file/index.html
new file mode 100644
index 000000000..3abd2c8fa
--- /dev/null
+++ b/app/admin/view/file/index.html
@@ -0,0 +1,44 @@
+{extend name='table'}
+
+{block name="button"}
+
+
批量删除
+
+{/block}
+
+{block name="content"}
+
+ {include file='file/index_search'}
+
+
+
+
+
+{/block}
diff --git a/app/admin/view/file/index_search.html b/app/admin/view/file/index_search.html
new file mode 100644
index 000000000..54f0a0c7d
--- /dev/null
+++ b/app/admin/view/file/index_search.html
@@ -0,0 +1,49 @@
+
+
+
+ 文件名称
+
+
+
+
+
+
+ 文件哈希
+
+
+
+
+
+
+ 文件后缀
+
+
+
+
+
+
+
+
+
+
+
+ 搜 索
+
+
\ No newline at end of file