'通用头事件
Dim fl As String = "d:\web\" & e.path
If filesys.FileExists(fl)
Dim idx As Integer = fl.LastIndexOf(".")
Dim ext As String = fl.SubString(idx)
Select Case ext
Case ".jpg",".gif",".png",".bmp",".wmf",".js",".css" ,".html",".htm",".zip",".rar"
e.WriteFile(fl)
Return
End Select
End If
'----创建一个Weui
Dim wb As new WeUI
'将常量定义在此
'先进入大页面
If e.Path="" Then
wb.AddPageTitle("","pageheader","荣e享后台系统")
wb.AddForm("","form1","")
With wb.AddButtonGroup("form1","btg1",True)
.Add("btn1","我的一级合伙人","","logon.htm")
.Add("btn2","我的二级合伙人","","logon0.htm")
.Add("btn4","我的申请订单","","logon1.htm")
.Add("btn5","一级申请订单","","logon2.htm")
.Add("btn6","二级申请订单","","logon3.htm")
.Add("btn3","我的咨询订单","","logon4.htm")
.Add("btn7","我的财务报表","","logon5.htm").Kind=2
.Add("btn9","")
.Add("btn8","修改密码","","xgmm.htm").Kind=2
End With
e.WriteString(wb.Build)
'否则,进入小页面
Else
'---身份验证
Dim verified As Boolean '用户身份验证
Dim Username As String =e.Cookies("username")'将保存的cookies值赋给username
Dim Password As String =e.Cookies("password")'将保存的cookies值赋给password
Dim fs As String =e.Cookies("fs")
Dim v1 As Boolean
'--------------------------------------------------------------------------------------------------------------------------------------修改密码页面
Select Case e.Path
Case "xgmm.htm" '全局修改密码
If e.PostValues.Count=0 Then
wb.AddPageTitle("","pagetitle","修改密码")
wb.AddForm("","form","xgmm.htm")
With wb.AddInputGroup("form","ipg")
.AddInput("txtname","用户名","text")
.AddInput("pwdold","原密码","text")
.AddInput("pwdnew","新密码","text")
End With
With wb.AddButtonGroup("form","btg",True)
.Add("btn4","确认修改","submit")
End With
Else
Dim txtname =e.PostValues("txtname")
Dim pwdold = e.PostValues("pwdold")
Dim pwdnew = e.PostValues("pwdnew")
Dim p1 As DataRow= DataTables("平台合伙人订单数据").SQLfind("上级统计所有合伙人_上级='" & txtname & "'")
If p1 IsNot Nothing AndAlso p1("登录密码1")=pwdold Then
DataTables("平台合伙人订单数据").ReplaceFor("登录密码1",pwdnew,"[上级统计所有合伙人_上级] = '" & txtname & "'")
v1=True
End If
Dim p2 As DataRow= DataTables("平台合伙人订单数据").SQLfind("上上级非在职合伙人即不填_上上级='" & txtname & "'")
If p2 IsNot Nothing AndAlso p2("登录密码2")=pwdold Then
DataTables("平台合伙人订单数据").ReplaceFor("登录密码2",pwdnew,"[上上级非在职合伙人即不填_上上级] = '" & txtname & "'")
v1=True
End If
Dim p3 As DataRow= DataTables("贷款每日进度表1").SQLfind("订单原始归属所有合伙人_归属人='" & txtname & "'")
If p3 IsNot Nothing AndAlso p3("归属人登录密码")=pwdold Then
DataTables("贷款每日进度表1").ReplaceFor("归属人登录密码",pwdnew,"[订单原始归属所有合伙人_归属人]='" & txtname & "'")
v1=True
End If
Dim p4 As DataRow = DataTables("贷款每日进度表1").SQLfind("上一级归属所有合伙人_上级='" & txtname & "'")
If p4 IsNot Nothing AndAlso p4("上一级归属登录密码")=pwdold Then
DataTables("贷款每日进度表1").ReplaceFor("上一级归属登录密码",pwdnew,"[上一级归属所有合伙人_上级]='" & txtname & "'")
v1=True
End If
Dim p5 As DataRow = DataTables("贷款每日进度表1").SQLfind("上二级归属仅录员工_上上级='" & txtname & "'")
If p5 IsNot Nothing AndAlso p5("上二级归属登录密码")=pwdold Then
DataTables("贷款每日进度表1").ReplaceFor("上二级归属登录密码",pwdnew,"[上二级归属仅录员工_上上级]='" & txtname & "'")
v1 = True
End If
Dim p6 As DataRow= DataTables("客户需求登记表").SQLfind("归属合伙人='" & txtname & "'")
If p6 IsNot Nothing AndAlso p6("归属登录密码")=pwdold Then
DataTables("客户需求登记表").ReplaceFor("归属登录密码",pwdnew,"[归属合伙人]='" & txtname & "'")
v1=True
End If
If v1=True Then
With wb.AddMsgPage("","msgpage","修改成功","") '生成成功提示页
.AddButton("btn1","返回","")
msgbox(111)
End With
Else