<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/Dialog/DialogMaster.Master"
    CodeBehind="CustomerView.aspx.cs" Inherits="OAWeb.crm.customer.CustomerView"
    EnableViewState="true" Theme="Default" %>

<%@ Register Src="/UserControls/CustomerViewRight.ascx" TagName="TaskNav" TagPrefix="uc1" %>
<%@ Register Src="/UserControls/ActionList.ascx" TagName="ActionList" TagPrefix="uc2" %>
<%@ Register Src="/NewProject/ProUserControl/MainComment.ascx" TagName="CommentList"
    TagPrefix="uc3" %>
<%@ Register Src="/UserControls/OpportunityList.ascx" TagName="OpportunityList" TagPrefix="uc4" %>
<%@ Register Src="/UserControls/LogList.ascx" TagName="LogList" TagPrefix="uc5" %>
<%@ Register Src="/UserControls/OrderList.ascx" TagName="OrderList" TagPrefix="uc6" %>
<%@ Register Src="/UserControls/SnList.ascx" TagName="SnList" TagPrefix="uc7" %>
<%@ Register Src="/UserControls/ContactList.ascx" TagName="ContactList" TagPrefix="uc8" %>
<%@ Register Src="/UserControls/CustomerServiceList.ascx" TagName="ServiceList" TagPrefix="uc9" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <style type="text/css">
        .right
        {
            width: 100px;
            color: #000000;
        }
        .table_list th
        {
            padding: 0px;
        }
        .order_product td
        {
            background-color: #fff;
            padding: 4px;
        }
        .CustomerTop
        {
            width: 100%;
        }
        .CustomerTop td
        {
            padding: 10px;
        }
        .CustomerTop td a
        {
            margin-left: 15px;
        }
        .TopTb .right
        {
            width: 70px;
        }
        .header_op, .header_nav
        {
            display: none;
        }
        body
        {
            background-color: #ededed;
        }
        .tab_handles
        {
            border-top: #c1c8d2 1px solid;
        }
        .tabs .tab_handles
        {
        }
        .tabs .tab_contents .TbDetail .right
        {
            color: Black;
            background-color: #f0f0f0;
            padding-right: 2px;
        }
        .tabs .tab_contents .TbDetail td
        {
            padding-left: 3px;
            height: 30px;
            line-height: 30px;
        }
        
        .tabs .tab_handles span
        {
            border-color: #CCCCCC;
            border-style: solid solid solid;
            border-width: 1px 1px 1px;
            background-color: #EEEEEE;
            padding: 5px;
            padding-left: 10px;
            padding-right: 10px;
        }
    </style>
    <!--主体左侧-->
    <table id="plc_profile" cellpadding="0" cellspacing="0" border="0" style="margin: auto;
        width: 80%;">
        <tr>
            <td class="main_center">
                <div class="page_content tabs">
                    <div class="order_widget tab_contents" style="padding-bottom: 5px; margin-bottom: 0px;">
                        <div class="order_State">
                            <table class="CustomerTop">
                                <tr>
                                    <td style="padding-left: 28px;">
                                        <strong class="fonts" style="font-size: 25px;">
                                            <asp:Label ID="lblCustomerName" runat="server" Text=""></asp:Label>
                                        </strong><span id="spFollow" visible="false" runat="server" style="color: Green;
                                            margin-left: 10px;">已关注 </span><span>
                                                <asp:LinkButton ID="lbtnFollow" runat="server" OnClick="lbtnFollow_Click">[+关注]</asp:LinkButton>
                                            </span><span><a href="javascript:void(0)" id="LinkEdit" runat="server">[编辑]</a></span>
                                    </td>
                                    <td style="text-align: right">
                                        <a href="javascript:void(0)" runat="server" id="LinkAction">创建活动记录</a> <a href="javascript:void(0)"
                                            runat="server" id="LinkOrder">创建订单</a> <a href="javascript:void(0)"  id="LinkService" runat="server">创建服务单</a>
                                    </td>
                                </tr>
                            </table>
                            <table border="0" cellspacing="0" cellpadding="0" style="margin: 10px; margin-left: 0px;
                                margin-right: 0px;" class="TopTb">
                                <tr>
                                    <td class="right ">
                                        状态：
                                    </td>
                                    <td>
                                        <asp:Label ID="txtBizTypeName" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        级别：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblGrade" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        积分：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblPoints" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        预存款：
                                    </td>
                                    <td>
                                        <asp:Label ID="Label1" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        应收款：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblReceivable" runat="server" Text=""></asp:Label>
                                    </td>
                                </tr>
                                <tr>
                                    <td class="right ">
                                        电话：
                                    </td>
                                    <td>
                                        <asp:Label ID="txtTelephone" runat="server" Text=""></asp:Label>
                                        <asp:Label ID="lblTelphoneLink" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        手机：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblCellPhone" runat="server" Text=""></asp:Label>
                                        <asp:Label ID="lblMobilePhoneLink" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        传真：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblFax" runat="server"></asp:Label>
                                        <asp:Label ID="lblFaxLink" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        邮件：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblEmail" runat="server"></asp:Label>
                                        <asp:Label ID="lblEmailLink" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        其他：
                                    </td>
                                    <td>
                                        <asp:Label ID="lblContact" runat="server" Text=""></asp:Label>
                                        <asp:Label ID="lblQQLink" runat="server" Text=""></asp:Label>
                                    </td>
                                </tr>
                                <tr>
                                    <td class="right ">
                                        地区：
                                    </td>
                                    <td >
                                        <asp:Label ID="lblStateName" runat="server" Text=""></asp:Label>
                                    </td>
                                    <td class="right ">
                                        地址：
                                    </td>
                                    <td colspan="7">
                                        <asp:Label ID="lblAddress" runat="server" Text=""></asp:Label>
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <div class="tab_handles" style="margin-left: 30px; background: none; border-top: none;
                            height: 35px;">
                            <span class="current">动态</span> <span>详细信息</span> <span>订单</span> <span>商机</span>
                            <span>行动</span> <span>服务</span> <span>积分</span> <span>预存款</span> <span>序列号</span>
                            <span>访问日志</span> <span>操作日志</span>
                        </div>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td class="main_center">
                <!--主体-->
                <div class="page_main">
                    <div class="page_content">
                        <div class="tabs">
                            <div class="tab_contents" style="border-top: none;">
                                <table width="100%" cellpadding="0" cellspacing="0">
                                    <tr>
                                        <td width="75%">
                                            <div class="order_widget" style="display: none;">
                                                <div class="order_State">
                                                    <ul>
                                                        <li><strong class="fonts colorE">当前订单状态：<asp:Literal ID="ltlOrderState" runat="server"
                                                            Text=""></asp:Literal>
                                                        </strong></li>
                                                        <li>
                                                            <asp:Button ID="btnAudit" runat="server" Text="审批" CssClass="btn_77px" Enabled="false" />
                                                            <asp:Button ID="btnPay" runat="server" Text="付款" CssClass="btn_77px" OnClientClick="return OpenDialog('DeliveryEdit.aspx','新增收款');"
                                                                Enabled="false" />
                                                            <asp:Button ID="btnBackPay" runat="server" Text="退款" CssClass="btn_77px" Enabled="false" />
                                                            <asp:Button ID="btnDelivery" runat="server" Text="发货" CssClass="btn_77px" Enabled="false" />
                                                            <asp:Button ID="btnBack" runat="server" Text="退货" CssClass="btn_77px" Enabled="false" />
                                                            <asp:Button ID="btnComplete" runat="server" Text="完成" CssClass="btn_77px" Enabled="false" />
                                                            <asp:Button ID="btnBlankOut" runat="server" Text="作废" CssClass="btn_77px" Enabled="false" />
                                                            <input id="btnBackUrl" type="button" value="返回" class="btn_77px" onclick="window.location.href='<%=Request["ref"] %>'" />
                                                        </li>
                                                    </ul>
                                                </div>
                                            </div>
                                            <div class="tab_content">
                                                <div class="order_widget">
                                                    <div class="order_State" style="padding-top: 10px">
                                                        <uc3:CommentList ID="CommentList" runat="server" />
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                    <div class="order_State">
                                                        <table border="0" cellspacing="0" cellpadding="0" style="margin: 10px; width: 95%"
                                                            class="TbDetail">
                                                            <tr>
                                                                <td class="right" width="15%">
                                                                    登录名：
                                                                </td>
                                                                <td class="data-field" width="35%">
                                                                    <asp:Label ID="lblLoginName" runat="server"></asp:Label>
                                                                    <asp:Label ID="lblState" runat="server" Text="Label"></asp:Label>
                                                                    <asp:LinkButton ID="lbtnAudit" runat="server" OnClick="lbtnAudit_Click"></asp:LinkButton>
                                                                </td>
                                                                <td class="right" width="15%">
                                                                    密码：
                                                                </td>
                                                                <td class="data-field">
                                                                    <table>
                                                                        <tr>
                                                                            <td>
                                                                                <span>******</span>
                                                                            </td>
                                                                            <td>
                                                                                <span style="margin-left: 10px;">
                                                                                    <asp:LinkButton ID="lbtnInitPwd" runat="server" OnClick="lbtnInitPwd_Click">[初始化密码]</asp:LinkButton></span>
                                                                            </td>
                                                                        </tr>
                                                                    </table>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right" width="15%">
                                                                    客户名称：
                                                                </td>
                                                                <td class="data-field" width="35%">
                                                                    <asp:Label ID="txtCustomerName" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    助记简称：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblShortName" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right" width="15%">
                                                                    重要程度：
                                                                </td>
                                                                <td class="data-field" width="35%">
                                                                    <asp:Label ID="lblHotLevel" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    分类：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblBizTypeName" runat="server" Text="Label"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right" width="15%">
                                                                    上级客户：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblParentName" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    行业：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblIndustryName" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    网址：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblWeb" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    微博/SNS：
                                                                </td>
                                                                <td class="data-field">
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    来源：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblSourceName" runat="server"></asp:Label>
                                                                    <asp:Label ID="lblOtherSource" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    来源线索：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:HyperLink ID="hyplnkCustomerClue" runat="server" Target="_blank"></asp:HyperLink>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    来源网址：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblFromUrl" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    来源Id：
                                                                </td>
                                                                <td class="data-field">
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    是否锁定：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblIsLock" runat="server" Text=""></asp:Label>
                                                                    <asp:LinkButton ID="lbtnLock" runat="server" OnClick="lbtnLock_Click"></asp:LinkButton>
                                                                </td>
                                                                <td class="right">
                                                                    货币：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblCurrency" runat="server" Text=""></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    消费次数：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblOrderCount" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    消费金额：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblExpenditure" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    上次交易时间：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblLastTradeDate" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    信用额度：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblCredit_line" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    登录次数：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lbllogin_count" runat="server" Text=""></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    是否黑名单：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblIsBlackList" runat="server" Text=""></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    上次登录：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lbllast_login" runat="server" Text=""></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    上次登录Ip：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lbllast_ip" runat="server" Text=""></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    企业性质：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblNature" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    公司规模：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblScale" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    年营业额：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblTurnover" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    产品服务：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblService" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    法人代表：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblLegalPerson" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    证件号码：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblIDnumber" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    公司简介：
                                                                </td>
                                                                <td class="data-field" colspan="3">
                                                                    <asp:Label ID="lblCustomerInfo" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    成交时间：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="txtTradeDate" runat="server" Text=""></asp:Label>
                                                                    <asp:Label ID="lblTradeUserId" runat="server" Text=""></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    下次联系时间：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:TextBox ID="txtNextContactTime" onfocus="WdatePicker()" runat="server"></asp:TextBox>
                                                                    <asp:Button ID="btnUpdate" runat="server" OnClick="btnUpdate_Click" Text="更新" />
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    创建时间：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblCreateDate" runat="server"></asp:Label>
                                                                    <asp:Label ID="lblCreateBy" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    最后更新时间：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblModifyDate" runat="server"></asp:Label>
                                                                    <asp:Label ID="lblModifyMan" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    省份：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblProvinceName" runat="server"></asp:Label>
                                                                    城市：<asp:Label ID="lblCityName" runat="server"></asp:Label>
                                                                </td>
                                                                <td class="right">
                                                                    其他城市：
                                                                </td>
                                                                <td class="data-field">
                                                                    <asp:Label ID="lblCity" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                            <tr>
                                                                <td class="right">
                                                                    备注：
                                                                </td>
                                                                <td class="data-field" colspan="3">
                                                                    <asp:Label ID="lblRemark" runat="server"></asp:Label>
                                                                </td>
                                                            </tr>
                                                        </table>
                                                    </div>
                                                </div>
                                                <div class="order_widget">
                                                    <uc8:ContactList ID="ContactList1" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                    <uc6:OrderList ID="OrderList1" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide" runat="server">
                                                <div class="order_widget">
                                                    <uc4:OpportunityList ID="OpportunityList1" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                    <uc2:ActionList ID="ActionList1" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                 <uc9:ServiceList ID="ServiceList" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                    <uc7:SnList ID="SnList1" runat="server" />
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                </div>
                                            </div>
                                            <div class="tab_content hide">
                                                <div class="order_widget">
                                                    <uc5:LogList ID="LogList1" runat="server" />
                                                </div>
                                            </div>
                                        </td>
                                        <td>
                                            <div class="order_widget" style="margin-left: 10px;">
                                                <div class="order_State">
                                                    <uc1:TaskNav ID="TaskNav1" runat="server" />
                                                </div>
                                            </div>
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </div>
                    </div>
                </div>
            </td>
        </tr>
    </table>
    <asp:HiddenField ID="TabId" runat="server" Value="0" />
    <script type="text/javascript">

        $(".tab_handles span").click(function () {
            var hideIndex = $(".tab_handles .current").index();
            $(".tab_handles span").removeClass("current");
            $(this).addClass("current");
            $(".tab_contents .tab_content:eq(" + hideIndex + ")").hide();
            $(".tab_contents .tab_content:eq(" + $(this).index() + ")").show();

            $("#<%=TabId.ClientID  %>").val($(this).index());

        })

        var CurrentIndex = $("#<%=TabId.ClientID  %>").val();
        $(".tab_handles span:eq(" + CurrentIndex + ")").click();
       
    </script>
</asp:Content>
