<%@ page language="C#" autoeventwireup="true" inherits="erkcz, App_Web_ml12ysap" %>

<!DOCTYPE html>
<html lang="en">
<head >
<title><%Response.Write(fiyhlx == "0" ? "进货查询" : "货品入库");%>-<%Response.Write(titlestr);%></title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="Content-Language" content="zh-CN" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <script src="/content/js/jquery-2.1.5.min.js" type="text/javascript"></script>
    <script src="/content/layer/layer.js" type="text/javascript"></script>
    <script type="text/javascript">
        layer.config({
            extend: "extend/layer.ext.js"
        });
    </script>
    <link href="/content/css/bootstrap.css" rel="stylesheet" />
    <link href="/content/css/custom.min.css" rel="stylesheet" />
    <link href="/content/css/contextMenu.css" rel="stylesheet" />
    <link rel="stylesheet" href="/content/font/iconfont.css" />
    <link rel="stylesheet" href="/content/css/main.css"/>
    <script src="/content/js/contextMenu.js" type="text/javascript"></script>
    <script src="/content/js/xggbf.js" type="text/javascript"></script>
    <script src="/content/js/erkcz.js" type="text/javascript"></script>
    <script type="text/javascript" src="/content/laydate/laydate.js"></script>
</head>
   <body>
     <!-- 左侧菜单内容 -->
         <%Response.Write(tempnavmenu); %>
      <!-- 左侧菜单内容结束 -->
 <!-- 右页面内容 -->
<div class="bg-danger pagebody">
<div class="right_col" role="main"   id="right1"  >
<script type="text/javascript">
    var var2 = window.innerHeight - 58;
    right1.style.setProperty('min-height', var2 + 'px', 'important');
</script>
        <div class="page-title">
            <div class="title_left">
                <h3><%Response.Write(fiyhlx == "0" ? "进货查询" : "货品入库");%></h3>
                <h4> &nbsp;&nbsp;&nbsp;&nbsp;</h4>
            </div>
        </div>
        <div class="clearfix"></div>
    <!--内容-->
        <div class="row">
            <div class="clearfix"></div>
            <div class="col-md-12 col-sm-12 col-xs-12">
                  <div class="x_content">
                       <!-- 开始 -->
                       <form id="form1" runat="server">
                          <input type="hidden" name="act" id="act" value="<%Response.Write(WebAct); %>"    />
                       <table class="table"  width="100%"  >
                              <tr>
                                    <td colspan="<%Response.Write(fiyhlx == "0" ? "10" : "11");%>" align="left">
                                        <asp:Button ID="Button1" runat="server" class="btn btn-primary" Text="生成EXCEL" OnClick="Button1_Click" />
                                          <% if (fiyhlx == "1") {%>
                                       <input name="button3" type="button"  class="btn btn-primary" onclick="addUser('货品入库', '0')" value="入库" />
                                         <%} %>
                                    </td>
                                </tr>
                 <tr>
             <% if (fiyhlx == "1") {%>
            <td width="5%" height="22"  align="center" valign="middle">序号</td>
            <td width="5%" height="22"  align="center" valign="middle">ID</td>
            <td width="20%" height="22" align="center" valign="middle" >货品名称</td>
            <td width="10%" height="22" align="center" valign="middle" >入库编码</td>
            <td width="7%" height="22" align="center" valign="middle" >入库数量</td>
            <td width="8%" height="22" align="center" valign="middle" >进价</td>
            <td width="10%" height="22" align="center" valign="middle" >金额</td>
            <td width="10%" height="22" align="center" valign="middle">有效期</td>
            <td width="10%" height="22" align="center" valign="middle">入库人</td>
            <td width="10%" height="22" align="center" valign="middle">备注</td>
            <td width="5%" height="22" align="center" valign="middle" >删除</td>
                     <%} else{%>
            <td width="5%" height="22"  align="center" valign="middle">序号</td>
            <td width="5%" height="22"  align="center" valign="middle">ID</td>
            <td width="20%" height="22" align="center" valign="middle" >货品名称</td>
            <td width="10%" height="22" align="center" valign="middle" >入库编码</td>
            <td width="10%" height="22" align="center" valign="middle" >入库数量</td>
            <td width="10%" height="22" align="center" valign="middle" >进价</td>
            <td width="10%" height="22" align="center" valign="middle" >金额</td>
            <td width="10%" height="22" align="center" valign="middle">有效期</td>
            <td width="10%" height="22" align="center" valign="middle">入库人</td>
            <td width="10%" height="22" align="center" valign="middle">备注</td>
                    <%}%>
            </tr>
          <%Response.Write(flist()); %>
        </table>
               <div class="ln_solid"></div> 
                       </form>  
                       <!-- 结束 -->         
                   </div>
            </div>
        </div>
     <!--替换内容-->
    </div>
</div> 
 <!-- 右页面内容完成 -->
    <!-- 底部内容 -->    
      <% Response.Write(copystr);%>
         <!-- 底部内容完成 -->
   <script src="/content/js/zmain.js" charset="utf-8" type="text/javascript"></script>
   <script   charset="utf-8" type="text/javascript">
        $(document).ready(function () {
            $('#fvcode').keyup(function(){
                var1 = "beduajax.aspx?ACT=1ABCDD96051DB83C89914473420AA861&zjm=" + $('#fvcode').val();
                var temptext = "";
                var1 = encodeURI((var1));
                $.ajax({
                    type: "Post",
                    url: var1,
                    data: { data1: '13D17C93EDB', },
                    cache: false,
                    contentType: "application/x-www-form-urlencoded; charset=UTF-8",
                    success: function (temptext) {
                        $("#fvhpmc").val(temptext);
                    }
                });
            });
            $('#firksl').keyup(function () {
                $('#zje').html('金额：￥' + $('#firksl').val() * $('#fdjhjz').val() + "元");
            });

            $('#fdjhjz').keyup(function () {
                $('#zje').html('金额：￥' + $('#firksl').val() * $('#fdjhjz').val() + "元");
            });
        });
   </script>
           <!--添加入库 弹窗-->
                <div id="jsAddUser" class="modal fade bs-example-modal-lg in" tabindex="-1" role="dialog" aria-hidden="true" style="margin-top:70px; padding-right: 17px;">
                    <div class="modal-dialog modal-lg">
                        <div class="modal-content" style="padding: 15px">
                            <div class="modal-header">
                                <button type="button" onclick="cansleAdd()" class="close" data-dismiss="modal">
                                    <span aria-hidden="true">×</span>
                                </button>
                                <h2 class="modal-title" id="jswintitle">货品入库</h2>
                            </div>
                            <form class="form-horizontal form-label-left" novalidate="" style="margin-top: 20px">
                                <div id="JS_div" runat="server">    </div>
                                 <input type="hidden" name="id" id="id" value="0"    />
                                <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">货品名称</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                      <input  type="text" id="fvcode" name="fvcode" class="form-control col-md-7 col-xs-12"   placeholder="首字母助记码" required="required" />
                                     <select class="form-control col-md-7 col-xs-12" id="fvhpmc" name="fvhpmc">
                                     <%Response.Write(fvhpmc); %>
                                    </select>
                                     </div>
                                </div>
                              <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">数量</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                        <input  type="text" id="firksl" name="firksl" class="form-control col-md-7 col-xs-12"   placeholder="数字整数" required="required" />
                                    </div>
                                </div>
                                <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">进价</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                        <input  type="text" id="fdjhjz" name="fdjhjz" class="form-control col-md-7 col-xs-12"   placeholder="进价货币型" required="required" />
                                        <div id="zje">金额：</div>
                                         </div>
                                </div>
                                   <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">直入直出</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                     <select class="form-control col-md-7 col-xs-12"  id="fizrst" name="fizrst"  >
                                                <%Response.Write(fizrst); %>
                                     </select>
                                    </div>
                                </div>
                                <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">有效期</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                        <input  type="text" id="ftyxrq" name="ftyxrq" class="form-control col-md-7 col-xs-12"  value="<%Response.Write(ftyxrq); %>"  placeholder="yyyy-MM-dd" required="required" />
                                         </div>
                                </div>
                                   <div class="item form-group bad">
                                    <label class="control-label col-md-3 col-sm-3 col-xs-12" for="name">备注说明</label>
                                    <div class="col-md-6 col-sm-6 col-xs-12">
                                        <input  type="text" id="fvbzsm" name="fvbzsm" class="form-control col-md-7 col-xs-12"  value="无" placeholder="备注说明-可写无" required="required" />
                                    </div>
                                </div>
                                <div class="ln_solid"></div>
                                <div class="form-group">
                                    <div class="col-md-6 col-md-offset-3">
                                        <button type="button" onclick="javascript: return checkSubmit();" class="btn btn-primary">保存</button>
                                        <button onclick="cansleAdd()" type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                                    </div>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
            <!--添加入库 弹窗--> 
</body>
    <script type="text/javascript">
        laydate.render({
            elem: '#fvrkbm1' //指定元素fvrkbm1
        });
        laydate.render({
            elem: '#fvrkbm2' //指定元素fvrkbm2  
        });
        laydate.render({
            elem: '#ftyxrq' //指定元素  ftyxrq
        });
</script>
</html>