求教下,weui 帮助里的这个 Edit函数
我加了个编辑明细的按钮
With wb.AddActionSheet("","menu")
.Add("mnudAdd", "增加明细").A ttri bute="" '调用js函数
.Add("mnuEdit", "编辑明细").A ttri bute =""
.Add("mnuDelete", "删除明细").A ttri bute ="""
.Add("mnuCancel","取消","",True)
End With
End If
With wb.AddDialog("","dlg1", "删除确认","您确定要删除当前明细吗?")
.AddButton("btnCancel","取消").Kind = 1
.AddButton("btnOK","确定").A ttri bute = ""
End With
With wb.AddButtonGroup("form1","btg1",False)
.Add("btn1", "增加明细", "submit").FormAction = url & "&addnext=true" '加上addnext参数,表示保存后进入增加明细状态
.Add("btn6", "编辑明细", "submit").A ttri bute =""
.Add("btn2", "保存", "submit") '正常提交,保存后进入编辑状态
If e.GetValues.ContainsKey("oid") = False Then '如过是新增订单
.Add("btn3", "取消", "button","list.htm?page=" & page & "&deloid=" & pr("订单编号")) '删除新增订单后返回列表
ElseIf IsNew OrElse mr IsNot Nothing Then '如果在给旧订单新增或修改明细,则直接返回编辑状态
.Add("btn3", "取消", "button",url) '返回编辑状态
Else
.Add("btn3", "返回", "button","list.htm?page=" & page) '返回列表
End If
End With
js也改成
function editDetail(){
if (detailtable.primarykey){
location = form1.action + "&did=" + detailtable.primarykey;
}
}
但是点击编辑明细,变成保存了,求教下要怎么改啊