以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 请问移动端的控件如何隐藏? (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=127378) |
-- 作者:chen37280600 -- 发布时间:2018/11/12 20:46:00 -- 请问移动端的控件如何隐藏? Dim
wb
As
New
weui
例如这里的单价控件,我希望通过判断用户角色,再是否显示。但是如果我加一个Attribute="sttle =\'dispaly:none\'",效果只是把单价的数字隐藏了,单价这2个字还在,并不是整个单价的Input控件隐藏了。我的单价待会还会参与js运算,所以我不能不添加,我只能隐藏,请问如何做? [此贴子已经被作者于2018/11/12 20:48:19编辑过]
|
-- 作者:有点蓝 -- 发布时间:2018/11/12 20:57:00 -- 例如 With wb.AddInputGroup("form1","ipg1","订单编辑") .AddInput("客户","客户","text") .AddInput("产品","产品","text") .AddInput("数量","数量","number") If User.IsRole("某角色") .AddInput("单价","单价","number").Step= "0.01" End If End With |
-- 作者:chen37280600 -- 发布时间:2018/11/12 21:04:00 -- 我说了我不能不添加这个控件,因为待会js运算要用到。我必须添加,但是我想添加过程中控制隐藏 |
-- 作者:有点蓝 -- 发布时间:2018/11/12 21:18:00 -- wb.AddForm("","form1","test.htm") With wb.AddInputGroup("form1","ipg1","订单编辑") .AddInput("客户","客户","text") .AddInput("产品","产品","text") .AddInput("数量","数量","number") End With wb.InsertHTML("form1","<div id=\'dj00001\' style =\'display:none\'>") With wb.AddInputGroup("form1","ipg2","") .Attribute = "style=\'margin-top:0px\'" .AddInput("单价","单价","number") End With wb.InsertHTML("form1","</div>") With wb.AddButtonGroup("form1","btg1",True) .Add("btn1", "确定", "submit") End With
|