main
kgdxpr 1 year ago
parent 0f857c4542
commit 2f60092803

@ -4406,8 +4406,8 @@ layui.config({base: './ayq/modules/'}).define(["layer", 'flow', "laytpl", "eleme
});
form.on('radio', function (data) {
console.log(data);
var _json = options.selectItem;
switch (_json.tag) {
case 'radio':
var _index = parseInt($("#" + _json.id + " .layui-input-block div.layui-form-radio").index(data.othis[0]));
@ -4421,7 +4421,6 @@ layui.config({base: './ayq/modules/'}).define(["layer", 'flow', "laytpl", "eleme
}
_json.options[i].checked = false;
}
console.log(_json);
that.components[_json.tag].update(_json, that);
break;
case 'select':
@ -4515,6 +4514,15 @@ layui.config({base: './ayq/modules/'}).define(["layer", 'flow', "laytpl", "eleme
Class.prototype.render = function () {
var that = this
, options = that.config;
options.data.forEach(function (item, index) {
if (index === 0) {
options.selectItem = item;
}
that.bindPropertyEvent(item);
});
if (options.viewOrDesign) {
var that = this
, options = that.config;
@ -5168,10 +5176,7 @@ layui.config({base: './ayq/modules/'}).define(["layer", 'flow', "laytpl", "eleme
//显示当前的属性
that.components[tag].property(options.selectItem, that);
alert("点击!");
that.bindPropertyEvent(options.selectItem);
//移除 #formDesignerForm .layui-form-item 下所有的 active
$('#formDesignerForm .layui-form-item').removeClass('active');
//给当前元素增加class

Loading…
Cancel
Save