此主题相关图片如下:22.png
此主题相关图片如下:12.png
此主题相关图片如下:32.png
老师麻烦帮看一下我查询方式 选中后出现以上错位 日期或月份应该显示一行 现在多行显示了
wb.AddForm("mrbb","formmrbb","")
With wb.AddInputGroup("formmrbb","rbbcxipg","")
.Attribute = " style='margin-top: 0px; padding-top: 0px; ' "
.AddSelect("cxfs","查询方式","月报表|日报表").Attribute = " ""
Dim yfs As New List(Of String)
For i As Integer = 0 To 4
yfs.Add( Format( Date.Today.AddMonths( -i) ,"yyyy-MM") )
Next
.AddSelect("yf","月份", String.Join("|",yfs.ToArray()) )
.AddInput("rbbrq","日期","date")
With .AddInputCell("ic1")
.AddLabel("rbbxyg","选择员工",0).Attribute = " ""
.AddInput("rbbgh","text",1).Readonly = True
.AddVcodeButton("rbbcx","查询",2).Attribute = " " style='width: 100px; text-align: center; ' "
End With
End With
js 代码
function xzcxfs(obj) {
var selectedValue = document.getElementById("cxfs").value; // 获取当前选中的 value 属性值
if(selectedValue=="日报表") {
document.getElementById('yf').parentElement.parentElement.style.display = "none";
document.getElementById('rbbrq').parentElement.parentElement.style.display = "block";
}
else{
document.getElementById('rbbrq').parentElement.parentElement.style.display = "none";
document.getElementById('yf').parentElement.parentElement.style.display = "block";
}
}
[此贴子已经被作者于2024/4/12 13:12:52编辑过]