From d789099e9dc45e7fa3ee0eb73ee97f80b1963466 Mon Sep 17 00:00:00 2001
From: CB2-20200827ONU\Administrator <liaoxujun@qq.com>
Date: 星期五, 08 十月 2021 09:23:47 +0800
Subject: [PATCH] no message

---
 CY_ECommercePlatform/CY.WebForm/CY.WebForm.csproj                                              |    9 
 CY_ECommercePlatform/CY.WebForm/js/PictureShow/spotlight.bundle.js                             |   31 +
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx.cs                    |   21 +
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.designer.cs   |   35 +
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx               |   50 ++
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.cs            |   91 +++++
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx             |  318 +++++++++++++----
 CY_ECommercePlatform/CY.Model/OA/OA_CorporateClients.cs                                        |    4 
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx                       |    4 
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.cs          |  436 +++++++++++++++++++++---
 CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.designer.cs |   27 +
 11 files changed, 887 insertions(+), 139 deletions(-)

diff --git a/CY_ECommercePlatform/CY.Model/OA/OA_CorporateClients.cs b/CY_ECommercePlatform/CY.Model/OA/OA_CorporateClients.cs
index aa8aed1..4415ba6 100644
--- a/CY_ECommercePlatform/CY.Model/OA/OA_CorporateClients.cs
+++ b/CY_ECommercePlatform/CY.Model/OA/OA_CorporateClients.cs
@@ -606,6 +606,10 @@
         /// 搴旀敹娆捐鍗曟暟閲�
         /// </summary>
         public int? NoOverOderCount { get; set; }
+        /// <summary>
+        /// 鍚堝悓鏁伴噺
+        /// </summary>
+        public int? ContractCount { get; set; }
 
         /// <summary>
         /// 鏄惁闇�瑕佹墽琛屼簡鏃ュ父缁存姢
diff --git a/CY_ECommercePlatform/CY.WebForm/CY.WebForm.csproj b/CY_ECommercePlatform/CY.WebForm/CY.WebForm.csproj
index 70a51a7..b273fc9 100644
--- a/CY_ECommercePlatform/CY.WebForm/CY.WebForm.csproj
+++ b/CY_ECommercePlatform/CY.WebForm/CY.WebForm.csproj
@@ -732,6 +732,7 @@
     <Content Include="js\Inquiry\Calculator.js" />
     <Content Include="js\Inquiry\Inquiry.js" />
     <Content Include="js\jquery.form.js" />
+    <Content Include="js\PictureShow\spotlight.bundle.js" />
     <Content Include="js\procurement\GoodsName.js" />
     <Content Include="js\procurement\PaperWeight.js" />
     <Content Include="js\utils\calendar.js" />
@@ -1872,6 +1873,7 @@
     <Content Include="Pages\business\ComplaintsManage.aspx" />
     <Content Include="Pages\business\ComplaintsView.aspx" />
     <Content Include="Pages\business\CompledWork.aspx" />
+    <Content Include="Pages\business\CorporateClientsContractShow.aspx" />
     <Content Include="Pages\business\CorporateClientsDetail.aspx" />
     <Content Include="Pages\business\CorporateClientsEdit.aspx" />
     <Content Include="Pages\business\CorporateClientsList.aspx" />
@@ -3283,6 +3285,13 @@
     <Compile Include="Pages\business\CompledWork.aspx.designer.cs">
       <DependentUpon>CompledWork.aspx</DependentUpon>
     </Compile>
+    <Compile Include="Pages\business\CorporateClientsContractShow.aspx.cs">
+      <DependentUpon>CorporateClientsContractShow.aspx</DependentUpon>
+      <SubType>ASPXCodeBehind</SubType>
+    </Compile>
+    <Compile Include="Pages\business\CorporateClientsContractShow.aspx.designer.cs">
+      <DependentUpon>CorporateClientsContractShow.aspx</DependentUpon>
+    </Compile>
     <Compile Include="Pages\business\CorporateClientsDetail.aspx.cs">
       <DependentUpon>CorporateClientsDetail.aspx</DependentUpon>
       <SubType>ASPXCodeBehind</SubType>
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx
new file mode 100644
index 0000000..0642d2e
--- /dev/null
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx
@@ -0,0 +1,50 @@
+锘�<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CorporateClientsContractShow.aspx.cs" Inherits="CY.WebForm.Pages.business.CorporateClientsContractShow" %>
+
+<%-- 鍚堝悓娴忚椤甸潰銆備富瑕佹槸鐢ㄦ潵鎸夌収浠ユ祻瑙堟柟寮� --%>
+<!DOCTYPE html>
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head runat="server">
+    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+    <title></title>
+    <script src="./../../js/PictureShow/spotlight.bundle.js"></script>
+     <style type="text/css">
+
+     .textcenter{text-align:center} 
+      .horizontal{
+        float:left;
+        border:1px solid black;
+        margin-left:20px;
+    }
+</style>
+</head>
+     
+<form id="form1" runat="server">
+     <div class="textcenter">鍚堝悓棰勮</div>
+
+   
+<asp:Repeater id="RepClientList" runat="server">
+         <ItemTemplate>
+             <div class="textcenter horizontal"  width="100" >
+            <a class="spotlight" href="<%#Eval("FilePath").ToString() %>">
+            
+                <img src="<%#Eval("FilePath").ToString() %>" width="100" height="200" >
+                   
+                
+            </a>
+               <p >绗�<%#Eval("PageCode")%>椤�</p>
+
+                </div>
+           </ItemTemplate>
+     
+</asp:Repeater>   
+
+   
+</form>
+
+
+
+
+   
+
+</html>
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.cs
new file mode 100644
index 0000000..5c24e29
--- /dev/null
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.cs
@@ -0,0 +1,91 @@
+锘縰sing CY.Infrastructure.Common;
+using CY.Infrastructure.Logging;
+using CY.Model.OA;
+using CY.SQLDAL;
+using System;
+using System.Collections.Generic;
+using System.Data.SqlClient;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+using static CY.WebForm.MainPage;
+
+namespace CY.WebForm.Pages.business
+{
+    public partial class CorporateClientsContractShow : System.Web.UI.Page
+    {
+        /// <summary>
+        /// 鍚堝悓闄勪欢闆嗗悎
+        /// </summary>
+        List<OA_CorporateClientsContract> fileDataList { set; get; } = new List<OA_CorporateClientsContract>();
+        protected void Page_Load(object sender, EventArgs e)
+        {
+            ReadList();
+        }
+
+
+        private void ReadList()
+        {
+
+            Guid Keyid = Request["Keyid"].ToGuid2();
+
+            if (Keyid == null)
+            {
+                JavaScript.MessageBox("鏈壘鍒拌瀹㈡埛", this, false, false);
+                return;
+            }
+            Database DC = new Database();
+            string sqlStr = string.Format(@"USE [ECTEST]    select * from  [dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}' order by PageCode  ", Keyid);
+            int count = 0;
+            try
+            {
+                SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
+                //SqlDataAdapter myDa = new SqlDataAdapter(myCmd);
+                var a = myCmd.ExecuteReader();
+                //myDa.Dispose();
+                fileDataList = new List<OA_CorporateClientsContract>();
+                OA_CorporateClientsContract Contract;
+                while (a.Read())
+                {   //娉ㄦ剰濡備綍灏嗘瘡娆¤鍙栧埌鐨勮褰曟坊鍔犲埌listbox1涓紙鍥犱负绗竴娆″仛鏃跺嚭閿欎簡锛屽樋鍢匡級
+                    Contract = new OA_CorporateClientsContract();
+                    Contract.Keyid = a.GetGuid(0);
+                    Contract.CorporateClientsid = a.GetGuid(1);
+                    Contract.CorporateClientsName = a.GetString(2);
+                    Contract.FileName = a.GetString(3);
+                    Contract.PageCode = a.GetInt32(4);
+                    Contract.FilePath = a.GetString(5);
+                    Contract.Remark = a.GetString(6);
+
+
+                    fileDataList.Add(Contract);
+                }
+                a.Close();     //鍏抽棴sqldatareader
+                sqlStr = string.Format("select  count(*) from [dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}'", Keyid);
+                myCmd = new SqlCommand(sqlStr, DC.Connection);
+                count = (int)myCmd.ExecuteScalar();
+
+
+            }
+            catch (Exception ee)
+            {
+                new Log4NetAdapter().Log("鏌ユ壘鍚堝悓鍑洪敊锛�" + ee.Message);
+
+            }
+            finally
+            {
+                if (DC.Connection.State != System.Data.ConnectionState.Closed)
+                    DC.Connection.Close();
+            }
+
+
+
+
+            this.RepClientList.DataSource = fileDataList;// fileDataList.AsEnumerable<OA_CorporateClientsContract>();
+
+            this.RepClientList.DataBind();
+
+           
+        }
+    }
+}
\ No newline at end of file
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.designer.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.designer.cs
new file mode 100644
index 0000000..9b28b5c
--- /dev/null
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsContractShow.aspx.designer.cs
@@ -0,0 +1,35 @@
+锘�//------------------------------------------------------------------------------
+// <鑷姩鐢熸垚>
+//     姝や唬鐮佺敱宸ュ叿鐢熸垚銆�
+//
+//     瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉
+//     閲嶆柊鐢熸垚浠g爜锛屽垯鎵�鍋氭洿鏀瑰皢涓㈠け銆�
+// </鑷姩鐢熸垚>
+//------------------------------------------------------------------------------
+
+namespace CY.WebForm.Pages.business
+{
+
+
+    public partial class CorporateClientsContractShow
+    {
+
+        /// <summary>
+        /// form1 鎺т欢銆�
+        /// </summary>
+        /// <remarks>
+        /// 鑷姩鐢熸垚鐨勫瓧娈点��
+        /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+        /// </remarks>
+        protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+        /// <summary>
+        /// RepClientList 鎺т欢銆�
+        /// </summary>
+        /// <remarks>
+        /// 鑷姩鐢熸垚鐨勫瓧娈点��
+        /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+        /// </remarks>
+        protected global::System.Web.UI.WebControls.Repeater RepClientList;
+    }
+}
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx
index 4f5a9e8..0d4f535 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx
@@ -357,7 +357,9 @@
                                 <span menu_member_case_id="case_setinquiryCorporateClients" menu_member_case_name="璇环璁剧疆" onclick="SetInquiryPar('<%#Eval("Keyid")%>')">璇环璁剧疆</span> 
                                 <span menu_member_case_id="case_orderapplyCorporateClients" menu_member_case_name="璁㈠崟鍏宠仈" onclick="onChange('<%#Eval("Keyid")%>')" title="绾夸笅瀹㈡埛杞崲涓虹嚎涓婂鎴�" style="display: <%#Eval("Keyid").ToString() == Eval("MemberId").ToString() ? "inline" : "none"%>;">璁㈠崟鍏宠仈</span>
                                 <span onclick="onViewWeihu('<%#Eval("Keyid")%>')">缁存姢璁板綍</span>
-                                <span onclick="onViewuplod('<%#Eval("Keyid")%>')">鏌ョ湅鍚堝悓</span>
+                               
+                                <span onclick="onViewuplod('<%#Eval("Keyid")%>')"  <%#Eval("ContractCount").ToString() == "0" ? "hidden" : ""%>>鏌ョ湅鍚堝悓</span>
+                                
                             </td>
                         </tr>
                     </ItemTemplate>
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx.cs
index bd89264..aed7ac1 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx.cs
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsList.aspx.cs
@@ -11,6 +11,7 @@
 using CY.BLL.Sys;
 using CY.BLL.OA;
 using CY.SQLDAL;
+using System.Data.SqlClient;
 
 namespace CY.WebForm.Pages.business
 {
@@ -155,6 +156,26 @@
                 item.LessOrderMoneyProperty = item.Contractmoney-item.OrderMoney;
 
                 item.NoOverOderCount = bll_eC_OrderBasicDAL.GetOrderById(item.Keyid, -1).Count;
+                Database DC = new Database();
+                try
+                {
+                  
+                    string sqlStr = string.Format("select  count(*) from [dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}'", item.Keyid);
+                    SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
+                    item.ContractCount = (int)myCmd.ExecuteScalar();
+                }
+                catch (Exception)
+                {
+
+                    item.ContractCount = 0;
+                }
+                finally
+                {
+                    if (DC.Connection.State != System.Data.ConnectionState.Closed)
+                        DC.Connection.Close();
+                }
+               
+
             }
             this.RepClientList.DataBind();
             UCPager1.AspNetPager.RecordCount = pa.RecordCount;
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx
index 37b68fb..38cd8c1 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx
@@ -1,141 +1,295 @@
 锘�<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CorporateClientsUpLoadContract.aspx.cs" Inherits="CY.WebForm.Pages.business.CorporateClientsUpLoadContract" %>
+
 <%-- 涓婁紶鍚堝悓椤甸潰  寤� 20210916澧炲姞--%>
 <!DOCTYPE html>
-<script src="js/jquery.min.js" type="text/javascript"></script>
-<script src="js/jquery.hammer.min.js" type="text/javascript"></script>  
+<script src="./../../myPagination/js/share/js/jquery.min.js" type="text/javascript"></script>
+<%--<script src="./../../js/jquery.hammer.min.js" type="text/javascript"></script>--%>
 
 <html xmlns="http://www.w3.org/1999/xhtml">
-<head  id="Head1"  runat="server">
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+<head id="Head1" runat="server">
+    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
     <title></title>
-    
- 
-      <uc:CMSHead ID="CMSHead1" runat="server" />
+
+
+    <uc:CMSHead ID="CMSHead1" runat="server" />
+
 </head>
 <body>
     <form id="form1" runat="server">
-           <div class="box1" paneltitle="鍔熻兘闈㈡澘" roller="false">
+        <div class="box1" paneltitle="鍔熻兘闈㈡澘" roller="false">
             <table class="TableNewStyle">
                 <tr>
-                      <td class="ali03">鏂板鍚堝悓椤甸潰锛�
-                        </td>                    
+                    <td style="width:200px">鏂板鎴栬�呮浛鎹㈠悎鍚岄〉闈細
+                    </td>                   
+
+                    <td style="width:100px">绗�
+                        <input type="text" runat="server" id="TextPage" style="width:40px" onkeyup="value=value.replace(/[^\d]/g,'')" />
+                        椤�
+                    </td>
+                    <td class="ali03"></td>
+
                     <td class="ali03">
-                        椤电爜锛�
+                        <input type="file" id="filesel" name="__hetongFile" keepdefaultstyle="true" runat="server" text="璇烽�夋嫨鏂囦欢" /></td>
+                    <td>
+                        <asp:Button ID="UpdateFileNew" Text="涓婁紶" runat="server" OnClick="btn_Submit_Click" OnClientClick="return checkSelFile()" /></td>
+                </tr>
+            </table>
+
+
+        </div>
+
+        <div class="box1" paneltitle="鍔熻兘闈㈡澘" roller="false">
+            <table class="TableNewStyle">
+                <tr>
+                    <td class="ali06" style="width:200px">
+                        
+                        鎵归噺涓婁紶锛�
+                         
+                    </td>
+                    <td class="ali03" style="width:100px">
                     </td>
 
+                    <td class="ali03"></td>
+
+                    <td class="ali03">
+                        <input type="file" id="file2" name="__hetongMutilfiles" keepdefaultstyle="true" multiple="multiple" runat="server"  text="璇烽�夋嫨鏂囦欢"/></td>
                     <td>
-                        绗� <input type="text" runat="server" id="TextPage" /> 椤�
-                    </td>
-                     <td class="ali03"></td>
-                  
-                    <td class="ali03"><input type="file" id="filesel" name="__hetongFile"  keepdefaultstyle="true" multiple="multiple" runat="server"  /></td>
-                    <td> <asp:Button ID="UpdateFileNew" Text="鏂板鎴栬�呮浛鎹㈣椤�(涓婁紶鍥剧墖)" runat="server" OnClick="btn_Submit_Click"   OnClientClick="return checkSelFile()" /></td>
+                        <asp:Button ID="Button1" Text="鎵归噺涓婁紶" runat="server" OnClick="btn_Submit_Click_multi" OnClientClick="return checkSelMulitFile()" /></td>
                 </tr>
             </table>
         </div>
-          <div>
-  
-              <p style="text-align:center"> 宸叉湁椤甸潰</p>
-   
-            <asp:repeater id="RepClientList" runat="server" >
-                <headertemplate>
+        <div>
+
+            <p style="text-align: center">宸叉湁椤甸潰</p>
+
+            <asp:Repeater ID="RepClientList" runat="server">
+                <HeaderTemplate>
                     <table class="tableStyle">
                         <tr>
-                           <%-- <th width="25"></th>--%>
-                            <th width="60" style="text-align:center">
-                                椤电爜
+                            <%-- <th width="25"></th>--%>
+                            <th width="60" style="text-align: center">椤电爜
                             </th>
-                            <th style="text-align:center" >
-                                棰勮
+                            <th style="text-align: center">棰勮
                             </th>
-                           <th style="text-align:center">
-                                鎿嶄綔
-                            </th>               
-                          
-                          
+                            <th style="text-align: center">鎿嶄綔
+                            </th>
+
+
                         </tr>
-                </headertemplate>        
-              
+                </HeaderTemplate>
+
 
                 <ItemTemplate>
-                        <tr>
-                           <%-- <td>
+                    <tr>
+                        <%-- <td>
                                 <input type="checkbox" class="SelectCheck" value_kid="<%#Eval("Keyid")%>" />
                             </td>--%>
-                            <td>
-                               绗�  <%#Eval("PageCode")%> 椤�                       
-                            </td>
-                            <td>
-                                 
-                             <a   title="鐐瑰嚮鏌ョ湅鍘熷浘"   href="<%#Eval("FilePath").ToString() %>" target="view_window">
-                                   <img src="<%#Eval("FilePath").ToString() %>"  width="80" height="100"/> </a>
-                       
-                            </td>
+                        <td>绗�  <%#Eval("PageCode")%> 椤�                       
+                        </td>
+                        <td>
+
+                            <a title="鐐瑰嚮鏌ョ湅鍘熷浘" href="<%#Eval("FilePath").ToString() %>" target="view_window">
+                                <img src="<%#Eval("FilePath").ToString() %>" width="80" height="100" />
+                            </a>
+
+                        </td>
 
 
-                           <td>
-                                 
-                                <a onclick="delelid('<%#Eval("Keyid")%>','<%= Request["Keyid"]%>')">鍒犻櫎褰撳墠椤甸潰</a>
-                           </td>
-                           
-                            
-                          
-                         
-                            
-                          
-                           
-                        </tr>
-                    </ItemTemplate>
-                 
+                        <td>
 
-                    <FooterTemplate>
-                        </table>
-                    </FooterTemplate>
-                  
+                            <a onclick="delelid('<%#Eval("Keyid")%>','<%= Request["Keyid"]%>')">鍒犻櫎褰撳墠椤甸潰</a>
+                        </td>
 
 
 
 
-                </asp:repeater>
-                     <div id="page">
-                    <uc:UCPager ID="UCPager1" runat="server" />
-                </div>
 
-               
-                 
-             
-              </div>
+
+
+                    </tr>
+                </ItemTemplate>
+
+
+                <FooterTemplate>
+                    </table>
+                </FooterTemplate>
+
+
+
+
+
+            </asp:Repeater>
+            <div id="page">
+                <uc:UCPager ID="UCPager1" runat="server" />
+            </div>
+
+
+
+
+        </div>
+        <button id="Buttonupload" onclick="onViewuplodshow('<%= Request["Keyid"]%>')">娴忚鍏ㄩ儴</button>
        
+        <asp:Button ID="Button3"  Text="鍒犻櫎鎵�鏈夊悎鍚�"  runat="server"  OnClick="btn_Submit_Click_DELLALL" />
+        
+
     </form>
 </body>
 </html>
 <script type="text/javascript">
 
     //鏌ョ湅
+    function checkSelMulitFile() {
+
+        var oFile = document.getElementById('file2');
+        if (oFile.value == "") {
+            alertMsg('娌℃湁閫夋嫨鏂囦欢');
+            return false;
+           
+        }
+        //debugger;
+        //replaceParamVal("deleteKeyIds", "");
+        return true;
+    }
+    //鏌ョ湅
     function checkSelFile() {
-    
+
         if (document.getElementById("TextPage").value == "") {
             alertMsg("娌℃湁杈撳叆椤垫暟");
-           
+
             return false;
         }
         var oFile = document.getElementById('filesel');
-            if(oFile.value == ""){
-                alertMsg('娌℃湁閫夋嫨鏂囦欢');
-                return false;
-               
-}
+        if (oFile.value == "") {
+            alertMsg('娌℃湁閫夋嫨鏂囦欢');
+            return false;
 
+        }
+        //debugger;
+        //replaceParamVal("deleteKeyIds", "");
         return true;
     }
 
-    //鍒犻櫎鍒跺畾鍚堝悓椤甸潰
-    function delelid(KeyID,pageID) {
+    //鏀瑰彉鍙傛暟
+    function changeURLArg(url, arg, arg_val) {
+        var pattern = arg + '=([^&]*)';
+        var replaceText = arg + '=' + arg_val;
+        if (url.match(pattern)) {
+            var tmp = '/(' + arg + '=)([^&]*)/gi';
+            tmp = url.replace(eval(tmp), replaceText);
+            return tmp;
+        } else {
+            if (url.match('[\?]')) {
+                return url + '&' + replaceText;
+            } else {
+                return url + '?' + replaceText;
+            }
+        }
+    }
 
+
+    // 鑾峰彇url閲岀殑鍙傛暟
+
+    function getURLString(arg) {
+        var reg = new RegExp("(^|&)" + arg + "=([^&]*)(&|$)", "i");
+        var r = window.location.search.substr(1).match(reg);
+        if (r != null)
+            return unescape(r[2]);
+        return null;
+    }
+
+    //鏇挎崲鎸囧畾浼犲叆鍙傛暟鐨勫��,paramName涓哄弬鏁�,replaceWith涓烘柊鍊�
+    function replaceParamVal(paramName, replaceWith) {
+        var oUrl = this.location.href.toString();
+        var re = eval('/(' + paramName + '=)([^&]*)/gi');
+        var nUrl = oUrl.replace(re, paramName + '=' + replaceWith);
+        this.location = nUrl;
+        window.location.href = nUrl
+    }
+    //鍒犻櫎鍒跺畾鍚堝悓椤甸潰
+    function delelid(KeyID, pageID) {
+
+     
         top.Dialog.confirm("鏄惁瑕佸垹闄よ鍚堝悓椤甸潰锛�", function () {
             window.location = "/Pages/business/CorporateClientsUpLoadContract.aspx?deleteKeyIds=" + KeyID + "&Keyid=" + pageID;
         }
         );
     }
-            
+
+
+
+    //缁存姢
+    function onViewuplodshow(keyid) {
+
+       
+        top.Dialog.open({ URL: "/Pages/business/CorporateClientsContractShow.aspx?Keyid=" + keyid, Title: "娴忚鍚堝悓", Width: 1024, Height: 750 });
+    }
+
+    $(document).ready(function () {
+        $("#file2").change(function () {
+            var myfile = document.getElementById('file2');
+         
+       
+            for (let i = 0; i < myfile.files.length; i++)
+        {
+                var filepath = myfile.files[i].name;
+          
+            var extStart = filepath.lastIndexOf(".");
+            var ext = filepath.substring(extStart, filepath.length).toUpperCase();
+            if (ext != ".BMP" && ext != ".PNG" && ext != ".GIF" && ext != ".JPG" && ext != ".JPEG") {
+                alertMsg("鍥剧墖闄愪簬bmp,png,gif,jpeg,jpg鏍煎紡");
+                
+                return false;
+            } else { $("#fileType").text(ext) }
+             
+                var ext = filepath.substring(0, extStart);
+                if (isNumber(ext)) {
+
+                }
+                else {
+                    alertMsg(filepath + '鏂囦欢鍚嶆湁璇�');
+                    return false;
+                }
+                
+        }
+           
+            //var file_size = 0;
+            //if ($.browser.msie) {
+            //    var img = new Image();
+            //    img.src = filepath;
+            //    while (true) {
+            //        if (img.fileSize > 0) {
+            //            if (img.fileSize > 3 * 1024 * 1024) {
+            //                alert("鍥剧墖涓嶅ぇ浜�100MB銆�");
+            //            } else {
+            //                var num03 = img.fileSize / 1024;
+            //                num04 = num03.toFixed(2)
+            //                $("#fileSize").text(num04 + "KB");
+            //            }
+            //            break;
+            //        }
+            //    }
+            //} else {
+            //    file_size = this.files[0].size;
+            //    var size = file_size / 1024;
+            //    if (size > 10240) {
+            //        alert("涓婁紶鐨勫浘鐗囧ぇ灏忎笉鑳借秴杩�10M锛�");
+            //    } else {
+            //        var num01 = file_size / 1024;
+            //        num02 = num01.toFixed(2);
+            //        $("#fileSize").text(num02 + " KB");
+            //    }
+            //}
+            return true;
+        });
+    });
+    function isNumber(val) {
+        var regPos = /^\d+(\.\d+)?$/; //闈炶礋娴偣鏁�
+        var regNeg = /^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$/; //璐熸诞鐐规暟
+        if (regPos.test(val) || regNeg.test(val)) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+
 </script>
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.cs
index 20e062c..6f2c9e8 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.cs
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.cs
@@ -39,69 +39,147 @@
 
             
             
-                if (Request["deleteKeyIds"] != null)
+                if (Request["deleteKeyIds"] != null&& Request["deleteKeyIds"]!="")
             {
-                //鍒犻櫎椤甸潰
-                string  keyid = Request["deleteKeyIds"].ToString();
-                Database DC = new Database();
-                string  sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid]      ,[CorporateClientsid]       ,[CorporateClientsName]       ,[FileName]       ,[PageCode]       ,[FilePath]       ,[Remark]     FROM[dbo].[OA_CorporateClientContract] where Keyid='{0}'ORDER BY PageCode ", keyid);
-
-                
-                try
+                if (Request["deleteKeyIds"] == "all")
                 {
-                    SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
-                    //SqlDataAdapter myDa = new SqlDataAdapter(myCmd);
-                    var a = myCmd.ExecuteReader();
-                    //myDa.Dispose();
-                    fileDataList = new List<OA_CorporateClientsContract>();
-                    OA_CorporateClientsContract Contract;
-                    while (a.Read())
-                    {   //娉ㄦ剰濡備綍灏嗘瘡娆¤鍙栧埌鐨勮褰曟坊鍔犲埌listbox1涓紙鍥犱负绗竴娆″仛鏃跺嚭閿欎簡锛屽樋鍢匡級
-                        Contract = new OA_CorporateClientsContract();
-                        Contract.Keyid = a.GetGuid(0);
-                        Contract.CorporateClientsid = a.GetGuid(1);
-                        Contract.CorporateClientsName = a.GetString(2);
-                        Contract.FileName = a.GetString(3);
-                        Contract.PageCode = a.GetInt32(4);
-                        Contract.FilePath = a.GetString(5);
-                        Contract.Remark = a.GetString(6);
+                    //鍒犻櫎璇存湁椤甸潰
+                    string keyid = Request["deleteKeyIds"].ToString();
+                    string pageID = Request["Keyid"];
+                    Database DC = new Database();
+                    string sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid]      ,[CorporateClientsid]       ,[CorporateClientsName]       ,[FileName]       ,[PageCode]       ,[FilePath]       ,[Remark]     FROM[dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}'ORDER BY PageCode ", pageID);
 
 
-                        fileDataList.Add(Contract);
-                    }
-                    a.Close();     //鍏抽棴sqldatareader
-                    if (fileDataList.Count > 0)
-                    { FileInfo file = new FileInfo(Server.MapPath(fileDataList[0].FilePath));//鎸囧畾鏂囦欢璺緞
-                        if (file.Exists)//鍒ゆ柇鏂囦欢鏄惁瀛樺湪
-                        {
-                            file.Attributes = FileAttributes.Normal;//灏嗘枃浠跺睘鎬ц缃负鏅��,姣旀柟璇村彧璇绘枃浠惰缃负鏅��
-                            file.Delete();//鍒犻櫎鏂囦欢
+                    try
+                    {
+                        SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
+                        //SqlDataAdapter myDa = new SqlDataAdapter(myCmd);
+                        var a = myCmd.ExecuteReader();
+                        //myDa.Dispose();
+                        fileDataList = new List<OA_CorporateClientsContract>();
+                        OA_CorporateClientsContract Contract;
+                        while (a.Read())
+                        {   //娉ㄦ剰濡備綍灏嗘瘡娆¤鍙栧埌鐨勮褰曟坊鍔犲埌listbox1涓紙鍥犱负绗竴娆″仛鏃跺嚭閿欎簡锛屽樋鍢匡級
+                            Contract = new OA_CorporateClientsContract();
+                            Contract.Keyid = a.GetGuid(0);
+                            Contract.CorporateClientsid = a.GetGuid(1);
+                            Contract.CorporateClientsName = a.GetString(2);
+                            Contract.FileName = a.GetString(3);
+                            Contract.PageCode = a.GetInt32(4);
+                            Contract.FilePath = a.GetString(5);
+                            Contract.Remark = a.GetString(6);
+
+
+                            fileDataList.Add(Contract);
                         }
+                        a.Close();     //鍏抽棴sqldatareader
+                        if (fileDataList.Count > 0)
+                        {
+                            foreach (var item in fileDataList)
+                            {
+                                FileInfo file = new FileInfo(Server.MapPath(item.FilePath));//鎸囧畾鏂囦欢璺緞
+                                if (file.Exists)//鍒ゆ柇鏂囦欢鏄惁瀛樺湪
+                                {
+                                    file.Attributes = FileAttributes.Normal;//灏嗘枃浠跺睘鎬ц缃负鏅��,姣旀柟璇村彧璇绘枃浠惰缃负鏅��
+                                    file.Delete();//鍒犻櫎鏂囦欢
+                                }
+                                sqlStr = string.Format(@"USE [ECTEST]DELETE FROM [dbo].[OA_CorporateClientContract] where Keyid='{0}'", item.Keyid);
+                                myCmd = new SqlCommand(sqlStr, DC.Connection);
+                                myCmd.ExecuteNonQuery();
+                                myCmd.Dispose();
+                            }
+                          
+                        }
+                    
+                        JavaScript.MessageBox("鍒犻櫎鎴愬姛", this);
+                        //  Response.Redirect("/Pages/business/CorporateClientsUpLoadContract.aspx");
                     }
-                    sqlStr = string.Format(@"USE [ECTEST]DELETE FROM [dbo].[OA_CorporateClientContract] where Keyid='{0}'", keyid);
-                    myCmd = new SqlCommand(sqlStr, DC.Connection);
-                    myCmd.ExecuteNonQuery();
-                    JavaScript.MessageBox("鍒犻櫎鎴愬姛",this);
-                  //  Response.Redirect("/Pages/business/CorporateClientsUpLoadContract.aspx");
-                }
-                catch (Exception ee)
-                {
-                    new Log4NetAdapter().Log("鏌ユ壘鍚堝悓鍑洪敊锛�" + ee.Message);
-                    JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+                    catch (Exception ee)
+                    {
+                        new Log4NetAdapter().Log("鏌ユ壘鍚堝悓鍑洪敊锛�" + ee.Message);
+                        JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+
+                    }
+                    finally
+                    {
+                        if (DC.Connection.State != System.Data.ConnectionState.Closed)
+                            DC.Connection.Close();
+                    }
+
+
 
                 }
-                finally
+                else
                 {
-                    if (DC.Connection.State != System.Data.ConnectionState.Closed)
-                        DC.Connection.Close();
+                    //鍒犻櫎椤甸潰
+                    string keyid = Request["deleteKeyIds"].ToString();
+                    Database DC = new Database();
+                    string sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid]      ,[CorporateClientsid]       ,[CorporateClientsName]       ,[FileName]       ,[PageCode]       ,[FilePath]       ,[Remark]     FROM[dbo].[OA_CorporateClientContract] where Keyid='{0}'ORDER BY PageCode ", keyid);
+
+
+                    try
+                    {
+                        SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
+                        //SqlDataAdapter myDa = new SqlDataAdapter(myCmd);
+                        var a = myCmd.ExecuteReader();
+                        //myDa.Dispose();
+                        fileDataList = new List<OA_CorporateClientsContract>();
+                        OA_CorporateClientsContract Contract;
+                        while (a.Read())
+                        {   //娉ㄦ剰濡備綍灏嗘瘡娆¤鍙栧埌鐨勮褰曟坊鍔犲埌listbox1涓紙鍥犱负绗竴娆″仛鏃跺嚭閿欎簡锛屽樋鍢匡級
+                            Contract = new OA_CorporateClientsContract();
+                            Contract.Keyid = a.GetGuid(0);
+                            Contract.CorporateClientsid = a.GetGuid(1);
+                            Contract.CorporateClientsName = a.GetString(2);
+                            Contract.FileName = a.GetString(3);
+                            Contract.PageCode = a.GetInt32(4);
+                            Contract.FilePath = a.GetString(5);
+                            Contract.Remark = a.GetString(6);
+
+
+                            fileDataList.Add(Contract);
+                        }
+                        a.Close();     //鍏抽棴sqldatareader
+                        if (fileDataList.Count > 0)
+                        {
+                            FileInfo file = new FileInfo(Server.MapPath(fileDataList[0].FilePath));//鎸囧畾鏂囦欢璺緞
+                            if (file.Exists)//鍒ゆ柇鏂囦欢鏄惁瀛樺湪
+                            {
+                                file.Attributes = FileAttributes.Normal;//灏嗘枃浠跺睘鎬ц缃负鏅��,姣旀柟璇村彧璇绘枃浠惰缃负鏅��
+                                file.Delete();//鍒犻櫎鏂囦欢
+                            }
+                        }
+                        sqlStr = string.Format(@"USE [ECTEST]DELETE FROM [dbo].[OA_CorporateClientContract] where Keyid='{0}'", keyid);
+                        myCmd = new SqlCommand(sqlStr, DC.Connection);
+                        myCmd.ExecuteNonQuery();
+                        JavaScript.MessageBox("鍒犻櫎鎴愬姛", this);
+                        //  Response.Redirect("/Pages/business/CorporateClientsUpLoadContract.aspx");
+                    }
+                    catch (Exception ee)
+                    {
+                        new Log4NetAdapter().Log("鏌ユ壘鍚堝悓鍑洪敊锛�" + ee.Message);
+                        JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+
+                    }
+                    finally
+                    {
+                        if (DC.Connection.State != System.Data.ConnectionState.Closed)
+                            DC.Connection.Close();
+                    }
                 }
+
+                Response.AppendHeader("deleteKeyIds", "");
 
             }
+              
             if (!IsPostBack)
                 BindList();
-            
+           
         }
-
+        public Guid GetKeyid()
+        {
+            return Request["Keyid"].ToGuid2();
+        }
         //缁戝畾鍒楄〃
         private void BindList()
         {
@@ -176,15 +254,212 @@
             BindList();
         }
 
+        protected void btn_Submit_Click_multi(object sender, EventArgs e)
+        {
+
+            var files = Request.Files;
+            //if (files.Count <= 0)
+            //    return;
+            HttpPostedFile postedFile;
+            List<HttpPostedFile> fileList = new List<HttpPostedFile>();
+
+
+            for (int i=0;i< files.Count;i++)
+            {
+              
+                if (files.Keys[i]=="file2")
+                {
+                    postedFile = files[i];
+                    if (postedFile.ContentLength == 0)
+                        continue;
+                    fileList.Add(postedFile);
+                }
+                
+            }
+       
+            upLoadContractFile uploadContract = null;
+            OA_CorporateClientsContract contract = null;
+            Guid? g = null;
+            foreach (var item in fileList)
+            {
+
+                int page = 0;
+                try
+                {
+                    page = pagecount(item);
+                }
+                catch (Exception)
+                {
+
+                    continue;
+                }
+                try
+                {
+                    g = GetContractFileID(page);
+                }
+                catch (Exception)
+                {
+
+                    continue;
+                }
+               
+                uploadContract = new upLoadContractFile();
+                if (g != null)
+                {
+
+                    try
+                    {
+                        uploadContract.SavAndUpDataContractFile(item, CountractFileKeiId: g);
+
+                        JavaScript.MessageBox( "涓婁紶鏂囦欢鎴愬姛", this);
+                        //JavaScript.RefreshSelf(this);
+                        //JavaScript.RefreshOpener(this);
+                       
+                    }
+                    catch (Exception)
+                    {
+                        JavaScript.MessageBox("涓婁紶鏂囦欢澶辫触", this);
+                        // JavaScript.RefreshSelf(this);
+                        //JavaScript.RefreshOpener(this);
+                      
+
+                    }
+
+                    continue;
+                }
+
+                //鏂板缓璧颁笅闈㈤〉闈�
+                 contract = new OA_CorporateClientsContract
+                {
+                    CorporateClientsid = Request["Keyid"].ToGuid2(),
+                    FileName = System.IO.Path.GetFileName(item.FileName),
+                    PageCode = page,
+                    Creater = CurrentUser.TrueMemberId,
+
+                };
+
+
+
+                try
+                {
+                    uploadContract.SavAndUpDataContractFile(item, contract);
+
+                    JavaScript.MessageBox("涓婁紶鏂囦欢鎴愬姛", this);
+                   
+                   
+                }
+                catch (Exception)
+                {
+                    JavaScript.MessageBox( "涓婁紶鏂囦欢澶辫触", this);
+                  
+
+                }
+
+
+            }
+            BindList();
+               
+
+
+           
+
+        }
+        protected void btn_Submit_Click_DELLALL(object sender, EventArgs e)
+        {
+
+          
+            string pageID = Request["Keyid"];
+            Database DC = new Database();
+            string sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid]      ,[CorporateClientsid]       ,[CorporateClientsName]       ,[FileName]       ,[PageCode]       ,[FilePath]       ,[Remark]     FROM[dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}'ORDER BY PageCode ", pageID);
+
+
+            try
+            {
+                SqlCommand myCmd = new SqlCommand(sqlStr, DC.Connection);
+                //SqlDataAdapter myDa = new SqlDataAdapter(myCmd);
+                var a = myCmd.ExecuteReader();
+                //myDa.Dispose();
+                fileDataList = new List<OA_CorporateClientsContract>();
+                OA_CorporateClientsContract Contract;
+                while (a.Read())
+                {   //娉ㄦ剰濡備綍灏嗘瘡娆¤鍙栧埌鐨勮褰曟坊鍔犲埌listbox1涓紙鍥犱负绗竴娆″仛鏃跺嚭閿欎簡锛屽樋鍢匡級
+                    Contract = new OA_CorporateClientsContract();
+                    Contract.Keyid = a.GetGuid(0);
+                    Contract.CorporateClientsid = a.GetGuid(1);
+                    Contract.CorporateClientsName = a.GetString(2);
+                    Contract.FileName = a.GetString(3);
+                    Contract.PageCode = a.GetInt32(4);
+                    Contract.FilePath = a.GetString(5);
+                    Contract.Remark = a.GetString(6);
+
+
+                    fileDataList.Add(Contract);
+                }
+                a.Close();     //鍏抽棴sqldatareader
+                if (fileDataList.Count > 0)
+                {
+                    foreach (var item in fileDataList)
+                    {
+                        FileInfo file = new FileInfo(Server.MapPath(item.FilePath));//鎸囧畾鏂囦欢璺緞
+                        if (file.Exists)//鍒ゆ柇鏂囦欢鏄惁瀛樺湪
+                        {
+                            file.Attributes = FileAttributes.Normal;//灏嗘枃浠跺睘鎬ц缃负鏅��,姣旀柟璇村彧璇绘枃浠惰缃负鏅��
+                            file.Delete();//鍒犻櫎鏂囦欢
+                        }
+                        sqlStr = string.Format(@"USE [ECTEST]DELETE FROM [dbo].[OA_CorporateClientContract] where Keyid='{0}'", item.Keyid);
+                        myCmd = new SqlCommand(sqlStr, DC.Connection);
+                        myCmd.ExecuteNonQuery();
+                        myCmd.Dispose();
+                    }
+
+                }
+
+                JavaScript.MessageBox("鍒犻櫎鎴愬姛", this);
+                //  Response.Redirect("/Pages/business/CorporateClientsUpLoadContract.aspx");
+            }
+            catch (Exception ee)
+            {
+                new Log4NetAdapter().Log("鏌ユ壘鍚堝悓鍑洪敊锛�" + ee.Message);
+                JavaScript.MessageBox("鍒犻櫎澶辫触", this);
+
+            }
+            finally
+            {
+                if (DC.Connection.State != System.Data.ConnectionState.Closed)
+                    DC.Connection.Close();
+            }
+
+            BindList();
+        }
         protected void btn_Submit_Click(object sender, EventArgs e)
         {
-        
+
             var files = Request.Files;
             if (files.Count <= 0)
                 return;
-            HttpPostedFile postedFile = files[0];           
-            if (postedFile.ContentLength == 0)
-                return;
+            //    return;
+            HttpPostedFile postedFile=null;
+         
+
+
+            for (int i = 0; i < files.Count; i++)
+            {
+
+                if (files.Keys[i] == "filesel")
+                {
+                    postedFile = files[i];
+                    if (postedFile.ContentLength == 0)
+                    {
+                        return;
+                    }
+                       
+                    break;
+                }
+
+            }
+       
+            
+
             Guid? g = GetContractFileID();
             upLoadContractFile uploadContract = new upLoadContractFile();
             if (g != null)
@@ -206,6 +481,7 @@
                     BindList();
 
                 }
+              
                 return;
             }
           
@@ -238,7 +514,7 @@
                 BindList();
 
             }
-            
+        
 
             //    CY.WebForm.cs.UploadCS.Upload(System.Web.HttpContext.Current.Request.MapPath("contractImgs/") + Guid.NewGuid().ToString() + fileName)
 
@@ -266,6 +542,7 @@
 
             //    }
             //}
+
         }
 
         public void  test()
@@ -274,14 +551,42 @@
         }
         
         /// <summary>
-        /// 鑾峰彇褰撳墠椤甸潰鐨刧uiid锛屽垽鏂槸鍚︽椂鏂板缓椤甸潰
+        /// 鑾峰彇褰撳墠椤甸潰鐨刧uiid锛屽垽鏂槸鍚︽槸鏂板缓椤甸潰  濡傛灉娌℃湁锛屽垯鑾峰彇椤甸潰鐨勯〉鐮�
         /// </summary>
         /// <returns></returns>
-        public Guid? GetContractFileID()
+        public Guid? GetContractFileID(int?  Pagecode=null)
         {
             Guid Keyid = Request["Keyid"].ToGuid2();
             Database DC = new Database();
-            string sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid] FROM[dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}' and [PageCode]='{1}' ", Keyid, Convert.ToInt32(this.TextPage.Value));
+            if (Pagecode != null)
+            {
+                try
+                {
+                    Pagecode = Convert.ToInt32(Pagecode);
+                }
+                catch (Exception)
+                {
+
+                    return null;
+                }
+            }
+            else
+            {
+                try
+                {
+                    Pagecode = Convert.ToInt32(this.TextPage.Value);
+                }
+                catch (Exception)
+                {
+
+                    return null;
+                }
+             
+            }
+             
+                   
+                    
+            string sqlStr = string.Format(@"USE [ECTEST] SELECT[Keyid] FROM[dbo].[OA_CorporateClientContract] where CorporateClientsid='{0}' and [PageCode]='{1}' ", Keyid, Pagecode);
 
             try
             {
@@ -315,6 +620,25 @@
 
         }
 
+        public int pagecount(HttpPostedFile file)
+        {
+            try
+            {
+                string filepagecode = System.IO.Path.GetFileNameWithoutExtension(file.FileName);
+                return Convert.ToInt32(filepagecode);
+
+            }
+            catch (Exception)
+            {
+
+                JavaScript.MessageBox(file.FileName + "鏂囦欢涓婁紶澶辫触锛屽懡鍚嶈鍒欏啿绐�", this);
+                throw;
+            }
+           
+
+        }
+
+
 
 
     }
diff --git a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.designer.cs b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.designer.cs
index 64771a7..76f81c2 100644
--- a/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.designer.cs
+++ b/CY_ECommercePlatform/CY.WebForm/Pages/business/CorporateClientsUpLoadContract.aspx.designer.cs
@@ -69,6 +69,24 @@
         protected global::System.Web.UI.WebControls.Button UpdateFileNew;
 
         /// <summary>
+        /// file2 鎺т欢銆�
+        /// </summary>
+        /// <remarks>
+        /// 鑷姩鐢熸垚鐨勫瓧娈点��
+        /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+        /// </remarks>
+        protected global::System.Web.UI.HtmlControls.HtmlInputFile file2;
+
+        /// <summary>
+        /// Button1 鎺т欢銆�
+        /// </summary>
+        /// <remarks>
+        /// 鑷姩鐢熸垚鐨勫瓧娈点��
+        /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+        /// </remarks>
+        protected global::System.Web.UI.WebControls.Button Button1;
+
+        /// <summary>
         /// RepClientList 鎺т欢銆�
         /// </summary>
         /// <remarks>
@@ -85,5 +103,14 @@
         /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
         /// </remarks>
         protected global::CY.WebForm.Pages.common.UCPager UCPager1;
+
+        /// <summary>
+        /// Button3 鎺т欢銆�
+        /// </summary>
+        /// <remarks>
+        /// 鑷姩鐢熸垚鐨勫瓧娈点��
+        /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+        /// </remarks>
+        protected global::System.Web.UI.WebControls.Button Button3;
     }
 }
diff --git a/CY_ECommercePlatform/CY.WebForm/js/PictureShow/spotlight.bundle.js b/CY_ECommercePlatform/CY.WebForm/js/PictureShow/spotlight.bundle.js
new file mode 100644
index 0000000..e1878a9
--- /dev/null
+++ b/CY_ECommercePlatform/CY.WebForm/js/PictureShow/spotlight.bundle.js
@@ -0,0 +1,31 @@
+/**
+ * Spotlight.js v0.5.9 (Bundle)
+ * Copyright 2019 Nextapps GmbH
+ * Author: Thomas Wilkerling
+ * Licence: Apache-2.0
+ * https://github.com/nextapps-de/spotlight
+ */
+(function(){'use strict';var aa={};function ba(a){for(var b=a.classList,c={},d=0;d<b.length;d++)c[b[d]]=1;a.a=c;a.c=b}function e(a,b){a=g(a);var c="string"===typeof b;if(a.length)for(var d=0;d<a.length;d++)(c?ca:da)(a[d],b);else(c?ca:da)(a,b)}function da(a,b){for(var c=0;c<b.length;c++)ca(a,b[c])}function ca(a,b){a.a||ba(a);a.a[b]||(a.a[b]=1,a.c.add(b))}function h(a,b){a=g(a);var c="string"===typeof b;if(a.length)for(var d=0;d<a.length;d++)(c?ea:fa)(a[d],b);else(c?ea:fa)(a,b)}
+function fa(a,b){for(var c=0;c<b.length;c++)ea(a,b[c])}function ea(a,b){a.a||ba(a);a.a[b]&&(a.a[b]=0,a.c.remove(b))}function k(a,b,c){a=g(a);var d="string"!==typeof b&&Object.keys(b);if(a.length)for(var f=0;f<a.length;f++)(d?ha:ia)(a[f],b,d||c,void 0);else(d?ha:ia)(a,b,d||c,void 0)}function ha(a,b,c,d){for(var f=0;f<c.length;f++){var p=c[f];ia(a,p,b[p],d)}}
+function ia(a,b,c,d){var f=a.f;f||(a.f=f={});f[b]!==c&&(f[b]=c,(a.g||(a.g=a.style)).setProperty(aa[b]||(aa[b]=b.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()),c,d?"important":null))}var ja=0;function l(a,b,c){k(a,"transition","none");k(a,b,c);ja||(ja=a.clientTop&&0);k(a,"transition","")}function ka(a,b){b||(b="");a=g(a);if(a.length)for(var c=0;c<a.length;c++){var d=a[c],f=b;d.b!==f&&(d.b=f,d.textContent=f)}else a.b!==b&&(a.b=b,a.textContent=b)}
+function g(a){return"string"===typeof a?document.querySelectorAll(a):a}function m(a,b){return(b||document).getElementsByClassName(a)};function la(a,b,c,d){ma("add",a,b,c,d)}function na(a,b,c,d){ma("remove",a,b,c,d)}function ma(a,b,c,d,f){b[a+"EventListener"](c||"click",d,"undefined"===typeof f?!0:f)}function n(a,b){a||(a=window.event);a&&(b||a.preventDefault(),a.stopImmediatePropagation(),a.returnValue=!1);return!1};var oa=document.createElement("style");oa.innerHTML="@keyframes pulsate{0%,to{opacity:1}50%{opacity:.2}}#spotlight,#spotlight .drag,#spotlight .preloader,#spotlight .scene{top:0;width:100%;height:100%}#spotlight .arrow,#spotlight .icon{cursor:pointer;background-repeat:no-repeat}#spotlight{position:fixed;z-index:99999;color:#fff;background-color:#000;visibility:hidden;opacity:0;overflow:hidden;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;transition:visibility .25s ease,opacity .25s ease;font-family:Helvetica,Arial,sans-serif;font-size:16px;font-weight:400;contain:layout size paint style;touch-action:none;-webkit-tap-highlight-color:transparent}#spotlight.show{opacity:1;visibility:visible;transition:none}#spotlight.show .pane,#spotlight.show .scene{will-change:transform}#spotlight.show .scene img{will-change:transform,opacity}#spotlight .preloader{position:absolute;background-position:center center;background-repeat:no-repeat;background-size:42px 42px;visibility:hidden}#spotlight .preloader.show{transition:visibility 0s linear .25s;visibility:visible}#spotlight .drag{position:absolute}#spotlight .scene{position:absolute;transition:transform 1s cubic-bezier(.1,1,.1,1);contain:layout size style;pointer-events:none}#spotlight .scene img{display:inline-block;position:absolute;width:auto;height:auto;max-width:100%;max-height:100%;left:50%;top:50%;opacity:1;margin:0;padding:0;border:0;transform:translate(-50%,-50%) scale(1) perspective(100vw);transition:transform 1s cubic-bezier(.1,1,.1,1),opacity 1s cubic-bezier(.3,1,.3,1);transform-style:preserve-3d;contain:layout paint style;visibility:hidden}#spotlight .header,#spotlight .pane{position:absolute;top:0;width:100%;height:100%;contain:layout size style}#spotlight .header{height:50px;text-align:right;background-color:rgba(0,0,0,.45);transform:translateY(-100px);transition:transform .35s ease-out;contain:layout size paint style}#spotlight .header:hover,#spotlight.menu .header{transform:translateY(0)}#spotlight .header div{display:inline-block;vertical-align:middle;white-space:nowrap;width:30px;height:50px;padding-right:20px;opacity:.5}#spotlight .progress{position:absolute;top:0;width:100%;height:3px;background-color:rgba(255,255,255,.45);transform:translateX(-100%);transition:transform 1s linear}#spotlight .arrow,#spotlight .footer{position:absolute;background-color:rgba(0,0,0,.45)}#spotlight .footer{bottom:0;line-height:1.35em;padding:20px 25px;text-align:left;pointer-events:none;contain:layout paint style}#spotlight .footer .title{font-size:125%;padding-bottom:10px}#spotlight .page{float:left;width:auto;padding-left:20px;line-height:50px}#spotlight .icon{background-position:left center;background-size:21px 21px;transition:opacity .2s ease-out}#spotlight .fullscreen{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyLjUiIHZpZXdCb3g9Ii0xIC0xIDI2IDI2IiB3aWR0aD0iMjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTggM0g1YTIgMiAwIDAgMC0yIDJ2M20xOCAwVjVhMiAyIDAgMCAwLTItMmgtM20wIDE4aDNhMiAyIDAgMCAwIDItMnYtM00zIDE2djNhMiAyIDAgMCAwIDIgMmgzIi8+PC9zdmc+)}#spotlight .fullscreen.on{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyLjUiIHZpZXdCb3g9IjAgMCAyNCAyNCIgd2lkdGg9IjI0IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik04IDN2M2EyIDIgMCAwIDEtMiAySDNtMTggMGgtM2EyIDIgMCAwIDEtMi0yVjNtMCAxOHYtM2EyIDIgMCAwIDEgMi0yaDNNMyAxNmgzYTIgMiAwIDAgMSAyIDJ2MyIvPjwvc3ZnPg==)}#spotlight .autofit{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBoZWlnaHQ9Ijk2cHgiIHZpZXdCb3g9IjAgMCA5NiA5NiIgd2lkdGg9Ijk2cHgiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggdHJhbnNmb3JtPSJyb3RhdGUoOTAgNTAgNTApIiBmaWxsPSIjZmZmIiBkPSJNNzEuMzExLDgwQzY5LjY3LDg0LjY2LDY1LjIzLDg4LDYwLDg4SDIwYy02LjYzLDAtMTItNS4zNy0xMi0xMlYzNmMwLTUuMjMsMy4zNC05LjY3LDgtMTEuMzExVjc2YzAsMi4yMSwxLjc5LDQsNCw0SDcxLjMxMSAgeiIvPjxwYXRoIHRyYW5zZm9ybT0icm90YXRlKDkwIDUwIDUwKSIgZmlsbD0iI2ZmZiIgZD0iTTc2LDhIMzZjLTYuNjMsMC0xMiw1LjM3LTEyLDEydjQwYzAsNi42Myw1LjM3LDEyLDEyLDEyaDQwYzYuNjMsMCwxMi01LjM3LDEyLTEyVjIwQzg4LDEzLjM3LDgyLjYzLDgsNzYsOHogTTgwLDYwICBjMCwyLjIxLTEuNzksNC00LDRIMzZjLTIuMjEsMC00LTEuNzktNC00VjIwYzAtMi4yMSwxLjc5LTQsNC00aDQwYzIuMjEsMCw0LDEuNzksNCw0VjYweiIvPjwvc3ZnPg==)}#spotlight .zoom-out{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48Y2lyY2xlIGN4PSIxMSIgY3k9IjExIiByPSI4Ii8+PGxpbmUgeDE9IjIxIiB4Mj0iMTYuNjUiIHkxPSIyMSIgeTI9IjE2LjY1Ii8+PGxpbmUgeDE9IjgiIHgyPSIxNCIgeTE9IjExIiB5Mj0iMTEiLz48L3N2Zz4=)}#spotlight .zoom-in{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48Y2lyY2xlIGN4PSIxMSIgY3k9IjExIiByPSI4Ii8+PGxpbmUgeDE9IjIxIiB4Mj0iMTYuNjUiIHkxPSIyMSIgeTI9IjE2LjY1Ii8+PGxpbmUgeDE9IjExIiB4Mj0iMTEiIHkxPSI4IiB5Mj0iMTQiLz48bGluZSB4MT0iOCIgeDI9IjE0IiB5MT0iMTEiIHkyPSIxMSIvPjwvc3ZnPg==)}#spotlight .theme{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBoZWlnaHQ9IjI0cHgiIHZlcnNpb249IjEuMiIgdmlld0JveD0iMiAyIDIwIDIwIiB3aWR0aD0iMjRweCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjZmZmIj48cGF0aCBkPSJNMTIsNGMtNC40MTgsMC04LDMuNTgyLTgsOHMzLjU4Miw4LDgsOHM4LTMuNTgyLDgtOFMxNi40MTgsNCwxMiw0eiBNMTIsMThjLTMuMzE0LDAtNi0yLjY4Ni02LTZzMi42ODYtNiw2LTZzNiwyLjY4Niw2LDYgUzE1LjMxNCwxOCwxMiwxOHoiLz48cGF0aCBkPSJNMTIsN3YxMGMyLjc1NywwLDUtMi4yNDMsNS01UzE0Ljc1Nyw3LDEyLDd6Ii8+PC9nPjwvc3ZnPg==)}#spotlight .player{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSItMC41IC0wLjUgMjUgMjUiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48Y2lyY2xlIGN4PSIxMiIgY3k9IjEyIiByPSIxMCIvPjxwb2x5Z29uIGZpbGw9IiNmZmYiIHBvaW50cz0iMTAgOCAxNiAxMiAxMCAxNiAxMCA4Ii8+PC9zdmc+)}#spotlight .player.on{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSItMC41IC0wLjUgMjUgMjUiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48Y2lyY2xlIGN4PSIxMiIgY3k9IjEyIiByPSIxMCIvPjxsaW5lIHgxPSIxMCIgeDI9IjEwIiB5MT0iMTUiIHkyPSI5Ii8+PGxpbmUgeDE9IjE0IiB4Mj0iMTQiIHkxPSIxNSIgeTI9IjkiLz48L3N2Zz4=);animation:pulsate 1s ease infinite}#spotlight .close{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSIyIDIgMjAgMjAiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48bGluZSB4MT0iMTgiIHgyPSI2IiB5MT0iNiIgeTI9IjE4Ii8+PGxpbmUgeDE9IjYiIHgyPSIxOCIgeTE9IjYiIHkyPSIxOCIvPjwvc3ZnPg==)}#spotlight .preloader{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzgiIGhlaWdodD0iMzgiIHZpZXdCb3g9IjAgMCAzOCAzOCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiBzdHJva2U9IiNmZmYiPjxnIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+PGcgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMSAxKSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2Utb3BhY2l0eT0iLjY1Ij48Y2lyY2xlIHN0cm9rZS1vcGFjaXR5PSIuMTUiIGN4PSIxOCIgY3k9IjE4IiByPSIxOCIvPjxwYXRoIGQ9Ik0zNiAxOGMwLTkuOTQtOC4wNi0xOC0xOC0xOCI+PGFuaW1hdGVUcmFuc2Zvcm0gYXR0cmlidXRlTmFtZT0idHJhbnNmb3JtIiB0eXBlPSJyb3RhdGUiIGZyb209IjAgMTggMTgiIHRvPSIzNjAgMTggMTgiIGR1cj0iMXMiIHJlcGVhdENvdW50PSJpbmRlZmluaXRlIi8+PC9wYXRoPjwvZz48L2c+PC9zdmc+)}#spotlight .arrow{top:50%;left:20px;width:50px;height:50px;border-radius:100%;margin-top:-25px;padding:10px;transform:translateX(-100px);transition:transform .35s ease-out,opacity .2s ease-out;box-sizing:border-box;background-position:center center;background-size:30px 30px;opacity:.65;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIj8+PHN2ZyBmaWxsPSJub25lIiBoZWlnaHQ9IjI0IiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHdpZHRoPSIyNCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cG9seWxpbmUgcG9pbnRzPSIxNSAxOCA5IDEyIDE1IDYiLz48L3N2Zz4=)}#spotlight .arrow-right{left:auto;right:20px;transform:translateX(100px) scaleX(-1)}#spotlight.menu .arrow-left{transform:translateX(0)}#spotlight.menu .arrow-right{transform:translateX(0) scaleX(-1)}#spotlight .arrow-left:hover,#spotlight .arrow-right:hover,#spotlight .icon:hover{opacity:1;animation:none}#spotlight.white{color:#fff;background-color:#fff}#spotlight.white .arrow,#spotlight.white .footer,#spotlight.white .header,#spotlight.white .preloader,#spotlight.white .progress{filter:invert(1)}.hide-scrollbars{overflow:-moz-hidden-unscrollable;-ms-overflow-style:none}.hide-scrollbars::-webkit-scrollbar{width:0}@media (max-width:800px){#spotlight .header div{width:20px}#spotlight .footer{font-size:12px}#spotlight .arrow{width:35px;height:35px;margin-top:-17.5px;background-size:15px 15px}#spotlight .preloader{background-size:30px 30px}}@media (max-width:400px),(max-height:400px){#spotlight .fullscreen{display:none!important}}";
+document.getElementsByTagName("head")[0].appendChild(oa);var q="theme fullscreen autofit zoom-in zoom-out page title description player progress".split(" "),r,t,pa,qa,x,y,z,A,B,C,D,E,F,G,H,ra,I,J,K,L,sa,ta,M,N,O,P,Q,ua,va,wa,xa,ya,R,za,Aa,Ba,Ca,S,Da,T,V,W,Ea;function Fa(a,b,c){this.src=a;this.title=b;this.description=c}
+function Ga(a,b){if(J=a.length){O||(O=m("pane",Q));var c=O.length,d=K.title,f=K.description;W=Array(J);for(var p=0;p<J;p++){var u=a[p],v=u.dataset;if(p>=c){var w=O[0].cloneNode(!1);k(w,"left",100*p+"%");O[0].parentNode.appendChild(w)}w=void 0;W[p]=new Fa(v&&(v.href||v.src)||u.src||u.href,v&&v.title||u.title||(w=(u||document).getElementsByTagName("img")).length&&w[0].alt||d||"",v&&v.description||u.description||f||"")}I=b||1;l(M,"transform","translateX(-"+100*(I-1)+"%)");Ha()}}
+function Ia(a,b,c,d){if(d||a[c])K[c]=b&&b[c]||d}
+function Ja(a,b){K={};b&&Ka(b);Ka(a);Ia(a,b,"description");Ia(a,b,"title");Ia(a,b,"prefetch",!0);Ia(a,b,"preloader",!0);L=K.infinite;L="undefined"!==typeof L&&"false"!==L;sa="false"!==K.progress;ta=1*K.player||7E3;if((a=K.zoom)||""===a)K["zoom-in"]=K["zoom-out"]=a,delete K.zoom;if((a=K.control)||""===a){a="string"===typeof a?a.split(","):a;for(b=0;b<q.length;b++)K[q[b]]="false";for(b=0;b<a.length;b++){var c=a[b].trim();"zoom"===c?K["zoom-in"]=K["zoom-out"]="true":K[c]="true"}}for(a=0;a<q.length;a++)b=
+q[a],k(m(b,Q)[0],"display","false"===K[b]?"none":"");(ra=K.theme)?La():ra="white"}function Ka(a){for(var b=K,c=Object.keys(a),d=0;d<c.length;d++){var f=c[d];b[f]=""+a[f]}}
+function Ma(){var a=I;N=O[a-1];P=N.firstElementChild;I=a;if(!P){var b="false"!==K.preloader;P=new Image;P.onload=function(){b&&h(Ca,"show");W&&(z=this.width,A=this.height,k(this,{visibility:"visible",opacity:1,transform:""}),"false"!==K.prefetch&&a<J&&((new Image).src=W[a].src))};P.onerror=function(){N.removeChild(this)};N.appendChild(P);P.src=W[a-1].src;b&&e(Ca,"show");return!b}return!0}la(document,"",Na);
+la(document,"DOMContentLoaded",function(){Q=document.createElement("div");Q.id="spotlight";Q.innerHTML='<div class=drag></div><div class=preloader></div><div class=scene><div class=pane></div></div><div class=header><div class=page></div><div class="icon fullscreen"></div><div class="icon autofit"></div><div class="icon zoom-out"></div><div class="icon zoom-in"></div><div class="icon theme"></div><div class="icon player"></div><div class="icon close"></div></div><div class=progress></div><div class="arrow arrow-left"></div><div class="arrow arrow-right"></div><div class=footer><div class=title></div><div class=description></div></div>';
+k(Q,"transition","none");document.body.appendChild(Q);M=m("scene",Q)[0];ua=m("footer",Q)[0];va=m("title",ua)[0];wa=m("description",ua)[0];xa=m("arrow-left",Q)[0];ya=m("arrow-right",Q)[0];R=m("fullscreen",Q)[0];za=m("page",Q)[0];Aa=m("player",Q)[0];Ba=m("progress",Q)[0];Ca=m("preloader",Q)[0];V=document.documentElement||document.body;document.cancelFullScreen||(document.cancelFullScreen=document.exitFullscreen||document.webkitCancelFullScreen||document.webkitExitFullscreen||document.mozCancelFullScreen||
+function(){});V.requestFullScreen||(V.requestFullScreen=V.webkitRequestFullScreen||V.msRequestFullScreen||V.mozRequestFullScreen||k(R,"display","none")||function(){});var a=m("drag",Q)[0];Ea=[[window,"keydown",Oa],[window,"wheel",Pa],[window,"hashchange",Qa],[window,"resize",Ra],[a,"mousedown",Sa],[a,"mouseleave",Ta],[a,"mouseup",Ta],[a,"mousemove",Ua],[a,"touchstart",Sa,{passive:!1}],[a,"touchcancel",Ta],[a,"touchend",Ta],[a,"touchmove",Ua,{passive:!0}],[R,"",Va],[xa,"",Wa],[ya,"",X],[Aa,"",Xa],
+[m("autofit",Q)[0],"",Ya],[m("zoom-in",Q)[0],"",Za],[m("zoom-out",Q)[0],"",$a],[m("close",Q)[0],"",ab],[m("theme",Q)[0],"",La]]},{once:!0});function Ra(){x=Q.clientWidth;y=Q.clientHeight;P&&(z=P.width,A=P.height,bb())}function bb(){k(P,"transform","translate(-50%, -50%) scale("+B+")")}function cb(a){for(var b=0;b<Ea.length;b++){var c=Ea[b];(a?la:na)(c[0],c[1],c[2],c[3])}}
+function Na(a){var b=db.call(a.target,".spotlight");if(b){var c=db.call(b,".spotlight-group"),d=m("spotlight",c);Ja(b.dataset,c&&c.dataset);for(c=0;c<d.length;c++)if(d[c]===b){Ga(d,c+1);break}eb();return n(a)}}function Oa(a){if(N)switch(a.keyCode){case 8:Ya();break;case 27:ab();break;case 32:"false"!==K.player&&Xa();break;case 37:Wa();break;case 39:X();break;case 38:case 107:case 187:Za();break;case 40:case 109:case 189:$a()}}function Pa(a){N&&(a=a.deltaY,0>.5*(0>a?1:a?-1:0)?$a():Za())}
+function Qa(){N&&"#spotlight"===location.hash&&ab(!0)}function Xa(a){("boolean"===typeof a?a:!S)?S||(S=setInterval(X,ta),e(Aa,"on"),sa&&fb()):S&&(S=clearInterval(S),h(Aa,"on"),sa&&l(Ba,"transform",""));return S}function Y(){T?clearTimeout(T):e(Q,"menu");var a=K.autohide;T="false"!==a?setTimeout(function(){h(Q,"menu");T=null},1*a||3E3):1}function gb(a){"boolean"===typeof a&&(T=a?T:0);T?(T=clearTimeout(T),h(Q,"menu")):Y();return n(a)}
+function Sa(a){C=!0;D=!1;var b=hb(a);E=z*B<=x;pa=b.x;qa=b.y;return n(a,!0)}function Ta(a){if(C&&!D)return C=!1,gb(a);E&&D&&(l(M,"transform","translateX("+-(100*(I-1)-r/x*100)+"%)"),r<-(y/10)&&X()||r>y/10&&Wa()||k(M,"transform","translateX(-"+100*(I-1)+"%)"),r=0,E=!1,k(N,"transform",""));C=!1;return n(a)}
+function Ua(a){if(C){Da||(Da=requestAnimationFrame(ib));var b=hb(a),c=(z*B-x)/2;D=!0;r-=pa-(pa=b.x);E?F=!0:r>c?r=c:0<x-r-z*B+c?r=x-z*B+c:F=!0;A*B>y&&(c=(A*B-y)/2,t-=qa-(qa=b.y),t>c?t=c:0<y-t-A*B+c?t=y-A*B+c:F=!0)}else Y();return n(a,!0)}function hb(a){var b=a.touches;b&&(b=b[0]);return{x:b?b.clientX:a.pageX,y:b?b.clientY:a.pageY}}function ib(a){F?(a&&(Da=requestAnimationFrame(ib)),k(N,"transform","translate("+r+"px, "+t+"px)")):Da=null;F=!1}
+function Va(a){("boolean"===typeof a?a:document.isFullScreen||document.webkitIsFullScreen||document.mozFullScreen)?(document.cancelFullScreen(),h(R,"on")):(V.requestFullScreen(),e(R,"on"))}function Ya(a){"boolean"===typeof a&&(G=!a);G=1===B&&!G;k(P,{maxHeight:G?"none":"",maxWidth:G?"none":"",transform:""});z=P.width;A=P.height;B=1;t=r=0;F=!0;ib();Y()}function Za(a){var b=B/.65;5>=b&&jb(B=b);a||Y()}function jb(a){B=a||1;bb()}function $a(a){var b=.65*B;1<=b&&(jb(B=b),t=r=0,F=!0,ib());a||Y()}
+function eb(){location.hash="spotlight";location.hash="show";k(Q,"transition","");e(V,"hide-scrollbars");e(Q,"show");cb(!0);Ra();Y()}function ab(a){cb(!1);history.go(!0===a?-1:-2);h(V,"hide-scrollbars");h(Q,"show");S&&Xa(!1);P.parentNode.removeChild(P);N=P=W=null}function Wa(){if(1<I)return Z(I-1);if(S||L)return Z(J)}function X(){if(I<J)return Z(I+1);if(S||L)return Z(1)}function Z(a){if(!(S&&C||a===I)){S||Y();S&&sa&&fb();var b=a>I;I=a;Ha(b);return!0}}
+function fb(){l(Ba,{transitionDuration:"",transform:""});k(Ba,{transitionDuration:ta+"ms",transform:"translateX(0)"})}function La(a){"boolean"===typeof a?H=a:(H=!H,Y());H?e(Q,ra):h(Q,ra)}
+function Ha(a){t=r=0;B=1;var b=K.animation,c=!0,d=!0,f=!0;if(b||""===b){c=d=f=!1;b="string"===typeof b?b.split(","):b;for(var p=0;p<b.length;p++){var u=b[p].trim();if("scale"===u)c=!0;else if("fade"===u)d=!0;else if("slide"===u)f=!0;else if("flip"===u)var v=!0;else if("false"!==u){c=d=f=v=!1;var w=u;break}}}k(M,{transition:f?"":"none",transform:"translateX(-"+100*(I-1)+"%)"});N&&k(N,"transform","");if(P){k(P,{opacity:d?0:1,transform:""});var U=P;setTimeout(function(){U&&P!==U&&U.parentNode&&U.parentNode.removeChild(U)},
+800)}f=Ma();w&&e(P,w);l(P,{opacity:d?0:1,transform:"translate(-50%, -50%)"+(c?" scale(0.8)":"")+(v&&"undefined"!==typeof a?" rotateY("+(a?"":"-")+"90deg)":""),maxHeight:"",maxWidth:""});f&&k(P,{visibility:"visible",opacity:1,transform:""});w&&h(P,w);k(N,"transform","");k(xa,"visibility",L||1!==I?"":"hidden");k(ya,"visibility",L||I!==J?"":"hidden");a=W[I-1];if(c=a.title||a.description)ka(va,a.title),ka(wa,a.description);k(ua,"visibility",c?"visible":"hidden");ka(za,I+" / "+J)}
+var db=Element.prototype.closest||function(a){var b=this;for(a=a.substring(1);b&&1===b.nodeType;){if(b.classList.contains(a))return b;b=b.parentElement||b.parentNode}};window.Spotlight={theme:La,fullscreen:Va,autofit:Ya,next:X,prev:Wa,"goto":Z,close:ab,zoom:jb,menu:gb,show:function(a,b){setTimeout(function(){a?(b?Ja(b):b={},Ga(a,b.index)):K={};eb()})},play:Xa};}).call(this);

--
Gitblit v1.9.1