From 1656be2e05e04daa37351757339f11f6340a3528 Mon Sep 17 00:00:00 2001 From: wangbing Date: Fri, 3 May 2019 00:07:47 +0800 Subject: [PATCH] =?UTF-8?q?Home=E9=A1=B5=E9=87=8D=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/templates/screen/home.ftl | 22 +++++++++++ .../resources/templates/screen/index.ftl | 39 ++++++++++++------- .../resources/templates/screen/login.ftl | 10 ++--- 3 files changed, 51 insertions(+), 20 deletions(-) diff --git a/src/main/resources/modules/SpringBoot/resources/templates/screen/home.ftl b/src/main/resources/modules/SpringBoot/resources/templates/screen/home.ftl index 590ad899..07749a60 100644 --- a/src/main/resources/modules/SpringBoot/resources/templates/screen/home.ftl +++ b/src/main/resources/modules/SpringBoot/resources/templates/screen/home.ftl @@ -130,6 +130,16 @@ 调用AJAX + + +

ajax.example({}).then(function (response) {

+

if (response.errors.length > 0) {

+

nav.e(response.errors[0].message);

+

} else {

+

nav.i("Ajax调用成功!");

+

}

+

})

+ @@ -145,6 +155,18 @@ 点击上传
只能上传jpg/png文件,且不超过500kb
+ + + +

ajax.fileUpload(req.file).then(function (response) {

+

if (response.errors.length > 0) {

+

req.onError();

+

nav.e(response.errors[0].message);

+

} else {

+

req.onSuccess();

+

nav.i("文件上传成功!");

+

}

+

})

diff --git a/src/main/resources/modules/SpringBoot/resources/templates/screen/index.ftl b/src/main/resources/modules/SpringBoot/resources/templates/screen/index.ftl index 2bc7627f..4f7f0ee8 100644 --- a/src/main/resources/modules/SpringBoot/resources/templates/screen/index.ftl +++ b/src/main/resources/modules/SpringBoot/resources/templates/screen/index.ftl @@ -1,13 +1,14 @@
@@ -22,7 +23,7 @@ 登录日志 @@ -33,7 +34,7 @@
@@ -40,8 +40,8 @@ } .frame { - width: 50%; - height: 50%; + width: 600px; + height: 500px; background: #42424263; border-radius: 10px; display: flex;