⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mlist_right.asp

📁 一个比较完整的企业erp系统
💻 ASP
📖 第 1 页 / 共 2 页
字号:
	 for i_u = 1 to thisPageSize
	     if Rs.eof then exit for
		  sid = Rs("stockid")'
		  isstockid = Rs("isstockid")'相关主id
		  stockNum = Rs("stockNum")'进货编号
          supplierid = isNumber(Rs("supplierid"),"int",0)'相应供应商id
          mtypeid = Rs("mtypeid")'所属商品类别id
          Code = Rs("Code") & ""'代码
          cName = Rs("cName") & ""'中文名
		  model = Rs("model") & ""'型号
          eName = Rs("eName")'英文名
          eRemark = Rs("eRemark")'英文备注
          cRemark = Rs("cRemark")'中文备注
          typeCode = Rs("typeCode")'型号条码
		  Quality = Rs("Quality") '性质
          inprice = Rs("inprice")'参考进货价
          outprice = Rs("outprice")'参考预出售价
          inhow = Rs("inhow")'数量
          unit = Rs("unit")'单位
          total = Rs("total")'总价格
          inpayment = Rs("inpayment")'已支付给供应商
          intotime = Rs("intotime")'进货时间
          updatetime = Rs("updatetime")'最后修改时间
          guarantyTime = Rs("guarantyTime")'保修期
          guarantyRemark = Rs("guarantyRemark")'保修期备注
          stockMax = Rs("stockMax")'库存上限
          stockMin = Rs("stockMin")'库存下限
          thisDate = Rs("thisDate")'
          aid = Rs("aid")'
          auid = Rs("auid")'
          disabled = isNumber(Rs("disabled"),"int",0)'
          inModel = Rs("inModel")'入库模式-是直接录入或销售时同步录入

          SubCode = SelectZD("select Code from mtype where mtypeid = " & mtypeid & "","未知")

          if updateStock = "YES" then 
		  Rs("outhowed") = SelectZD("select Sum(outHow) from salelist where stockid = " & sid & "",0)'同步更新商品库存
			 Rs.update
		  else
		     upChecked = ""
          end if
          serviceCount = SelectZD("select Count(proserviceid) from ProductsService where stockid = " & sid & "",0)

          outHow = Rs("outhowed") 'SelectZD("select Sum(outHow) from salelist where stockid = " & sid & "",0)
		  outHow = SelectZD("select Sum(outHow) from salelist where stockid = " & sid & "",0)
          nowKC = inhow-outHow





'if nowKC = 0 and not seenullKC = "YES" then
   'nullKC = nullKC+1
'else

		  DYSP_Count = DYSP_Count+(inprice*inHow)'当页商品_总额
		  DYKC_Count = DYKC_Count+(inprice*(inHow-outHow))'当页库存_总额

		  KCJZinprice = KCJZinprice+(nowKC*inprice)
		  KCJZoutprice = KCJZoutprice+(nowKC*outprice)

%>
            <tr ondblclick = "javascript:WindowOpen('mview.asp?stockid=<%=sid%>','mview',430,608,'');" style = 'background-color:#ffffff;' class = 'tempA' style='cursor: default;' onclick = "javascript:clicked_(<%=i_u-1%>);">
			   <input type = 'hidden' name ='input_<%=sid%>' id = 'input_'/>
			   <input type = 'hidden' name ='id_' id = 'id_' value = '<%=sid%>'/>
			   <td style = 'text-align:center;background-color:<%=v1v2(i_u mod 2,0," #eeeeee ;","#ffffff;")%>' ondblclick="javascript:WindowOpen('<%=HOME_PATH%>merchandise/mListview.asp?stockmid=<%=isstockid%>','mListview',screen.availWidth-50,screen.availHeight-100,'');"><a href = "javascript:WindowOpen('<%=HOME_PATH%>merchandise/mListview.asp?stockmid=<%=isstockid
			   %>','mListview',screen.availWidth-50,screen.availHeight-100,'');"><%=stockNum%></a></td>			   <td style = 'text-align:center;' id = 'td_'><%=sid%></td>
			   <td><%=SubCode & "-" & Replace(Code,key_,"<span style = 'color:red;'><b>" & key_ & "</b></span>")%></td>
			   <td><%=Replace(cName,key_,"<span style = 'color:red;'><b>" & key_ & "</b></span>")%></td>
			   <td><%=model%></td>
			   <td><%=v1v2(AdminSelFlag("SeeinPrice",","),true,"¥" & FormatNumber(inprice,2),"^_^")%></td>
			   <%outPrice_ = v1v2(sel,"P", Replace(FormatNumber(outprice,2),FormatNumber(isNumber(key_,"dec",0),2),"<span style = 'color:red;'>" & FormatNumber(isNumber(key_,"dec",0),2) & "</span>"),FormatNumber(outPrice,2))%>
			   <td>¥<%=outPrice_%></td>
			   <td><%=thisDate%><input type = 'checkbox' name = 'box_' id = 'box_' value = '<%=sid%>' style = 'visibility:hidden;height:10px;'/></td>
			   <td style = 'text-align:center;'><%=inhow%></td>
			   <td style = 'text-align:center;'><%=outhow%></td>
			   <td style = 'text-align:center;'><%=v1v2(nowKc,0,"",nowKc)%></td>
			   <td style ='text-align:center;'><%=serviceCount%></td>
			   <td><a href="javascript:SDD('<%=HOME_PATH%>supplier/supplierview.asp?uid=<%=supplierid%>','supplierview',778,480,'');"><%=Replace(SelectZD("select FullName from supplier where uid = " & supplierid & "","未知"),key_,"<span style = 'color:red;'><b>" & key_ & "</b></span>")%></a></td>
			   <td style = 'text-align:center;'><%=v1v2(disabled,1,"<span style = 'color:#000'>可用</span>","<span style = 'color:#808080;'>禁用</span>")%></td>
			   <td style = 'text-align:center;' id = 'selid_'><input type = 'checkbox' style = 'border-style:none;widht:15px;height:15px;' name = 'selAnnounce' onClick = "javascript:checked_(<%=i_u-1%>);" onfocus="this.blur();" value = '<%=sid%>'/></td>
			</tr>

<%
'end if
        Rs.movenext
     next


	 'if not nullKC = 0 then nullKCview = "其中当页商品库存为空值的记录有(<span style = 'color:red;'>" & nullKC & "</span>)个"else nullKCview = ""
	 Response.Write"<tr><td style = 'text-align:center;' colspan = '15'>" & PageWrite & nullKCview & "</td></tr>"

	 Set kcCount = Server.CreateObject("Adodb.RecordSet")
	     SQL = "select Sum(inprice*inhow) , Sum(inprice*(inhow-outhowed)) from stock"
	     kcCount.Open(SQL),Conn,1,1
		 if not kcCount.eof then
		    KCJZinpriceCount = kcCount(0)
			KCJZoutpriceCount = KcCount(1)
		 else
		    KCJZinpriceCount = 0
			KCJZoutpriceCount = 0
         end if
		 kcCount.Close
	 Set kcCount = Nothing


%>
     <tr>
	   <td style = 'text-align:left;padding:5px;line-height:18px;' colspan = '15'>
	   <div>·当页商品总额:¥<%=formatNumber(isNumber(DYSP_Count,"dec",0),3)%>(全部)</div>
	   <div>·当页尚有价值:¥<%=formatNumber(isNumber(DYKC_Count,"dec",0),3)%> 的商品库存(<!--参考-->进价)</div>
	   <!--div>·当页尚有价值:¥<%=formatNumber(isNumber(KCJZoutprice,"dec",0),3)%> 的商品库存(参考销价)</div-->
<hr/>
	   <div>·一共还有价值:<span style = 'color:blue;'>¥<%=formatNumber(isNumber(KCJZoutpriceCount,"dec",0),3)%> 的商品库存(<!--参考-->进价)</span></div>
	   <div style = 'text-align:center;'><!--·一共还有价值:<span style = 'color:blue;'>¥<%=formatNumber(isNumber(KCJZoutpriceCount,"dec",0),3)%> 的商品库存(参考销价)</span>      --><input type = 'button' onclick = "javascript:var countData = <%=noteTotal%> ; if(countData>2000){var con = confirm('当前(<%=mtypeName%>)类别的记录总量为'+countData+'.更新需要较长时间.是否继续?');if(con){this.value='(<%=mtypeName%>)数据['+countData+']个记录更新中.请耐心等待…';form.buttonText.disabled = true;SDD('updateData.asp?mtypeid=<%=Rmainid%>&W=280&H=100','updateData',280,100,'');}else{return false;}}else{this.value='(<%=mtypeName%>)数据更新中.请稍候…';form.buttonText.disabled = true;SDD('updateData.asp?mtypeid=<%=Rmainid%>&W=280&H=100','updateData',280,100,'');}" value = '点击这里更新[<%=mtypeName%>]库存数据[数据总量:<%=noteTotal%>]' style = 'border-style:none;' name = 'buttonText'/></div>
<hr/>
	   <br/>

	   </td>
	 </tr>

<%
  else
%>
	        <tr style = 'background-color:#ffffff;' class = 'tempA'>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;</td>
			   <td>&nbsp;<input type = 'hidden' name = 'box_' value = ''/></td>
			   <td>&nbsp;<input type = 'hidden' name = 'selAnnounce' value = ''/></td>
			</tr>


<%
  end if
  Rs.Close
%>
  </table>
</form>
<%
  Options = trim(Request.Form("Options"))
  if Options = "delTrue" then 
     Set c01 = new CL01
	 ExecuteList = c01.splitList(trim(Request.Form("Execute")),",",0)
     SQL = "delete from stock where stockid in(" & ExecuteList & ")"
	 Set c01 = Nothing
	 'Response.Write SQL
	 SQLservice = "delete from ProductsService where stockid in(" & ExecuteList & ")"
	 'Response.Write SQLservice
	 Conn.Execute(SQLservice)
     Conn.Execute(SQL)
     Response.Write viewinfo("divLoca","正在执行删除操作.请稍候…","")
     Response.Write viewinfo("LocaTimeself","",SELVAR("FN","mlist_right.asp"))

  end if

  if Options = "move" then 
     Set c01 = new CL01
	 dim mTypeid___ , supplierid___ , SQL___
	 ExecuteList = c01.splitList(trim(Request.Form("Execute")),",",0)
	 mTypeid___ = isNumber(trim(Request.Form("movetomtypeid")),"int",0)
	 supplierid___ = isNumber(trim(Request.form("movetosupplierid")),"int",0)
	 Set c01 = Nothing

	 if not mTypeid___ = 0 then SQL___ = " mtypeid = " & mtypeid___ & ""
	 if not supplierid___ = 0 then SQL___ = " supplierid = " & supplierid___ & ""
	 if not mTypeid___ = 0 and not supplierid___ = 0 then SQL___ = " mtypeid = " & mtypeid___ & " , supplierid = " & supplierid___ & " "

     if not mTypeid___ = 0 or not supplierid___ = 0 then
        SQL = "update stock set " & SQL___ & " where stockid in(" & ExecuteList & ")"
	    'Response.Write SQL
        Conn.Execute(SQL)
        Response.Write viewinfo("divLoca","正在执行移动操作.请稍候…","")
        Response.Write viewinfo("LocaTimeself","",SELVAR("FN","mlist_right.asp"))
	 end if
  end if

  if trim(Request.Form("Searched")) = "Y" then Response.Redirect(LinkFile & "?" & LUrl)



ConnClose()
'Response.Write endtime*1000
%>
</div>
<SCRIPT LANGUAGE="JavaScript">
<!--
//document.write(location.href);
//-->
</SCRIPT>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -