<%@ Page Language="C#" %>
<%@ Register TagPrefix="aspxform" Namespace="XFormDesigner.Framework.Web.UI" Assembly="XFormDesigner.Framework" %>
<script runat="server">

    // Insert page code here
    //

</script>
<html xmlns:xform="xmlns:xform">
<head runat="server">
    <link href="/Oimec/Styles/css/StyleSheet.css" rel="stylesheet" type="text/css" />
    <title>BPM Form</title> <style>
    BODY {FONT-SIZE: 12px; FONT-FAMILY: verdana}
    TABLE {border-collapse: collapse; FONT-SIZE: 12px; FONT-FAMILY: verdana}
    P {PADDING-RIGHT: 0px; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px; FONT-SIZE: 12px; FONT-FAMILY: verdana}
    TD {PADDING-RIGHT: 0px; PADDING-LEFT: 2px; PADDING-BOTTOM: 0px}
    TD.NoPadding {PADDING-RIGHT: 0px; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; PADDING-TOP: 0px}
    INPUT {HEIGHT: 20px}
    INPUT.UL {BORDER-RIGHT: medium none; BORDER-TOP: medium none; BORDER-LEFT: medium none; BORDER-BOTTOM: #33ff33 1px solid}
    TEXTAREA {FONT-SIZE:12px}
    </style>
</head>
<script type="text/javascript">
YZSoft.XForm.Agent.BlockButtonClick = function(ev, el, opt) {
    var x = YZSoft.XForm;
    var xa = x.Agent;

    if (!xa.BlockMenu) {
        var insertAbove = new Ext.menu.Item({
            iconCls: 'insertabove',
            text: RS.$('YZStrings.XFormAgent_Grid_InsertAbove'),
            handler: function(item) {
                var o = item.parentMenu.opt;
                o.grid.InsertBlockAbove(o.blockIndex);
            }
        });

        var insertBelow = new Ext.menu.Item({
            iconCls: 'insertbelow',
            text: RS.$('YZStrings.XFormAgent_Grid_InsertBelow'),
            handler: function(item) {
                var o = item.parentMenu.opt;
                o.grid.InsertBlockBelow(o.blockIndex);
            }
        });

        var appendCopy = new Ext.menu.Item({
            iconCls: 'appendcopy',
            text: RS.$('YZStrings.XFormAgent_Grid_AppendCopy'),
            handler: function(item) {
                var o = item.parentMenu.opt;
                o.grid.AppendCopy(o.blockIndex);
            }
        });

        var copy = new Ext.menu.Item({
            iconCls: 'copy',
            text: RS.$('YZStrings.XFormAgent_Grid_Copy'),
            handler: function(item) {
                var o = item.parentMenu.opt;
                o.elType.CopyTable = xa.CopyBlock(o.grid.Blocks[o.blockIndex]);
            }
        });

        var paste = new Ext.menu.Item({
            iconCls: 'paste',
            text: RS.$('YZStrings.XFormAgent_Grid_Paste'),
            handler: function(item) {
                var o = item.parentMenu.opt;
                o.grid.PasteBlockCopy(o.blockIndex);
            }
        });

        var del = new Ext.menu.Item({
            iconCls: 'delete',
            text: RS.$('YZStrings.XFormAgent_Grid_Delete'),
            handler: function(item) {
                var inames = '';
                var n;
                inames = XFormShell.XFormAgent.CalcExpress(el, "DF_ASSETDISPOSAL_DETAIL.AssetID");
                inamesline = XFormShell.XFormAgent.CalcExpress(el, "DF_ASSETDISPOSAL_DETAIL.LineNumber");
                if (inamesline != 1) {
                    n = inames[item.parentMenu.opt.blockIndex];
                }
                else {
                    n = inames;
                }

                var o = item.parentMenu.opt;
                o.grid.DeleteBlocks(o.blockIndex, 1);
                var tidvalue = agent.Eles[document.getElementById("XTextBox5").getAttribute("xform_xele_index")].getValue();




                //alert(n);
                if (tidvalue != "") {
                    YZSoft.Ajax.request({
                        url: YZSoft.$url( 'Oimec/WorkFlow/Rent2/RFC/UpdateAssetCZData.ashx'),
                        params: { AssetBPMID: n, taskid: tidvalue },
                        sync: true,
                        success: function(action) {
                            //alert("dd");
                        },
                        failure: function(action) {
                            alert(action.result.errorMessage);
                        }
                    })
                }
            }
        });

        xa.BlockMenu = new Ext.menu.Menu({
            cls: 'yz-grid-menu',
            shadow: false,
            minWidth: 80,
            items: [insertAbove, insertBelow, appendCopy, '-', copy, paste, '-', del],
            listeners: {
                show: function() { xa.menuTrack = true; },
                hide: function() { xa.menuTrack = false; }
            }
        });
    }

    xa.BlockMenu.opt = opt;
    var items = xa.BlockMenu.items;
    items.itemAt(0).setDisabled(true);
    items.itemAt(1).setDisabled(true);
    items.itemAt(2).setDisabled(true);
    items.itemAt(4).setDisabled(true);
    items.itemAt(5).setDisabled(!opt.elType.CopyTable);
    var bc = opt.grid.Blocks.length;
    items.itemAt(7).setDisabled((bc <= 0) || (bc == 1 && opt.elType.GridDefine.ShowOneBlockAlways));

    xa.BlockMenu.show(el);

}



</script>
<body>
    <form runat="server">
        <table width="1200" align="center" class="head" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td class="logo">
                    </td>
                    <td class="biaoti">
                        <asp:Label id="XLabel2" runat="server" value valuetodisplaytext text="资产处置申请单 "></asp:Label></td>
                    <td class="formno">
                        <asp:Label id="XLabel93" runat="server" value valuetodisplaytext text="表单号："></asp:Label>
                        <aspxform:XLabel id="XLabel94" runat="server" Value ValueToDisplayText text="----自动生成------" BackColor="#8AB3DF" XDataBind="DF_ASSETDISPOSAL_INFO.FormNo"></aspxform:XLabel>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table align="center" class="table">
            <tbody>
                <tr>
                    <td class="basiclblfirst" style="WIDTH: 10%">
                        <asp:Label id="XLabel5" runat="server" value valuetodisplaytext text="创建用户"></asp:Label></td>
                    <td class="basictextfirst" style="WIDTH: 35%">
                        <aspxform:XTextBox id="XTextBox20" runat="server" ValueToDisplayText="TableName:V_Users;FilterColumn:Account;DisplayColumn:DisplayName" XDataBind="DF_ASSETDISPOSAL_INFO.CreateName" DisableBehavior="ReadOnly" Width="50%" CssClass="text" backColor="#e6f1f8" ReadOnly="True"></aspxform:XTextBox>
                    </td>
                    <td class="basiclblfirst3" style="WIDTH: 10%">
                        <asp:Label id="XLabel49" runat="server" value valuetodisplaytext text="创建日期"></asp:Label></td>
                    <td class="basictextfirst3" style="WIDTH: 35%">
                        <aspxform:XDateTimePicker id="XDateTimePicker4" runat="server" XDataBind="DF_ASSETDISPOSAL_INFO.CreateDate" Width="50%" CssClass="text" backColor="#e6f1f8" DisplayOnly="True"></aspxform:XDateTimePicker>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table align="center" class="table">
            <tbody>
                <tr>
                    <td class="title1" colspan="6">
                        <asp:Label id="XLabel1" runat="server" value valuetodisplaytext text="基本信息"></asp:Label></td>
                </tr>
                <tr>
                    <td class="basiclblfirst" style="WIDTH: 10%">
                        <asp:Label id="XLabel3" runat="server" value valuetodisplaytext text="业务员"></asp:Label></td>
                    <td class="basictextfirst" style="WIDTH: 35%">
                        <div style="FLOAT: left">
                            <aspxform:XTextBox id="XTextBox3" runat="server" ValueToDisplayText XDataBind="DF_ASSETDISPOSAL_INFO.SalesMan" Width="100" CssClass="text" backColor="#e6f1f8" ReadOnly="True"></aspxform:XTextBox>
                        </div>
                        <aspxform:XDataBrowserButton id="XDataBrowserButton9" runat="server" Width="60px" CssClass="anxiu" DisplayColumns="DisplayName:姓名,;Mobile:联系电话,;OUName:部门," Text="查询" XDataSource="TableName:V_ContraUser" DataMap="DisplayName->DF_ASSETDISPOSAL_INFO.SalesMan;OUName->DF_ASSETDISPOSAL_INFO.Area"></aspxform:XDataBrowserButton>
                    </td>
                    <td class="basiclblfirst3" style="WIDTH: 10%">
                        <asp:Label id="XLabel8" runat="server" value valuetodisplaytext text="所属区域"></asp:Label></td>
                    <td class="basictextfirst3" style="WIDTH: 35%">
                        <aspxform:XTextBox id="XTextBox2" runat="server" ValueToDisplayText XDataBind="DF_ASSETDISPOSAL_INFO.Area" Width="50%" CssClass="text" backColor="#e6f1f8" ReadOnly="True"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="basiclblfirst" style="WIDTH: 10%">
                        <asp:Label id="XLabel7" runat="server" value valuetodisplaytext text="税种"></asp:Label>
                        <aspxform:XLabel id="XLabel83" style="DISPLAY: none" runat="server" Value ValueToDisplayText text="shuizhongzc" XDataBind="varsz"></aspxform:XLabel>
                    </td>
                    <td class="basictextfirst" style="WIDTH: 35%">
                        <aspxform:XDropDownList id="XDropDownList7" runat="server" XDataBind="DF_ASSETDISPOSAL_INFO.TaxType" Width="50%" XDataSource="TableName:V_DF_DataSourceList;Filter:Type->varsz;BufferType:RuntimeUpdate" DataMap="Value->DF_ASSETDISPOSAL_INFO.RateName" ValueColumn="ItemID" DisplayColumn="Name" PromptText="-请选择-">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="basiclblfirst3" style="WIDTH: 10%">
                        <asp:Label id="XLabel9" runat="server" value valuetodisplaytext text="税率"></asp:Label></td>
                    <td class="basictextfirst3" style="WIDTH: 35%">
                        <aspxform:XDropDownList id="XDropDownList2" runat="server" XDataBind="DF_ASSETDISPOSAL_INFO.RateName" XDataSource="TableName:V_DF_DataSourceList;Filter:LdValue->DF_ASSETDISPOSAL_INFO.TaxType;BufferType:RuntimeUpdate" DataMap="CalValue->DF_ASSETDISPOSAL_INFO.Rate" ValueColumn="Value" DisplayColumn="Name" PromptText="-请选择-">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox4" runat="server" XDataBind="DF_ASSETDISPOSAL_INFO.Rate" HiddenInput="True" width="100%" BorderWidth="1" BorderColor="#DCDCDC"></aspxform:XTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table align="center" class="table" dynamicarea="2,1">
            <tbody>
                <tr>
                    <td style="FONT-SIZE: 16px; BORDER-TOP: #93a1ae 1px solid; FONT-FAMILY: 微软雅黑; BORDER-RIGHT: #d4e4fe 0px solid; BORDER-BOTTOM: #b2bcc6 1px solid; FONT-WEIGHT: bold; BORDER-LEFT: #93a1ae 1px solid; BACKGROUND-COLOR: #c1d7ec" colspan="6">
                        <asp:Label id="XLabel4" runat="server" value valuetodisplaytext text="仪器基本信息"></asp:Label></td>
                    <td align="right" style="FONT-SIZE: 16px; BORDER-TOP: #93a1ae 1px solid; FONT-FAMILY: 微软雅黑; BORDER-RIGHT: #c1d7ec 1px solid; BORDER-BOTTOM: #b2bcc6 1px solid; FONT-WEIGHT: bold; BORDER-LEFT: #d4e4fe 0px solid; BACKGROUND-COLOR: #c1d7ec">
                    </td>
                    <td align="right" style="FONT-SIZE: 16px; BORDER-TOP: #93a1ae 1px solid; FONT-FAMILY: 微软雅黑; BORDER-RIGHT: #c1d7ec 1px solid; BORDER-BOTTOM: #b2bcc6 1px solid; FONT-WEIGHT: bold; BORDER-LEFT: #d4e4fe 0px solid; BACKGROUND-COLOR: #c1d7ec">
                    </td>
                    <td align="right" style="FONT-SIZE: 16px; BORDER-TOP: #93a1ae 1px solid; FONT-FAMILY: 微软雅黑; BORDER-RIGHT: #93a1ae 1px solid; BORDER-BOTTOM: #b2bcc6 1px solid; FONT-WEIGHT: bold; BORDER-LEFT: #d4e4fe 0px solid; BACKGROUND-COLOR: #c1d7ec">
                        <p>
                            <aspxform:XCustomBrowserButton id="XCustomBrowserButton1" runat="server" Width="113px" CssClass="anxiu" Text="选择仪器" XDataSource="" DataMap="PrdtModelNo->DF_ASSETDISPOSAL_DETAIL.PrdtModelNo;PrdtName->DF_ASSETDISPOSAL_DETAIL.PrdtName;SerialNo->DF_ASSETDISPOSAL_DETAIL.SerialNo;SapAssetID->DF_ASSETDISPOSAL_DETAIL.SapAssetID;StorageID->DF_ASSETDISPOSAL_DETAIL.StorageID;PurchaseDate->DF_ASSETDISPOSAL_DETAIL.BuyDate;ManufacturerID->DF_ASSETDISPOSAL_DETAIL.Manufacturer;AssetID->DF_ASSETDISPOSAL_DETAIL.AssetID" MultiSelect="True" NavigateUrl="DFJC/Dialogs/ZCCZSearch.js" BrowserWindowType="AjaxPanel" DisableExpress="Global.StepName=='物流部经理审批'||Global.StepName=='2.业务推进部经理审批'"></aspxform:XCustomBrowserButton>
                        </p>
                    </td>
                </tr>
                <tr>
                    <td width="50" height="18" align="center" class="tds">
                        <asp:Label id="XLabel32" runat="server" value valuetodisplaytext text="序号"></asp:Label></td>
                    <td width="150" align="center" class="tds">
                        <div align="center">
                            <div align="center"><asp:Label id="XLabel36" runat="server" value valuetodisplaytext text="SAP固定资产号"></asp:Label>
                            </div>
                        </div>
                    </td>
                    <td width="150" align="center" class="tds">
                        <div align="center">
                            <div align="center"><asp:Label id="XLabel33" runat="server" value valuetodisplaytext text="产品型号"></asp:Label>
                            </div>
                        </div>
                    </td>
                    <td width="150" align="center" class="tds">
                        <div align="center"><asp:Label id="XLabel39" runat="server" value valuetodisplaytext text="产品中文名称"></asp:Label>
                        </div>
                    </td>
                    <td width="150" align="center" class="tds">
                        <div align="center"><asp:Label id="XLabel6" runat="server" value valuetodisplaytext text="资产处置含税价格"></asp:Label>
                        </div>
                    </td>
                    <td width="150" align="center" class="tds">
                        <div align="center"><asp:Label id="XLabel10" runat="server" value valuetodisplaytext text="资产处置不含税价格"></asp:Label>
                        </div>
                    </td>
                    <td width="150" align="center" class="tds">
                        <asp:Label id="XLabel38" runat="server" value valuetodisplaytext text="厂商"></asp:Label></td>
                    <td width="150" align="center" class="tds">
                        <asp:Label id="XLabel35" runat="server" value valuetodisplaytext text="序列号"></asp:Label></td>
                    <td width="150" align="center" class="tds" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <asp:Label id="XLabel37" runat="server" value valuetodisplaytext text="库存地"></asp:Label></td>
                </tr>
                <tr>
                    <td height="25" class="tds1">
                        <aspxform:XGridLineNo id="XGridLineNo1" runat="server" BackColor="Transparent" XDataBind="DF_ASSETDISPOSAL_DETAIL.LineNumber" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BorderStyle="None" TextAlign="Center">1</aspxform:XGridLineNo>
                    </td>
                    <td class="tds1">
                        <aspxform:XTextBox id="XTextBox8" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.SapAssetID" CssClass="text1" backColor="#e6f1f8" ReadOnly="True" width="99.9%"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox9" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.AssetID" CssClass="text1" backColor="#e6f1f8" ReadOnly="True" HiddenInput="True" width="50%"></aspxform:XTextBox>
                    </td>
                    <td class="tds1">
                        <aspxform:XTextBox id="XTextBox6" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.PrdtModelNo" CssClass="text1" backColor="#e6f1f8" ReadOnly="True" width="99.9%"></aspxform:XTextBox>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox100" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.PrdtName" CssClass="text1" backColor="#e6f1f8" ReadOnly="True" width="99.9%"></aspxform:XTextBox>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox14" runat="server" Value ValueToDisplayText XDataBind="DF_ASSETDISPOSAL_DETAIL.AssetDisposalValue" Max="0" Min="0" HiddenInput="False" width="99.9%" TextAlign="Right" Format="type:currency;.2"></aspxform:XTextBox>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox7" runat="server" Value ValueToDisplayText XDataBind="DF_ASSETDISPOSAL_DETAIL.AssetDisposalNOValue" CssClass="text1" backColor="#E6F1F8" ReadOnly="True" Max="0" Min="0" HiddenInput="False" width="99.9%" TextAlign="Right" Format="type:currency;.2" Express="DF_ASSETDISPOSAL_DETAIL.AssetDisposalValue/(1+DF_ASSETDISPOSAL_INFO.Rate)"></aspxform:XTextBox>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox1" runat="server" Value ValueToDisplayText="TableName:V_DF_DataSourceList_changshang;FilterColumn:ItemID;DisplayColumn:Name" XDataBind="DF_ASSETDISPOSAL_DETAIL.Manufacturer" DisableBehavior="ReadOnly" CssClass="text1" backColor="#E6F1F8" ReadOnly="True" Max="0" Min="0" HiddenInput="False" width="99.9%"></aspxform:XTextBox>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox19" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.SerialNo" CssClass="text1" backColor="#e6f1f8" ReadOnly="True" width="99.9%"></aspxform:XTextBox>
                        <aspxform:XDateTimePicker id="XDateTimePicker1" style="DISPLAY: none" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.BuyDate" Width="100px" BorderWidth="1" BorderColor="#DCDCDC"></aspxform:XDateTimePicker>
                    </td>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XDropDownList id="XDropDownList1" runat="server" XDataBind="DF_ASSETDISPOSAL_DETAIL.StorageID" Width="99.9%" XDataSource="TableName:V_Storage" ValueColumn="StorageID" DisplayColumn="StorageName" PromptText="--请选择--" DisableExpress="123456789">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table align="center" class="table">
            <tbody>
                <tr>
                    <td class="title1">
                        <asp:Label id="XLabel22" runat="server" value valuetodisplaytext text="备注"></asp:Label></td>
                </tr>
                <tr>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XTextBox id="XTextBox18" runat="server" Value ValueToDisplayText XDataBind="DF_ASSETDISPOSAL_INFO.Remark" Width="100%" CssClass="text" Max="0" Min="0" HiddenInput="False" BorderWidth="1px" TextMode="MultiLine" Height="76px"></aspxform:XTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table align="center" class="table">
            <tbody>
                <tr>
                    <td class="title1">
                        <asp:Label id="XLabel30" runat="server" value valuetodisplaytext text="意见"></asp:Label></td>
                </tr>
                <tr>
                    <td class="tds1" style="BORDER-RIGHT: #93a1ae 1px solid; TEXT-ALIGN: center">
                        <aspxform:XCommentsTextBox id="XCommentsTextBox1" runat="server" Width="100%" CssClass="text" BorderWidth="1" TextMode="MultiLine" Rows="5"></aspxform:XCommentsTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <table width="1200" align="center" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="22">
                        <aspxform:XProcessButtonList id="XProcessButtonList1" runat="server" PositionSelectVisible="False"></aspxform:XProcessButtonList>
                        <aspxform:XTextBox id="XTextBox5" runat="server" XDataBind="DF_ASSETDISPOSAL_INFO.TaskID" HiddenInput="True" BorderWidth="1" BorderColor="#DCDCDC"></aspxform:XTextBox>
                    </td>
                    <td>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <p align="center">
            <aspxform:XSignTrace id="XSignTrace1" runat="server" Width="1200px" BorderWidth="1" BorderColor="#dcdcdc"></aspxform:XSignTrace>
        </p>
        <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator8" runat="server" ControlToValidate="XTextBox14" ErrorMessage="请填写资产处置含税价格"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator1" runat="server" ControlToValidate="XDropDownList2" ErrorMessage="请选择税率"></aspxform:XRequiredFieldValidator>
    </form>
</body>
</html>
