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

    protected void Page_Load(object sender, EventArgs e)
    {
        string formstate = Convert.ToString(Request.Params["formstate"]);
        this.XTextBox192.Text = formstate;
    
    }

</script>
<html xmlns:xform="xmlns:xform">
<head runat="server">

    <link href="/Oimec/Styles/css/StyleSheet1366.css" rel="stylesheet" type="text/css" />
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />
    <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;
        }

        .yz-inp-cnt {
            display: inline;
        }

        .tm {
            width: 8%;
        }

        .ty {
            border-bottom: #b2bcc6 1px solid;
            border-left: #93a1ae 1px solid;
            border-top: #93a1ae 1px solid;
            border-right: #b2bcc6 1px solid;
            font-family: 微软雅黑;
            font-size: 14px;
            width: 8%;
        }

        .inputbtn {
            color: Red;
            font-size: 15px;
            font-family: 微软雅黑;
        }

        .tdStyle {
            WIDTH: 10%;
            font-size: 16px;
            text-align: right;
        }
    </style>
     <script src="../../../../Oimec/Script/jquery-3.2.1.js"></script>
    <script src="../../../../Oimec/Script/jquery-3.2.1.min.js"></script>
    <script type="text/javascript">
        //获取X控件值
        function GetXValue(id) {
            return agent.Eles[document.getElementById(id).getAttribute("xform_xele_index")].getValue();
        }

        //控件是否选中 checkbox,radiobutton
        function XChecked(name) {
            var inputs = document.getElementsByTagName("input");
            for (var i = 0; i < inputs.length; i++) {
                var a = document.getElementsByName(name);
                if (inputs[i].name == name) {
                    return inputs[i].checked;
                }
            }
        }


        /*   注**：这是一个公共的方法
       **  获取行项目table对应标签控件元素id
       **  参数说明：name(控件name)，i(行索引)，htmltag(要获取控件div中对应的标签名)
       **  示例：获取第1行行项目文本框name="txtname",参数：txtname,0,input
       */
        function getElementId(name, i, htmltag) {
            var divs = document.getElementsByName(name);
            var div = divs[i];
            var id = div.getElementsByTagName(htmltag)[0].id;
            return id;

        }


        //实体清单客户
        function stqdkh(sdf, fkf) {
            //查询是否是实体清单客户

            //产品明细
            var tableObj = document.getElementById('tablenew');

            var issdf = false;
            var isfkf = false;
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列

                var IsFlagSDF = document.getElementById(getElementId("IsFlagSDF", i - 2, "select")).value;
                var IsFlagFKF = document.getElementById(getElementId("IsFlagFKF", i - 2, "select")).value;

                if (IsFlagSDF)
                    issdf = true;
                if (IsFlagFKF)
                    isfkf = true;
            }
            if (issdf)
                $("input[name='XRadioButtonList3'][value=T]").attr("checked", true);//T为是
            else
                $("input[name='XRadioButtonList3'][value=F]").attr("checked", true);

            if (isfkf)
                $("input[name='XRadioButtonList4'][value=T]").attr("checked", true);//T为是
            else
                $("input[name='XRadioButtonList4'][value=F]").attr("checked", true);
        }

    </script>

    <%--获取供应商数量--%>
    <script type="text/javascript">

        //删除数组中某数据
        Array.prototype.del = function (n) {　//n表示第几项，从0开始算起。
            //prototype为对象原型，注意这里为对象增加自定义方法的方法。
            if (n < 0)　//如果n<0，则不进行任何操作。
                return this;
            else
                return this.slice(0, n).concat(this.slice(n + 1, this.length));
            /*
          　　　concat方法：返回一个新数组，这个新数组是由两个或更多数组组合而成的。
          　　　　　　　　　这里就是返回this.slice(0,n)/this.slice(n+1,this.length)
          　　 　　　　　　组成的新数组，这中间，刚好少了第n项。
          　　　slice方法： 返回一个数组的一段，两个参数，分别指定开始和结束的位置。
          　　*/
        }
        //获取供应商数量，如果供应商相同就将它删除，得到不同供应商数量。
        function GetInfoFromTable(tableid) {
            var tableInfo1 = new Array();
            var tableRow = "";
            var tableObj = document.getElementById(tableid);
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                var str = tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[35].children[0].getAttribute("xform_xele_index")].getValue();
            }
            for (var i = 0; i < tableInfo1.length; i++) {
                if (tableInfo1.length !== 1) {
                    var j = i + 1;
                    while (j < tableInfo1.length) {

                        if (tableInfo1[i] === tableInfo1[j]) {
                            tableInfo1 = tableInfo1.del(i);
                            i = 0;
                            j = i + 1;
                            continue;
                        }
                        else {
                            j++;
                        }
                    }
                }
                else {
                    break;
                }

            }
            //document.getElementById("XTextBox25").value = tableInfo1.length;
            return tableInfo1.length;
        }
        //获取产品BPMID
        function GetMaterialTable(tableid) {
            var tableInfo1 = new Array();
            var tableRow = "";
            var tableObj = document.getElementById(tableid);
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[5].children[1].getAttribute("xform_xele_index")].getValue();
            }
            //document.getElementById("XTextBox25").value = tableInfo1.length;
            return tableInfo1;
        }
        //获取物料类型
        function GetMaterialTable1(tableid) {
            var tableInfo1 = new Array();
            var tableRow = "";
            var tableObj = document.getElementById(tableid);
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[2].children[4].getAttribute("xform_xele_index")].getValue();
            }
            //document.getElementById("XTextBox25").value = tableInfo1.length;
            return tableInfo1;
        }
        //产品型号添加自动点击事件(暂时不用)
        function GetMaterialTable2(tableid) {
            var tableInfo1 = new Array();
            var tableRow = "";
            var tableObj = document.getElementById(tableid);
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                if (!tableObj.rows[i].cells[3].children[0].children[0].disabled) {
                    //tableObj.rows[i].cells[3].children[0].children[0].focus();
                    //tableObj.rows[i].cells[3].children[0].children[0].blur();
                }

                //tableObj.rows[i].cells[3].children[1].children[0].focus();
                //tableObj.rows[i].cells[3].children[1].children[0].blur();
            }
            //document.getElementById("XTextBox25").value = tableInfo1.length;
            return tableInfo1;
        }

    </script>
    <%--将税率转换为小数格式--%>
    <script type="text/javascript">
        //将税率转换为小数格式
        function GetRate(rateB) {
            var rate = 0;
            if (rateB === "17%") {
                rate = 0.17;
            }
            else if (rateB === "6%") {
                rate = 0.06;
            }
            else if (rateB === "3%") {
                rate = 0.03;
            }
            else if (rateB === "5%") {
                rate = 0.05;
            }
            else if (rateB === "16%") {
                rate = 0.16;
            }
            else if (rateB === "13%") {
                rate = 0.13;
            }
            return rate;
        }
    </script>
    <%--折扣计算 参数：ZheKou-折扣，UnitPrice-单价，Number-数量--%>
    <script type="text/javascript">
        function CountPurchasePrices(ZheKou, UnitPrice, Number, ManufacturersID) {
            var Sum = 0;
           
            //if (ManufacturersID == "217") {
            //    //计算公式：采购单价×（1+标准服务比例）×数量×（1-采购折扣%）
                
            //   Proportion = (100 +Proportion) / 100;
                
            //    ZheKou = (100 - ZheKou) / 100;
                
            //    Sum = UnitPrice * Proportion * Number * ZheKou;
            
            //}else{
                if (ZheKou == 0) {
                    Sum = UnitPrice * Number;
                }
                else {
                    ZheKou = (100 - ZheKou) / 100;
                    Sum = UnitPrice * Number * ZheKou;
                }
      //  }
            
            return Sum;
        }
    </script>
    <%--HOSIC相关费用计算公式--%>
    <script type="text/javascript">
        //sale-不含税销售总价（人民币）,BillingCompany-开票公司，CustomerDeliveryWay-客户交货方式，Purchase-不含税采购总价（人民币），TermsPayment-付款条件
        function CountBankCost(sale, BillingCompany, CustomerDeliveryWay, Purchase, TermsPayment) {
            var BankCost = 0;
            var HOSICCost = 0;
            var HOSICBank = 0;
            var HOSICFreightFee = 0;
            var HOSICInsuranceFee = 0;
            //美元汇率
            var USD = agent.Eles[document.getElementById("XTextBox95").getAttribute("xform_xele_index")].getValue();
            if (BillingCompany == "A300HOSIC 香港") {
                //HOSIC 手续费
                HOSICCost = HOSICTransactionFee(CustomerDeliveryWay, sale, USD);
                //ZHD6-银行费用
                HOSICBank = OFHOSICBankFee(BillingCompany, TermsPayment, sale);
                //ZHD3-运保费
                HOSICFreightFee = HOSICFreight(CustomerDeliveryWay, USD);
                //ZHD4-入关费
                HOSICInsuranceFee = HOSICTransportationInsurance(CustomerDeliveryWay, sale, USD, Purchase);

            }
            BankCost = HOSICCost + HOSICBank + HOSICFreightFee + HOSICInsuranceFee;
            return BankCost;
        }
        //ZHD6-银行费用
        //BillingCompany-开票公司，sale-不含税销售总价（人民币），TermsPayment-付款条件
        function HOSICBankFee(BillingCompany, TermsPayment, sale, GongYingShang) {
            var TT = 0;
            //供应商数量
            var SupplierNumber = GetInfoFromTable('tablenew');
            //美元汇率
            ////var USD = document.getElementById("XTextBox95").value;
            var USD = agent.Eles[document.getElementById("XTextBox95").getAttribute("xform_xele_index")].getValue();
            if (BillingCompany == "2000上海颐合" || BillingCompany == "A300HOSIC 香港") {
                var HOSICBank = 0;
                if (TermsPayment == "100%信用证(L/C) 100%见单议付" || TermsPayment == "100%信用证(L/C) 90%见单议付，10%验收议付60") {
                    var commission = 0;
                    if (sale / USD < 50000) {
                        commission = (sale * 0.00125);
                    }
                    else if (sale / USD >= 50000) {
                        commission = (sale * 0.000625);
                    }
                    TT = (20 * SupplierNumber) * USD;
                    HOSICBank = commission + (40 * USD) + TT;
                }
                else {
                    if (SupplierNumber == 1) {
                        HOSICBank = (20 * 2) * USD;
                    }
                    else {
                        HOSICBank = (20 + (20 * SupplierNumber)) * USD;
                    }
                }
            }
            return HOSICBank;
        }
        //厂商是Agilent 安捷伦时的银行费用
        function OFHOSICBankFee(BillingCompany, TermsPayment, sale, GongYingShang) {
            var USD = agent.Eles[document.getElementById("XTextBox95").getAttribute("xform_xele_index")].getValue();
            var BankFee = HOSICBankFee(BillingCompany, TermsPayment, sale, GongYingShang);
            var tableObj = document.getElementById('tablenew');
            //获取所有的厂商编号，如果有厂商是Agilent 安捷伦时，则在原银行费上加上100美金
            //for (var i = 2; i < tableObj.rows.length - 1; i++) {//遍历Table的所有Row //遍历Row中的每一列
            //    ////if (tableObj.rows[i].cells[6].children[0].children[0].value == '103') {
            //    if (agent.Eles[tableObj.rows[i].cells[6].children[0].getAttribute("xform_xele_index")].getValue() == '103') {
            //        BankFee = BankFee + (100 * USD);
            //        break;
            //    }
            //}
            return BankFee;
        }

        //HOSIC 手续费
        //CustomerDeliveryWay-客户交货方式，sale-不含税销售总价（人民币），USD-美金汇率
        function HOSICTransactionFee(CustomerDeliveryWay, sale, USD) {
            var HOSICCost = 0;
            if (CustomerDeliveryWay == "供应商直发**机场") {
                if (sale / USD < 50000) {
                    HOSICCost = (sale * 0.012);
                }
                else if (sale / USD >= 50000 && sale / USD < 100000) {
                    HOSICCost = (sale * 0.01);
                }
                else {
                    HOSICCost = (sale * 0.008);
                }
            }
            else {
                if (sale / USD < 20000) {
                    HOSICCost = (sale * 0.016);
                }
                else if (sale / USD >= 20000 && sale / USD < 50000) {
                    HOSICCost = (sale * 0.014);
                }
                else if (sale / USD >= 50000 && sale / USD < 100000) {
                    HOSICCost = (sale * 0.012);
                }
                else if (sale / USD >= 100000) {
                    HOSICCost = (sale * 0.01);
                }
                else {
                    HOSICCost = 0;
                }
            }
            return HOSICCost;
        }
        //ZHD3-运保费（HOSIC接/送货运费）
        //CustomerDeliveryWay - 客户交货方式，USD-美金汇率
        function HOSICFreight(CustomerDeliveryWay, USD) {
            SupplierNumber = GetInfoFromTable('tablenew');
            var Freight = 0;
            if (CustomerDeliveryWay == "HOSIC发至**机场") {
                Freight = (100 * USD * SupplierNumber) + (100 * USD);
            }
            else if (CustomerDeliveryWay == "HOSIC送货到客户香港指定地点") {
                Freight = (100 * USD * SupplierNumber) + (100 * USD);
            }
            else if (CustomerDeliveryWay == "客户到HOSIC办公室自提") {
                Freight = (100 * USD * SupplierNumber);
            }
            else {
                Freight = 0;
            }
            return Freight;
        }
        //ZHD4-入关费（香港国内运保费）
        //CustomerDeliveryWay - 客户交货方式，sale - 不含税销售总价（人民币），USD - 美金汇率，Purchase-不含税采购总价（人民币）
        function HOSICTransportationInsurance(CustomerDeliveryWay, sale, USD, Purchase) {
            var TransportationInsurance = 0.00;
            if (CustomerDeliveryWay == "HOSIC发至**机场") {
                if (sale / USD < 20000) {
                    TransportationInsurance = (Purchase * 0.015);
                }
                else if (sale / USD >= 20000 && sale / USD < 50000) {
                    TransportationInsurance = (Purchase * 0.012);
                }
                else if (sale / USD >= 50000) {
                    TransportationInsurance = (Purchase * 0.01);
                }
            }
            return TransportationInsurance;
        }
        //通过填写国际运保费率，计算国际运保费，如果国际运保费低于500美元，则按500美元算，如果超过500美元，则按照（500＋超出价格）进行计算。
        //国际运保费（人民币），国际运保费（采购币种）  ----计算错误,已取消
        function IFGuoJiYunBaoFei(guojiyunbaofei2, GJYF) {
            var USD = agent.Eles[document.getElementById("XTextBox95").getAttribute("xform_xele_index")].getValue();
            if (GJYF == "") {
                if (guojiyunbaofei2 / USD <= (500) && guojiyunbaofei2 > 0) {
                    return 500 * USD;
                }
                else {
                    return guojiyunbaofei2;
                }
            }
            else {
                return guojiyunbaofei2;
            }
        }
        //如果是4000或2000公司，含税销售价格和不含税销售相等，反之计算不含税销售价格
        //BillingCompany-开票公司, PDSellingTotalvalueRest-含税销售总价, shuilv-税率
        function IFBillingCompany(BillingCompany, PDSellingTotalvalueRest, shuilv) {
            if (BillingCompany == "2000上海颐合" || BillingCompany == "A300HOSIC 香港") {
                return PDSellingTotalvalueRest;
            }
            return PDSellingTotalvalueRest / (shuilv + 1);
        }
        //如果是4000或2000公司，税额等于0，反之计算税额
        //BillingCompany - 开票公司, SUMNPDSellingTotalvalueRMB - 合计不含税销售总价, shuilv - 税率
        function IFTaxLimit(BillingCompany, SUMNPDSellingTotalvalueRMB, shuilv) {
            if (BillingCompany == "2000上海颐合" || BillingCompany == "A300HOSIC 香港") {
                return 0;
            }
            return SUMNPDSellingTotalvalueRMB * shuilv;
        }
        //如果是4000或2000公司，含税采购价格和不含税采购相等，反之计算不含税采购价格
        //BillingCompany-开票公司, PDPurchaseTotalvalueRest-含税采购总价, shuilv-税率
        function IFPDPurchaseTotalvalueRest(BillingCompany, PDPurchaseTotalvalueRest, shuilv) {
            if (BillingCompany == "2000上海颐合" || BillingCompany == "A300HOSIC 香港") {
                return PDPurchaseTotalvalueRest;
            }
            return PDPurchaseTotalvalueRest / (shuilv + 1);
        }
        //计算行项目国际运保费
        //GJYF-国际运保费（采购币种）, CGRate-采购汇率, NPDPurchaseTotalvalueRMB-不含税采购总价（人民币）, InternationCIF-国际运保费率
        function CountGUOJIYUNFEI(GJYF, CGRate, NPDPurchaseTotalvalueRMB, InternationCIF) {
            var GJYFR = 0;
            GJYFR = GJYF * CGRate;
            if (GJYFR != 0) {
                return GJYFR;
            }
            else {
                GJYFR = NPDPurchaseTotalvalueRMB * InternationCIF;
            }
            return GJYFR;
        }
        //计算整单国际运保费
        function GetInfoFromTable1(SourcingPurchasing, InternationCIF) {
            var USD = agent.Eles[document.getElementById("XTextBox95").getAttribute("xform_xele_index")].getValue();
            var num = 0;
            var vNum = 0.00;
            var tableInfo1 = new Array();
            var tableInfo2 = new Array();
            var tableInfo3 = new Array();
            var NewArr = new Array();
            var tableRow = "";
            var tableObj = document.getElementById('tablenew');
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                //获取供应商名称
                tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[35].children[0].getAttribute("xform_xele_index")].getValue();
                //获取国际运保费（人民币）
                tableInfo2[i - 2] = agent.Eles[tableObj.rows[i].cells[29].children[0].getAttribute("xform_xele_index")].getValue();
                //获取国际运保费（采购币种）
                tableInfo3[i - 2] = agent.Eles[tableObj.rows[i].cells[28].children[0].getAttribute("xform_xele_index")].getValue();
            }

            for (var i = 0; i < tableInfo1.length ; i++) {
                for (var j = i + 1; j < tableInfo1.length; j++) {
                    //比较供应商是否为同一个供应商
                    if (tableInfo1[i] === tableInfo1[j] && tableInfo1[i] !== "") {
                        if (j != 1 || tableInfo2[j] != 0) {
                            tableInfo2[i] = Number(tableInfo2[i]) + Number(tableInfo2[j]);
                            tableInfo2[j] = 0;
                        }
                    }
                }
                if (tableInfo3[i] != 0) {
                    NewArr[i] = 1;      //记录行项目是否填写国际运保费
                }
                else
                    NewArr[i] = 0;
            }

            //与$500比较，若单个供应商国际运保费<$500，则按照$500计算
            for (var i = 0; i < tableInfo2.length; i++) {
                if (NewArr[i] != 1) {
                    if (tableInfo2[i] != 0 && tableInfo2[i] / USD < 500) {
                        tableInfo2[i] = 500 * USD;
                    }
                }
            }

            for (var i = 0; i < tableInfo2.length; i++) {
                num = Number(tableInfo2[i]);
                vNum = vNum + num;
                //tableObj.rows[i + 2].cells[27].children[0].children[0].value = tableInfo2[i];
            }
            //document.getElementById('XTextBox67').value = vNum;
            return vNum;
        }

    </script>
    <%--获取当前月份（暂时不用）--%>
    <script type="text/javascript">
        function GetDateTimeMothe(DateTime) {
            DateTime = DateTime.replace(/-/g, "/");
            var date = new Date(DateTime);
            var month = date.getMonth() + 1;
            return month;
        }
        //获取采购关税税率
        //合同币种，产品型号，产品BPMID，采购币种，行号
        function GetPurchasingTariff(SalesCurrency, productnumber, productBPMID, Currency, RowNumber) {
            var Tariff = 0;
            if (SalesCurrency == "CNY") {
                if (productnumber != "" && Currency != "CNY" && Currency != "") {
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        params: {
                            method: 'GetPurchaseTariffRate',
                            productBPMID: productBPMID
                        },
                        success: function (action) {
                            var tableObj = document.getElementById('tablenew');
                            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                                if (agent.Eles[tableObj.rows[i].cells[0].children[0].getAttribute("xform_xele_index")].getValue() == RowNumber) {
                                    var tb = agent.Eles[tableObj.rows[i].cells[31].children[0].getAttribute("xform_xele_index")];
                                    var tbIncrease = agent.Eles[tableObj.rows[i].cells[47].children[0].getAttribute("xform_xele_index")];   //加征关税%
                                    var result = action.result;
                                    var data = action.result.Value;
                                    if (data != null && data != "" && data != undefined) {
                                        tb.setValue(data[0][0]);
                                        tbIncrease.setValue(data[0][1]);
                                    }
                                    XFormOnChange(tb);
                                    XFormOnChange(tbIncrease);
                                }
                            }
                        }
                    });
                }
            }

        }
    </script>

    <%--交易属性字符串拼接--%>

    <script type="text/javascript">
        /*
        //判断APP1是否选择为‘其他’，如果选择是其他，将APP1和APP3拼接在一起，
        //如果不是就将APP1和APP2拼接在一起
        function Apply(APP1, APP2, APP3) {
            var str = "";
            if (APP1 != "其他") {
                str = APP1 + "," + APP2;
            }
            else {
                str = APP1 + "," + APP3;
            }
            return str;
        }*/
    </script>



    <%--SIP业务基金扣款(销售币种)--%>
    <script type="text/javascript">
        //SIP业务基金扣款(销售币种)
        function SIPdeduct(yewufenlei, HSXSZJ) {
            var str = "";
            var tableInfo1 = new Array();
            var tableRow = "";
            var tableObj = document.getElementById('tablenew');
            for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                //var obj = tableObj.rows[i].cells[1].children[0];

                //var index = obj.selectedIndex;
                // tableInfo1[i - 2] = tableObj.rows[i].cells[1].children[index].innerText;
                tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[1].children[0].getAttribute("xform_xele_index")].getValue();
            }
            for (var i = 0; i < tableInfo1.length; i++) {
                if (tableInfo1[i] == "集成销售" || tableInfo1[i] == "集成服务") {
                    str = HSXSZJ * 0.03;
                }
            }
            return str;

        }
    </script>
    <%--获取超期应收账款和应收账款/红旗客户的赋值/是否免税字段赋值/计划行类别赋值---%>
    <script type="text/javascript">
        //获取售达方的超期应收账款和应收账款
        function GetInfo() {
            var kehuID = agent.Eles[document.getElementById("XTextBox49").getAttribute("xform_xele_index")].getValue();
            if (kehuID != "") {
                YZSoft.Ajax.request({
                    url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                    method: 'POST',
                    params: {
                        method: 'GetDMBTRData',
                        KEHUID: kehuID,
                        days: 30
                    },
                    success: function (action) {
                        var result = action.result;
                        var data = action.result.Value;
                        agent.Eles[document.getElementById("XTextBox23").getAttribute("xform_xele_index")].setValue(data.I_DMBTR_C);
                        agent.Eles[document.getElementById("XTextBox54").getAttribute("xform_xele_index")].setValue(data.I_DMBTR_Y);
                    },
                    failure: function (action) {
                        alert(action.result.Message);
                    }
                });
            }
            else {
                alert("请填写售达方客户SAPID！");
            }
        }
        //获取付款方的超期应收账款和应收账款
        function GetInfo2() {
            var kehuID = agent.Eles[document.getElementById("XTextBox57").getAttribute("xform_xele_index")].getValue();
            if (kehuID != "") {
                YZSoft.Ajax.request({
                    url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                    method: 'POST',
                    params: {
                        method: 'GetDMBTRData',
                        KEHUID: kehuID,
                        days: 30
                    },
                    success: function (action) {
                        var result = action.result;
                        var data = action.result.Value;
                        agent.Eles[document.getElementById("XTextBox1").getAttribute("xform_xele_index")].setValue(data.I_DMBTR_C);
                        agent.Eles[document.getElementById("XTextBox62").getAttribute("xform_xele_index")].setValue(data.I_DMBTR_Y);
                        agent.Eles[document.getElementById("Overdue30").getAttribute("xform_xele_index")].setValue(data.I_DAY_C);
                        agent.Eles[document.getElementById("XTextBox184").getAttribute("xform_xele_index")].setValue(data.E_SAUFT);
                        agent.Eles[document.getElementById("XTextBox185").getAttribute("xform_xele_index")].setValue(data.E_KLIMK);
                    },
                    failure: function (action) {
                        alert(action.result.Message);
                    }
                });

                //是不是白名单
                var urlbm = YZSoft.$url('Oimec/WorkFlow/Services/MasterDataHandler.ashx');
                var CustomerName = agent.Eles[document.getElementById("XTextBox56").getAttribute("xform_xele_index")].getValue();//付款方客户
                //CustomerName = "东45555方";
                var parmbm = { method: "GetCustomerWhiteList", CustomerName: CustomerName };
                var Identification = "";

                YZSoft.Ajax.request({
                    url: urlbm,
                    async:false ,
                    params: parmbm,
                    success: function (action) {
                        
                        var data = action;
                        var obj = eval("(" + data.responseText + ")");
                        var len = obj.children.length;
                         
                        if (len > 0) {

                            Identification = obj.children[0].Identification;

                        }
                    },
                    failure: function (action) {
                        Identification = "";
                    }
                }); //是不是白名单结束
               
                if (Identification == "1") {//是白名单
                    agent.Eles[document.getElementById("Overdue15").getAttribute("xform_xele_index")].setValue("");
                } else {
                    
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        params: {
                            method: 'GetDMBTRData',
                            KEHUID: kehuID,
                            days: 15
                        },
                        success: function (action) {
                            var result = action.result;
                            var data = action.result.Value;
                           
                            agent.Eles[document.getElementById("Overdue15").getAttribute("xform_xele_index")].setValue(data.I_DAY_C);
                        },
                        failure: function (action) {
                            alert(action.result.Message);
                        }
                    });
                }//结束
               



            }
            else {
                alert("请填写付款方客户SAPID！");
            }

        }
        //根据物料类型返回不同的SAPID
        //wuliaoType-物料类型, SASapID-销售物料号, PROSapID-自营租赁物料号, OTHSaPID-其他服务物料号, SERSaPID-技术服务物料号
        function GetPROSAPID(wuliaoType, SASapID, PROSapID, OTHSaPID, SERSaPID) {
            if (wuliaoType == "销售物料") {
                return SASapID;
            }
            else if (wuliaoType == "自营租赁物料") {
                return PROSapID;
            }
            else if (wuliaoType == "其他服务物料") {
                return OTHSaPID;
            }
            else if (wuliaoType == "技术服务物料") {
                return SERSaPID;
            }
        }
        //售达方红旗客户
        function Flag1(Flag1) {
            var radio3_0 = document.getElementById("XRadioButtonList3_0");
            var radio3_1 = document.getElementById("XRadioButtonList3_1");
            if (Flag1 == "是") {
                radio3_0.checked = true;
            }
            else if (Flag1 == "否") {
                radio3_1.checked = true;
            }
        }
        //付款方红旗客户
        function Flag2(Flag2) {
            var radio4_0 = document.getElementById("XRadioButtonList4_0");
            var radio4_1 = document.getElementById("XRadioButtonList4_1");
            if (Flag2 == "是") {
                radio4_0.checked = true;
            }
            else if (Flag2 == "否") {
                radio4_1.checked = true;
            }
        }
        //根据开票公司判读是否免税，Exemption-开票公司
        function ISExemption(Exemption) {

            var radio2_0 = document.getElementById("XRadioButtonList2_0"); // 是否免税 是
          
            //是否免税“否”
            var radio2_1 = document.getElementById("XRadioButtonList2_1"); //是否免税 否
            if (radio2_0.checked == true || radio2_1.checked == true) //是否免税已存在值则不进行下面规则 Add Date:2020-04-24
            { }
            else
            {
                if (Exemption == "1000东方中科北京" || Exemption == "1010东方中科上海" || Exemption == "1020东方中科深圳" || Exemption == "2100苏州博德") {
                    radio2_1.checked = true;
                }
                else {
                    radio2_1.checked = false;
                }
            }
        }

        //根据采购模式和采购数量，判读计划行类别BP或BN
        //PlanSort-采购数量, CaiGouMoShi-采购模式
        function ISPlanSort(PlanSort, CaiGouMoShi) {
            //var radio2_0 = document.getElementById("XRadioButtonList2_0");
            //var radio2_1 = document.getElementById("XRadioButtonList2_1");
            var sort = "BN";

            if (CaiGouMoShi == "备货") {
                sort = "BP";
            }
            return sort;
        }

         
    </script>
    <script type="text/javascript">
        //表单加载的时候进行数据及业务逻辑处理
        Ext.onReady(function () {
		Getplaceholder();
            //获取formstate值
            var formstate = getQueryString("formstate");
            this.setXValue("formstate", formstate);
            GetMenuByManufacturerID("");

            //隐藏：费用明细、毛利计算公式
            document.getElementById("div_fymx").style.display = "none";//隐藏
            document.getElementById("div_mljs").style.display = "none";//隐藏
            //document.getElementById("div_xdyq").style.display = "none";//隐藏  厂商下单要求DIV


            //即时更新采购信息  获取采购处理申请单号、采购员姓名

            var formNo = document.getElementById("XLabel3").innerText;      //预审单号
            //tablenew
            var tableObj = document.getElementById("tablenew");
            for (var i = 2; i < tableObj.rows.length - 1; i++) {//遍历Table的所有Row //遍历Row中的每一列
                var model = agent.Eles[tableObj.rows[i].cells[3].children[0].getAttribute("xform_xele_index")].getValue();//获取对应行 产品型号
                if (model != '') {
                    GetPurchaser(formNo, model, i);
                }
            }

            function GetPurchaser(formNo, prdtModel, row) {
                //alert("formNo=="+formNo+"prdtModel=="+prdtModel);
                //alert("采购信息：预审单号：" + formNo + "，型号：" + prdtModel);
                if (formNo != '' && prdtModel != '') {
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        params: {
                            method: 'GetPurchaser',
                            inquiryFormNo: formNo,
                            prdtModel: prdtModel
                        },
                        success: function (action) {
                            var result = action.result;
                            var data = action.result.Value;
                            if (data != null && data != "" && data != undefined) {
                                var i = row;
                                var table = document.getElementById("tablenew");
                                var taskId = data[0][0];
                                var displayName = data[0][1];
                                if (taskId != '') {
                                    agent.Eles[table.rows[i].cells[46].children[2].getAttribute("xform_xele_index")].setValue(taskId);
                                    XFormOnChange(agent.Eles[table.rows[i].cells[46].children[2].getAttribute("xform_xele_index")]);
                                }
                                if (displayName != '') {
                                    agent.Eles[table.rows[i].cells[46].children[0].getAttribute("xform_xele_index")].setValue(displayName);
                                }
                            }
                        },
                        failure: function (action) {
                            //alert(action.result.Message);
                        }
                    });
                }
            }

            //产品型号触发事件（已取消）
            var MaterialObject = GetMaterialTable2('tablenew');
            //获取产品的BPMID
            var Material = GetMaterialTable('tablenew');
            //获取物料类型
            var Material1 = GetMaterialTable1('tablenew');
            //产品BPMID数组
            var s1 = Material.join(',');
            //物料类型数组
            var s2 = Material1.join(',');

            //BPM表单号
            var BPMformNo = agent.Eles[document.getElementById("XLabel3").getAttribute("xform_xele_index")].getValue();    //XLabel3
            ////var STPObject = Ext.getDom("XTextBox123");
            var STPObject = agent.Eles[document.getElementById("XTextBox123").getAttribute("xform_xele_index")].getValue();
            //售达方客户SAPID
            var STPSAPID = agent.Eles[document.getElementById("XTextBox123").getAttribute("xform_xele_index")].getValue();
            //付款方客户SAPID
            var PTPSAPID = agent.Eles[document.getElementById("XTextBox125").getAttribute("xform_xele_index")].getValue();
            //当前预审流程状态
            var ZhuangTai = agent.Eles[document.getElementById("XTextBox145").getAttribute("xform_xele_index")].getValue();
            if (ZhuangTai == "业务员发起申请") {
                //分销渠道
                var ChannelOfDistribution = agent.Eles[document.getElementById("XDropDownList12").getAttribute("xform_xele_index")].getValue();
                if (ChannelOfDistribution == '')
                    agent.Eles[document.getElementById("XDropDownList12").getAttribute("xform_xele_index")].setValue("30");
                //XFormOnChange(agent.Eles[document.getElementById("XTextBox187").getAttribute("xform_xele_index")]);

                //合同信息默认值
                ContractInfoDefaultValue();

            }
            //当预审流程状态是“董事会秘书审批”时，打开表单时提示
            if (ZhuangTai == "董事会秘书审批") {
                Ext.MessageBox.alert("审批提示：", "此单含税销售总价CNY≥1000万元，所以需要审批。");
            }

            //当前预审流程状态是“地区助理复核”或“业务员再次发起申请”时，打开表单时提示。
            if (ZhuangTai == "地区助理复核" || ZhuangTai == "业务员再次发起申请") {
                //SAP报价单报错信息
                var EXMessage = agent.Eles[document.getElementById("XTextBox129").getAttribute("xform_xele_index")].getValue();
                var EXcode = agent.Eles[document.getElementById("XTextBox146").getAttribute("xform_xele_index")].getValue();
                var CEXcode = agent.Eles[document.getElementById("XTextBox164").getAttribute("xform_xele_index")].getValue();
                var CEXMessage = agent.Eles[document.getElementById("XTextBox138").getAttribute("xform_xele_index")].getValue();

                if (EXcode == 1) {
                    alert("生成SAP报价单错误，错误信息: " + EXMessage);
                }
                else if (EXcode == 2) {
                    alert("报价单号不存在！");
                }
                else if (EXcode == 3) {
                    alert("SAP系统已根据原有报价单生成SO，BPM系统无法自动删除此报价单并创建新报价单，请注意：将手工将SAP数据修正并退回到业务员撤销此预审单，谢谢！");
                }
                if (CEXcode == 1) {
                    alert("联系人信息有误！错误信息：" + CEXMessage + "请重新填写！");
                }
            }


            //地区经理审批，若销售机会未从crm导入，进行提示
            //产品线对象
            var ProductLineObject = document.getElementById("XDropDownList22");
            //产品线选中的值
            ////var ProductLine = ProductLineObject.options[ProductLineObject.selectedIndex].value;
            var ProductLine = agent.Eles[document.getElementById("XDropDownList22").getAttribute("xform_xele_index")].getValue();
            if (ZhuangTai == "地区经理审批") {
                if (ProductLine == "02") {
                    Ext.MessageBox.alert("审批提示：", "此单为不满足下面条件之一的易捷预审单 或：此单为 非易捷预审单，都需地区经理审批：</br>1）C/Q类客户付款方客户建议授权条件: 合同额<=5万，且毛利率>3%，且付款条件为“全款预付，无收验”或“COD/带款提货，无收验”；</br> 2）P类付款方客户建议授权条件：合同额<=5万，且毛利率>3%，且付款条件为“全款预付，无收验”或“COD/带款提货，无收验”或“货到30天付款T/T，加收、验5天”或“月结30天付款T/T，加收货、验收30天”");
                }
                if (ProductLine == "01") {
                    Ext.MessageBox.alert("审批提示：", "此单为不满足下面条件之一的易捷预审单 或：此单为 非易捷预审单，都需地区经理审批：</br>1）C/Q类客户付款方客户建议授权条件：合同额<=5万，且毛利率>3%，且付款条件为“全款预付，无收验”或“COD/带款提货，无收验”；</br> 2）P类付款方客户建议授权条件：合同额<=5万，且毛利率>3%，且付款条件为“全款预付，无收验”或“COD/带款提货，无收验”或“货到30天付款T/T，加收、验5天”或“月结30天付款T/T，加收货、验收30天");
                }

                if (XChecked("XCheckBox2") != true) {
                    if (XChecked("XCheckBox4") == true) {
                        if (GetXValue("XTextBox171") == '') {

                            if (ProductLine != "03" && ProductLine != '05') {
                                // alert("此单销售机会不是来源于CRM！");
                                Ext.MessageBox.alert("", "此单销售机会不是来源于CRM！")
                            }
                        }
                    }
                }
            }
            //当前预审流程状态时“CSO审批”时，打开表单时的提示和高亮显示
            if (ZhuangTai == "CSO审批") {
                //毛利率
                document.getElementById("XTextBox58").style.backgroundColor = "red";
                //含税销售总价人民币
                document.getElementById("XTextBox68").style.backgroundcolor = "red";
                //合同总金额
                document.getElementById("XTextBox72").style.backgroundColor = "red";
                //质保金
                document.getElementById("XTextBox2").style.backgroundColor = "red";

                var ZhuangTaiString = "";
                var tableObj = document.getElementById('tablenew');
                for (var i = 2; i < tableObj.rows.length - 1; i++) {
                    ////if (tableObj.rows[i].cells[5].children[0].children[0].value == "6109082") {
                    if (agent.Eles[tableObj.rows[i].cells[5].children[0].getAttribute("xform_xele_index")].getValue() == "6109082") {
                        ZhuangTaiString = "此单存在标准件";
                    }
                }
                if (ZhuangTaiString != '') {
                    alert(ZhuangTaiString);
                }
                else {
                    if (ProductLine == "02") {
                        Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 毛利率＜3%</br>2) 毛利率≥3%且含税销售总价CNY≥50万</br>3) 毛利率≥3%且有标准件</br>4) 毛利率≥3%且有质保金");
                    }
                    else {
                        Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 毛利率＜3%</br>2) 毛利率≥3%且含税销售总价CNY≥50万</br>3) 毛利率≥3%且有标准件</br>4) 毛利率≥3%且有质保金");
                    }
                }
            }
                //当前预审流程状态为“BU总经理审批1”或 为"BU经理审批"时，打开表单时的提示和高亮显示
            else if (ZhuangTai == "BU总经理审批1" || ZhuangTai == "BU经理审批") {
                //毛利率
                document.getElementById("XTextBox58").style.backgroundColor = "red";
                //含税销售总价人民币
                document.getElementById("XTextBox68").style.backgroundcolor = "red";
                //合同总金额
                document.getElementById("XTextBox72").style.backgroundColor = "red";
                var ZhuangTaiString = "";
                var tableObj = document.getElementById('tablenew');
                for (var i = 2; i < tableObj.rows.length - 1; i++) {
                    ////if (tableObj.rows[i].cells[9].children[0].children[0].value == "0") {
                    if (agent.Eles[tableObj.rows[i].cells[9].children[0].getAttribute("xform_xele_index")].getValue() == "0") {
                        ZhuangTaiString = "此单为零金额销售";
                    }
                }
                if (ZhuangTaiString != '') {
                    alert(ZhuangTaiString);
                }
                else {
                    Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 含税销售总价CNY≥100万或毛利率＜0</br>2) 有零金额销售</br>3) 有重点复核");
                }
            }

                //常务副总裁审批(预审流程状态节点处理人为常务副总裁)时，打开表单时提示
            else if (ZhuangTai == "总裁审批" || ZhuangTai == "联想客户审批" || ZhuangTai == "总裁审批1" || ZhuangTai == "总裁审批2") {
                if (ProductLine == '02') {
                    Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 含税销售总价CNY≥200万</br>2) 质保金金额大于毛利的50%（含）且账期超过6个月</br>3) 有重点复核</br>4) 售达方或付款方是联想客户 ");
                }
                if (ProductLine == '01') {
                    Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 含税销售总价CNY≥200万</br>2) 质保金金额大于毛利的50%（含）且账期超过6个月</br>3) 有重点复核 ");
                }
                //NEBU
                if (ProductLine == '06') {
                    Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 含税销售总价CNY≥200万</br>2) 质保金金额大于毛利的50%（含）且账期超过6个月</br>3) 有重点复核 ");
                }
            }
                //当前预审流程状态时“总裁审批”时，打开表单时的提示和高亮显示
            else if (ZhuangTai == "总裁审批3") {
                //毛利率
                document.getElementById("XTextBox58").style.backgroundColor = "red";
                //含税销售总价人民币
                document.getElementById("XTextBox68").style.backgroundcolor = "red";
                //合同总金额
                document.getElementById("XTextBox72").style.backgroundColor = "red";
                //质保金
                document.getElementById("XTextBox2").style.backgroundColor = "red";
                //账期
                document.getElementById("XTextBox65").style.backgroundColor = "red";

                Ext.MessageBox.alert("审批提示", "含有供应商直发产品 且 采购总价CNY≥50万");
                //if (ProductLine != '13') {
                //    Ext.MessageBox.alert("审批提示：", "此单满足下面条件，所以需要审批：</br>含税销售总价CNY≤100万，且付款方客户为关联方");
                //}
                //else {
                //    Ext.MessageBox.alert("审批提示：", "此单满足下面条件之一，所以需要审批：</br>1) 含税销售总价CNY≥200万</br>2) 质保金金额大于毛利的50%（含）且账期超过6个月</br>3) 含税销售总价≤100万，且付款方客户为关联方");
                //}
            }

            else if (ZhuangTai == "CFO审批") {
                Ext.MessageBox.alert("审批提示：", "此单满足下面条件，所以需要审批：</br>付款方是关联客户");
                //alert("付款方是关联客户");

            }
            else if (ZhuangTai == "财务部经理审批") {
                Ext.MessageBox.alert("审批提示：", "开票公司是颐合，且（行项目的含税采购总价（人民币）≤1000元 且 采购模式为备货）");
                //alert("付款方是关联客户");

            }
            else if (ZhuangTai == "EMD产品负责人审批" || ZhuangTai == "EMD产品管理负责人审批") {
                Ext.MessageBox.alert("审批提示：", "行项目产品有SAP库存，但需单独采购");

            }

            else if (ZhuangTai == "财务信控岗审批") {
                if (BPMformNo.substring(0, 4) == "HWYS") {
                    Ext.MessageBox.alert("审批提示", "满足下面条件之一时需审批：</br>1)付款方客户的应收账款有超期30天以上的（后台是按超期天数>30天取数）且 付款条件非（30天付款(电子商务) 或 全款预付无验收 或 COD/带款提货无验收 或 送货取支票/现金 或 100%信用证(L/C)100%见单议付）</br>2)BPM预审时，从SAP实时获取付款方客户（除C/Q类客户外，即：A/B/P类客户）当前可用额度，如可用额度小于0，需信控岗审批（可用额度=信贷额度-信贷风险总额）");
                }
                else {
                    Ext.MessageBox.alert("审批提示", "满足下面条件之一时需审批：</br>1)渠道非电子商务 且 付款方B、P类客户 且（付款条件账期大于90天 or 可用额度小于0）</br>2)渠道非电子商务 且 付款方A类客户 且（付款条件账期大于120天 or 可用额度小于0）</br>3)渠道电子商务 且 付款条件非（30天付款(电子商务) 或 全款预付无验收 或 COD/带款提货无验收 或 送货取支票/现金 或 100%信用证(L/C)100%见单议付）</br>4)合同金额(含税)大于人民币50万元</br>5)付款方客户是A、B、P类客户 且 付款条件非（30天付款(电子商务) or 全款预付无验收 or COD/带款提货无验收 or 送货取支票/现金 or 100%信用证(L/C)100%见单议付）且 应收账款超期天数＞30天</br>6)付款方客户是C、Q类客户 且 付款条件非（全款预付无验收 或 COD/带款提货无验收 或 送货取支票/现金 或 100%信用证(L/C)100%见单议付）且 应收账款超期天数≥30天</br>7)付款条件是承兑汇票（3个月）或 承兑汇票（6个月）或 承兑汇票（9个月）或 承兑汇票（12个月）");
                }
            }
                //当前预审流程状态时“SIP负责人审批”时，打开表单时的提示和高亮显示
            else if (ZhuangTai == "SIP负责人审批") {
                var ZhuangTaiString = "";
                var tableObj = document.getElementById('tablenew');
                for (var i = 2; i < tableObj.rows.length - 1; i++) {
                    //if (tableObj.rows[i].cells[1].children[0].value == "集成销售" || tableObj.rows[i].cells[1].children[0].value == "集成服务") {
                    var avalue = agent.Eles[tableObj.rows[i].cells[1].children[0].getAttribute("xform_xele_index")].getValue()
                    if (avalue == "集成销售" || avalue == "集成服务") {
                        ZhuangTaiString = "此单有SIP业务";
                    }
                }
                if (ZhuangTaiString != '') {
                    //alert(ZhuangTaiString);
                    Ext.MessageBox.alert("审批提示", ZhuangTaiString);
                }
            }
            else if (ZhuangTai == "技术服务中心经理审批") {
                //alert("此单业务分类为“技术服务中心”");
                Ext.MessageBox.alert("审批提示", "此单有技术服务业务");

            }
            else if (ZhuangTai == "EM TEST产品负责人审批") {
                //alert("此单产品的厂商有“EM TEST”");
                Ext.MessageBox.alert("审批提示", "此单产品的厂商有“EM TEST”");
            }
            else if (ZhuangTai == "NF、菊水产品负责人审批") {
                //alert("此单产品的厂商有“NF”或“菊水”");
                Ext.MessageBox.alert("审批提示", "此单产品的厂商有“NF”或“菊水”");
            }
            else if (ZhuangTai == "高砂产品负责人审批") {
                //alert("此单产品的厂商有“高砂”");
                Ext.MessageBox.alert("审批提示", "此单产品的厂商有“高砂”");
            }
                //ESPEC产品负责人审批
            else if (ZhuangTai == "ESPEC产品负责人审批") {
                //alert("此单产品的厂商有“ESPEC”");
                Ext.MessageBox.alert("审批提示", "此单产品的厂商有“ESPEC”");
            }
                //特测产品负责人审批
            else if (ZhuangTai == "特测产品负责人审批") {
                //alert("此单产品的厂商有“特测”");
                Ext.MessageBox.alert("审批提示", "此单产品的厂商有“特测”");
            }
            else if (ZhuangTai == "人民币采购组长审批") {
                Ext.MessageBox.alert("审批提示", "含有供应商直发产品 且 采购币种为CNY");
            }

            //任何状态打开表单时，都提示重点复核，红旗客户
            ////var chenckBox = document.getElementById("XCheckBox1");
            ////if (chenckBox.checked) {
            if (XChecked("XCheckBox1") == true) {
                alert("请注意，此单需重点复核！");
            }
            var radio3_0 = document.getElementById("XRadioButtonList3_0");
            var radio4_0 = document.getElementById("XRadioButtonList4_0");
            if (radio3_0.checked) {
               // alert("售达方客户是红旗客户！");
            }
             if (radio4_0.checked) {
                alert("付款方客户是实体清单客户！");
            }

            /*
           汇率变动提示
           1、预审单中的销售合同币种与采购合同币种不同
           2、行项目上的采购币种只要有一行不是USD（非人民币），且整单毛利率＜15%
           */

            var grossMargin = agent.Eles[document.getElementById("XTextBox58").getAttribute("xform_xele_index")].getValue();  //毛利率
            ////var ddl = document.getElementById("XDropDownList17");   //销售币种
            ////var SalesCurrency = ddl.options[ddl.selectedIndex].value;
            var SalesCurrency = agent.Eles[document.getElementById("XDropDownList17").getAttribute("xform_xele_index")].getValue(); //销售币种
            var Currency = new Array(); //行项目采购币种
            if (SalesCurrency != '') {
                for (var i = 2; i < document.getElementById('tablenew').rows.length - 1; i++) {
                    ////Currency[i - 2] = document.getElementById('tablenew').rows[i].cells[19].children[0].value;
                    Currency[i - 2] = agent.Eles[document.getElementById('tablenew').rows[i].cells[19].children[0].getAttribute("xform_xele_index")].getValue();
                }
                var flag = 0;
                for (var i = 0; i < Currency.length; i++) {
                    //alert(Currency[i]);
                    if (Currency[i] != '') {
                        if (Currency[i] != SalesCurrency) {
                            flag = 1;
                        }
                        else if (Currency[i] != "USD" && Currency[i] != "CNY" && grossMargin < 15) {
                            flag = 1;
                        }
                    }
                }

                if (flag == 1) {
                    // Ext.MessageBox.alert("", "请注意汇率波动，此单特别注意！");
                    alert("请注意汇率波动，此单特别注意！");
                }
            }

            if (ZhuangTai == "业务员发起申请" || ZhuangTai == "EMD产品负责人审批" || ZhuangTai == "地区助理复核" || ZhuangTai == "业务员确认并生成合同") {
                //表单打开时，进行数据加载，并赋值
                if (STPSAPID != "" && s1 != "" && s2 != "") {
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        //售达方客户SAPID，付款方客户SAPID，物料号，物料类型
                        params: {
                            method: 'OnLoadSAPID',
                            STPSAPID: STPSAPID,
                            PTPSAPID: PTPSAPID,
                            MaterialNum: s1,
                            MaterialType: s2
                        },
                        success: function (action) {
                            var result = action.result;
                            var data = action.result.Value;
                            //售达方客户数据赋值到表单中

                            var SsapTable = data.Ssap;
                            var Scount = data.StotalRows;
                            if (Scount > 0) {
                                //售达方客户SAPID
                                agent.Eles[document.getElementById("XTextBox49").getAttribute("xform_xele_index")].setValue(SsapTable[0].CustomerSAPID);
                                //售达方客户等级
                                agent.Eles[document.getElementById("XTextBox55").getAttribute("xform_xele_index")].setValue(SsapTable[0].CusLeavel);
                                //售达方客户红旗客户
                                agent.Eles[document.getElementById("XTextBox105").getAttribute("xform_xele_index")].setValue(SsapTable[0].IsFlag);
                                var radio3_0 = document.getElementById("XRadioButtonList3_0");
                                var radio3_1 = document.getElementById("XRadioButtonList3_1");
                                if (SsapTable[0].IsFlag == "是") {
                                    radio3_0.checked = true;
                                }
                                else if (SsapTable[0].IsFlag == "否") {
                                    radio3_1.checked = true;
                                }
                            }
                            //付款方客户数据赋值到表单中
                            var PsapTable = data.Psap;
                            var Pcount = data.PtotalRows;
                            if (Pcount > 0) {
                                //付款方客户SAPID
                                agent.Eles[document.getElementById("XTextBox57").getAttribute("xform_xele_index")].setValue(PsapTable[0].CustomerSAPID);
                                //付款方客户等级
                                agent.Eles[document.getElementById("XTextBox63").getAttribute("xform_xele_index")].setValue(SsapTable[0].CusLeavel);
                                //付款方客户SAPID
                                agent.Eles[document.getElementById("XTextBox107").getAttribute("xform_xele_index")].setValue(PsapTable[0].IsFlag);
                                var radio4_0 = document.getElementById("XRadioButtonList4_0");
                                var radio4_1 = document.getElementById("XRadioButtonList4_1");
                                if (PsapTable[0].IsFlag == "是") {
                                    radio4_0.checked = true;
                                }
                                else if (PsapTable[0].IsFlag == "否") {
                                    radio4_1.checked = true;
                                }
                            }
                            //产品信息数据赋值到表单中
                            var MaterialCount = data.Rows;
                            if (MaterialCount > 0) {
                                var tableObj = document.getElementById('tablenew');
                                var rv = new Array();
                                for (var i = 0; i < MaterialCount; i++) {

                                    var item = data.MaterialSAP[i][0];
                                    //表单中物料号
                                    var s1 = agent.Eles[tableObj.rows[i + 2].cells[5].children[0].getAttribute("xform_xele_index")].getValue();
                                    //表单中厂商编号
                                    var s2 = agent.Eles[tableObj.rows[i + 2].cells[6].children[0].getAttribute("xform_xele_index")].getValue();
                                    //表单中产品名称
                                    var s3 = agent.Eles[tableObj.rows[i + 2].cells[4].children[0].getAttribute("xform_xele_index")].getValue();
                                    //表单中厂商名称
                                    var s4 = agent.Eles[tableObj.rows[i + 2].cells[7].children[0].getAttribute("xform_xele_index")].getValue();
                                    if (s1 == "" || s2 == "" || s3 == "" || s4 == "") {
                                        if (item != null) {
                                            if (MaterialCount > 0 && item.MaterialSAPID != null && item.PrdtName != "" && item.ManufacturerID != "" && item.Name != "") {
                                                //物料号
                                                agent.Eles[tableObj.rows[i + 2].cells[5].children[0].getAttribute("xform_xele_index")].setValue(item.MaterialSAPID);
                                                //产品名称
                                                agent.Eles[tableObj.rows[i + 2].cells[4].children[0].getAttribute("xform_xele_index")].setValue(item.PrdtName);
                                                //厂商编号
                                                agent.Eles[tableObj.rows[i + 2].cells[6].children[0].getAttribute("xform_xele_index")].setValue(item.ManufacturerID);
                                                //厂商名称
                                                agent.Eles[tableObj.rows[i + 2].cells[7].children[0].getAttribute("xform_xele_index")].setValue(item.Name);
                                            }
                                        }

                                    }
                                }
                            }

                        },
                        failure: function (action) {
                            alert(action.result.Message);
                        }
                    });
                }
            }


        });
        //window.onload = function getOs() {
        Ext.onReady(function () {

            var ie = !!window.ActiveXObject;
            if (ie) {

                document.getElementById('XTextBox49').attachEvent("onpropertychange", STPSAPIDCustomer);
                document.getElementById('XTextBox57').attachEvent("onpropertychange", PTPSAPIDCustomer);
                document.getElementById('PTPButton').style.display = "none";
                document.getElementById('STPButton').style.display = "none";
            }
            else {

                document.getElementById('XTextBox49').addEventListener("input", STPSAPIDCustomer, false);
                document.getElementById('XTextBox57').addEventListener("input", PTPSAPIDCustomer, false);
                //document.getElementById('XTextBox49').addEventListener("click", txChange, false);
            }

            getWhith();//页面首次进来是不是白名单

            //MEUR客户分类设置备注 placeholder
            var aDivMEURemarks = document.getElementsByClassName("MEURemarks");
            var aDivMEURemarksId = aDivMEURemarks[0].getElementsByTagName('textarea')[0].id;
            var v = document.getElementById(aDivMEURemarksId).setAttribute("placeholder", "若最终客户和报供应商最终客户名称不一致，需单独说明");
        });

        //售达方客户SAPID
        function STPSAPIDCustomer() {
            var STPSAPID1 = agent.Eles[document.getElementById("XTextBox49").getAttribute("xform_xele_index")].getValue();
            var STPName = agent.Eles[document.getElementById("XTextBox43").getAttribute("xform_xele_index")].getValue();
            //判断售达方和付款方的客户是否冻结
            if (STPSAPID1 != "") {
                //售达方客户信息
                YZSoft.Ajax.request({
                    url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                    method: 'POST',
                    params: {
                        method: 'IsCustomerFreeze',
                        ClientSAPID: STPSAPID1
                    },
                    success: function (action) {
                        var result = action.result;
                        var ISRights = action.result.Value;
                        SISRights = ISRights;
                        if (SISRights == '1') {
                            alert(STPName + "（SAPID：" + STPSAPID1 + "）" + "该售达方客户已在SAP中被冻结！请选择其他客户！");
                            agent.Eles[document.getElementById("XTextBox49").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox105").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox55").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox43").getAttribute("xform_xele_index")].setValue("");
                        }
                    },
                    failure: function (action) {
                        alert(action.result.Message);
                    }
                });

            }

        }

        //付款方客户SAPID
        function PTPSAPIDCustomer() {
            var PTPSAPID1 = agent.Eles[document.getElementById("XTextBox57").getAttribute("xform_xele_index")].getValue();
            var PTPName = agent.Eles[document.getElementById("XTextBox56").getAttribute("xform_xele_index")].getValue();

            if (PTPSAPID1 != "") {

                //付款方客户信息
                //ClientSAPID-付款方客户
                YZSoft.Ajax.request({
                    url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                    method: 'POST',
                    params: {
                        method: 'IsCustomerFreeze',
                        ClientSAPID: PTPSAPID1
                    },
                    success: function (action) {
                        var result = action.result;
                        var ISRights = action.result.Value;
                        PISRights = ISRights;
                        if (PISRights == '1') {
                            alert(PTPName + "（SAPID：" + PTPSAPID1 + "）" + "该付款方客户已在SAP中被冻结！请选择其他客户！");
                            agent.Eles[document.getElementById("XTextBox57").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox56").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox63").getAttribute("xform_xele_index")].setValue("");
                            agent.Eles[document.getElementById("XTextBox107").getAttribute("xform_xele_index")].setValue("");
                        }
                    },
                    failure: function (action) {
                        alert(action.result.Message);
                    }
                });

            }
        }


        //解决IE8以下getElementsByClassName兼容性问题
        function hasClass(node, className) {
            var cNames = node.className.split(/\s+/);//根据空格来分割node里的元素；
            for (var i = 0; i < cNames.length; i++) {
                if (cNames[i] == className) return true;
            }
            return false;
        }
        function getByClassName(className) {
            if (document.getElementsByClassName) {
                return document.getElementsByClassName(className); //FF下因为有此方法，所以可以直接获取到；
            }
            var nodes = document.getElementsByTagName("*");//获取页面里所有元素，因为他会匹配全页面元素，所以性能上有缺陷，但是可以约束他的搜索范围；
            var arr = [];//用来保存符合的className；
            for (var i = 0; i < nodes.length; i++) {
                if (hasClass(nodes[i], className)) arr.push(nodes[i]);
            }
            return arr;
        }


        //获取付款信息
        function getFKInfo(InvoiceType, PTPSapID, value) {
            //alert(PTPSapID);
            if (PTPSapID == "1036401")//一次性客户
            {
                if (InvoiceType == "6%增值税普通发票" || InvoiceType == "13%增值税普通发票") {
                    return null;
                }
            }
            return value;
        }

        //付款信息失效表达式
        function FKInfoDisable(InvoiceType, PTPSapID) {
            //alert(InvoiceType);
            if (PTPSapID == "1036401")//一次性客户
            {
                if (InvoiceType == "6%增值税普通发票" || InvoiceType == "13%增值税普通发票") {
                    return false;
                }
            }
            return true;
        }

        //表单提交时进行数据及业务逻辑处理
        agent.on('beforeSubmit', function (actname1, actname) {


            //付款方是实体清单客户，合同币种为外币，申请不能提交
            var radio4_0 = document.getElementById("XRadioButtonList4_0");
            var contractCurrency = agent.Eles[document.getElementById("XDropDownList17").getAttribute("xform_xele_index")].getValue();
            if (radio4_0.checked) {
                if (contractCurrency != '' && contractCurrency != 'CNY') {
                    alert("此单付款方是实体清单客户且为外币订单，不允许操作，请联系商务部经理！");
                    return false;
                }
            }

            //报供应商最终客户为实体清单客户时提示
            var tableObj = document.getElementById("tablenew");
            for (var i = 2; i < tableObj.rows.length - 1; i++) {//遍历Table的所有Row //遍历Row中的每一列
                var isFlage = agent.Eles[tableObj.rows[i].cells[43].children[2].getAttribute("xform_xele_index")].getValue();//获取对应行 红旗客户信息
                if (isFlage == "是") {
                    var line = i - 1;
                    alert("产品明细第[ " + line + " ]行 报供应商最终客户 为实体清单客户,不能提交！");
                    return false;
                }
            }


            //一次性客户控制:发票类型不允许开6%或13%增值税专用发票
            var PTPSapID = GetXValue('XTextBox57');
            if (PTPSapID == "1036401") {
                var salesInvoiceType = GetXValue('XDropDownList4');
                if (salesInvoiceType == "6%增值税专用发票" || salesInvoiceType == "13%增值税专用发票") {
                    Ext.MessageBox.alert("提示", "公司财务规定：一次性客户不能开具增值税专用发票，请申请SAP客户主数据。");
                    return false;
                }
            }

            //当前预审流程状态
            var ZhuangTai = agent.Eles[document.getElementById("XTextBox145").getAttribute("xform_xele_index")].getValue();
            var TaskID = agent.Eles[document.getElementById("XTextBox183").getAttribute("xform_xele_index")].getValue();

            //业务员发起申请，合同信息控制
            if ((ZhuangTai == "业务员发起申请" && actname == "提交") || (ZhuangTai == "业务员确认" && actname == "重新提交") || (ZhuangTai == "业务员确认1" && actname == "重新提交")) {
                //手机、电话控制
               
                //供应商直发控制
                var res = CheckSupplierSend();
                if (res == false) {
                    //Ext.MessageBox.alert("提示", "请选择供应商直发");
                    return false;
                }
                //return CheckSupplierSend();

                //采购模式
                var aDivPurchasingPattern = document.getElementsByName("PurchasingPattern");
                //是否有预付
                var aDivIsAdvancePay = document.getElementsByClassName("IsAdvancePay");

                //供应商货期
                var aDivSupplierDeliveryDate = document.getElementsByName("SupplierDeliveryDate");
                //供应商货期单位
                var aDivSupplierDeliveryDateUnit = document.getElementsByName("SupplierDeliveryDateUnit");

                //厂商编号

                var aDivManufacturerID = document.getElementsByName("ManufacturerID");
                var KeysightFlag = false;

                for (var i = 0; i < aDivPurchasingPattern.length; i++) {

                    //采购模式
                    var divPurchasingPattern = aDivPurchasingPattern[i];
                    var idPurchasingPattern = divPurchasingPattern.getElementsByTagName('select')[0].id;
                    var vPurchasingPattern = document.getElementById(idPurchasingPattern).value;
                    //是否有预付
                    var divIsAdvancePay = aDivIsAdvancePay[i];
                    // console.log(s);
                    var idIsAdvancePay = divIsAdvancePay.getElementsByTagName('input')[0].name;
                    var vIsAdvancePay = checkedVaule(idIsAdvancePay);

                    //供应商货期
                    var divSupplierDeliveryDate = aDivSupplierDeliveryDate[i];
                    var idSupplierDeliveryDate = divSupplierDeliveryDate.getElementsByTagName('input')[0].id;
                    var vSupplierDeliveryDate = document.getElementById(idSupplierDeliveryDate).value;
                    //供应商货期单位
                    var divSupplierDeliveryDateUnit = aDivSupplierDeliveryDateUnit[i];
                    var idSupplierDeliveryDateUnit = divSupplierDeliveryDateUnit.getElementsByTagName('select')[0].id;
                    var vSupplierDeliveryDateUnit = document.getElementById(idSupplierDeliveryDateUnit).value;

                    //厂商编号
                    var divManufacturerID = aDivManufacturerID[i];
                    var idManufacturerID = divManufacturerID.getElementsByTagName('input')[0].id;
                    var vManufacturerID = document.getElementById(idManufacturerID).value;

                    if (vManufacturerID == "103") {//厂商编号103  是德
                        var MEUR = agent.Eles[document.getElementById("MEUR").getAttribute("xform_xele_index")].getValue();//MEU/MEUR客户分类

                        if (MEUR == "") {

                            Ext.MessageBox.alert("提示", "MEU/MEUR客户分类下,请选择MEU/MEUR客户分类");

                            return false;
                        }

                        if (MEUR == "C类" || MEUR == "D类") {

                            var MEURAttachments = agent.Eles[document.getElementById("MEURAttachments").getAttribute("xform_xele_index")].getValue();//MEU/MEUR附件
                            if (MEURAttachments == "") {
                                Ext.MessageBox.alert("提示", "MEU/MEUR客户分类下,请上传MEU/MEUR的具有法律效力的书面证明");

                                return false;
                            }

                        }
                        if (MEUR == "A类" || MEUR == "B类" || MEUR == "C类") {

                            var MEURJudgingMaterials = agent.Eles[document.getElementById("MEURJudgingMaterials").getAttribute("xform_xele_index")].getValue();//MEU/MEUR附件
                            if (MEURJudgingMaterials == "") {
                                Ext.MessageBox.alert("提示", "MEU/MEUR客户分类下,请上传MEU/MEUR客户分类的判定材料");

                                return false;
                            }

                        }


                         KeysightFlag = true;
                    }


                    if (vPurchasingPattern == "原厂采购" || vPurchasingPattern == "非原厂采购") {
                        // if (vIsAdvancePay == "1") {
                        var ii = i + 1;
                        if (vSupplierDeliveryDate == "") {

                            Ext.MessageBox.alert("提示", "产品明细里,第【" + ii + "】行产品,请填写供应商货期");
                            return false;
                        }
                        if (!(/(^[0-9]\d*$)/.test(vSupplierDeliveryDate))) {  //当输入不是数字的时候，Number后返回的值是NaN;然后用isNaN判断。
                            Ext.MessageBox.alert("提示", "供应商货期只能输入正整数或0");
                            return false;
                        }
                         
                        if (vSupplierDeliveryDateUnit == "") {
                            Ext.MessageBox.alert("提示", "产品明细里,第【" + ii + "】行产品,请选择供应商货期单位");
                            return false;
                        }

                        //}


                    }

                }//结束
                 
               

                // 不能提交
                var XTextBox63 = getXValue("XTextBox63"); //付款方客户等级
                var Overdue15 = getXValue("Overdue15"); // //超期应收逾期15天 付款方
                if (XTextBox63 == "P" && Overdue15 == "0") {
                    Ext.MessageBox.alert('提示', '付款方客户有逾期天数＞15天的超期应收，不能提交！');
                    return false;
                }


                //销售合同模板
                var ContractType = checkedVaule("XRadioButtonList7");
                if (ContractType == "我司标准合同且标准条款" || ContractType == "我司标准合同且非标准条款") {
                    return CheckContractInfo();
                }

                if (KeysightFlag == false) {
                    agent.Eles[document.getElementById("MEUR").getAttribute("xform_xele_index")].setValue("");
                    agent.Eles[document.getElementById("MEURAttachments").getAttribute("xform_xele_index")].setValue("");
                    agent.Eles[document.getElementById("MEURJudgingMaterials").getAttribute("xform_xele_index")].setValue("");
                }

            }

            //return false;



            if (actname == "创建合同") {

                //判断  预付款是否审批已完成
                //IsNeedAdvanceApp() 判断是否需要预付款
                if (IsNeedAdvanceApp()) {
                    var vstate = 0;
                    var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');
                    var parm = { method: "GetIsdvancePayAppList", ProcessName: "采购-预付款申请流程", FkItemId: TaskID };
                    AjaxParm(url, false, parm, function (action) {
                        var data = action.result;
                        if (data.length > 0) { //发起过流程未结束
                            var nodeName = data[0].NodeName;
                            if (nodeName != "结束") {
                                alert("对应的采购预付流程未审批通过，不能提交！");
                                vstate = 0;
                            }
                            else { vstate = 1; }
                        }
                        else { //未发起过
                            alert("对应的采购预付流程未审批通过，不能提交！");
                            vstate = 0;
                        }

                    });
                    if (vstate == 0) return false;

                }

                //创建合同
                var code = GenerationContract();//创建正式合同
                if (code == 0) {
                    //Ext.MessageBox.alert('提示', '合同生成成功');
                }
                else {
                    Ext.MessageBox.alert('提示', '合同生成失败');
                    return false;
                }

            }

            //审批意见为“不同意”，中止其他审批节点   --tx51
            if (actname == "不同意") {
                var stepID = getQueryString("pid");   //当前节点步骤编号
                var taskID = agent.Eles[document.getElementById("XTextBox183").getAttribute("xform_xele_index")].getValue();
                var formNo = agent.Eles[document.getElementById("XLabel3").getAttribute("xform_xele_index")].getValue();    //XLabel3
                var appName = agent.Eles[document.getElementById("XTextBox40").getAttribute("xform_xele_index")].getValue();
                var appAccount = agent.Eles[document.getElementById("XTextBox35").getAttribute("xform_xele_index")].getValue();

                YZSoft.Ajax.request({
                    async: false,  //执行完再执行后面的代码
                    url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                    method: 'POST',
                    params: {
                        method: 'AbortProcStep',
                        stepID: stepID,
                        taskID: taskID,
                        formNo: formNo,
                        appName: appName,
                        appAccount: appAccount
                    },
                    success: function (action) {
                    },
                    failure: function (action) {
                        //alert(action.result.Message);
                    }
                })
            }

       

            var SISRights = '0';
            var PISRights = '0';

            //申请人提交时含税销售总价CNY大于1千万时提示
            if (ZhuangTai == "业务员发起申请" && actname == "提交") {
                //查询物料原产地，若原产地是美国，则提示信息
                if (contractCurrency == "CNY") {
                    for (var i = 2; i < tableObj.rows.length - 1; i++) {
                        var purchaseCurrency = agent.Eles[tableObj.rows[i].cells[19].children[0].getAttribute("xform_xele_index")].getValue();
                        var origin = agent.Eles[tableObj.rows[i].cells[4].children[1].getAttribute("xform_xele_index")].getValue();
                        var state = 0;
                        //alert(purchaseCurrency + "：" + origin);
                        if (purchaseCurrency != 'CNY' && origin == "美国") {
                            state = 1;

                        }
                    }
                    if (state == 1) {
                        //alert("有原产国是美国的产品，注意加征关税！");
                    }
                }


                var SUMPDSellingTotalvalueRMB = agent.Eles[document.getElementById("XTextBox175").getAttribute("xform_xele_index")].getValue();
                if (SUMPDSellingTotalvalueRMB >= 10000000) {
                    Ext.MessageBox.alert("审批提示：", "此单含税销售总价CNY≥1000万元，需要先到董秘审批。");
                }

                //售达方超期应收账款
                var XTextBox23 = agent.Eles[document.getElementById("XTextBox23").getAttribute("xform_xele_index")].getValue();
                //付款方超期应收账款
                var XTextBox1 = agent.Eles[document.getElementById("XTextBox1").getAttribute("xform_xele_index")].getValue();
                //售达方超期应收账款说明
                var XTextBox140 = agent.Eles[document.getElementById("XTextBox140").getAttribute("xform_xele_index")].getValue();
                //付款方超期应收账款说明
                var XTextBox150 = agent.Eles[document.getElementById("XTextBox150").getAttribute("xform_xele_index")].getValue();

                if (parseInt(XTextBox23) > 0) {
                    if (XTextBox140 == "") {
                        //alert("请填写售达方超期应收账款说明！");
                       // return false;
                    }
                    if (parseInt(XTextBox1) > 0) {
                        if (XTextBox150 == "") {
                            alert("请填写付款方超期应收账款说明！");
                            return false;
                        }
                    }
                }

                //质保金
                var XTextBox2 = agent.Eles[document.getElementById("XTextBox2").getAttribute("xform_xele_index")].getValue();
                //质保金判断
                var RetentionMoney = agent.Eles[document.getElementById("XTextBox2").getAttribute("xform_xele_index")].getValue();
                if (RetentionMoney == '') {
                    agent.Eles[document.getElementById("XTextBox2").getAttribute("xform_xele_index")].setValue(0);
                }


                if (parseInt(XTextBox2) > 0) {
                    var XDropDownList39 = agent.Eles[document.getElementById("XDropDownList39").getAttribute("xform_xele_index")].getValue();
                    if (XDropDownList39 == "") {
                        alert("请选择质保金付款条件！");
                        return false;
                    }
                }
            }



            //预审流程状态为地区助理复核或业务员再次发起申请
            if (ZhuangTai == "地区助理复核" || ZhuangTai == "业务员再次发起申请") {
                //地区助理账号
                var Assistant = agent.Eles[document.getElementById("XTextBox116").getAttribute("xform_xele_index")].getValue();
                //售达方客户SAPID
                var STPSAPID = agent.Eles[document.getElementById("XTextBox49").getAttribute("xform_xele_index")].getValue();
                //付款方客户SAPID
                var PTPSAPID = agent.Eles[document.getElementById("XTextBox57").getAttribute("xform_xele_index")].getValue();
                //销售组织
                var Organization = agent.Eles[document.getElementById("XTextBox16").getAttribute("xform_xele_index")].getValue();
                //分销渠道对象
                var ChannelOfDistributionObject = document.getElementById("XDropDownList12");
                //分销渠道选中的值
                //var ChannelOfDistribution = ChannelOfDistributionObject.options[ChannelOfDistributionObject.selectedIndex].value;
                var ChannelOfDistribution = agent.Eles[document.getElementById("XDropDownList12").getAttribute("xform_xele_index")].getValue();
                //产品线对象
                var ProductLineObject = document.getElementById("XDropDownList22");
                //产品线选中的值
                //var ProductLine = ProductLineObject.options[ProductLineObject.selectedIndex].value;
                var ProductLine = agent.Eles[document.getElementById("XDropDownList22").getAttribute("xform_xele_index")].getValue();


                //判断售达方和付款方的客户是否在该销售组织下
                if (Assistant != "" && STPSAPID != "" && Organization != "" && PTPSAPID != "") {
                    //售达方客户信息
                    ////AssistantSAPID-助理SAPID，ClientSAPID-售达方客户，SalesOrganization-销售组织，ProductLine-产品线，ChannelOfDistribution-分销渠道
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        params: {
                            method: 'CustomerRights',
                            AssistantSAPID: Assistant,
                            ClientSAPID: STPSAPID,
                            SalesOrganization: Organization,
                            ProductLine: ProductLine,
                            ChannelOfDistribution: ChannelOfDistribution
                        },
                        success: function (action) {
                            var result = action.result;
                            var ISRights = action.result.Value;
                            SISRights = ISRights;
                        },
                        failure: function (action) {
                            alert(action.result.Message);
                        }
                    });

                    //付款方客户信息
                    YZSoft.Ajax.request({
                        url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                        method: 'POST',
                        params: {
                            method: 'CustomerRights',
                            AssistantSAPID: Assistant,
                            ClientSAPID: PTPSAPID,
                            SalesOrganization: Organization,
                            ProductLine: ProductLine,
                            ChannelOfDistribution: ChannelOfDistribution
                        },
                        success: function (action) {
                            var result = action.result;
                            var ISRights = action.result.Value;
                            PISRights = ISRights;
                        },
                        failure: function (action) {
                            alert(action.result.Message);
                        }
                    });

                    if (SISRights == '1') {
                        alert("该售达方客户无操作权限，需授权！");
                        return false;
                    }
                    else if (SISRights == '2') {
                        alert("该售达方客户需扩展到该销售组织下！");
                        return false;
                    }
                    else if (SISRights == '0') {
                        if (PISRights == '1') {
                            alert("该付款方客户无操作权限，需授权！");
                            return false;
                        }
                        else if (PISRights == '2') {
                            alert("该付款方客户需扩展到该销售组织下！");
                            return false;
                        }
                    }

                }

            }



            //售达方和付款方是否是红旗客户，如果是就在提交的时候给出一个提示
            var radio3_0 = document.getElementById("XRadioButtonList3_0");
            var radio4_0 = document.getElementById("XRadioButtonList4_0");
            if (radio3_0.checked) {
               // alert("售达方客户是红旗客户！");
                //return false;
            }
            else if (radio4_0.checked) {
                alert("付款方客户是实体清单客户！");
                //return false;
            }
            //查看售达方和付款方客户是否有SAPID、是否存在物料号
            var tableObj = document.getElementById('tablenew');
            var tableInfo1 = new Array();
            var ProcurementModel = new Array();
            var ManufacturerNo = new Array();
            for (var i = 2; i < tableObj.rows.length - 1; i++) {
                //物料号
                tableInfo1[i - 2] = agent.Eles[tableObj.rows[i].cells[5].children[0].getAttribute("xform_xele_index")].getValue();
                //采购模式
                ProcurementModel[i - 2] = agent.Eles[tableObj.rows[i].cells[15].children[0].getAttribute("xform_xele_index")].getValue();
                //厂商编号
                ManufacturerNo[i - 2] = agent.Eles[tableObj.rows[i].cells[6].children[0].getAttribute("xform_xele_index")].getValue();
            }
            var BackValue = true;
            for (var i = 0; i < tableInfo1.length; i++) {
                if (tableInfo1[i] == "") {
                    BackValue = false;
                }
                if (STPSAPID == "" && PTPSAPID == "") {
                    alert("请申请客户SAPID");
                }
            }
            if (BackValue == false) {
                alert("请申请SAP物料主数据！");
            }

            if (SISRights == '1') {
                alert("该售达方客户无操作权限，需授权！");
            }
            else if (SISRights == '2') {
                alert("该售达方客户需扩展到该销售组织下！");
            }
            else if (SISRights == '0') {
                if (PISRights == '1') {
                    alert("该付款方客户无操作权限，需授权！");
                }
                else if (PISRights == '2') {
                    alert("该付款方客户需扩展到该销售组织下！");
                }
            }

            //合同金额大于10万  所有0金额行项目的不含税成本小计 不大于 不含税采购总价的10%  --直接使用汇率计算
            /*
            var SumPurchasePrice = getByClassName("purchaseValue");     //行项目 采购价格
            //var SumPurchasePrice =document.getElementsByClassName("purchaseValue");     //行项目 采购价格
            //var SumTotalAmount = document.getElementsByClassName("sellValue");       //行项目 销售价格
            var SumTotalAmount = getByClassName("sellValue");       //行项目 销售价格
            */

            var ContractAmount = agent.Eles[document.getElementById("XTextBox175").getAttribute("xform_xele_index")].getValue();  //合同总金额
            var SumPurchaseAmount = agent.Eles[document.getElementById("XTextBox172").getAttribute("xform_xele_index")].getValue();   //不含税采购总价*0.1

            var gg = 0;
            var tableObj = document.getElementById("tablenew");
            if (Number(ContractAmount) > 100000) {
                for (var i = 2; i < tableObj.rows.length - 1; i++) {
                    var SumPurchasePrice = agent.Eles[tableObj.rows[i].cells[26].children[1].getAttribute("xform_xele_index")].getValue();//不含税采购总价(人民币)
                    var SumTotalAmount = agent.Eles[tableObj.rows[i].cells[13].children[1].getAttribute("xform_xele_index")].getValue();//含税销售总价（人民币）
                    if (SumTotalAmount == 0) {
                        if (parseFloat(SumPurchasePrice) > parseFloat(SumPurchaseAmount)) {
                            gg = 1;
                        }
                    }
                }
                /*
                for (var i = 0; i < SumTotalAmount.length; i++) {
                    if (SumTotalAmount[i].value == 0) {
                        if (parseFloat(SumPurchasePrice[i].value) > parseFloat(SumPurchaseAmount)) {
                            gg = 1;
                        }
                    }

                }*/
            }
            if (actname == "提交" || actname == "重新提交") {
                if (gg == 1) {
                    alert("合同金额大于10万 ；零金额行项目的不含税成本小计大于不含税采购总价的10%，预审不予通过！！ ");
                    return false;
                }
                 
               
            }

            /*
            //联系人邮箱可是否正确
            var APPID = agent.Eles[document.getElementById("XTextBox154").getAttribute("xform_xele_index")].getValue();
            var mail = agent.Eles[document.getElementById("XTextBox89").getAttribute("xform_xele_index")].getValue();
            var filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
            if (agent.Eles[document.getElementById("XTextBox154").getAttribute("xform_xele_index")].getValue() == userToken.Account && ZhuangTai == "提交") {
                if (filter.test(mail)) {
                    return true;
                }
                else {
                    alert('联系人Email格式不正确');
                    return false;
                }
            }
            */

            if (agent.Eles[document.getElementById("XTextBox154").getAttribute("xform_xele_index")].getValue() == userToken.Account || ZhuangTai == "暂存") {
                //零采时给出信息提示
                for (var i = 0; i < ProcurementModel.length; i++) {
                    if (ProcurementModel[i] == "零采") {
                        alert("此单有零采仪器，请判断是否需做预付款申请！");
                        break;
                    }
                }
                //厂商是日置是给出信息提示
                for (var i = 0; i < ManufacturerNo.length; i++) {
                    if (ManufacturerNo[i] == "206") {
                        alert("日置非现货产品货期尽量签6-8周，或提前请日置销售备货！");
                        break;
                    }
                }
            }
        });


        //页面首次进来是不是白名单
        function getWhith() {
            //是不是白名单
            var urlbm = YZSoft.$url('Oimec/WorkFlow/Services/MasterDataHandler.ashx');
            var CustomerName = agent.Eles[document.getElementById("XTextBox56").getAttribute("xform_xele_index")].getValue();//付款方客户
            //  CustomerName = "东方";
            var parmbm = { method: "GetCustomerWhiteList", CustomerName: CustomerName };
            var Identification = "";

            YZSoft.Ajax.request({
                url: urlbm,
                async: false,
                params: parmbm,
                success: function (action) {

                    var data = action;
                    var obj = eval("(" + data.responseText + ")");
                    var len = obj.children.length;

                    if (len > 0) {

                        Identification = obj.children[0].Identification;

                    }
                },
                failure: function (action) {
                    Identification = "";
                }
            }); //是不是白名单结束

            if (Identification=="1") {//是白名单
                agent.Eles[document.getElementById("Overdue15").getAttribute("xform_xele_index")].setValue("");
            }

        }

        //获取地址栏参数
        function getQueryString(name) {
            var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)', 'i');
            var r = window.location.search.substr(1).match(reg);
            if (r != null) {
                return unescape(r[2]);
            }
            return null;
        }

        //获取SAP备货价格
        function GetStockingPrice() {
            var rv = new Array();
            var ArrayCode = new Array();
            var tableObj = document.getElementById('tablenew');
            for (var i = 2; i < tableObj.rows.length - 1; i++) {
                if (agent.Eles[tableObj.rows[i].cells[15].children[0].getAttribute("xform_xele_index")].getValue() == "备货") {
                    rv[i - 2] = agent.Eles[tableObj.rows[i].cells[5].children[0].getAttribute("xform_xele_index")].getValue();
                }
            }
            YZSoft.Ajax.request({
                url: YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx'),
                method: 'POST',
                params: {
                    method: 'GetStockingPrice',
                    ItemNumber: rv
                },
                success: function (action) {
                    var result = action.result;
                    var data = action.result.Value;
                    //alert(data);
                    for (var i = 2; i < tableObj.rows.length - 1; i++) {
                        if (agent.Eles[tableObj.rows[i].cells[15].children[0].getAttribute("xform_xele_index")].getValue() == "备货") {
                            //含税采购单价
                            agent.Eles[tableObj.rows[i].cells[20].children[0].getAttribute("xform_xele_index")].setValue(Number(data[i - 2].Price));
                            //不含税库存成本单价
                            //agent.Eles[tableObj.rows[i].cells[48].children[0].getAttribute("xform_xele_index")].setValue(Number(data[i - 2].NTPrice));
                            ArrayCode[i - 2] = data[i - 2].Code;
                            if (ArrayCode[i - 2] == "1") {
                                agent.Eles[tableObj.rows[i].cells[18].children[0].getAttribute("xform_xele_index")].setValue("");
                            }
                            //销售数量赋值采购数量
                            agent.Eles[tableObj.rows[i].cells[18].children[0].getAttribute("xform_xele_index")].setValue(agent.Eles[tableObj.rows[i].cells[8].children[0].children[0].getAttribute("xform_xele_index")].getValue());
                            //tableObj.rows[i].cells[17].children[0].value = "CNY";
                            //采购币种设置为CNY
                            agent.Eles[tableObj.rows[i].cells[19].children[0].getAttribute("xform_xele_index")].setValue("CNY");
                            XFormOnChange(agent.Eles[tableObj.rows[i].cells[19].children[0].getAttribute("xform_xele_index")]);
                            //采购折扣
                            agent.Eles[tableObj.rows[i].cells[21].children[0].getAttribute("xform_xele_index")].setValue(0);
                            //采购发票税点
                            agent.Eles[tableObj.rows[i].cells[39].children[0].getAttribute("xform_xele_index")].setValue("13%增值税发票");
                            //采购发票税点（小数)
                            agent.Eles[tableObj.rows[i].cells[39].children[1].getAttribute("xform_xele_index")].setValue(0.13);
                            //供应商货期
                            agent.Eles[tableObj.rows[i].cells[40].children[0].getAttribute("xform_xele_index")].setValue(0);
                            // var a = agent.Eles[tableObj.rows[i].cells[20].children[0].getAttribute("xform_xele_index")].disabled;
                            //var a = tableObj.rows[i].cells[20].children[0].children[0].disabled;
                            //alert(a);
                            if (!tableObj.rows[i].cells[20].children[0].children[0].disabled) {
                                XFormOnChange(agent.Eles[tableObj.rows[i].cells[20].children[0].getAttribute("xform_xele_index")]);
                            }
                        }

                    }
                    for (var i = 0; i < ArrayCode.length; i++) {
                        if (ArrayCode[i] == "1") {
                            alert("当前无库存数量，请手工填写成本！");
                            break;
                        }
                    }
                },
                failure: function (action) {
                    alert(action.result.Message);
                }
            });

        }
    </script>
    <script type="text/javascript">

        //导入销售机会 传参
        function OppSearch(btn, cfg) {
            //销售机会名称
            //var oppName = document.getElementById("XTextBox109").vlaue;
            var accountID = agent.Eles[document.getElementById("XTextBox35").getAttribute("xform_xele_index")].getValue();
            var buName = agent.Eles[document.getElementById("XTextBox42").getAttribute("xform_xele_index")].getValue();

            cfg.param = { AccountID: accountID, BUName: buName };
        }
    </script>
    <script type="text/javascript">
        //如果选中易捷，则清除客户属性字符串
        function ClearlyStateCRM(OFYIJIE, YUANZHI, ClearlyStateCRM) {
            if (OFYIJIE == "1") {
                return "";
            }
            else {
                if (YUANZHI == "") {
                    return ClearlyStateCRM;
                }
                else {
                    return YUANZHI;
                }

            }
        }
        //如果选中易捷，则清除客户属性信息
        function CRMOppString(YingYongHuanJie, ShiYongZhe, ReDian, Opp, OFYIJIE) {
            if (OFYIJIE == "1") {
                return "";
            }
            else {
                var OppString = YingYongHuanJie + ShiYongZhe + ReDian + Opp;
                return OppString;
            }

        }
        //根据开票公司，清空客户交货方式
        function ClearlyStateDelivery(Company, YUANZHI, ClearlyStateDelivery) {
            if (Company == "1000东方中科北京" || Company == "1010东方中科上海" || Company == "1020东方中科深圳" || Company == "2100苏州博德") {
                return "";
            }
            else {
                if (ClearlyStateDelivery == "") {
                    return ClearlyStateDelivery;
                }
                else {
                    return YUANZHI;
                }
            }
        }
        //开票公司选择2000、A300，税率为0
        function ClearlyStateRate(Company, YUANZHI) {
            if (Company != "1000东方中科北京" && Company != "1010东方中科上海" && Company != "1020东方中科深圳" && Company != "2100苏州博德") {

                return "0%";
            }
            else {
                return YUANZHI;
            }
        }
        //开票公司选择1000、1001、1002、2100，税种为空
        function ClearlyStateRate1(Company, YUANZHI, ysInvoiceType) {
            
            if (ysInvoiceType != "") {
              
                if (Company == "2000上海颐合") {
                    return "";
                } else {
                    return ysInvoiceType;
                }
               

            } else {
                if (Company != "1000东方中科北京" && Company != "1010东方中科上海" && Company != "1020东方中科深圳" && Company != "2100苏州博德") {
                     
                    return "";
                }
                else {
                    return YUANZHI;
                }
            }
            agent.Eles[document.getElementById("ysInvoiceType").getAttribute("xform_xele_index")].setValue("");
            agent.Eles[document.getElementById("ysTaxType").getAttribute("xform_xele_index")].setValue("");
            
           
        }
    </script>
    <script type="text/javascript">
        //点击全选新品销售按钮，将物料类型赋值为销售物料
        function AllXINPINXIAOSHOU() {
            var tableInfo1 = new Array();
            var tableObj = document.getElementById('tablenew');
            if (tableObj.rows.length > 3) {
                for (var i = 2; i < tableObj.rows.length - 1; i++) {    //遍历Table的所有Row //遍历Row中的每一列
                    agent.Eles[tableObj.rows[i].cells[1].children[0].getAttribute("xform_xele_index")].setValue("新品销售");
                    XFormOnChange(agent.Eles[tableObj.rows[i].cells[1].children[0].getAttribute("xform_xele_index")]);
                    agent.Eles[tableObj.rows[i].cells[2].children[4].getAttribute("xform_xele_index")].setValue("销售物料");
                    agent.Eles[tableObj.rows[i].cells[5].children[0].getAttribute("xform_xele_index")].setValue(agent.Eles[tableObj.rows[i].cells[2].children[0].getAttribute("xform_xele_index")].getValue());
                }
            }
        }

        //打印采购申请单函数
        function aa() {
            var temp = document.getElementById('XLabel3').innerText;
            window.open("采购申请单.aspx?serialNum=" + temp);
        }
        //打印销售预审单函数
        function aa1() {
            var temp = document.getElementById('XLabel3').innerText;
            window.open("销售预审单.aspx?serialNum=" + temp);
        }
        //获取BPM价格体系价格，选择为订货时带出订货价格
        function DingHuoCaiGouJiaGe(YuanCaiGouJiaGe, CaiGouJiaGe, CaiGouMoShi,Proportion, ManufacturersID) {
            if (ManufacturersID == "217") {
                //计算公式：采购单价×（1+标准服务比例）×数量×（1-采购折扣%）
                if (Proportion=="") {
                    Proportion = 0;
                }
                Proportion = parseFloat(Proportion);
                Proportion = (100 + Proportion) / 100;

                if (CaiGouMoShi == "原厂采购" && CaiGouJiaGe != "") {
                    if (parseInt(CaiGouJiaGe) >= 0) {
                        return CaiGouJiaGe * Proportion;
                    }
                    else {
                        return YuanCaiGouJiaGe;
                    }
                }
                else {
                    return YuanCaiGouJiaGe;
                }



            } else {
                if (CaiGouMoShi == "原厂采购" && CaiGouJiaGe != "") {
                    if (parseInt(CaiGouJiaGe) >= 0) {
                        return CaiGouJiaGe;
                    }
                    else {
                        return YuanCaiGouJiaGe;
                    }
                }
                else {
                    return YuanCaiGouJiaGe;
                }
            }
        }
        //获取BPM价格体系折扣，选择为订货时带出订货折扣
        function DingHuoCaiGouZheKou(YuanCaiGouZheKou, CaiGouZheKou, CaiGouMoShi ) {
           


                if (CaiGouMoShi == "原厂采购" && CaiGouZheKou != "") {
                    if (parseInt(CaiGouZheKou) >= 0) {
                        return CaiGouZheKou;
                    }
                    else {
                        return YuanCaiGouZheKou;
                    }
                }
                else {
                    return YuanCaiGouZheKou;
                }
            
        }

        //采购模式为备货是，采购发票税点是“17%增值税发票”
        function IFCNY(CaiGouBiZhong, YuanCaiGouFaPiao, CaiGouMoShi) {
            if (CaiGouMoShi == "备货") {
                return "13%增值税发票";
            }
            else if (CaiGouBiZhong == "CNY") {
                return YuanCaiGouFaPiao;
            }
            else {
                return "";
            }
        }

        //技术服务协议类型
        function TSType(BusinessCategories, Type) {
            if (BusinessCategories == "代理维修" || BusinessCategories == "代理延保" || BusinessCategories == "代理校准") {
                return "";
            }
            else
                return Type;
        }

        function div_ShowHidden(id) {
            //div 展开 隐藏
            var btnName = 'btn_' + id;
            var divName = "div_" + id;
            var btn_value = document.getElementById(btnName).value;
            if (btn_value == "▽展开") {
                document.getElementById(btnName).value = "△隐藏";
                document.getElementById(divName).style.display = "";//显示
            }
            else {
                document.getElementById(btnName).value = "▽展开";
                document.getElementById(divName).style.display = "none";//隐藏
            }
        }

        //修改行项目控件失效时样式
        function UpLineItemStyle(ContractCurrency, PrchaseCurrency, PurchasingPattern, RowNumber) {
            var tableObj = document.getElementById('tablenew');


            //控件backgroundColor清空
            tableObj.rows[RowNumber + 1].cells[27].children[0].children[0].style.backgroundColor = "";//国际运保费
            tableObj.rows[RowNumber + 1].cells[28].children[0].children[0].style.backgroundColor = "";//国际运保费(采购币种)
            tableObj.rows[RowNumber + 1].cells[30].children[0].children[0].style.backgroundColor = "";//报关杂费(人民币)
            tableObj.rows[RowNumber + 1].cells[31].children[0].children[0].style.backgroundColor = "";//关税税率
            tableObj.rows[RowNumber + 1].cells[39].children[0].children[0].style.backgroundColor = "";//采购发票税点
            tableObj.rows[RowNumber + 1].cells[36].children[0].children[0].style.backgroundColor = "";//联系人
            tableObj.rows[RowNumber + 1].cells[37].children[0].children[0].style.backgroundColor = "";//联系电话
            tableObj.rows[RowNumber + 1].cells[38].children[0].children[0].style.backgroundColor = "";//采购付款方式

            //采购币种、采购数量
            if (PurchasingPattern == "备货") {
                tableObj.rows[RowNumber + 1].cells[19].children[0].children[0].style.backgroundColor = "#E6F1F8";
                tableObj.rows[RowNumber + 1].cells[18].children[0].children[0].style.backgroundColor = "#E6F1F8";
                tableObj.rows[RowNumber + 1].cells[34].children[0].children[0].style.backgroundColor = "#E6F1F8";   //计划行类别
                tableObj.rows[RowNumber + 1].cells[40].children[0].children[0].style.backgroundColor = "#E6F1F8";   //供应商货期
                tableObj.rows[RowNumber + 1].cells[42].children[0].children[0].style.backgroundColor = "#E6F1F8";   //供应商保修期
                tableObj.rows[RowNumber + 1].cells[35].children[0].children[0].style.backgroundColor = "#E6F1F8";   //采购供应商

            }
            //国际运保费、国际运保费(采购币种)
            if (PrchaseCurrency == "CNY" || PurchasingPattern == "备货") {
                tableObj.rows[RowNumber + 1].cells[27].children[0].children[0].style.backgroundColor = "#E6F1F8";//国际运保费
                tableObj.rows[RowNumber + 1].cells[28].children[0].children[0].style.backgroundColor = "#E6F1F8";//国际运保费(采购币种)
            }
            //报关杂费(人民币)、关税税率
            if (PrchaseCurrency == "CNY" || (PrchaseCurrency != "CNY" && ContractCurrency != "CNY") || PurchasingPattern == "备货") {
                tableObj.rows[RowNumber + 1].cells[30].children[0].children[0].style.backgroundColor = "#E6F1F8";//报关杂费(人民币)
                tableObj.rows[RowNumber + 1].cells[31].children[0].children[0].style.backgroundColor = "#E6F1F8";//关税税率
            }
            //采购发票税点
            if (PrchaseCurrency != "CNY" || PurchasingPattern == "备货") {
                tableObj.rows[RowNumber + 1].cells[39].children[0].children[0].style.backgroundColor = "#E6F1F8";//采购发票税点
            }
            //联系人、联系电话、采购付款方式
            if (PurchasingPattern == "备货") {
                tableObj.rows[RowNumber + 1].cells[36].children[0].children[0].style.backgroundColor = "#E6F1F8";//联系人
                tableObj.rows[RowNumber + 1].cells[37].children[0].children[0].style.backgroundColor = "#E6F1F8";//联系电话
                tableObj.rows[RowNumber + 1].cells[38].children[0].children[0].style.backgroundColor = "#E6F1F8";//采购付款方式
            }
        }

    </script>
    <script type="text/javascript">
        //alert(window.navigator.userAgent.indexOf("Firefox"));

        if (window.navigator.userAgent.indexOf("MSIE") >= 1) {
            var IE1024 = "";
            var IE800 = "";
            var IE1152 = "";
            var IEother = "";

            ScreenWidth(IE1024, IE800, IE1152, IEother)
        } else {
            if (window.navigator.userAgent.indexOf("Firefox") >= 1) {
                //如果浏览器为Firefox
                var Firefox1024 = "";
                var Firefox800 = "";
                var Firefox1152 = "";
                var Firefoxother = "";

                ScreenWidth(Firefox1024, Firefox800, Firefox1152, Firefoxother)
            } else {
                //如果浏览器为其他
                var Other1024 = "";
                var Other800 = "";
                var Other1152 = "";
                var Otherother = "";
                ScreenWidth(Other1024, Other800, Other1152, Otherother)
            }
        }

        function ScreenWidth(CSS1, CSS2, CSS3, CSS4) {
            //alert("分辨率：" + screen.height + "," + screen.width);
            if ((screen.width == 1024) && (screen.height == 768)) {
                setActiveStyleSheet(CSS1);
            } else {
                if ((screen.width == 800) && (screen.height == 600)) {
                    setActiveStyleSheet(CSS2);
                } else {
                    if ((screen.width == 1152) && (screen.height == 864)) {
                        setActiveStyleSheet(CSS3);
                    } else {
                        setActiveStyleSheet(CSS4);
                    }
                }
            }
        }

        function setActiveStyleSheet(title) {
            //document.getElementsByTagName("link")[1].href = "/Oimec/Styles/css/" + "StyleSheet1366.css";
            //<link href="/Oimec/Styles/css/StyleSheet.css" rel="stylesheet" type="text/css" />
        }

       

    </script>

    <script type="text/javascript">


        function onkeyup_UpdateSupplierSAPID()
        {
            GetSupplier();
        }


        //根据供应商名称 判断是否是新供应商，如果原来是老供应商  后又修改成新供应商 则清空老供应商sapid。
        function GetSupplier() {

            var aDivSourcingPurchasing = document.getElementsByClassName("SourcingPurchasing");//采购供应商
            var aDivSupplierSAPID = document.getElementsByName("SupplierSAPID");//采购供应商sapid

            for (var i = 0; i < aDivSourcingPurchasing.length; i++) {

                //采购供应商名称
                var div = aDivSourcingPurchasing[i];
                var id = div.getElementsByTagName('input')[0].id;
                var v = document.getElementById(id).value;

                //采购供应商sapid
                var divSapId = aDivSupplierSAPID[i];
                var Sapid = divSapId.getElementsByTagName('input')[0].id;
                var sapv = document.getElementById(Sapid).value;

                var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');
                // var itemId = agent.Eles[document.getElementById("XTextBox216").getAttribute("xform_xele_index")].getValue();
                var parm = { method: "GetAdvancePayAppDetailByNameList", SupplierName: v };


                AjaxParm(url, false, parm, function (action) {
                    var data = action;
                    //console.log("ss")
                    //console.log(data)
                    if (data.result.length == 0) {
                        document.getElementById(Sapid).value = "";
                    } else {
                        var SupplierSAPID = data.result[0].SupplierSAPID;
                        var SupplierID = data.result[0].SupplierID;
                        document.getElementById(Sapid).value = SupplierSAPID;
                        //agent.Eles[document.getElementById("PartnerID").getAttribute("xform_xele_index")].setValue(SupplierID);
                        //PartnerID
                    }

                });



            }

        }


        //根据表单号获取SO号
        function GetSoInfoByFormNo() {
            //表单号
            var formNo = agent.Eles[document.getElementById("XLabel3").getAttribute("xform_xele_index")].getValue();

            var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');
            var parm = { method: "GetSoInfoByFormNo", FormNo: formNo };
            // document.getElementById("so").disabled = false;
            AjaxParm(url, true, parm, function (action) {
                var data = action.result;
                console.log(data.Bean);
                //VoucherNo
                if (data.Bean.length > 0) {
                    //alert("ds")
                    var VoucherNo = "";
                    var no = "";
                    for (var i = 0; i < data.Bean.length; i++) {

                        VoucherNo += data.Bean[i].VoucherNo + "/";

                    }
                    no = VoucherNo.toString().substring(0, VoucherNo.length - 1);
                    var formNo = agent.Eles[document.getElementById("XTextBox48").getAttribute("xform_xele_index")].setValue(no);
                    var date = new Date();
                    agent.Eles[document.getElementById("UpdateSoDate").getAttribute("xform_xele_index")].setValue(date);
                }
            });

        }

        //付款方地址必填
        function payAddress(InvoiceType, IsContractBusiness) {
            //发票类型不为 增值税普通发票时必填
            //alert(InvoiceType.indexOf("增值税普通发票"));
            //非增值税普通发票
            if (InvoiceType != "" && InvoiceType.indexOf("增值税普通发票") < 0 && IsContractBusiness=="否") {
                return false;
            }
            else
                return true
        }

        //实际付款条件
        function ActTermsPayment() {
            var SettlementMethod = getXValue("SettlementMethod");
            setXValue("XTextBox179", SettlementMethod)
        }

        //更新合同产品信息
        function updateContractProduct() {

            //获取产品明细TABLE
            //循环遍历行项目信息
            var tableObj = document.getElementById('tablenew');
            var count = tableObj.rows.length - 3;

            var ctable = document.getElementById('ctable'); //合同产品信息

            //合同产品信息
            //添加行
            var c = ctable.rows.length - 1;
            //alert(c);
            var table = agent.findGridFromTableName(null, 'DF_SA_ContractProductList'); //获取table对象
            if (table == undefined)
                return null;
            if (c > 0) {
                table.deleteBlocks(0, c);
            }
            //alert(count);
            table.appendBlock(count);

            for (var i = 2; i < tableObj.rows.length - 1; i++) {

                var productModel = agent.Eles[tableObj.rows[i].cells[3].children[0].getAttribute("xform_xele_index")].getValue(); //产品型号
                var productName = agent.Eles[tableObj.rows[i].cells[4].children[0].getAttribute("xform_xele_index")].getValue(); //产品名称
                var manufacturer = agent.Eles[tableObj.rows[i].cells[7].children[0].getAttribute("xform_xele_index")].getValue(); //厂商
                var number = getElementIdValue("Number", i - 2, "input");//数量
                var unit = getElementIdValue("Unit", i - 2, "input"); //单位
                var unitPrice = agent.Eles[tableObj.rows[i].cells[12].children[0].getAttribute("xform_xele_index")].getValue(); //单价
                var totalPrice = agent.Eles[tableObj.rows[i].cells[13].children[0].getAttribute("xform_xele_index")].getValue(); //总价
                var DeliveryDeadline = getElementIdValue("DeliveryDeadline", i - 2, "input");//交货期限
                var DeliveryDeadlineDayOrWeek = getElementIdValue("DeliveryDeadlineDayOrWeek", i - 2, "select");//交货期限单位
                var WarrantyPeriod = getElementIdValue("WarrantyPeriod", i - 2, "select"); //保修期
                var WarrantyPeriodOther = getElementIdValue("WarrantyPeriodOther", i - 2, "input"); //保修期

                agent.Eles[ctable.rows[i - 1].cells[2].children[0].getAttribute("xform_xele_index")].setValue(productModel);
                agent.Eles[ctable.rows[i - 1].cells[1].children[0].getAttribute("xform_xele_index")].setValue(productName);
                agent.Eles[ctable.rows[i - 1].cells[3].children[0].getAttribute("xform_xele_index")].setValue(manufacturer);
                agent.Eles[ctable.rows[i - 1].cells[4].children[0].getAttribute("xform_xele_index")].setValue(unit);
                agent.Eles[ctable.rows[i - 1].cells[5].children[0].getAttribute("xform_xele_index")].setValue(number);
                agent.Eles[ctable.rows[i - 1].cells[6].children[0].getAttribute("xform_xele_index")].setValue(unitPrice);
                agent.Eles[ctable.rows[i - 1].cells[7].children[0].getAttribute("xform_xele_index")].setValue(totalPrice);
                agent.Eles[ctable.rows[i - 1].cells[8].children[0].getAttribute("xform_xele_index")].setValue(DeliveryDeadline);
                agent.Eles[ctable.rows[i - 1].cells[8].children[1].getAttribute("xform_xele_index")].setValue(DeliveryDeadlineDayOrWeek);
                agent.Eles[ctable.rows[i - 1].cells[9].children[0].getAttribute("xform_xele_index")].setValue(WarrantyPeriod);
                agent.Eles[ctable.rows[i - 1].cells[9].children[1].getAttribute("xform_xele_index")].setValue(WarrantyPeriodOther);
                XFormOnChange(agent.Eles[ctable.rows[i - 1].cells[7].children[0].getAttribute("xform_xele_index")]);
            }
        }

        //验证合同信息控制
        function CheckContractInfo() {

            //供方联系人电话 手机验证
            //var SupplierTel = getXValue("SupplierTel");
            //var SupplierPhone = getXValue("SupplierPhone");
            //if (SupplierTel == "" && SupplierPhone == "") {
            //    Ext.MessageBox.alert("提示", "供方联系人电话或供方联系人手机不能为空,请您输入");
            //    return false;
            //}

            //if (SupplierTel != "") {
            //    var tel = param.checkTel(SupplierTel, "0");
            //    if (!tel) {
            //        Ext.MessageBox.alert("提示", "供方联系电话格式不正确");
            //        return false;
            //    }
            //}

            //if (SupplierPhone != "") {
            //    var tel = param.checkTel(SupplierPhone, "1");
            //    if (!tel) {
            //        Ext.MessageBox.alert("提示", "供方联系手机格式不正确");
            //        return false;
            //    }
            //}

            //合同明细更改之后的金额 不能大于合同金额
            /*
            var totals = agent.Eles[document.getElementById("totals").getAttribute("xform_xele_index")].getValue();//更改后的总金额
            var ContractAmount = agent.Eles[document.getElementById("XTextBox68").getAttribute("xform_xele_index")].getValue(); //产品明细合同金额(含税销售总价人民币)
            //alert(ContractAmount);
            var t = parseFloat(totals);
            var amount = parseFloat(ContractAmount);

            var money = t - amount;
            var html = "";
            if (money < 0) {
                html = "合同金额大于合同明细总金额" + money + "";
            } else {
                html = "合同金额小于合同明细总金额" + money + "";
            }
            if (totals != ContractAmount) {
                Ext.MessageBox.alert("提示", "合同明细总金额必须等于合同金额," + html + "");
                return false;
            }
            */

            //货到交货地点的日期
            var ObjectionPeriod = getXValue("ObjectionPeriod");

            if (ObjectionPeriod <= 0) {
                Ext.MessageBox.alert('提示', '货到交货地点的日期必须大于0');
                return false;
            }

            //结算方式及期限 //也就是实际付款条件
            var SettlementMethod = getXValue("SettlementMethod");
            if (SettlementMethod == "") {
                Ext.MessageBox.alert('提示', '请输入结算方式及期限');
                return false;
            }

            //供方应向需方支付相当于本合同总价
            var SupplierToDemander = getXValue("SupplierToDemander");
            //alert(SupplierToDemander);
            if (SupplierToDemander <= 0) {
                Ext.MessageBox.alert('提示', '供方应向需方支付相当于本合同总价的违约金必须大于0');
                return false;
            }

            //需方应向供方支付相当于本合同总价
            var DemanderToSupplier = getXValue("DemanderToSupplier");

            if (DemanderToSupplier <= 0) {
                Ext.MessageBox.alert('提示', '需方应向供方支付相当于本合同总价的违约金必须大于0');
                return false;
            }

            //需方应向供方支付相当于本合同总价
            var RescindContract = getXValue("RescindContract");

            if (RescindContract <= 0) {
                Ext.MessageBox.alert('提示', '合同生效后，供、需任何一方单方废止合同，应向对方支付相当于合同价款的违约金必须大于0');
                return false;
            }

            //我司标准合同且非标准条款，需填写其它约定事项

            var ContractType = checkedVaule("XRadioButtonList7");
            if (ContractType == "我司标准合同且非标准条款") {
                //非标准条款
                var aDivNonStandardClauses = document.getElementsByName("NonStandardClauses");

                for (var i = 0; i < aDivNonStandardClauses.length; i++) {
                    var div = aDivNonStandardClauses[i];
                    // console.log(s);
                    var id = div.getElementsByTagName('textarea')[0].id;
                    var v = document.getElementById(id).value;
                    if (v == "") {
                        Ext.MessageBox.alert("提示", "请输入其它约定事项");
                        return false;
                    }

                }
            }

            //供方、需方合同份数
            var SupplierContractScore = agent.Eles[document.getElementById("SupplierContractScore").getAttribute("xform_xele_index")].getValue();
            var DemanderContractScore = agent.Eles[document.getElementById("DemanderContractScore").getAttribute("xform_xele_index")].getValue();
            if (SupplierContractScore <= 0) {
                Ext.MessageBox.alert("提示", "请输入供方执合同份数");
                return false;
            }
            if (DemanderContractScore <= 0) {
                Ext.MessageBox.alert("提示", "请输入需方执合同份数");
                return false;
            }



        }

        //合同信息默认值
        function ContractInfoDefaultValue() {
            checkValue("ObjectionPeriod", "5");
            checkValue("DeliveryNotTime", "1");
            checkValue("SupplierToDemander", "0.1");
            checkValue("DemanderToSupplierDay", "1");
            checkValue("DemanderToSupplier", "0.1");
            checkValue("RescindContract", "30");
            checkValue("PerformanceContract", "30");
            //合同签订地点
            checkValue("XTextBox88", "北京");


            //合同份数
            var SupplierContractScore = getXValue("SupplierContractScore");
            var ContractScore = getXValue("ContractScore");
            if (ContractScore == "0") {
                setXValue("SupplierContractScore", "1");
                setXValue("DemanderContractScore", "1");
                setXValue("ContractScore", "2");
            }

        }

        function checkValue(id, val) {
            var v = getXValue(id);
            if (v == "") {
                setXValue(id, val);
            }
        }

        /*供应商直发选项控制*/
        function IsSupplierSend(BillingCompany, PurchasingPattern, PrchaseCurrency, IsSupplierSend) {
            //alert(BillingCompany);
            if (BillingCompany == "2000上海颐合") {
                if ((PurchasingPattern == "原厂采购" || PurchasingPattern == "非原厂采购") && PrchaseCurrency != "CNY" && PrchaseCurrency != "") {
                    return "直发";   //满足此条件 供应商直发设置为直发且不可修改，直发条件空白不可修改
                }
            }
            else if (PurchasingPattern == "备货") {
                return ""; //供应商直发、直发条件为空 且不可修改
            }
            else
                return IsSupplierSend;
        }

        //检查供应商直发控制
        function CheckSupplierSend() {
            var aDivIsSupplierSend = document.getElementsByName("IsSupplierSend");

            var aDivSupplierSendReason = document.getElementsByClassName("SupplierSendReason");
            var billingCompanys = agent.Eles[document.getElementById("XDropDownList5").getAttribute("xform_xele_index")].getValue(); //开票公司

            for (var i = 0; i < aDivSupplierSendReason.length; i++) {
                var div = aDivSupplierSendReason[i];
                // console.log(s);
                var id = div.getElementsByTagName('select')[0].id;
                var v = document.getElementById(id).value;

                var divIsSupplierSend = aDivIsSupplierSend[i];
                var idIsSupplierSend = divIsSupplierSend.getElementsByTagName('input')[0].name;
                var vIsSupplierSend = checkedVaule(idIsSupplierSend)
                // var vIsSupplierSend = document.getElementsByName(idIsSupplierSend)[1].value;

                //采购模式
                var aDivPurchasingPattern = document.getElementsByClassName("PurchasingPattern");
                var divPurchasingPattern = aDivPurchasingPattern[i];
                var idPurchasingPattern = divPurchasingPattern.getElementsByTagName('select')[0].id;
                var vPurchasingPattern = document.getElementById(idPurchasingPattern).value;
                //采购币种
                var aDivPrchaseCurrency = document.getElementsByClassName("PrchaseCurrency");
                var divPrchaseCurrency = aDivPrchaseCurrency[i];
                var idPrchaseCurrency = divPrchaseCurrency.getElementsByTagName('select')[0].id;
                var vPrchaseCurrency = document.getElementById(idPrchaseCurrency).value;

                if (vPurchasingPattern != "备货" && vPurchasingPattern != "") {

                    if ((billingCompanys == "2000上海颐合" || billingCompanys == "A300HOSIC 香港") && vPrchaseCurrency != "CNY" && vPrchaseCurrency != "" && vPurchasingPattern != "") {

                        if (vIsSupplierSend == "" || vIsSupplierSend == undefined) {

                            Ext.MessageBox.alert("提示", "请选择供应商直发");
                            return false;
                        }

                    } else {

                        if (vIsSupplierSend == "" || vIsSupplierSend == undefined) {

                            Ext.MessageBox.alert("提示", "请选择供应商直发");
                            return false;
                        }
                        if (vIsSupplierSend == "直发") {
                            if (v == "") {
                                //getLocationH(div, id, "select");
                                Ext.MessageBox.alert("提示", "请选择直发条件");
                                return false;
                            }
                        }
                    }
                }
            }

        }



        //判断是否需要预付审批(新供应商且预付款勾选为"是")
        function IsNeedAdvanceApp() {
            var aDivSupplierSAPID = document.getElementsByName("SupplierSAPID");
            var aDivIsAdvancePay = document.getElementsByClassName("IsAdvancePay");
            var aDivPurchasingPattern = document.getElementsByName("PurchasingPattern");
            var AdvancePayFlag = false;
            for (var i = 0; i < aDivSupplierSAPID.length; i++) {

                //是否勾选预付
                var divIsAdvancePay = aDivIsAdvancePay[i];
                // var idIsAdvancePay = divIsAdvancePay.getElementsByTagName('input')[0].id;
                var idIsAdvancePay = divIsAdvancePay.getElementsByTagName('input')[0].name;
                //var vIsAdvancePay = document.getElementById(idIsAdvancePay).checked;
                var vIsAdvancePay = checkedVaule(idIsAdvancePay);

                //新供应商
                var divSupplierSAPID = aDivSupplierSAPID[i];
                var idSupplierSAPID = divSupplierSAPID.getElementsByTagName('input')[0].id;
                var vSupplierSAPID = document.getElementById(idSupplierSAPID).value;

                //采购模式
                var divPurchasingPattern = aDivPurchasingPattern[i];
                var idPurchasingPattern = divPurchasingPattern.getElementsByTagName('select')[0].id;
                var vPurchasingPattern = document.getElementById(idPurchasingPattern).value;

                if (vIsAdvancePay == "1" && vSupplierSAPID == "" && vPurchasingPattern != "备货" && vPurchasingPattern != "") {
                    AdvancePayFlag = true;
                    break;
                }
            }

            return AdvancePayFlag;
        }

        //合同信息
        function getElementIdValue(name, i, htmltag) {
            var divs = document.getElementsByName(name);
            var div = divs[i];
            var id = div.getElementsByTagName(htmltag)[0].id;
            return document.getElementById(id).value;
        }

        //合同信息 查看
        function EditGenerationContract() {
            var me = this;
            var TaskID = getXValue("TaskID");
            //var bh = getXValue("XTextBox52");


            //供方信息：开票公司代码、合同联系人、手机号、联系电话
            var g_CompanyCode = getXValue("XTextBox16"),
                SupplierContractContact = getXValue("XTextBox40"),
                SupplierPhone = getXValue("XTextBox87"),
                SupplierTel = getXValue("XTextBox83"),

            //需方信息：公司、需方合同编号、合同联系人、联系电话、联系传真
                Demander = getXValue("XTextBox56"),
                DemanderContractNumber = getXValue("XTextBox52"),
                DemanderContractContact = getXValue("XTextBox82"),
                DemanderTel = getXValue("ContractTel"),
                DemanderPhone = getXValue("ContractPhone"),
                DemanderFax = getXValue("Fax"),

                Address = getXValue("XTextBox88"),  //     合同签订地点
                Rate = getXValue("XTextBox70"),//税率
                ObjectionPeriod = getXValue("ObjectionPeriod"),  //合同信息
                DeliveryNotTime = getXValue("DeliveryNotTime"),
                SupplierToDemander = getXValue("SupplierToDemander"),
                DemanderToSupplierDay = getXValue("DemanderToSupplierDay"),
                DemanderToSupplier = getXValue("DemanderToSupplier"),
                RescindContract = getXValue("RescindContract"),
                PerformanceContract = getXValue("PerformanceContract"),
                SupplierContractScore = getXValue("SupplierContractScore"),
                DemanderContractScore = getXValue("DemanderContractScore"),

            //付款条件Settlement
            //实际付款条件SettlementMethod
            Settlement = getXValue("Settlement"),
            SettlementMethod = getXValue("SettlementMethod");
            //供方收票信息

            //需方开票信息
            BankName = getXValue("BankName"),
            PaymentAddress = getXValue("PaymentAddress"),
            PaymentTaxNumber = getXValue("PaymentTaxNumber"),
            PaymentTel = getXValue("PaymentTel"),

            //签章日期
            DateSupplier = getXValue("DateSupplier"),
            DateDemander = getXValue("DateDemander"),

            setCookie("DateSupplier", DateSupplier);
            setCookie("DateDemander", DateDemander);
            setCookie("SupplierContractScore", SupplierContractScore);
            setCookie("DemanderContractScore", DemanderContractScore);
            setCookie("g_CompanyCode", g_CompanyCode);
            setCookie("SupplierContractContact", SupplierContractContact);
            setCookie("SupplierPhone", SupplierPhone);
            setCookie("SupplierTel", SupplierTel);

            setCookie("Demander", Demander);
            setCookie("DemanderContractNumber", DemanderContractNumber);
            setCookie("DemanderContractContact", DemanderContractContact);
            setCookie("DemanderTel", DemanderTel);
            setCookie("DemanderPhone", DemanderPhone);
            setCookie("DemanderFax", DemanderFax);

            setCookie("Address", Address);
            setCookie("Rate", Rate);
            setCookie("ObjectionPeriod", ObjectionPeriod);
            setCookie("DeliveryNotTime", DeliveryNotTime);
            setCookie("SupplierToDemander", SupplierToDemander);
            setCookie("DemanderToSupplierDay", DemanderToSupplierDay);
            setCookie("DemanderToSupplier", DemanderToSupplier);
            setCookie("RescindContract", RescindContract);
            setCookie("PerformanceContract", PerformanceContract);

            setCookie("Settlement", Settlement);
            setCookie("SettlementMethod", SettlementMethod);

            setCookie("BankName", BankName);
            setCookie("PaymentAddress", PaymentAddress);
            setCookie("PaymentTaxNumber", PaymentTaxNumber);
            setCookie("PaymentTel", PaymentTel);

            var rv = new Array();
            //合同产品信息
            var tableObj = document.getElementById('ctable');
            for (var i = 1; i < tableObj.rows.length ; i++) {

                productModel = agent.Eles[ctable.rows[i].cells[2].children[0].getAttribute("xform_xele_index")].getValue(); //产品型号
                productName = agent.Eles[ctable.rows[i].cells[1].children[0].getAttribute("xform_xele_index")].getValue();//产品名称
                manufacturer = agent.Eles[ctable.rows[i].cells[3].children[0].getAttribute("xform_xele_index")].getValue();//厂商
                unit = agent.Eles[ctable.rows[i].cells[4].children[0].getAttribute("xform_xele_index")].getValue();//单位
                number = agent.Eles[ctable.rows[i].cells[5].children[0].getAttribute("xform_xele_index")].getValue();//数量
                unitPrice = agent.Eles[ctable.rows[i].cells[6].children[0].getAttribute("xform_xele_index")].getValue();//单价
                totalPrice = agent.Eles[ctable.rows[i].cells[7].children[0].getAttribute("xform_xele_index")].getValue();//总价
                DeliveryDeadline = agent.Eles[ctable.rows[i].cells[8].children[0].getAttribute("xform_xele_index")].getValue();//交货期限
                DeliveryDeadlineDayOrWeek = agent.Eles[ctable.rows[i].cells[8].children[1].getAttribute("xform_xele_index")].getValue();//交货期限单位
                WarrantyPeriod = agent.Eles[ctable.rows[i].cells[9].children[0].getAttribute("xform_xele_index")].getValue();//保修期
                WarrantyPeriodOther = agent.Eles[ctable.rows[i].cells[9].children[1].getAttribute("xform_xele_index")].getValue();//保修期

                rv.push(
                    {
                        productModel: productModel, productName: productName, manufacturer: manufacturer, unit: unit, number: number, unitPrice: unitPrice, totalPrice: totalPrice,
                        DeliveryDeadline: DeliveryDeadline, DeliveryDeadlineDayOrWeek: DeliveryDeadlineDayOrWeek, WarrantyPeriod: WarrantyPeriod, WarrantyPeriodOther: WarrantyPeriodOther
                    });
            }
            //cookie记录产品信息值
            setCookie("rv", JSON.stringify(rv));


            //我司标准合同且非标准条款，其它事项
            var rvClauses = new Array();
            var tab = document.getElementById('tab_NonStandardClauses');
            var ContractType = checkedVaule("XRadioButtonList7");
            setCookie("ContractType", ContractType);//合同类型

            if (ContractType == "我司标准合同且非标准条款") {
                for (var i = 1; i < tab.rows.length ; i++) {
                    var v = agent.Eles[tab.rows[i].cells[1].children[0].getAttribute("xform_xele_index")].getValue();
                    rvClauses.push(
                  {
                      value: v
                  });
                }
                //cookie记录其它事项
                setCookie("rvClauses", JSON.stringify(rvClauses));
            }

            //var parm = {
            //    TaskID: TaskID
            //    //      rv: JSON.stringify(rv)
            //};

            //TaskID
            YZSoft.BPM.src.ux.FormManager.openFormApplication('30-销售/销售-易捷合同信息', TaskID, 'Read', Ext.apply({
                sender: "",
                title: '合同信息',
                //params: parm,
                dlgModel: 'Window',//Tab,Window,Dialog
                listeners: {
                    submit: function (action, data) {

                        ////从Cookie获取对应数据
                        //this.setXValue("SaveState", this.getCookie("savaState"));//合同状态
                        //this.setXValue("XTextBox179", this.getCookie("SettlementMethod"));//合同实际付款条件
                        //this.setXValue("XTextBox52", this.getCookie("DemanderContractNumber"));//需方合同编号

                    }
                }
            }, this.dlgCfg));
        };

        //获取cookie值
        function getCookie(name) {
            var arr, reg = new RegExp("(^| )" + name + "=([^;]*)(;|$)");
            if (arr = document.cookie.match(reg))
                return unescape(arr[2]);
            else
                return null;
        };

        //生成合同【正式合同盖章】
        function GenerationContract() {
            var TaskID = getXValue("TaskID");
            var ElectronicChapterType = checkedVaule("ElectronicChapterType");//是否盖电子章
           
            var FileType;

            //判断合同类型
            var ContractType = checkedVaule("XRadioButtonList7");
            if (ContractType == "客户合同模板") {
                //客户合同附件
                var id = document.getElementById("XAttachments1").getElementsByTagName("div")[2].id;
                var s = document.getElementById(id).getAttribute("filename");
                //文件后缀名
                FileType = getFileType(s);
                
            }

            var decode = "";

            var url = YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx');
            var parm = {
                method: "CreateYJContract",
                TaskID: TaskID,
                FileType: FileType,
                ContractType: ContractType
            };

            var res;
            AjaxParm(url, false, parm, function (action) {

                var obj = eval("(" + action.responseText + ")");
                //alert(obj.code);
                //alert(obj.objName);
                var code = obj.code;
                var Message = obj.Message;
                res = code
                if (code == 0) {//成功
                    var objName = obj.objName;
                    setXValue("ObjName", objName);
                }

            });
            return res;

        };

        //根据文件名获取文件后缀
        function getFileType(s) {
            var FileType = ""; //文件类型
            if (s != null) {
                //文件扩展名的正则表达式
                var patternFileExtension = /\.([0-9a-z]+)(?:[\?#]|$)/i;
                //获得文件扩展名
                var fileExtension = s.split('.').pop();

                var docx = s.lastIndexOf(".docx");
                var pdf = s.lastIndexOf(".pdf");
                var pdf1 = s.lastIndexOf(".PDF");
                var doc = s.lastIndexOf(".doc");

                if (fileExtension == "docx") {
                    FileType = "word";
                }
                else if (fileExtension == "pdf" || fileExtension == "PDF") {
                    FileType = "pdf";
                }
                else if (fileExtension == "doc") {
                    FileType = "doc";
                }
                return FileType;
            }
        };

        //【生成合同预览】 控制
        function btnBusinessApprovals() {
            //var code = this.GenerationContract();
            //return code;

            var TaskID = getXValue("TaskID");
            var FileType;
            if (TaskID == null || TaskID == "") {
                Ext.MessageBox.alert('提示', '未生成合同不允许预览');
                return false;
            }

            var ContractType = checkedVaule("XRadioButtonList7");
            if (ContractType == "客户合同模板") {
                Ext.MessageBox.alert('提示', '客户合同模板不允许预览');
                return false;
            }
           
            var url = YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx');
            YZSoft.src.ux.File.download(url, {
                method: 'CreateYJInformalContract',
                TaskID: TaskID,
                FileType: FileType,
                ContractType: ContractType
            });

        };


        //【查看合同】
        function ButtonGenerationContract() {

            var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');

            //aliOss文件路径
            var objName = getXValue("ObjName");
            //alert(objName);
            var parm = { method: "GetCreateContract", ObjName: objName };
            // alert(objName);
            AjaxParm(url, true, parm, function (action) {

                var obj = eval("(" + action.responseText + ")");
                var urls = obj.Value;
                window.open(urls, "_blank", "scrollbars=yes,resizable=1,modal=false,alwaysRaised=yes");
            })
        };
        //【下载合同】
        function DownGenerationContract() {
            var objName = getXValue("ObjName");
            var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');
            YZSoft.src.ux.File.download(url, {
                method: 'DownloadPDFBySalesTemplate',
                objName: objName
            });
        }

        function AjaxParm(url, async, parm, fun) {

            YZSoft.Ajax.request({
                async: async,
                url: url,
                params: parm,
                success: fun
            });
        };

        //单选获取选中的值
        function checkedVaule(name) {
            var obj = document.getElementsByName(name);
            for (var i = 0; i < obj.length; i++) {
                if (obj[i].checked) {
                    return obj[i].value;
                }
            }
        };

   
        //开票公司改变 控制合同模板选项
        function onchange_BillingCompany() {
            var SalesOrganizationCode = agent.Eles[document.getElementById("XTextBox16").getAttribute("xform_xele_index")].getValue();
            //  --开票公司为A300 或者2000时，默认为客户合同模板不可修改且 是否盖合同电子章为"否" 
            if (SalesOrganizationCode == "A300" || SalesOrganizationCode == "2000") {
                document.getElementById("XRadioButtonList7_1").checked = true;
                document.getElementById("ElectronicChapterType_1").checked = true;
                document.getElementById("trXAttachments1").style.display = "";
            }
                //开票公司是北京、上海、深圳、博德公司时，且选择我司合同模板。默认 是否盖合同电子章为"是"且可修改 AddDate:2020-04-16
            else if (SalesOrganizationCode == "1000" || SalesOrganizationCode == "1010" || SalesOrganizationCode == "1020" || SalesOrganizationCode == "2100") {
                if (document.getElementById("XRadioButtonList7_0").checked == true || document.getElementById("XRadioButtonList7_2").checked == true) {
                    //document.getElementById("XRadioButtonList7_1").checked = true;
                    document.getElementById("ElectronicChapterType_0").checked = true;
                    document.getElementById("trXAttachments1").style.display = "";
                }
            }
        }


        //非标准条款 记录到cookie值
        function GetNonStandardClauses(ContractType) {
            if (ContractType == "我司标准合同且标准条款" || ContractType == "客户合同模板") {
                var tbNonStandardClauses = agent.Eles[document.getElementById("NonStandardClauses").getAttribute("xform_xele_index")].getValue();

                var NonStandardClause = getCookie('NonStandardClauses');
                if (NonStandardClause == "") {
                    setCookie('NonStandardClauses', tbNonStandardClauses);
                }
                if (tbNonStandardClauses != "" && tbNonStandardClauses != NonStandardClause) {
                    setCookie('NonStandardClauses', tbNonStandardClauses);
                }
                return "";
            }
            if (ContractType == "我司标准合同且非标准条款") {
                var NonStandardClauses = getCookie('NonStandardClauses');

                return NonStandardClauses;

            }
        }

        //生成合同
        function generateContract(itemId, ContractAmount, EstimatedSalesAmount, ElectronicChapterType, FileType) {
            var url = YZSoft.$url('Oimec/ApiServices/CrmapiHandler.ashx');

            var parm = {
                method: "CreateContract",
                oppID: itemId,
                SalesLeadsID: SalesLeadsID,
                ContractAmount: ContractAmount,
                EstimatedSalesAmount: EstimatedSalesAmount,
                ElectronicChapterType: ElectronicChapterType,
                FileType: FileType
            };
            AjaxParm(url, false, parm, function (action) {

                var obj = eval("(" + action.responseText + ")");
                var code = obj.Code;
                var Message = obj.Message;

                if (code == 0) {//成功
                    var v = obj.Value;

                    // Ext.MessageBox.alert('提示', '合同生成成功');
                    //setTimeout(param.hide, 2000);
                    // document.getElementById("ButtonGenerationContract").style.display = "";
                    //  document.getElementById("DownGenerationContract").style.display = "";
                    decode = "0";
                } else {
                    // alert("ss");
                    // Ext.MessageBox.alert('提示', '' + Message + '');

                    //  return false;
                    decode = "1";
                }

            });

            return decode;
        };

        //设置cookie
        function setCookie(cname, cvalue) {
            document.cookie = cname + "=" + cvalue + ";";
        };

        //验证邮箱格式
        function EmailChange(txt, lab) {
            var email = getXValue(txt);
            reg = /^([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/gi;
            if (!reg.test(email)) {
                if (email == "") {
                    document.getElementById(lab).style.display = "none";
                } else {
                    document.getElementById(lab).style.display = "";
                    document.getElementById(lab).style.color = "red";
                }

            } else {
                document.getElementById(lab).style.display = "none";
            }
        }

        //验证手机格式
        function PhoneChange(txt, lab) {
            var value = getXValue(txt);
            var phones = value.split('/');

            for (var i = 0; i < phones.length; i++) {
                var tel = checkTel(phones[i], "1");
                yzLable(tel, lab);

            }
        };
        //验证座机格式
        function TelChange(txt, lab) {
            var value = getXValue(txt);

            var tel = checkTel(value, "0");
            yzLable(tel, lab);
        }

        function yzLable(tel, id) {
            if (!tel) {

                document.getElementById(id).style.display = "";
                document.getElementById(id).style.color = "red";

            } else {
                document.getElementById(id).style.display = "none";
                document.getElementById(id).style.color = "";
            }
        }

        /*
        ** 验证座机和手机
        ** zt=0 座机，zt=1 手机
        */
        function checkTel(value, zt) {
            //var isPhone = /^([0-9]{3,4}-)?[0-9]{7,8}$/;
            var isPhone = /^(\d{3,4}\-?)?\d{7,8}(\-\d{2,6})?$/ //验证座机号
            // var isPhone = /^([0-9]{3,4}-)?[0-9]{7,8}-?([0-9]{4})$/;
            var isMob = /^[1][3,4,5,6,7,8,9][0-9]{9}$/;  //验证手机号
            // var value=document.getElementById("ss").value.trim();
            if (value == "") {
                return true;
            }
            if (isMob.test(value) && zt == 1) {
                return true;
            } else if (isPhone.test(value) && zt == 0) {

                return true;
            }
            else {
                return false;
            }
        }


        function getXValue(id) {
            return agent.Eles[document.getElementById(id).getAttribute("xform_xele_index")].getValue();
        }

        function setXValue(id, value) {
            agent.Eles[document.getElementById(id).getAttribute("xform_xele_index")].setValue(value);
        }

    </script>

    <script>
        Ext.onReady(function () {
            document.getElementById("XDropDownList5").getElementsByTagName("select")[0].options[6].style.display = "none";
            var IsContractBusiness = checkedVaule("IsContractBusiness");
            //当前预审流程状态
            var ZhuangTai = agent.Eles[document.getElementById("XTextBox145").getAttribute("xform_xele_index")].getValue();
            var ObjName = agent.Eles[document.getElementById("ObjName").getAttribute("xform_xele_index")].getValue();
            if (IsContractBusiness == "是" && ZhuangTai == "业务员确认2") {
               GenerationContractPO();
            }
            var ObjName1 = agent.Eles[document.getElementById("ObjName").getAttribute("xform_xele_index")].getValue();
            
            if (IsContractBusiness == "是" && ObjName1 != "") {
                document.getElementById("trPO").style.display = "";
            } else {
                document.getElementById("trPO").style.display = "none";
            }
            var TaskID = agent.Eles[document.getElementById("TaskID").getAttribute("xform_xele_index")].getValue();
           
            if ((ZhuangTai != "业务员发起申请" && ZhuangTai != "业务员确认" && ZhuangTai != "业务员确认1"))
            {
                document.getElementsByName("XDataBrowserButton1")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton4")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton2")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserBtnPTP")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton3")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton9")[0].disabled = "disabled";
                document.getElementsByName("XDataBrowserButton6")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton5")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton10")[0].disabled = "disabled";
                document.getElementsByName("XDataBrowserButton7")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton1")[0].disabled = "disabled";
                document.getElementById("getinfo").disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton12")[0].disabled = "disabled";
                document.getElementsByName("XDataBrowserButton13")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton11")[0].disabled = "disabled";
                document.getElementsByName("XCustomBrowserButton6")[0].disabled = "disabled";
                document.getElementsByName("XDataBrowserButton8")[0].disabled = "disabled";
                document.getElementsByName("XDataBrowserButton10")[0].disabled = "disabled";
                document.getElementsByName("XRadioImmediateDelivery")[0].disabled = "disabled";
                document.getElementsByName("XRadioImmediateDelivery")[1].disabled = "disabled";
                document.getElementsByName("XRadioImmediateDelivery")[1].disabled = "disabled";
                document.getElementById("DeliveryWay").getElementsByTagName("select")[0].disabled = "disabled";
            }

             
          
        });

        //表单提交时进行数据及业务逻辑处理
        agent.on('beforeSubmit', function (actname1, actname) {
             

            //当前预审流程状态
            var ZhuangTai = agent.Eles[document.getElementById("XTextBox145").getAttribute("xform_xele_index")].getValue();
            var TaskID = agent.Eles[document.getElementById("XTextBox183").getAttribute("xform_xele_index")].getValue();

            //业务员发起申请，合同信息控制
            if ((ZhuangTai == "业务员发起申请" && actname == "提交") || (ZhuangTai == "业务员确认" && actname == "重新提交") || (ZhuangTai == "业务员确认1") || (ZhuangTai == "业务员确认2"))
            {
                //开票公司
                var XDropDownList5000 = agent.Eles[document.getElementById("XDropDownList5").getAttribute("xform_xele_index")].getValue();

                if (XDropDownList5000 != "A300HOSIC 香港" && XDropDownList5000 != "2000上海颐合") {

                    var XDropDownList4 = agent.Eles[document.getElementById("XDropDownList4").getAttribute("xform_xele_index")].getValue();
                    if (XDropDownList4!="") {
                        //业务分类
                        var aDivBusinessClassification = document.getElementsByName("BusinessClassification");
                        var BusinessClassificationflag = false;
                        var h = "";
                        for (var i = 0; i < aDivBusinessClassification.length; i++) {
                            var div = aDivBusinessClassification[i];
                            // console.log(s);
                            var id = div.getElementsByTagName('select')[0].id;
                            var v = document.getElementById(id).value;
                            if (v == "代理校准" || v == "其他服务" || v == "集成服务" || v == "带采购服务") {
                                BusinessClassificationflag = true;
                                if (h.indexOf(v) > -1) {
                                } else {
                                    h += v + ",";
                                }


                            } else {
                                h = "";
                                h = v;
                                BusinessClassificationflag = false;

                                break; //只要有一行不是 就return
                            }

                        }

                        if (BusinessClassificationflag) {
                            if (XDropDownList4 == "13%增值税专用发票" || XDropDownList4 == "13%增值税普通发票") {
                                Ext.MessageBox.alert("提示", "机会产品明细里,业务分类为:" + h + "时,税率必须是6%");
                                return false;
                            }
                        }
                        if (BusinessClassificationflag == false) {
                            if (XDropDownList4 == "6%增值税专用发票" || XDropDownList4 == "6%增值税普通发票") {
                                Ext.MessageBox.alert("提示", "机会产品明细里,业务分类为:" + v + "时,税率必须是13%");
                                return false;
                            }
                        }
                    }
                   
                   
                }
            }
            if (ZhuangTai == "业务员确认2" && actname == "已上传双方盖章后的PO") {

            }
        });

        ///判断行项目是不是全备货  

        function bhPurchasingPattern(PurchasingPattern) {
            var aDivPurchasingPattern = document.getElementsByName("PurchasingPattern");//采购模式
            var f = "";
            for (var i = 0; i < aDivPurchasingPattern.length; i++) {
                //厂商sapid
                var divPurchasingPattern = aDivPurchasingPattern[i];
                var idPurchasingPattern = divPurchasingPattern.getElementsByTagName('select')[0].id;
                var v = document.getElementById(idPurchasingPattern).value;

                if (v == "备货") {

                    f = "1";
                } else if (v == "") {
                    f = "";
                    break;
                } else{

                    f = "0";
                    break;
                }
            }
            return f;
        }

        //发运要求
        function checkSendRequire(str) {
            var flag = 0;
            //FYYQStyle(str);

            if (str != null && str != undefined && str != '') {

                if (str.indexOf("用户指定文件需要随货发运") != -1)
                    flag = 1;

            }
            return flag;
        }


        //验证座机和手机 zt 0 验证座机，1 验证手机
        function checkTel1(value, zt) {
           
            //var isPhone = /^([0-9]{3,4}-)?[0-9]{7,8}$/;
            var isPhone = /^(\d{3,4}\-?)?\d{7,8}(\-\d{2,6})?$/
            // var isPhone = /^([0-9]{3,4}-)?[0-9]{7,8}-?([0-9]{4})$/;
            var isMob = /^[1][3,4,5,6,7,8,9][0-9]{9}$/;
            // var value=document.getElementById("ss").value.trim();
            if (value=="") {
                return true;
            }
            if(isMob.test(value)&&zt==1){
                return true;
            } else if (isPhone.test(value) && zt == 0) {
             
                return true;
            }
            else {
                return false;
            }
        }


        //【生成我司PO预览】 控制
        function btnBusinessApprovalsPO() {
            //var code = this.GenerationContract();
            //return code;

            var TaskID = getXValue("TaskID");
            var FileType;
            if (TaskID == null || TaskID == "") {
                Ext.MessageBox.alert('提示', '未生成PO不允许预览');
                return false;
            }

            var ContractType = checkedVaule("XRadioButtonList1");
            if (ContractType == "客户PO") {
                Ext.MessageBox.alert('提示', '客户PO不允许预览');
                return false;
            }

            var url = YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx');
            YZSoft.src.ux.File.download(url, {
                method: 'CreateYJPO',
                TaskID: TaskID,
                FileType: FileType,
                ContractType: ContractType
            });

        };

        //生成PO【正式PO盖章】
        function GenerationContractPO() {
            var TaskID = getXValue("TaskID");
            var ElectronicChapterType = checkedVaule("ElectronicChapterType");//是否盖电子章

            var FileType;

            //判断合同类型
            var ContractType = checkedVaule("XRadioButtonList1");
            if (ContractType == "客户PO") {
                //客户合同附件
                var id = document.getElementById("XAttachments1").getElementsByTagName("div")[2].id;
                var s = document.getElementById(id).getAttribute("filename");
                //文件后缀名
                FileType = getFileType(s);

            }

            //
            var OurElectronicSeal = checkedVaule("OurElectronicSeal");//是否盖我司电子章
            
            var SalesOrganizationCodes = getXValue("XTextBox16");//我司开票公司
            var formNo = getXValue("XLabel3");//表单号
            var keyword = getXValue("KeyWordsSeal");//关键字
 
             
            var decode = "";

            var url = YZSoft.$url('Oimec/ApiServices/SalesAPIHandler.ashx');
            var parm = {
                method: "GetFormalYJPO",
                TaskID: TaskID,
                FileType: FileType,
                ContractType: ContractType,
                OurElectronicSeal: OurElectronicSeal,
                SalesOrganizationCodes: SalesOrganizationCodes,
                formNo: formNo,
                keyword: keyword
            };

            var res;
            AjaxParm(url, false, parm, function (action) {

                var obj = eval("(" + action.responseText + ")");
                if (obj=="1") {
                
                    alert("生成PO失败");
                    return false;
                }
                //alert(obj.code);
                //alert(obj.objName);
                console.log(obj)
                var code = obj.Code;
                var Message = obj.Message;
                res = code
                if (code == 0) {//成功
                    var objName = Message;
                    //console.log(objName)
                    setXValue("ObjName", objName);
                   
                }

            });
            return res;

        };

        function GetFZJG()
        {
            var DeliveryWay = agent.Eles[document.getElementById("DeliveryWay").getAttribute("xform_xele_index")].getValue();
            var FZJGZ = agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].getValue();
            
            if (DeliveryWay == "发货到客户" && FZJGZ == "发货到分支机构") {
                 alert("dd")
                agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].setValue("发货到客户");
              //  agent.Eles[document.getElementById("XTextBox195").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingContacts").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPhone").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("XTextBox193").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BranchID").getAttribute("xform_xele_index")].setValue("");//分支机构
                
                
            
            } else if (DeliveryWay == "发货到分支机构" && FZJGZ == "发货到客户") {
                agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].setValue("发货到分支机构");
                agent.Eles[document.getElementById("XTextBox195").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingContacts").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPhone").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BranchID").getAttribute("xform_xele_index")].setValue("");//分支机构
            } else if (DeliveryWay == "发货到分支机构" && FZJGZ == "") {
                
                agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].setValue("发货到分支机构");
                agent.Eles[document.getElementById("XTextBox195").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingContacts").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPhone").getAttribute("xform_xele_index")].setValue("");
            } else if (DeliveryWay == "发货到客户" && (FZJGZ == "")) {
                agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].setValue("发货到客户");
            } else if (DeliveryWay == "自提") {

                agent.Eles[document.getElementById("FZJGZ").getAttribute("xform_xele_index")].setValue("自提");
                agent.Eles[document.getElementById("XTextBox195").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingContacts").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("ReceivingPhone").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("XTextBox193").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BranchID").getAttribute("xform_xele_index")].setValue("");//分支机构
            }
            //DeliveryWay
            if (DeliveryWay == "发货到客户") {
            
                document.getElementById("txtFzjg").innerText = "客户收货地址信息：";
                
            } else if (DeliveryWay == "发货到分支机构") {
                document.getElementById("txtFzjg").innerText = "分支机构地址信息：";
            }
            //if (DeliveryWay == "发货到客户" && fzjg=="发货到分支机构") {
            //  alert("ff")
            //}
        }

        function GetMailTicket() {

            var DeliveryWay = agent.Eles[document.getElementById("MailTicketDropDownList").getAttribute("xform_xele_index")].getValue();
            var JPFS = agent.Eles[document.getElementById("JPFS").getAttribute("xform_xele_index")].getValue();
          
            if (DeliveryWay == "邮寄客户" && JPFS == "邮寄分支机构") {
                agent.Eles[document.getElementById("JPFS").getAttribute("xform_xele_index")].setValue("邮寄客户");
                agent.Eles[document.getElementById("BranchesDropDownList").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingContact").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPhone").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("XTextBox197").getAttribute("xform_xele_index")].setValue("");


            } else if (DeliveryWay == "邮寄分支机构" && JPFS == "邮寄客户") {
                agent.Eles[document.getElementById("JPFS").getAttribute("xform_xele_index")].setValue("邮寄分支机构");
                agent.Eles[document.getElementById("BranchesDropDownList").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingContact").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPhone").getAttribute("xform_xele_index")].setValue("");
            } else if (DeliveryWay == "邮寄分支机构" && JPFS == "") {

                agent.Eles[document.getElementById("JPFS").getAttribute("xform_xele_index")].setValue("邮寄分支机构");
                
                agent.Eles[document.getElementById("BranchesDropDownList").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingContact").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPhone").getAttribute("xform_xele_index")].setValue("");
            } else if (DeliveryWay == "邮寄客户" && (JPFS == "")) {
                agent.Eles[document.getElementById("JPFS").getAttribute("xform_xele_index")].setValue("邮寄客户");
            } else if (DeliveryWay == "自取") {

                agent.Eles[document.getElementById("BranchesDropDownList").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingAddress").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingContact").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingLandline").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPostcode").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingEmail").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("BillingPhone").getAttribute("xform_xele_index")].setValue("");
                agent.Eles[document.getElementById("XTextBox197").getAttribute("xform_xele_index")].setValue("");
            }
            //DeliveryWay
            //if (DeliveryWay == "发货到客户" && (fzjg == "发货到客户" || fzjg=="")) {

            //}
            //if (DeliveryWay == "发货到客户" && fzjg=="发货到分支机构") {
            //  alert("ff")
            //}
        }

        //立即出库
       // if (DF_SA_PTPClientMessage.IsContractBusiness != '是' || bhPurchasingPattern != '1', '', '')
        function getDelivery(IsContractBusiness, bhPurchasingPattern, IsImmediateDelivery) {
            if (IsImmediateDelivery == "是") {
                agent.Eles[document.getElementById("IsImmediateDelivery").getAttribute("xform_xele_index")].setValue("");
                return "是";
            } else if (IsImmediateDelivery == "否") {
                agent.Eles[document.getElementById("IsImmediateDelivery").getAttribute("xform_xele_index")].setValue("");
                return "否";
            } else {
                if (IsContractBusiness != "是" || bhPurchasingPattern != "1") {
                    return "";
                } else {
                    return "";
                }
            }
           
        }

        //出库方式
        function getDeliveryWay(IsContractBusiness,IsImmediateDelivery,DeliveryWay){
        
            if (DeliveryWay != "") {
                agent.Eles[document.getElementById("txtDeliveryWay").getAttribute("xform_xele_index")].setValue("");
                return DeliveryWay;
            } else {

                if (IsContractBusiness == "是" && IsImmediateDelivery == "否") {
                    return "";
                } else {
                    return "";
                }
            }
          
        }

        //获取收获公司

        function getPOUserCompanyName(DeliveryWay, PTPName, ysPOUserCompanyName, IsContractBusiness) {
            if (ysPOUserCompanyName != "") {
                
                var city = agent.Eles[document.getElementById("ysPOcity").getAttribute("xform_xele_index")].getValue("");
                agent.Eles[document.getElementById("XDropDownList47").getAttribute("xform_xele_index")].setValue(city);
                
                agent.Eles[document.getElementById("ysPOUserCompanyName").getAttribute("xform_xele_index")].setValue("");
                return ysPOUserCompanyName;
            }
            else {
                //if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay=="")) {

                    return PTPName;
              //  } else {
              //      return "";
               // }
            }
         
        }
        //收货联系人
        function getPOReceivingContacts(DeliveryWay, POReceivingContacts, ysPOReceivingContacts, IsContractBusiness) {
        
            if(ysPOReceivingContacts!=""){
                agent.Eles[document.getElementById("ysPOReceivingContacts").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingContacts;
            }else{
               // if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingContacts;
            
              //  }else{
               //     return "";
              //  }
            
            }
           
        
        }

        //
        //收货联系人地址
        function getPOReceivingAddress(DeliveryWay, POReceivingAddress, ysPOReceivingAddress, IsContractBusiness) {
        
            if (ysPOReceivingAddress != "") {
                agent.Eles[document.getElementById("ysPOReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingAddress;
            }else{
               // if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingAddress;
            
             //   }else{
             //       return "";
             //   }
            
            }
           
        
        }

        //收货联系人邮编
        function getPOReceivingPostcode(DeliveryWay, POReceivingPostcode, ysPOReceivingPostcode, IsContractBusiness) {
        
            if (ysPOReceivingPostcode != "") {
                agent.Eles[document.getElementById("ysPOReceivingAddress").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingPostcode;
            }else{
                //if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingPostcode;
            
               // }else{
              // //     return "";
              //  }
            
            }
           
        
        }

        //收货联系座机
        function getPOReceivingLandline(DeliveryWay, POReceivingLandline, ysPOReceivingLandline, IsContractBusiness) {
        
            if (ysPOReceivingLandline != "") {
                agent.Eles[document.getElementById("ysPOReceivingLandline").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingLandline;
            }else{
               // if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingLandline;
            
               // }else{
              //      return "";
              //  }
            
            }
           
        
        }
        //收货联系座机
        function getPOReceivingEmail(DeliveryWay, POReceivingEmail, ysPOReceivingEmail, IsContractBusiness) {
        
            if (ysPOReceivingEmail != "") {
                agent.Eles[document.getElementById("ysPOReceivingEmail").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingEmail;
            }else{
                //if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingEmail;
            
               // }else{
               //     return "";
               // }
            
            }
           
        
        }
        //收货联系座机
        function getPOReceivingPhone(DeliveryWay, POReceivingPhone, ysPOReceivingPhone, IsContractBusiness) {
        
            if (ysPOReceivingPhone != "") {
                agent.Eles[document.getElementById("ysPOReceivingPhone").getAttribute("xform_xele_index")].setValue("");
                return ysPOReceivingPhone;
            }else{
               // if (DeliveryWay == "发货到客户" || (IsContractBusiness == "是" && DeliveryWay == "")) {

                    return POReceivingPhone;
            
              //  }else{
              //      return "";
              //  }
            
            }
           
        
        }

        // 收货公司id
        function getPOCustomerID(DeliveryWay,ClientBPMID,ysPOCustomerID){
        
            if (ysPOCustomerID != "") {
                agent.Eles[document.getElementById("ysPOCustomerID").getAttribute("xform_xele_index")].setValue("");
                return ysPOCustomerID;
            }else{
               // if(DeliveryWay=="发货到客户" || DeliveryWay==""){

                    return ClientBPMID;
            
               // }else{
               //     return "";
               // }
            
            }
           
        
        }

        // 收货公司 分支机构
        function getUserCompanyName(DeliveryWay,PTPName,ysUserCompanyName){
        
            if (ysUserCompanyName != "") {
               var city= agent.Eles[document.getElementById("ysCity").getAttribute("xform_xele_index")].getValue();
               agent.Eles[document.getElementById("XDropDownList49").getAttribute("xform_xele_index")].setValue(city);
                agent.Eles[document.getElementById("ysUserCompanyName").getAttribute("xform_xele_index")].setValue("");
                return ysUserCompanyName;
            }else{
                if(DeliveryWay=="发货到客户" ){

                    return PTPName;
            
                }else{
                    return "";
                }
            
            }
           
        
        }
        // 收货公司id 分支机构
        function getCustomerID(DeliveryWay,ClientBPMID,ysCustomerID){
        
            if (ysCustomerID != "") {
                agent.Eles[document.getElementById("ysCustomerID").getAttribute("xform_xele_index")].setValue("");
                return ysCustomerID;
            }else{
                if(DeliveryWay=="发货到客户"  ||DeliveryWay=="" ){

                    return ClientBPMID;
            
                }else{
                    return "";
                }
            
            }
           
        
        }
  
        //更据厂商编号控制MENU
        function GetMenuByManufacturerID(ManufacturerID) {
              document.getElementById("OrderRequire").style.display = "none";
            var aDivManufacturerID = document.getElementsByName("ManufacturerID");  //报供应商最终用户
            for (var i = 0; i < aDivManufacturerID.length; i++) {
                //厂商sapid
                var divManufacturerID = aDivManufacturerID[i];
                var idManufacturerID = divManufacturerID.getElementsByTagName('input')[0].id;
                var v = document.getElementById(idManufacturerID).value;
                if (v == "103") {
                    document.getElementById("OrderRequire").style.display = "";

                    break;
                } else {
                     document.getElementById("OrderRequire").style.display = "none";
                   

                }

            }
          

        }
		
		 function Getplaceholder() {

            //省
            var aDivPOprovinceText = document.getElementsByName("POprovinceText");
            var aDivPOprovinceTextId = aDivPOprovinceText[0].getElementsByTagName('input')[0].id;
            var v = document.getElementById(aDivPOprovinceTextId).setAttribute("placeholder", "点【查询】选择");
            //市
            var aDivPOcityText = document.getElementsByName("POcityText");
            var aDivPOcityTextId = aDivPOcityText[0].getElementsByTagName('input')[0].id;
            var v = document.getElementById(aDivPOcityTextId).setAttribute("placeholder", "点【查询】选择");
			
			 //省
            var aDivprovinceText = document.getElementsByName("ProvinceText");
            var aDivprovinceTextId = aDivprovinceText[0].getElementsByTagName('input')[0].id;
            var v = document.getElementById(aDivprovinceTextId).setAttribute("placeholder", "点【查询】选择");

            //市
            var aDivcityText = document.getElementsByName("CityText");
            var aDivcityTextId = aDivcityText[0].getElementsByTagName('input')[0].id;
            var v = document.getElementById(aDivcityTextId).setAttribute("placeholder", "点【查询】选择");
            
        }
                          
    </script>

</head>
<body>
    <form runat="server">
        <!-- Insert content here -->
        <table width="1366" align="center" class="head" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td class="logo">
                    </td>
                    <td class="biaoti">
                        <asp:Label id="XLabel1" runat="server" text="易捷销售预审单" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox192" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="formstate"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox146" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.ExCode"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox165" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.ConfluenceNode">0</aspxform:XTextBox>
                        &nbsp;<aspxform:XTextBox id="itemid" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.ItemID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="TaskID" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.TaskID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="formstate" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="formstate"></aspxform:XTextBox>
                    </td>
                    <td class="formno">
                        <asp:Label id="XLabel2" runat="server" text="表单号：" valuetodisplaytext value></asp:Label>
                        <aspxform:XLabel id="XLabel3" runat="server" XDataBind="DF_SA_MarketInquiry.FormNo" ForeColor="White" BackColor="#8AB3DF" Value ValueToDisplayText Text="--系统自动生成--"></aspxform:XLabel>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <aspxform:XTextBox id="XTextBox133" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.EMDFilingLeaderBPMID" Height="20"></aspxform:XTextBox>
        <aspxform:XTextBox id="XTextBox134" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.ATBUFilingLeaderBPMID" Height="20"></aspxform:XTextBox>
        <aspxform:XTextBox id="XTextBox135" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.AIBUFilingLeaderBPMID" Height="20"></aspxform:XTextBox>
        <aspxform:XDropDownList id="XDropDownList14" runat="server" HiddenExpress="1" Height="20" DataMap="ATBUFilingLeaderBPMID->DF_SA_MarketInquiry.ATBUFilingLeaderBPMID;EMDFilingLeaderBPMID->DF_SA_MarketInquiry.EMDFilingLeaderBPMID;AIBUFilingLeaderBPMID->DF_SA_MarketInquiry.AIBUFilingLeaderBPMID" XDataSource="ProcedureName:proc_Df_sa_ss_FilingMessage;Filter:@BU->DF_SA_MarketInquiry.BU,@EachDistrict->DF_SA_MarketInquiry.EachDistrict" ValueColumn="EachDistrict" DisplayColumn="BU">
            <asp:ListItem>未绑定</asp:ListItem>
        </aspxform:XDropDownList>
        <aspxform:XRequiredFieldValidator id="请选择事业部" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择事业部" ControlToValidate="XDropDownList22"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择开票公司" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择开票公司" ControlToValidate="XDropDownList5"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择销售组织" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择销售组织" ControlToValidate="XDropDownList6"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择销售办公室" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择销售办公室" ControlToValidate="XDropDownList7"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择分销渠道" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择分销渠道" ControlToValidate="XDropDownList12"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择销售组织1" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择销售组织" ControlToValidate="XTextBox16"></aspxform:XRequiredFieldValidator>
        <aspxform:XTextBox id="XTextBox147" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.Approver" Height="20"></aspxform:XTextBox>
        <aspxform:XDropDownList id="XDropDownList38" runat="server" HiddenExpress="1" Height="20" DataMap="Approver->DF_SA_MarketInquiry.Approver" XDataSource="ProcedureName:PROC_DF_CreditControl;Filter:@ChannelOfDistribution->DF_SA_MarketInquiry.ChannelOfDistribution,@STPCustomerLevel->DF_SA_PTPClientMessage.PTPCustomerLevel,@TermsPayment->DF_SA_MarketInquiry.TermsPayment" ValueColumn="Approver" DisplayColumn="Approver">
            <asp:ListItem>未绑定</asp:ListItem>
        </aspxform:XDropDownList>
        <aspxform:XRequiredFieldValidator id="业务员信息没有维护" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="业务员信息没有维护，请在系统设置中进行维护,并在维护后重新选择业务员" ControlToValidate="XTextBox84"></aspxform:XRequiredFieldValidator>
        <table align="center" class="table" style="WIDTH: 1366px" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="32" align="left" class="title2" colspan="3">
                        <asp:Label id="XLabel191" runat="server" text="标记 * 的为业务员必填项" valuetodisplaytext value forecolor="Red" font-size="8pt"></asp:Label></td>
                    <td align="right" class="title3" colspan="3">
                        <aspxform:XDataBrowserButton id="XDataBrowserButton4" runat="server" Width="110px" Text="修改已结束预审单" Height="25px" DataMap="TaskID->DF_SA_MarketInquiry.BPMEndTaskID;FormNo->DF_SA_MarketInquiry.BPMEndForm" XDataSource="TableName:V_DF_SA_ReferringSingle;Filter:OwnerIDBPM->DF_SA_MarketInquiry.OwnerID;BufferType:RuntimeUpdate" DisplayColumns="FormNo:销售预审单号,100;CreateDate:创建日期,100;STPName:售达方客户名称,200;PTPName:付款方客户名称,200" AppendMode="ClearAndAppend"></aspxform:XDataBrowserButton>
                        <aspxform:XTextBox id="XTextBox183" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.TaskID" HiddenInput="true"></aspxform:XTextBox>
                       <%--SAPOrderNumber->DF_SA_MarketInquiry.SAPOrderNumber;--%>
                         <aspxform:XDropDownList id="XDropDownList44" runat="server"  HiddenExpress="1" DataMap="AssistantName->DF_SA_MarketInquiry.AssistantName;AssistantID->DF_SA_MarketInquiry.AssistantID;AssistantSAPID->DF_SA_MarketInquiry.AssistantSAPID;SalesmanID->DF_SA_MarketInquiry.SalesmanID;Salesman->DF_SA_MarketInquiry.Salesman;Review->DF_SA_MarketInquiry.Review;BU->DF_SA_MarketInquiry.BU;EachDistrict->DF_SA_MarketInquiry.EachDistrict;SAContractNo->DF_SA_MarketInquiry.SAContractNo;Owner->DF_SA_MarketInquiry.Owner;BillingCompany->DF_SA_MarketInquiry.BillingCompany;SalesOrganizationCode->DF_SA_MarketInquiry.SalesOrganizationCode;SalesOrganization->DF_SA_MarketInquiry.SalesOrganization;SalesOffice->DF_SA_MarketInquiry.SalesOffice;ProductLine->DF_SA_MarketInquiry.ProductLine;ChannelOfDistribution->DF_SA_MarketInquiry.ChannelOfDistribution;CustomerDeliveryDate->DF_SA_MarketInquiry.CustomerDeliveryDate;CustomerDeliveryWay->DF_SA_MarketInquiry.CustomerDeliveryWay;Exemption->DF_SA_MarketInquiry.Exemption;PaymentDays->DF_SA_MarketInquiry.PaymentDays;TaxType->DF_SA_MarketInquiry.TaxType;ContractCurrency->DF_SA_MarketInquiry.ContractCurrency;ExchangeRate->DF_SA_MarketInquiry.ExchangeRate;ContractAmount->DF_SA_MarketInquiry.ContractAmount;TaxLimit->DF_SA_MarketInquiry.TaxLimit;InvoiceType->InvoiceType;Quality->DF_SA_MarketInquiry.Quality;SIPBFdeduct->DF_SA_MarketInquiry.SIPBFdeduct;SIPBFdeductRMB->DF_SA_MarketInquiry.SIPBFdeductRMB;GrossMargin->DF_SA_MarketInquiry.GrossMargin;GrossProfitRate->DF_SA_MarketInquiry.GrossProfitRate;Remark->DF_SA_MarketInquiry.Remark;SUMPDSellingTotalvalueRest->DF_SA_MarketInquiry.SUMPDSellingTotalvalueRest;SUMNPDSellingTotalvalueRest->DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRest;SUMPDSellingTotalvalueRMB->DF_SA_MarketInquiry.SUMPDSellingTotalvalueRMB;SUMPDPurchaseTotalvalueRest->DF_SA_MarketInquiry.SUMPDPurchaseTotalvalueRest;SUMNPDSellingTotalvalueRMB->DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB;SUMNPDPurchaseTotalvalueRest->DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRest;SUMPDPurchaseTotalvalueRMB->DF_SA_MarketInquiry.SUMPDPurchaseTotalvalueRMB;SUMNPDPurchaseTotalvalueRMB->DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB;SalesEmployeeID->DF_SA_MarketInquiry.SalesEmployeeID;EMDFilingLeaderBPMID->DF_SA_MarketInquiry.EMDFilingLeaderBPMID;ATBUFilingLeaderBPMID->DF_SA_MarketInquiry.ATBUFilingLeaderBPMID;DescriptionExemption->DF_SA_MarketInquiry.DescriptionExemption;PaymentDaysExplanation->DF_SA_MarketInquiry.PaymentDaysExplanation;RebateGrossMargin->DF_SA_MarketInquiry.RebateGrossMargin;RebateGrossMarginString->DF_SA_MarketInquiry.RebateGrossMarginString;RetentionPaymentTerms->DF_SA_MarketInquiry.RetentionPaymentTerms;OtherCosts->DF_SA_MarketInquiry.OtherCosts;OtherFee->DF_SA_MarketInquiry.OtherFee;STPName->DF_SA_STPClientMessage.STPName;STPSapID->DF_SA_STPClientMessage.STPSapID;STPAccountsReceivable->DF_SA_STPClientMessage.STPAccountsReceivable;STPCustomerLevel->DF_SA_STPClientMessage.STPCustomerLevel;STPOverdueAccountsReceivableExplanation->DF_SA_STPClientMessage.STPOverdueAccountsReceivableExplanation;PTPName->DF_SA_PTPClientMessage.PTPName;PTPSapID->DF_SA_PTPClientMessage.PTPSapID;PTPAccountsReceivable->DF_SA_PTPClientMessage.PTPAccountsReceivable;PTPCustomerLevel->DF_SA_PTPClientMessage.PTPCustomerLevel;PTPOverdueAccountsReceivableExplanation->DF_SA_PTPClientMessage.PTPOverdueAccountsReceivableExplanation;IsRelatedCus->DF_SA_STPClientMessage.IsRelatedCus;IsRelatedCus2->DF_SA_PTPClientMessage.IsRelatedCus;ContractType->DF_SA_MarketInquiry.ContractType;ElectronicChapterType->DF_SA_MarketInquiry.ElectronicChapterType;ResponsibleContractsName->DF_SA_MarketInquiry.ResponsibleContractsName;ContractSex->DF_SA_MarketInquiry.ContractSex;ResponsibleContractsLandline->DF_SA_MarketInquiry.ResponsibleContractsLandline;ResponsibleContractsPhone->DF_SA_MarketInquiry.ResponsibleContractsPhone;ResponsibleEmail->DF_SA_MarketInquiry.ResponsibleEmail;Fax->DF_SA_MarketInquiry.Fax;IsNeedTaxNumber->DF_SA_MarketInquiry.IsNeedTaxNumber;PaymentTel->DF_SA_MarketInquiry.PaymentTel;NoTaxReason->DF_SA_MarketInquiry.NoTaxReason;PaymentAddress->DF_SA_MarketInquiry.PaymentAddress;PaymentTaxNumber->DF_SA_MarketInquiry.PaymentTaxNumber;BankAccount->DF_SA_MarketInquiry.BankAccount;BankName->DF_SA_MarketInquiry.BankName;NotesInvoice->DF_SA_MarketInquiry.NotesInvoice;LocationSignature->DF_SA_MarketInquiry.LocationSignature;ObjectionPeriod->DF_SA_MarketInquiry.ObjectionPeriod;DeliveryNotTime->DF_SA_MarketInquiry.DeliveryNotTime;SupplierToDemander->DF_SA_MarketInquiry.SupplierToDemander;DemanderToSupplierDay->DF_SA_MarketInquiry.DemanderToSupplierDay;DemanderToSupplier->DF_SA_MarketInquiry.DemanderToSupplier;RescindContract->DF_SA_MarketInquiry.RescindContract;PerformanceContract->DF_SA_MarketInquiry.PerformanceContract;SupplierContractScore->DF_SA_MarketInquiry.SupplierContractScore;DemanderContractScore->DF_SA_MarketInquiry.DemanderContractScore;SupplierPhone->DF_SA_MarketInquiry.SupplierPhone;SupplierTel->DF_SA_MarketInquiry.SupplierTel;DateDemander->DF_SA_MarketInquiry.DateDemander;DateSupplier->DF_SA_MarketInquiry.DateSupplier;Overdue15->DF_SA_MarketInquiry.Overdue15;IsImmediateDelivery->IsImmediateDelivery;DeliveryWay->DeliveryWay;POprovince->DF_SA_MarketInquiry.POprovince;POcity->ysPOcity;POUserCompanyName->ysPOUserCompanyName;POReceivingContacts->ysPOReceivingContacts;POReceivingAddress->ysPOReceivingAddress;POReceivingPostcode->ysPOReceivingPostcode;POReceivingLandline->ysPOReceivingLandline;POReceivingEmail->ysPOReceivingEmail;POReceivingPhone->ysPOReceivingPhone;ShippingRequirements->DF_SA_MarketInquiry.ShippingRequirements;ShippingRequirementsRemarks->DF_SA_MarketInquiry.ShippingRequirementsRemarks;OtherAttachment->DF_SA_MarketInquiry.OtherAttachment;CustomerIDPO->ysPOCustomerID;DeliveryBatch->DF_SA_MarketInquiry.DeliveryBatch;BatchdeliveryRemarks->DF_SA_MarketInquiry.BatchdeliveryRemarks;Branch->DF_SA_MarketInquiry.Branch;BranchID->DF_SA_MarketInquiry.BranchID;ReceivingPostcode->DF_SA_MarketInquiry.ReceivingPostcode;ReceivingLandline->DF_SA_MarketInquiry.ReceivingLandline;ReceivingEmail->DF_SA_MarketInquiry.ReceivingEmail;ReceivingPhone->DF_SA_MarketInquiry.ReceivingPhone;UserCompanyName->ysUserCompanyName;FZCustomerID->ysCustomerID;ReceivingAddress->DF_SA_MarketInquiry.ReceivingAddress;ReceivingContacts->DF_SA_MarketInquiry.ReceivingContacts;Province->DF_SA_MarketInquiry.Province;City->ysCity;MEUR->DF_SA_MarketInquiry.MEUR;MEURAttachments->DF_SA_MarketInquiry.MEURAttachments;MEURemarks->DF_SA_MarketInquiry.MEURemarks;MEURJudgingMaterials->DF_SA_MarketInquiry.MEURJudgingMaterials;" XDataSource="TableName:V_DF_SA_ReferringSingle;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID;BufferType:RuntimeUpdate" ValueColumn="TaskID" DisplayColumn="TaskID">
                            <asp:ListItem Selected="True">未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox145" runat="server" HiddenExpress="1" XDataBind="StepName" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" Express="Global.StepName"></aspxform:XTextBox>
                        <aspxform:XButton id="XButton2" runat="server" HiddenExpress="Global.StepName=='业务员发起预审'" Width="110px" Text="打印预审申请单" Height="25px" OnClientClick="aa1()" align="right"></aspxform:XButton>
                        <aspxform:XButton id="XButton1" runat="server" HiddenExpress="Global.StepName=='业务员发起预审'" Width="110px" Text="打印采购申请单" Height="25px" OnClientClick="aa()" align="right"></aspxform:XButton>
                    </td>
                </tr>
                <tr>
                    <td height="15" class="title1" colspan="6">
                        <asp:Label id="XLabel34" runat="server" text="基本信息" valuetodisplaytext value></asp:Label></td>
                </tr>
                <tr>
                    <td width="298" height="19" class="ts">
                        <asp:Label id="XLabel35" runat="server" text="创建用户" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox154" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.APPID"></aspxform:XTextBox>
                    </td>
                    <td width="178" class="ts1">
                        <aspxform:XTextBox id="XTextBox38" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.AppName" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td width="180" class="ts">
                        <asp:Label id="XLabel40" runat="server" text="创建日期" valuetodisplaytext value></asp:Label></td>
                    <td width="182" class="ts1">
                        <aspxform:XDateTimePicker id="XDateTimePicker1" style="WIDTH: 50%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.CreateDate" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XDateTimePicker>
                        <aspxform:XTextBox id="XTextBox96" runat="server" HiddenExpress="1" BorderWidth="1" Width="10px" XDataBind="dangqianyue" Express="javascript('GetDateTimeMothe',DF_SA_MarketInquiry.CreateDate)"></aspxform:XTextBox>
                    </td>
                    <td width="298" class="ts">
                        <asp:Label id="XLabel42" runat="server" text="重点复核" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XCheckBox id="XCheckBox1" runat="server" XDataBind="DF_SA_MarketInquiry.Review"></aspxform:XCheckBox>
                    </td>
                </tr>
                <tr>
                    <td height="26" class="ts">
                        <asp:Label id="XLabel36" runat="server" text="业务员" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox35" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20%" XDataBind="DF_SA_MarketInquiry.SalesmanID" ValueToDisplayText="TableName:DF_SA_SS_SalesPersonnel;FilterColumn:StaffID;DisplayColumn:StaffID" DataMap="StaffID->DF_SA_MarketInquiry.OwnerID;StaffName->DF_SA_MarketInquiry.Owner;SalesOffice->DF_SA_MarketInquiry.SalesOffice;ProductLine->BU;Region->DF_SA_MarketInquiry.EachDistrict;StaffSAPNumber->DF_SA_MarketInquiry.SalesEmployeeID;IsEasyJet->YJ"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox187" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="15px" XDataBind="YJ" Max="0" Min="0" ValueToDisplayText HiddenInput="True"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox40" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.Salesman" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XDataBrowserButton   id="XDataBrowserButton1" runat="server" Width="35px" Text="查询" DataMap="StaffID->DF_SA_MarketInquiry.SalesmanID;StaffName->DF_SA_MarketInquiry.Salesman;SalesOffice->DF_SA_MarketInquiry.SalesOffice;ProductLine->DF_SA_MarketInquiry.BU;Region->DF_SA_MarketInquiry.EachDistrict;StaffSAPNumber->DF_SA_MarketInquiry.SalesEmployeeID;IsEasyJet->YJ" XDataSource="ProcedureName:proc_DF_SD_PersonnelSearch;Filter:@bpmAccount->DF_SA_MarketInquiry.APPID" DisplayColumns="StaffName:姓名,;SalesOffice:销售办公室,"></aspxform:XDataBrowserButton>
                    </td>
                    <td class="ts" hidden="hidden">
                        <asp:Label id="XLabel38" HiddenExpress="1" runat="server" text="BU" valuetodisplaytext value></asp:Label>
                        <aspxform:XDropDownList  id="XDropDownList34" runat="server" HiddenExpress="1" DataMap="Name->DF_SA_MarketInquiry.BU;Value->DF_SA_MarketInquiry.ProductLine" XDataSource="TableName:V_DF_SA_SS_ProductLine;Filter:Value->BU" ValueColumn="Name" DisplayColumn="Name">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox128" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="BU"></aspxform:XTextBox>
                    </td>
                    <td class="ts1" hidden="hidden">
                        <aspxform:XTextBox id="XTextBox42" HiddenExpress="1" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.BU" BackColor="#E6F1F8" ValueToDisplayText DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="ts" hidden="hidden">
                        <asp:Label id="XLabel39" runat="server" HiddenExpress="1" text="所属地区" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1" hidden="hidden">
                        <aspxform:XTextBox id="XTextBox41" HiddenExpress="1" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.EachDistrict" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                     <td class="tsbottomlabel">
                        <asp:Label id="XLabel147" runat="server" text="*"   valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel111" runat="server" text="开票公司" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList5"  runat="server" Width="175px" XDataBind="DF_SA_MarketInquiry.BillingCompany" XDataSource="TableName:DF_SA_SS_Company;OrderBy:'CompanyCode';BufferType:RuntimeUpdate" ValueColumn="Company" DisplayColumn="Company" PromptText="--请选择--" onchange="onchange_BillingCompany()">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel164" runat="server" text="参照预审单号" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox167" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.BPMEndTaskID"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox166" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.BPMEndForm"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="ts" hidden="hidden">
                        <asp:Label id="XLabel41" runat="server" text="*" HiddenExpress="1" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel129" HiddenExpress="1" runat="server" text="事业部" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1" hidden="hidden">
                        <aspxform:XDropDownList id="XDropDownList22" HiddenExpress="1" runat="server" XDataBind="DF_SA_MarketInquiry.ProductLine" XDataSource="TableName:V_DF_SA_SS_ProductLine;Filter:OrderBy:'OrderID';BufferType:RuntimeUpdate" ValueColumn="Value" DisplayColumn="Name" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XLabel id="XLabel101" runat="server" HiddenExpress="1" XDataBind="chanpinxian" BackColor="#d4e4fe" Value ValueToDisplayText Text="产品线"></aspxform:XLabel>
                    </td>
                   <td class="ts">
                        <asp:Label id="XLabel149" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel94" runat="server" text="销售办公室" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList7" runat="server" Width="155px" XDataBind="DF_SA_MarketInquiry.SalesOffice" XDataSource="TableName:DF_SA_SS_SalesOffice;OrderBy:OrderID" ValueColumn="SalesOfficeID" DisplayColumn="SalesOffice" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel230" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel37" runat="server" text="销售组织" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList6" runat="server" Width="150px" XDataBind="DF_SA_MarketInquiry.SalesOrganization" XDataSource="TableName:V_DF_SA_SS_SalesOrganizing;Filter:CompanyName->DF_SA_MarketInquiry.BillingCompany" ValueColumn="SalesOrganization" DisplayColumn="SalesOrganization">
                            <asp:ListItem Selected="True">未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox16" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100px" XDataBind="DF_SA_MarketInquiry.SalesOrganizationCode" ValueToDisplayText DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XDropDownList id="XDropDownList11" runat="server" HiddenExpress="1" DataMap="SalesOrganizationCode->DF_SA_MarketInquiry.SalesOrganizationCode" XDataSource="ProcedureName:proc_DF_SA_SS_SalesOrganizing;Filter:@Company->DF_SA_MarketInquiry.BillingCompany,@SalesOrganization->DF_SA_MarketInquiry.SalesOrganization" ValueColumn="SalesOrganizationCode" DisplayColumn="SalesOrganizationCode">
                            <asp:ListItem Selected="True">未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomlabel">
                    </td>
                    <td class="tsbottomtext">
                    </td>
                </tr>
              
                <tr hidden="hidden">
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel231" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel112" runat="server" text="分销渠道" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList12" runat="server" XDataBind="DF_SA_MarketInquiry.ChannelOfDistribution" CellSpacing="0" CellPadding="0" RepeatDirection="Horizontal">
                            <asp:ListItem Selected="True" Value="30">易捷</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XLabel id="XLabel130" runat="server" HiddenExpress="1" XDataBind="fenxiaoqudao" BackColor="#d4e4fe" Value ValueToDisplayText Text="分销渠道"></aspxform:XLabel>
                    </td>
                    <td height="23" class="ts" hidden="hidden">
                        <asp:Label id="XLabel13" runat="server" text="拥有人" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox114" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.OwnerID" ValueToDisplayText="TableName:V_DF_SA_BPMSysOUs;FilterColumn:Account;DisplayColumn:Account" DataMap="UserAccount->DF_SA_MarketInquiry.AssistantID;DisplayName->DF_SA_MarketInquiry.AssistantName;AssistantSAPID->DF_SA_MarketInquiry.AssistantSAPID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox111" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.AssistantID" ValueToDisplayText></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox115" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.AssistantName"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox116" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.AssistantSAPID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox84" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.SalesEmployeeID"></aspxform:XTextBox>
                    </td>
                    <td class="ts1" hidden="hidden">
                        <aspxform:XTextBox id="XTextBox7" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.Owner" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                        <%--<aspxform:XDropDownList id="XDropDownList 35" runat="server" HiddenExpress="1" DataMap="Account->DF_SA_MarketInquiry.OwnerID;UserAccount->DF_SA_MarketInquiry.AssistantID;DisplayName->DF_SA_MarketInquiry.AssistantName;UserName->DF_SA_MarketInquiry.Owner;AssistantSAPID->DF_SA_MarketInquiry.AssistantSAPID" XDataSource="TableName:V_DF_SA_BPMSysOUs;Filter:Account->DF_SA_MarketInquiry.SalesmanID" ValueColumn="Account" DisplayColumn="Account">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>--%></td>
                    <td class="ts">
                    </td>
                    <td class="ts1">
                    </td>
                </tr>
            </tbody>
        </table>
        <%--<aspxform:XRequiredFieldValidator id="请选择应用环节" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" ControlToValidate="XDropDownList28" ErrorMessage="请选择应用环节" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>
        &nbsp;<aspxform:XRequiredFieldValidator id="请选择使用者" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" ControlToValidate="XDropDownList26" ErrorMessage="请选择使用者" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择热点" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" ControlToValidate="XDropDownList27" ErrorMessage="请选择热点" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择应用方向" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" ControlToValidate="XDropDownList24" ErrorMessage="请选择应用方向" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择应用方向1" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" ControlToValidate="XDropDownList25" ErrorMessage="请选择应用方向" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>
        <br /><table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="19" class="title1" colspan="4">
                        <asp:Label id="XLabel233" runat="server" text="交易属性" value valuetodisplaytext></asp:Label><asp:Label id="XLabel234" runat="server" text="标记 * 的为业务员必填项" value valuetodisplaytext forecolor="Red" font-size="8pt"></asp:Label>&nbsp;<asp:Label id="XLabel235" runat="server" text="标记 *  的为助理必填项" value valuetodisplaytext forecolor="Red" font-size="8pt"></asp:Label>
                        <aspxform:XCheckBox id="XCheckBox2" runat="server" XDataBind="DF_SA_MarketInquiry.OFYIJIE" Width="71px" Text="易捷" Express="if(DF_SA_MarketInquiry.ProductLine=='05',0,DF_SA_MarketInquiry.OFYIJIE)" DisableExpress="DF_SA_MarketInquiry.ProductLine=='05'"></aspxform:XCheckBox>
                    </td>
                </tr>
                <tr>
                    <td height="22" class="tsbottomlabel">
                        <asp:Label id="XLabel151" runat="server" text="*" value valuetodisplaytext forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel143" runat="server" text="应用环节" value valuetodisplaytext></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList28" runat="server" XDataBind="DF_SA_MarketInquiry.AppLink" Width="130px" XDataSource Express="javascript('ClearlyStateCRM',DF_SA_MarketInquiry.OFYIJIE,DF_SA_MarketInquiry.AppLink)" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" PromptText="--请选择--" PrintOut="False">
                            <asp:ListItem Value="1">研发</asp:ListItem>
                            <asp:ListItem Value="2">制造、生产</asp:ListItem>
                            <asp:ListItem Value="3">检测，监控，维修</asp:ListItem>
                            <asp:ListItem Value="4">教学</asp:ListItem>
                            <asp:ListItem Value="5">医用、治疗</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel154" runat="server" text="*" value valuetodisplaytext forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel141" runat="server" text="使用者" value valuetodisplaytext></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList26" runat="server" XDataBind="DF_SA_MarketInquiry.APPUser" XDataSource Express="javascript('ClearlyStateCRM',DF_SA_MarketInquiry.OFYIJIE,DF_SA_MarketInquiry.APPUser)" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" PromptText="--请选择--">
                            <asp:ListItem Value="1">科研人员</asp:ListItem>
                            <asp:ListItem Value="2">工程师</asp:ListItem>
                            <asp:ListItem Value="3">教师</asp:ListItem>
                            <asp:ListItem Value="4">学生</asp:ListItem>
                            <asp:ListItem Value="5">工人</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel155" runat="server" text="*" value valuetodisplaytext forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel142" runat="server" text="热点" value valuetodisplaytext></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList27" runat="server" XDataBind="DF_SA_MarketInquiry.Hotspot" Width="130px" XDataSource Express="javascript('ClearlyStateCRM',DF_SA_MarketInquiry.OFYIJIE,DF_SA_MarketInquiry.Hotspot)" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" PromptText="--请选择--">
                            <asp:ListItem Value="0">&lt;没有&gt;</asp:ListItem>
                            <asp:ListItem Value="1">LED</asp:ListItem>
                            <asp:ListItem Value="2">混动汽车（EHV）</asp:ListItem>
                            <asp:ListItem Value="3">物联网</asp:ListItem>
                            <asp:ListItem Value="4">新材料</asp:ListItem>
                            <asp:ListItem Value="5">轨道交通</asp:ListItem>
                            <asp:ListItem Value="6">智能电网</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel152" runat="server" text="*" value valuetodisplaytext forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel140" runat="server" text="应用方向" value valuetodisplaytext></asp:Label>
                        <aspxform:XTextBox id="XTextBox99" runat="server" XDataBind="DF_SA_MarketInquiry.AppDirection" Width="40%" BorderColor="#DCDCDC" BorderWidth="1" HiddenExpress="1" Express="javascript('Apply',DF_SA_MarketInquiry.APP1,DF_SA_MarketInquiry.APP2,DF_SA_MarketInquiry.APP4)"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList24" runat="server" XDataBind="DF_SA_MarketInquiry.APP1" Width="120px" XDataSource="TableName:DF_SA_SS_Apply;BufferType:RuntimeUpdate" DisplayColumn="Apply1" ValueColumn="Apply1" Express="javascript('ClearlyStateCRM',DF_SA_MarketInquiry.OFYIJIE,DF_SA_MarketInquiry.APP1)" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XDropDownList id="XDropDownList25" runat="server" XDataBind="DF_SA_MarketInquiry.APP2" Width="140px" HiddenExpress='DF_SA_MarketInquiry.APP1=="其他"||DF_SA_MarketInquiry.APP1=="材料"||DF_SA_MarketInquiry.APP1=="医疗仪器"||DF_SA_MarketInquiry.APP1=="教学/科研"||DF_SA_MarketInquiry.APP1=="装备"' XDataSource="TableName:DF_SA_SS_Apply;Filter:Apply1->DF_SA_MarketInquiry.APP1;BufferType:RuntimeUpdate" DataMap="OPPString->OPP" DisplayColumn="Apply2" ValueColumn="Apply2" Express="javascript('ClearlyStateCRM',DF_SA_MarketInquiry.OFYIJIE,DF_SA_MarketInquiry.APP2,APP2)" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox98" runat="server" XDataBind="DF_SA_MarketInquiry.APP4" Width="50%" BorderColor="#DCDCDC" BorderWidth="1" HiddenExpress='DF_SA_MarketInquiry.APP1!="其他"'></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox139" runat="server" XDataBind="OPP" Width="10px" BorderColor="#DCDCDC" BorderWidth="1" HiddenExpress="1"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel144" runat="server" text="OPP字符串" value valuetodisplaytext></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox97" runat="server" XDataBind="DF_SA_MarketInquiry.OPPString" Width="60%" BorderColor="#DCDCDC" BorderWidth="1" Express="javascript('CRMOppString',DF_SA_MarketInquiry.AppLink,DF_SA_MarketInquiry.APPUser,DF_SA_MarketInquiry.Hotspot,OPP,DF_SA_MarketInquiry.OFYIJIE)" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <aspxform:XDropDownList id="XDropDownList41" runat="server" XDataBind="APP2" HiddenExpress="1" XDataSource="TableName:V_DF_SA_ReferringSingle;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID;BufferType:RuntimeUpdate" DataMap="SAPOFSapID->DF_SA_STPClientMessage.SAPOFSapID;SAPOFAddress->DF_SA_STPClientMessage.SAPOFAddress;SAPOFEmail->DF_SA_STPClientMessage.SAPOFEmail;SAPOFName->DF_SA_STPClientMessage.SAPOFName;SAPOFDepartment->DF_SA_STPClientMessage.SAPOFDepartment;SAPOFContact->DF_SA_STPClientMessage.SAPOFContact;SAPOFTelephone->DF_SA_STPClientMessage.SAPOFTelephone;SAPOFPhone->DF_SA_STPClientMessage.SAPOFPhone;ClientCRMID->DF_SA_STPClientMessage.ClientCRMID;SAPOFAreaCode->DF_SA_STPClientMessage.SAPOFAreaCode;STPClientTag->DF_SA_STPClientMessage.STPClientTag;SAPOFExtCode->DF_SA_STPClientMessage.SAPOFExtCode;ClientBPMID->DF_SA_STPClientMessage.ClientBPMID" DisplayColumn="APP2" ValueColumn="APP2">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomtext">
                    </td>
                </tr>
            </tbody>
        </table>--%><%--<aspxform:XRequiredFieldValidator id="请填写销售机会名称" runat="server" DisableExpress="DF_SA_MarketInquiry.ProductLine=='05'" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写销售机会名称" ControlToValidate="XTextBox109"></aspxform:XRequiredFieldValidator>--%><%--        <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0" hiddenexpress="DF_SA_MarketInquiry.ProductLine=='05'">
            <tbody>
                <tr>
                    <td width="250">
                        <asp:Label id="XLabel222" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel206" runat="server" valuetodisplaytext value text="销售机会名称"></asp:Label>&nbsp;<aspxform:XCheckBox id="XCheckBox4" runat="server" Width="119px" XDataBind="DF_SA_MarketInquiry.IsImportOpp" Text="此单没有销售机会" Express="if(DF_SA_MarketInquiry.ProductLine=='05',1,DF_SA_MarketInquiry.IsImportOpp)" Font-Bold="True"></aspxform:XCheckBox>
                    </td>
                    <td width="650">
                        <aspxform:XTextBox id="XTextBox109" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.SalesOpportunities"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox171" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10" XDataBind="DF_SA_MarketInquiry.OpportunityID"></aspxform:XTextBox>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton6" runat="server" Width="150px" XClass="Oimec.Dialogs.SalesOpportunityButton" Text="导入销售机会" Height="25px" DataMap="OpportunityID->DF_SA_MarketInquiry.OpportunityID;OpportunityName->DF_SA_MarketInquiry.SalesOpportunities;CustomerName->DF_SA_STPClientMessage.STPName;ContactName->DF_SA_STPClientMessage.SAPOFContact;ContactMobile->DF_SA_STPClientMessage.SAPOFTelephone;ContactPhone->DF_SA_STPClientMessage.SAPOFPhone;ContactMail->DF_SA_STPClientMessage.SAPOFEmail;ContactDepart->DF_SA_STPClientMessage.SAPOFDepartment" Filter="AccountID->DF_SA_MarketInquiry.SalesmanID,BUName->DF_SA_MarketInquiry.BU" BeforePopupCallFunc="OppSearch" NavigateUrl="DFJC/Sales/Dialogs/OpportunityDlg.js" BrowserWindowType="AjaxPanel"></aspxform:XCustomBrowserButton>
                        <aspxform:XTextBox id="XTextBox127" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.SalesOpportunitiesID" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                </tr>
            </tbody>
        </table>--%>
        <br />
        <table width="1199" align="center" class="table" id="Table1" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="16" class="title1" colspan="6">
                        <asp:Label id="Label7" runat="server" text="销售跟进" valuetodisplaytext value></asp:Label></td>
                </tr>
                <tr>
                    <td class="ts">
                        <asp:Label id="XLabel45" runat="server" text="SAP报价单号" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox53" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.SAPOrderNumber" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <%--<asp:Label id="XLabel236" runat="server" valuetodisplaytext value text="* " forecolor="Red"></asp:Label>&nbsp;--%><asp:Label id="XLabel44" runat="server" text="SAP-SO号" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox48" style="WIDTH: 50%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.SONOPRNO" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XButton id="XButton3" runat="server" Text="更新SAP-SO" OnClientClick="GetSoInfoByFormNo()" DisableExpress="formstate!='Edit'"></aspxform:XButton>
                        <%--<asp:Label id="XLabel153" runat="server" valuetodisplaytext value text="助理回填" font-size="8pt" forecolor="Red"></asp:Label>--%>
                        <aspxform:XTextBox id="UpdateSoDate" runat="server" HiddenExpress="1" Width="120" XDataBind="DF_SA_MarketInquiry.UpdateSoDate"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                    </td>
                    <td class="ts1">
                    </td>
                </tr>
                <tr>
                    <td height="22" class="tsbottomlabel">
                        <aspxform:XLabel id="XLabel212" runat="server" XDataBind="diudanyuanyin" BackColor="#d4e4fe" Value ValueToDisplayText Text="丢单原因"></aspxform:XLabel>
                    </td>
                    <td class="tsbottomtext">
                        <aspxform:XDropDownList id="XDropDownList20" runat="server" XDataBind="DF_SA_MarketInquiry.LostReasonMain" XDataSource="TableName:V_DF_SA_SS_LostCause;" ValueColumn="Name" DisplayColumn="Name" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XDropDownList id="XDropDownList21" runat="server" Width="150px" XDataBind="DF_SA_MarketInquiry.LostReasonItem" XDataSource="TableName:V_DF_SA_SS_LostCause;Filter:Name->DF_SA_MarketInquiry.LostReasonMain" ValueColumn="Value" DisplayColumn="Value" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="tsbottomlabel">
                        <aspxform:XLabel id="XLabel239" runat="server" XDataBind="diudanyuanyin" BackColor="#d4e4fe" Value ValueToDisplayText Text="合同未签回原因"></aspxform:XLabel>
                    </td>
                    <td class="tsbottomtext" colspan="3">
                        <aspxform:XDropDownList id="XDropDownList40" runat="server" Width="160px" XDataBind="DF_SA_MarketInquiry.ContractNotSigned" DisableExpress="formstate!='Edit'" PromptText="--请选择--">
                            <asp:ListItem>订单取消</asp:ListItem>
                            <asp:ListItem>预审有变化，重新制作</asp:ListItem>
                            <asp:ListItem>其他</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox161" style="WIDTH: 30%" runat="server" HiddenExpress="DF_SA_MarketInquiry.ContractNotSigned !='其他'" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.OtherContractNotSigned"></aspxform:XTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <table width="1199" align="center" class="table" id="Table1" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="13" class="title1" colspan="6">
                        <asp:Label id="Label6" runat="server" text="客户信息" valuetodisplaytext value></asp:Label></td>
                </tr>
                <tr>
                    <td height="16" class="title1" colspan="6">
                        <asp:Label id="XLabel46" runat="server" text="售达方信息" valuetodisplaytext value font-size="14px"></asp:Label>&nbsp; 
                        <input id="STPButton" onclick="STPSAPIDCustomer()" type="button" value="售达方是否冻结" />
                            <aspxform:XTextBox ID="XTextBox164" HiddenExpress="1" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Express="javascript('stqdkh',DF_SA_MarketInquiryApparatusList.IsFlagSDF,DF_SA_MarketInquiryApparatusList.IsFlagFKF)" Width="100px"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="ts">
                        <asp:Label id="XLabel156" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel47" runat="server" text="售达方客户名称" valuetodisplaytext value></asp:Label> 
                        <aspxform:XDropDownList id="XDropDownList30" runat="server" HiddenExpress="1" DataMap="CustomerID->DF_SA_STPClientMessage.ClientBPMID;CustomerSAPID->DF_SA_STPClientMessage.STPSapID;IsFlag->DF_SA_MarketInquiry.IsFlag1;CusLeavel->DF_SA_STPClientMessage.STPCustomerLevel" XDataSource="ProcedureName:proc_DF_MasterData_Customer;Filter:@CustomerNameCH -> DF_SA_STPClientMessage.STPName,@CreateName -> DF_SA_MarketInquiry.OwnerID" ValueColumn="CustomerNameCH" DisplayColumn="CustomerNameCH">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox43" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="Gainsboro" XDataBind="DF_SA_STPClientMessage.STPName" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton4" runat="server" Width="35px" XClass="Oimec.Dialogs.SelCustomerButton" Text="查询" Height="25px" DataMap="CustomerID->BPMID;CustomerNameCH->DF_SA_STPClientMessage.STPName;CustomerSAPID->DF_SA_STPClientMessage.STPSapID;CusLeavel->DF_SA_STPClientMessage.STPCustomerLevel;IsRelatedCus->DF_SA_STPClientMessage.IsRelatedCus;IsFlag->DF_SA_MarketInquiry.IsFlag1" AppendMode="ClearAndAppend"></aspxform:XCustomBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton2" runat="server" Width="35px" XClass="Oimec.Dialogs.CustomerAddButton" Text="新建" Height="25px" Filter="SalesName->DF_SA_MarketInquiry.Salesman,SalesID->DF_SA_MarketInquiry.SalesmanID" BrowserWindowType="AjaxPanel"></aspxform:XCustomBrowserButton>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel48" runat="server" text="客户SapID" valuetodisplaytext value></asp:Label> 
                        <aspxform:XTextBox id="XTextBox124" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.ClientCRMID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox178" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.IsRelatedCus"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox123" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.ClientBPMID" Express="BPMID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="BPMID" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="BPMID"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox49" style="WIDTH: 70%" onpropertychange="STPSAPIDCustomer();" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.STPSapID"  ValueToDisplayText DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <aspxform:XLabel id="XLabel158" runat="server" HiddenExpress="1" ForeColor="Red" BackColor="#d4e4fe" Value ValueToDisplayText Text="*"></aspxform:XLabel>
                        <asp:Label id="XLabel54" runat="server" text="售达方客户等级" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox55" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.STPCustomerLevel" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr  hidden="hidden">
                    <td class="ts">
                        <asp:Label id="XLabel53" runat="server" text="售达方应收账款" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox54" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.STPAccountsReceivable" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel30" runat="server" text="超期应收账款" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox23" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.STPOverdueAccountsReceivable" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                        <input onclick="GetInfo()" type="button" value="更新" /></td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel22" runat="server" text="实体清单客户" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox105" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.IsFlag1" ValueToDisplayText="TableName:V_DF_Customer1;FilterColumn:CustomerID;DisplayColumn:IsFlag"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox106" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" Express="javascript('Flag1',DF_SA_MarketInquiry.IsFlag1)"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomtext">
                        <aspxform:XRadioButtonList id="XRadioButtonList3" name="XRadioButtonList3" runat="server" XDataBind="DF_SA_STPClientMessage.STPClientTag" DisableExpress="1" RepeatDirection="Horizontal">
                            <asp:ListItem Value="T">是</asp:ListItem>
                            <asp:ListItem Value="F">否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                    </td>
                </tr>
                <tr hidden="hidden">
                    <td height="14" class="tsbottomlabel">
                        <asp:Label id="XLabel207" runat="server" text="超期应收账款说明" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext" colspan="3">
                        <aspxform:XTextBox id="XTextBox140" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_STPClientMessage.STPOverdueAccountsReceivableExplanation"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                    </td>
                    <td class="tsbottomtext">
                    </td>
                </tr>
                <tr>
                    <td height="16" class="title1" colspan="6">
                        <asp:Label id="XLabel55" runat="server" text="付款方信息" valuetodisplaytext value font-size="14px"></asp:Label>&nbsp; 
                        <input id="PTPButton" onclick="PTPSAPIDCustomer()" type="button" value="付款方是否冻结" />
                    </td>
                </tr>
                <tr>
                    <td height="31" class="ts">
                        <asp:Label id="XLabel168" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel56" runat="server" text="付款方客户名称" valuetodisplaytext value></asp:Label> 
                        <aspxform:XDropDownList id="XDropDownList31" runat="server" HiddenExpress="1" DataMap="CustomerSAPID->DF_SA_PTPClientMessage.PTPSapID;IsFlag->DF_SA_MarketInquiry.IsFlag2" XDataSource="ProcedureName:proc_DF_MasterData_Customer;Filter:@CustomerNameCH -> DF_SA_PTPClientMessage.PTPName,@CreateName -> DF_SA_MarketInquiry.OwnerID" ValueColumn="CustomerNameCH" DisplayColumn="CustomerNameCH">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="Overdue30" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_PTPClientMessage.OFExtended"></aspxform:XTextBox>
                        <aspxform:XTextBox id="Overdue15" runat="server" HiddenExpress="1"  BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.Overdue15"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox56" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPName" Express="DF_SA_STPClientMessage.STPName" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserBtnPTP" runat="server" Width="35px" XClass="Oimec.Dialogs.SelCustomerButton" Text="查询" Height="25px" DataMap="CustomerID->DF_SA_PTPClientMessage.ClientBPMID;CustomerNameCH->DF_SA_PTPClientMessage.PTPName;CustomerSAPID->DF_SA_PTPClientMessage.PTPSapID;CusLeavel->DF_SA_PTPClientMessage.PTPCustomerLevel;IsRelatedCus->DF_SA_PTPClientMessage.IsRelatedCus;IsFlag->DF_SA_MarketInquiry.IsFlag2"></aspxform:XCustomBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton3" runat="server" Width="35px" XClass="Oimec.Dialogs.CustomerAddButton" Text="新建" Height="25px" Filter="SalesName->DF_SA_MarketInquiry.Salesman,SalesID->DF_SA_MarketInquiry.SalesmanID" BrowserWindowType="AjaxPanel"></aspxform:XCustomBrowserButton>
                    </td>
                    <td class="ts">
                       <asp:Label id="XLabel57" runat="server" text="客户SapID" valuetodisplaytext value></asp:Label> 
                        <aspxform:XTextBox id="XTextBox125" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_PTPClientMessage.ClientBPMID" Express="DF_SA_STPClientMessage.ClientBPMID"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox126" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_PTPClientMessage.ClientCRMID" Express="DF_SA_STPClientMessage.ClientCRMID"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox57" style="WIDTH: 70%" onpropertychange="PTPSAPIDCustomer();"  runat="server"   BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPSapID"  ValueToDisplayText Express="if(DF_SA_PTPClientMessage.PTPSapID=='',DF_SA_STPClientMessage.STPSapID,DF_SA_PTPClientMessage.PTPSapID)" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                      <asp:Label id="XLabel63" runat="server" text="付款方客户等级" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox63" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPCustomerLevel" Express="DF_SA_STPClientMessage.STPCustomerLevel" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel62" runat="server" text="付款方应收账款" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox62" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPAccountsReceivable" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel4" runat="server" text="超期应收账款" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox1" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPOverdueAccountsReceivable" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                        <input onclick="GetInfo2()" id="getinfo" type="button" value="更新" /></td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel27" runat="server" text="实体清单客户" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox107" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.IsFlag2" ValueToDisplayText="TableName:V_DF_Customer1;FilterColumn:CustomerID;DisplayColumn:IsFlag" Express="DF_SA_MarketInquiry.IsFlag1"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox108" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" Express="javascript('Flag2',DF_SA_MarketInquiry.IsFlag2)"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomtext">
                        <aspxform:XRadioButtonList id="XRadioButtonList4" name="XRadioButtonList4" runat="server" XDataBind="DF_SA_PTPClientMessage.PTPClientTag" Express="DF_SA_STPClientMessage.STPClientTag" DisableExpress="1" RepeatDirection="Horizontal">
                            <asp:ListItem Value="T">是</asp:ListItem>
                            <asp:ListItem Value="F">否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td height="14" class="tsbottomlabel">
                        <asp:Label id="XLabel208" runat="server" text="超期应收账款说明" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext" style="HEIGHT: 25px" colspan="3">
                        <aspxform:XTextBox id="XTextBox150" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_PTPClientMessage.PTPOverdueAccountsReceivableExplanation"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel244" runat="server" text="关联方客户" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XRadioButtonList id="XRadioButtonList5" runat="server" XDataBind="DF_SA_PTPClientMessage.IsRelatedCus" Express="DF_SA_STPClientMessage.IsRelatedCus" DisableExpress="1" RepeatDirection="Horizontal">
                            <asp:ListItem Value="是">是</asp:ListItem>
                            <asp:ListItem Value="否">否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td height="14" class="tsbottomlabel">
                        <asp:Label id="Label3" runat="server" text="信贷限额" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox185" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPCreditLimit" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="Label1" runat="server" text="信贷风险总额" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox184" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_PTPClientMessage.PTPCreditRiskTotal" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                     <asp:Label id="Label9" runat="server" text="签约业务" valuetodisplaytext value></asp:Label>
                    </td>
                    <td class="tsbottomtext">
                          <aspxform:XDropDownList id="XDropDownList37" runat="server"  HiddenExpress="1" DataMap="SignUpCustome->qyyw;FormContract->PoStyle;IsNeedsSeal->OurElectronicSeal;TermPayment->DF_SA_MarketInquiry.TermsPayment;TaxType->ysTaxType;InvoiceType->ysInvoiceType;Currency->DF_SA_MarketInquiry.ContractCurrency;" XDataSource="TableName:V_DF_SD_ContractedDistributor;Filter:CustomerSAPID->DF_SA_PTPClientMessage.PTPSapID;OrderBy:ByValidityContract desc" ValueColumn="CustomerNameCH" DisplayColumn="CustomerNameCH">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox runat="server" ID="ysInvoiceType"  HiddenExpress="1" XDataBind="ysInvoiceType"></aspxform:XTextBox>
                         <aspxform:XTextBox runat="server" ID="ysTaxType" HiddenExpress="1" XDataBind="ysTaxType"></aspxform:XTextBox>

                        
                         <aspxform:XTextBox  runat="server" HiddenExpress="1" XDataBind="qyyw"></aspxform:XTextBox>
                         <aspxform:XRadioButtonList id="IsContractBusiness" runat="server" XDataBind="DF_SA_PTPClientMessage.IsContractBusiness" Express="if(qyyw=='1'&&(DF_SA_MarketInquiry.SalesOrganizationCode!='2000'&&DF_SA_MarketInquiry.SalesOrganizationCode!='A300'),'是','否')"  DisableExpress="qyyw!='1'||Global.StepName!='业务员发起申请'|| (DF_SA_MarketInquiry.SalesOrganizationCode=='2000'||DF_SA_MarketInquiry.SalesOrganizationCode=='A300')" RepeatDirection="Horizontal">
                            <asp:ListItem Value="是">是</asp:ListItem>
                            <asp:ListItem Value="否">否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                        
                    </td>
                </tr>
            </tbody>
        </table>
        <aspxform:XLabel id="XLabel145" runat="server" HiddenExpress="1" XDataBind="gonggongkeyong" BackColor="#d4e4fe" Value ValueToDisplayText Text="公共可用" Height="20"></aspxform:XLabel>
        <aspxform:XRequiredFieldValidator id="售达方客户没有客户SAPID" runat="server" ValidationGroup="zhuli" Display="None" ErrorMessage="售达方客户没有客户SAPID,请发起SAP客户主数据申请" ControlToValidate="XTextBox49"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择红旗客户" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择红旗客户" ControlToValidate="XRadioButtonList3" DisableExpress="1"></aspxform:XRequiredFieldValidator>
        <%--SAP订单联系人--%><%--<aspxform:XRequiredFieldValidator id="请填写联系人" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写联系人" ControlToValidate="XTextBox83"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写联系电话" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写联系电话" ControlToValidate="XTextBox87"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写部门" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写部门" ControlToValidate="XDropDownList36"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写移动电话" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写移动电话" ControlToValidate="XTextBox87"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写联系地址" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写联系地址" ControlToValidate="XTextBox85"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写移动电话1" runat="server" ControlToValidate="XTextBox137" ErrorMessage="请填写分机号" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请填写Email" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写Email" ControlToValidate="XTextBox89"></aspxform:XRequiredFieldValidator>--%><%--SAP订单联系人 end--%>
        <aspxform:XRequiredFieldValidator id="请填写客户等级" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户等级" ControlToValidate="XTextBox55"></aspxform:XRequiredFieldValidator>
        <%--<aspxform:XRequiredFieldValidator id="请从CRM获取销售机会" runat="server" DisableExpress="DF_SA_MarketInquiry.OFYIJIE=='1'|| DF_SA_MarketInquiry.IsImportOpp=='1'|| DF_SA_MarketInquiry.ProductLine=='03'" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请从CRM获取销售机会" ControlToValidate="XTextBox171"></aspxform:XRequiredFieldValidator>--%><%--      <table width="1200" align="center" class="table" id="Table2" border="0" cellspacing="0" cellpadding="0" hiddenexpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='地区助理复核'&amp;&amp;Global.StepName!='地区经理审批'&amp;&amp;Global.StepName!='CSO审批'&amp;&amp;Global.StepName!='BU经理审批'&amp;&amp;Global.StepName!='业务员确认'&amp;&amp;formstate==''">
            <tbody>
                <tr>
                    <td height="19" class="title1" colspan="6">
                        <asp:Label id="XLabel81" runat="server" valuetodisplaytext value text="SAP订单联系人信息"></asp:Label>&nbsp;
                        <aspxform:XTextBox id="XTextBox138" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.SAPContactExmessage"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="ts">
                        <aspxform:XLabel id="XLabel160" runat="server" HiddenExpress="1" ForeColor="Red" BackColor="#d4e4fe" Value ValueToDisplayText Text="*"></aspxform:XLabel>
                        <asp:Label id="XLabel82" runat="server" valuetodisplaytext value text="售达方客户名称"></asp:Label>
                        <aspxform:XTextBox id="XTextBox164" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.SAPContactExmessageCode"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox82" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFName" Express="DF_SA_STPClientMessage.STPName" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel83" runat="server" valuetodisplaytext value text="联系人SapID"></asp:Label></td>
                    <td class="ts1" style="WIDTH: 25%">
                        <aspxform:XTextBox id="XTextBox86" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFSapID" DisableExpress="1"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel161" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel84" runat="server" valuetodisplaytext value text="联系人"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox83" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFContact"></aspxform:XTextBox>
                        <aspxform:XDataBrowserButton id="XDataBrowserButton9" runat="server" HiddenExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'&amp;&amp;Global.StepName!='地区助理复核'" Width="35px" Text="查询" Height="25px" DataMap="ContactName->DF_SA_STPClientMessage.SAPOFContact;ContactSAPID->DF_SA_STPClientMessage.SAPOFSapID;ContactTel->DF_SA_STPClientMessage.SAPOFPhone;ContactMobile->DF_SA_STPClientMessage.SAPOFTelephone;ContactEmail->DF_SA_STPClientMessage.SAPOFEmail;ContactDept->DF_SA_STPClientMessage.SAPOFDepartment;ContactAddr->DF_SA_STPClientMessage.SAPOFAddress" XDataSource="TableName:V_DF_MasterData_Contact;Filter:CustomerID->DF_SA_STPClientMessage.ClientBPMID,OwnerAccount->DF_SA_MarketInquiry.OwnerID" DisplayColumns="ContactName:联系人,60;ContactSAPID:联系人SapID,90;ContactTel:电话,100;ContactMobile:手机号,120;ContactEmail:邮箱,120;ContactAddr:地址,150;ContactDepart:部门描述,150"></aspxform:XDataBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton1" runat="server" HiddenExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='地区助理复核'" Width="35px" XClass="Oimec.Dialogs.SalesContactAddButton" Text="新建" Height="25px" DisableExpress='DF_SA_STPClientMessage.ClientBPMID ==  "" ' Filter="OwnerAccount->DF_SA_MarketInquiry.OwnerID,CustomerID->DF_SA_STPClientMessage.ClientBPMID" BrowserWindowType="AjaxPanel"></aspxform:XCustomBrowserButton>
                    </td>
                </tr>
                <tr>
                    <td class="ts">
                        <asp:Label id="XLabel165" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel85" runat="server" valuetodisplaytext value text="联系电话"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox136" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_STPClientMessage.SAPOFAreaCode" HiddenInput="true"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox87" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="150px" XDataBind="DF_SA_STPClientMessage.SAPOFPhone"></aspxform:XTextBox>
                        -
                        <aspxform:XTextBox id="XTextBox137" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_STPClientMessage.SAPOFExtCode"></aspxform:XTextBox>
                    </td>
                    <td height="14" class="ts">
                        <asp:Label id="XLabel162" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>
                        <aspxform:XLabel id="XLabel86" runat="server" XDataBind="BUMEN" BackColor="#d4e4fe" Value ValueToDisplayText Text="部门"></aspxform:XLabel>
                        <aspxform:XTextBox id="XTextBox141" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="Department"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox142" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_STPClientMessage.SAPOFDepartmentID"></aspxform:XTextBox>
                        <aspxform:XDropDownList id="XDropDownList37" runat="server" HiddenExpress="1" DataMap="Value->DF_SA_STPClientMessage.SAPOFDepartment" XDataSource="TableName:DF_DataSourceList;Filter:Type->BUMEN,Value->Department;BufferType:RuntimeUpdate" ValueColumn="Name" DisplayColumn="Name">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList36" runat="server" XDataBind="DF_SA_STPClientMessage.SAPOFDepartment" DataMap="Value->DF_SA_STPClientMessage.SAPOFDepartmentID" XDataSource="TableName:V_DF_SA_SS_DF_Department;BufferType:RuntimeUpdate" ValueColumn="Value" DisplayColumn="Name" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel166" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel87" runat="server" valuetodisplaytext value text="移动电话"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox88" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFTelephone"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel163" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel88" runat="server" valuetodisplaytext value text="联系地址"></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox85" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFAddress"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel167" runat="server" valuetodisplaytext value text="*" forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel89" runat="server" valuetodisplaytext value text="Email"></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox89" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_STPClientMessage.SAPOFEmail"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                    </td>
                    <td class="tsbottomtext">
                    </td>
                </tr>
            </tbody>
        </table>
        <br />--%>
        <aspxform:XRequiredFieldValidator id="付款方客户没有客户SAPID" runat="server" ValidationGroup="zhuli" Display="None" ErrorMessage="付款方客户没有客户SAPID,请发起SAP客户主数据申请" ControlToValidate="XTextBox57"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写客户名称" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户名称" ControlToValidate="XTextBox56"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择红旗客户1" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择实体清单客户" ControlToValidate="XRadioButtonList4"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写客户等级1" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请付款方填写客户等级" ControlToValidate="XTextBox63"></aspxform:XRequiredFieldValidator>
         <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator7" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="付款方应收账款不能为空，请点击更新按钮" ControlToValidate="XTextBox62"></aspxform:XRequiredFieldValidator>
        <br />
        <p>
            <aspxform:XLabel id="XLabel109" runat="server" HiddenExpress="1" XDataBind="var2" Value ValueToDisplayText Text="fukuantiaojian" Height="20"></aspxform:XLabel>
            <aspxform:XLabel id="XLabel114" runat="server" HiddenExpress="1" XDataBind="var3" Value ValueToDisplayText Text="shuizhong" Height="20"></aspxform:XLabel>
            <aspxform:XLabel id="XLabel115" runat="server" HiddenExpress="1" XDataBind="var4" Value ValueToDisplayText Text="fapiaoleixing" Height="20"></aspxform:XLabel>
            <aspxform:XLabel id="XLabel116" runat="server" HiddenExpress="1" XDataBind="var5" Value ValueToDisplayText Text="kaipiaogongsi" Height="20"></aspxform:XLabel>
        </p>
       
        <aspxform:XRequiredFieldValidator id="请填写客户交货方式" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户交货方式" ControlToValidate="XDropDownList8" DisableExpress='DF_SA_MarketInquiry.BillingCompany=="1000东方中科北京" || DF_SA_MarketInquiry.BillingCompany=="1010东方中科上海" ||DF_SA_MarketInquiry.BillingCompany=="1020东方中科深圳" || DF_SA_MarketInquiry.BillingCompany=="2100苏州博德"'></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写直发机场" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写直发机场" ControlToValidate="XTextBox29" DisableExpress=' DF_SA_MarketInquiry.CustomerDeliveryWay == "HOSIC送货到客户香港指定地点"||DF_SA_MarketInquiry.CustomerDeliveryWay == "客户到HOSIC办公室自提"||DF_SA_MarketInquiry.CustomerDeliveryWay == "客户到供应商处自提" || DF_SA_MarketInquiry.BillingCompany=="1000东方中科北京" || DF_SA_MarketInquiry.BillingCompany=="1010东方中科上海" ||DF_SA_MarketInquiry.BillingCompany=="1020东方中科深圳" || DF_SA_MarketInquiry.BillingCompany=="2100苏州博德"'></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写客户交货期" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户交货期" ControlToValidate="XDateTimePicker2"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写是否免税" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写是否免税" ControlToValidate="XRadioButtonList2" DisableExpress="DF_SA_MarketInquiry.ContractCurrency=='CNY'"></aspxform:XRequiredFieldValidator>
         <aspxform:XRequiredFieldValidator ID="请选择是否立即出货" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||bhPurchasingPattern!='1'" ValidationGroup="yewuyuan" ControlToValidate="XRadioImmediateDelivery" ErrorMessage="请选择是否立即出货" Display="None">请选择是否立即出货</aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator ID="请选择出库方式" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| DF_SA_MarketInquiry.IsImmediateDelivery!='是'" ValidationGroup="yewuyuan" ControlToValidate="DeliveryWay" ErrorMessage="请选择出库方式" Display="None">请选择出库方式</aspxform:XRequiredFieldValidator>
        
          <aspxform:XRequiredFieldValidator ID="请选择分支机构" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'  || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="XTextBox193" ErrorMessage="请选择分支机构" Display="None">请选择分支机构</aspxform:XRequiredFieldValidator>
 <aspxform:XRequiredFieldValidator ID="请选择收获公司名称" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="XTextBox195" ErrorMessage="请选择收货公司名称" Display="None">请选择收货公司名称</aspxform:XRequiredFieldValidator>
  <aspxform:XRequiredFieldValidator ID="请选择省" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="XDropDownList48" ErrorMessage="请选择省" Display="None">请选择省</aspxform:XRequiredFieldValidator>
   <aspxform:XRequiredFieldValidator ID="请选择市" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="XDropDownList49" ErrorMessage="请选择市" Display="None">请选择市</aspxform:XRequiredFieldValidator>

         <aspxform:XRequiredFieldValidator ID="请选择收货地址" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="ReceivingAddress" ErrorMessage="收货地址不能为空,请到客户主数据联系人下更新之后,请选择收货地址" Display="None">收货地址不能为空,请到客户主数据联系人下更新之后,请选择收货地址</aspxform:XRequiredFieldValidator>
       <aspxform:XRequiredFieldValidator ID="请填写联系人" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="ReceivingContacts" ErrorMessage="联系人不能为空,请到客户主数据联系人下更新之后,请重新查询填写联系人" Display="None">联系人不能为空,请到客户主数据联系人下更新之后,请重新查询填写联系人</aspxform:XRequiredFieldValidator>
       <%--<aspxform:XRequiredFieldValidator ID="请填写邮箱" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构') " ValidationGroup="yewuyuan" ControlToValidate="ReceivingEmail" ErrorMessage="Email不能为空,请到客户主数据联系人下更新之后,请重新查询填写Eamil" Display="None">Email不能为空,请到客户主数据联系人下更新之后,请重新查询填写Eamil</aspxform:XRequiredFieldValidator>--%>
       <aspxform:XRequiredFieldValidator ID="请填写座机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.ReceivingPhone!='' ||  (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="ReceivingLandline" ErrorMessage="座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机" Display="None">座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机</aspxform:XRequiredFieldValidator>
      <aspxform:XRequiredFieldValidator ID="请填写手机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.ReceivingLandline!='' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构')" ValidationGroup="yewuyuan" ControlToValidate="ReceivingPhone" ErrorMessage="手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机" Display="None">手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机</aspxform:XRequiredFieldValidator>
       
        <aspxform:XRequiredFieldValidator ID="请选择整单分批交货" runat="server" ForeColor="Red" DisableExpress=" bhPurchasingPattern!='0' " ValidationGroup="yewuyuan" ControlToValidate="DeliveryBatch" ErrorMessage="请选择整单/分批交货" Display="None">请选择整单/分批交货</aspxform:XRequiredFieldValidator>
      
         <aspxform:XRequiredFieldValidator ID="请填写分批交货备注" runat="server" ForeColor="Red" DisableExpress="DF_SA_MarketInquiry.DeliveryBatch!='分批'|| bhPurchasingPattern!='0' " ValidationGroup="yewuyuan" ControlToValidate="BatchdeliveryRemarks" ErrorMessage="请填写分批交货备注" Display="None">请填写分批交货备注</aspxform:XRequiredFieldValidator>
      
       <%--<aspxform:XRequiredFieldValidator ID="请选择发运要求" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" ControlToValidate="ShippingRequirements" ErrorMessage="请选择发运要求" Display="None">请选择发运要求</aspxform:XRequiredFieldValidator>--%>
      
         <aspxform:XRequiredFieldValidator ID="请上传其他附件" runat="server" ForeColor="Red" DisableExpress='varRequire!="1" || (DF_SA_MarketInquiry.DeliveryWay!="发货到分支机构"&amp;&amp;DF_SA_MarketInquiry.DeliveryWay!="发货到客户")' ValidationGroup="yewuyuan" ControlToValidate="OtherAttachment" ErrorMessage="请上传其他附件" Display="None">请上传其他附件</aspxform:XRequiredFieldValidator>
        
        <aspxform:XRequiredFieldValidator ID="请选择PO收货公司" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="XTextBox199" ErrorMessage="请选择客户收货地址信息下的收货公司名称" Display="None">请选择客户收货地址信息下的收货公司名称</aspxform:XRequiredFieldValidator>
    <aspxform:XRequiredFieldValidator ID="请选择PO收货地址" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="POReceivingAddress" ErrorMessage="请选择客户收货地址信息下的收货地址" Display="None">请选择客户收货地址信息下的收货地址</aspxform:XRequiredFieldValidator>
    <aspxform:XRequiredFieldValidator ID="请选择客户收货省" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')  ||(DF_SA_MarketInquiry.IsImmediateDelivery!='是')" ValidationGroup="yewuyuan" ControlToValidate="XDropDownList46" ErrorMessage="请选择客户收货省" Display="None">请选择客户收货省</aspxform:XRequiredFieldValidator>
   <aspxform:XRequiredFieldValidator ID="请选择客户收货市" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')  ||(DF_SA_MarketInquiry.IsImmediateDelivery!='是')" ValidationGroup="yewuyuan" ControlToValidate="XDropDownList47" ErrorMessage="请选择客户收货市" Display="None">请选择客户收货市</aspxform:XRequiredFieldValidator>
       
        <aspxform:XRequiredFieldValidator ID="请选择PO联系人" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="POReceivingContacts" ErrorMessage="请选择客户收货地址信息下的联系人" Display="None">请选择客户收货地址信息下的联系人</aspxform:XRequiredFieldValidator>
  <%--<aspxform:XRequiredFieldValidator ID="请填写PO邮箱" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="POReceivingEmail" ErrorMessage="请选择客户收货地址信息下的Email" Display="None">请选择客户收货地址信息下的Email</aspxform:XRequiredFieldValidator>--%>
   <aspxform:XRequiredFieldValidator ID="请填写PO座机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.POReceivingPhone!='' ||  (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="POReceivingLandline" ErrorMessage="座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机" Display="None">座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机</aspxform:XRequiredFieldValidator>
      <aspxform:XRequiredFieldValidator ID="请填写PO手机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.POReceivingLandline!='' || (DF_SA_MarketInquiry.DeliveryWay!='发货到客户')" ValidationGroup="yewuyuan" ControlToValidate="POReceivingPhone" ErrorMessage="手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机" Display="None">手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机</aspxform:XRequiredFieldValidator>
      
        <table width="1366" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="22" class="title1" colspan="6">
                        <asp:Label id="XLabel64" runat="server" text="发票信息" valuetodisplaytext value></asp:Label>&nbsp; 
                        <aspxform:XDropDownList id="XDropDownList42" runat="server" HiddenExpress="1" XDataBind="TermsPayment" DataMap="TermsPayment->DF_SA_MarketInquiry.TermsPayment;ActTermsPayment->DF_SA_MarketInquiry.ActTermsPayment" XDataSource="TableName:V_DF_SA_ReferringSingle;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID;BufferType:RuntimeUpdate" ValueColumn="TermsPayment" DisplayColumn="TermsPayment">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox168" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="InvoiceType"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td height="20" class="ts" style="WIDTH: 10%">
                        <asp:Label id="XLabel176" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel65" runat="server" text="付款条件" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1" colspan="3">
                        <aspxform:XDropDownList id="XDropDownList2" runat="server" Width="350px" XDataBind="DF_SA_MarketInquiry.TermsPayment" DataMap="Value->DF_SA_MarketInquiry.TermsPaymentID;CalValue->DF_SA_MarketInquiry.PaymentDays;Email->koukuanleixing" XDataSource="TableName:V_DF_SA_SS_PaymentTerms;Filter:ValueAssociate->'销售额';OrderBy:OrderID" ValueColumn="Name" DisplayColumn="Name" Express="TermsPayment" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认' || DF_SA_PTPClientMessage.IsContractBusiness=='是'" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox id="XTextBox90" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="100px" XDataBind="DF_SA_MarketInquiry.TermsPaymentID" Max="0" Min="0" BackColor="#E6F1F8" Value ValueToDisplayText HiddenInput="False" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox94" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10%" XDataBind="koukuanleixing"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel66" runat="server" text="账期" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox65" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="200px" XDataBind="DF_SA_MarketInquiry.PaymentDays" BackColor="#E6F1F8" DisableExpress="1" Format="type:number;.0"></aspxform:XTextBox>
                        天</td>
                </tr>
                <tr>
                    <td height="23" class="ts">
                        <asp:Label id="XLabel245" runat="server" text="合同实际付款条件" valuetodisplaytext value width="160"></asp:Label></td>
                    <td class="ts1" colspan="3">
                        <aspxform:XTextBox id="XTextBox179" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ActTermsPayment" Express="if(DF_SA_MarketInquiry.BPMEndForm=='',DF_SA_MarketInquiry.TermsPayment,DF_SA_MarketInquiry.ActTermsPayment)" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel213" runat="server" text="账期说明" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox151" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.PaymentDaysExplanation"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td height="22" class="ts">
                        <asp:Label id="XLabel177" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel67" runat="server" text="税种" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList3" runat="server" XDataBind="DF_SA_MarketInquiry.TaxType" XDataSource="TableName:DF_SA_SS_TaxRate;BufferType:RuntimeUpdate" ValueColumn="TaxType" DisplayColumn="TaxType" Express="javascript('ClearlyStateRate1',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.TaxType,ysTaxType)" DisableExpress="DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港'||DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel180" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel68" runat="server" text="发票类型" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList4"  runat="server" Width="155px" DataMap="TaxRate->TaxRate" XDataBind="DF_SA_MarketInquiry.InvoiceType" XDataSource="TableName:V_DF_DF_SA_SS_TaxRate;Filter:TaxType->DF_SA_MarketInquiry.TaxType;BufferType:RuntimeUpdate;OrderBy:ItemID DESC" ValueColumn="InvoiceType" DisplayColumn="InvoiceType" Express="javascript('ClearlyStateRate1',DF_SA_MarketInquiry.BillingCompany,InvoiceType,ysInvoiceType)" DisableExpress="DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港'||DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'" PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XTextBox HiddenExpress="1" runat="server" ID="TaxRate" XDataBind="TaxRate" Express="if(DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港'||DF_SA_MarketInquiry.BillingCompany=='2000上海颐合','%',TaxRate)" Width="100px"></aspxform:XTextBox>
                    </td>
                    <td class="ts" style="WIDTH: 10%">
                        <asp:Label id="XLabel182" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="XLabel69" runat="server" text="销售合同币种" valuetodisplaytext value font-bold="True"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList17" runat="server" XDataBind="DF_SA_MarketInquiry.ContractCurrency" XDataSource="TableName:V_DF_SA_SS_SalesCurrency;Filter:BufferType:RuntimeUpdate" ValueColumn="Name" DisplayColumn="Name" PromptText="--请选择--" Font-Bold="True">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XLabel id="XLabel132" runat="server" HiddenExpress="1" XDataBind="xiaoshoubizhong" Value ValueToDisplayText Text="销售币种"></aspxform:XLabel>
                    </td>
                </tr>
                <tr>
                    <td height="23" class="ts" style="WIDTH: 10%">
                        <asp:Label id="XLabel71" runat="server" text="税率" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox70" runat="server" BorderWidth="1px" BorderColor="Gainsboro" XDataBind="DF_SA_MarketInquiry.Rate" Max="0" Min="0" BackColor="#E6F1F8" Value ValueToDisplayText HiddenInput="False" Express="javascript('ClearlyStateRate',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.Rate)" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox15" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="shuilv" Express="javascript('GetRate',DF_SA_MarketInquiry.Rate)"></aspxform:XTextBox>
                        <aspxform:XDropDownList id="XDropDownList13" runat="server" HiddenExpress="1" DataMap="TaxRate->DF_SA_MarketInquiry.Rate" XDataSource="TableName:DF_SA_SS_TaxRate;Filter:TaxType->DF_SA_MarketInquiry.TaxType,InvoiceType->DF_SA_MarketInquiry.InvoiceType" ValueColumn="TaxRate" DisplayColumn="TaxRate">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                    <td class="ts" style="WIDTH: 15%">
                        <asp:Label id="Label2" runat="server" text="销售币种/人民币汇率" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox181" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ExchangeRate" BackColor="#E6F1F8" DisableExpress="1" Format="type:number;.4"></aspxform:XTextBox>
                    </td>
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel73" runat="server" text="合同总金额" valuetodisplaytext value font-bold="True"></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox72" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.ContractAmount" BackColor="#E6F1F8" Express="DF_SA_MarketInquiry.SUMPDSellingTotalvalueRest" DisableExpress="1" Format="type:currency;.2" Font-Bold="True" TextAlign="Right"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td height="22" class="tsbottomlabel">
                        <asp:Label id="XLabel75" runat="server" text="税额" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox74" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.TaxLimit" BackColor="#E6F1F8" Express="javascript('IFTaxLimit',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB,shuilv )" DisableExpress="1" Format="type:currency;pfx:￥;.2"></aspxform:XTextBox>
                    </td>
                    <td height="22" class="ts">
                        <asp:Label id="Label41" runat="server" text="需要付款方税号"></asp:Label></td>
                    <td class="ts1">
                        <%--<aspxform:XRadioButtonList id="XRadioButtonList9" runat="server" XDataBind="DF_SA_MarketInquiry.IsNeedTaxNumber" Express="javascript('disabelNeedTax',DF_SA_MarketInquiry.InvoiceType,DF_SA_MarketInquiry.IsNeedTaxNumber)" DisableExpress="javascript('.IsNeedTax',DF_SA_MarketInquiry.InvoiceType) " RepeatDirection="Horizontal" CellPadding="0" CellSpacing="0">--%>
                        <aspxform:XRadioButtonList id="XRadioButtonList9" runat="server" XDataBind="DF_SA_MarketInquiry.IsNeedTaxNumber" DisableExpress="Global.StepName!='业务员发起申请'" CellSpacing="0" CellPadding="0" RepeatDirection="Horizontal">
                            <asp:ListItem Selected="True" Value="1">是</asp:ListItem>
                            <asp:ListItem Value="0">否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                    </td>
                    <td class="ts">
                        <asp:Label id="Label45" runat="server" text="无需税号原因" hiddenexpress="DF_SA_MarketInquiry.IsNeedTaxNumber==1"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox85" style="WIDTH: 100%" runat="server" HiddenExpress="DF_SA_MarketInquiry.IsNeedTaxNumber==1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.NoTaxReason" DisableExpress="Global.StepName!='业务员发起申请'"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                    <td class="ts">
                        <asp:Label id="Label110" runat="server" text="付款方地址" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="PaymentAddress" style="WIDTH: 87%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.PaymentAddress" Express="javascript('getFKInfo',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiry.PaymentAddress)" BackColor="#E6F1F8" DisableExpress="javascript('FKInfoDisable',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID)"></aspxform:XTextBox>
                        <aspxform:XDataBrowserButton id="XDataBrowserButton5" runat="server" Text="查询" DataMap="BillingAddress->DF_SA_MarketInquiry.PaymentAddress;BillingTel->DF_SA_MarketInquiry.PaymentTel;BankName->DF_SA_MarketInquiry.BankName;BankAccount->DF_SA_MarketInquiry.BankAccount;SocialCreditCode->DF_SA_MarketInquiry.PaymentTaxNumber" XDataSource="TableName:V_DF_Partner_CusBillInfo;Filter:PartnerID->DF_SA_PTPClientMessage.ClientBPMID" DisplayColumns="BillingAddress:付款方地址;BillingTel:付款方电话;BankName:付款方开户行;BankAccount:付款方账号; " DisableExpress="Global.StepName!='业务员发起申请'"></aspxform:XDataBrowserButton>
                    </td>
                    <td class="ts">
                        <asp:Label id="Label107" runat="server" text="付款方电话" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="PaymentTel" style="WIDTH: 100%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.PaymentTel" Express="javascript('getFKInfo',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiry.PaymentTel)" BackColor="#E6F1F8" DisableExpress="javascript('FKInfoDisable',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID)"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="Label111" runat="server" text="付款方税号" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="PaymentTaxNumber" style="WIDTH: 100%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.PaymentTaxNumber" Express="javascript('getFKInfo',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiry.PaymentTaxNumber)" BackColor="#E6F1F8" DisableExpress="javascript('FKInfoDisable',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID)"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                    <td class="ts">
                        <asp:Label id="Label112" runat="server" text="付款方开户行" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="BankName" style="WIDTH: 100%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.BankName" Express="javascript('getFKInfo',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiry.BankName)" BackColor="#E6F1F8" DisableExpress="javascript('FKInfoDisable',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID)"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="Label113" runat="server" text="付款方账号" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="BankAccount" style="WIDTH: 100%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.BankAccount" Express="javascript('getFKInfo',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiry.BankAccount)" BackColor="#E6F1F8" DisableExpress="javascript('FKInfoDisable',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.PTPSapID)"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="Label108" runat="server" text="发票备注" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="NotesInvoice" style="WIDTH: 100%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.NotesInvoice" DisableExpress="Global.StepName!='业务员发起申请'"></aspxform:XTextBox>
                    </td>
                </tr>
               
            </tbody>
        </table>
        <aspxform:XRequiredFieldValidator id="请选择付款条件" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择付款条件" ControlToValidate="XDropDownList2"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择税种" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择税种" ControlToValidate="XDropDownList3" DisableExpress="DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港'||DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择发票类型" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择发票类型" ControlToValidate="XDropDownList4" DisableExpress="DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港'||DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择销售合同币种" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择销售合同币种" ControlToValidate="XDropDownList17"></aspxform:XRequiredFieldValidator>
       
          <%--<aspxform:XRequiredFieldValidator ID="请选择寄票方式" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| DF_SA_MarketInquiry.IsImmediateDelivery!='是'" ValidationGroup="yewuyuan" ControlToValidate="MailTicketDropDownList" ErrorMessage="请选择寄票方式" Display="None">请选择寄票方式</aspxform:XRequiredFieldValidator>--%>
       <%--  <aspxform:XRequiredFieldValidator ID="请选择收票地址" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' " ValidationGroup="yewuyuan" ControlToValidate="BillingAddress" ErrorMessage="收货地址不能为空,请到客户主数据联系人下更新之后,请选择收货地址" Display="None">收货地址不能为空,请到客户主数据联系人下更新之后,请选择收货地址</aspxform:XRequiredFieldValidator>
       <aspxform:XRequiredFieldValidator ID="请填写收票联系人" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'  " ValidationGroup="yewuyuan" ControlToValidate="BillingContact" ErrorMessage="联系人不能为空,请到客户主数据联系人下更新之后,请重新查询填写联系人" Display="None">联系人不能为空,请到客户主数据联系人下更新之后,请重新查询填写联系人</aspxform:XRequiredFieldValidator>
       <aspxform:XRequiredFieldValidator ID="请填写收票座机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' " ValidationGroup="yewuyuan" ControlToValidate="BillingEmail" ErrorMessage="Email不能为空,请到客户主数据联系人下更新之后,请重新查询填写Eamil" Display="None">Email不能为空,请到客户主数据联系人下更新之后,请重新查询填写Eamil</aspxform:XRequiredFieldValidator>
       <aspxform:XRequiredFieldValidator ID="请填写收票Email" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.BillingPhone!=''  " ValidationGroup="yewuyuan" ControlToValidate="BillingLandline" ErrorMessage="座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机" Display="None">座机不能为空,请到客户主数据联系人下更新之后,请重新查询填写座机</aspxform:XRequiredFieldValidator>
      <aspxform:XRequiredFieldValidator ID="请填写收票手机" runat="server" ForeColor="Red" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||DF_SA_MarketInquiry.BillingLandline!=''  " ValidationGroup="yewuyuan" ControlToValidate="BillingPhone" ErrorMessage="手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机" Display="None">手机不能为空,请到客户主数据联系人下更新之后,请重新查询填写手机</aspxform:XRequiredFieldValidator>
        --%>
         <%--<aspxform:XTextBox id="XTextBox51" runat="server" XDataBind="DF_SA_MarketInquiry.ExchangeRate" Width="20%" BorderColor="#DCDCDC" BorderWidth="1" HiddenExpress="1" Format="type:number;.4"></aspxform:XTextBox>--%>
        <aspxform:XDropDownList id="XDropDownList18" runat="server" HiddenExpress="1" Height="20" DataMap="ComputeRate->DF_SA_MarketInquiry.ExchangeRate" XDataSource="TableName:DF_SA_SS_ExchangeRate;Filter:ForeignCurrency->DF_SA_MarketInquiry.ContractCurrency" ValueColumn="ComputeRate" DisplayColumn="ComputeRate">
            <asp:ListItem>未绑定</asp:ListItem>
        </aspxform:XDropDownList>
        <aspxform:XDropDownList id="XDropDownList23" runat="server" HiddenExpress="1" Height="20" DataMap="ComputeRate->meiyuan" XDataSource="TableName:DF_SA_SS_ExchangeRate;Filter:ForeignCurrency->USD" ValueColumn="ComputeRate" DisplayColumn="ExchangeRate">
            <asp:ListItem>未绑定</asp:ListItem>
        </aspxform:XDropDownList>
        <aspxform:XLabel id="XLabel139" runat="server" HiddenExpress="1" XDataBind="USD" Value ValueToDisplayText Text="USD" Height="20"></aspxform:XLabel>
        <aspxform:XTextBox id="XTextBox95" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="meiyuan" Height="20"></aspxform:XTextBox>
        &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator15" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择付款方地址" ControlToValidate="PaymentAddress" DisableExpress="javascript('payAddress',DF_SA_MarketInquiry.InvoiceType,DF_SA_PTPClientMessage.IsContractBusiness)">请选择付款方地址</aspxform:XRequiredFieldValidator>
        <br />
        <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="14" class="title1" colspan="6">
                        <asp:Label id="XLabel76" runat="server" text="费用明细" valuetodisplaytext value></asp:Label>
                        <input class="inputbtn" id="btn_fymx" style="HEIGHT: 23px; WIDTH: 65px" onclick="div_ShowHidden('fymx');" type="button" size="46" value=▽展开 /></td>
                </tr>
            </tbody>
        </table>
        <div id="div_fymx">
            <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
                <tbody>
                    <tr>
                        <td class="ts2" style="WIDTH: 13%">
                            <asp:Label id="XLabel77" runat="server" text="账期扣款(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td width="83" class="ts21">
                            <aspxform:XTextBox id="XTextBox59" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.PaymentDaysCharge" BackColor="#E6F1F8" Express="(DF_SA_MarketInquiry.SUMPDSellingTotalvalueRMB - DF_SA_MarketInquiry.Quality) * koukuanleixing" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="ts2" style="WIDTH: 13%">
                            <asp:Label id="XLabel78" runat="server" text="进口关税(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td width="231" class="ts21">
                            <aspxform:XTextBox id="XTextBox66" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.ImportTariff" BackColor="#E6F1F8" Express="sum(guanshuixiaoji)+sum(DF_SA_MarketInquiryApparatusList.SUMIncreaseTariff)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="ts2" style="WIDTH: 13%">
                            <asp:Label id="XLabel80" runat="server" text="国际运保费(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="ts21">
                            <aspxform:XTextBox id="XTextBox67" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.InternationCIF" BackColor="#E6F1F8" Express="javascript('GetInfoFromTable1',DF_SA_MarketInquiryApparatusList.SourcingPurchasing,DF_SA_MarketInquiryApparatusList.InternationCIF,DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign )" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel2">
                            <asp:Label id="XLabel100" runat="server" text="银行费用(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox69" style="WIDTH: 70%" runat="server" BorderWidth="1px" BorderColor="Gainsboro" XDataBind="DF_SA_MarketInquiry.BankFee" Max="0" Min="0" BackColor="#E6F1F8" Value ValueToDisplayText HiddenInput="False" Express="javascript('OFHOSICBankFee',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.TermsPayment,DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB,DF_SA_MarketInquiryApparatusList.SourcingPurchasing)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomlabel2">
                            <asp:Label id="XLabel138" runat="server" text="SIP业务基金扣款(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox47" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.SIPBFdeductRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiry.SIPBFdeduct * DF_SA_MarketInquiry.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomlabel2">
                            <asp:Label id="XLabel148" runat="server" text="SIP业务基金扣款(销售币种)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox110" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.SIPBFdeduct" BackColor="#E6F1F8" Express="javascript('SIPdeduct',DF_SA_MarketInquiryApparatusList.BusinessClassification,DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRest)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right" Wrap="False"></aspxform:XTextBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel5">
                            <aspxform:XLabel id="XLabel216" runat="server" XDataBind="zhibaojinfukuantiaojian" BackColor="#d4e4fe" Value ValueToDisplayText Text="质保金付款条件"></aspxform:XLabel>
                            <aspxform:XTextBox id="XTextBox156" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.RetentionPaymentTermsSAPID"></aspxform:XTextBox>
                            <aspxform:XTextBox id="XTextBox157" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.DebitPoints"></aspxform:XTextBox>
                            <aspxform:XTextBox id="XTextBox158" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.RetentionDebitPoints"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomtext">
                            <aspxform:XDropDownList id="XDropDownList39" runat="server" Width="250px" XDataBind="DF_SA_MarketInquiry.RetentionPaymentTerms" DataMap="Value->DF_SA_MarketInquiry.RetentionPaymentTermsSAPID;Email->DF_SA_MarketInquiry.RetentionDebitPoints;LdType->DF_SA_MarketInquiry.DebitPoints" XDataSource="TableName:V_DF_SA_SS_PaymentTerms;Filter:ValueAssociate->'质保金'" ValueColumn="Name" DisplayColumn="Name" PromptText="--请选择--">
                                <asp:ListItem>未绑定</asp:ListItem>
                            </aspxform:XDropDownList>
                        </td>
                        <td class="tsbottomlabel2">
                            <asp:Label id="XLabel7" runat="server" text="质保金(人民币)" valuetodisplaytext value font-bold="False"></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox2" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.Quality" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomlabel2">
                            <asp:Label id="XLabel217" runat="server" text="质保金扣款(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox155" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.RetentionDebit" BackColor="#E6F1F8" Express="DF_SA_MarketInquiry.Quality * DF_SA_MarketInquiry.RetentionDebitPoints" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel">
                            <asp:Label id="XLabel79" runat="server" text="HOSIC手续费(人民币)" valuetodisplaytext value></asp:Label>
                            <aspxform:XTextBox id="XTextBox130" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.HOSICCost" Express="javascript('HOSICTransactionFee',DF_SA_MarketInquiry.CustomerDeliveryWay,DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB,meiyuan)"></aspxform:XTextBox>
                            <%--HOSIC接/送货运费--%>
                            <aspxform:XTextBox id="XTextBox131" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.HOSICFreightFee" Express="javascript('HOSICFreight',DF_SA_MarketInquiry.CustomerDeliveryWay,meiyuan)"></aspxform:XTextBox>
                            <%--香港国内运保费--%>
                            <aspxform:XTextBox id="XTextBox132" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiry.HOSICInsuranceFee" Express="javascript('HOSICTransportationInsurance',DF_SA_MarketInquiry.CustomerDeliveryWay,DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB,meiyuan,DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB)"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox9" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.HOSICFee" BackColor="#E6F1F8" Express="javascript('CountBankCost',DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB,DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.CustomerDeliveryWay,DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB,DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                       <td class="tsbottomlabel">
                            <asp:Label id="Label85" runat="server" text="AM业务基金扣款(销售币种)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox203" style="WIDTH: 70%" runat="server"  BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.NIdeduct" BackColor="#E6F1F8" Express="sum(varNI)" DisableExpress="1" Format="type:.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomlabel">
                            <asp:Label id="Label86" runat="server" text="AM业务基金扣款(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox204" style="WIDTH: 70%" runat="server"  BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.NIdeductRMB" BackColor="#E6F1F8" Express="sum(varNIRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                    </tr>
                    <tr>
                         <td class="tsbottomlabel2">
                            <asp:Label id="XLabel221" runat="server" text="其他费用(人民币)" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox159" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.OtherCosts" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                        </td>
                        <td class="tsbottomlabel">
                            <asp:Label id="XLabel238" runat="server" text="其他费用说明" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox160" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.OtherFee"></aspxform:XTextBox>
                        </td>
                        
                        <td class="tsbottomlabel">
                        </td>
                        <td class="tsbottomtext">
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
        <%--<aspxform:XRequiredFieldValidator id="请填写质保金" runat="server" ControlToValidate="XTextBox2" ErrorMessage="请填写质保金" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>--%>
        <aspxform:XLabel id="XLabel204" runat="server" HiddenExpress="1" XDataBind="WuLiaoZhuangTai" Value ValueToDisplayText Text="248" Height="20"></aspxform:XLabel>
        <br />
        <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td class="title1" colspan="4">
                        <asp:Label id="XLabel5" runat="server" text="毛利计算" valuetodisplaytext value></asp:Label></td>
                </tr>
                <tr>
                    <td class="ts">
                        <asp:Label id="XLabel6" runat="server" text="毛利(不含税)" valuetodisplaytext value font-bold="True"></asp:Label>
                        <aspxform:XTextBox id="XTextBox101" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="SumMaoLi" Express="sum(DF_SA_MarketInquiryApparatusList.GrossMargin)"></aspxform:XTextBox>
                        <aspxform:XTextBox id="XTextBox102" runat="server" HiddenExpress="1" BorderWidth="1px" BorderColor="Gainsboro" Width="10px" XDataBind="CustomsFees" Max="0" Min="0" Value ValueToDisplayText HiddenInput="False" Express="sum(DF_SA_MarketInquiryApparatusList.CustomsFees)"></aspxform:XTextBox>
                    </td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox50" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.GrossMargin" BackColor="#E6F1F8" Express="if(DF_SA_MarketInquiry.BillingCompany =='A300HOSIC 香港',SumMaoLi - DF_SA_MarketInquiry.PaymentDaysCharge -DF_SA_MarketInquiry.SIPBFdeductRMB -DF_SA_MarketInquiry.HOSICFee -DF_SA_MarketInquiry.InternationCIF - DF_SA_MarketInquiry.ImportTariff - CustomsFees + DF_SA_MarketInquiry.RebateGrossMargin - DF_SA_MarketInquiry.RetentionDebit - DF_SA_MarketInquiry.OtherCosts,SumMaoLi - DF_SA_MarketInquiry.PaymentDaysCharge -DF_SA_MarketInquiry.BankFee -DF_SA_MarketInquiry.SIPBFdeductRMB -DF_SA_MarketInquiry.HOSICFee -DF_SA_MarketInquiry.InternationCIF - DF_SA_MarketInquiry.ImportTariff - CustomsFees + DF_SA_MarketInquiry.RebateGrossMargin - DF_SA_MarketInquiry.RetentionDebit  - DF_SA_MarketInquiry.OtherCosts) " DisableExpress="1" Format="type:currency;pfx:￥;.2" Font-Bold="True" TextAlign="Right"></aspxform:XTextBox>
                    </td>
                    <td class="ts">
                        <asp:Label id="XLabel70" runat="server" text="毛利率" valuetodisplaytext value font-bold="True"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox58" style="WIDTH: 230px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="220px" XDataBind="DF_SA_MarketInquiry.GrossProfitRate" BackColor="#E6F1F8" Express="(DF_SA_MarketInquiry.GrossMargin / DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB) * 100" DisableExpress="1" Format="type:number;.2" Font-Bold="True" TextAlign="Right"></aspxform:XTextBox>
                        %</td>
                </tr>
                <tr>
                    <td height="18" class="ts5">
                        <asp:Label id="XLabel214" runat="server" text="预计返点毛利(人民币)" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox152" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.RebateGrossMargin" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                    </td>
                    <td class="ts5">
                        <asp:Label id="XLabel215" runat="server" text="返点毛利说明" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox153" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.RebateGrossMarginString"></aspxform:XTextBox>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomlabel" colspan="4">
                        <asp:Label id="XLabel74" runat="server" text="毛利计算公式" valuetodisplaytext value></asp:Label>
                        <aspxform:XTextBox id="XTextBox25" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="30%"></aspxform:XTextBox>
                        <aspxform:XLabel id="XLabel108" runat="server" HiddenExpress="1" XDataBind="var1" Value ValueToDisplayText Text="tablenew"></aspxform:XLabel>
                        <input id="button1" style="DISPLAY: none" onclick="GetInfoFromTable('tablenew')" type="button" value="获取行数" />
                        <input class="inputbtn" id="btn_mljs" style="HEIGHT: 23px; WIDTH: 65px" onclick="div_ShowHidden('mljs');" type="button" value=▽展开 /></td>
                </tr>
            </tbody>
        </table>
        <table width="1200" align="center" class="table" id="div_mljs" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td colspan="4">
                        <p>
                            <aspxform:XLabel id="XLabel121" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="A300HOSIC 香港"' BackColor="#d4e4fe" Value ValueToDisplayText Text="外币销售(HOSIC开票)、外币采购" Font-Size="Medium"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel33" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="A300HOSIC 香港"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="整单毛利(人民币)＝不含税销售总价(人民币) + 预计返点毛利(人民币) —不含税采购总价(人民币)—国际运保费(人民币)—HOSIC相关费用(人民币)—账期扣款(人民币) －质保金扣款(人民币) - AIBU维修基金扣款(人民币) －其他费用(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                        <p>
                            &nbsp;<aspxform:XLabel id="XLabel122" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' BackColor="#d4e4fe" Value ValueToDisplayText Text="外币销售(颐合开票)" Font-Size="Medium"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel60" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="整单毛利(人民币)＝行项目毛利汇总(人民币) + 预计返点毛利(人民币) －账期扣款(人民币)—银行费用(人民币) — SIP业务基金扣款（人民币）—国际运保费(人民币)－质保金扣款(人民币) - AIBU维修基金扣款(人民币)－其他费用(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel123" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' BackColor="#d4e4fe" Value ValueToDisplayText Text="外币采购：" Font-Size="Small"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel90" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="行项目毛利(人民币)＝不含税销售总价(人民币)—不含税采购总价(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel124" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' BackColor="#d4e4fe" Value ValueToDisplayText Text="人民币采购：" Font-Size="Small"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel120" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany!="2000上海颐合"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="行项目毛利(人民币)＝不含税销售总价(人民币)—不含税采购总价(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel125" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' BackColor="#d4e4fe" Value ValueToDisplayText Text="人民币销售(国内开票)" Font-Size="Medium"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel128" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="整单毛利(人民币)＝行项目毛利汇总(人民币) + 预计返点毛利(人民币) －账期扣款(人民币) — SIP业务基金扣款（人民币）—国际运保费(人民币)—关税(人民币)—报关杂费(人民币)－质保金扣款(人民币) - AIBU维修基金扣款(人民币)－其他费用(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel127" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' BackColor="#d4e4fe" Value ValueToDisplayText Text="人民币采购：" Font-Size="Small"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel99" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="行项目毛利(人民币)＝不含税销售总价(人民币)—不含税采购总价(人民币)" Font-Size="11pt"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel126" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' BackColor="#d4e4fe" Value ValueToDisplayText Text="外币采购：" Font-Size="Small"></aspxform:XLabel>
                        </p>
                        <p>
                            <aspxform:XLabel id="XLabel119" runat="server" HiddenExpress='DF_SA_MarketInquiry.BillingCompany=="2000上海颐合" || DF_SA_MarketInquiry.BillingCompany=="A300HOSIC 香港"' ForeColor="Blue" BackColor="#d4e4fe" Value ValueToDisplayText Text="行项目毛利(人民币)＝不含税销售总价(人民币)—不含税采购总价(人民币)" Font-Size="10.5pt"></aspxform:XLabel>
                        </p>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />
        <%--<table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="14" class="title1" colspan="4">
                        <asp:Label id="Label6" runat="server" valuetodisplaytext value text="厂商订货下单要求"></asp:Label>
                        <input class="inputbtn" id="btn_xdyq" style="HEIGHT: 23px; WIDTH: 65px" onclick="div_ShowHidden('xdyq')" type="button" size="46" value=▽展开 /></td>
                </tr>
            </tbody>
        </table>--%><%--     <div id="div_xdyq">
            <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
                <tbody>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px; TEXT-ALIGN: center">
                            <b>厂商</b></td>
                        <td class="tsbottomtext" style="WIDTH: 1080px; TEXT-ALIGN: center">
                            <b>厂商订货下单要求</b>
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            是德分销</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            1、是德分销下单(含人民币、外币)：需要提供最终用户的中、英文公司名称、英文地址<br />
                            2、教育折扣订单：需要提供给用户的报价单、教育证明<br />
                            3、特折订单：是德工程师审批邮件、特折申请表
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            是德直销</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            1、厂商销售人员名<br />
                            2、三方盖章表
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            TEK&amp;FLUKE</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            1、TEK &amp; FLUKE 人民币、外币采购必须需要提供厂商销售人员名<br />
                            2、TEK 人民币采购直销、分销的特折下单需要提供最终用户中文名称<br />
                            3、TEK 人民币采购使用教育折扣的订单需要提供东方中科与学校合同（要与报备相同）<br />
                            4、TEK &amp; Fluke 外币采购需要提供免表预计办好日期、用户需求货期，说明。以便TEK公司外币入单类型由免表预计办好日期决定，Fluke公司外币入单时，要求免表已办好。
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            B&amp;K</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            需要提供最终用户的中、英文公司名称、用户联系人
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            AMTEK</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            需要提供最终用户中、英文公司名称、地址、用户联系人及用户电话
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            NF</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            需要提供最终用户信息表（NF报备表格——上传固定模板Excel表）
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            日置</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            直销：需要提供最终用户中文名称、用户联系人及用户电话<br />
                            分销（如果最终用户是二级代理商时）：需要提供二级代理商名称、代理商联系人、代理商电话、最终用户名称、最终用户联系人及电话
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            菊水</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            需要提供最终用户中文名称、厂商销售人员名
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            大华</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            需要提供厂商报备单号
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomlabel" style="WIDTH: 120px">
                            艾德克斯</td>
                        <td class="tsbottomtext" style="WIDTH: 1080px">
                            跨区销售需要提供最终用户中文名称
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>--%>
        <aspxform:XTextBox id="XTextBox172" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="88px" XDataBind="varSumSalesAmount" Max="0" Min="0" Value ValueToDisplayText Height="20" HiddenInput="true" Express="DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB*0.1"></aspxform:XTextBox>
        <aspxform:XTextBox id="XTextBox175" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="88px" XDataBind="varSumSalesAmount" Max="0" Min="0" Value ValueToDisplayText Height="20" HiddenInput="true" Express="DF_SA_MarketInquiry.SUMPDSellingTotalvalueRMB"></aspxform:XTextBox>
        <div id="dnew" style="TEXT-ALIGN: center" runat="server">
            <div class="scrollDiv" id="scrollDiv" style="HEIGHT: auto; MARGIN: 0px auto; MAX-HEIGHT: 600px">
                <table width="6000" align="center" class="scrolltable" id="tablenew" border="0" runat="server" menudock="Left" dynamicarea="2,1" xdatasource="TableName:DF_SA_MarketInquiryApparatusList;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID;BufferType:RuntimeUpdate" datamap="BusinessClassification->DF_SA_MarketInquiryApparatusList.BusinessClassification;MaterialType->DF_SA_MarketInquiryApparatusList.MaterialType;ProductModel->DF_SA_MarketInquiryApparatusList.ProductModel;ProductNmae->DF_SA_MarketInquiryApparatusList.ProductNmae;MaterialID->DF_SA_MarketInquiryApparatusList.MaterialID;ManufacturerID->DF_SA_MarketInquiryApparatusList.ManufacturerID;Manufacturer->DF_SA_MarketInquiryApparatusList.Manufacturer;Number->DF_SA_MarketInquiryApparatusList.Number;PDSellingPriceRest->DF_SA_MarketInquiryApparatusList.PDSellingPriceRest;PDSellingTotalvalueRest->DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRest;NPDSellingTotalvalueRest->DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRest;PDSellingPriceRMB->DF_SA_MarketInquiryApparatusList.PDSellingPriceRMB;PDSellingTotalvalueRMB->DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRMB;NPDSellingTotalvalueRMB->DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRMB;PurchaseNumber->DF_SA_MarketInquiryApparatusList.PurchaseNumber;PDPurchasePriceRest->DF_SA_MarketInquiryApparatusList.PDPurchasePriceRest;PDPurchaseTotalvalueRest->DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRest;NPDPurchaseTotalvalueRest->DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRest;PDPurchasePriceRMB->DF_SA_MarketInquiryApparatusList.PDPurchasePriceRMB;PDPurchaseTotalvalueRMB->DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRMB;NPDPurchaseTotalvalueRMB->DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB;InternationCIF->DF_SA_MarketInquiryApparatusList.InternationCIF;CustomsFees->DF_SA_MarketInquiryApparatusList.CustomsFees;PrchaseCurrency->DF_SA_MarketInquiryApparatusList.PrchaseCurrency;Discount->DF_SA_MarketInquiryApparatusList.Discount;ExchangeRate->DF_SA_MarketInquiryApparatusList.ExchangeRate;GrossMargin->DF_SA_MarketInquiryApparatusList.GrossMargin;TariffRate->DF_SA_MarketInquiryApparatusList.TariffRate;PlanSort->DF_SA_MarketInquiryApparatusList.PlanSort;PurchasingPattern->DF_SA_MarketInquiryApparatusList.PurchasingPattern;SourcingPurchasing->DF_SA_MarketInquiryApparatusList.SourcingPurchasing;Linkman->DF_SA_MarketInquiryApparatusList.Linkman;Phone->DF_SA_MarketInquiryApparatusList.Phone;PurchasePaymentMethod->DF_SA_MarketInquiryApparatusList.PurchasePaymentMethod;PurchaseInvoiceTaxPoint->DF_SA_MarketInquiryApparatusList.PurchaseInvoiceTaxPoint;SupplierDeliveryDate->DF_SA_MarketInquiryApparatusList.SupplierDeliveryDate;SupplierDeliveryDateUnit->DF_SA_MarketInquiryApparatusList.SupplierDeliveryDateUnit;WarrantyPeriod->DF_SA_MarketInquiryApparatusList.WarrantyPeriod;WarrantyPeriodOther->DF_SA_MarketInquiryApparatusList.WarrantyPeriodOther;ProductBPMID->DF_SA_MarketInquiryApparatusList.ProductBPMID;ProductCRMID->DF_SA_MarketInquiryApparatusList.ProductCRMID;SupplierPeriod->DF_SA_MarketInquiryApparatusList.SupplierPeriod;SupplierPeriodOther->DF_SA_MarketInquiryApparatusList.SupplierPeriodOther;InternationCIFRateForeign->DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign;InternationCIFRate->DF_SA_MarketInquiryApparatusList.InternationCIFRate;SupplierCustomerName->DF_SA_MarketInquiryApparatusList.SupplierCustomerName;SupplierCustomerSAPID->DF_SA_MarketInquiryApparatusList.SupplierCustomerSAPID;IsFlag->DF_SA_MarketInquiryApparatusList.IsFlag;IsSupplierSend->DF_SA_MarketInquiryApparatusList.IsSupplierSend;SupplierSendReason->DF_SA_MarketInquiryApparatusList.SupplierSendReason;IncreaseTariff->DF_SA_MarketInquiryApparatusList.IncreaseTariff;SUMIncreaseTariff->DF_SA_MarketInquiryApparatusList.SUMIncreaseTariff;SupplierSAPID->DF_SA_MarketInquiryApparatusList.SupplierSAPID;DeliveryDeadlineDayOrWeek->DF_SA_MarketInquiryApparatusList.DeliveryDeadlineDayOrWeek;DeliveryDeadline->DF_SA_MarketInquiryApparatusList.DeliveryDeadline;DirectDistribution->DF_SA_MarketInquiryApparatusList.DirectDistribution;CustomerDesignatedSupplier->DF_SA_MarketInquiryApparatusList.CustomerDesignatedSupplier;IsAdvancePayForSupplier->DF_SA_MarketInquiryApparatusList.IsAdvancePayForSupplier;YearsService->DF_SA_MarketInquiryApparatusList.YearsService;Proportion->DF_SA_MarketInquiryApparatusList.Proportion">
                    <tbody>
                        <tr class="scrollColThead">
                            <th height="26" class="scrollRowThead scrollCR" style="TEXT-ALIGN: left" colspan="52">
                                <asp:Label id="XLabel8" runat="server" text="产品明细 " valuetodisplaytext value></asp:Label>&nbsp; <%--<aspxform:XDataBrowserButton id="XDataBrowserButton5" runat="server" Text="导入CRM产品信息" Width="150px" HiddenExpress="DF_SA_MarketInquiry.BU=='ATBU'" DisplayColumns="DESCRIPTION:销售机会,;QUANTITY:数量,;EXTENDEDPRICE:含税销售单价,;NAME:产品型号,;PRODUCTID:产品CRMID," XDataSource="DataSource:CRM正式库;TableName:BPM_PRODUCT;Filter:OPPORTUNITYID->DF_SA_MarketInquiry.SalesOpportunitiesID;BufferType:RuntimeUpdate" DataMap="QUANTITY->DF_SA_MarketInquiryApparatusList.Number;NAME->DF_SA_MarketInquiryApparatusList.ProductModel;PRODUCTID->DF_SA_MarketInquiryApparatusList.ProductCRMID;CALCPRICE->DF_SA_MarketInquiryApparatusList.PDSellingPriceRest" Height="25px" MultiSelect="True"></aspxform:XDataBrowserButton>--%>
                                <aspxform:XCustomBrowserButton id="XCustomBrowserButton7" runat="server" Width="150px" XClass="Oimec.Dialogs.ProductButton" Text="选择产品信息" Height="25px" DataMap="PrdtID->DF_SA_MarketInquiryApparatusList.ProductBPMID;PrdtName->DF_SA_MarketInquiryApparatusList.ProductNmae;PrdtModelNo->DF_SA_MarketInquiryApparatusList.ProductModel;SalesSapID->SASapID;ServicesSapID->SEVSapID;ProprietarySapID->PROSapID;OtherSapID->OTHSapID;ManufacturerID->DF_SA_MarketInquiryApparatusList.ManufacturerID;OriginCountry->varOrigin" AppendMode="Append" BrowserWindowType="AjaxPanel" MultiSelect="True"></aspxform:XCustomBrowserButton>
                                <asp:Label id="XLabel220" runat="server" text="同一型号不同的供应商采购，请分行填写" valuetodisplaytext value forecolor="Red" font-size="8pt"></asp:Label>
                            </th>
                        </tr>
                        <tr class="scrollColThead">
                            <th width="42" height="44" class="tds">
                                <asp:Label id="XLabel9" runat="server" text="序号" valuetodisplaytext value></asp:Label>
                            </th>
                            <th width="130" class="tds">
                                <asp:Label id="XLabel184" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>
                                <aspxform:XLabel id="XLabel96" runat="server" XDataBind="yewufenlei" BackColor="#d5dade" Value ValueToDisplayText Text="业务分类" Font-Bold="False"></aspxform:XLabel>
                                <input onclick="AllXINPINXIAOSHOU()" type="button" value="全选为新品销售" />
                            </th>
                            <th width="99" class="tds">
                                <asp:Label id="XLabel11" runat="server" text="物料类型" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="139" class="tds">
                                <asp:Label id="XLabel12" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel14" runat="server" text="产品型号" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="117" class="tds">
                                &nbsp;<asp:Label id="XLabel20" runat="server" text="产品名称" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="101" class="tds">
                                &nbsp;<asp:Label id="XLabel15" runat="server" text="SAP物料号" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="99" class="tds">
                                &nbsp;<asp:Label id="XLabel16" runat="server" text="厂商编号" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="99" class="tds">
                                &nbsp;<asp:Label id="XLabel17" runat="server" text="厂商名称" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="109" class="tds">
                                <asp:Label id="XLabel189" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel21" runat="server" text="数量" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel190" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel23" runat="server" text="含税销售单价（销售币种）" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel24" runat="server" text="含税销售总价（销售币种）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel25" runat="server" text="不含税销售总价（销售币种）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="115" class="tds">
                                <asp:Label id="XLabel26" runat="server" text="含税销售单价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="115" class="tds">
                                <asp:Label id="XLabel28" runat="server" text="含税销售总价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="115" class="tds">
                                <asp:Label id="XLabel29" runat="server" text="不含税销售总价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <td width="119" class="tds">
                                <asp:Label id="XLabel232" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel102" runat="server" text="采购模式" valuetodisplaytext value xdatabind="caigoumoshi"></asp:Label></td>
                            <th width="150" class="tds">
                                <asp:Label id="XLabel246" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel247" runat="server" text="供应商直发" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="199" class="tds">
                                <asp:Label id="XLabel249" runat="server" text="直发条件" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="99" class="tds">
                                <asp:Label id="XLabel200" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel31" runat="server" text="采购数量" valuetodisplaytext value font-bold="False"></asp:Label> 
                            </th>
                            <th width="115" class="tds">
                                <asp:Label id="XLabel201" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel32" runat="server" text="采购币种" valuetodisplaytext value font-bold="False" xdatabind="caigoubizhong"></asp:Label> 
                            </th>
                            <td width="140" class="tds">
                                <asp:Label id="XLabel202" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel18" runat="server" text="含税采购单价(采购币种)" valuetodisplaytext value></asp:Label> 
                                <input onclick="GetStockingPrice()" type="button" value="SAP备货价格" /></td>
                            <th width="100" class="tds">
                                <asp:Label id="XLabel19" runat="server" text="采购折扣" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel49" runat="server" text="含税采购总价（采购币种）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel50" runat="server" text="不含税采购总价（采购币种）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel51" runat="server" text="含税采购单价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel52" runat="server" text="含税采购总价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel58" runat="server" text="不含税采购总价（人民币）" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel59" runat="server" text="国际运保费率" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="115" class="tds">
                                <asp:Label id="XLabel136" runat="server" text="国际运保费(采购币种)" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="112" class="tds">
                                <asp:Label id="XLabel61" runat="server" text="国际运保费(人民币)" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <th width="102" class="tds">
                                <asp:Label id="XLabel72" runat="server" text="报关杂费(人民币)" valuetodisplaytext value font-bold="False"></asp:Label>
                            </th>
                            <td width="115" class="tds">
                                <asp:Label id="XLabel91" runat="server" text="关税税率" valuetodisplaytext value></asp:Label>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <asp:Label id="XLabel178" runat="server" text="（以实际为准）" valuetodisplaytext value forecolor="Red"></asp:Label></td>
                            <td width="100" class="tds">
                                <asp:Label id="XLabel92" runat="server" text="关税小计(人民币)" valuetodisplaytext value></asp:Label></td>
                            <td width="99" class="tds">
                                <asp:Label id="XLabel135" runat="server" text="毛利" valuetodisplaytext value></asp:Label></td>
                            <td width="115" class="tds">
                                <asp:Label id="XLabel205" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel93" runat="server" text="计划行类别" valuetodisplaytext value></asp:Label></td>
                            <td width="171" class="tds">
                                <asp:Label id="XLabel209" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel103" runat="server" text="采购供应商" valuetodisplaytext value></asp:Label></td>
                            <td width="114" class="tds">
                                <asp:Label id="XLabel104" runat="server" text="联系人" valuetodisplaytext value></asp:Label></td>
                            <td width="114" class="tds">
                                <asp:Label id="XLabel105" runat="server" text="联系电话" valuetodisplaytext value></asp:Label></td>
                            <td width="250" class="tds">
                                <asp:Label id="XLabel106" runat="server" text="采购付款方式" valuetodisplaytext value></asp:Label></td>
                            <td width="100" class="tds">
                                <asp:Label id="XLabel107" runat="server" text="采购发票税点" valuetodisplaytext value xdatabind="caigoufapiaoshuidian"></asp:Label></td>
                            <td width="114" class="tds">
                                <asp:Label id="XLabel133" runat="server" text="供应商货期" valuetodisplaytext value></asp:Label></td>
                            <td width="110" class="tds">
                                <asp:Label id="XLabel218" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel134" runat="server" text="客户保修期" valuetodisplaytext value></asp:Label></td>
                            <td width="110" class="tds">
                                <aspxform:XLabel id="XLabel219" runat="server" HiddenExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " ForeColor="Red" BackColor="#d5dade" Value ValueToDisplayText Text="*"></aspxform:XLabel>
                                &nbsp;<asp:Label id="XLabel113" runat="server" text="供应商保修期" valuetodisplaytext value></asp:Label></td>
                            <td width="220" class="tds">
                                <aspxform:XLabel id="XLabel179" runat="server" HiddenExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " ForeColor="Red" BackColor="#d5dade" Value ValueToDisplayText Text="*"></aspxform:XLabel>
                                &nbsp;<asp:Label id="XLabel10" runat="server" text="报供应商最终客户名称" valuetodisplaytext value></asp:Label></td>
                            <td width="175" class="tds">
                                <asp:Label id="XLabel242" runat="server" text="国际运保费小计(采购币种)" valuetodisplaytext value></asp:Label></td>
                            <td width="140" class="tds" hidden="hidden">
                                <asp:Label id="XLabel241" runat="server" text="采购处理单号" valuetodisplaytext value></asp:Label></td>
                            <td width="134" class="tds" hidden="hidden">
                                <asp:Label id="XLabel243" runat="server" text="采购员" valuetodisplaytext value></asp:Label></td>
                            <td width="100" class="tds">
                                <asp:Label id="Label4" runat="server" text="加征关税%" valuetodisplaytext value></asp:Label></td>
                            <td width="100" class="tds">
                                <asp:Label id="Label5" runat="server" text="加征关税小计(人民币)" valuetodisplaytext value></asp:Label></td>
                            <td width="106" class="tds">
                                <asp:Label id="Label33" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="Label8" runat="server" text="客户指定供应商" valuetodisplaytext value></asp:Label></td>
                            <td width="104" class="tds" hidden="hidden">
                                <asp:Label id="Label10" runat="server" text="厂商直/分销" valuetodisplaytext value></asp:Label></td>
                            <td width="102" class="tds">
                                <asp:Label id="Label34" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="Label126" runat="server" text="客户交货期限" valuetodisplaytext value></asp:Label></td>
                             <td width="100" class="tds">
                                <asp:Label id="Label199" runat="server" text="含标准服务" value valuetodisplaytext></asp:Label></td>
                            <td width="100" class="tds">
                                <asp:Label id="Label200" runat="server" text="标准服务年限" value valuetodisplaytext></asp:Label></td>
                              <td width="100" class="tds">
                                <asp:Label id="Label201" runat="server" text="标准服务%" value valuetodisplaytext></asp:Label></td>
                            <%--<td width="104" class="tds">
                                <asp:Label id="Label4" runat="server" valuetodisplaytext value text="不含税库存成本单价(CNY)"></asp:Label></td>--%>
                        </tr>
                        <tr>
                            <td height="45" class="tds1" style="TEXT-ALIGN: center">
                                <aspxform:XGridLineNo id="XGridLineNo1" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.RowNumber" BackColor="Transparent" TextAlign="Center" RenderAs="Label" BorderStyle="None" TextMode="MultiLine">1</aspxform:XGridLineNo>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList1" name="BusinessClassification" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.BusinessClassification" DataMap="Value->DF_SA_MarketInquiryApparatusList.MaterialType;Value1->DF_SA_MarketInquiryApparatusList.BusinessClassificationID" XDataSource="TableName:V_DF_SA_SS_BusinessCategories;Filter:InvoiceTypes->TaxRate|like;OrderBy:'OrderID';BufferType:RuntimeUpdate" ValueColumn="Name" DisplayColumn="Name" PromptText="--请选择--">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XDropDownList id="XDropDownList45" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" runat="server" HiddenExpress="DF_SA_MarketInquiryApparatusList.BusinessClassification!='代理维修'&amp;&amp; DF_SA_MarketInquiryApparatusList.BusinessClassification!='代理延保'&amp;&amp; DF_SA_MarketInquiryApparatusList.BusinessClassification!='代理校准'" XDataBind="DF_SA_MarketInquiryApparatusList.TSType" PromptText="--请选择--">
                                    <asp:ListItem>泰克原厂服务</asp:ListItem>
                                    <asp:ListItem>是德原厂服务</asp:ListItem>
                                    <asp:ListItem>其他</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XTextBox id="XTextBox186" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiryApparatusList.BusinessClassificationID" HiddenInput="true" DisableExpress="1"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox117" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="SASapID" HiddenInput="true" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox118" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="PROSapID" HiddenInput="true" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox119" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="OTHSapID" HiddenInput="true" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox120" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="SEVSapID" HiddenInput="true" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox6" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="90%" XDataBind="DF_SA_MarketInquiryApparatusList.MaterialType" BackColor="#E6F1F8" ValueToDisplayText DisableExpress="1"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox class="prdtModel" id="XTextBox3" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100px" XDataBind="DF_SA_MarketInquiryApparatusList.ProductModel" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                                <%-- <aspxform:XDropDownList id="XDropDownList29" runat="server" HiddenExpress="1" Width="1px" DataMap="PrdtID->DF_SA_MarketInquiryApparatusList.ProductBPMID;PrdtName->DF_SA_MarketInquiryApparatusList.ProductNmae;SalesSapID->SASapID;ServicesSapID->SEVSapID;OtherSapID->OTHSapID;ProprietarySapID->PROSapID;Name->DF_SA_MarketInquiryApparatusList.Manufacturer;ManufacturerID->DF_SA_MarketInquiryApparatusList.ManufacturerID" XDataSource="ProcedureName:PROC_DF_SA_PRODUCTS;Filter:@PrdtModelNo -> DF_SA_MarketInquiryApparatusList.ProductModel,@CreateName -> DF_SA_MarketInquiry.OwnerID;BufferType:RuntimeUpdate" ValueColumn="PrdtName" DisplayColumn="PrdtName" DisableExpress="1">
                                        <asp:ListItem>未绑定</asp:ListItem>
                                    </aspxform:XDropDownList>--%>
                                <aspxform:XCustomBrowserButton id="XCustomBrowserButton8" runat="server" Width="20px" XClass="Oimec.Dialogs.ProductInfoButton" Text="..." DataMap="PrdtID->DF_SA_MarketInquiryApparatusList.ProductBPMID;PrdtName->DF_SA_MarketInquiryApparatusList.ProductNmae;PrdtModelNo->DF_SA_MarketInquiryApparatusList.ProductModel;SalesSapID->SASapID;ServicesSapID->SEVSapID;ProprietarySapID->PROSapID;OtherSapID->OTHSapID;ManufacturerID->DF_SA_MarketInquiryApparatusList.ManufacturerID;OriginCountry->varOrigin" BrowserWindowType="AjaxPanel" MultiSelect="false" PopupWndWidth="-1" PopupWndHeight="-1" UseSubmitBehavior="False"></aspxform:XCustomBrowserButton>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox4" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.ProductNmae" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox189" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="30px" XDataBind="varOrigin" HiddenInput="True"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox5" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="90%" XDataBind="DF_SA_MarketInquiryApparatusList.MaterialID" BackColor="#E6F1F8" Express="javascript('GetPROSAPID',DF_SA_MarketInquiryApparatusList.MaterialType,SASapID,PROSapID,OTHSapID,SEVSapID)" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox121" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiryApparatusList.ProductBPMID"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox122" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="1px" XDataBind="DF_SA_MarketInquiryApparatusList.ProductCRMID"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox runat="server" XDataBind="qwe"  HiddenExpress="1" DisableExpress="javascript('GetMenuByManufacturerID',DF_SA_MarketInquiryApparatusList.ManufacturerID)"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox8" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.ManufacturerID" BackColor="#E6F1F8" DisableExpress="1" name="ManufacturerID"></aspxform:XTextBox>
                                <aspxform:XDropDownList id="XDropDownList29" runat="server" HiddenExpress="1" Width="1px" DataMap="ManufacturerName->DF_SA_MarketInquiryApparatusList.Manufacturer" XDataSource="TableName:V_DF_PRODUCTS_ProductManagement;Filter:PrdtID->DF_SA_MarketInquiryApparatusList.ProductBPMID" ValueColumn="PrdtID" DisplayColumn="PrdtID">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                 <aspxform:XDropDownList ID="IsFlagSDF" HiddenExpress="1" name="IsFlagSDF" CssClass="IsFlagSDF" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.IsFlagSDF" XDataSource="TableName:DF_MasterData_RedFlagCustomer;Filter:CustomerCode->DF_SA_STPClientMessage.ClientBPMID,ManufacturerCode->DF_SA_MarketInquiryApparatusList.ManufacturerID" ValueColumn="ItemId" DisplayColumn="ItemId"></aspxform:XDropDownList>
                                    <br />
                                    <aspxform:XDropDownList ID="IsFlagFKF" HiddenExpress="1" name="IsFlagFKF" CssClass="IsFlagFKF" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.IsFlagFKF" XDataSource="TableName:DF_MasterData_RedFlagCustomer;Filter:CustomerCode->DF_SA_PTPClientMessage.ClientBPMID,ManufacturerCode->DF_SA_MarketInquiryApparatusList.ManufacturerID" ValueColumn="ItemId" DisplayColumn="ItemId"></aspxform:XDropDownList>
                              
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox10" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.Manufacturer" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <div style="FLOAT: left">
                                    <aspxform:XTextBox id="XTextBox11" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="80" XDataBind="DF_SA_MarketInquiryApparatusList.Number" TextAlign="Center" name="Number"></aspxform:XTextBox>
                                </div>
                                <div style="FLOAT: left">
                                    <aspxform:XTextBox id="XTextBox170" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20" XDataBind="DF_SA_MarketInquiryApparatusList.Unit" Text="台" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Center" name="Unit"></aspxform:XTextBox>
                                </div>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox12" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDSellingPriceRest" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox14" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRest" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.Number * DF_SA_MarketInquiryApparatusList.PDSellingPriceRest" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox17" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRest" BackColor="#E6F1F8" Express="javascript('IFBillingCompany',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRest,shuilv)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                           <aspxform:XTextBox id="XTextBox201"  HiddenExpress="1"  runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="varNI" Express="if(DF_SA_MarketInquiryApparatusList.ManufacturerID=='217',DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRest*0.02,0)" Format="type:number;.2"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox202" HiddenExpress="1"   runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="varNIRMB" Express="varNI*DF_SA_MarketInquiry.ExchangeRate" Format="type:number;.2"></aspxform:XTextBox>
                                 </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox20" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDSellingPriceRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.PDSellingPriceRest * DF_SA_MarketInquiry.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox21" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRest * DF_SA_MarketInquiry.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                                <aspxform:XTextBox class="sellValue" id="XTextBox174" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" Express="DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRMB"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox22" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRest * DF_SA_MarketInquiry.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList10" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.PurchasingPattern" XDataSource="TableName:V_DF_CRM_ProcurementModel" ValueColumn="Name" DisplayColumn="Name" PromptText="--请选择--" name="PurchasingPattern" CssClass="PurchasingPattern">
                                    <%-- XDataSource="TableName:V_DF_SA_SS_ProcurementModel;Filter:BufferType:RuntimeUpdate"--%> 
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XDropDownList id="XDropDownList35" runat="server" HiddenExpress="1" Width="10px" DataMap="PDPurchasePriceRest->PDPurchasePriceRest;Discount->DingHuoZheKou;Proportion->Proportion;IncludingStandardService->IncludingStandardService;" XDataSource="ProcedureName:PROC_DF_CRM_PriceSystem;Filter:@ProductModel->DF_SA_MarketInquiryApparatusList.ProductModel,@Currency->DF_SA_MarketInquiryApparatusList.PrchaseCurrency,@PurchasingPattern->DF_SA_MarketInquiryApparatusList.PurchasingPattern" ValueColumn="PDPurchasePriceRest" DisplayColumn="PDPurchasePriceRest">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                 
                            </td>
                            <td class="tds1">
                                <aspxform:XRadioButtonList id="XRadioButtonList6" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.IsSupplierSend" Express="javascript('IsSupplierSend',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiryApparatusList.PurchasingPattern,DF_SA_MarketInquiryApparatusList.PrchaseCurrency,DF_SA_MarketInquiryApparatusList.IsSupplierSend)" DisableExpress="(DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!='备货'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!=''&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='CNY'&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='')|| (DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货') || (Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认') " RepeatDirection="Horizontal" name="IsSupplierSend">
                                    <asp:ListItem Selected="True">非直发</asp:ListItem>
                                    <asp:ListItem>直发</asp:ListItem>
                                </aspxform:XRadioButtonList>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList24" style="WIDTH: 90%" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierSendReason" ValueColumn="Name" DisplayColumn="Name" Express="if((DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!='备货'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!=''&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='CNY'&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='')||(DF_SA_MarketInquiryApparatusList.IsSupplierSend!='直发'),'',DF_SA_MarketInquiryApparatusList.SupplierSendReason)" DisableExpress="(DF_SA_MarketInquiry.BillingCompany=='2000上海颐合'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!='备货'&amp;&amp;DF_SA_MarketInquiryApparatusList.PurchasingPattern!=''&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='CNY'&amp;&amp;DF_SA_MarketInquiryApparatusList.PrchaseCurrency!='')||(DF_SA_MarketInquiryApparatusList.IsSupplierSend!='直发') ||(DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货') || (Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认')" PromptText="--请选择--" CssClass="SupplierSendReason">
                                    <asp:ListItem>重量超过50KGS 体积超过1立方米</asp:ListItem>
                                    <asp:ListItem>产品数量大于30件，且单个货物体积超过0.2立方米</asp:ListItem>
                                    <asp:ListItem>特殊运输要求（易燃易爆产品、精密仪器、不适合转运产品）</asp:ListItem>
                                    <asp:ListItem>无实物产品</asp:ListItem>
                                    <asp:ListItem>客户货期紧急：要求3个工作日内交付</asp:ListItem>
                                    <asp:ListItem>符合以上多种情况</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox24" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PurchaseNumber" HiddenInput="False" Express="DF_SA_MarketInquiryApparatusList.Number" TextAlign="Center" name="PurchaseNumber" ReadOnly="True"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList9" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.PrchaseCurrency" XDataSource="TableName:V_DF_SA_SS_PurchasingCurrency;Filter:BufferType:RuntimeUpdate" ValueColumn="Name" DisplayColumn="Name" DisableExpress='DF_SA_MarketInquiryApparatusList.PurchasingPattern=="备货"' PromptText="--请选择--" CssClass="PrchaseCurrency">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XTextBox id="XTextBox61" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="1px" XDataBind="DF_SA_MarketInquiryApparatusList.ExchangeRate" Format="type:number;.4"></aspxform:XTextBox>
                                <aspxform:XDropDownList id="XDropDownList19" runat="server" HiddenExpress="1" Width="10px" DataMap="ComputeRate->DF_SA_MarketInquiryApparatusList.ExchangeRate" XDataSource="TableName:DF_SA_SS_ExchangeRate;Filter:ForeignCurrency->DF_SA_MarketInquiryApparatusList.PrchaseCurrency" ValueColumn="ComputeRate" DisplayColumn="ComputeRate">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox28" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDPurchasePriceRest" Max="0" Min="0" Value ValueToDisplayText HiddenInput="False" Express="javascript('DingHuoCaiGouJiaGe',DF_SA_MarketInquiryApparatusList.PDPurchasePriceRest,PDPurchasePriceRest,DF_SA_MarketInquiryApparatusList.PurchasingPattern,DF_SA_MarketInquiryApparatusList.Proportion,DF_SA_MarketInquiryApparatusList.ManufacturerID)" Format="type:currency;.2" TextAlign="Right" AutoCompleteType="Disabled"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox144" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="PDPurchasePriceRest"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox30" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70px" XDataBind="DF_SA_MarketInquiryApparatusList.Discount" Express="javascript('DingHuoCaiGouZheKou',DF_SA_MarketInquiryApparatusList.Discount,DingHuoZheKou,DF_SA_MarketInquiryApparatusList.PurchasingPattern)" Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                                % 
                                <aspxform:XTextBox id="XTextBox76" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="1px" XDataBind="zhekou" Express=" (100 - DF_SA_MarketInquiryApparatusList.Discount)  /  100"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox162" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DingHuoZheKou"></aspxform:XTextBox>
                                 <aspxform:XTextBox id="XTextBox200" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="Proportion"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox31" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRest" BackColor="#E6F1F8" Express="javascript('CountPurchasePrices',DF_SA_MarketInquiryApparatusList.Discount,DF_SA_MarketInquiryApparatusList.PDPurchasePriceRest,DF_SA_MarketInquiryApparatusList.PurchaseNumber,DF_SA_MarketInquiryApparatusList.ManufacturerID)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox32" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRest" BackColor="#E6F1F8" Express="javascript('IFPDPurchaseTotalvalueRest',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRest,caigoushuilv)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox33" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDPurchasePriceRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.ExchangeRate * DF_SA_MarketInquiryApparatusList.PDPurchasePriceRest" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox39" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRest * DF_SA_MarketInquiryApparatusList.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox71" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB" BackColor="#E6F1F8" Express="DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRest * DF_SA_MarketInquiryApparatusList.ExchangeRate" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                                <aspxform:XTextBox class="purchaseValue" id="XTextBox173" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" Express="DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox36" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70px" XDataBind="DF_SA_MarketInquiryApparatusList.InternationCIF" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                                %<aspxform:XTextBox id="XTextBox45" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="1px" XDataBind="guoji" Express="(DF_SA_MarketInquiryApparatusList.InternationCIF / 100)"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox100" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " Format="type:number;.2"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox18" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100px" XDataBind="DF_SA_MarketInquiryApparatusList.InternationCIFRate" BackColor="#E6F1F8" Express="guojiyunbaofei2" DisableExpress="1" Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox60" runat="server" HiddenExpress="1" BorderWidth="1px" BorderColor="Gainsboro" Width="1px" XDataBind="guojiyunbaofei2" Max="0" Min="0" Value ValueToDisplayText HiddenInput="False" Express="javascript('CountGUOJIYUNFEI',DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign,DF_SA_MarketInquiryApparatusList.ExchangeRate,DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB,guoji) "></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox37" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.CustomsFees" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || (DF_SA_MarketInquiryApparatusList.PrchaseCurrency !='CNY' &amp;&amp; DF_SA_MarketInquiry.ContractCurrency !='CNY') || DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox19" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="80px" XDataBind="DF_SA_MarketInquiryApparatusList.TariffRate" Express="javascript('GetPurchasingTariff',DF_SA_MarketInquiry.ContractCurrency,DF_SA_MarketInquiryApparatusList.ProductModel,DF_SA_MarketInquiryApparatusList.ProductBPMID,DF_SA_MarketInquiryApparatusList.PrchaseCurrency,DF_SA_MarketInquiryApparatusList.RowNumber)" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || (DF_SA_MarketInquiryApparatusList.PrchaseCurrency !='CNY' &amp;&amp; DF_SA_MarketInquiry.ContractCurrency !='CNY')  ||DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' " Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                                %<aspxform:XTextBox id="XTextBox46" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="1px" XDataBind="guanshui" Express="DF_SA_MarketInquiryApparatusList.TariffRate / 100"></aspxform:XTextBox>
                                <%--<aspxform:XDropDownList id="XDropDownList45" runat="server" HiddenExpress="1" DataMap="TaxRate->DF_SA_MarketInquiryApparatusList.TariffRate" XDataSource="TableName:DF_SA_SS_PurchaseTariffRates;Filter:ProductBPMID->DF_SA_MarketInquiryApparatusList.ProductBPMID;BufferType:RuntimeUpdate" ValueColumn="TaxRate" DisplayColumn="TaxRate">
                                        <asp:ListItem>未绑定</asp:ListItem>
                                    </aspxform:XDropDownList>--%></td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox26" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="guanshuixiaoji" BackColor="#E6F1F8" Express="(DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB + DF_SA_MarketInquiryApparatusList.InternationCIFRate ) *  (DF_SA_MarketInquiryApparatusList.TariffRate / 100)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox75" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.GrossMargin" Express="DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRMB - DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB " Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList15" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.PlanSort" Express="javascript('ISPlanSort',DF_SA_MarketInquiryApparatusList.PurchaseNumber,DF_SA_MarketInquiryApparatusList.PurchasingPattern)" DisableExpress='DF_SA_MarketInquiryApparatusList.PurchasingPattern=="备货"' PromptText="--请选择--">
                                    <asp:ListItem>BP</asp:ListItem>
                                    <asp:ListItem>BN</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox77" runat="server" CssClass="SourcingPurchasing" BorderWidth="1px" BorderColor="Gainsboro" Width="120px" XDataBind="DF_SA_MarketInquiryApparatusList.SourcingPurchasing" onkeyup="onkeyup_UpdateSupplierSAPID()"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox97" runat="server"  HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="120px" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierSAPID" name="SupplierSAPID"></aspxform:XTextBox>
                                <aspxform:XDataBrowserButton id="XDataBrowserButton3" runat="server" Width="20px" XClass="YZSoft.Forms.Field.DataBrowserButton" Text="..." DataMap="SupplierID->PartnerID;SupplierName->DF_SA_MarketInquiryApparatusList.SourcingPurchasing;SupplierSAPID->DF_SA_MarketInquiryApparatusList.SupplierSAPID" XDataSource="TableName:V_DF_Supplier_ZK;" DisplayColumns="SupplierName:供应商名称;SupplierID:供应商ID;SupplierSAPID:供应商SAPID" PopupWndWidth="-1" PopupWndHeight="-1" UseSubmitBehavior="False"></aspxform:XDataBrowserButton>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox78" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiryApparatusList.Linkman" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' "></aspxform:XTextBox>
                                <aspxform:XDataBrowserButton id="browser" runat="server" Width="20px" XClass="YZSoft.Forms.Field.DataBrowserButton" Text="..." DataMap="ContactName->DF_SA_MarketInquiryApparatusList.Linkman;ContactTel->DF_SA_MarketInquiryApparatusList.Phone" XDataSource="TableName:V_DF_MSupplier_Contact;Filter:CustomerID->PartnerID" DisplayColumns="ContactName:联系人;ContactTel:联系人电话;" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' "></aspxform:XDataBrowserButton>
                                <aspxform:XTextBox id="PartnerID" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="80px" XDataBind="PartnerID"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox79" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.Phone" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' "></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox81" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="60%" XDataBind="DF_SA_MarketInquiryApparatusList.PurchasePaymentMethod" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' "></aspxform:XTextBox>
                                <asp:Label id="r" runat="server" text="供应商预付"></asp:Label>
                                <aspxform:XRadioButtonList id="IsAdvancePay" style="FLOAT: right" runat="server" Width="86px" XDataBind="DF_SA_MarketInquiryApparatusList.IsAdvancePayForSupplier" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" RepeatDirection="Horizontal" CssClass="IsAdvancePay">
                                    <asp:ListItem Value="1">有</asp:ListItem>
                                    <asp:ListItem Value="0">无</asp:ListItem>
                                </aspxform:XRadioButtonList>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList16" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.PurchaseInvoiceTaxPoint" DataMap="Value->caigoushuilv" XDataSource="TableName:V_DF_SD_PurchaseTax;Filter:BufferType:RuntimeUpdate;OrderBy:OrderID" ValueColumn="Name" DisplayColumn="Name" Express="javascript('IFCNY',DF_SA_MarketInquiryApparatusList.PrchaseCurrency,DF_SA_MarketInquiryApparatusList.PurchaseInvoiceTaxPoint,DF_SA_MarketInquiryApparatusList.PurchasingPattern)" DisableExpress='DF_SA_MarketInquiryApparatusList.PrchaseCurrency!="CNY"||DF_SA_MarketInquiryApparatusList.PurchasingPattern=="备货"' PromptText="--请选择--">
                                    <asp:ListItem>未绑定</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XTextBox id="XTextBox64" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="caigoushuilv"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox91" format="type:number;0"  name="SupplierDeliveryDate" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="40%" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierDeliveryDate"></aspxform:XTextBox>
                            <aspxform:XDropDownList runat="server" name="SupplierDeliveryDateUnit" ID="SupplierDeliveryDateUnit" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierDeliveryDateUnit" Width="50%" PromptText="--请选择--">
                                      <asp:ListItem>周</asp:ListItem>
                                      <asp:ListItem>天</asp:ListItem>
                                 </aspxform:XDropDownList>
                                 </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList33" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.WarrantyPeriod" XDataSource="BufferType:RuntimeUpdate" PromptText="--请选择--" name="WarrantyPeriod">
                                    <asp:ListItem>1年</asp:ListItem>
                                    <asp:ListItem>2年</asp:ListItem>
                                    <asp:ListItem>3年</asp:ListItem>
                                    <asp:ListItem>5年</asp:ListItem>
                                    <asp:ListItem>按厂商质量技术标准</asp:ListItem>
                                    <asp:ListItem>其他</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XTextBox id="XTextBox92" runat="server" HiddenExpress="DF_SA_MarketInquiryApparatusList.WarrantyPeriod != '其他'" BorderWidth="1" BorderColor="#DCDCDC" Width="90px" XDataBind="DF_SA_MarketInquiryApparatusList.WarrantyPeriodOther" name="WarrantyPeriodOther"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XDropDownList id="XDropDownList32" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierPeriod" DisableExpress='DF_SA_MarketInquiryApparatusList.PurchasingPattern=="备货"' PromptText="--请选择--">
                                    <asp:ListItem>1年</asp:ListItem>
                                    <asp:ListItem>2年</asp:ListItem>
                                    <asp:ListItem>3年</asp:ListItem>
                                    <asp:ListItem>5年</asp:ListItem>
                                    <asp:ListItem>其他</asp:ListItem>
                                </aspxform:XDropDownList>
                                <aspxform:XTextBox id="XTextBox93" runat="server" HiddenExpress='DF_SA_MarketInquiryApparatusList.SupplierPeriod != "其他"' BorderWidth="1px" BorderColor="Gainsboro" Width="90px" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierPeriodOther" Max="0" Min="0" Value ValueToDisplayText HiddenInput="False"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox143" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="80%" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierCustomerName" Express="if(DF_SA_MarketInquiryApparatusList.SupplierCustomerName=='',DF_SA_PTPClientMessage.PTPName,DF_SA_MarketInquiryApparatusList.SupplierCustomerName)" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" ReadOnly="True"></aspxform:XTextBox>
                                <aspxform:XDataBrowserButton id="XDataBrowserButton2" runat="server" Width="20px" XClass="YZSoft.Forms.Field.DataBrowserButton" Text="..." DataMap="CustomerNameCH->DF_SA_MarketInquiryApparatusList.SupplierCustomerName;CustomerSAPID->DF_SA_MarketInquiryApparatusList.SupplierCustomerSAPID;CustomerID->DF_SA_MarketInquiryApparatusList.SupplierCustomerID" XDataSource="TableName:V_DF_MasterData_Customer" DisplayColumns="CustomerID:客户编号;CustomerNameCH:客户名称;CustomerSAPID:SAPID;IsFlag:实体清单客户;CusLeavel:客户等级" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" PopupWndWidth="-1" PopupWndHeight="-1" UseSubmitBehavior="False"></aspxform:XDataBrowserButton>
                                <aspxform:XTextBox id="XTextBox51" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiryApparatusList.IsFlag" HiddenInput="True" Express='if(SUPPLIERCID=="","否","是")' name="IsFlag"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox182" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="20px" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierCustomerSAPID" HiddenInput="True" Express="if(DF_SA_MarketInquiryApparatusList.SupplierCustomerSAPID=='',DF_SA_PTPClientMessage.PTPSapID,DF_SA_MarketInquiryApparatusList.SupplierCustomerSAPID)"></aspxform:XTextBox>
                                <aspxform:XDropDownList ID="XDropDownList41" HiddenExpress="1" runat="server" XDataBind="SUPPLIERCID" XDataSource="TableName:DF_MasterData_RedFlagCustomer;Filter:CustomerCode->DF_SA_MarketInquiryApparatusList.SupplierCustomerID,ManufacturerCode->DF_SA_MarketInquiryApparatusList.ManufacturerID" DisplayColumn="ItemId" ValueColumn="ItemId" ></aspxform:XDropDownList>                           
                             <br />
                                <aspxform:XTextBox ID="XTextBox171" runat="server" Width="60px" BorderColor="#DCDCDC" BorderWidth="1" XDataBind="DF_SA_MarketInquiryApparatusList.SupplierCustomerID" HiddenInput="true" Express="if(DF_SA_MarketInquiryApparatusList.SupplierCustomerID=='',DF_SA_PTPClientMessage.ClientBPMID,DF_SA_MarketInquiryApparatusList.SupplierCustomerID)" CssClass="SupplierCustomerSAPID"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox169" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.SUMInternationCIF" Express='if(DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign==0||DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign=="",DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRest*DF_SA_MarketInquiryApparatusList.InternationCIF/100,DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign)' DisableExpress="1" Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds1" bordercolor="#dcdcdc" hidden="hidden" borderwidth="1">
                                <aspxform:XHistoryFormLink id="XHistoryFormLink1" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.PurchseTaskID" BackColor="#e9f1f4" Express="taskId" PopupWndWidth="-1" PopupWndHeight="-1" EmptyText="尚未关联">#SerialNum</aspxform:XHistoryFormLink>
                            </td>
                            <td class="tds1" bordercolor="#dcdcdc" hidden="hidden" borderwidth="1">
                                <aspxform:XTextBox id="XTextBox176" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.Purchaser" BackColor="#E6F1F8" DisableExpress="1"></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox188" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" HiddenInput="True" Express='javascript("UpLineItemStyle",DF_SA_MarketInquiry.ContractCurrency,DF_SA_MarketInquiryApparatusList.PrchaseCurrency,DF_SA_MarketInquiryApparatusList.PurchasingPattern,DF_SA_MarketInquiryApparatusList.RowNumber)'></aspxform:XTextBox>
                                <aspxform:XTextBox id="XTextBox177" style="HEIGHT: 22px; WIDTH: 1px" runat="server" HiddenExpress="1" BorderColor="Gainsboro" Width="1px" XDataBind="taskId" Max="0" Min="0" Value ValueToDisplayText HiddenInput="False"></aspxform:XTextBox>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox191" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="80px" XDataBind="DF_SA_MarketInquiryApparatusList.IncreaseTariff" Max="0" Min="0" BackColor="#E6F1F8" Value ValueToDisplayText HiddenInput="False" Express="javascript('GetPurchasingTariff',DF_SA_MarketInquiry.ContractCurrency,DF_SA_MarketInquiryApparatusList.ProductModel,DF_SA_MarketInquiryApparatusList.ProductBPMID,DF_SA_MarketInquiryApparatusList.PrchaseCurrency,DF_SA_MarketInquiryApparatusList.RowNumber)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                                %</td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox190" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="100%" XDataBind="DF_SA_MarketInquiryApparatusList.SUMIncreaseTariff" Max="0" Min="0" BackColor="#E6F1F8" Value ValueToDisplayText HiddenInput="False" Express="(DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB + DF_SA_MarketInquiryApparatusList.InternationCIFRate ) *  (DF_SA_MarketInquiryApparatusList.IncreaseTariff / 100)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right" AutoCompleteType="Disabled"></aspxform:XTextBox>
                            </td>
                            <td width="106" class="tds1">
                                <aspxform:XDropDownList id="XDropDownList25" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.CustomerDesignatedSupplier" Express="if(DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货','',DF_SA_MarketInquiryApparatusList.CustomerDesignatedSupplier)" DisableExpress="(Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认') || DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'  " PromptText="--请选择--">
                                    <asp:ListItem>是</asp:ListItem>
                                    <asp:ListItem>否</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                            <td width="104" class="tds1" hidden="hidden">
                                <aspxform:XDropDownList id="XDropDownList26" runat="server" XDataBind="DF_SA_MarketInquiryApparatusList.DirectDistribution" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" PromptText="--请选择--">
                                    <asp:ListItem>直销</asp:ListItem>
                                    <asp:ListItem>分销</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="DeliveryDeadline" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="55%" XDataBind="DF_SA_MarketInquiryApparatusList.DeliveryDeadline" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" name="DeliveryDeadline"></aspxform:XTextBox>
                                <aspxform:XDropDownList id="DeliveryDeadlineDayOrWeek" runat="server" Width="40%" XDataBind="DF_SA_MarketInquiryApparatusList.DeliveryDeadlineDayOrWeek" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" name="DeliveryDeadlineDayOrWeek">
                                    <asp:ListItem Selected="True">周</asp:ListItem>
                                    <asp:ListItem>天</asp:ListItem>
                                </aspxform:XDropDownList>
                            </td>
                             <td class="tds1">
                                 <aspxform:XTextBox XDataBind="IncludingStandardService" runat="server" HiddenExpress="1"></aspxform:XTextBox>
                                      <aspxform:XDropDownList ID="IncludingStandardService" DisableExpress="1" XDataBind="DF_SA_MarketInquiryApparatusList.IncludingStandardService" Express="if(IncludingStandardService==''|| IncludingStandardService=='否', '否','是')" runat="server" PromptText="--请选择--">
                                            <asp:ListItem>是</asp:ListItem>
                                        <asp:ListItem>否</asp:ListItem>
                                      </aspxform:XDropDownList>
                                </td>
                                 <td class="tds1">
                                      <aspxform:XDropDownList ID="YearsService" DisableExpress="if((DF_SA_MarketInquiryApparatusList.IncludingStandardService=='否'&&Global.StepName=='业务员发起申请')||Global.StepName!='业务员发起申请','1','')"  XDataBind="DF_SA_MarketInquiryApparatusList.YearsService" runat="server" PromptText="--请选择--" XDataSource="ProcedureName:PROC_DF_CRM_PriceSystem_distinct;Filter:@ProductModel->DF_SA_MarketInquiryApparatusList.ProductModel,@Manufacturers->DF_SA_MarketInquiryApparatusList.Manufacturer,@status->'1'"       DisplayColumn="YearsService" ValueColumn="YearsService" >
                                          <%--  <asp:ListItem>三年NI标准服务</asp:ListItem>
                                        <asp:ListItem>五年NI标准服务</asp:ListItem>--%>
                                      </aspxform:XDropDownList>
                                      <aspxform:XDropDownList ID="XDropDownList50"   runat="server" PromptText="" HiddenExpress="1" DataMap="Proportion->DF_SA_MarketInquiryApparatusList.Proportion;" XDataSource="ProcedureName:PROC_DF_CRM_PriceSystem_Proportion;Filter:@ProductModel->DF_SA_MarketInquiryApparatusList.ProductModel,@Manufacturers->DF_SA_MarketInquiryApparatusList.Manufacturer,@YearsService->DF_SA_MarketInquiryApparatusList.YearsService;"       DisplayColumn="Proportion" ValueColumn="Proportion" >
                                          <%--  <asp:ListItem>三年NI标准服务</asp:ListItem>
                                        <asp:ListItem>五年NI标准服务</asp:ListItem>--%>
                                      </aspxform:XDropDownList>
                                </td>
                                <td class="tds1">
                                       <aspxform:XTextBox id="ysProportion" runat="server" Width="70%" BorderColor="#DCDCDC" BorderWidth="1" XDataBind="DF_SA_MarketInquiryApparatusList.Proportion" BackColor="#E6F1F8"   DisableExpress="1"  CssClass="Proportion" name="Proportion"></aspxform:XTextBox>%
                                </td>
                        </tr>
                        <tr>
                            <td height="23">
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td class="tds">
                                <asp:Label id="XLabel137" runat="server" text="合计" valuetodisplaytext value></asp:Label></td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox27" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMPDSellingTotalvalueRest" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRest)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds2">
                                <aspxform:XTextBox id="XTextBox34" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRest" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRest)" DisableExpress="1" Format="type:currency;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td>
                            </td>
                            <td class="tds1">
                                <aspxform:XTextBox id="XTextBox68" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMPDSellingTotalvalueRMB" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.PDSellingTotalvalueRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds2">
                                <aspxform:XTextBox id="XTextBox73" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMNPDSellingTotalvalueRMB" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.NPDSellingTotalvalueRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                                <aspxform:XTextBox id="XTextBox13" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMPDPurchaseTotalvalueRest" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRest)" Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td>
                                <aspxform:XTextBox id="XTextBox80" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRest" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRest)" Format="type:number;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td>
                            </td>
                            <td class="tds2">
                                <aspxform:XTextBox id="XTextBox112" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMPDPurchaseTotalvalueRMB" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.PDPurchaseTotalvalueRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td class="tds2">
                                <aspxform:XTextBox id="XTextBox44" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SUMNPDPurchaseTotalvalueRMB" BackColor="#E6F1F8" Express="sum(DF_SA_MarketInquiryApparatusList.NPDPurchaseTotalvalueRMB)" DisableExpress="1" Format="type:currency;pfx:￥;.2" TextAlign="Right"></aspxform:XTextBox>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td>
                            </td>
                            <td width="106">
                            </td>
                            <td width="104">
                            </td>
                            <td>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
        <br />
         <table width="1200" align="center" class="table" >
             <tbody>
                <tr>
                    <td width="1200" class="title1" colspan="4">
                        <asp:Label id="Label68" runat="server" text="上传附件" valuetodisplaytext value></asp:Label>
                         
                    </td>
                </tr>
                 <tr>
                      <td class="ts" style="WIDTH: 12%" colspan="4">
                           <aspxform:XAttachments runat="server" XDataBind="DF_SA_MarketInquiry.ReportAttachments" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'" />
                           </td>
                 </tr>
            </tbody>
          </table>
        <aspxform:XRequiredFieldValidator id="该产品没有物料号" runat="server" ValidationGroup="zhuli" Display="None" ErrorMessage="该产品没有物料号,请发起SAP物料主数据申请" ControlToValidate="XTextBox5"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择业务分类" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择业务分类" ControlToValidate="XDropDownList1"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写产品型号" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写产品型号" ControlToValidate="XTextBox3"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写产品名称" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写产品名称" ControlToValidate="XTextBox4"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写厂商编号" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写厂商编号" ControlToValidate="XTextBox8"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写生产厂商" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写生产厂商" ControlToValidate="XTextBox10"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写数量" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写数量" ControlToValidate="XTextBox11"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写含税销售单价" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写含税销售单价（销售币种）" ControlToValidate="XTextBox12"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择采购模式" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择采购模式" ControlToValidate="XDropDownList10"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写采购数量" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购数量" ControlToValidate="XTextBox24"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择采购币种" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择采购币种" ControlToValidate="XDropDownList9"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写含税采购单价" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写含税采购单价" ControlToValidate="XTextBox28"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写国际运保费率" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写国际运保费率" ControlToValidate="XTextBox36" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY'  ||DF_SA_MarketInquiryApparatusList.InternationCIFRateForeign !=''"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写国际运保费" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写国际运保费" ControlToValidate="XTextBox100" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || DF_SA_MarketInquiryApparatusList.InternationCIF !=''"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写报关杂费" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写报关杂费" ControlToValidate="XTextBox37" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || (DF_SA_MarketInquiryApparatusList.PrchaseCurrency !='CNY' &amp;&amp; DF_SA_MarketInquiry.ContractCurrency !='CNY') "></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写关税税率" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写关税税率" ControlToValidate="XTextBox19" DisableExpress="DF_SA_MarketInquiryApparatusList.PrchaseCurrency=='CNY' || (DF_SA_MarketInquiryApparatusList.PrchaseCurrency !='CNY' &amp;&amp; DF_SA_MarketInquiry.ContractCurrency !='CNY') "></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择计划行类别" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择计划行类别" ControlToValidate="XDropDownList15"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写采购供应商" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购供应商 " ControlToValidate="XTextBox77" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写采购联系人" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购联系人" ControlToValidate="XTextBox78" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写采购联系电话" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购联系电话" ControlToValidate="XTextBox79" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货' "></aspxform:XRequiredFieldValidator>
        <%--<aspxform:XRequiredFieldValidator id="请填写采购付款方式" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购付款方式" ControlToValidate="XTextBox81" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>--%>
        <aspxform:XRequiredFieldValidator id="请填写采购发票税点" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写采购发票税点" ControlToValidate="XDropDownList16" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern!='备货' || DF_SA_MarketInquiryApparatusList.PrchaseCurrency!=&quot;CNY&quot;"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写供应商货期" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写供应商货期" ControlToValidate="XTextBox91" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写客户保修期" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户保修期" ControlToValidate="XDropDownList33" ></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写供应商保修期" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写供应商保修期" ControlToValidate="XDropDownList32" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写报供应商最终客户名称" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写报供应商最终客户名称" ControlToValidate="XTextBox143"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请选择客户指定供应商" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择客户指定供应商" ControlToValidate="XDropDownList25" DisableExpress="DF_SA_MarketInquiryApparatusList.PurchasingPattern=='备货'"></aspxform:XRequiredFieldValidator>
        <aspxform:XRequiredFieldValidator id="请填写客户交货期限" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写客户交货期限" ControlToValidate="DeliveryDeadline"></aspxform:XRequiredFieldValidator>
        <%--<aspxform:XRequiredFieldValidator id="请选择是否上传附件" runat="server" ControlToValidate="XRadioButtonList1" ErrorMessage="请选择是否上传附件" Display="None" ValidationGroup="yewuyuan"></aspxform:XRequiredFieldValidator>--%><%--<aspxform:XRequiredFieldValidator id="请选择附件" runat="server" ControlToValidate="XAttachments2" ErrorMessage="请选择附件" Display="None" ValidationGroup="yewuyuan" DisableExpress="DF_SA_MarketInquiry.OFAccessory=='否'"></aspxform:XRequiredFieldValidator>--%>
        <br />
         <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td height="18" class="title1" colspan="6">
                        <asp:Label id="XLabel117" runat="server" text="交货信息" valuetodisplaytext value></asp:Label>&nbsp; 
                    </td>
                </tr>
                <tr>
                    <td class="ts">
                        <asp:Label id="XLabel173" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel97" runat="server" text="客户期望交货期" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDateTimePicker id="XDateTimePicker2" style="WIDTH: 50%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.CustomerDeliveryDate"></aspxform:XDateTimePicker>
                    </td>
                    <td height="22" class="ts">
                        <asp:Label id="XLabel172" runat="server" text="*" HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel98" HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'" runat="server" text="客户交货方式" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XDropDownList id="XDropDownList8" HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'" runat="server" Width="220px" XDataBind="DF_SA_MarketInquiry.CustomerDeliveryWay" XDataSource="TableName:V_DF_SA_SS_CustomerDelivery;Filter:BufferType:RuntimeUpdate" ValueColumn="Name" DisplayColumn="Name" Express="javascript('ClearlyStateDelivery',DF_SA_MarketInquiry.BillingCompany,DF_SA_MarketInquiry.CustomerDeliveryWay)" DisableExpress='DF_SA_MarketInquiry.BillingCompany=="1000东方中科北京" || DF_SA_MarketInquiry.BillingCompany=="1010东方中科上海" ||DF_SA_MarketInquiry.BillingCompany=="1020东方中科深圳" || DF_SA_MarketInquiry.BillingCompany=="2100苏州博德"' PromptText="--请选择--">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                        <aspxform:XLabel id="XLabel131" runat="server" HiddenExpress="1" XDataBind="kehujiaohuofangshi" Value ValueToDisplayText Text="客户交货方式"></aspxform:XLabel>
                    </td>
                    
                    <td class="ts">
                        <asp:Label id="XLabel174" HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel110" runat="server" text="直发的机场" valuetodisplaytext value HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'"></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox id="XTextBox29" HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.NonstopAirport" HiddenInput="False" Express="javascript('ClearlyStateDelivery',DF_SA_MarketInquiry.BillingCompany,NonstopAirport)" DisableExpress='DF_SA_MarketInquiry.CustomerDeliveryWay == "HOSIC送货到客户香港指定地点"||DF_SA_MarketInquiry.CustomerDeliveryWay == "客户到HOSIC办公室自提"||DF_SA_MarketInquiry.CustomerDeliveryWay == "客户到供应商处自提" || DF_SA_MarketInquiry.BillingCompany=="1000东方中科北京" || DF_SA_MarketInquiry.BillingCompany=="1010东方中科上海" ||DF_SA_MarketInquiry.BillingCompany=="1020东方中科深圳" || DF_SA_MarketInquiry.BillingCompany=="2100苏州博德"'></aspxform:XTextBox>
                        <aspxform:XDropDownList id="XDropDownList43" runat="server" HiddenExpress="1" XDataBind="NonstopAirport" DataMap="NonstopAirport->DF_SA_MarketInquiry.NonstopAirport" XDataSource="TableName:V_DF_SA_ReferringSingle;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID;BufferType:RuntimeUpdate" ValueColumn="NonstopAirport" DisplayColumn="NonstopAirport">
                            <asp:ListItem>未绑定</asp:ListItem>
                        </aspxform:XDropDownList>
                    </td>
                </tr>
                <tr HiddenExpress="DF_SA_MarketInquiry.BillingCompany!='2000上海颐合'&amp;&amp;DF_SA_MarketInquiry.BillingCompany!='A300HOSIC 香港'">
                    <td class="tsbottomlabel">
                        <asp:Label id="XLabel175" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel118" runat="server" text="是否免税" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomlabel">
                        <aspxform:XRadioButtonList id="XRadioButtonList2"  runat="server" XDataBind="DF_SA_MarketInquiry.Exemption" RepeatDirection="Horizontal">
                            <asp:ListItem>是</asp:ListItem>
                            <asp:ListItem>否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                        <aspxform:XTextBox id="xtxtExemption" runat="server" HiddenExpress="1" Express="javascript('ISExemption',DF_SA_MarketInquiry.BillingCompany)"></aspxform:XTextBox>
                    </td>
                    <td height="14" class="tsbottomlabel">
                        <asp:Label id="XLabel181" runat="server" text="免税说明" valuetodisplaytext value></asp:Label></td>
                    <td class="tsbottomtext" colspan="3">
                        <aspxform:XTextBox id="XTextBox148" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.DescriptionExemption" Value DisableExpress="DF_SA_MarketInquiry.Exemption=='否' || DF_SA_MarketInquiry.Exemption==''" ToolTip="特殊说明：如一张免表分批发货，或一个订单分两免表等"></aspxform:XTextBox>
                   <aspxform:XTextBox runat="server" Width="100px" HiddenExpress="1" ID="bhPurchasingPattern" XDataBind="bhPurchasingPattern" Express="javascript('bhPurchasingPattern',DF_SA_MarketInquiryApparatusList.PurchasingPattern)"></aspxform:XTextBox>
                   </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'||bhPurchasingPattern!='1'">
                    <td class="ts">
                         <asp:Label id="Label75" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="xlableImmediateDelivery" runat="server">立即出货</asp:Label>
                        </td>
                     <td class="ts1" colspan="2" style="border-right: #93a1ae 0px solid;">
                           <aspxform:XTextBox runat="server"  HiddenExpress="1" ID="IsImmediateDelivery"  XDataBind="IsImmediateDelivery"></aspxform:XTextBox>
                         <%--if(DF_SA_PTPClientMessage.IsContractBusiness!='是'||bhPurchasingPattern!='1','','')--%>
                            <aspxform:XRadioButtonList id="XRadioImmediateDelivery"   Express="javascript('getDelivery',DF_SA_PTPClientMessage.IsContractBusiness,bhPurchasingPattern,IsImmediateDelivery)" runat="server"  XDataBind="DF_SA_MarketInquiry.IsImmediateDelivery" RepeatDirection="Horizontal">
                            <asp:ListItem>是</asp:ListItem>
                            <asp:ListItem>否</asp:ListItem>
                        </aspxform:XRadioButtonList>
                        
                     </td>
                    <td class="ts" colspan="3" style="border-left: #b2bcc6 0px solid">
                        <asp:Label id="xlable175" style="margin-left: -290px;" runat="server" HiddenExpress="DF_SA_MarketInquiry.IsImmediateDelivery=='否' || DF_SA_MarketInquiry.IsImmediateDelivery==''" forecolor="blue">注意：请先查询库存，整单都是备货产品，且备货产品都有实际可用库存时才能立即出货。</asp:Label>
                    </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || DF_SA_MarketInquiry.IsImmediateDelivery!='是'">
                     <td class="ts">
                          <asp:Label  id="Label77" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="Label78" runat="server">出库方式</asp:Label>
                         </td>
                      <td class="ts1" colspan="5">
                          <aspxform:XTextBox runat="server" ID="txtDeliveryWay" HiddenExpress="1" XDataBind="DeliveryWay"></aspxform:XTextBox>
                          <%--DF_SA_PTPClientMessage.IsContractBusiness=='是'&&DF_SA_MarketInquiry.IsImmediateDelivery=='否','发货到客户', ''--%>
                          <aspxform:XDropDownList ID="DeliveryWay" onchange="GetFZJG()"  Express="javascript('getDeliveryWay',DF_SA_PTPClientMessage.IsContractBusiness,DF_SA_MarketInquiry.IsImmediateDelivery,DeliveryWay)" runat="server" XDataBind="DF_SA_MarketInquiry.DeliveryWay" Width="150px"  PromptText="----请选择----" Height="20px">
                            <asp:ListItem>自提</asp:ListItem>
                            <asp:ListItem>发货到客户</asp:ListItem>
                            <asp:ListItem>发货到分支机构</asp:ListItem>
                        </aspxform:XDropDownList>

                          <%--<aspxform:XTextBox runat="server" XDataBind="FZJG" Express="javascript('GetFZJG',DF_SA_MarketInquiry.DeliveryWay,FZJGZ)"></aspxform:XTextBox>--%>
                          <aspxform:XTextBox runat="server" ID="FZJGZ" HiddenExpress="1" XDataBind="FZJGZ" ></aspxform:XTextBox>

                           
                         </td>
                </tr>
                 <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构' ) " >
                    <td height="16" class="title1" colspan="6">
                        <asp:Label id="txtFzjg" runat="server" text="分支机构地址信息：" valuetodisplaytext value font-size="14px"></asp:Label>&nbsp; 
                     </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构' ) ">
                     <td class="ts">
                          <aspxform:XLabel ID="XLabel95" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到分支机构"'></aspxform:XLabel>
                        <asp:Label ID="Label79" runat="server" Text="分支机构" hiddenexpress="DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'"></asp:Label>
                          <aspxform:XTextBox ID="BranchID" runat="server" XDataBind="DF_SA_MarketInquiry.BranchID" Width="20px" HiddenInput="True" BorderColor="#DCDCDC" BorderWidth="1"></aspxform:XTextBox>
                         </td>
                      <td class="ts1"  colspan="2">
                          <aspxform:XTextBox class="text" ID="XTextBox193" runat="server" XDataBind="DF_SA_MarketInquiry.Branch" BackColor="#E6F1F8" Width="150" BorderColor="#DCDCDC" BorderWidth="1" DisableBehavior="ReadOnly" ReadOnly="True" HiddenExpress="DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'" DisableExpress="1"></aspxform:XTextBox>
                        <aspxform:XCustomBrowserButton ID="XCustomBrowserButton6"  runat="server" Text="查询" XClass="Oimec.Dialogs.BranchInfoButton" DataMap="BranchID->DF_SA_MarketInquiry.BranchID;Branch->DF_SA_MarketInquiry.Branch;InitBranch->varBranch;Address->DF_SA_MarketInquiry.ReceivingAddress;CompanyName->DF_SA_MarketInquiry.UserCompanyName;Contact->DF_SA_MarketInquiry.ReceivingContacts;Phone->DF_SA_MarketInquiry.ReceivingLandline;Mobile->DF_SA_MarketInquiry.ReceivingPhone;ZipCode->DF_SA_MarketInquiry.ReceivingPostcode" Width="40px" hiddenexpress="DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'" Filter="Branch->DF_SA_MarketInquiry.Branch,InitBranch->varBranch,Address->DF_SA_MarketInquiry.ReceivingAddress,CompanyName->DF_SA_MarketInquiry.UserCompanyName,Contact->DF_SA_MarketInquiry.ReceivingContacts,Phone->DF_SA_MarketInquiry.ReceivingLandline,Mobile->DF_SA_MarketInquiry.ReceivingPhone,ZipCode->DF_SA_MarketInquiry.ReceivingPostcode"></aspxform:XCustomBrowserButton>
                         <aspxform:XTextBox ID="XTextBox196" runat="server" XDataBind="varBranch" Width="50px" HiddenInput="True" BorderColor="#DCDCDC" BorderWidth="1"></aspxform:XTextBox>
                           </td>
                    <td class="ts">
                        <asp:Label ID="Label80" runat="server" Text="*" ForeColor="Red" ></asp:Label>&nbsp;<asp:Label ID="Label81" runat="server" Text="收货公司名称" ></asp:Label>
                        <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户'||DF_SA_MarketInquiry.DeliveryWay=='',DF_SA_PTPClientMessage.ClientBPMID,'')--%>
                        <aspxform:XTextBox ID="XTextBox194" runat="server" XDataBind="CustomerID" Express="javascript('getCustomerID',DF_SA_MarketInquiry.DeliveryWay,DF_SA_PTPClientMessage.ClientBPMID,ysCustomerID)" BackColor="#E6F1F8" Width="20px" Min="0" Max="0" ValueToDisplayText HiddenInput="true" BorderColor="Gainsboro" BorderWidth="1px" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                        </td>
                      <td class="ts1" colspan="2">
                          <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户',DF_SA_PTPClientMessage.PTPName,'')--%>
                            <aspxform:XTextBox ID="XTextBox195" runat="server" XDataBind="DF_SA_MarketInquiry.UserCompanyName" Express="javascript('getUserCompanyName',DF_SA_MarketInquiry.DeliveryWay,DF_SA_PTPClientMessage.PTPName,ysUserCompanyName)" BackColor="#E6F1F8" Width="70%" Min="0" Max="0" ValueToDisplayText HiddenInput="False" BorderColor="Gainsboro" BorderWidth="1px" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                        &nbsp;<aspxform:XCustomBrowserButton DataMap="CustomerNameCH->DF_SA_MarketInquiry.UserCompanyName;CustomerID->CustomerID;" ID="XCustomBrowserButton9" runat="server" Text="查询" XClass="Oimec.Dialogs.SelCustomerButton" Width="40px" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay=="发货到分支机构"' Height="25px"></aspxform:XCustomBrowserButton>
                        <aspxform:XDataBrowserButton ID="XDataBrowserButton8"  DataMap="ID->CustomerID;CompanyName->DF_SA_MarketInquiry.UserCompanyName;CompanyAddress->DF_SA_MarketInquiry.ReceivingAddress;CompanyZipCode->DF_SA_MarketInquiry.ReceivingPostcode" runat="server" Text="查询" XDataSource="TableName:DF_FI_BranchCompany;Filter:BranchID->DF_SA_MarketInquiry.BranchID" Width="40px" HiddenExpress="DF_SA_MarketInquiry.DeliveryWay!=&quot;发货到分支机构&quot;"   Height="22px" DisplayColumns="CompanyName:公司名称,260;CompanyAddress:公司地址,300;CompanyZipCode:邮编,60"></aspxform:XDataBrowserButton>
                    
                          <aspxform:XTextBox runat="server" XDataBind="DF_SA_MarketInquiry.FZCustomerID" Express="CustomerID" HiddenExpress="1"></aspxform:XTextBox>
                           <aspxform:XTextBox runat="server" ID="ysCustomerID" XDataBind="ysCustomerID" HiddenExpress="1"></aspxform:XTextBox>
                           <aspxform:XTextBox runat="server" ID="ysUserCompanyName" XDataBind="ysUserCompanyName" HiddenExpress="1"></aspxform:XTextBox>
                          </td>
                    
                </tr>
                 <tr  HiddenExpress="1">
                      <td class="ts">
                            <aspxform:XLabel ID="XLabel151" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到分支机构"'></aspxform:XLabel> <asp:Label id="Label98" runat="server">收货省市</asp:Label>
                         <aspxform:XLabel runat="server" HiddenExpress="1" XDataBind="ProvinceID"></aspxform:XLabel>
                        </td>
                      <td class="ts1" colspan="2">
                              </td>
                      <td class="ts">
                        </td>
                      <td class="ts1" colspan="2">
                          </td>
                </tr>
                 <tr    HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'">
                     <td class="ts">
                         <aspxform:XLabel ID="XLabel150" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到分支机构"'></aspxform:XLabel> <asp:Label id="Label35" runat="server">收货详细地址</asp:Label>
                         <%--<aspxform:XDropDownList runat="server" XDataSource="TableName:V_DF_MContact;Filter:CustomerID->DF_SA_PTPClientMessage.ClientBPMID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID;OrderBy:IsDefaultReceipt desc" DataMap="ContactAddr->DF_SA_MarketInquiry.ReceivingAddress;ContactName->DF_SA_MarketInquiry.ReceivingContacts;ContactTel->DF_SA_MarketInquiry.ReceivingLandline;ZipCode->DF_SA_MarketInquiry.ReceivingPostcode;ContactEmail->DF_SA_MarketInquiry.ReceivingEmail;ContactMobile->DF_SA_MarketInquiry.ReceivingPhone;" HiddenExpress="1"></aspxform:XDropDownList>--%>
                      </td>
                     <td class="ts1" colspan="3">
                             <aspxform:XTextBox name="ProvinceText" ID="XDropDownList48" Width="140" runat="server" XDataBind="DF_SA_MarketInquiry.Province" DisableExpress="1"></aspxform:XTextBox>
                          <aspxform:XDataBrowserButton DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' " id="XDataBrowserButton16" runat="server" Width="35px"   Text="查询" XDataSource="TableName:DF_Comm_Province;" DataMap="ProvinceID->ProvinceID;ProvinceName->DF_SA_MarketInquiry.Province;''->DF_SA_MarketInquiry.City;"   Height="25px" DisplayColumns="ProvinceName:省份,100;"></aspxform:XDataBrowserButton>
                        <aspxform:XTextBox name="CityText" ID="XDropDownList49" Width="140" runat="server" XDataBind="DF_SA_MarketInquiry.City" DisableExpress="1"></aspxform:XTextBox>
                         <aspxform:XDataBrowserButton DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' " id="XDataBrowserButton17" runat="server" Width="35px"   Text="查询" XDataSource="TableName:DF_Comm_City;Filter:ProvinceID->ProvinceID" DataMap="CityName->DF_SA_MarketInquiry.City;"   Height="25px" DisplayColumns="CityName:市,100;"></aspxform:XDataBrowserButton>
                      
                       <aspxform:XTextBox runat="server"    BackColor="#E6F1F8"  DisableExpress="1" ID="ReceivingAddress" XDataBind="DF_SA_MarketInquiry.ReceivingAddress" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"></aspxform:XTextBox>
                           <aspxform:XTextBox runat="server" ID="ysCity" XDataBind="ysCity" HiddenExpress="1"></aspxform:XTextBox>
                          </td>
                      <td class="ts">
                          <aspxform:XLabel ID="XLabel152" HiddenExpress="1" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" ></aspxform:XLabel> <asp:Label id="Label36" runat="server">联系人</asp:Label>
                         
                           </td>
                       <td class="ts1">
                           <aspxform:XTextBox runat="server" ID="ReceivingContacts" BackColor="#E6F1F8" XDataBind="DF_SA_MarketInquiry.ReceivingContacts" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox><%--Global.StepName!='业务员发起申请'  &amp;&amp; Global.StepName!='业务员确认1'  &amp;&amp;Global.StepName!='业务员确认2'--%>
                           <aspxform:XDataBrowserButton  id="XDataBrowserButton6" runat="server" Width="35px"   Text="查询" XDataSource="TableName:V_DF_MasterData_InvoiceContact;Filter:CustomerID->CustomerID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID" DataMap="ContactAddr->DF_SA_MarketInquiry.ReceivingAddress;ContactName->DF_SA_MarketInquiry.ReceivingContacts;ContactTel->DF_SA_MarketInquiry.ReceivingLandline;ZipCode->DF_SA_MarketInquiry.ReceivingPostcode;ContactEmail->DF_SA_MarketInquiry.ReceivingEmail;ContactMobile->DF_SA_MarketInquiry.ReceivingPhone;" HiddenExpress="DF_SA_MarketInquiry.DeliveryWay=='发货到分支机构'" Height="25px" DisplayColumns="ContactName:联系人,60;ContactTel:电话,100;ContactMobile:手机号,120;ContactEmail:邮箱,120;ContactAddr:地址,150;ZipCode:邮编,100;InvoiceMailingSex:称呼"></aspxform:XDataBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton5" runat="server" Width="35px" XClass="Oimec.Dialogs.ContactDefaultAddButton" Text="新建" Height="25px" Filter="OwnerAccount->DF_SA_MarketInquiry.SalesmanID,CustomerID->CustomerID" BrowserWindowType="AjaxPanel"  HiddenExpress="DF_SA_MarketInquiry.DeliveryWay=='发货到分支机构'" ></aspxform:XCustomBrowserButton>
                 <aspxform:XDataBrowserButton  ID="XDataBrowserButton10" runat="server" Text="查询" Width="41px" DataMap="ContactName->DF_SA_MarketInquiry.ReceivingContacts;Telphone->DF_SA_MarketInquiry.ReceivingLandline;Mobile->DF_SA_MarketInquiry.ReceivingPhone" HiddenExpress="DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'" XDataSource="TableName:DF_FI_BranchContact;Filter:BranchID->DF_SA_MarketInquiry.BranchID"  Height="25px" DisplayColumns="ContactName:联系人,100;Telphone:电话,200;Mobile:手机,100" PrintOut="False"></aspxform:XDataBrowserButton>
                   
                            </td>
                       
                 </tr>
                 <tr  HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' || DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'">
                      <td class="ts">
                        <asp:Label id="Label48" runat="server">邮编</asp:Label>
                      </td>
                        <td class="ts1">
                             <aspxform:XTextBox runat="server" ID="ReceivingPostcode" XDataBind="DF_SA_MarketInquiry.ReceivingPostcode" BackColor="#E6F1F8" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                      <td class="ts">
                              <asp:Label id="Label37" runat="server">座机</asp:Label>
                          </td>
                        <td class="ts1">
                            <aspxform:XTextBox runat="server" ID="ReceivingLandline" BackColor="#E6F1F8" XDataBind="DF_SA_MarketInquiry.ReceivingLandline" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                          </td>
                      <td class="ts" hidden="hidden">
                        <asp:Label id="Label52" HiddenExpress="1"  runat="server">Email</asp:Label>
                      </td>
                        <td class="ts1" hidden="hidden">
                             <aspxform:XTextBox HiddenExpress="1" runat="server" ID="ReceivingEmail" XDataBind="DF_SA_MarketInquiry.ReceivingEmail" BackColor="#E6F1F8" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                       <td class="ts">
                        <asp:Label id="Label53" runat="server">手机</asp:Label>
                      </td>
                        <td class="ts1">
                             <aspxform:XTextBox runat="server" ID="ReceivingPhone" XDataBind="DF_SA_MarketInquiry.ReceivingPhone" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                  </tr>
                  <tr  HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                    <td height="16" class="title1" colspan="6">
                        <asp:Label id="Label87" runat="server" text="客户收货地址信息" valuetodisplaytext value font-size="14px"></asp:Label>&nbsp; 
                     </td>
                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'  ">
                    
                     <td class="ts">
                             <aspxform:XLabel ID="XLabel142" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到客户"'></aspxform:XLabel>&nbsp;<asp:Label ID="Label96" runat="server" Text="收货公司名称" ></asp:Label>
                       <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户'||DF_SA_MarketInquiry.DeliveryWay=='',DF_SA_PTPClientMessage.ClientBPMID,'')--%>
                          <aspxform:XTextBox ID="XTextBox198" runat="server" XDataBind="POCustomerID" Express="javascript('getPOCustomerID',DF_SA_MarketInquiry.DeliveryWay,DF_SA_PTPClientMessage.ClientBPMID,ysPOCustomerID)" BackColor="#E6F1F8" Width="20px" Min="0" Max="0" ValueToDisplayText HiddenInput="true" BorderColor="Gainsboro" BorderWidth="1px" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server" XDataBind="DF_SA_MarketInquiry.CustomerIDPO" Express="POCustomerID" HiddenExpress="1"></aspxform:XTextBox>
                           <aspxform:XTextBox runat="server" ID="ysPOCustomerID" XDataBind="ysPOCustomerID" HiddenExpress="1"></aspxform:XTextBox>
                     </td>
                      <td class="ts1"  >
                          <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户',DF_SA_PTPClientMessage.PTPName,'')--%>
                            <aspxform:XTextBox ID="XTextBox199" runat="server" XDataBind="DF_SA_MarketInquiry.POUserCompanyName" Express="javascript('getPOUserCompanyName',DF_SA_MarketInquiry.DeliveryWay,DF_SA_PTPClientMessage.PTPName,ysPOUserCompanyName,DF_SA_PTPClientMessage.IsContractBusiness)" BackColor="#E6F1F8" Width="70%" Min="0" Max="0" ValueToDisplayText HiddenInput="False" BorderColor="Gainsboro" BorderWidth="1px" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                        &nbsp;<aspxform:XCustomBrowserButton DataMap="CustomerNameCH->DF_SA_MarketInquiry.POUserCompanyName;CustomerID->POCustomerID;POReceivingAddress->DF_SA_MarketInquiry.POReceivingAddress;POReceivingContacts->DF_SA_MarketInquiry.POReceivingContacts;POReceivingLandline->DF_SA_MarketInquiry.POReceivingLandline;POReceivingPostcode->DF_SA_MarketInquiry.POReceivingPostcode;POReceivingEmail->DF_SA_MarketInquiry.POReceivingEmail;POReceivingPhone->DF_SA_MarketInquiry.POReceivingPhone;" ID="XCustomBrowserButton12" runat="server" Text="查询" XClass="Oimec.Dialogs.SelCustomerButton" Width="40px"  Height="25px"></aspxform:XCustomBrowserButton>
                       
                          </td>
                     <td class="ts">
                             <aspxform:XLabel ID="XLabel143" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到客户"'></aspxform:XLabel>  <asp:Label id="Label89" runat="server">联系人</asp:Label>
                          </td>
                       <td class="ts1" colspan="3">
                           <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户' ,POReceivingContacts,'')--%>
                           <aspxform:XTextBox runat="server" Express="javascript('getPOReceivingContacts',DF_SA_MarketInquiry.DeliveryWay,POReceivingContacts,ysPOReceivingContacts,DF_SA_PTPClientMessage.IsContractBusiness)" ID="POReceivingContacts" BackColor="#E6F1F8" XDataBind="DF_SA_MarketInquiry.POReceivingContacts" BorderWidth="1" BorderColor="#DCDCDC" Width="15%"  DisableExpress="1"></aspxform:XTextBox><%--Global.StepName!='业务员发起申请'  &amp;&amp; Global.StepName!='业务员确认1'  &amp;&amp;Global.StepName!='业务员确认2'--%>
                            <aspxform:XDataBrowserButton  id="XDataBrowserButton13" runat="server" Width="35px"   Text="查询" XDataSource="TableName:V_DF_MasterData_InvoiceContact;Filter:CustomerID->POCustomerID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID" DataMap="ContactAddr->DF_SA_MarketInquiry.POReceivingAddress;ContactName->DF_SA_MarketInquiry.POReceivingContacts;ContactTel->DF_SA_MarketInquiry.POReceivingLandline;ZipCode->DF_SA_MarketInquiry.POReceivingPostcode;ContactEmail->DF_SA_MarketInquiry.POReceivingEmail;ContactMobile->DF_SA_MarketInquiry.POReceivingPhone;"   Height="25px" DisplayColumns="ContactName:联系人,100;ContactTel:电话,100;ContactMobile:手机号,120;ContactEmail:邮箱,120;ContactAddr:地址,150;ZipCode:邮编,100;InvoiceMailingSex:称呼"></aspxform:XDataBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton11" runat="server" Width="35px" XClass="Oimec.Dialogs.ContactDefaultAddButton" Text="新建" Height="25px" Filter="OwnerAccount->DF_SA_MarketInquiry.SalesmanID,CustomerID->POCustomerID" BrowserWindowType="AjaxPanel"   ></aspxform:XCustomBrowserButton>
                      
                            </td>
                    
                </tr>
                <tr HiddenExpress="1">
                      <td class="ts">
                               <aspxform:XLabel ID="XLabel141" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到客户"'></aspxform:XLabel>  <asp:Label id="Label97" runat="server">收货省市</asp:Label>
                         <aspxform:XLabel runat="server" HiddenExpress="1" XDataBind="POProvinceID"></aspxform:XLabel>
                        </td>
                      <td class="ts1" colspan="2">
                             </td>
                      <td class="ts">
                        </td>
                      <td class="ts1" colspan="2">
                          </td>
                </tr>
                 <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' ">
                     <td class="ts">
                                       <aspxform:XLabel ID="XLabel140" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress='DF_SA_MarketInquiry.DeliveryWay!="发货到客户"'></aspxform:XLabel> <asp:Label id="Label88" runat="server">收货详细地址</asp:Label>
                         <aspxform:XDropDownList runat="server" XDataSource="TableName:V_DF_MContact;Filter:CustomerID->DF_SA_PTPClientMessage.ClientBPMID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID,IsDefaultReceipt->'是';OrderBy:IsDefaultReceipt desc" DataMap="ContactAddr->POReceivingAddress;ContactName->POReceivingContacts;ContactTel->POReceivingLandline;ZipCode->POReceivingPostcode;ContactEmail->POReceivingEmail;ContactMobile->POReceivingPhone;Province->DF_SA_MarketInquiry.POprovince;City->DF_SA_MarketInquiry.POcity;ProvinceID->POProvinceID;" HiddenExpress="1"></aspxform:XDropDownList>
                        <aspxform:XTextBox runat="server"  XDataBind="POReceivingAddress" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  XDataBind="POReceivingContacts" HiddenExpress="1" ></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  XDataBind="POReceivingLandline" HiddenExpress="1"></aspxform:XTextBox>
                         <aspxform:XTextBox runat="server"  XDataBind="POReceivingPostcode" HiddenExpress="1"></aspxform:XTextBox>
                         <aspxform:XTextBox runat="server"  XDataBind="POReceivingEmail" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  XDataBind="POReceivingPhone" HiddenExpress="1"></aspxform:XTextBox>
                         <aspxform:XTextBox runat="server"  XDataBind="POUserCompanyName"  HiddenExpress="1"></aspxform:XTextBox>

                          <aspxform:XTextBox runat="server"  ID="ysPOUserCompanyName" XDataBind="ysPOUserCompanyName" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  ID="ysPOReceivingAddress" XDataBind="ysPOReceivingAddress" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  ID="ysPOReceivingContacts" XDataBind="ysPOReceivingContacts" HiddenExpress="1"></aspxform:XTextBox>
                           <aspxform:XTextBox runat="server"  ID ="ysPOReceivingLandline" XDataBind="ysPOReceivingLandline" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  ID ="ysPOReceivingPostcode" XDataBind="ysPOReceivingPostcode" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  ID ="ysPOReceivingEmail" XDataBind="ysPOReceivingEmail" HiddenExpress="1"></aspxform:XTextBox>
                          <aspxform:XTextBox runat="server"  ID ="ysPOReceivingPhone" XDataBind="ysPOReceivingPhone" HiddenExpress="1"></aspxform:XTextBox>
                     </td>
                     <td class="ts1" colspan="5">
					  <aspxform:XTextBox name="POprovinceText" ID="XDropDownList46" Width="140" runat="server" XDataBind="DF_SA_MarketInquiry.POprovince" DisableExpress="1"></aspxform:XTextBox>
                          <aspxform:XDataBrowserButton DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' " id="XDataBrowserButton14" runat="server" Width="35px"   Text="查询" XDataSource="TableName:DF_Comm_Province;" DataMap="ProvinceID->POProvinceID;ProvinceName->DF_SA_MarketInquiry.POprovince;''->DF_SA_MarketInquiry.POcity;"   Height="25px" DisplayColumns="ProvinceName:省份,100;"></aspxform:XDataBrowserButton>
                           <%--<aspxform:XDropDownList DisableExpress="1" ID="XDropDownList46" Style="height: 25px; width: 120px" runat="server" XDataBind="DF_SA_MarketInquiry.POprovince" DataMap="ProvinceID->POProvinceID" DisplayColumn="ProvinceName" ValueColumn="ProvinceName" XDataSource="TableName:DF_Comm_Province" PromptText="----请选择----"></aspxform:XDropDownList>--%>
                           <aspxform:XTextBox name="POcityText" ID="XDropDownList47" Width="140" runat="server" XDataBind="DF_SA_MarketInquiry.POcity" DisableExpress="1"></aspxform:XTextBox>
                         <aspxform:XDataBrowserButton DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' " id="XDataBrowserButton15" runat="server" Width="35px"   Text="查询" XDataSource="TableName:DF_Comm_City;Filter:ProvinceID->POProvinceID" DataMap="CityName->DF_SA_MarketInquiry.POcity;"   Height="25px" DisplayColumns="CityName:市,100;"></aspxform:XDataBrowserButton>
                      
                            <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户' ,POReceivingAddress,'')--%>
                       <aspxform:XTextBox runat="server"  Express="javascript('getPOReceivingAddress',DF_SA_MarketInquiry.DeliveryWay,POReceivingAddress,ysPOReceivingAddress,DF_SA_PTPClientMessage.IsContractBusiness)"   BackColor="#E6F1F8"  DisableExpress="1" ID="POReceivingAddress" XDataBind="DF_SA_MarketInquiry.POReceivingAddress" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"></aspxform:XTextBox>
                       <aspxform:XTextBox runat="server" ID="ysPOcity" XDataBind="ysPOcity" HiddenExpress="1"></aspxform:XTextBox>
                           </td>
                     
                       
                 </tr>
                 <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' ">
                      <td class="ts">
                        <asp:Label id="Label91" runat="server">邮编</asp:Label>
                          <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户' ,POReceivingPostcode,'')--%>
                      </td>
                        <td class="ts1">
                             <aspxform:XTextBox runat="server"  Express="javascript('getPOReceivingPostcode',DF_SA_MarketInquiry.DeliveryWay,POReceivingPostcode,ysPOReceivingPostcode,DF_SA_PTPClientMessage.IsContractBusiness)" ID="POReceivingPostcode" XDataBind="DF_SA_MarketInquiry.POReceivingPostcode" BackColor="#E6F1F8" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                      <td class="ts">
                              <asp:Label id="Label90" runat="server">座机</asp:Label>
                          </td>
                        <td class="ts1" >
                            <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户' ,POReceivingLandline,'')--%>
                            <aspxform:XTextBox runat="server"  Express="javascript('getPOReceivingLandline',DF_SA_MarketInquiry.DeliveryWay,POReceivingLandline,ysPOReceivingLandline,DF_SA_PTPClientMessage.IsContractBusiness)" ID="POReceivingLandline" BackColor="#E6F1F8" XDataBind="DF_SA_MarketInquiry.POReceivingLandline" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                          </td>
                      <td class="ts" hidden="hidden">
                             <aspxform:XLabel ID="XLabel144" HiddenExpress="1" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" ></aspxform:XLabel><asp:Label id="Label92"  HiddenExpress="1" runat="server">Email</asp:Label>
                      </td>
                        <td class="ts1" hidden="hidden">
                            <%--if(DF_SA_MarketInquiry.DeliveryWay=='发货到客户' ,POReceivingEmail,'')--%>
                             <aspxform:XTextBox runat="server" HiddenExpress="1" Express="javascript('getPOReceivingEmail',DF_SA_MarketInquiry.DeliveryWay,POReceivingEmail,ysPOReceivingEmail,DF_SA_PTPClientMessage.IsContractBusiness)" ID="POReceivingEmail" XDataBind="DF_SA_MarketInquiry.POReceivingEmail" BackColor="#E6F1F8" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                       <td class="ts">
                        <asp:Label id="Label93" runat="server">手机</asp:Label>
                      </td>
                        <td class="ts1">
                             <aspxform:XTextBox runat="server"  Express="javascript('getPOReceivingPhone',DF_SA_MarketInquiry.DeliveryWay,POReceivingPhone,ysPOReceivingPhone,DF_SA_PTPClientMessage.IsContractBusiness)" ID="POReceivingPhone" XDataBind="DF_SA_MarketInquiry.POReceivingPhone" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" Width="70%"  DisableExpress="1"></aspxform:XTextBox>
                        </td>
                  </tr>
                <tr HiddenExpress="bhPurchasingPattern!='0'">
                     <td class="ts">
                       <aspxform:XLabel ID="XLabel153" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" ></aspxform:XLabel> <asp:Label id="Label54" runat="server">整单/分批交货</asp:Label>
                      </td>
                     <td class="ts1">
                           <aspxform:XDropDownList id="DeliveryBatch" Width="70%" runat="server" XDataBind="DF_SA_MarketInquiry.DeliveryBatch"  DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' &amp;&amp;Global.StepName!='业务员确认2'" PromptText="--请选择--">
                                <asp:ListItem>整单</asp:ListItem>
                                <asp:ListItem>分批</asp:ListItem>
                                <asp:ListItem>货到即发</asp:ListItem>
                            </aspxform:XDropDownList>
                   </td>
                     <td class="ts">
                        <asp:Label id="Label55" runat="server" HiddenExpress="DF_SA_MarketInquiry.DeliveryBatch!='分批'">分批交货备注</asp:Label>
                      </td>
                     <td class="ts1" colspan="3">
                           <aspxform:XTextBox Rows="3" HiddenExpress="DF_SA_MarketInquiry.DeliveryBatch!='分批'" runat="server" ID="BatchdeliveryRemarks" Width="100%" XDataBind="DF_SA_MarketInquiry.BatchdeliveryRemarks" TextMode="MultiLine" DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' &amp;&amp;Global.StepName!='业务员确认2'"></aspxform:XTextBox>
                     </td>
                </tr>
                <tr HiddenExpress="DF_SA_MarketInquiry.IsImmediateDelivery!='是' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'&amp;&amp;DF_SA_MarketInquiry.DeliveryWay!='发货到客户') ">
                     <td class="ts"  >
                        <asp:Label ID="Label56" runat="server" Text="发运要求"></asp:Label>
                          <aspxform:XTextBox ID="XTextBox149" runat="server" XDataBind="varRequire" Width="50px" HiddenInput="True" BorderColor="#DCDCDC" BorderWidth="1" Express="javascript('checkSendRequire',DF_SA_MarketInquiry.ShippingRequirements)"></aspxform:XTextBox>
                     </td>
                    <td class="ts1"   colspan="3">
                        <div id="div_ShippingRequirements">
                            <aspxform:XCheckBoxList ID="ShippingRequirements" runat="server" XDataBind="DF_SA_MarketInquiry.ShippingRequirements" RepeatDirection="Horizontal" name="ShippingRequirements" DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' &amp;&amp;Global.StepName!='业务员确认2'">
                                <asp:ListItem>次日达</asp:ListItem>
                                <asp:ListItem>签收单、运单备注客户PO号</asp:ListItem>
                                <asp:ListItem>用户指定文件需要随货发运</asp:ListItem>
                                <asp:ListItem>周末可正常送货</asp:ListItem>
                                  <asp:ListItem>透明胶带</asp:ListItem>
                                 <asp:ListItem>不返客户验收单</asp:ListItem>
                            </aspxform:XCheckBoxList>
                        </div>
                    </td>
                      <td class="ts"  >
                        <asp:Label ID="Label57" runat="server" Text="发运要求备注"></asp:Label>
                     </td>
                       <td class="ts1"  >
                            <aspxform:XTextBox Rows="3" ID="ShippingRequirementsRemarks" Width="100%" runat="server" XDataBind="DF_SA_MarketInquiry.ShippingRequirementsRemarks" TextMode="MultiLine" DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' &amp;&amp;Global.StepName!='业务员确认2'"></aspxform:XTextBox>
                      </td>
                </tr>
                  <tr HiddenExpress="DF_SA_MarketInquiry.IsImmediateDelivery!='是'|| varRequire!='1' || (DF_SA_MarketInquiry.DeliveryWay!='发货到分支机构'&amp;&amp;DF_SA_MarketInquiry.DeliveryWay!='发货到客户')  ">
                       <td class="ts"  >
                        <asp:Label ID="Label58" runat="server" Text="其他附件"></asp:Label>
                     </td>
                       <td class="ts1"   colspan="3">
                            <aspxform:XAttachments runat="server" Width="50%"  ID="OtherAttachment" XDataBind="DF_SA_MarketInquiry.OtherAttachment" FileTypes="*.doc;*.docx;*.xls;*.xlsx;*.pdf;*.jpg;*.gif;*.png;*.EML,*.MSG" DisableExpress="Global.StepName!='业务员发起申请' &amp;&amp;Global.StepName!='业务员确认1' &amp;&amp;Global.StepName!='业务员确认2'"/>
                       </td>
                       <td class="ts"  colspan="3" >
                            <asp:Label ID="Label76" runat="server" forecolor="blue" Text="若勾选了“□用户指定文件需要随货发运”，则必须上传“其他附件“"></asp:Label>
                           </td>
                     
                  </tr>

              
            </tbody>
        </table>
        <br HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'"/>
       <table  HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'" width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
           <tbody>
                  <tr hidden="hidden">
                      <td class="ts" >
                           <asp:Label id="Label82" runat="server" text="寄票方式" valuetodisplaytext value></asp:Label>
                      </td>
                      <td class="ts1" colspan="2">
                           <aspxform:XDropDownList ID="MailTicketDropDownList" onchange="GetMailTicket()" runat="server" Width="220px" XDataBind="DF_SA_MarketInquiry.MailTicket" XDataSource='TableName:DF_DataSourceList;Filter:Type->"邮寄方式"' PromptText="--请选择--" DisplayColumn="Name" ValueColumn="Name" >
                                <asp:ListItem>未绑定</asp:ListItem>
                            </aspxform:XDropDownList>
                      </td>
                     <td class="ts">
                           <asp:Label id="Label83" runat="server"  HiddenExpress="DF_SA_MarketInquiry.MailTicket!='邮寄分支机构'" text="分支机构" valuetodisplaytext value></asp:Label>
                         <aspxform:XTextBox runat="server" HiddenExpress="1" XDataBind="MailTicketBranchID"></aspxform:XTextBox>
                      </td>
                    <td class="ts1" colspan="2">
                           <aspxform:XDropDownList ID="BranchesDropDownList"   runat="server" Width="220px" XDataBind="DF_SA_MarketInquiry.MailTicketBranchID" HiddenExpress="DF_SA_MarketInquiry.MailTicket!='邮寄分支机构'" DataMap="BranchID->MailTicketBranchID" XDataSource="TableName:DF_FI_Branches;" PromptText="--请选择--" DisplayColumn="Branch" ValueColumn="BranchID"  AutoPostBack="false">
                                <asp:ListItem>未绑定</asp:ListItem>
                            </aspxform:XDropDownList>
                        <aspxform:XTextBox runat="server" ID="JPFS" HiddenExpress="1" XDataBind="JPFS"></aspxform:XTextBox>
                        </td>
                </tr>
                <tr hidden="hidden" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'|| (DF_SA_MarketInquiry.MailTicket!='邮寄分支机构' &amp;&amp;DF_SA_MarketInquiry.MailTicket!='邮寄客户') ">
                     <td class="ts" >
                           <asp:Label id="Label84" runat="server" text="收票公司名称" valuetodisplaytext value></asp:Label>
                      </td>
                     <td class="ts1" colspan="5">
                         
                            <aspxform:XTextBox ID="XTextBox197" runat="server" Width="60%" BorderColor="#DCDCDC" BorderWidth="1" Express="if(DF_SA_MarketInquiry.MailTicket=='邮寄客户',DF_SA_PTPClientMessage.PTPName,'')" XDataBind="DF_SA_MarketInquiry.TicketingCompany" Value   DisableExpress="1"></aspxform:XTextBox>
                            <aspxform:XTextBox ID="customID" runat="server" Width="60%" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.MailTicketCustomID" HiddenExpress="1" Value Express="MailTicketBpmID"  ></aspxform:XTextBox>
                            <aspxform:XCustomBrowserButton ID="XCustomBrowserButton10" DataMap="CustomerNameCH->DF_SA_MarketInquiry.TicketingCompany;CustomerID->MailTicketBpmID;" runat="server" Width="35px" XClass="Oimec.Dialogs.SelCustomerButton" HiddenExpress="DF_SA_MarketInquiry.MailTicket=='邮寄分支机构'" Text="查询"   Height="20px"></aspxform:XCustomBrowserButton>
                            <aspxform:XDataBrowserButton ID="XDataBrowserButton11"  DataMap="CompanyName->DF_SA_MarketInquiry.TicketingCompany;CompanyAddress->DF_SA_MarketInquiry.BillingAddress" runat="server" HiddenExpress="DF_SA_MarketInquiry.MailTicket!='邮寄分支机构'" Text="分支机构对应公司"  XDataSource="TableName:DF_FI_BranchCompany;Filter:BranchID->MailTicketBranchID" DisplayColumns="CompanyName:公司名称;CompanyAddress:公司地址"></aspxform:XDataBrowserButton>
               
                         </td>
                </tr>
               
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'" style="margin-top:2px;">
                     <td class="title1" colspan="6">
                        
                          <asp:Label id="Label99" runat="server" text="发票邮寄地址信息" valuetodisplaytext value ></asp:Label>&nbsp; 
                         </td>

                </tr>
                <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                     <td class="ts">
                         <aspxform:XTextBox runat="server" XDataBind="MailTicketBpmID" HiddenExpress="1" Express="if(DF_SA_MarketInquiry.MailTicket=='邮寄客户'|| DF_SA_MarketInquiry.MailTicket=='',DF_SA_PTPClientMessage.ClientBPMID,'')" ></aspxform:XTextBox>
                        <asp:Label id="Label61" runat="server" text="收票地址" valuetodisplaytext value></asp:Label>
                          <aspxform:XDropDownList runat="server" XDataSource="TableName:V_DF_MContact_TicketCollection;Filter:CustomerID->DF_SA_PTPClientMessage.ClientBPMID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID,IsDefaultTicketCollection->'是';OrderBy:IsDefaultTicketCollection desc" DataMap="ContactAddr->DF_SA_MarketInquiry.BillingAddress;ContactName->DF_SA_MarketInquiry.BillingContact;ContactTel->DF_SA_MarketInquiry.BillingLandline;ZipCode->DF_SA_MarketInquiry.BillingPostcode;ContactEmail->DF_SA_MarketInquiry.BillingEmail;ContactMobile->DF_SA_MarketInquiry.BillingPhone;" HiddenExpress="1"></aspxform:XDropDownList>
                     </td>
                    <td class="ts1">
                        <aspxform:XTextBox ID="BillingAddress" DisableExpress="1" Width="70%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingAddress"></aspxform:XTextBox>
                      <aspxform:XDataBrowserButton id="XDataBrowserButton7" runat="server" Width="35px"   Text="查询" HiddenExpress="DF_SA_MarketInquiry.MailTicket=='邮寄分支机构'" XDataSource="TableName:V_DF_MasterData_InvoiceContact;Filter:CustomerID->MailTicketBpmID,OwnerAccount->DF_SA_MarketInquiry.SalesmanID" DataMap="ContactAddr->DF_SA_MarketInquiry.BillingAddress;ContactName->DF_SA_MarketInquiry.BillingContact;ContactTel->DF_SA_MarketInquiry.BillingLandline;ZipCode->DF_SA_MarketInquiry.BillingPostcode;ContactEmail->DF_SA_MarketInquiry.BillingEmail;ContactMobile->DF_SA_MarketInquiry.BillingPhone;" Height="25px" DisplayColumns="ContactName:联系人,100;ContactTel:电话,100;ContactMobile:手机号,120;ContactEmail:邮箱,120;ContactAddr:地址,150;ZipCode:邮编,100;InvoiceMailingSex:称呼"></aspxform:XDataBrowserButton>
                        <aspxform:XCustomBrowserButton id="XCustomBrowserButton1" runat="server" Width="35px" HiddenExpress="DF_SA_MarketInquiry.MailTicket=='邮寄分支机构'" XClass="Oimec.Dialogs.ContactDefaultAddButton" Text="新建" Height="25px" Filter="OwnerAccount->DF_SA_MarketInquiry.SalesmanID,CustomerID->MailTicketBpmID" BrowserWindowType="AjaxPanel"></aspxform:XCustomBrowserButton>
                  <aspxform:XDataBrowserButton ID="XDataBrowserButton12" runat="server" HiddenExpress="DF_SA_MarketInquiry.MailTicket!='邮寄分支机构'" Text="查询" DataMap="ContactName->DF_SA_MarketInquiry.BillingContact;Telphone->DF_SA_MarketInquiry.BillingLandline;Mobile->DF_SA_MarketInquiry.BillingPhone;''->DF_SA_MarketInquiry.BillingEmail" XDataSource="TableName:DF_FI_BranchContact;Filter:BranchID->MailTicketBranchID" DisplayColumns="ContactName:联系人;Telphone:电话;Mobile:手机"></aspxform:XDataBrowserButton>
                     </td>
                     <td class="ts">
                        <asp:Label id="Label62" runat="server" text="联系人" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox ID="BillingContact" DisableExpress="1" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingContact"></aspxform:XTextBox>
                        </td>
                      <td class="ts">
                        <asp:Label id="Label63" runat="server" text="座机" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                        <aspxform:XTextBox ID="BillingLandline"  DisableExpress="1" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingLandline"></aspxform:XTextBox>
                        </td>
                       
                </tr>
                 <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                       <td class="ts">
                        <asp:Label id="Label64" runat="server" text="邮编" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                         <aspxform:XTextBox ID="BillingPostcode"  DisableExpress="1" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingPostcode"></aspxform:XTextBox>
                        </td>
                       <td class="ts">
                        <asp:Label id="Label66" runat="server" text="Email" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                         <aspxform:XTextBox ID="BillingEmail"  DisableExpress="1" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingEmail"></aspxform:XTextBox>
                        </td>
                        <td class="ts">
                        <asp:Label id="Label67" runat="server" text="手机" valuetodisplaytext value></asp:Label></td>
                    <td class="ts1">
                         <aspxform:XTextBox ID="BillingPhone"  DisableExpress="1" Width="100%" BorderWidth="1" BorderColor="#DCDCDC" BackColor="#E6F1F8" runat="server" XDataBind="DF_SA_MarketInquiry.BillingPhone"></aspxform:XTextBox>
                        </td>
               </tr>
           </tbody>
       </table>
        <br />
         <table width="1200" align="center" class="table" id="OrderRequire" >
             <tbody>
                <tr>
                    <td width="1200" class="title1" colspan="4">
                        <asp:Label id="Label186" runat="server" text="MEU/MEUR客户分类" valuetodisplaytext value></asp:Label>
                         
                    </td>
                </tr>
            <tbody>
                 <tr>
                         <td class="ts" style="WIDTH: 12%">
                           <asp:Label id="Label184" runat="server" text="MEU/MEUR客户分类"></asp:Label></td>
                           <td class="ts1" style="WIDTH:35%">
                              <aspxform:XDropDownList runat="server" Width="70%"   ID="MEUR" XDataBind="DF_SA_MarketInquiry.MEUR" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'" PromptText="--请选择--">
                                  <asp:ListItem>A类</asp:ListItem>
                                    <asp:ListItem>B类</asp:ListItem>
                                    <asp:ListItem>C类</asp:ListItem>
                                    <asp:ListItem>D类</asp:ListItem>
                                   <asp:ListItem>E类</asp:ListItem>
                              </aspxform:XDropDownList>
                         </td>
                        <td class="ts" style="WIDTH:21%">
                            <asp:Label id="Label185" runat="server" text="MEU/MEUR的具有法律效力的书面证明"></asp:Label></td>
                           <td class="ts1" style="WIDTH: 35%">
                                  <aspxform:XAttachments id="MEURAttachments"  runat="server" XDataBind="DF_SA_MarketInquiry.MEURAttachments" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'" BorderWidth="1" BorderColor="#DCDCDC" Width="70%"></aspxform:XAttachments>
                               </td>
                    </tr>
                  <tr>
                         <td class="ts">
                           <asp:Label id="Label189" runat="server" text="备注"></asp:Label></td>
                           <td class="ts1" >
                                <aspxform:XTextBox runat="server" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'" Rows="2" style="border-bottom: #e4e5e7  1px solid"  CssClass="MEURemarks" name="MEURemarks" ID="MEURemarks" XDataBind="DF_SA_MarketInquiry.MEURemarks" Width="100%" TextMode="MultiLine"></aspxform:XTextBox>
                           
                               </td>
                          <td class="ts">
                           <asp:Label id="Label190" runat="server" text="MEU/MEUR客户分类的判定材料"></asp:Label></td>
                           <td class="ts1" >
                                <aspxform:XAttachments id="MEURJudgingMaterials" runat="server" XDataBind="DF_SA_MarketInquiry.MEURJudgingMaterials" BorderWidth="1" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'" BorderColor="#DCDCDC" Width="70%"></aspxform:XAttachments>
                               </td>
                      </tr>
                 
            </tbody>
            </tbody>
        </table>
        <br />
        <table width="1200" align="center" class="table" id="ContractTable" border="0" cellspacing="0" cellpadding="0">
            <%--hiddenexpress="DF_SA_MarketInquiry.SalesProgress!='50%' &amp;&amp;DF_SA_MarketInquiry.SalesProgress!='70%' &amp;&amp;DF_SA_MarketInquiry.SalesProgress!='90%' &amp;&amp;DF_SA_MarketInquiry.SalesProgress!='100%' "--%> 
            <tbody>
                <tr>
                    <td width="1200" class="title1" colspan="4">
                        <asp:Label id="Label16" runat="server" text="合同信息" valuetodisplaytext value></asp:Label>
                        <input class="inputbtn" id="btn_ContractTbody" style="HEIGHT: 23px" onclick="div_ShowHidden('ContractTbody')" type="button" size="46" value=▽隐藏 />
                         <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator8" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择合同样式"  DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness=='否'" ControlToValidate="XRadioButtonList1">请选择合同样式</aspxform:XRequiredFieldValidator>
                        <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator3" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择销售合同模板"  DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'" ControlToValidate="XRadioButtonList7">请选择销售合同模板</aspxform:XRequiredFieldValidator>
                        <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator4" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择是否盖合同电子章" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板' || DF_SA_PTPClientMessage.IsContractBusiness=='是' " ControlToValidate="ElectronicChapterType">请选择是否盖合同电子章</aspxform:XRequiredFieldValidator>
                        <aspxform:XRequiredFieldValidator id="请填写需方合同编号" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写需方合同编号" ControlToValidate="XTextBox52"></aspxform:XRequiredFieldValidator>
                        &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator12" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请上传合同文档" ControlToValidate="XAttachments1" DisableExpress='DF_SA_MarketInquiry.ContractType!="客户合同模板"'>请上传合同文档</aspxform:XRequiredFieldValidator>
                        <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator9" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请上传客户PO文档" ControlToValidate="XAttachments1" DisableExpress='(DF_SA_MarketInquiry.PoStyle!="客户PO")'>请上传客户PO文档</aspxform:XRequiredFieldValidator>
                        &nbsp;&nbsp; 
                    </td>
                </tr>
            </tbody>
        </table>
        <div id="div_ContractTbody">
            <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0"  >
                <tbody id="ContractTbody">
                    <tr id="contractType">
                        <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <asp:Label id="Label11" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="Label121" runat="server" text="销售合同模板"></asp:Label></td>
                        <td class="tsbottomtext"   HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <aspxform:XRadioButtonList id="XRadioButtonList7"  onkeyup="ContractInfoDefaultValue" Express="if(DF_SA_PTPClientMessage.IsContractBusiness=='是','',DF_SA_MarketInquiry.ContractType)" runat="server" XDataBind="DF_SA_MarketInquiry.ContractType" DisableExpress="(Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认' &amp;&amp;Global.StepName!='业务员确认1') || DF_SA_MarketInquiry.SalesOrganizationCode=='A300' || DF_SA_MarketInquiry.SalesOrganizationCode=='2000'  " RepeatDirection="Horizontal">
                                <asp:ListItem>我司标准合同且标准条款</asp:ListItem>
                                <asp:ListItem>客户合同模板</asp:ListItem>
                                <asp:ListItem>我司标准合同且非标准条款</asp:ListItem>
                            </aspxform:XRadioButtonList>
                        </td>
                         <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                            <asp:Label id="Label69" runat="server" text="合同样式"></asp:Label>
                             <aspxform:XLabel runat="server" HiddenExpress="1" ID="PoStyle" XDataBind="PoStyle"></aspxform:XLabel>
                         </td>
                        <td class="tsbottomtext"   HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                            <aspxform:XRadioButtonList id="XRadioButtonList1"  DisableCssClass="1"  onkeyup="ContractInfoDefaultValue" Express="if(DF_SA_PTPClientMessage.IsContractBusiness=='是',PoStyle,'')" runat="server" XDataBind="DF_SA_MarketInquiry.PoStyle" DisableExpress="1" RepeatDirection="Horizontal">
                                <asp:ListItem>我司PO</asp:ListItem>
                                <asp:ListItem>客户PO</asp:ListItem>
                                 
                            </aspxform:XRadioButtonList>
                             <td class="ts">
                            <asp:Label id="XLabel146" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="XLabel43" runat="server" text="需方合同编号" valuetodisplaytext value></asp:Label></td>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox52" style="WIDTH: 70%" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.SAContractNo" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'&amp;&amp;Global.StepName!='业务员确认1'"></aspxform:XTextBox>
                            <aspxform:XTextBox id="XTextBox129" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10px" XDataBind="DF_SA_MarketInquiry.EXMessage"></aspxform:XTextBox>
                        </td>
                        </td>
                    </tr>
                    <tr id="informalTr"  HiddenExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'|| DF_SA_MarketInquiry.PoStyle=='客户PO' ||  (DF_SA_MarketInquiry.PoStyle=='' &amp;&amp;DF_SA_PTPClientMessage.IsContractBusiness=='是')">
                        <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <asp:Label id="Label173" runat="server" text="合同预览"></asp:Label></td>
                        <td class="tsbottomtext" colspan="3" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <input class="inputbtn" id="btn_BusinessApprovals" style="HEIGHT: 23px; WIDTH: 150px" onclick="btnBusinessApprovals()" type="button" size="46" value="生成合同预览" />
                        </td>
                         <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' ">
                            <asp:Label id="Label70" runat="server" text="PO预览"></asp:Label></td>
                        <td class="tsbottomtext" colspan="3" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是' ">
                            <input class="inputbtn" id="btn_BusinessApprovalsPO" style="HEIGHT: 23px; WIDTH: 150px" onclick="btnBusinessApprovalsPO()" type="button" size="46" value="生成PO预览" />
                        </td>
                    </tr>
                    <tr id="ElectronicChapterTypes"  hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'">
                        <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <div hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType=='' || DF_SA_MarketInquiry.SalesOrganizationCode=='A300' || DF_SA_MarketInquiry.SalesOrganizationCode=='2000' "><asp:Label id="Label12" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label>&nbsp;<asp:Label id="Label130" runat="server" text="是否盖合同电子章"></asp:Label> 
                            </div>
                        </td>
                        <td class="ts1" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                            <div hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType=='' || DF_SA_MarketInquiry.SalesOrganizationCode=='A300' || DF_SA_MarketInquiry.SalesOrganizationCode=='2000' ">
                                <aspxform:XRadioButtonList id="ElectronicChapterType" runat="server" XDataBind="DF_SA_MarketInquiry.ElectronicChapterType" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" RepeatDirection="Horizontal" name="ElectronicChapterType">
                                    <asp:ListItem Selected="True">是</asp:ListItem>
                                    <asp:ListItem>否</asp:ListItem>
                                </aspxform:XRadioButtonList>
                            </div>
                        </td>
                         <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                          </td>
                         <td class="ts1"  HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                             </td>
                         <td class="ts" HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                             <asp:Label id="Label94" runat="server" text="最终客户名称和地址"></asp:Label>
                          </td>
                         <td class="ts1"  HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                             <aspxform:XTextBox runat="server" XDataBind="DF_SA_MarketInquiry.CustomerAddress" style="WIDTH: 70%"   BorderWidth="1" BorderColor="#DCDCDC" Rows="3" TextMode="MultiLine" DisableExpress="StepName!='业务员发起申请'&amp;&amp;StepName!='业务员确认'&amp;&amp;StepName!='业务员确认1'"></aspxform:XTextBox>
                             </td>
                       
                    </tr>
                    <tr id="trGenerationContractButton" hiddenexpress="(DF_SA_MarketInquiry.SalesOrganizationCode=='A300' || DF_SA_MarketInquiry.SalesOrganizationCode=='2000'||  DF_SA_MarketInquiry.SAPOrderNumber=='' ) || DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                        <td height="22" class="tsbottomlabel" colspan="4">
                            <aspxform:XTextBox id="ManufacturerProductsExamine" runat="server" HiddenExpress="1" XDataBind="ManufacturerProductsExamine"></aspxform:XTextBox>
                            <aspxform:XTextBox id="BUButtonExamine" runat="server" HiddenExpress="1" XDataBind="BUButtonExamine"></aspxform:XTextBox>
                            <aspxform:XTextBox id="ObjName" style="WIDTH: 70%" HiddenInput="true" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.ObjName"></aspxform:XTextBox>
                            <input id="btn_ButtonGenerationContract" onclick="ButtonGenerationContract()" type="button" value="查看合同" />
                            <input id="btn_DownGenerationContract" onclick="DownGenerationContract()" type="button" value="下载合同" />
                              <input id="btn_DownGenerationContract1" onclick="GenerationContract()" type="button" hidden="hidden" value="合同盖章" />
                              
                        </td>
                    </tr>
                    <tr id="trPO">
                         <td height="22" class="tsbottomlabel" colspan="4">
                         <input id="btn_ButtonGenerationContractpo" onclick="ButtonGenerationContract()" type="button" value="查看PO" />
                            <input id="btn_DownGenerationContractpo" onclick="DownGenerationContract()" type="button" value="下载PO" />
                        <input id="btn_DownGenerationContractPO" onclick="GenerationContractPO()" type="button" hidden="hidden" value="PO盖章" />
                            </td>
                    </tr>
                    <tr id="trXAttachments1" hiddenexpress="(DF_SA_MarketInquiry.ContractType!='客户合同模板'|| DF_SA_MarketInquiry.ContractType=='')&amp;&amp;(DF_SA_MarketInquiry.PoStyle!='客户PO' ||DF_SA_MarketInquiry.PoStyle=='')" >
                        <td class="tsbottomlabel">
                            <asp:Label id="Label39" runat="server" text="合同文档上传" hiddenexpress="DF_SA_MarketInquiry.PoStyle=='客户PO'" valuetodisplaytext value></asp:Label>
                               <aspxform:XLabel ID="XLabel154" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'|| DF_SA_PTPClientMessage.IsContractBusiness=='否'" ></aspxform:XLabel> <asp:Label id="Label71" runat="server" text="客户PO文档上传" hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'|| DF_SA_PTPClientMessage.IsContractBusiness=='否'" valuetodisplaytext value></asp:Label>
                        </td>
                        <td height="22" class="tsbottomtext" >
                            <aspxform:XAttachments id="XAttachments1" runat="server" Width="100%" XDataBind="DF_SA_MarketInquiry.Accessory" FileTypes="*.doc;*.docx;*.pdf"></aspxform:XAttachments>
                        </td>
                          <td class="tsbottomtext" colspan="2">
                            <aspxform:XLabel ID="lab1" runat="server" BackColor="#d4e4fe" HiddenExpress="DF_SA_MarketInquiry.ContractType!='客户合同模板'" text="注：目前只支持上传一个客户合同，支持格式：WORD或PDF"  forecolor="Blue" font-size="14px"></aspxform:XLabel>
                              <aspxform:XLabel ID="XLabel89" runat="server" BackColor="#d4e4fe" HiddenExpress="DF_SA_MarketInquiry.PoStyle!='客户PO'" text="注：目前只支持上传一个客户PO，支持格式：WORD或PDF"  forecolor="Blue" font-size="14px"></aspxform:XLabel>

                      </td>
                    </tr>
                    <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness!='是'">
                         <td class="tsbottomlabel">
                                <asp:Label id="Label72" runat="server" text="需要我司盖电子章"  valuetodisplaytext value></asp:Label>
                             <aspxform:XLabel runat="server" ID="OurElectronicSeal1" HiddenExpress="1" XDataBind="OurElectronicSeal"></aspxform:XLabel>
                         </td>
                         <td height="22" class="tsbottomtext" >
                              <aspxform:XRadioButtonList id="OurElectronicSeal" DisableExpress="1"  Express="if(DF_SA_PTPClientMessage.IsContractBusiness=='是',OurElectronicSeal,'')"  runat="server" XDataBind="DF_SA_MarketInquiry.OurElectronicSeal"  RepeatDirection="Horizontal" name="ElectronicChapterType">
                                    <asp:ListItem>是</asp:ListItem>
                                    <asp:ListItem>否</asp:ListItem>
                                </aspxform:XRadioButtonList>
                        </td>
                         <td class="tsbottomlabel">
                               <aspxform:XLabel ID="XLabel155" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" HiddenExpress="DF_SA_MarketInquiry.PoStyle!='客户PO'||DF_SA_MarketInquiry.OurElectronicSeal!='是'" ></aspxform:XLabel>  <asp:Label id="Label73" runat="server" text="电子章关键字"  HiddenExpress="DF_SA_MarketInquiry.PoStyle!='客户PO'||DF_SA_MarketInquiry.OurElectronicSeal!='是'" valuetodisplaytext value></asp:Label>
                             </td>
                          <td height="22" class="tsbottomtext" >
                               <aspxform:XTextBox id="KeyWordsSeal" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" runat="server" BorderWidth="1" HiddenExpress=" DF_SA_MarketInquiry.PoStyle!='客户PO'|| DF_SA_MarketInquiry.OurElectronicSeal!='是'"  BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.KeyWordsSeal"></aspxform:XTextBox>
                          </td>
                          <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator10" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择是否需要我司盖电子章" ControlToValidate="OurElectronicSeal" DisableExpress='DF_SA_MarketInquiry.PoStyle!="我司PO"'>请选择是否需要我司盖电子章</aspxform:XRequiredFieldValidator>
                         <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator11" runat="server" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写电子章关键字" ControlToValidate="KeyWordsSeal" DisableExpress='DF_SA_MarketInquiry.PoStyle!="客户PO"|| DF_SA_MarketInquiry.OurElectronicSeal!="是"'>请填写电子章关键字</aspxform:XRequiredFieldValidator>
                    </tr>
                    <tr HiddenExpress="(DF_SA_MarketInquiry.PoStyle=='客户PO' ||DF_SA_MarketInquiry.PoStyle=='')&amp;&amp;(DF_SA_MarketInquiry.OurElectronicSeal=='否' || DF_SA_MarketInquiry.OurElectronicSeal=='') ||(DF_SA_MarketInquiry.ObjName==''&amp;&amp;DF_SA_PTPClientMessage.IsContractBusiness=='是'&amp;&amp;Global.StepName!='业务员确认2')|| DF_SA_PTPClientMessage.IsContractBusiness=='否' "  >
                         <td height="22" class="tsbottomtext" >
                               <aspxform:XLabel ID="XLabel159" runat="server" Text="*" BackColor="#D4E4FE" ForeColor="Red" ></aspxform:XLabel>  <asp:Label id="Label74" runat="server" text="上传双方盖章后的PO"  valuetodisplaytext value></asp:Label>
                             </td>
                         <td class="tsbottomtext" colspan="2">
                             <aspxform:XAttachments runat="server" ID="StampPo"  XDataBind="DF_SA_MarketInquiry.StampPo"  FileTypes="*.doc;*.docx;*.xls;*.xlsx;*.pdf;*.png;*.jpg;*.jpeg;*.gif;*.msg;*.eml;*.zip;*.7z" RepeatDirection="Horizontal"></aspxform:XAttachments>
                             </td>
                    </tr>
                    <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator16" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请上传双方盖章后的PO" ControlToValidate="StampPo" DisableExpress="(DF_SA_MarketInquiry.PoStyle=='客户PO' ||DF_SA_MarketInquiry.PoStyle=='')&amp;&amp;(DF_SA_MarketInquiry.OurElectronicSeal=='否' || DF_SA_MarketInquiry.OurElectronicSeal=='')||Global.StepName!='业务员确认2'">请上传双方盖章PO</aspxform:XRequiredFieldValidator>
                    <%--  <tr id="EditGenerationContractButtonTr" hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板' ">
                        <td width="1200" height="23" class="tsbottomlabel" colspan="4">
                            <input id="EditGenerationContractButton" style="HEIGHT: 23px" onclick="EditGenerationContract()" type="button" value="合同信息" />
                        </td>
                    </tr>--%> 
                    <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                        <td class="title1" colspan="4">
                            <asp:Label id="Label95" runat="server" text="客户负责合同处理人员信息" valuetodisplaytext value font-size="12px"></asp:Label>&nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator5" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'" ErrorMessage="请填写客户负责合同处理人姓名" ControlToValidate="XTextBox82">请填写客户负责合同处理人姓名</aspxform:XRequiredFieldValidator>
                            &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator6" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请选择客户负责合同处理人称呼" ControlToValidate="Sex" DisableExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">请选择客户负责合同处理人称呼</aspxform:XRequiredFieldValidator>
                            &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator13" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写座机或手机" ControlToValidate="ContractTel" DisableExpress='DF_SA_MarketInquiry.ResponsibleContractsPhone!="" || DF_SA_PTPClientMessage.IsContractBusiness!="否"'>请填写座机或手机</aspxform:XRequiredFieldValidator>
                            &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator14" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请填写座机或手机1" ControlToValidate="ContractPhone" DisableExpress='DF_SA_MarketInquiry.ResponsibleContractsLandline!="" || DF_SA_PTPClientMessage.IsContractBusiness!="否"'>请填写座机或手机1</aspxform:XRequiredFieldValidator>
                        </td>
                    </tr>
                    <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                        <td class="ts">
                            <asp:Label id="Label13" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="Label59" runat="server" text="姓名"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XTextBox id="XTextBox82" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ResponsibleContractsName" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                            <aspxform:XDataBrowserButton id="XDataBrowserButton9" runat="server" Width="35px" Text="查询" Height="25px" DataMap="ContactName->DF_SA_MarketInquiry.ResponsibleContractsName;ContactMobile->DF_SA_MarketInquiry.ResponsibleContractsPhone;ContactTel->DF_SA_MarketInquiry.ResponsibleContractsLandline;ContactEmail->DF_SA_MarketInquiry.ResponsibleEmail" XDataSource="TableName:V_DF_MasterData_Contact;Filter:CustomerID->DF_SA_PTPClientMessage.ClientBPMID,OwnerAccount->DF_SA_MarketInquiry.OwnerID" DisplayColumns="ContactName:联系人,60;ContactSAPID:联系人SapID,90;ContactTel:电话,100;ContactMobile:手机号,120;ContactEmail:邮箱,120;ContactAddr:地址,150;ContactDepart:部门描述,150" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XDataBrowserButton>
                        </td>
                        <td class="ts">
                            <asp:Label id="Label14" runat="server" text="*" valuetodisplaytext value forecolor="Red"></asp:Label><asp:Label id="Label156" runat="server" text="称呼"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XRadioButtonList id="Sex" runat="server" Width="140px" XDataBind="DF_SA_MarketInquiry.ContractSex" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" RepeatDirection="Horizontal">
                                <asp:ListItem>先生</asp:ListItem>
                                <asp:ListItem>女士</asp:ListItem>
                            </aspxform:XRadioButtonList>
                        </td>
                    </tr>
                    <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                        <td class="ts">
                            <asp:Label id="Label60" runat="server" text="座机"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XTextBox id="ContractTel" onkeyup="TelChange('ContractTel','ContractTelLabel')" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ResponsibleContractsLandline" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" CssClass="ContractTel"></aspxform:XTextBox>
                            <aspxform:XTextBox id="ContractExtension" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="10%"></aspxform:XTextBox>
                            <asp:Label id="ContractTelLabel" style="DISPLAY: none" runat="server" text="座机">座机格式不正确</asp:Label></td>
                        <td class="ts">
                            <asp:Label id="Label65" runat="server" text="手机"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XTextBox id="ContractPhone" onkeyup="PhoneChange('ContractPhone','ContractPhoneLabel')" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ResponsibleContractsPhone" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                            <asp:Label id="ContractPhoneLabel" style="DISPLAY: none" runat="server" text="手机">手机格式不正确</asp:Label></td>
                    </tr>
                    <tr HiddenExpress="DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                        <td class="ts">
                            <asp:Label id="Label104" runat="server" text="Email"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XTextBox id="XTextBox217" onkeyup="EmailChange('XTextBox217','Label105')" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ResponsibleEmail" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" CssClass="ResponsibleEmail"></aspxform:XTextBox>
                            <asp:Label id="Label105" style="DISPLAY: none" runat="server" text="Email">邮箱格式不正确</asp:Label></td>
                        <td class="ts">
                            <asp:Label id="Label115" runat="server" text="联系传真"></asp:Label></td>
                        <td class="ts1">
                            <aspxform:XTextBox id="Fax" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.Fax" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                            <aspxform:XTextBox id="ContractNumber" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="70%" XDataBind="DF_SA_MarketInquiry.ContractNumber" Express="DF_SA_MarketInquiry.FormNo" DisableExpress="1"></aspxform:XTextBox>
                        </td>
                    </tr>
                    <tr>
                        <td class="ts" colspan="4">
                        </td>
                    </tr>
                </tbody>
            </table>
            <div id="divContract" style="BORDER-TOP: 1px solid; BORDER-RIGHT: 1px solid; BORDER-BOTTOM: 1px solid; BORDER-LEFT: 1px solid" hiddenexpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType=='' || DF_SA_PTPClientMessage.IsContractBusiness=='是'">
                <table width="1366" align="center" border="0" cellspacing="0" cellpadding="0" runat="server">
                    <tbody>
                        <tr>
                            <td height="26" align="center" style="FONT-SIZE: 20px; TEXT-ALIGN: center" colspan="4">
                                <asp:Label id="Label20" runat="server" text="合同信息"></asp:Label></td>
                        </tr>
                        <tr>
                            <td height="20" class="tdStyle" style="WIDTH: 10%">
                                <asp:Label id="Label21" runat="server" text="供方:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel82" runat="server" Express="PayAccountName"></aspxform:XLabel>
                            </td>
                            <td class="tdStyle" style="WIDTH: 20%">
                                <asp:Label id="Label22" runat="server" text="需方:"></asp:Label></td>
                            <td style="WIDTH: 30%">
                                &nbsp;<aspxform:XLabel id="XLabel84" runat="server" Express="DF_SA_PTPClientMessage.PTPName"></aspxform:XLabel>
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label38" runat="server" text="供方合同编号:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel83" runat="server" Express='if(DF_SA_MarketInquiry.TaskID!="",DF_SA_MarketInquiry.FormNo,"")'></aspxform:XLabel>
                            </td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label40" runat="server" text="需方合同编号:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel85" runat="server" Express="DF_SA_MarketInquiry.SAContractNo"></aspxform:XLabel>
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label42" runat="server" text="合同联系人:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                <aspxform:XDropDownList id="XDropDownList36" runat="server" HiddenExpress="1" Width="50px" DataMap="MobilePhone->DF_SA_MarketInquiry.SupplierPhone;ContactPhoneUumber->DF_SA_MarketInquiry.SupplierTel" XDataSource="TableName:V_DF_HR_BasicInfo;Filter:AttendanceKakaNO->DF_SA_MarketInquiry.SalesmanID"></aspxform:XDropDownList>
                                &nbsp;<aspxform:XLabel id="XLabel81" runat="server" Text="Label" Express="DF_SA_MarketInquiry.Salesman"></aspxform:XLabel>
                            </td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label43" runat="server" text="合同联系人:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel86" runat="server" Express="DF_SA_MarketInquiry.ResponsibleContractsName"></aspxform:XLabel>
                            </td>
                        </tr>
                        <tr>
                            <td height="19" style="FONT-SIZE: 16px; WIDTH: 20%; TEXT-ALIGN: right">
                                <asp:Label id="Label44" runat="server" text="联系电话:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                <aspxform:XTextBox id="XTextBox83" onkeyup="TelChange('XTextBox83','Label15')" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="30%" XDataBind="DF_SA_MarketInquiry.SupplierTel" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                                <asp:Label id="Label15" style="DISPLAY: none" runat="server" text="座机">联系电话格式不正确</asp:Label></td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label46" runat="server" text="联系电话:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel87" runat="server" Express='if(DF_SA_MarketInquiry.ResponsibleContractsPhone=="",DF_SA_MarketInquiry.ResponsibleContractsLandline,DF_SA_MarketInquiry.ResponsibleContractsPhone)'></aspxform:XLabel>
                            </td>
                        </tr>
                        <tr>
                            <td height="19" style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label47" runat="server" text="手机号:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                <aspxform:XTextBox id="XTextBox87" onkeyup="PhoneChange('XTextBox87','Label17')" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="30%" XDataBind="DF_SA_MarketInquiry.SupplierPhone" Max="0" Min="0" ValueToDisplayText HiddenInput="False" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                                <asp:Label id="Label17" style="DISPLAY: none" runat="server" text="手机">手机格式不正确</asp:Label></td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                            </td>
                            <td style="WIDTH: 35%">
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label49" runat="server" text="联系传真:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                            </td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label50" runat="server" text="联系传真:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                &nbsp;<aspxform:XLabel id="XLabel88" runat="server" Express="DF_SA_MarketInquiry.Fax"></aspxform:XLabel>
                            </td>
                        </tr>
                        <tr>
                            <td style="WIDTH: 10%">
                            </td>
                            <td style="WIDTH: 35%">
                            </td>
                            <td style="FONT-SIZE: 16px; WIDTH: 10%; TEXT-ALIGN: right">
                                <asp:Label id="Label51" runat="server" text="合同签订地点:"></asp:Label></td>
                            <td style="WIDTH: 35%">
                                <aspxform:XTextBox id="XTextBox88" runat="server" BorderWidth="1px" BorderColor="Gainsboro" Width="30%" XDataBind="DF_SA_MarketInquiry.LocationSignature" Max="0" Min="0" ValueToDisplayText HiddenInput="False" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" Font-Bold="True"></aspxform:XTextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px" colspan="4">
                                供、需双方经友好协商一致，共同签署本合同。 
                            </td>
                        </tr>
                        <tr hidden="hidden">
                            <td class="ts" style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                一、需方向供方购买以下产品： 
                                <aspxform:XButton id="xbtn_uptcp" runat="server" Text="获取产品信息" OnClientClick="updateContractProduct()" DisableExpress="Global.StepName!='业务员发起申请'"></aspxform:XButton>
                            </td>
                        </tr>
                    </tbody>
                </table>
                <div id="Div1" style="TEXT-ALIGN: center" runat="server" hidden="hidden">
                    <div class="scrollDiv" id="scrollDiv1" style="HEIGHT: 150px">
                        <table align="center" class="scrolltable" id="ctable" border="0" runat="server" menudock="Left" dynamicarea="1,1">
                            <tbody>
                                <tr class="scrollColThead">
                                    <td class="tds" style="WIDTH: 50px">
                                        <asp:Label id="Label23" runat="server" text="序号"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 200px">
                                        <asp:Label id="Label24" runat="server" text="产品名称"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 200px">
                                        <asp:Label id="Label25" runat="server" text="规格型号"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 200px">
                                        <asp:Label id="Label26" runat="server" text="厂商品牌"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 50px">
                                        <asp:Label id="Label27" runat="server" text="单位"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 50px">
                                        <asp:Label id="Label28" runat="server" text="数量"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 150px">
                                        <asp:Label id="Label29" runat="server" text="单价"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 150px">
                                        <asp:Label id="Label30" runat="server" text="总价"></asp:Label>
                                        <aspxform:XTextBox id="totals" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="totals" Express="sum(DF_SA_ContractProductList.PDSellingTotalvalueRest)" Format="type:currency;.2" width="100px"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds" style="WIDTH: 170px">
                                        <asp:Label id="Label31" runat="server" text="交货期限"></asp:Label></td>
                                    <td class="tds" style="WIDTH: 180px">
                                        <asp:Label id="Label32" runat="server" text="保修期"></asp:Label></td>
                                </tr>
                                <tr>
                                    <td class="tds1">
                                        <aspxform:XGridLineNo id="XGridLineNo2" runat="server" BorderWidth="1" Width="100%" XDataBind="DF_SA_ContractProductList.LineItem" TextAlign="Center" BorderStyle="None">1</aspxform:XGridLineNo>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox98" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.ProductNmae" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox99" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.ProductModel" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" name="ProductModel"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox103" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.Manufacturer" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XTextBox>
                                        <aspxform:XTextBox id="ManufacturerID" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="ManufacturerID"></aspxform:XTextBox>
                                        <aspxform:XDropDownList id="XDropDownList27" runat="server" HiddenExpress="1" Width="1px" DataMap="Name->DF_SA_ContractProductList.Manufacturer" XDataSource="TableName:V_DF_DataSourceList_changshang;Filter:Value->ManufacturerID" ValueColumn="ItemID" DisplayColumn="Name">
                                            <asp:ListItem>未绑定</asp:ListItem>
                                        </aspxform:XDropDownList>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox104" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.Unit" Text="台" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Center"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox109" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.Number" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Center" name="Number"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox127" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.PDSellingPriceRest" Express=" " DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" Format="type:currency;.2" TextAlign="Right" name="PDSellingPriceRMB"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox136" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.PDSellingTotalvalueRest" Express="DF_SA_ContractProductList.Number*DF_SA_ContractProductList.PDSellingPriceRest" DisableExpress="1" Format="type:currency;.2" TextAlign="Right" name="PDSellingTotalvalueRest"></aspxform:XTextBox>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="XTextBox137" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50%" XDataBind="DF_SA_ContractProductList.DeliveryDeadline" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Center" name="DeliveryDeadline"></aspxform:XTextBox>
                                        <aspxform:XDropDownList id="XDropDownList28" runat="server" Width="45%" XDataBind="DF_SA_ContractProductList.DeliveryDeadlineDayOrWeek" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'">
                                            <asp:ListItem Selected="True">周</asp:ListItem>
                                            <asp:ListItem>天</asp:ListItem>
                                        </aspxform:XDropDownList>
                                    </td>
                                    <td class="tds1">
                                        <aspxform:XTextBox id="WarrantyPeriod" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_ContractProductList.WarrantyPeriod" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" name="WarrantyPeriod"></aspxform:XTextBox>
                                        <aspxform:XTextBox id="WarrantyPeriodOther" runat="server" HiddenExpress="1" BorderWidth="1" BorderColor="#DCDCDC" Width="90px" XDataBind="DF_SA_ContractProductList.WarrantyPeriodOther" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" name="WarrantyPeriodOther"></aspxform:XTextBox>
                                    </td>
                                </tr>
                            </tbody>
                        </table>
                    </div><DIVSTYLE="FONT: 
0px sans-serif;clear: both;display: block?>
                </div>
                <%--   <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator7" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请输入产品型号" ControlToValidate="XTextBox99" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType==''">请输入产品型号</aspxform:XRequiredFieldValidator>
                &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator8" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请输入数量" ControlToValidate="XTextBox109" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType==''">请输入数量</aspxform:XRequiredFieldValidator>
                &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator9" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请输入单价" ControlToValidate="XTextBox127" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType==''">请输入单价</aspxform:XRequiredFieldValidator>
                &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator10" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请输入交货期限" ControlToValidate="XTextBox137" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType==''">请输入交货期限</aspxform:XRequiredFieldValidator>
                &nbsp;<aspxform:XRequiredFieldValidator id="XRequiredFieldValidator11" runat="server" ForeColor="Red" ValidationGroup="yewuyuan" Display="None" ErrorMessage="请输入保修期" ControlToValidate="WarrantyPeriod" DisableExpress="DF_SA_MarketInquiry.ContractType=='客户合同模板'||  DF_SA_MarketInquiry.ContractType==''">请输入保修期</aspxform:XRequiredFieldValidator>
              --%> 
                <table width="1366" align="center" border="0" cellspacing="0" cellpadding="0" runat="server">
                    <tbody>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                一、需方向供方购买以下产品： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                （同产品明细）</td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                二、运输方式及运费承担： 
                            </td>
                        </tr>
                        <%-- <tr>
                    <td class="tsbottomlabel">
                        &nbsp;
                    </td>
                </tr>--%> 
                        <tr>
                            <td colspan="4">
                                供方应依照约定交货期限将产品发运到需方指定收货地址，供方承担送货至需方收货地址所产生的运费。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                三、包装标准： 
                            </td>
                        </tr>
                        <%-- <tr>
                    <td class="tsbottomlabel">
                        &nbsp;
                    </td>
                </tr>--%> 
                        <tr>
                            <td colspan="4">
                                产品的包装必须牢固，供方应保障产品在运输途中的安全。需方对产品的包装有特殊要求的，应将该等特殊要求以书面形式告知供方，供方须按该要求包装（该特殊包装费用由需方承担）。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                四、质量要求、验收标准、方法及提出异议期限： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                产品质量要求为原厂技术标准。货到交货地点的 
                                <aspxform:XTextBox id="ObjectionPeriod" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.ObjectionPeriod" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                日内，需方对供方交付产品的包装、外观、型号、数量、规格，以及质量和技术标准等进行验收，并在供方提供的产品出库验收单上签收，出库验收单一式2份，供需双方各持1份。如供方交付的产品不符合本合同约定，需方应在前述相应验收期限内以书面或邮件形式向供方提出，经供方确认属实后，供方负责维修或更换。如需方逾期未在供方提供的产品出库验收单上签收，也未在前述验收期限内提出异议，视为供方已履行产品交付义务且交付的产品不存在质量问题。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                五、结算方式及期限： 
                            </td>
                        </tr>
                        <tr>
                            <td style="COLOR: blue" colspan="4">
                                注: 1、您选择的付款条件为:<aspxform:XLabel id="Settlement" style="HEIGHT: 25px" runat="server" XDataBind="TPayment" Express="DF_SA_MarketInquiry.TermsPayment"></aspxform:XLabel>
                                <br />
                                &nbsp;&nbsp;&nbsp;&nbsp; 2、根据实际情况可修改结算方式及期限 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                <aspxform:XTextBox id="SettlementMethod" style="WIDTH: 100%" onkeyup="ActTermsPayment()" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.ActTermsPayment" Express="DF_SA_MarketInquiry.ActTermsPayment" DisableExpress="Global.StepName!='业务员发起申请'" TextMode="MultiLine"></aspxform:XTextBox>
                                <%--<aspxform:XTextBox runat="server" ID="ActTermsPayment"  Express="DF_SA_MarketInquiry.SettlementMethod" HiddenInput="true" XDataBind="DF_SA_MarketInquiry.ActTermsPayment"></aspxform:XTextBox>--%></td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                六、发票、邮寄信息： 
                            </td>
                        </tr>
                        <tr>
                            <td class="tsbottomlabel" style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                供方收款信息： 
                                <aspxform:XDropDownList id="Company" runat="server" HiddenExpress="1" BackColor="#E6F1F8" DataMap="Demander->PayAccountName;Deposit->PayDeposit;Account->PayAccount;Telphone->PayTel;Fax->PayFax" XDataSource="TableName:DF_SA_SS_Company;Filter:CompanyCode->DF_SA_MarketInquiry.SalesOrganizationCode"></aspxform:XDropDownList>
                            </td>
                        </tr>
                        <tr>
                            <td class="tsbottomlabel" style="WIDTH: 50%">
                                户名： 
                                <aspxform:XTextBox id="PayAccountName" runat="server" Width="70%" XDataBind="PayAccountName" DisableBehavior="ReadOnly" Express="" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                电话： 
                                <aspxform:XTextBox id="XTextBox163" runat="server" Width="70%" XDataBind="PayTel" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                            </td>
                            <td class="tsbottomlabel" style="WIDTH: 50%">
                                开户行： 
                                <aspxform:XTextBox id="XTextBox142" runat="server" Width="70%" XDataBind="PayDeposit" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                账号： 
                                <aspxform:XTextBox id="XTextBox180" runat="server" Width="70%" XDataBind="PayAccount" DisableBehavior="ReadOnly" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                传真： 
                                <aspxform:XTextBox id="PayFax" runat="server" Width="70%" XDataBind="PayFax" DisableBehavior="ReadOnly" Express="" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                            </td>
                        </tr>
                        <tr>
                            <td class="tsbottomlabel" style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                需方开票信息： 
                            </td>
                        </tr>
                        <tr>
                            <td class="tsbottomlabel">
                                公司： 
                                <aspxform:XTextBox id="PTPName" runat="server" Width="90%" XDataBind="PTPName" Express="DF_SA_PTPClientMessage.PTPName" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                地址： 
                                <aspxform:XTextBox id="XTextBox89" runat="server" Width="70%" XDataBind="PaymentAddress" Express="DF_SA_MarketInquiry.PaymentAddress" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                电话： 
                                <aspxform:XTextBox id="XTextBox138" runat="server" Width="70%" XDataBind="PaymentTel" Express="DF_SA_MarketInquiry.PaymentTel" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                            </td>
                            <td class="tsbottomlabel">
                                开户行： 
                                <aspxform:XTextBox id="XTextBox139" runat="server" Width="70%" XDataBind="BankName" Express="DF_SA_MarketInquiry.BankName" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                账号： 
                                <aspxform:XTextBox id="XTextBox86" runat="server" Width="70%" XDataBind="BankAccount" Express="DF_SA_MarketInquiry.BankAccount" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                                税号： 
                                <aspxform:XTextBox id="XTextBox141" runat="server" Width="70%" XDataBind="PaymentTaxNumber" Express="DF_SA_MarketInquiry.PaymentTaxNumber" ReadOnly="True"></aspxform:XTextBox>
                                <br />
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                七、保修： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                <%-- 产品的保修期为设备终验合格后
                        <aspxform:XTextBox id="DefectsLiabilityPeriod" runat="server" XDataBind="DefectsLiabilityPeriod" Width="10%" BorderWidth="1" BorderColor="#DCDCDC" TextAlign="Right"></aspxform:XTextBox>
                        个月。--%>供方保证在保修期内免费进行维修并提供因产品质量问题而必须更换的零部件。对于需方人为损坏或使用、保管不当损坏的，维修费由需方承担。 
                            </td>
                        </tr>
                        <tr>
                            <td height="19" style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                八、违约责任： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                供方未按照前述约定交货期限向需方交货的，每逾期 
                                <aspxform:XTextBox id="DeliveryNotTime" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.DeliveryNotTime" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                日，供方应向需方支付相当于本合同总价【 
                                <aspxform:XTextBox id="SupplierToDemander" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.SupplierToDemander" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                】%的违约金。需方未按照前述约定向供方支付合同款，每逾期 
                                <aspxform:XTextBox id="DemanderToSupplierDay" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.DemanderToSupplierDay" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                日，需方应向供方支付相当于本合同总价【<aspxform:XTextBox id="DemanderToSupplier" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.DemanderToSupplier" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                】%的违约金。合同生效后，供、需任何一方单方废止合同，应向对方支付相当于合同价款【 
                                <aspxform:XTextBox id="RescindContract" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.RescindContract" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                】%的违约金，且无需再支付本款前述违约金。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                九、不可抗力： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                任何一方对于因其不可预见、无法控制的情况（“不可抗力”）所导致的不能或迟延履行本合同约定的行为均不承担责任，也不应被视为违约，但声称受此影响的一方应尽快通知对方发生不能或迟延履行的原因和可能延续的时间，并应减少由此所产生的影响。如果任何一方由于受不可抗力影响而导致不能或迟延履行其在本合同下的义务总计超过 
                                <aspxform:XTextBox id="PerformanceContract" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="50px" XDataBind="DF_SA_MarketInquiry.PerformanceContract" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextAlign="Right"></aspxform:XTextBox>
                                天，则另一方有权以书面方式通知对方立即终止本合同，且不承担违约责任。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                十、解决合同纠纷的方式： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                供需双方友好协商解决，协商不成，向供方所在地人民法院提起诉讼解决。 
                            </td>
                        </tr>
                        <tr>
                            <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold" colspan="4">
                                十一、合同生效： 
                            </td>
                        </tr>
                        <tr>
                            <td colspan="4">
                                本合同由双方盖章后生效，电子章与物理章有同等效力，如需方为自然人，则供方盖章且需方签字后生效。盖章后的传真件、复印件、扫描件与原件合同具有同等效力。 合同一式<aspxform:XLabel id="ContractScore" style="HEIGHT: 25px" runat="server" Width="3%" XDataBind="ContractScore" Express="sum(DF_SA_MarketInquiry.SupplierContractScore+DF_SA_MarketInquiry.DemanderContractScore)" TextAlign="Right" max="0" min="0"></aspxform:XLabel>
                                份，供方执<aspxform:XTextBox id="SupplierContractScore" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="3%" XDataBind="DF_SA_MarketInquiry.SupplierContractScore" Text="1" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" Format="type:number;.0" TextAlign="Right"></aspxform:XTextBox>
                                份，需方执<aspxform:XTextBox id="DemanderContractScore" style="HEIGHT: 25px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="3%" XDataBind="DF_SA_MarketInquiry.DemanderContractScore" Text="1" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" Format="type:number;.0" TextAlign="Right"></aspxform:XTextBox>
                                份，具有同等法律效力。 
                            </td>
                        </tr>
                    </tbody>
                </table>
                <br />
                <div id="divNonStandardClauses" hiddenexpress="DF_SA_MarketInquiry.ContractType!='我司标准合同且非标准条款'">
                    <table width="1366" align="center" border="0" cellspacing="0" cellpadding="0" runat="server" >
                        <tbody>
                            <tr>
                                <td style="FONT-SIZE: 16px; FONT-WEIGHT: bold">
                                    十二、其它约定事项： 
                                </td>
                            </tr>
                        </tbody>
                    </table>
                    <table width="1366" align="center" id="tab_NonStandardClauses" border="0" cellspacing="0" cellpadding="0" runat="server" menudock="Left" dynamicarea="1,1" datamap="NonStandardClauses->DF_CRM_NonStandardClauses.NonStandardClauses" xdatasource="TableName:DF_CRM_NonStandardClauses;Filter:TaskID->DF_SA_MarketInquiry.BPMEndTaskID">
                        <tbody>
                            <tr class="scrollColThead">
                                <td class="ts" style="WIDTH: 10%">
                                    序号</td>
                                <td class="ts1" style="WIDTH: 90%">
                                    其它约定事项</td>
                            </tr>
                            <tr>
                                <td height="30">
                                    <aspxform:XGridLineNo id="XGridLineNo3" runat="server" BorderWidth="1" Width="100%" TextAlign="Center" BorderStyle="None"></aspxform:XGridLineNo>
                                </td>
                                <td>
                                    <aspxform:XTextBox id="NonStandardClauses" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_CRM_NonStandardClauses.NonStandardClauses" ValueToDisplayText Height="30" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" TextMode="MultiLine" name="NonStandardClauses"></aspxform:XTextBox>
                                </td>
                            </tr>
                        </tbody>
                    </table>
                </div>
                <table width="1366" border="0" cellspacing="0" cellpadding="0" runat="server">
                    <tbody>
                        <tr>
                            <td align="right" style="WIDTH: 30%">
                                <asp:Label id="Label18" runat="server" text="供方签章日期："></asp:Label></td>
                            <td align="left" style="WIDTH: 15%">
                                <aspxform:XDateTimePicker id="DateSupplier" style="HEIGHT: 25px; WIDTH: 100px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.DateSupplier" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XDateTimePicker>
                            </td>
                            <td align="right" style="WIDTH: 10%">
                                <asp:Label id="Label19" runat="server" text="需方签章日期："></asp:Label></td>
                            <td align="left" style="WIDTH: 35%">
                                <aspxform:XDateTimePicker id="DateDemander" style="HEIGHT: 25px; WIDTH: 100px" runat="server" BorderWidth="1" BorderColor="#DCDCDC" XDataBind="DF_SA_MarketInquiry.DateDemander" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'"></aspxform:XDateTimePicker>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
            <br />
            <%--   <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
                <tbody>
                    <tr>
                        <td width="431" class="title1">
                            <asp:Label id="Label33" runat="server" value valuetodisplaytext text="*" forecolor="Red"></asp:Label><asp:Label id="XLabel237" runat="server" value valuetodisplaytext text="上传附件"></asp:Label><asp:Label id="XLabel203" runat="server" value valuetodisplaytext text="产品配置清单与物料申请不一致，需要上传附件" font-size="8pt" forecolor="Red"></asp:Label></td>
                        <td width="765" class="title1">
                            <aspxform:XRadioButtonList id="XRadioButtonList1" runat="server" XDataBind="DF_SA_MarketInquiry.OFAccessory" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" RepeatDirection="Horizontal">
                                <asp:ListItem>是</asp:ListItem>
                                <asp:ListItem>否</asp:ListItem>
                            </aspxform:XRadioButtonList>
                        </td>
                    </tr>
                    <tr>
                        <td class="tsbottomtext" colspan="2">
                            <aspxform:XAttachments id="XAttachments2" runat="server" XDataBind="DF_SA_MarketInquiry.Accessory1" Width="100%" DisableExpress="Global.StepName!='业务员发起申请'&amp;&amp;Global.StepName!='业务员确认'" FileTypes="*.doc;*.docx;*.xls;*.xlsx;*.pdf;*.jpg;*.GIF;*.PNG;*.msg;*.eml"></aspxform:XAttachments>
                        </td>
                    </tr>
                </tbody>
            </table>--%> 
            <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
                <tbody>
                    <tr>
                        <td width="1200" class="title1">
                            <asp:Label id="XLabel183" runat="server" text="备注" valuetodisplaytext value></asp:Label></td>
                    </tr>
                    <tr>
                        <td class="tsbottomtext">
                            <aspxform:XTextBox id="XTextBox113" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.Remark" Height="80px" TextMode="MultiLine"></aspxform:XTextBox>
                        </td>
                    </tr>
                </tbody>
            </table>
            <%--   <table width="1200" align="center" class="table" border="0" cellspacing="0" cellpadding="0">
            <tbody>
                <tr>
                    <td width="1200" class="title1">
                        <aspxform:XLabel id="XLabel240" runat="server" HiddenExpress="DF_SA_MarketInquiry.ContractCurrency=='CNY'" BackColor="#d4e4fe" Value ValueToDisplayText Text="外币直发客户中、英文信息（内容：公司名称、地址、电话、联系人）"></aspxform:XLabel>
                        <aspxform:XLabel id="XLabel248" runat="server" HiddenExpress="DF_SA_MarketInquiry.ContractCurrency!='CNY'" BackColor="#d4e4fe" Value ValueToDisplayText Text="直发客户中文信息（内容：公司名称、地址、电话、联系人）"></aspxform:XLabel>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomtext">
                        <aspxform:XTextBox id="XTextBox163" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" XDataBind="DF_SA_MarketInquiry.SupplierStraightInformation" Height="80px" TextMode="MultiLine"></aspxform:XTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />--%><%--  <table class="table" cellspacing="0" cellpadding="0" width="1200" align="center" border="0">
            <tbody>
                <tr>
                    <td class="title1" width="1200">
                        <aspxform:XLabel id="XLabel211" runat="server" Text="意见" Value ValueToDisplayText></aspxform:XLabel>
                    </td>
                </tr>
                <tr>
                    <td class="tsbottomtext">
                        <aspxform:XCommentsTextBox id="XCommentsTextBox1" runat="server" BorderWidth="1" BorderColor="#DCDCDC" Width="100%" Height="80px" TextMode="MultiLine" Rows="3"></aspxform:XCommentsTextBox>
                    </td>
                </tr>
            </tbody>
        </table>
        <br />--%> 
            <table width="1366" align="center" border="0" cellspacing="0" cellpadding="0">
                <tbody>
                    <tr>
                        <td width="1366">
                            <aspxform:XProcessButtonList id="XProcessButtonList1" runat="server" SaveAsTemplateButtonVisible="False" SaveButtonVisible="False" PositionSelectVisible="False"></aspxform:XProcessButtonList>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <aspxform:XSignTrace id="XSignTrace1" runat="server" BorderWidth="1" BorderColor="#dcdcdc" Width="100%"></aspxform:XSignTrace>
                        </td>
                    </tr>
                </tbody>
            </table>
            <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator1" runat="server" ValidationGroup="C" Display="None" ErrorMessage="请选择丢单原因" ControlToValidate="XDropDownList20">请选择丢单原因</aspxform:XRequiredFieldValidator>
            <aspxform:XRequiredFieldValidator id="XRequiredFieldValidator2" runat="server" ValidationGroup="C" Display="None" ErrorMessage="请选择丢单原因" ControlToValidate="XDropDownList21">请选择丢单原因</aspxform:XRequiredFieldValidator>
        </div>
        <div>
        </div>
    </form>
</body>
</html>
