Views/Set/Js/AddMicroDataTableColumn.js
(开头部分) 9KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
layui.use(['index', 'jquery', 'form', 'micro'], function () {
var $ = layui.$
, form = layui.form
, micro = layui.micro;
var MID = micro.getUrlPara('mid');
//selTableName bind
if ($("#selTableName").length > 0) {
var Fields = { "txt": "TabColName,Title", "val": "TID", "stn": "mTabs", "ob": "TID" };
micro.getTxtVal("getalltn", "selTableName", "", Fields);
}
//selTableName Change
form.on('select(selTableName)', function (data) {
var Val = ($(data.elem).find("option:selected").text());
$("#txtTableName").val(Val.split('-')[0]);
});
var mGet = {
//SourceTabl赋值
getTxtValSrcTab: function () {
var Fields = { "txt": "TabColName", "val": "TabColName", "stn": "mTabs", "ob": "ParentID,Sort" };
micro.getTxtVal('getalltn', 'ctlSourceTable', micro.getRootPath() + '/App_Handler/GetPublicTextValue.ashx', Fields);
},
//显示字段
getTextName: function (TabColName, Selected) {
var Fields = { "txt": "TabColName", "val": "TabColName", "stn": "mTabs", "tcn": "" + TabColName + "", "ob": "Sort" };
micro.getTxtVal('get', 'ctlTextName', micro.getRootPath() + '/App_Handler/GetPublicTextValue.ashx', Fields, Selected);
},
//值字段
getTextValue: function (TabColName, Selected) {
var Fields = { "txt": "TabColName", "val": "TabColName", "stn": "mTabs", "tcn": "" + TabColName + "", "ob": "Sort" };
micro.getTxtVal('get', 'ctlTextValue', micro.getRootPath() + '/App_Handler/GetPublicTextValue.ashx', Fields, Selected);
},
//select值初始化
setIniSourceTable: function () {
$('#ctlSourceTable option:first').prop('selected', 'selected');
$("#ctlTextName").empty();
$('#ctlTextName').removeAttr('lay-verify');
$("#ctlTextName").prepend("<option value=''>请选择</option>");
$("#ctlTextValue").empty();
$('#ctlTextValue').removeAttr('lay-verify');
$("#ctlTextValue").prepend("<option value=''>请选择</option>");
form.render();
},
//表单控件值初始化
setIniFormCtl: function () {
$('#ctlTypes option:first').prop('selected', 'selected');
$('#ctlTypes').removeAttr('lay-verify');
$('#txtctlTitle').removeAttr('lay-verify');
$('#txtctlTitle').val("");
$('#ctlValue').val("");
$('#ctlDefaultValue').val("");
$('#ctlVerify2').val("");
$('#ctlSourceTable option:first').prop('selected', 'selected');
$("#ctlTextName").empty();
$('#ctlTextName').removeAttr('lay-verify');
后面还有 167 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
