%
M_UAdd = fun_chkRight("Staff","V")
M_LAdd = fun_chkRight("Login","V")
if M_UAdd = 0 and M_LAdd = 0 then %>
<% response.end
end if%>
<%
id = Trim(Request("id"))
if id = "" or isNumeric(id) = False Then Response.Redirect "userL.asp"
Set rs = Server.CreateObject("ADODB.Recordset")
strSQL = "select a.userId, a.userFnm, a.userLnm, a.notes, a.updated from users a where a.userId = " & id
rs.Open strSQL, con, 3, 3
if not rs.EOF Then
userArr = rs.GetRows()
userId = userArr(0,0)
end if
rs.Close
if userId <> "" Then
strSQL = "select rightId, linkNm, rights from rights where display = 'Y' order by linkNm"
rs.Open strSQL, con, 3, 3
if not rs.EOF Then
rightsArr = rs.GetRows()
end if
rs.close
strSQL = "select loginId, login, pasword, linkNm, rights, tableNm, colNm, recordId, userType, active from admin where tableNm = 'users' and recordId = " & userId
rs.Open strSQL, con, 3, 3
if not rs.EOF Then
loginArr = rs.GetRows()
loginId = Trim(loginArr(0,0))
userType = Trim(loginArr(8,0))
set objenpwd = Server.CreateObject("Encryption.EncryptPwd")
pasword = objenpwd.EnCrpDeCrypt("D", loginArr(2,0))
set objenpwd=nothing
end if
rs.Close
end if
set rs = nothing
con.Close
set con = nothing
%>
| User |
|
| First Name |
<%=Trim(userArr(1,0))%> |
Last Name |
<%=Trim(userArr(2,0))%> |
| Notes |
<%=Trim(userArr(3,0))%> |
| Last Updated |
<%=Trim(userArr(4,0))%> |
<% if M_LAdd = 1 and isEmpty(loginArr) = False Then %>
|
| Login Detail |
|
| Login |
<%=loginArr(1,0)%> |
Password |
<%'if Trim(loginArr(8,0)) = "WM" then
'response.write pasword
'else
response.write "*****"
'end if%>
|
| Active |
<%
if Trim(loginArr(9,0)) = "Y" Then
Response.Write "Yes"
elseif Trim(loginArr(9,0)) = "N" Then
Response.Write "No"
end if
%>
|
User Type |
<%
if Trim(loginArr(8,0)) = "WM" Then
Response.Write "Webmaster"
elseif Trim(loginArr(8,0)) = "SU" Then
Response.Write "System User"
end if
%>
|
<%
if isEmpty(rightsArr) = False Then
tmplinkNmArr = split(Trim(loginArr(3,0)),",")
tmprightsArr = split(Trim(loginArr(4,0)),"|")
%>
| Rights |
<%
for i=0 To UBound(rightsArr,2)
if instr(Trim(loginArr(3,0)),Trim(rightsArr(1,i))) > 0 Then
idAt = ""
for l=0 To UBound(tmplinkNmArr)
if tmplinkNmArr(l) = Trim(rightsArr(1,i)) Then
idAt = l
DB_rightArr = split(rightsArr(2,i),",")
end if
next
dispVal = ""
for r=0 To UBound(DB_rightArr)
if instr(tmprightsArr(idAt),DB_rightArr(r)) > 0 Then
if dispVal = "" Then
dispVal = DB_rightArr(r)
else
dispVal = dispVal & ", " & DB_rightArr(r)
end if
end if
next
%>
| <%=rightsArr(1,i)%> |
<%=dispVal%> |
<%
end if
next
%>
|
<% end if %>
<% end if %>
|
<%
if fun_chkRight("Staff","E") > 0 then
%>
<% if Session("userType") = "WM" or (cint(Trim(Session("userId"))) = cint(Trim(userArr(0,0)))) or (Session("userType") = "SU" and userType <> "WM") Then %>
| |
|
<% end if %>
<%
if (cint(Trim(Session("userId"))) <> cint(Trim(userArr(0,0)))) and (Session("userType") = "WM" or (Session("userType") = "SU" and userType <> "WM"))Then
%>
|
<% end if %>
<% end if %>