[更新]修改节点过虑

This commit is contained in:
Anyon 2017-04-25 12:00:48 +08:00
parent 511cd20a4f
commit 925e577a94
3 changed files with 19 additions and 15 deletions

View File

@ -1,4 +1,5 @@
<?php <?php
// +---------------------------------------------------------------------- // +----------------------------------------------------------------------
// | Think.Admin // | Think.Admin
// +---------------------------------------------------------------------- // +----------------------------------------------------------------------
@ -19,6 +20,8 @@ use think\Request;
* 视图输出过滤 * 视图输出过滤
* Class FilterView * Class FilterView
* @package hook * @package hook
* @author Anyon <zoujingli@qq.com>
* @date 2017/04/25 11:59
*/ */
class FilterView { class FilterView {
@ -53,4 +56,5 @@ class FilterView {
public function cnzz(&$params) { public function cnzz(&$params) {
// @todo CNZZ统计 // @todo CNZZ统计
} }
} }

View File

@ -66,11 +66,11 @@ define(['jquery', 'admin.plugs'], function () {
/*! 注册 data-update 事件行为 */ /*! 注册 data-update 事件行为 */
this.$body.on('click', '[data-update]', function () { this.$body.on('click', '[data-update]', function () {
var id = $(this).attr('data-update') || (function () { var id = $(this).attr('data-update') || (function () {
var data = []; var data = [];
return $($(this).attr('data-list-target') || 'input.list-check-box').map(function () { return $($(this).attr('data-list-target') || 'input.list-check-box').map(function () {
(this.checked) && data.push(this.value); (this.checked) && data.push(this.value);
}), data.join(','); }), data.join(',');
}).call(this); }).call(this);
if (id.length < 1) { if (id.length < 1) {
return $.msg.tips('请选择需要操作的数据!'); return $.msg.tips('请选择需要操作的数据!');
} }

View File

@ -26,12 +26,12 @@ define(['jquery'], function () {
$(':input[placeholder]').map(function () { $(':input[placeholder]').map(function () {
var self = $(this), txt = self.attr('placeholder'); var self = $(this), txt = self.attr('placeholder');
self.wrap($('<div></div>').css({ self.wrap($('<div></div>').css({
position: 'relative',
zoom: '1', zoom: '1',
margin: 'none',
border: 'none', border: 'none',
background: 'none',
padding: 'none', padding: 'none',
margin: 'none' background: 'none',
position: 'relative',
})); }));
var pos = self.position(), h = self.outerHeight(true), paddingleft = self.css('padding-left'); var pos = self.position(), h = self.outerHeight(true), paddingleft = self.css('padding-left');
var holder = $('<span></span>').text(txt).css({ var holder = $('<span></span>').text(txt).css({
@ -167,8 +167,8 @@ define(['jquery'], function () {
msg.prototype.loading = function (msg, callback) { msg.prototype.loading = function (msg, callback) {
this.close(); this.close();
return this.index = msg return this.index = msg
? layer.msg(msg, {icon: 16, scrollbar: false, shade: this.shade, time: 0, end: callback}) ? layer.msg(msg, {icon: 16, scrollbar: false, shade: this.shade, time: 0, end: callback})
: layer.load(2, {time: 0, scrollbar: false, shade: this.shade, end: callback}); : layer.load(2, {time: 0, scrollbar: false, shade: this.shade, end: callback});
}; };
/** /**
@ -752,10 +752,10 @@ define(['jquery'], function () {
var callback = $(this).attr('data-callback'); var callback = $(this).attr('data-callback');
$(this).attr('data-listen', "true").validate(function (data) { $(this).attr('data-listen', "true").validate(function (data) {
$.form.load(this.getAttribute('action') || window.location.href, data, $.form.load(this.getAttribute('action') || window.location.href, data,
this.getAttribute('method') || 'POST', this.getAttribute('method') || 'POST',
window[callback || '_default_callback'] || undefined, true, window[callback || '_default_callback'] || undefined, true,
this.getAttribute('data-tips') || undefined, this.getAttribute('data-tips') || undefined,
this.getAttribute('data-time') || undefined); this.getAttribute('data-time') || undefined);
}); });
$(this).find('[data-form-loaded]').map(function () { $(this).find('[data-form-loaded]').map(function () {
$(this).html(this.getAttribute('data-form-loaded') || this.innerHTML); $(this).html(this.getAttribute('data-form-loaded') || this.innerHTML);