<!--#include file="conn.asp"-->
<!--#include file="inc/cookies_check.asp"-->
<%
'*****************************************
'* 软件名称 乐彼网上开店软件(56770 EShop)
'* 软件开发 http://www.56770.com
'* 版权所有 http://www.56770.com
'* 文件名称 Admin_bank.asp
'* 最后更新 2011-01-07 by 56770.kingdge
'*****************************************
Dim admin_flag
admin_flag=",8.7,"
include "lang/"& LangFilePath &"/lang_sys.inc"
include "lang/"& LangFilePath &"/lang_menu.inc"
include "lang/"& LangFilePath &"/lang_bank.inc"
CurrentId = 5
CurrentUrl = "admin_bank.asp"
LB_Head()
LB_Menu()
Response.Write("<div class=""mainbody"">")
Response.Write("<div class=""mainbody2"">")
if Eshop_Lebi_name="" or instr(","&Eshop_Lebi_flag&",",admin_flag)=0 then
	    adminflag()
Else
		If OutSubmit = 1 Then CheckOutSubmit()
	    Select Case request("action")
		       Case "del" : del()
			   Case "add" : add()
			   Case "edit" : edit()
			   Case Else
				    main()
		End Select
End If
Response.Write("</div>")
Response.Write("</div>")
LB_Footer()

Sub del
        If OnlyRead = 1 Then OnlyReadMessage()
        id=CheckNum(request("id"),0)
        conn.execute("Delete from [Lebi_bank] where id="& id &"")
		ManageLog Lang_bank(1) & id
		NewEvent "0"
        m_t=Lang_sys(43)
        m_s="·"& Lang_sys(42)
        m_u="admin_bank.asp"
		m_time="2"
		Call Up_mes(m_t,m_s,0,m_u,0,0,m_time,1)
End Sub

Sub edit
        If OnlyRead = 1 Then OnlyReadMessage()
        id=CheckNum(request("id"),0)
		ShowLang = replace(safereplace(request("ShowLang"))," ","")
		set rs=server.CreateObject("adodb.recordset")
		sql="select * from [Lebi_bank] where id=" &id
		rs.open sql, conn, 1, 3
		For LangT = 1 To TotalLang
				rs("bank" & LanguageTxt(LangT))=safereplace(request("bank" & LanguageTxt(LangT)))
				rs("zf_fs" & LanguageTxt(LangT))=safereplace(request("zf_fs" & LanguageTxt(LangT)))
		Next
		rs("ShowLang") = ShowLang
		rs.update
		rs.close : Set rs = Nothing
		ManageLog Lang_bank(2) &"["&Safereplace(request("zf_fs"& lang))&"]"
		NewEvent "0"
        m_t=Lang_sys(48)
        m_s="·"& Lang_sys(47)
        m_u="admin_bank.asp"
		m_time="2"
		Call Up_mes(m_t,m_s,0,m_u,0,0,m_time,1)
End Sub

Sub add
        If OnlyRead = 1 Then OnlyReadMessage()
		ShowLang = replace(safereplace(request("ShowLang"))," ","")
		set rs=server.CreateObject("adodb.recordset")
		sql="select * from [Lebi_bank]"
		rs.open sql, conn, 1, 3
		rs.addnew
		For LangT = 1 To TotalLang
				rs("bank" & LanguageTxt(LangT))=safereplace(request("bank" & LanguageTxt(LangT)))
				rs("zf_fs" & LanguageTxt(LangT))=safereplace(request("zf_fs" & LanguageTxt(LangT)))
		Next
		rs("ShowLang") = ShowLang
		rs.update
		rs.close : Set rs = Nothing
		ManageLog Lang_bank(3) &"["&Safereplace(request("zf_fs"& lang))&"]"
		NewEvent "0"
		m_t=Lang_sys(45)
		m_s="·"& Lang_sys(44)
		m_u="admin_bank.asp"
		m_time="2"
		Call Up_mes(m_t,m_s,0,m_u,0,0,m_time,1)
End Sub

Sub main
%>
<script>var _showtable = '';</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="classtable-top">
<form name="form" method="post" action="?">
<tr>
	<td height="30" align="left" class="classhead"><input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " title=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"><input type="hidden" name="action" value="add"></td>
	<td height="30" align="right" class="classhead">
	<%=QuickMenu("Admin_deliver_area.asp|"& Lang_Menu(137) &"","Admin_pay.asp|"& Lang_Menu(139) &"")%>
	</td>
 </tr>
    <tr>
     <td class="classtop" colspan="2" height="30"><%=Lang_bank(4)%></td>
    </tr>
<tr>
<td class="classbg" colspan="2">
<ul id="tablist">
   <%For LangT = 1 To TotalLang%>
   <li<%If LangT = 1 Then response.write(" class=""selected""") End If%>><a rel="tcontent<%= LangT %>" style="CURSOR:hand;"><%= LanguageName(LangT) %></a></li>
   <%Next%>
</ul>
<div id="tabcontentcontainer">
<%For LangT = 1 To TotalLang%>
   <div id="tcontent<%= LangT %>" class="tabcontent">
   <table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable_<%= LangT %>">
		<tr class="classrow">
		  <td height="30" width="15%" class="classrow"><%=Lang_bank(5)%></td>
		  <td width="85%" class="classrow">
			<input name="zf_fs<%= LanguageTxt(LangT) %>" type="text" size="50" maxlength="50" value="" class="form"></td>
		</tr>
		<tr class="classrow">
		  <td class="classrow"><%=Lang_bank(6)%></td>
		  <td class="classrow">
		   <textarea name="bank<%= LanguageTxt(LangT) %>" cols="56" rows="4" class="text"></textarea>
			</td>
		</tr>
	</table>
	</div>
	<script>tdshow("classtable_<%= LangT %>");</script>
<%Next%>
<table cellspacing="0" cellpadding="4" width="100%" border="0">
		<tr class="classrow">
			<td height="30" width="15%" class="classrow"><%=Lang_bank(7)%></td>
			<td width="55%" class="classrow" align="left">
			<%
			Set Lang = conn.execute("Select l_name from [Lebi_Language] where l_state = 1 order by l_default desc,l_order desc")
			Do While Not Lang.eof
			%>
			<input type="checkbox" name="ShowLang" value="<%=Lang(0)%>" checked><%=Lang(0)%>
			<%
			Lang.movenext
			Loop
			Lang.close : Set Lang = Nothing
			%></td>
			<td class="classrow" align="right"><input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " title=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_res.gif" border="0" title=" <%=Lang_sys(2)%> " onclick="reset();return false;" align="absmiddle"></td>
		</tr>
</table>
</div>
<script>showtabcontent("tablist")</script>
</td>
</tr>
</form>
</table>
<%
Set rs=Server.CreateObject("ADODB.Recordset")
sql="select * from [Lebi_bank] order by id desc"
rs.open sql, conn, 1, 1
if Not rs.eof then
%>
<table width="100%" border="0" cellspacing="0" cellpadding="0" id="classtable" class="classtable2">
  <tr>
     <td class="classtop" height="30"><%=Lang_bank(8)%></td>
  </tr>
<%do while not rs.eof%>
<form name="form" method="post" action="?">
<tr>
<td class="classbg">
<ul id="tablist_<%=rs("id")%>" class="tablist">
   <%For LangT = 1 To TotalLang%>
   <li<%If LangT = 1 Then response.write(" class=""selected""") End If%>><a rel="tcontent_<%=rs("id")%>_<%= LangT %>" style="CURSOR:hand;"><%= LanguageName(LangT) %></a></li>
   <%Next%>
</ul>
<div id="tabcontentcontainer">
<%For LangT = 1 To TotalLang%>
   <div id="tcontent_<%=rs("id")%>_<%= LangT %>" class="tabcontent">
   <table cellspacing="0" cellpadding="4" width="100%" border="0" id="classtable_<%=rs("id")%>_<%= LangT %>">
		<tr class="classrow">
		  <td height="30" width="15%" class="classrow"><%=Lang_bank(5)%></td>
		  <td width="85%" class="classrow">
			<input name="zf_fs<%= LanguageTxt(LangT) %>" type="text" size="50" maxlength="50" value="<%=rs("zf_fs" & LanguageTxt(LangT))%>" class="form"></td>
		</tr>
		<tr class="classrow">
		  <td class="classrow"><%=Lang_bank(6)%></td>
		  <td class="classrow">
		   <textarea name="bank<%= LanguageTxt(LangT) %>" cols="56" rows="4" class="text"><%=rs("bank" & LanguageTxt(LangT))%></textarea>
			</td>
		</tr>
	</table>
	</div>
	<script>tdshow("classtable_<%=rs("id")%>_<%= LangT %>");</script>
<%Next%>
<table cellspacing="0" cellpadding="4" width="100%" border="0">
		<tr class="classrow">
			<td height="30" width="15%" class="classrow"><%=Lang_bank(7)%></td>
			<td width="55%" class="classrow" align="left">
			<%
			Set Lang = conn.execute("Select l_name from [Lebi_Language] where l_state = 1 order by l_default desc,l_order desc")
			Do While Not Lang.eof
			%>
			<input type="checkbox" name="ShowLang" value="<%=Lang(0)%>" <%=judge(rs("showlang"),lang(0))%>><%=Lang(0)%>
			<%
			Lang.movenext
			Loop
			Lang.close : Set Lang = Nothing
			%></td>
			<td class="classrow" align="right">
			<input name="submit" type="image" src="lang/<%=LangFilePath%>/images/bt_app.gif" value=" <%=Lang_sys(1)%> " title=" <%=Lang_sys(1)%> " align="absmiddle">&nbsp;<input type="image" src="lang/<%=LangFilePath%>/images/bt_delete.gif" border="0" title=" <%=Lang_sys(15)%> " onclick="{if(confirm('<%=Lang_sys(64)%>')){location.href='?action=del&id=<%=rs("id")%>';}return false;}" align="absmiddle"><input type="hidden" name="action" value="edit"><input type="hidden" name="id" value="<%=rs("id")%>">
			</td>
		</tr>
</table>
</div>
<script>showtabcontent("tablist_<%=rs("id")%>")</script>
</td>
</tr>
</form>
<%
rs.movenext
loop
%>
</table>
<%
end if
rs.close
set rs=Nothing
End Sub%>