1. 文章编辑加入未保存浏览器缓存

2. 文章编辑标题加入长度检查
This commit is contained in:
2018-05-13 00:38:49 +08:00
parent 976c62197a
commit 9011563784
7 changed files with 38 additions and 12 deletions

View File

@@ -247,7 +247,9 @@ layui.define(['fly','laypage'], function(exports){
bean:JSON.stringify(bean)
},function (res) {
layer.msg("发布成功",{time:2000},function () {
location.href = "/";
var cache_key = "content_" + $("input[name='contentId']").val();
localStorage.removeItem(cache_key);
location.href = "/user";
});
});
return false; //阻止表单跳转。如果需要表单跳转,去掉这段即可。