Dim lszc As String
Integer.TryParse(e.GetValues("key"),PrimaryKey )
If e.GetValues.ContainsKey("deloid") Then
DataTables("用车申请单").SQLDeleteFor("[_Identify]=" & ycid) \'e.GetValues("deloid"))
wb.InsertHTML("<meta http-equiv=\'Refresh\' c>")
wb.AddToast("","t2", e.GetValues("deloid") & "数据删除完毕",0).Msec= 800
e.WriteString(wb.Build)
Return 0
End If
Dim zz1() As String={"车牌号","事由"}
With wb.AddDialog("","dlg1", "删除确认",ycid & "您确定要删除当前记录吗?")
.AddButton("btnCancel","取消").Kind = 1
.AddButton("btnOK","确定","yc_sj_cxxx.htm?key=" & PrimaryKey & "&deloid=" & ycid) \'.Attribute = ""
End With
Dim zz2() As String={"用车城市","用车地点","司机","申请日期","流程状态"}
\',"公司审批人","公司审批结果","部门审批人","部门审批结果"}
rh=DataTables("用车申请单").sqlfind("[_Identify]=\'" & PrimaryKey & "\'")
If rh IsNot Nothing Then
wb.AppendCookie("ycID",PrimaryKey)
wb.AppendCookie("xzzd",rh("流程状态"))
With wb.AddPreview("","pv1","司机交车",rh("申请号") & "/" & rh("申请人"))
For Each x As String In zz1
.AddItem(x,rh(x))
Next
.AddItem("用车时间",format(rh("用车时间"),"f") & "/" & format(rh("返回时间"),"f"))
.AddItem("公里数","发车:" & rh("发车公里数") & " 返回:" & rh("返回公里数"))
For Each x As String In zz2
.AddItem(x,rh(x))
Next
.AddItem("部门审核",rh("部门审批人") & "-" & rh("部门审批结果"))
.AddItem("公司审核",rh("公司审批人") & "-" & rh("公司审批结果"))
End With
Dim lb1 As String="NewAdd"
Dim lb2 As String="Update"
Dim xgbs As Integer=-1
Dim PageURL As String= "yc_sj_sqd.htm?page=" & PageNumber & "&key=" & PrimaryKey & "&xzzd=" & rh("流程状态")
Dim tpml As String
\'
\'If rh.Isnull("图片")=False Then
\'With wb.AddInputGroup("form2","ipg1","图片浏览")
\'\'
\'With .AddUploader("up2","照片浏览",True)
\'.AllowAdd = False \'关闭文件上传功能
\'Dim lsts As New List(of String)
\'lsts = rh("图片")
\'For Each lst As String In lsts
\'Dim lsml As String=tpml & lst
\'.AddImage(lsml)
\'Next
\'End With
\'End With
\'End If
\'\'
With wb.AddButtonGroup("","btg1",False)
Select rh("流程状态")
Case "部门同意","公司同意","完成任务"
.Add("btn15","修改","","yc_sj_editx.htm?key=" & PrimaryKey & "&page=" & PageNumber & "&czbs=" & lb2) \'.Attribute = ""
End Select
.Add("btn16","返回","",PageURL) \'.Attribute ="" \'" \' ""
End With
\' End With
End If
wb.AppendHTML("<script src=\'./lib/table.js\'></script>") \'引入脚本文件
e.WriteString(wb.Build) \'生成网页
Return 0