<!--#include file="admin_start.asp"-->
<%
ids=trim(request("ids_list"))
rs.open "select * from jins_goods_list where goods_id in ("&ids&")",conn,1,3
set rss=server.createobject("adodb.recordset")
do while not rs.eof 

	if request.form("goods_name_"&rs("goods_id"))<>"" then rs("goods_name")=trim(request.form("goods_name_"&rs("goods_id")))
	'rs("goods_open")=0
	if request.form("goods_open_"&rs("goods_id"))<>"" then rs("goods_open")=int(request.form("goods_open_"&rs("goods_id")))
	if request.form("goods_commend_"&rs("goods_id"))<>"" then rs("goods_commend")=1 else rs("goods_commend")=0
	if request.form("goods_special_"&rs("goods_id"))<>"" then rs("goods_special")=1 else rs("goods_special")=0
	if request.form("goods_new_"&rs("goods_id"))<>"" then rs("goods_new")=1 else rs("goods_new")=0
	'/////////////
    'set rs_t=conn.execute("select sort_description,sort_name from jins_customer_sort ")
    'do while not rs_t.eof
 
		'if request.form("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))<>"" then rs("goods_price_"&rs_t("sort_name"))=request.form("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))
	
	'rs_t.movenext
	'loop
	'set rs_t=nothing
	'/////////////
    set rs_t=conn.execute("select sort_name from jins_customer_sort ")
	rss.open  "select * from jins_goods_price ",conn,1,3
	rss.addnew
	rss("goods_id")=rs("goods_id")
	rss("price_addtime")=now()
	do while not rs_t.eof 
	   
	   if request("goods_price_mart_"&rs("goods_id"))<>"" then rs("goods_price_mart")=request("goods_price_mart_"&rs("goods_id"))
	   if MySys.check.DbNameSearch("jins_goods_list","goods_price_"&rs_t("sort_name")) then 
	      if request("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))<>"" then rs("goods_price_"&rs_t("sort_name"))=request("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))
	   end if
		  '/////
	   if request("goods_price_mart_"&rs("goods_id"))<>"" then rss("price_mart")=request("goods_price_mart_"&rs("goods_id"))
	   if MySys.check.DbNameSearch("jins_goods_price","price_"&rs_t("sort_name")) then 
	      if request("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))<>"" then rss("price_"&rs_t("sort_name"))=request("goods_price_"&rs_t("sort_name")&"_"&rs("goods_id"))
	   end if
	   
	rs_t.movenext
	loop
	set rs_t=nothing
	
	rss.update
	rss.close
	
	rs.update
	rs.movenext
	
loop
rs.close
set rss=nothing
MySys.error.info="商品列表设置成功！"
MySys.error.location="back"
MySys.error.suc()
%>
<!--#include file="admin_end.asp"-->
