<%@ page language="C#" autoeventwireup="true" inherits="Shop_Auction_shop_request_product, WebApp_deploy" title="发布商品求购信息" validaterequest="false" viewstateencryptionmode="Never" enableviewstatemac="false" %>

<html id="Html1" runat="server" visible="false">
<head>
    <title></title>
    <link href="/Skin/css/Auction/ShopSaleProduct.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <script type="text/javascript" language="javascript" src="/Js/HoWave_ShopClass.js"></script>
    <script type="text/javascript" language="javascript" src="/Js/HoWave_ShopSaleProduct.js"></script>
    <script type="text/javascript" language="javascript" src="/Js/SaleProduct.js"></script>
    <script type="text/javascript">
        var imageObject;
        function ResizeImage(obj, MaxW, MaxH) {
            if (obj != null) imageObject = obj;
            var state = imageObject.readyState;
            if (state != 'complete') {
                setTimeout("ResizeImage(null," + MaxW + "," + MaxH + ")", 50);
                return;
            }
            var oldImage = new Image();
            oldImage.src = imageObject.src;
            var dW = oldImage.width; var dH = oldImage.height;
            if (dW > MaxW || dH > MaxH) {
                a = dW / MaxW; b = dH / MaxH;
                if (b > a) a = b;
                dW = dW / a; dH = dH / a;
            }
            if (dW > 0 && dH > 0) {
                imageObject.width = dW;
                imageObject.height = dH;
            }
        }
    </script>
    <table class="SellProductDetail" id="table1">
        <tr>
            <th>
                <b>*</b>求购商品类别：
            </th>
            <td>
                <asp:Literal ID="Reuqest_Class" runat="server" />
                <asp:Label ID="ClassName" runat="server" />
                <asp:HiddenField ID="ClassID" runat="server" />
                <a href="javascript:void(0)" id="ChangeClass" onclick="return SelectClass()">[选择类目]</a>
                <br />
                <div id="ClassBar" style="background-color: #ffffff; border: 1px #ccc solid; display: none;
                    padding: 5px; height: 200px;">
                    <div style="float: none;">
                        <div style="float: left; width: 250px;">
                            您可以选择以下类目：</div>
                        <a href="javascript:void(0)" onclick="{ClassBar.style.display='none'}">关闭</a></div>
                    <div id="ClassBarContent">
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <th>
                <b>*</b>求购商品名称：
            </th>
            <td>
                <asp:TextBox ID="p_name" runat="server" Width="300px" />
                <asp:HiddenField ID="H_p_CLASSID" runat="server" />
                <br />
                <span style="color: Gray">
                    <br />
                    标题请限定在20个汉字内（40个字符）。如：求购佳能a70数码相机；求购纯白t恤衬衫。请写清楚您要求购的宝贝名称，卖家才能更容易看到您的求购信息。 </span>
            </td>
        </tr>
        <tr>
            <th>
                <b>*</b>对商品的要求：
            </th>
            <td>
                <asp:TextBox ID="ProductDescripe" runat="server" Style="display: none;" />
                <iframe src="Editor/Editor.aspx?id=ProductDescripe" frameborder="0" scrolling="auto"
                    width="100%" height="250"></iframe>
                <span style="color: Gray">
                    <br />
                    如：求佳能A70的新旧程度；T恤衬衫的型号，质地等等。描述得具体，卖家才能尽快提供给您合适的宝贝。</span>
            </td>
        </tr>
    </table>
    <table class="SellProductDetail" id="table2">
        <tr>
            <th>
                上传商品图片：
            </th>
            <td>
                <div style="float: left">
                    <asp:FileUpload ID="FileUpload1" runat="server" /></div>
                <div id="previewImage" style="float: right; height: 100px; width: 100px; border: solid 1px black;
                    text-align: center;">
                    缩微图
                </div>
            </td>
        </tr>
        <tr>
            <th>
                <b>*</b>求购数量：
            </th>
            <td>
                <asp:TextBox ID="p_num" runat="server" Text="1" Width="30px" MaxLength="4" />
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="p_num"
                    ErrorMessage="不能空" Display="Dynamic" />
                <asp:RangeValidator ID="rv1" runat="server" ControlToValidate="p_num" ErrorMessage="整数类型"
                    MaximumValue="9999999" MinimumValue="1" Type="Integer" Display="Dynamic" />
            </td>
        </tr>
        <tr>
            <th>
                <b>*</b>单位：
            </th>
            <td>
                <asp:TextBox ID="P_uint" runat="server" Width="40px" Text="件" />
                <select onchange='document.getElementById("ctl00$ContentPlaceHolder1$P_uint").value=this.value'
                    name="selectmsg">
                    <option value="件" selected>件</option>
                    <option value="个">个</option>
                    <option value="台">台</option>
                    <option value="批">批</option>
                    <option value="箱">箱</option>
                    <option value="本">本</option>
                    <option value="双">双</option>
                    <option value="瓶">瓶</option>
                    <option value="">其它</option>
                </select>
                <asp:RequiredFieldValidator ID="rfv4" runat="server" ControlToValidate="P_uint" ErrorMessage="不能空"
                    Display="Dynamic" />
            </td>
            <tr>
                <th>
                    <b>*</b>商品价格：
                </th>
                <td>
                    <asp:TextBox ID="p_price" runat="server" MaxLength="6" Width="50px" />
                    元
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="p_price"
                        ErrorMessage="不能空" Display="Dynamic" />
                    <asp:RangeValidator ID="RangeValidator3" runat="server" ControlToValidate="p_price"
                        ErrorMessage="数字类型" MaximumValue="999999999" MinimumValue="0" Type="Double" Display="Dynamic" />
                </td>
            </tr>
            <tr>
                <th>
                    <b>*</b>求购有效期：
                </th>
                <td>
                    <asp:TextBox ID="p_validay" runat="server" Text="7" Width="30px" MaxLength="2" />
                    天<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="p_validay"
                        ErrorMessage="不能空" />
                    <asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="p_validay"
                        ErrorMessage="整数类型" MaximumValue="9999999" MinimumValue="1" Type="Integer" Display="Dynamic" />
                </td>
            </tr>
            <tr>
                <th>
                    *求购所在地：
                </th>
                <td>
                    <asp:ScriptManager ID="ScriptManager1" runat="server">
                    </asp:ScriptManager>
                    <hl:howaveprovincecity id="HowaveProvinceCity1" runat="server" />
                </td>
            </tr>
            <tr>
                <th>
                    心情故事：
                </th>
                <td>
                    <asp:TextBox ID="p_remark" runat="server" TextMode="MultiLine" Height="100px" Width="300px" />
                </td>
            </tr>
            <tr>
                <th>
                </th>
                <td>
                    <asp:Label ID="err_tips" runat="server" />
                </td>
            </tr>
            <tr>
                <td colspan="2" align="center">
                    <asp:Button ID="prev_Button" runat="server" Text="预 览" Visible="false" /><asp:Button
                        ID="submit_btn" runat="server" Text="确认无误，提交" OnClick="submit_btn_click" />
                </td>
            </tr>
    </table>
    <input type="hidden" name="RequestProduct" value="true" />
    </form>
</body>
</html>
