layui常用笔记

1. 省市级联动

form.on('select(eObjectType)', function(data){ var eObjectType = data.value; var optionstring = ''; if(eObjectType == '1'){//单元格 optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; optionstring += ""; }else if(eObjectType == '2'){//行 optionstring += ""; }else if(eObjectType == '3'){//列 optionstring += ""; } $("#eShuXing").html(optionstring); form.render('select'); //这个很重要 });

你可能感兴趣的:(layui,layui,javascript,前端)