<!--#include file="../setting/conn.asp"--><!--#include file="../inc/cls_other.asp"-->
<%:SoonBiz.chkadmin:cid=SoonBiz.rid("cid"):SoonBiz.readchannel(cid):act=SoonBiz.ract:jinlan="<a href='?cid="& cid &"'>表单管理</a>":Select Case act:Case "" : formlist :Case "savenewclass" : saveclass(false) :Case "editform" : editform :Case "savenew" : saveinfo(false) :Case "seforminfo" : saveinfo(true) :Case "isname" : isname :Case "list" : list :Case "read" : read :Case "del" : del :Case "editformvalue" : forminfo(true) :Case "editclass" : classinfo(true) :Case "saveeditclass" : saveclass(true) :Case "showcode" : showcode :Case "recycle" : recycle :Case "savefeedback" : savefeedback :Case "delclass" :id=SoonBiz.rid("id"):SoonBiz.execute("delete from "& sheethead &"_class where cid="& cid &" and id="&id):SoonBiz.execute("delete from "& sheethead &"_formvalue where cid="& cid &" and classid="&id):SoonBiz.execute("delete from "& sheethead &"_formhis where cid="& cid &" and classid=" &id):SoonBiz.loadclass:SoonBiz.ok:Case "isgood":SoonBiz.execute("update "& sheethead &"_formhis set isgood=1 where cid="& cid &" and id in ("&SoonBiz.rids&")"):SoonBiz.ok:Case "ungood":SoonBiz.execute("update "& sheethead &"_formhis set isgood=0 where cid="& cid &" and id in ("&SoonBiz.rids&")"):SoonBiz.ok:Case "delhis" :SoonBiz.execute("update "& sheethead &"_formhis set isdel=1 where cid="& cid &" and id in ("&SoonBiz.rids&")"):SoonBiz.ok:Case "readed":SoonBiz.execute("update "& sheethead &"_formhis set isread=1 where cid="& cid &" and id in ("&SoonBiz.rids&")"):SoonBiz.ok:Case "remove" :SoonBiz.execute("delete from "& sheethead &"_formhis where cid="& cid &" and isdel=1 and id in("& SoonBiz.rids &")"):SoonBiz.ok:Case "removeall":SoonBiz.execute("delete from "& sheethead &"_formhis where isdel=1 and cid="& cid):SoonBiz.ok:Case "restore" :SoonBiz.execute("update "& sheethead &"_formhis set isdel=0 where cid="& cid &" and id in("& SoonBiz.rids &")"):SoonBiz.ok:Case "ispass" :SoonBiz.execute("update "& sheethead &"_formhis set ispass=1 where cid="& cid &" and id in("& SoonBiz.rids &") "):SoonBiz.ok:End Select:SoonBiz.adfoot:setallnothing:Sub formlist() :Dim shujun:shujun="<tr onmouseover=""this.style.backgroundColor='#e2e8f4'"" onmouseout=""this.style.backgroundColor=''""><td align='center'>{$id}</td><td>{$title}</td><td>{$readme}</td><td align='center'><a href='?act=editclass&cid={$cid}&id={$id}' onclick=""return showinnew(this,510,320)"">修改</a>￤<a href='?act=editform&cid="& cid &"&classid={$id}'>表单内容管理</a>￤<a href='?act=showcode&cid="& cid &"&id={$id}' onclick=""return showinnew(this,560,220)"">调用代码</a>￤<a href='?act=delclass&cid="& cid &"&id={$id}' onclick=""return confirm('确定要删除么?\n\n将连同此表单下客户提交的信息一起删除,删除后不可恢复')"">删除</a></td></tr>":jinlan=jinlan & " - 表单列表":SoonBiz.title="表单列表":SoonBiz.adhead:SoonBiz.nstate(jinlan):Response.Write "<table cellspacing=1 class=tableborder1>":Response.Write "<tr>":Response.Write " <th width=40>ID</th>":Response.Write " <th>表单名</th>":Response.Write " <th>表单说明</th>":Response.Write " <th width=250>管理</th>":Response.Write "</tr>":Response.write SoonBiz.ReplaceClass("admin_form.asp",cid,0,shujun,"class1"):Response.write "</table>":classinfo(false):Dim omsg:omsg="<li>设置好表单内容后将&quot;链接代码&quot;复制到要表单的页面即可</li>":SoonBiz.ostate(omsg):End Sub:Sub showcode():id=SoonBiz.rid("id"):SoonBiz.title="调用代码":SoonBiz.adhead:SoonBiz.nstate("调用代码"):Response.Write "<div class=""formcode"">":Response.Write "<h1>链接代码:</h1>":Response.Write "<p>"&server.htmlencode("<a href=""form.asp?u="& cid &"w"& id &""">表单名</a>") &"</p>":Response.Write "<h1>链接地址:</h1>":Response.Write "<p>"&server.htmlencode("form.asp?u="& cid &"w"& id &"")&"</p>":Response.Write "<h1>嵌入代码:</h1>":Response.Write "<p>"&server.htmlencode("<script type=""text/javascript"">iframe(""form.asp?u="& cid &"w"& id &""",""600"",""400"");</script>")&"</p>":Response.Write "</div>":End Sub:Sub classinfo(isedit) :Dim hailin,action:Dim title,tags,readme:Dim preimg,cls,viewcls,postcls
If isedit Then
Dim rs:SoonBiz.readclass(SoonBiz.rid("id")):hailin="编辑表单":action="?act=saveeditclass&cid="& cid &"&id="&SoonBiz.rid("id"):Set rs=SoonBiz.execute("select * from "& sheethead &"_class where cid="& cid &" and id="&SoonBiz.rid("id")):title=rs("title"):tags=Rs("tags"):readme=rs("readme"):preimg=Rs("preimg"):cls=Rs("cls"):viewcls=Rs("viewcls"):postcls=Rs("postcls"):rs.close:Set rs=Nothing:SoonBiz.title="编辑表单":SoonBiz.adhead:SoonBiz.nstate("编辑表单")
Else:hailin="添加新表单":action="?act=savenewclass&cid="& cid:title="":tags="":readme="":preimg="":cls=100:viewcls="":postcls=""
End If:Response.Write "<br />":Response.Write "<form method=post action="""& action &""">":Response.Write "<table cellspacing=1 class=tableborder1>":Response.Write "<tr>":Response.Write "<th colspan=2>"& hailin &"</th>":Response.Write "</tr>":Response.Write "<tr>":Response.Write "<td>表单名称:<cite>*</cite></td>":Response.Write "<td><input type=""text"" name=""title"" value="""& title &""" class=""inputtext"" /></td>":Response.Write "</tr>":Response.Write "<tr>":Response.Write "<td>说明:</td>":Response.Write "<td><input type=""text"" name=""readme"" value="""& readme &""" class=""inputtext"" /></td>":Response.Write "</tr>":Response.Write "<tr>":Response.Write "<td>关键词:</td>":Response.Write "<td><input type=""text"" name=""tags"" value="""& tags &""" class=""inputtext"" /></td>":Response.Write "</tr>":Response.Write "<tr>":Response.Write " <td width=120>浏览权限</td>":Response.Write " <td>"& makecls("viewcls",isedit) &"</td>":Response.Write "</tr>":Response.Write "<tr>":Response.Write " <td width=120>提交权限</td>":Response.Write " <td>"& makecls("postcls",isedit) &"</td>":Response.Write "</tr>":Response.Write "<tr>":Response.Write " <td width=120>免验证权限</td>":Response.Write " <td>"& makecls("passcls",isedit) &"</td>":Response.Write "</tr>":Response.Write "</table>":Response.Write "<div class=""operate""><input type=""submit"" value=""提交""></div>":Response.Write "</form>":End Sub:Sub saveclass(isedit):Dim title,readme,tags,sql:Dim viewcls,postcls,passcls:title=SoonBiz.RequestStr("表单名","title","post",1,2,255,30,1):readme=SoonBiz.RequestStr("表单说明","readme","post",1,2,255,30,0):tags=SoonBiz.RequestStr("关键词","tags","post",1,2,255,30,0):viewcls=Replace(Trim(Request.Form("viewcls"))," ",""):postcls=Replace(Trim(Request.Form("postcls"))," ",""):passcls=Replace(Trim(Request.Form("passcls"))," ",""):ShowErr("")
If isedit Then
sql="update "& sheethead &"_class set ":sql=sql & "title='"& title &"'":sql=sql & ",readme='"& readme &"'":sql=sql & ",tags='"& tags &"'":sql=sql & ",viewcls='"& viewcls &"'":sql=sql & ",postcls='"& postcls &"'":sql=sql & ",passcls='"& passcls &"'":sql=sql & " where cid="& cid &" and id="&SoonBiz.rid("id"):SoonBiz.execute(sql):SoonBiz.loadclass:SoonBiz.nok
Else:sql="insert into "& sheethead &"_class(cid,title,readme,tags,viewcls,postcls,passcls,isshow) values (":sql=sql & cid:sql=sql & ",'"& SoonBiz.checkstr(title) &"'":sql=sql & ",'"& SoonBiz.checkstr(readme) &"'":sql=sql & ",'"& SoonBiz.Checkstr(tags) &"'":sql=sql & ",'"& viewcls &"'":sql=sql & ",'"& postcls &"'":sql=sql & ",'"& passcls &"'":sql=sql & ",1)":SoonBiz.execute(sql):SoonBiz.loadclass:SoonBiz.ok
End If:End Sub:Sub editform():Dim tr:Dim sql,rs:Dim aformvaluetype:jinlan=jinlan & " - 编辑表单内容":classid=SoonBiz.rid("classid"):aformvaluetype=Split(formvaluetype,"|"):sql="select * from ["& sheethead &"_formvalue] where cid="& cid &" and classid="& classid &" order by cls asc,id asc":Set rs=SoonBiz.execute(sql):SoonBiz.topplus="<script src=""../inc/form.js"" type=""text/javascript""></script>":SoonBiz.iseditor=True:SoonBiz.adhead:SoonBiz.nstate(jinlan):Response.Write "<table cellspacing=1 class=tableborder1>":Response.Write "<tr><th colspan=""3"">"& SoonBiz.Getxmlvalue("class","class[@id="& classid &"]","title") &"</th></tr>":Do While Not rs.eof:Response.Write "<tr valign='top'>":Response.Write "<td width=20%\>":Response.Write rs("title"):Response.Write "<br />(" & aformvaluetype(rs("f_type")) & ","& rs("cls") &")":Response.Write "<script type=""text/javascript"">mustfill("& rs("mustfill") &"); document.write("" "");isright("& rs("isname") &");</script>"
If Len(rs("readme"))>0 Then
Response.Write " <br />"&rs("readme")
End If:Response.Write "</td>":Response.Write "<td width=65%\>":Response.Write htmlinput(rs("id"),rs("optionlist"),rs("f_state"),rs("f_rows"),rs("f_size"),rs("mustfill")):Response.Write "</td>":Response.Write "<td align='center' width=15%\>":Response.Write " <a href=""?act=editformvalue&amp;cid="& cid &"&amp;classid="& classid &"&amp;id="& rs("id") &""" onclick=""return showinnew(this,560,320)"">编辑</a>￤<a href='?act=isname&cid="& cid &"&classid="& classid &"&id="& rs("id") &"'>标识</a>￤<a href='?act=del&cid="& cid &"&amp;classid="& classid &"&amp;id="& rs("id") &"' onClick=""return confirm('确定要删除么!')"">删除</a>":Response.Write "</td>":Response.Write "</tr>":rs.movenext:Loop:Response.Write "</table>":Response.Write "<br />":rs.close:Set rs=Nothing:forminfo(false):End Sub:Function htmlinput(inputid,f_option,f_state,f_rows,f_size,f_mustfill):Dim shujun,i:select case f_state:case 0 :shujun="<input type=text name='form"& inputid &"'"'#:"other::_/and'or:@have'(me'`
If f_size>0 Then
shujun=shujun & " size="""& f_size &""" maxlength="""& f_size &""" />"
Else:shujun=shujun & " class=""inputtext"" />"
End If:Case 1 :shujun="<textarea name=""form"& inputid &""" rows="""& f_rows &""" class=""inputtext""></textarea>":case 2 :f_option=split(f_option,vbnewline):for i=0 to ubound(f_option):shujun=shujun & "<input type=""radio"" name=""form"& inputid &""" value="""& f_option(i) &""" /> "& f_option(i) &"<br />":next:case 3 :f_option=split(f_option,vbnewline):for i=0 to ubound(f_option):shujun=shujun & "<input type=""checkbox"" name=""form"& inputid &""" value="""& f_option(i) &""" /> "& f_option(i) &"<br />":next:case 4 :f_option=split(f_option,vbnewline):shujun="<select nname=""form"& inputid &""">":for i=0 to ubound(f_option):shujun=shujun & "<option value="""& f_option(i) &""">"& f_option(i) &"</option>":Next:shujun=shujun & "</select>":case 5 :shujun="<input type=""password"" name='form"& inputid &"'"
If f_size>0 Then
shujun=shujun & " size="""& f_size &""" maxlength="""& f_size &""" />"'havecan"as::behowtheseallsee|them"more"also_is
Else:shujun=shujun & " class=""inputtext"" />"
End If:case 6 :shujun="<input type=text name='form"& inputid &"'"
If f_size>0 Then
shujun=shujun & " size="""& f_size &""" maxlength="""& f_size &""" />"
Else:shujun=shujun & " class=""inputtext"" />"
End If:Case 7 :shujun="<input name='form"& inputid &"' id='form"& inputid &"' value="""""']outasitovermost:'couldmemust~;'stilltheirbeenhe:
If f_size>0 Then
shujun=shujun & " size="""& f_size &""" maxlength="""& f_size &""" />"
Else:shujun=shujun & " class=""inputtext"" />"
End If:shujun=shujun & " <a href='#'>上传附件</a>":Case 8 :shujun="<script type=""text/javascript"">wedonetedit(""form"& inputid &""");</script>":Case 9:shujun="<input type=""text"" size=4 maxlength=4>"&SoonBiz.codestr:end Select:htmlinput=shujun:End Function:Sub forminfo(isedit):Dim action,hailin:Dim title,readme,optionlist,f_rows,f_size,mustfill,cls,f_state,f_type:Dim showline:classid=SoonBiz.rid("classid")
If isedit Then
SoonBiz.title="编辑表单内容":SoonBiz.adhead:SoonBiz.nstate("编辑表单内容"):Dim id,sql,rs:id=SoonBiz.rid("id"):sql="select * from "& sheethead &"_formvalue where id="&id:Set rs=SoonBiz.Execute(sql)':%comeanotherarealsoby':betweensome[+himselfanbefore`should"
If rs.eof Then
ShowErr(1018)
Else:title=Rs("title"):readme=Rs("readme"):optionlist=Rs("optionlist"):f_rows=Rs("f_rows"):f_size=Rs("f_size"):mustfill=Rs("mustfill"):cls=Rs("cls"):f_state=Rs("f_state"):f_type=rs("f_type")
End If:action="?act=seforminfo&amp;cid="& cid &"&amp;classid="& classid &"&amp;id="&id:hailin="编辑表单内容":showline="<br />"
Else:action="?act=savenew&amp;cid="& cid &"&amp;classid="& classid:hailin="添加新内容":title="":readme="":optionlist="":f_rows=3:f_size=0:mustfill=1:cls=100:f_state=0:f_type=1
End If:Response.Write "<form method=""post"" action="""& action &""">":Response.Write " <table cellspacing=1 class=tableborder1>":Response.Write " <tr align=""center"">":Response.Write " <th colspan=2>"& hailin &"</th>":Response.Write " </tr>":Response.Write " <tr>":Response.Write " <td width=80>问题:<cite>*</cite></td>":Response.Write " <td width=*><input type=""text"" name=""title"" class=""inputtext"" value="""& title &"""></td>":Response.Write " </tr>":Response.Write " <tr>":Response.Write " <td>说明:</td>":Response.Write " <td><input type=""text"" name=""readme"" size=""40"" class=""inputtext"" value="""& readme &""" /></td>":Response.Write " </tr>":Response.Write " <tr>":Response.Write " <td>选项:</td>":Response.Write " <td><textarea name=""optionlist"" rows=""3"" class=""inputtext"">"& optionlist &"</textarea><div style='margin-top:2px;'>不同选项用回车符(Enter)分隔</div></td>":Response.Write " </tr>":Response.Write " <tr>":Response.Write " <td>其它</td>":Response.Write " <td><select name=""f_state"" id=""f_state"" size=""1"">":Response.Write SoonBiz.OptionList(formtype,"|",0):Response.Write " </select>":Response.Write " <select name=""f_type"" id=""f_type"" size=""1"">"& SoonBiz.OptionList(formvaluetype,"|",0) &"</select>":Response.Write " <select name=""mustfill"" id=""mustfill"" size=""1"">":Response.Write " <option value=1>必填</option>":Response.Write " <option value=0>选填</option>":Response.Write " </select>":Response.Write " rows:<input type=""text"" name=""f_rows"" size=3 value="""& f_rows &""">":Response.Write " size:<input type=""text"" name=""f_size"" size=3 value="""& f_size &""">":Response.Write " 排序:<input type=""text"" name=""cls"" size=3 value="""& cls &""">":Response.Write " </td>":Response.Write " </tr>":Response.Write " </table>":Response.Write " <div class=""operate""><input type=""submit"" name=""Submit"" value=""保存""></div>":Response.Write "</form>":Response.Write "<div class=""ostate""><ul>":Response.Write "<li>问题名称:需要客户反馈的题目,例如:公司地址 从哪里了解到Wedonet?</li>":Response.Write "<li>说明:对问题的描述,和填写注意事项等</li>":Response.Write "<li>选项:供客户选择的项目,不同选项之间用回车符(Enter)分隔.</li>":Response.Write "<li>rows:行对文本区域有效</li>":Response.Write "<li>size:对文本框有效</li>":Response.Write "<li>排序:决定了内容的排列顺序,按正序排列.</li>":Response.Write "<li>标识:做为客户提交表单的标识,出现在提交结果列表中,以区分不同客户提交的表单.</li>":Response.Write "</ul></div>":Response.Write "<script type=""text/javascript"">":Response.Write " CheckSel(""f_state"","& f_state &");":Response.Write " CheckSel(""f_type"","& f_type &");":Response.Write " CheckSel(""mustfill"","& mustfill &");":Response.Write "</script>":End Sub:Sub saveinfo(isedit):Dim title,readme,optionlist,f_rows,f_size,f_state,f_type,cls,mustfill:Dim isname,rs,sql:classid=SoonBiz.rid("classid"):title=SoonBiz.RequestStr("调查内容","title","post",1,1,255,30,1):readme=SoonBiz.RequestStr("说明","readme","post",1,1,255,30,0):optionlist=SoonBiz.RequestStr("选项","optionlist","post",1,1,2000,0,0):f_rows=SoonBiz.RequestStr("高度","f_rows","post",0,1,999,0,1):f_size=SoonBiz.RequestStr("宽度","f_size","post",0,0,999,0,1):f_state=SoonBiz.RequestStr("属性","f_state","post",0,0,99,0,1):f_type=SoonBiz.RequestStr("数据类型","f_type","post",0,0,99,0,1):cls=SoonBiz.rid("cls"):mustfill=SoonBiz.rid("mustfill"):ShowErr("")':#from{ofeach.inthatbyboth''said:"now:much
If isedit Then
Set rs=server.CreateObject("adodb.recordset"):SoonBiz.ConnectionDatabase:id=SoonBiz.rid("id"):sql="select * from "& sheethead &"_formvalue where cid="& cid &" and id="&id:rs.open sql,conn,1,3
Else:Set rs=SoonBiz.execute("select id from "& sheethead &"_formvalue where cid="& cid &" and isname=1 and classid="&classid)
If rs.eof Then
isname=1
Else:isname=0'"cameonlycamebecause;muchinto:out:::'gethas::"
End If:rs.close:Set rs=Nothing:Set rs=server.CreateObject("adodb.recordset") :SoonBiz.ConnectionDatabase:rs.open ""& sheethead &"_formvalue",conn,1,3:rs.addnew:Rs("cid")=cid:rs("classid")=classid:Rs("stime")=Now():Rs("isname")=isname
End If:Rs("title")=title:Rs("readme")=readme:Rs("optionlist")=optionlist:Rs("f_rows")=f_rows:Rs("f_size")=f_size:Rs("f_state")=f_state:Rs("f_type")=f_type:Rs("cls")=cls:Rs("mustfill")=mustfill:Rs.update:rs.close:Set rs=Nothing
If isedit Then
SoonBiz.nok
Else:SoonBiz.ok
End If:End Sub:Sub list():classid=SoonBiz.rid("classid")'like)there"see$&any'theorouroftakedidafterdo:in
If classid < 0 Then
selectclass
Else:postlist
End If:End Sub:Sub SelectClass():Dim rs:Dim shujun:shujun="<tr><td align='center'>{$id}</td><td>{$title}</td><td align='center' id=""postcount_{$id}"">0</td><td align='center'><a href=""?act=list&cid="& cid &"&classid={$id}"">查看提交结果</a></td></tr>":SoonBiz.adhead:SoonBiz.nstate("提交记录 - 选择表单"):Response.write "<table cellspacing=1 class=tableborder1>":Response.write " <tr>":Response.Write " <th>ID</th>":Response.Write " <th>表单名称</th>":Response.Write " <th>提交数量</th>":Response.Write " <th>操作</th>":Response.Write " </tr>":Response.Write SoonBiz.ReplaceClass("",cid,"",shujun,"class1"):Response.write "</table>":Set rs=SoonBiz.execute("select count(*),classid from "& sheethead &"_formhis where isdel=0 group by classid"):Response.Write "<script type=""text/javascript"">":Do While Not rs.eof:Response.Write "lethtml('postcount_"& rs(1) &"',"& rs(0) &");":rs.movenext:Loop:rs.close:Set rs=Nothing:Response.Write "</script>":End Sub:Sub postlist():Dim isread:Dim astr,shujun:isread=SoonBiz.rid("isread"):astr=SoonBiz.PlusSQL("select * from ["& sheethead &"_formhis] where cid="& cid &" and isdel=0 ","?act="&act&"&amp;cid="&cid)
If isread>0 Then
astr(0)=astr(0) & " and isread="&isread:astr(1)=astr(1) & "&isread="&isread:astr(2)=astr(2) & "CheckSel(""isread"","& isread &");"'"makeonshouldif:many':theyit:theremight::takestillgot
End If:astr(0)=astr(0) & " order by id desc":shujun="<tr onmouseover=""this.style.backgroundColor='#e2e8f4'"" onmouseout=""this.style.backgroundColor=''"" ><td align='center'>{$id}</td><td align='center'>{$formid}</td><td>{$title}</td><td align='center'>{$ip}</td><td align='center'>{$stime_short}</td><td align='center'><script type=""text/javascript"">isright({$isgood});</script></td><td align='center'><script type=""text/javascript"">isright({$isread});</script></td><td align='center'><script type=""text/javascript"">isright({$ispass});</script></td><td align='center'><a href='?act=read&cid="& cid &"&id={$id}&classid="& classid &"'>查看</a></td><td align='center'><input type='checkbox' name='id' value='{$id}'></td></tr>":SoonBiz.adhead:SoonBiz.nstate("提交记录 - "& SoonBiz.Getxmlvalue("class","class[@id="& classid &"]","title")):listfilter:Response.write "<form method=post name=""myform"" id=""myform"" action=""?"">":Response.write "<table cellspacing=1 class=tableborder1>":Response.write " <tr>":Response.write " <th width=40>ID</th>":Response.write " <th width=150>表单号</th>":Response.write " <th width=*>表单标识</th>":Response.write " <th width=80>IP</th>":Response.write " <th width=80>时间</th>":Response.write " <th width=40>收藏</th>":Response.write " <th width=40>已读</th>":Response.write " <th width=40>审核</th>":Response.write " <th width=50>操作</th>":Response.write " <th width=40>选择</th>":Response.write " </tr>":Response.Write SoonBiz.ReplaceMdb("表单管理",astr(0),shujun,"",0):Response.write "</table>":Response.write SoonBiz.pagelist(""):Response.Write "<div class=""operate"">":Response.Write " <input type=""button"" onClick=""CheckAll(myform)"" value=""全选"">":Response.Write " <input type=""button"" onClick=""ContraSel(myform)"" value=""反选"">":Response.Write " <input type=""button"" onClick=""Csubmit('myform','?act=ispass&cid="& cid &"','确定要审核通过选定的文件吗?')"" value=""审核"">":Response.Write " <input type=""button"" onClick=""Csubmit('myform','?act=delhis&cid="& cid &"','确定要删除选择的文件么?')"" value=""删除"">":Response.write " <input type=""button"" onClick=""Csubmit('myform','?act=isgood&cid="& cid &"','')"" value=""收藏"">/<input type=""button"" onClick=""Csubmit('myform','?act=ungood&cid="& cid &"','')"" value=""取消"">":Response.write " <input type=""button"" onClick=""Csubmit('myform','?act=readed&cid="& cid &"','')"" value=""已读"">":Response.write "</div>":Response.write "</form>":Response.Write "<script type=""text/javascript"">"& astr(2) &"</script>":End Sub:Sub recycle():Dim sql:Dim shujun:sql="select * from ["& sheethead &"_formhis] where cid="& cid &" and isdel=1 order by id desc":SoonBiz.adhead:SoonBiz.nstate("表单回收站"):Response.write "<form method=post name=""myform"" id=""myform"" action=""?"">":Response.write "<table cellspacing=1 class=tableborder1>":Response.write " <tr>":Response.write " <th width=40>ID</th>":Response.write " <th width=*>表单标识</th>":Response.write " <th width=80>IP</th>":Response.write " <th width=80>时间</th>":Response.Write " <th width=60>操作</th>":Response.write " <th width=40>选择</th>":Response.write " </tr>":shujun="<tr onmouseover=""this.style.backgroundColor='#E2E8F4'"" onmouseout=""this.style.backgroundColor=''"" ><td align='center'>{$id}</td><td>{$title}</td><td align='center'>{$ip}</td><td align='center'>{$stime_short}</td><td align='center'><a href='?act=read&cid="& cid &"&uid={$uid}' onclick=""return showinnew(this,600,550)"">查看</a></td><td align='center'><input type='checkbox' name='id' value='{$id}'></td></tr>":Response.Write SoonBiz.ReplaceMdb("表单回收站",sql,shujun,"",0):Response.write "</table>":Response.write SoonBiz.pagelist(""):Response.Write "<div class=""operate"">":Response.Write " <input type=""button"" onClick=""CheckAll(myform)"" value=""全选"">":Response.Write " <input type=""button"" onClick=""ContraSel(myform)"" value=""反选"">":Response.Write " <input type=""button"" onClick=""Csubmit('myform','?act=remove&cid="& cid &"','确定要删除选择的文件么!')"" value=""移除"">":Response.write " <input type=""button"" onClick=""Csubmit('myform','?act=restore&cid="& cid &"','')"" value=""恢复"">":Response.write " <input type=""button"" onClick=""Csubmit('myform','?act=removeall&cid="& cid &"','确认要清空回收站吗!')"" value=""清空回收站"">":Response.write "</div>":Response.write "</form>":End Sub:Sub listfilter():Response.Write "<div class=""listfilter"">":Response.Write "<form method=get action=""?"">":Response.Write " <input type=""hidden"" name=""act"" value=""list"" />":Response.Write " <input type=""hidden"" name=""cid"" value="""& cid &""" />":Response.Write " <input type=""text"" name=""keyword"" id=""keyword"" class=""inputsearch"">":Response.Write " <select id=""myfield"" name=""myfield"">":Response.Write " <option value=""content"">按内容搜索</option>":Response.Write " <option value=""formid"">按表单号搜索</option>":Response.Write " </select>":Response.Write " <select name=""classid"" id=""classid"">":response.write SoonBiz.ReplaceClass("",cid,"","<option value=""{$id}"">{$title}</option>","class1"):Response.Write " </select>":Response.Write " <select id=""isgood"" name=""isgood"">":Response.Write " <option value="""">全部</option>":Response.Write " <option value=""1"">收藏</option>":Response.Write " <option value=""0"">未收藏</option>":Response.Write " </select>":Response.Write " <select id=""isread"" name=""isread"">":Response.Write " <option value="""">全部</option>":Response.Write " <option value=""1"">已读</option>":Response.Write " <option value=""0"">未读</option>":Response.Write " </select>":Response.Write " <input type='submit' name=""submit"" value='显示' class=""submit"">":Response.Write " </form>":Response.Write "</div>":End Sub:Sub read():Dim rs,sql,i:Dim titlestr,statestr,contentstr,feedback:id=SoonBiz.rid("id"):classid=SoonBiz.rid("classid"):SoonBiz.execute("update "& sheethead &"_formhis set isread=1 where cid="& cid &" and classid="& classid &" and id="&id):sql="select titlestr,statestr,content,feedback from "& sheethead &"_formhis where cid="& cid &" and id="&id&" order by id asc":Set rs=SoonBiz.execute(sql)
If Not rs.eof Then
titlestr=Split(rs(0),"|"):statestr=Split(rs(1),"|"):contentstr=Split(rs(2),"|"):feedback=rs(3)
Else:ShowErr(1018)
End If:rs.close:Set rs=Nothing:SoonBiz.adhead:SoonBiz.nstate("提交记录 - "&SoonBiz.Getxmlvalue("class","class[@id="& classid &"]","title")):Response.write "<table cellspacing=1 class=tableborder1>":Response.write "<tr>":Response.write "<th width=150>主题</th>":Response.write "<th width=*>内容</th>":Response.write "</tr>"
If IsArray(titlestr) Then'+than'butsaidanotherbeingget:thansamelike::aboutsuch(after
Dim jinfang:jinfang=UBound(titlestr):For i=0 To jinfang:Response.write "<tr valign=""top"">":Response.write "<td>"& titlestr(i) &"</td>"
If CInt(statestr(i))=7 Then 
Response.write "<td>"& contentstr(i) &" <a href='"& contentstr(i) &"' target='_blank'>+附件</a></td>"
Else:Response.write "<td>"& contentstr(i) &"</td>"
End If:Response.write "</tr>":Next
End If:Response.write "</table>":Response.Write "<iframe id=""upfile"" src=""admin_img.asp?act=nolist&amp;cid="& cid &"&amp;fid=f"& id &""" frameborder=""0"" scrolling=""no"" width=""100%"" height=""20""></iframe>":Response.Write "<p></p><strong>回复</strong>":Response.Write "<form method=""post"" name=""form_feedback"" action=""?act=savefeedback&amp;cid="& cid &"&amp;classid="& classid &"&amp;id="& id &""">":Response.Write "<textarea id=""feedback"" name=""feedback"" rows=""3"" cols=""10"" class=""inputtext"">"& feedback &"</textarea>":Response.Write "<input type=""submit"" value=""保存"" />":Response.Write "</form>":End Sub:Sub savefeedback():Dim feedback:feedback=SoonBiz.RequestStr("回复内容","feedback","post",1,1,1000,30,1):ShowErr(""):SoonBiz.execute("update "& sheethead &"_formhis set feedback='"& SoonBiz.Checkstr(feedback) &"' where id="&SoonBiz.rid("id")):SoonBiz.adsuccess("<li>保存成功</li><li><a href=""?act=list&amp;cid="& cid &"&amp;classid="& SoonBiz.rid("classid") &""">点击这里返回提交结果列表</a></li>"):End Sub:Sub del():Dim sql:id=SoonBiz.rid("id"):sql="delete from "& sheethead &"_formvalue where cid="& cid &" and id="&id:SoonBiz.execute(sql):SoonBiz.ok:End Sub:Sub isname():Dim sql:sql="update "& sheethead &"_formvalue set isname=0 where cid="& cid &" and classid="&SoonBiz.rid("classid"):SoonBiz.execute(sql):sql="update "& sheethead &"_formvalue set isname=1 where cid="& cid &" and classid="&SoonBiz.rid("classid")&" and id="&SoonBiz.rid("id"):SoonBiz.Execute(sql):SoonBiz.ok:End Sub
%>