<!--#include file="head.asp"-->
<style>body{background-color: #fff;}</style>

<%
'call iszizhu()
On error resume next 

act=SafeRequestform("act")
if act="edit" then

sql="select ayisguolv,ayguolvcon from ayquanju" 
rs.open sql,conn,1,1
ayisguolv=rs("ayisguolv")
ayguolvcon=trim(rs("ayguolvcon"))
rs.close

ayqq=SafeRequestform("ayqq")
aywebname=SafeRequestform("aywebname")
ayweburl=SafeRequestform("ayweburl")
ayusermiaoshu=SafeRequestform("ayusermiaoshu")
iswappay=SafeRequestform("iswappay")
isgzh=SafeRequestform("isgzh")
moban=SafeRequestform("moban")
tanchuang=SafeRequestform("tanchuang")
ayweixinid=SafeRequestform("ayweixinid")
ayweixinpic=SafeRequestform("ayweixinpic")
pic1=SafeRequestform("pic1")


if iswappay="" then iswappay=0
if isgzh="" then isgzh=0

isbuylog=SafeRequestform("isbuylog")
if isbuylog="" then isbuylog=0

if trim(ayqq)="" then call PopErr("请填写商家联系QQ")
if trim(aywebname)="" then call PopErr("请填写商家名称")
'if trim(ayweburl)="" then call PopErr("请填写商家网址")

if trim(ayusermiaoshu)<>"" then
	if instr(1,trim(ayusermiaoshu),"|")<>0 or instr(1,trim(ayusermiaoshu),"^")<>0 then call PopErr("商家描述,字符|与字符^不可以使用哦，请重新填写！")
	if ayisguolv=1 then
		if guolvRequestform("ayusermiaoshu",ayguolvcon)=false then 
		call logadd(request.Cookies("aynameid"),"商家描述含有敏感文字",0,1)
		call PopErr(""&ayguolvcon&"，以上敏感词语禁用哦！换一个试试吧！")
		end if
	end if
end if

if trim(ayweburl)<>"" then
	if instr(1,trim(ayweburl),"|")<>0 or instr(1,trim(ayweburl),"^")<>0 then call PopErr("商家网址,字符|与字符^不可以使用哦，请重新填写！")
	if ayisguolv=1 then
		if guolvRequestform("ayweburl",ayguolvcon)=false then 
		call logadd(request.Cookies("aynameid"),"商家网址含有敏感文字"&ayweburl,0,1)
		call PopErr(""&ayguolvcon&"，以上敏感词语禁用哦！")
		end if
	end if
end if

if trim(aywebname)<>"" then
	if instr(1,trim(aywebname),"|")<>0 or instr(1,trim(aywebname),"^")<>0 then call PopErr("商家名称,字符|与字符^不可以使用哦，请重新填写！")
	if ayisguolv=1 then
		if guolvRequestform("aywebname",ayguolvcon)=false then 
		call logadd(request.Cookies("aynameid"),"商家网址含有敏感文字"&aywebname,0,1)
		call PopErr(""&ayguolvcon&"，以上敏感词语禁用哦！")
		end if
	end if
end if

sql="select * from ayname where aynameid="&clng(request.Cookies("aynameid"))&"" 
rs.open sql,conn,1,3

if trim(rs("ayqq"))<>"" then
if trim(rs("ayqq"))<>trim(ayqq) then conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"改Q','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
else
conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"新Q','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
end if

if isnull(trim(rs("ayweixinid")))=false and trim(rs("ayweixinid"))<>"" then
if trim(rs("ayweixinid"))<>trim(ayweixinid) then conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"改WX','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
else
if trim(ayweixinid)<>"" then conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"新WX','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
end if


rs("ayqq")=ayqq

if aywebname<>"" then 
rs("aywebname")=aywebname
else
rs("aywebname")=" "
end if

if ayweburl<>"" then 
rs("ayweburl")=ayweburl
else
rs("ayweburl")=" "
end if

if ayusermiaoshu<>"" then 
rs("ayusermiaoshu")=ayusermiaoshu
else
rs("ayusermiaoshu")=" "
end if
rs("iswappay")=iswappay
rs("isgzh")=isgzh
rs("moban")=trim(moban)

if ayweixinid<>"" then 
rs("ayweixinid")=ayweixinid
else
rs("ayweixinid")=" "
end if
 
if trim(pic1)<>"" then 

	if trim(rs("ayweixinpic"))<>"" and isnull(trim(rs("ayweixinpic")))=false then
		if trim(rs("ayweixinpic"))<>trim(pic1) then
		rs("ayisweixinok")=1
		rs("ayweixinpic")=trim(pic1)
		conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"审核二维码','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
		end if
	else
		rs("ayisweixinok")=1
		rs("ayweixinpic")=trim(pic1)
		conn.Execute("Insert Into aymsn(aymsnbt,aymsnurl) values('"&request.Cookies("aytrueuser")&"审核二维码','adminuseredit.asp?id="&request.Cookies("aynameid")&"')")
	end if

end if

if cint(rs("iseditbuy"))=0 then rs("isbuylog")=isbuylog

if tanchuang<>"" then 
tanchuang=Replace(tanchuang,CHR(13)&CHR(10), "\n")
rs("tanchuang")=tanchuang
else
rs("tanchuang")=" "
end if

rs.update
rs.close
call logadd(request.Cookies("aynameid"),"账户信息修改成功",0,0)
call PopErr2("账户信息修改成功","myname")
end if

%>


<%
sql="select * from ayname where aynameid="&clng(request.Cookies("aynameid"))&"" 
rs.open sql,conn,1,1
%>
<main>
<div  class="container">
<div class="ui-lrctnei">

<%call userleft()%>
<div class="r"> 
<div class="ui-content">
                        
					
                            
<div class="neiye">

                   
                                                     
            <!-------------------------------------- 通知公告开始 -------------------------------------->									
            <div class="neibiaoti"></div>
            <div class="neibiaoti2">商家信息</div>
            <div class="gexian"></div>
                	<div class="neitableanquan">
                    
                                        <link rel="stylesheet" href="/kindeditor/themes/default/default.css" />
                                        <script charset="utf-8" src="/kindeditor/kindeditor.js"></script>
                                        <script charset="utf-8" src="/kindeditor/lang/zh-CN.js"></script>
                            			<script>
                                        KindEditor.ready(function(K) {
                                            var uploadbutton1 = K.uploadbutton({
                                                button : K('#uploadButton1')[0],
                                                fieldName : 'imgFile',
                                                url : '/kindeditor/asp/upload_weixin.asp?dir=image',
                                                afterUpload : function(data) { 
                                                    if (data.error === 0) {
                                                        var url = K.formatUrl(data.url, '');
                                                        urlcon=url.replace("/kindeditor/asp/../../","/"); 
                                                        K('#picurl1').val(urlcon);
                                                        con1.innerHTML='<a href='+urlcon+' target=_blank><img src='+urlcon+' width=120 height=120/></a>';
														con2.innerHTML='';
                                                    } else {
                                                        alert(data.message);
                                                    }
                                                },
                                                afterError : function(str) {
                                                    alert('自定义错误信息: ' + str);
                                                }
                                            });
                                            uploadbutton1.fileBox.change(function(e) {
                                                uploadbutton1.submit();
                                            });
                                        });
                                        KindEditor.ready(function(K) {
                                            var uploadbuttone = K.uploadbutton({
                                                button : K('#uploadButtone')[0],
                                                fieldName : 'imgFile',
                                                url : '/kindeditor/asp/upload_erweima.asp?dir=image',
                                                afterUpload : function(data) { 
                                                    if (data.error === 0) {
                                                        var url = K.formatUrl(data.url, '');
                                                        urlcon=url.replace("/kindeditor/asp/../../","/"); 
                                                        K('#picurle').val(urlcon);
                                                        cone.innerHTML='<a href='+urlcon+' target=_blank><img src='+urlcon+' width=120 height=120/></a>';
                                                    } else {
                                                        alert(data.message);
                                                    }
                                                },
                                                afterError : function(str) {
                                                    alert('自定义错误信息: ' + str);
                                                }
                                            });
                                            uploadbuttone.fileBox.change(function(e) {
                                                uploadbuttone.submit();
                                            });
                                        });
                                    </script>
                    
                    
                    <form action="myname" method="post" name="form1" id="form1">
					<table>
                  		<tr>
                            <td style="text-align: center" width="180"><img src="<%=ossurl%>Template/Template5/images/tou1.jpg" ></img></td>
                            <td colspan="3"><span class="neitablez">hi， <%=trim(request.Cookies("aytrueuser"))%>！</span><br>
                            <span class="neitable2">已签署并遵守【电子协议】：<a style="color:#FFB468" href="/index/xieyi" target="_blank">《寄售平台服务协议》</a></span>
                            </td>
                        </tr>
                        <!--
                  		<tr>
                            <td colspan="2" align="center">ID：</td>
                          <td width="350"><%'=rs("aynameid")%></td>
                            <td>&nbsp;</td>
                        </tr>
                        
                  		<tr>
                            <td colspan="2" align="center">商家名：</td>
                          <td><%'=rs("ayusername")%></td>
                            <td>&nbsp;</td>
                        </tr>
                        -->
                  		<tr>
                            <td colspan="2" align="center">商家姓名：</td>
                          <td width="350"><%=rs("aytrueuser")%></td>
                            <td><div class="regts" > 商家姓名无法修改</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">手机号码：</td>
                            <td>
                        	<%=rs("aytel")%>
                            <%if rs("istelrz")=1 then%>
                            <span style="color: #FF6600">[已认证]</span>
                            <%else%>
                            <a href="telrenzheng">[未认证]</a>
                            <%end if%>
                          </td>
                            <td><div class="regts" > 可用手机号作为登录账号</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">电子邮箱：</td>
                            <td><%=rs("aymail")%></td>
                            <td><div class="regts" > 可用电子邮箱作为登录账号</div></td>
                        </tr>

                        
                 		<tr>
                            <td colspan="2" align="center">身份证号：</td>
                            <td>
                            <%
							if trim(rs("ayshenfenzheng"))<>"" and isnull(trim(rs("ayshenfenzheng")))=false then 
							response.Write left(trim(rs("ayshenfenzheng")),3)&"************"&right(trim(rs("ayshenfenzheng")),3)
							end if
							%>
                          </td>
                            <td><div class="regts" > 完整身份证号是您账号身份验证唯一资料，一旦注册无法修改</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">商家级别：</td>
                            <td><%=getjbname(rs("ayjibie"))%></td>
                            <td><div class="regts" > 商家级别会影响交易费率</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center"><span style="color: #339900">投诉率：</span></td>
                            <td>
							<%=Formatnumber(rs("tousulv"),2,true,-1,0)%>%
                          </td>
                            <td><div class="regts" > 投诉率会影响商家级别</div></td>
                        </tr>

                 		<tr>
                            <td colspan="2" align="center"><span style="color: #339900">销售状态：</span></td>
                            <td>
							<%if cint(rs("ayispay"))=0 then response.Write("<font color=#00CC00>正常</font>")%>
                            <%if cint(rs("ayispay"))=1 then response.Write("<font color=red>禁止销售</font>")%>
                          </td>
                            <td><div class="regts" > 商家在平台的销售状态</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center"><span style="color: #339900">VIP会员：</span></td>
                            <td>
							<%if cint(rs("ayisxiaobao"))=0 then%>
                            非平台VIP会员 <a href="vipbuy?c=xb">[立即加入]</a>
                            <%elseif cint(rs("ayisxiaobao"))=1 then%>
                            平台VIP会员 <a href="vip">[查看详细]</a>
                            <%end if%>
                          </td>
                            <td><div class="regts" > VIP时效为永久，开通后不支持退款。<span style="color:#FF6600">【支持加急提现/秒结算】</span></div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center"><span style="color: #339900">免佣流量：</span></td>
                            <td><%=Formatnumber(rs("jjmoney"),2,true,-1,0)%>元 &nbsp;<a href="<%=weburl%>buy/duihuanma.html" target="_blank">[购买]</a>&nbsp;<a href="duihuannew">[兑换]</a></td>
                            <td><div class="regts" > 加急提现免手续费流量【加急提现手续费五折】 <a href="<%=weburl%>buy/duihuanma.html" target="_blank" style="color:#FF6600">购买兑换码</a></div></td>

                        </tr>

                 		<tr>
                            <td colspan="2" align="center">商家 QQ：</td>
                          <td><input name="ayqq" type="text" style="width:340px;" class="reginput" value="<%=trim(rs("ayqq"))%>" size="30" maxlength="50"></td>
                            <td><div class="regts" > <span style="color:#FF6600">必填</span>，商家QQ将出现在商品出售页面，方便买家联系到您</div></td>
                        </tr>
                        
                 		<tr>
                            <td colspan="2" align="center">商家微信号：</td>
                          <td><input name="ayweixinid" type="text" style="width:340px;" class="reginput" value="<%=trim(rs("ayweixinid"))%>" size="30" maxlength="30"></td>
                            <td><div class="regts" > 商家微信号将出现在商品购买页面，方便买家微信联系到您</div></td>
                        </tr> 
                 		<tr>
                            <td colspan="2" align="center">客服二维码：</td>
                          <td>
						  <input type="button" id="uploadButton1" value="上传商家微信名片二维码" />
                          <%
						  if cint(rs("ayisweixinok"))=1 then response.Write "[审核中]"
						  if cint(rs("ayisweixinok"))=2 then response.Write "[审核通过]"
						  if cint(rs("ayisweixinok"))=3 then response.Write "[审核失败]"
						  %>
                          <input name="pic1" type="hidden" id="picurl1" value="" readonly="readonly" /> 
                          <input name="ayweixinpic" type="hidden" value="<%=trim(rs("ayweixinpic"))%>" size="30" maxlength="50">
                          <span id="con1"></span><span id="con2"><%if trim(rs("ayweixinpic"))<>"" and isnull(trim(rs("ayweixinpic")))=false then response.Write"<img src="&trim(rs("ayweixinpic"))&" width=120 height=120/>"%></span>
                          </td>
                            <td><div class="regts" > 微信中"我的二维码"，注：上传需要审核！是微信名片并非收款二维码</div></td>
                        </tr>
                        
                 		<tr>
                            <td colspan="2" align="center">商家名称：</td>
                          <td><input name="aywebname" type="text" style="width:340px;" class="reginput" value="<%=trim(rs("aywebname"))%>" size="30" maxlength="50"></td>
                            <td><div class="regts" > <span style="color:#FF6600">必填</span>，商家名称将出现在商品出售页面</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">商家网址：</td>
                          <td><input name="ayweburl" type="text" style="width:340px;" class="reginput" value="<%=trim(rs("ayweburl"))%>" size="30" maxlength="50"></td>
                            <td><div class="regts" > <span style="color: #FF0000">完整地址 以http://开头</span> 如没有可留空，或填写<a href="mylink" target="_blank">店铺链接</a></div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">商家公告：</td>
                          <td><textarea name="ayusermiaoshu" rows="5" id="ayusermiaoshu" style=" margin-top:5px;width:340px;line-height:20px;"><%=trim(rs("ayusermiaoshu"))%></textarea></td>
                            <td><div class="regts" > 商家公告将在商品购买页与投诉进展页展示</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">弹窗提示：</td>
                            <%
							if trim(rs("tanchuang"))<>"" and isnull(trim(rs("tanchuang")))=false then
							'tanchuang=Replace(trim(rs("tanchuang")),"\n",CHR(13))
							tanchuang=Replace(trim(rs("tanchuang")),"\n",CHR(13)&CHR(10))
							end if
							%>
                          <td><textarea name="tanchuang" rows="5" id="tanchuang" style="width:340px;line-height:20px;"><%=trim(tanchuang)%></textarea></td>
                            <td><div class="regts" > 此弹框提示将在商品购买页弹窗提示</div></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">WAP支付：</td>
                          <td colspan="2"><input name="iswappay" type="checkbox" value="1" <%if cint(rs("iswappay"))=1 then response.Write "checked"%>/>
                           开启买家手机端支付功能</td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">公众号查询：</td>
                          <td colspan="2"><input name="isgzh" type="checkbox" value="1" <%if cint(rs("isgzh"))=1 then response.Write "checked"%>/>
                           允许买家在平台公众号内搜索我的QQ可以查询到我的店铺</td>
                        </tr>
                 		<tr>
                           <td colspan="2" align="center">登录购买：</td>
                          <td colspan="2"><input name="isbuylog" type="checkbox" value="1" <%if cint(rs("isbuylog"))=1 then response.Write "checked"%>/>
                           强制买家必须登录才可以购买,可以对买家封禁或加入买家黑名单，可以有效防止恶意投诉</td>
                        </tr>
                 		<tr><td colspan="4"></td>
                        </tr>
                 		<tr>
                            <td colspan="2" align="center">购买页模板：</td>
                          <td colspan="2">
                             <select name="moban" id="moban">
                               <option value="index" <%if trim(rs("moban"))="index" then response.Write "selected"%>>新版模板</option>
                               <option value="old"  <%if trim(rs("moban"))="old" then response.Write "selected"%>>老版模板</option>
                           </select></td>
                        </tr>
                 		<tr><td colspan="4"></td>
                        </tr>
                        
                        
                 		<tr><td colspan="2" align="center">&nbsp;</td>
                          <td colspan="2">
                          <input name="act" type="hidden" id="act" value="edit"><input style="cursor:pointer" class="logindlreg" type="submit" name="Submit" value=" 保存商家信息 " >
                          </td>
                        </tr>
                    </table>
           
                    
            <div class="clearfix"></div> 

                    </form>
            <!-------------------------------------- 通知公告结束 -------------------------------------->
        
            <div class="gexian20"></div>
            <div class="mzsmbox2" style="padding-top:20px;">
            提示：商家信息部分内容是禁止修改的，如预留信息有误请联系平台客服。<br>
            自动结算：全年全天正常结算到账，如需更改结算模式，请联系平台客服。<br>
            </div>
            </div>
            
        <div class="clearfix"></div>
       


</div>








</div>
</div>
</div>
</div>
</main>
<%rs.close%>

<footer>
<div class="container">
</div>
</footer>

</body>
</html>