Browse Source

首页数据修改,报表,坐席工作报表,appp管理,

duhongyu 6 years ago
parent
commit
ef2e8a94a8
21 changed files with 1352 additions and 186 deletions
  1. 16 32
      IVR_Auto.xml
  2. 106 0
      IVR_Auto.xml.bak
  3. 1 0
      codegit/CallCenterApi/CallCenterApi.BLL/CallCenterApi.BLL.csproj
  4. 140 0
      codegit/CallCenterApi/CallCenterApi.BLL/T_Sys_ApplicationsVersion.cs
  5. 1 0
      codegit/CallCenterApi/CallCenterApi.DAL/CallCenterApi.DAL.csproj
  6. 383 0
      codegit/CallCenterApi/CallCenterApi.DAL/T_Sys_ApplicationsVersion.cs
  7. 2 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/CallCenterApi.Interface.csproj
  8. 261 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/ApplicationsVersionController.cs
  9. 1 0
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/CallOutOptController.cs
  10. 1 1
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/EquipmentNumberController.cs
  11. 119 72
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/IndexController.cs
  12. 4 2
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/report/BusinessController.cs
  13. 26 30
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/report/ZuoXiWorkTotalController.cs
  14. 4 4
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/tel/CallrecordsController.cs
  15. 119 7
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkOrderController.cs
  16. 6 4
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkorderAppController.cs
  17. 1 1
      codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/WorkOrderInput.cs
  18. 1 0
      codegit/CallCenterApi/CallCenterApi.Model/CallCenterApi.Model.csproj
  19. 144 0
      codegit/CallCenterApi/CallCenterApi.Model/T_Sys_ApplicationsVersion.cs
  20. 0 1
      codegit/CallCenterCommon/CallCenter.Utility/NPOI/NPOIHelper.cs
  21. 16 32
      ivr/IVR_Auto.xml

+ 16 - 32
IVR_Auto.xml

@@ -13,13 +13,13 @@
13 13
 			groupcode:坐席组编号
14 14
 			插入通话记录示例:exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,1,'','KFZ' 
15 15
 		-->
16
-		<cell Name="CELL_BRANCH" Pos="2" Var="CalleeID" DefaultPos="2" Note="首次分支分支节点">
17
-			<Branch Value="8001" Pos="201" /><!--客服组正常流程:黑名单-节假日-坐席排队-->
18
-			<Branch Value="6800" Pos="202" /><!--市场组直接转坐席-->
16
+		<!--<cell Name="CELL_BRANCH" Pos="2" Var="CalleeID" DefaultPos="2" Note="首次分支分支节点"> -->
17
+			<!--<Branch Value="8001" Pos="201" />--><!--客服组正常流程:黑名单-节假日-坐席排队-->
18
+			<!--<Branch Value="6800" Pos="202" />--><!--市场组直接转坐席-->
19 19
 		</cell>
20
-		<cell Name="CELL_SQL" Pos="201" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','KFZ' " 
20
+		<cell Name="CELL_SQL" Pos="201" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','KFZ' " 
21 21
 		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-客服组" />
22
-		<cell Name="CELL_SQL" Pos="202" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','SCZ' " 
22
+		<cell Name="CELL_SQL" Pos="202" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','SCZ' " 
23 23
 		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-市场组" />
24 24
 		<cell Name="CELL_DEFINEVAR" Pos="3" Next="4" Note="定义变量节点">
25 25
 			<DefVar VarType="1" VarName="AgentNo" VarVal="0" />
@@ -31,12 +31,9 @@
31 31
 			<DefVar VarType="1" VarName="HolidayVerify" VarVal="0" />
32 32
 			<DefVar VarType="1" VarName="zbdh" VarVal="0" />
33 33
 		</cell>
34
-		<cell Name="CELL_BRANCH" Pos="4" Var="CalleeID" DefaultPos="1010" Note="流程不同分支节点">
35
-			<Branch Value="8001" Pos="104" /><!--客服组正常流程:黑名单-节假日-坐席排队-->
36
-			<Branch Value="6800" Pos="603" /><!--市场组直接转坐席--> 
37
-		</cell>
34
+		
38 35
 		<!--黑名单-->
39
-		<cell Name="CELL_SQL" Pos="104" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetBlacklist  '%[CallerID]','%[CallID]' " IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
36
+		<cell Name="CELL_SQL" Pos="4" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_GetBlacklist  '%[CallerID]','%[CallID]' " IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
40 37
 		<cell Name="CELL_RECORDSET" Pos="5" LPos="6" EPos="6" GPos="6" Note="取黑名单结果">
41 38
 			<Map Var="BlackListVerify" />
42 39
 		</cell>
@@ -48,28 +45,28 @@
48 45
 		<!--黑名单-->
49 46
 		
50 47
 		<!--欢迎词-->
51
-		<!-- <cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="D:\Midware\wav\欢迎词.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50"  TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" /> -->
48
+		<cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="E:\VS2019_Bin\Middle_shanghui\wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50"  TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" /> 
52 49
 		<!--欢迎词-->
53 50
 		
54 51
 		<!--节假日-->
55 52
 		<!--判断是否加班或节假日,是放节假日音后挂机,否转坐席-->
56
-		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetHolidays" IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
53
+		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_GetHolidays" IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
57 54
 		<cell Name="CELL_RECORDSET" Pos="9" LPos="10" EPos="10" GPos="10" Note="取节假日结果">
58 55
 			<Map Var="HolidayVerify" />
59 56
 		</cell>
60
-		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603" FalsePos="29" Note="判断节假日" />
57
+		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603"  Note="判断节假日" />
61 58
 		<cell Name="CELL_AUDIODTMF" Pos="11" PlayType="2" ContentType="1" Content="D:\Midware\wav\假期提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音" />
62 59
 		<!--节假日-->
63 60
 		
64 61
 		
65 62
 		<!--排队,转坐席-->
66
-		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetSeatGroup '%[CallerID]','%[CalleeID]'" 
63
+		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_GetSeatGroup '%[CallerID]','%[CalleeID]'" 
67 64
 		IsSaved="yes" SuccessPos="604" FailPos="24" Note="获取坐席组ID" />
68 65
 		<cell Name="CELL_RECORDSET" Pos="604" LPos="501" EPos="501" GPos="501" Note="获取坐席组ID结果">
69 66
 			<Map Var="GroupID" />
70 67
 		</cell>
71 68
 		
72
-		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',3,%[KeyGroup],'0','','' " IsSaved="no" SuccessPos="13" FailPos="13" Note="更新排队开始时间" />
69
+		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',3,%[KeyGroup],'0','','' " IsSaved="no" SuccessPos="13" FailPos="13" Note="更新排队开始时间" />
73 70
 		<!--坐席排队时,没有登录坐席直接转值班电话,无空闲坐席转坐席全忙放音,有空闲坐席继续播报-->
74 71
 		<!--Strategy:座席分配策略,1循环接听、2最大空闲接听、3最少接听接听、4指定坐席接听,指定多座席时,坐席工号之间用‘|’分隔,坐席数不要超过4个。-->
75 72
 		<cell Name="CELL_BRANCH" Pos="13" Var="CalleeID" DefaultPos="1013" Note="排队分支节点">
@@ -78,9 +75,9 @@
78 75
 		</cell>
79 76
 		
80 77
 		<cell Name="CELL_QUEUE" Pos="1013" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
81
-		NoAgentPos="29" NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点" />
78
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点" />
82 79
 		<cell Name="CELL_QUEUE" Pos="1014" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
83
-		NoAgentPos="29" NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点-sc" />
80
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点-sc" />
84 81
 		<cell Name="CELL_AUDIODTMF" Pos="1015" PlayType="2" ContentType="1" Content="D:\Midware\wav\嘟嘟无人接听.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音-sc" />
85 82
 		
86 83
 		<cell Name="CELL_AUDIODTMF" Pos="14" PlayType="1" ContentType="1" Content="D:\Midware\wav\坐席全忙.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
@@ -97,23 +94,10 @@
97 94
 		  <BandData Var="CallID" />
98 95
 		</cell>
99 96
 		<!--排队,转坐席-->
100
-				
101
-		<!--转值班电话-->
102
-		<cell Name="CELL_AUDIODTMF" Pos="29" PlayType="2" ContentType="1" Content="D:\Midware\wav\转值班电话提示.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="701" FailPos="24" HangupPos="24" Note="转值班电话提示音" />
103
-		<cell Name="CELL_BRANCH" Pos="701" Var="CalleeID" DefaultPos="1013" Note="排队分支节点">
104
-			<Branch Value="8001" Pos="7011" /><!--客服组-->
105
-			<Branch Value="6800" Pos="7012" /><!--市场组-->
106
-		</cell>
107
-		<cell Name="CELL_SQL" Pos="7011" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="EXEC P_GetZBDH '%[CallID]',0 " IsSaved="yes" SuccessPos="702" FailPos="24" Note="获取值班电话-客服组" />
108
-		<cell Name="CELL_SQL" Pos="7012" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="EXEC P_GetZBDH '%[CallID]',1 " IsSaved="yes" SuccessPos="702" FailPos="24" Note="获取值班电话-市场组" />
109
-		<cell Name="CELL_RECORDSET" Pos="702" LPos="30" EPos="30" GPos="30" Note="获取值班电话结果">
110
-			<Map Var="zbdh" />
111
-		</cell>
112
-		<cell Name="CELL_TRANSFEROUT" Pos="30" CalleeNumType="2" CalleeNum="zbdh" Timeout="60" SuccessPos="25" FailPos="24" Note="转值班电话" />
113
-		<!--转值班电话-->
97
+		
114 98
 		
115 99
 		<!---->
116
-		<cell Name="CELL_SQL" Pos="24" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',2,0,'0','','' " IsSaved="no" 
100
+		<cell Name="CELL_SQL" Pos="24" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',2,0,'0','','' " IsSaved="no" 
117 101
 		SuccessPos="204" FailPos="25" Note="更新挂机时间" />
118 102
 		<cell Name="CELL_HANGUP" Pos="204" Next="25" Note="挂机节点" />
119 103
 		<cell Name="CELL_END" Pos="25" Note="结束节点" />	

+ 106 - 0
IVR_Auto.xml.bak

@@ -0,0 +1,106 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<ivr>
3
+	<flow Name="IVR_Auto" Type="normal" MatchedNum="." MatchedLine="|-1|" Concurrency="1">
4
+		<cell Name="CELL_START" Pos="1" Next="2" Note="开始节点" />
5
+		<!--
6
+			exec P_OptCallRecords 'tel','callid',type,bustype,mydkey,'recfile'
7
+			tel:来电号码%[CallerID]
8
+			callid:中间件定义%[CallID]
9
+			typD:执行类型:1.插入通话记录;2.更新挂机时间;3.更新排队开始时间;4.插入留言;5.更新满意度
10
+			bustypD:业务选择,用于需要有按键选择业务按键值
11
+			mydkey:满意度按键值,1满意,2一般,3不满意
12
+			recfilD:留言的录音文件:%[CallID]_%[CallerID]_%[StartTime].wav
13
+			groupcode:坐席组编号
14
+			插入通话记录示例:exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,1,'','KFZ' 
15
+		-->
16
+		<!--<cell Name="CELL_BRANCH" Pos="2" Var="CalleeID" DefaultPos="2" Note="首次分支分支节点"> -->
17
+			<!--<Branch Value="8001" Pos="201" />--><!--客服组正常流程:黑名单-节假日-坐席排队-->
18
+			<!--<Branch Value="6800" Pos="202" />--><!--市场组直接转坐席-->
19
+		</cell>
20
+		<cell Name="CELL_SQL" Pos="201" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','KFZ' " 
21
+		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-客服组" />
22
+		<cell Name="CELL_SQL" Pos="202" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','SCZ' " 
23
+		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-市场组" />
24
+		<cell Name="CELL_DEFINEVAR" Pos="3" Next="4" Note="定义变量节点">
25
+			<DefVar VarType="1" VarName="AgentNo" VarVal="0" />
26
+			<DefVar VarType="1" VarName="AgentExtNo" VarVal="0" />
27
+			<DefVar VarType="1" VarName="KeyGroup" VarVal="0" /><!--坐席组按键值-->
28
+			<DefVar VarType="1" VarName="GroupID" VarVal="0" /><!--通过坐席组按键值 获取相应的坐席组ID-->
29
+			<DefVar VarType="1" VarName="Key" VarVal="0" />
30
+			<DefVar VarType="1" VarName="BlackListVerify" VarVal="0" />
31
+			<DefVar VarType="1" VarName="HolidayVerify" VarVal="0" />
32
+			<DefVar VarType="1" VarName="zbdh" VarVal="0" />
33
+		</cell>
34
+		
35
+		<!--黑名单-->
36
+		<cell Name="CELL_SQL" Pos="4" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetBlacklist  '%[CallerID]','%[CallID]' " IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
37
+		<cell Name="CELL_RECORDSET" Pos="5" LPos="6" EPos="6" GPos="6" Note="取黑名单结果">
38
+			<Map Var="BlackListVerify" />
39
+		</cell>
40
+		<cell Name="CELL_COMPARE" Pos="6" Data1Type="2" Data2Type="1" Data3Type="1" Data1="BlackListVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="26" FalsePos="8" Note="判断黑名单" />
41
+		<!--黑名单提示音-->
42
+		<cell Name="CELL_AUDIODTMF" Pos="26" PlayType="2" ContentType="1" Content="D:\Midware\wav\黑名单提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
43
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="25" FailPos="24" HangupPos="24" Note="黑名单提示音" />
44
+		<!--黑名单提示音-->
45
+		<!--黑名单-->
46
+		
47
+		<!--欢迎词-->
48
+		<cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="D:\Midware\wav\欢迎词.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50"  TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" /> 
49
+		<!--欢迎词-->
50
+		
51
+		<!--节假日-->
52
+		<!--判断是否加班或节假日,是放节假日音后挂机,否转坐席-->
53
+		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetHolidays" IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
54
+		<cell Name="CELL_RECORDSET" Pos="9" LPos="10" EPos="10" GPos="10" Note="取节假日结果">
55
+			<Map Var="HolidayVerify" />
56
+		</cell>
57
+		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603"  Note="判断节假日" />
58
+		<cell Name="CELL_AUDIODTMF" Pos="11" PlayType="2" ContentType="1" Content="D:\Midware\wav\假期提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音" />
59
+		<!--节假日-->
60
+		
61
+		
62
+		<!--排队,转坐席-->
63
+		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetSeatGroup '%[CallerID]','%[CalleeID]'" 
64
+		IsSaved="yes" SuccessPos="604" FailPos="24" Note="获取坐席组ID" />
65
+		<cell Name="CELL_RECORDSET" Pos="604" LPos="501" EPos="501" GPos="501" Note="获取坐席组ID结果">
66
+			<Map Var="GroupID" />
67
+		</cell>
68
+		
69
+		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',3,%[KeyGroup],'0','','' " IsSaved="no" SuccessPos="13" FailPos="13" Note="更新排队开始时间" />
70
+		<!--坐席排队时,没有登录坐席直接转值班电话,无空闲坐席转坐席全忙放音,有空闲坐席继续播报-->
71
+		<!--Strategy:座席分配策略,1循环接听、2最大空闲接听、3最少接听接听、4指定坐席接听,指定多座席时,坐席工号之间用‘|’分隔,坐席数不要超过4个。-->
72
+		<cell Name="CELL_BRANCH" Pos="13" Var="CalleeID" DefaultPos="1013" Note="排队分支节点">
73
+			<Branch Value="8001" Pos="1013" /><!--客服组-->
74
+			<Branch Value="6800" Pos="1014" /><!--市场组-->
75
+		</cell>
76
+		
77
+		<cell Name="CELL_QUEUE" Pos="1013" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
78
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点" />
79
+		<cell Name="CELL_QUEUE" Pos="1014" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
80
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点-sc" />
81
+		<cell Name="CELL_AUDIODTMF" Pos="1015" PlayType="2" ContentType="1" Content="D:\Midware\wav\嘟嘟无人接听.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音-sc" />
82
+		
83
+		<cell Name="CELL_AUDIODTMF" Pos="14" PlayType="1" ContentType="1" Content="D:\Midware\wav\坐席全忙.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
84
+		TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="Key" SuccessPos="15" FailPos="24" HangupPos="24" Note="坐席全忙放音" />
85
+		<cell Name="CELL_BRANCH" Pos="15" Var="Key" DefaultPos="14" Note="分支节点">
86
+			<Branch Value="1" Pos="16" /><!--1.继续等待-->
87
+		</cell>		
88
+		<cell Name="CELL_CONTINUEQUEUE" Pos="16" Agent="AgentNo" Exten="AgentExtNo" Audio="D:\Midware\wav\保持音.wav" Timeout="60" SuccessPos="18" HangupPos="24" TimeoutPos="14" Note="继续排队节点" />
89
+		<cell Name="CELL_CANCELQUEUE" Pos="17" Reason="等烦了" Next="24" Note="放弃排队节点" />		
90
+		<cell Name="CELL_AUDIODTMF" Pos="18" PlayType="2" ContentType="1" Content="D:\Midware\wav\通话录音提示音.wav" TTSNumMode="1" 
91
+		TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="31" FailPos="24" HangupPos="24" Note="转接电话提示录音" />
92
+		<cell Name="CELL_AUDIODTMF" Pos="31" PlayType="2" ContentType="2" Content=" `vs40 您好, `dig`vs30 %[AgentNo] `vs50 号客服为您服务." TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="19" FailPos="24" HangupPos="24" Note="播报工号" />
93
+		<cell Name="CELL_TURNAGENT" Pos="19" Exten="AgentExtNo" SuccessPos="25" FailPos="17" HangupPos="24" Note="转座席节点">
94
+		  <BandData Var="CallID" />
95
+		</cell>
96
+		<!--排队,转坐席-->
97
+		
98
+		
99
+		<!---->
100
+		<cell Name="CELL_SQL" Pos="24" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',2,0,'0','','' " IsSaved="no" 
101
+		SuccessPos="204" FailPos="25" Note="更新挂机时间" />
102
+		<cell Name="CELL_HANGUP" Pos="204" Next="25" Note="挂机节点" />
103
+		<cell Name="CELL_END" Pos="25" Note="结束节点" />	
104
+		<!---->
105
+	</flow>		
106
+</ivr>

+ 1 - 0
codegit/CallCenterApi/CallCenterApi.BLL/CallCenterApi.BLL.csproj

@@ -83,6 +83,7 @@
83 83
     <Compile Include="T_SMS_SentSMS.cs" />
84 84
     <Compile Include="T_SMS_Template.cs" />
85 85
     <Compile Include="T_Sys_Accessories.cs" />
86
+    <Compile Include="T_Sys_ApplicationsVersion.cs" />
86 87
     <Compile Include="T_Sys_Area.cs" />
87 88
     <Compile Include="T_Sys_Department.cs" />
88 89
     <Compile Include="T_Sys_DictionaryBase.cs" />

+ 140 - 0
codegit/CallCenterApi/CallCenterApi.BLL/T_Sys_ApplicationsVersion.cs

@@ -0,0 +1,140 @@
1
+using System;
2
+using System.Collections.Generic;
3
+using System.Data;
4
+
5
+namespace CallCenterApi.BLL
6
+{
7
+    /// <summary>
8
+    /// T_Sys_ApplicationsVersion
9
+    /// </summary>
10
+    public partial class T_Sys_ApplicationsVersion
11
+    {
12
+        private readonly DAL.T_Sys_ApplicationsVersion dal = new DAL.T_Sys_ApplicationsVersion();
13
+        public T_Sys_ApplicationsVersion()
14
+        { }
15
+        #region  BasicMethod
16
+
17
+        /// <summary>
18
+        /// 增加一条数据
19
+        /// </summary>
20
+        public int Add(Model.T_Sys_ApplicationsVersion model)
21
+        {
22
+            return dal.Add(model);
23
+        }
24
+
25
+        /// <summary>
26
+        /// 更新一条数据
27
+        /// </summary>
28
+        public bool Update(Model.T_Sys_ApplicationsVersion model)
29
+        {
30
+            return dal.Update(model);
31
+        }
32
+
33
+        /// <summary>
34
+        /// 删除一条数据
35
+        /// </summary>
36
+        public bool Delete(int F_ID)
37
+        {
38
+
39
+            return dal.Delete(F_ID);
40
+        }
41
+        /// <summary>
42
+        /// 删除一条数据
43
+        /// </summary>
44
+        public bool DeleteList(string F_IDlist)
45
+        {
46
+            return dal.DeleteList(F_IDlist);
47
+        }
48
+
49
+        /// <summary>
50
+        /// 得到一个对象实体
51
+        /// </summary>
52
+        public Model.T_Sys_ApplicationsVersion GetModel(int F_ID)
53
+        {
54
+
55
+            return dal.GetModel(F_ID);
56
+        }
57
+
58
+  
59
+
60
+        /// <summary>
61
+        /// 获得数据列表
62
+        /// </summary>
63
+        public DataSet GetList(string strWhere)
64
+        {
65
+            return dal.GetList(strWhere);
66
+        }
67
+        /// <summary>
68
+        /// 获得前几行数据
69
+        /// </summary>
70
+        public DataSet GetList(int Top, string strWhere, string filedOrder)
71
+        {
72
+            return dal.GetList(Top, strWhere, filedOrder);
73
+        }
74
+        /// <summary>
75
+        /// 获得数据列表
76
+        /// </summary>
77
+        public List<Model.T_Sys_ApplicationsVersion> GetModelList(string strWhere)
78
+        {
79
+            DataSet ds = dal.GetList(strWhere);
80
+            return DataTableToList(ds.Tables[0]);
81
+        }
82
+        /// <summary>
83
+        /// 获得数据列表
84
+        /// </summary>
85
+        public List<Model.T_Sys_ApplicationsVersion> DataTableToList(DataTable dt)
86
+        {
87
+            List<Model.T_Sys_ApplicationsVersion> modelList = new List<Model.T_Sys_ApplicationsVersion>();
88
+            int rowsCount = dt.Rows.Count;
89
+            if (rowsCount > 0)
90
+            {
91
+                Model.T_Sys_ApplicationsVersion model;
92
+                for (int n = 0; n < rowsCount; n++)
93
+                {
94
+                    model = dal.DataRowToModel(dt.Rows[n]);
95
+                    if (model != null)
96
+                    {
97
+                        modelList.Add(model);
98
+                    }
99
+                }
100
+            }
101
+            return modelList;
102
+        }
103
+
104
+        /// <summary>
105
+        /// 获得数据列表
106
+        /// </summary>
107
+        public DataSet GetAllList()
108
+        {
109
+            return GetList("");
110
+        }
111
+
112
+        /// <summary>
113
+        /// 分页获取数据列表
114
+        /// </summary>
115
+        public int GetRecordCount(string strWhere)
116
+        {
117
+            return dal.GetRecordCount(strWhere);
118
+        }
119
+        /// <summary>
120
+        /// 分页获取数据列表
121
+        /// </summary>
122
+        public DataSet GetListByPage(string strWhere, string orderby, int startIndex, int endIndex)
123
+        {
124
+            return dal.GetListByPage(strWhere, orderby, startIndex, endIndex);
125
+        }
126
+        /// <summary>
127
+        /// 分页获取数据列表
128
+        /// </summary>
129
+        //public DataSet GetList(int PageSize,int PageIndex,string strWhere)
130
+        //{
131
+        //return dal.GetList(PageSize,PageIndex,strWhere);
132
+        //}
133
+
134
+        #endregion  BasicMethod
135
+        #region  ExtensionMethod
136
+
137
+        #endregion  ExtensionMethod
138
+    }
139
+}
140
+

+ 1 - 0
codegit/CallCenterApi/CallCenterApi.DAL/CallCenterApi.DAL.csproj

@@ -83,6 +83,7 @@
83 83
     <Compile Include="T_SMS_SentSMS.cs" />
84 84
     <Compile Include="T_SMS_Template.cs" />
85 85
     <Compile Include="T_Sys_Accessories.cs" />
86
+    <Compile Include="T_Sys_ApplicationsVersion.cs" />
86 87
     <Compile Include="T_Sys_Area.cs" />
87 88
     <Compile Include="T_Sys_Department.cs" />
88 89
     <Compile Include="T_Sys_DictionaryBase.cs" />

+ 383 - 0
codegit/CallCenterApi/CallCenterApi.DAL/T_Sys_ApplicationsVersion.cs

@@ -0,0 +1,383 @@
1
+using System;
2
+using System.Data;
3
+using System.Text;
4
+using System.Data.SqlClient;
5
+using CallCenterApi.DB;
6
+namespace CallCenterApi.DAL
7
+{
8
+    /// <summary>
9
+    /// 数据访问类:T_Sys_ApplicationsVersion
10
+    /// </summary>
11
+    public partial class T_Sys_ApplicationsVersion
12
+    {
13
+        public T_Sys_ApplicationsVersion()
14
+        { }
15
+        #region  BasicMethod
16
+
17
+
18
+
19
+        /// <summary>
20
+        /// 增加一条数据
21
+        /// </summary>
22
+        public int Add(Model.T_Sys_ApplicationsVersion model)
23
+        {
24
+            StringBuilder strSql = new StringBuilder();
25
+            strSql.Append("insert into T_Sys_ApplicationsVersion(");
26
+            strSql.Append("F_Type,F_VersionName,F_VersionCode,F_Files,F_Url,F_CreateUser,F_CreateTime,F_UpdateUser,F_UpdateTime,F_IsDelete,F_DeleteTime,F_Sort,F_Remarks)");
27
+            strSql.Append(" values (");
28
+            strSql.Append("@F_Type,@F_VersionName,@F_VersionCode,@F_Files,@F_Url,@F_CreateUser,@F_CreateTime,@F_UpdateUser,@F_UpdateTime,@F_IsDelete,@F_DeleteTime,@F_Sort,@F_Remarks)");
29
+            strSql.Append(";select @@IDENTITY");
30
+            SqlParameter[] parameters = {
31
+                    new SqlParameter("@F_Type", SqlDbType.BigInt,8),
32
+                    new SqlParameter("@F_VersionName", SqlDbType.NVarChar,50),
33
+                    new SqlParameter("@F_VersionCode", SqlDbType.NVarChar,50),
34
+                    new SqlParameter("@F_Files", SqlDbType.NVarChar,50),
35
+                    new SqlParameter("@F_Url", SqlDbType.NVarChar,50),
36
+                    new SqlParameter("@F_CreateUser", SqlDbType.NVarChar,50),
37
+                    new SqlParameter("@F_CreateTime", SqlDbType.DateTime),
38
+                    new SqlParameter("@F_UpdateUser", SqlDbType.NVarChar,50),
39
+                    new SqlParameter("@F_UpdateTime", SqlDbType.DateTime),
40
+                    new SqlParameter("@F_IsDelete", SqlDbType.Int,4),
41
+                    new SqlParameter("@F_DeleteTime", SqlDbType.DateTime),
42
+                    new SqlParameter("@F_Sort", SqlDbType.Int,4),
43
+                    new SqlParameter("@F_Remarks", SqlDbType.NVarChar,50)};
44
+            parameters[0].Value = model.F_Type;
45
+            parameters[1].Value = model.F_VersionName;
46
+            parameters[2].Value = model.F_VersionCode;
47
+            parameters[3].Value = model.F_Files;
48
+            parameters[4].Value = model.F_Url;
49
+            parameters[5].Value = model.F_CreateUser;
50
+            parameters[6].Value = model.F_CreateTime;
51
+            parameters[7].Value = model.F_UpdateUser;
52
+            parameters[8].Value = model.F_UpdateTime;
53
+            parameters[9].Value = model.F_IsDelete;
54
+            parameters[10].Value = model.F_DeleteTime;
55
+            parameters[11].Value = model.F_Sort;
56
+            parameters[12].Value = model.F_Remarks;
57
+
58
+            object obj = DbHelperSQL.GetSingle(strSql.ToString(), parameters);
59
+            if (obj == null)
60
+            {
61
+                return 0;
62
+            }
63
+            else
64
+            {
65
+                return Convert.ToInt32(obj);
66
+            }
67
+        }
68
+        /// <summary>
69
+        /// 更新一条数据
70
+        /// </summary>
71
+        public bool Update(Model.T_Sys_ApplicationsVersion model)
72
+        {
73
+            StringBuilder strSql = new StringBuilder();
74
+            strSql.Append("update T_Sys_ApplicationsVersion set ");
75
+            strSql.Append("F_Type=@F_Type,");
76
+            strSql.Append("F_VersionName=@F_VersionName,");
77
+            strSql.Append("F_VersionCode=@F_VersionCode,");
78
+            strSql.Append("F_Files=@F_Files,");
79
+            strSql.Append("F_Url=@F_Url,");
80
+            strSql.Append("F_CreateUser=@F_CreateUser,");
81
+            strSql.Append("F_CreateTime=@F_CreateTime,");
82
+            strSql.Append("F_UpdateUser=@F_UpdateUser,");
83
+            strSql.Append("F_UpdateTime=@F_UpdateTime,");
84
+            strSql.Append("F_IsDelete=@F_IsDelete,");
85
+            strSql.Append("F_DeleteTime=@F_DeleteTime,");
86
+            strSql.Append("F_Sort=@F_Sort,");
87
+            strSql.Append("F_Remarks=@F_Remarks");
88
+            strSql.Append(" where F_ID=@F_ID");
89
+            SqlParameter[] parameters = {
90
+                    new SqlParameter("@F_Type", SqlDbType.BigInt,8),
91
+                    new SqlParameter("@F_VersionName", SqlDbType.NVarChar,50),
92
+                    new SqlParameter("@F_VersionCode", SqlDbType.NVarChar,50),
93
+                    new SqlParameter("@F_Files", SqlDbType.NVarChar,50),
94
+                    new SqlParameter("@F_Url", SqlDbType.NVarChar,50),
95
+                    new SqlParameter("@F_CreateUser", SqlDbType.NVarChar,50),
96
+                    new SqlParameter("@F_CreateTime", SqlDbType.DateTime),
97
+                    new SqlParameter("@F_UpdateUser", SqlDbType.NVarChar,50),
98
+                    new SqlParameter("@F_UpdateTime", SqlDbType.DateTime),
99
+                    new SqlParameter("@F_IsDelete", SqlDbType.Int,4),
100
+                    new SqlParameter("@F_DeleteTime", SqlDbType.DateTime),
101
+                    new SqlParameter("@F_Sort", SqlDbType.Int,4),
102
+                    new SqlParameter("@F_Remarks", SqlDbType.NVarChar,50),
103
+                    new SqlParameter("@F_ID", SqlDbType.Int,4)};
104
+            parameters[0].Value = model.F_Type;
105
+            parameters[1].Value = model.F_VersionName;
106
+            parameters[2].Value = model.F_VersionCode;
107
+            parameters[3].Value = model.F_Files;
108
+            parameters[4].Value = model.F_Url;
109
+            parameters[5].Value = model.F_CreateUser;
110
+            parameters[6].Value = model.F_CreateTime;
111
+            parameters[7].Value = model.F_UpdateUser;
112
+            parameters[8].Value = model.F_UpdateTime;
113
+            parameters[9].Value = model.F_IsDelete;
114
+            parameters[10].Value = model.F_DeleteTime;
115
+            parameters[11].Value = model.F_Sort;
116
+            parameters[12].Value = model.F_Remarks;
117
+            parameters[13].Value = model.F_ID;
118
+
119
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
120
+            if (rows > 0)
121
+            {
122
+                return true;
123
+            }
124
+            else
125
+            {
126
+                return false;
127
+            }
128
+        }
129
+
130
+        /// <summary>
131
+        /// 删除一条数据
132
+        /// </summary>
133
+        public bool Delete(int F_ID)
134
+        {
135
+
136
+            StringBuilder strSql = new StringBuilder();
137
+            strSql.Append("delete from T_Sys_ApplicationsVersion ");
138
+            strSql.Append(" where F_ID=@F_ID");
139
+            SqlParameter[] parameters = {
140
+                    new SqlParameter("@F_ID", SqlDbType.Int,4)
141
+            };
142
+            parameters[0].Value = F_ID;
143
+
144
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString(), parameters);
145
+            if (rows > 0)
146
+            {
147
+                return true;
148
+            }
149
+            else
150
+            {
151
+                return false;
152
+            }
153
+        }
154
+        /// <summary>
155
+        /// 批量删除数据
156
+        /// </summary>
157
+        public bool DeleteList(string F_IDlist)
158
+        {
159
+            StringBuilder strSql = new StringBuilder();
160
+            strSql.Append("UPDATE  T_Sys_ApplicationsVersion  set F_IsDelete=1");
161
+            strSql.Append(" where F_ID in (" + F_IDlist + ")  ");
162
+            int rows = DbHelperSQL.ExecuteSql(strSql.ToString());
163
+            if (rows > 0)
164
+            {
165
+                return true;
166
+            }
167
+            else
168
+            {
169
+                return false;
170
+            }
171
+        }
172
+
173
+
174
+        /// <summary>
175
+        /// 得到一个对象实体
176
+        /// </summary>
177
+        public Model.T_Sys_ApplicationsVersion GetModel(int F_ID)
178
+        {
179
+
180
+            StringBuilder strSql = new StringBuilder();
181
+            strSql.Append("select  top 1 F_ID,F_Type,F_VersionName,F_VersionCode,F_Files,F_Url,F_CreateUser,F_CreateTime,F_UpdateUser,F_UpdateTime,F_IsDelete,F_DeleteTime,F_Sort,F_Remarks from T_Sys_ApplicationsVersion ");
182
+            strSql.Append(" where F_ID=@F_ID");
183
+            SqlParameter[] parameters = {
184
+                    new SqlParameter("@F_ID", SqlDbType.Int,4)
185
+            };
186
+            parameters[0].Value = F_ID;
187
+
188
+            Model.T_Sys_ApplicationsVersion model = new Model.T_Sys_ApplicationsVersion();
189
+            DataSet ds = DbHelperSQL.Query(strSql.ToString(), parameters);
190
+            if (ds.Tables[0].Rows.Count > 0)
191
+            {
192
+                return DataRowToModel(ds.Tables[0].Rows[0]);
193
+            }
194
+            else
195
+            {
196
+                return null;
197
+            }
198
+        }
199
+
200
+
201
+        /// <summary>
202
+        /// 得到一个对象实体
203
+        /// </summary>
204
+        public Model.T_Sys_ApplicationsVersion DataRowToModel(DataRow row)
205
+        {
206
+            Model.T_Sys_ApplicationsVersion model = new Model.T_Sys_ApplicationsVersion();
207
+            if (row != null)
208
+            {
209
+                if (row["F_ID"] != null && row["F_ID"].ToString() != "")
210
+                {
211
+                    model.F_ID = int.Parse(row["F_ID"].ToString());
212
+                }
213
+                if (row["F_Type"] != null && row["F_Type"].ToString() != "")
214
+                {
215
+                    model.F_Type = long.Parse(row["F_Type"].ToString());
216
+                }
217
+                if (row["F_VersionName"] != null)
218
+                {
219
+                    model.F_VersionName = row["F_VersionName"].ToString();
220
+                }
221
+                if (row["F_VersionCode"] != null)
222
+                {
223
+                    model.F_VersionCode = row["F_VersionCode"].ToString();
224
+                }
225
+                if (row["F_Files"] != null)
226
+                {
227
+                    model.F_Files = row["F_Files"].ToString();
228
+                }
229
+                if (row["F_Url"] != null)
230
+                {
231
+                    model.F_Url = row["F_Url"].ToString();
232
+                }
233
+                if (row["F_CreateUser"] != null)
234
+                {
235
+                    model.F_CreateUser = row["F_CreateUser"].ToString();
236
+                }
237
+                if (row["F_CreateTime"] != null && row["F_CreateTime"].ToString() != "")
238
+                {
239
+                    model.F_CreateTime = DateTime.Parse(row["F_CreateTime"].ToString());
240
+                }
241
+                if (row["F_UpdateUser"] != null)
242
+                {
243
+                    model.F_UpdateUser = row["F_UpdateUser"].ToString();
244
+                }
245
+                if (row["F_UpdateTime"] != null && row["F_UpdateTime"].ToString() != "")
246
+                {
247
+                    model.F_UpdateTime = DateTime.Parse(row["F_UpdateTime"].ToString());
248
+                }
249
+                if (row["F_IsDelete"] != null && row["F_IsDelete"].ToString() != "")
250
+                {
251
+                    model.F_IsDelete = int.Parse(row["F_IsDelete"].ToString());
252
+                }
253
+                if (row["F_DeleteTime"] != null && row["F_DeleteTime"].ToString() != "")
254
+                {
255
+                    model.F_DeleteTime = DateTime.Parse(row["F_DeleteTime"].ToString());
256
+                }
257
+                if (row["F_Sort"] != null && row["F_Sort"].ToString() != "")
258
+                {
259
+                    model.F_Sort = int.Parse(row["F_Sort"].ToString());
260
+                }
261
+                if (row["F_Remarks"] != null)
262
+                {
263
+                    model.F_Remarks = row["F_Remarks"].ToString();
264
+                }
265
+            }
266
+            return model;
267
+        }
268
+
269
+        /// <summary>
270
+        /// 获得数据列表
271
+        /// </summary>
272
+        public DataSet GetList(string strWhere)
273
+        {
274
+            StringBuilder strSql = new StringBuilder();
275
+            strSql.Append("select F_ID,F_Type,F_VersionName,F_VersionCode,F_Files,F_Url,F_CreateUser,F_CreateTime,F_UpdateUser,F_UpdateTime,F_IsDelete,F_DeleteTime,F_Sort,F_Remarks ");
276
+            strSql.Append(" FROM T_Sys_ApplicationsVersion ");
277
+            if (strWhere.Trim() != "")
278
+            {
279
+                strSql.Append(" where " + strWhere);
280
+            }
281
+            return DbHelperSQL.Query(strSql.ToString());
282
+        }
283
+
284
+        /// <summary>
285
+        /// 获得前几行数据
286
+        /// </summary>
287
+        public DataSet GetList(int Top, string strWhere, string filedOrder)
288
+        {
289
+            StringBuilder strSql = new StringBuilder();
290
+            strSql.Append("select ");
291
+            if (Top > 0)
292
+            {
293
+                strSql.Append(" top " + Top.ToString());
294
+            }
295
+            strSql.Append(" F_ID,F_Type,F_VersionName,F_VersionCode,F_Files,F_Url,F_CreateUser,F_CreateTime,F_UpdateUser,F_UpdateTime,F_IsDelete,F_DeleteTime,F_Sort,F_Remarks ");
296
+            strSql.Append(" FROM T_Sys_ApplicationsVersion ");
297
+            if (strWhere.Trim() != "")
298
+            {
299
+                strSql.Append(" where " + strWhere);
300
+            }
301
+            strSql.Append(" order by " + filedOrder);
302
+            return DbHelperSQL.Query(strSql.ToString());
303
+        }
304
+
305
+        /// <summary>
306
+        /// 获取记录总数
307
+        /// </summary>
308
+        public int GetRecordCount(string strWhere)
309
+        {
310
+            StringBuilder strSql = new StringBuilder();
311
+            strSql.Append("select count(1) FROM T_Sys_ApplicationsVersion ");
312
+            if (strWhere.Trim() != "")
313
+            {
314
+                strSql.Append(" where " + strWhere);
315
+            }
316
+            object obj = DbHelperSQL.GetSingle(strSql.ToString());
317
+            if (obj == null)
318
+            {
319
+                return 0;
320
+            }
321
+            else
322
+            {
323
+                return Convert.ToInt32(obj);
324
+            }
325
+        }
326
+        /// <summary>
327
+        /// 分页获取数据列表
328
+        /// </summary>
329
+        public DataSet GetListByPage(string strWhere, string orderby, int startIndex, int endIndex)
330
+        {
331
+            StringBuilder strSql = new StringBuilder();
332
+            strSql.Append("SELECT * FROM ( ");
333
+            strSql.Append(" SELECT ROW_NUMBER() OVER (");
334
+            if (!string.IsNullOrEmpty(orderby.Trim()))
335
+            {
336
+                strSql.Append("order by T." + orderby);
337
+            }
338
+            else
339
+            {
340
+                strSql.Append("order by T.F_ID desc");
341
+            }
342
+            strSql.Append(")AS Row, T.*  from T_Sys_ApplicationsVersion T ");
343
+            if (!string.IsNullOrEmpty(strWhere.Trim()))
344
+            {
345
+                strSql.Append(" WHERE " + strWhere);
346
+            }
347
+            strSql.Append(" ) TT");
348
+            strSql.AppendFormat(" WHERE TT.Row between {0} and {1}", startIndex, endIndex);
349
+            return DbHelperSQL.Query(strSql.ToString());
350
+        }
351
+
352
+        /*
353
+		/// <summary>
354
+		/// 分页获取数据列表
355
+		/// </summary>
356
+		public DataSet GetList(int PageSize,int PageIndex,string strWhere)
357
+		{
358
+			SqlParameter[] parameters = {
359
+					new SqlParameter("@tblName", SqlDbType.VarChar, 255),
360
+					new SqlParameter("@fldName", SqlDbType.VarChar, 255),
361
+					new SqlParameter("@PageSize", SqlDbType.Int),
362
+					new SqlParameter("@PageIndex", SqlDbType.Int),
363
+					new SqlParameter("@IsReCount", SqlDbType.Bit),
364
+					new SqlParameter("@OrderType", SqlDbType.Bit),
365
+					new SqlParameter("@strWhere", SqlDbType.VarChar,1000),
366
+					};
367
+			parameters[0].Value = "T_Sys_ApplicationsVersion";
368
+			parameters[1].Value = "F_ID";
369
+			parameters[2].Value = PageSize;
370
+			parameters[3].Value = PageIndex;
371
+			parameters[4].Value = 0;
372
+			parameters[5].Value = 0;
373
+			parameters[6].Value = strWhere;	
374
+			return DbHelperSQL.RunProcedure("UP_GetRecordByPage",parameters,"ds");
375
+		}*/
376
+
377
+        #endregion  BasicMethod
378
+        #region  ExtensionMethod
379
+
380
+        #endregion  ExtensionMethod
381
+    }
382
+}
383
+

+ 2 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/CallCenterApi.Interface.csproj

@@ -171,6 +171,7 @@
171 171
     <Compile Include="App_Start\ErrorAttribute.cs" />
172 172
     <Compile Include="App_Start\RouteConfig.cs" />
173 173
     <Compile Include="Controllers\AddressBookController.cs" />
174
+    <Compile Include="Controllers\ApplicationsVersionController.cs" />
174 175
     <Compile Include="Controllers\AreaController.cs" />
175 176
     <Compile Include="Controllers\Base\BaseController.cs" />
176 177
     <Compile Include="Controllers\CallOutOptController.cs" />
@@ -311,6 +312,7 @@
311 312
   <ItemGroup>
312 313
     <Folder Include="App_Data\" />
313 314
     <Folder Include="Views\AddressBook\" />
315
+    <Folder Include="Views\ApplicationsVersion\" />
314 316
     <Folder Include="Views\Area\" />
315 317
     <Folder Include="Views\Base\" />
316 318
     <Folder Include="Views\Business\" />

+ 261 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/ApplicationsVersionController.cs

@@ -0,0 +1,261 @@
1
+using CallCenter.Utility;
2
+using CallCenterApi.DB;
3
+using CallCenterApi.Interface.Controllers.Base;
4
+using System;
5
+using System.Collections.Generic;
6
+using System.Data;
7
+using System.IO;
8
+using System.Linq;
9
+using System.Web;
10
+using System.Web.Mvc;
11
+
12
+namespace CallCenterApi.Interface.Controllers
13
+{
14
+    public class ApplicationsVersionController : BaseController
15
+    {
16
+        private BLL.T_Sys_ApplicationsVersion ApplicationsBLL = new BLL.T_Sys_ApplicationsVersion();
17
+
18
+        public class ApplicationsVersion
19
+        {
20
+            public int F_ID { get; set; }
21
+            public int  F_Type { get; set; }//应用分类(0android 1ios)
22
+            public string  F_VersionName  { get; set; }//版本名称
23
+            public string F_VersionCode { get; set; }//版本号
24
+            public string F_Files { get; set; }//android地址
25
+            public string F_Url { get; set; }//ios链接地址
26
+            public int  F_Sort { get; set; }//F_Sort
27
+            public string F_Remarks { get; set; }//F_Remarks
28
+            public DataTable FileUrl { get; set; }//android链接地址
29
+
30
+        }
31
+        /// <summary>
32
+        /// 添加
33
+        /// </summary>
34
+        /// <param name="input"></param>
35
+        /// <returns></returns>
36
+        [HttpPost]
37
+        public ActionResult Add(ApplicationsVersion input)
38
+        {
39
+            if (Request.IsAuthenticated)
40
+            {
41
+               
42
+                int userId = CurrentUser.UserData.F_UserId;
43
+                Model.T_Sys_UserAccount userModel = new BLL.T_Sys_UserAccount().GetModel(userId);
44
+                Model.T_Sys_ApplicationsVersion dModel = new Model.T_Sys_ApplicationsVersion();
45
+                dModel.F_Type = input.F_Type;
46
+                dModel.F_VersionName = input.F_VersionName;
47
+                dModel.F_VersionCode = input.F_VersionCode;
48
+                dModel.F_Files = input.F_Files;
49
+                dModel.F_Url = input.F_Url;
50
+                dModel.F_Remarks = input.F_Remarks;
51
+                dModel.F_Sort = input.F_Sort;
52
+                dModel.F_CreateTime = DateTime.Now;
53
+                if (userModel != null)
54
+                    dModel.F_CreateUser = userModel.F_UserCode;
55
+                dModel.F_IsDelete = 0;
56
+                if (input.F_ID > 0)
57
+                {
58
+                    dModel.F_ID = input.F_ID;
59
+                    bool  id = ApplicationsBLL.Update (dModel);
60
+                    if (id )
61
+                    {
62
+                        return Success("修改成功");
63
+                    }
64
+                    else
65
+                        return Success("修改失败");
66
+                }
67
+                else
68
+                {
69
+                    int id = ApplicationsBLL.Add(dModel);
70
+                    if (id > 0)
71
+                    {
72
+                        return Success("添加成功");
73
+                    }
74
+                    else
75
+                        return Success("添加失败");
76
+                }
77
+               
78
+            }
79
+            return NoToken("未知错误,请重新登录");
80
+        }
81
+
82
+        /// <summary>
83
+        /// 删除
84
+        /// </summary>
85
+        /// <param name="ids"></param>
86
+        /// <returns></returns>
87
+        public ActionResult DelEquipment(string[] ids)
88
+        {
89
+            if (Request.IsAuthenticated)
90
+            {
91
+                if (ids == null || ids.Length <= 0)
92
+                    return Error("请选择要删除的设备");
93
+
94
+                var idStr = string.Join(",", ids);
95
+                if (string.IsNullOrEmpty(idStr.Trim()))
96
+                    return Error("请选择要删除的设备");
97
+                if (ApplicationsBLL.DeleteList(idStr))
98
+                    return Success("删除成功");
99
+                return Error("删除失败");
100
+            }
101
+            return NoToken("未知错误,请重新登录");
102
+        }
103
+
104
+        /// <summary>
105
+        /// 列表
106
+        /// </summary>
107
+        /// <returns></returns>
108
+        public ActionResult GetList(string keywords, int pageindex = 1, int pagesize = 10)
109
+        {
110
+            DataTable dt = new DataTable();
111
+            string sql = "and F_IsDelete=0";
112
+            if (!string.IsNullOrWhiteSpace(keywords))//关键字搜索
113
+                sql += $"  and ( F_VersionName like '%" + keywords.Trim() + "%'or F_Type like '%" + keywords.Trim() + "%'or F_VersionCode like '%" + keywords.Trim() + "%' ) ";
114
+            int recordCount = 0;
115
+            if (!string.IsNullOrWhiteSpace(sql))
116
+            {
117
+
118
+                dt = BLL.PagerBLL.GetListPager(
119
+                    "T_Sys_ApplicationsVersion",
120
+                    "F_ID",
121
+                    "*",
122
+                    sql,
123
+                    "ORDER BY T_Sys_ApplicationsVersion.F_ID desc,F_Sort asc",
124
+                    pagesize,
125
+                    pageindex,
126
+                    true,
127
+                    out recordCount);
128
+            }
129
+         
130
+            List<Model.T_Sys_ApplicationsVersion> modlelist = new BLL.T_Sys_ApplicationsVersion().DataTableToList(dt);
131
+            if (modlelist.Count > 0)
132
+            {
133
+                var obj = new
134
+                {
135
+                    state = "success",
136
+                    message = "成功",
137
+                    rows = modlelist,
138
+                    total = recordCount
139
+                };
140
+
141
+                return Content(obj.ToJson()); ;
142
+            }
143
+            else
144
+            {
145
+
146
+                return Success("暂无数据"); ;
147
+            }
148
+        }
149
+        public DataTable GetFileData(string ids, string prefix)
150
+        {
151
+            DataTable dt = new DataTable();
152
+            if (!string.IsNullOrEmpty(ids))
153
+            {
154
+                dt = DbHelperSQL.Query("select * from T_Sys_Accessories where F_FileId in (" + ids + ")").Tables[0];
155
+                foreach (DataRow dr in dt.Rows)
156
+                {
157
+                    dr["F_FileUrl"] = prefix + dr["F_FileUrl"].ToString();
158
+                }
159
+            }
160
+            return dt;
161
+        }
162
+        private List <ApplicationsVersion> modeltoip(List<Model.T_Sys_ApplicationsVersion >t_Sys_ApplicationsVersion )
163
+        {
164
+            var configfj = new BLL.T_Sys_SystemConfig().GetModelList(" F_ParamCode='FileUrlPath' ").FirstOrDefault();
165
+            List<ApplicationsVersion> model = new List<ApplicationsVersion>();
166
+
167
+            if (t_Sys_ApplicationsVersion!=null )
168
+            {
169
+                foreach (var it in t_Sys_ApplicationsVersion)
170
+                {
171
+                    ApplicationsVersion app = new ApplicationsVersion();
172
+                    app.F_ID = it.F_ID;
173
+                    app.F_Type =(int ) it.F_Type;
174
+                    app.F_VersionName = it.F_VersionName;
175
+                    app.F_VersionCode = it.F_VersionCode;
176
+                    app.F_Files = it.F_Files;
177
+                    app.F_Url = it.F_Url;
178
+                    app.F_Sort = (int )it.F_Sort;
179
+                    app.F_Remarks = it.F_Remarks;
180
+                    app.FileUrl = GetFileData(it.F_Files, configfj.F_ParamValue);
181
+                }
182
+            }
183
+            return model;
184
+        }
185
+        /// <summary>
186
+        /// 查询设备详情
187
+        /// </summary>
188
+        public ActionResult GetDetails(int id)
189
+        {
190
+            int userId = CurrentUser.UserData.F_UserId;
191
+            if (userId != 0)
192
+            {
193
+                DataTable FileUrl = new DataTable();
194
+                Model.T_Sys_UserAccount ua = new BLL.T_Sys_UserAccount().GetModel(userId);
195
+
196
+                if (id <= 0)
197
+                {
198
+                    return Error("请输入正确的id");
199
+                }
200
+                var model = ApplicationsBLL.GetModel(id);
201
+                if (model == null)
202
+                    return Error("该应用不存在");
203
+                var obj = new
204
+                {
205
+                    state = "success",
206
+                    message = "成功",
207
+                    rows = model,
208
+                };
209
+                return Content(obj.ToJson());
210
+            }
211
+            else
212
+            {
213
+                return Error("无操作权限!");
214
+            }
215
+        }
216
+        /// <summary>
217
+        /// 上传附件
218
+        /// </summary>
219
+        /// <returns></returns>
220
+        public ActionResult UploadFile()
221
+        {
222
+            int userId = CurrentUser.UserData.F_UserId;
223
+            Model.T_Sys_UserAccount userModel = new BLL.T_Sys_UserAccount().GetModel(userId);
224
+
225
+            #region 多个上传
226
+            HttpFileCollection files = RequestString.GetFiles();
227
+            if (files.Count > 0)
228
+            {
229
+                List<Model.T_Sys_Accessories> acs = new List<Model.T_Sys_Accessories>();
230
+                string path = "/Upload/Files/" + DateTime.Now.ToString("yyyy") + "/" + DateTime.Now.ToString("MM") + "/" + DateTime.Now.ToString("dd") + "/";
231
+                for (int i = 0; i < files.Count; i++)
232
+                {
233
+                    HttpPostedFile file = files[i];
234
+                    FileUp fu = new FileUp();
235
+
236
+                    string name = fu.Upload(file, path);
237
+
238
+                    Model.T_Sys_Accessories model_T_Sys_Accessories = new Model.T_Sys_Accessories();
239
+                    model_T_Sys_Accessories.F_CreateTime = DateTime.Now;//上传时间
240
+                    model_T_Sys_Accessories.F_Name = file.FileName;//附件名称
241
+                    model_T_Sys_Accessories.F_Type = System.IO.Path.GetExtension(file.FileName);//附件类型
242
+                    model_T_Sys_Accessories.F_Url = path + name;//附件地址
243
+                    model_T_Sys_Accessories.F_Size = file.ContentLength;
244
+                    model_T_Sys_Accessories.F_CreateUser = userModel.F_UserCode;//上传人  
245
+                    int id = new BLL.T_Sys_Accessories().Add(model_T_Sys_Accessories);
246
+                    model_T_Sys_Accessories.F_Id = id;
247
+                    acs.Add(model_T_Sys_Accessories);
248
+                }
249
+
250
+                return Success("成功", acs);
251
+            }
252
+            else
253
+            {
254
+                return Error("请选择要上传的文件");
255
+            }
256
+            #endregion
257
+
258
+        }
259
+    }
260
+
261
+}

+ 1 - 0
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/CallOutOptController.cs

@@ -10,6 +10,7 @@ namespace CallCenterApi.Interface.Controllers
10 10
 {
11 11
     public class CallOutOptController : BaseController
12 12
     {
13
+    
13 14
         //外呼判断本地外地以及加前缀返回
14 15
         public ActionResult GetCallOutprefix(string phone)
15 16
         {

+ 1 - 1
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/EquipmentNumberController.cs

@@ -160,7 +160,7 @@ namespace CallCenterApi.Interface.Controllers
160 160
             else
161 161
             {
162 162
 
163
-                return Success("暂无工单"); ;
163
+                return Success("暂无数据"); ;
164 164
             }
165 165
         }
166 166
         /// <summary>

+ 119 - 72
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/IndexController.cs

@@ -156,87 +156,139 @@ namespace CallCenterApi.Interface.Controllers
156 156
             }
157 157
             return NoToken("未知错误,请重新登录");
158 158
         }
159
-
160 159
         /// <summary>
161 160
         /// 通话记录数量
162 161
         /// </summary>
163 162
         /// <returns></returns>
164 163
         public ActionResult GetTelRecordsTotal()
165 164
         {
166
-            
165
+            ActionResult res = NoToken("未知错误,请重新登录");
167 166
             if (Request.IsAuthenticated)
168 167
             {
169 168
                 int userId = CurrentUser.UserData.F_UserId;
170
-                Model.T_Sys_UserAccount userModel = new BLL.T_Sys_UserAccount().GetModel(userId);
169
+                string usercode = CurrentUser.UserData.F_UserCode;
170
+                int roleid = CurrentUser.UserData.F_RoleId;
171 171
                 if (userId != 0)
172 172
                 {
173 173
                     var date = DateTime.Now;
174 174
                     string strDate = date.ToString("yyyy-MM-dd");
175 175
                     string strMonth = date.ToString("yyyy-MM");
176 176
 
177
-                    string uwhere = " 1=1  and ISNULL(groupcode,'') != '' AND CONVERT(char(7),BeginTime,20) = '" + strMonth + "' ";;
178
-                    if (userModel.rolecode != "XTGLY")
177
+                    string uwhere = " 1=1 ";
178
+                    if (roleid != 17)
179 179
                     {
180
-                        uwhere += " and UserCode='" + userModel.F_UserCode + "' ";
181
-                    }
182
-                   
183
-                    if (!string.IsNullOrEmpty(userModel.groupcode))
184
-                    {
185
-                        uwhere += " and groupcode = '" + userModel.groupcode + "' ";
180
+                        uwhere += " and UserCode='" + usercode + "' ";
186 181
                     }
187 182
 
188 183
                     BLL.T_Call_CallRecords bll = new BLL.T_Call_CallRecords();
189
-                    DataTable dtConnect = DbHelperSQL.Query("select CONVERT(varchar(10),BeginTime, 23) AS yearmonthdays,CONVERT(char(7),BeginTime,20) AS yearmonths,CallType,BeginTime,groupcode,UserCode,ISNULL(TalkLongTime,0) AS TalkLongTime FROM T_Call_CallRecords WITH(NOLOCK) where " + uwhere + "").Tables[0];
190
-
191
-                    // 今日来电
192
-                    var dayinlist = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'").Count();
193
-                    var dayinlist_totaltimesum_0 = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'");
194
-                    var dayinlist_totaltimesum = (from DataRow dr in dayinlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
195
-                    //今日去电    
196
-                    var dayoutlist = dtConnect.Select("CallType='1' and yearmonthdays = '" + strDate + "'").Count();
197
-                    var dayoutlist_totaltimesum_0 = dtConnect.Select("CallType='1' and yearmonthdays = '" + strDate + "'");
198
-                    var dayoutlist_totaltimesum = (from DataRow dr in dayoutlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
199
-                    //本月来电    
200
-                    var moninlist = dtConnect.Select("CallType='0' and yearmonths = '" + strMonth + "'").Count();
201
-                    var moninlist_totaltimesum_0 = dtConnect.Select("CallType='0' and yearmonths = '" + strMonth + "'");
202
-                    var moninlist_totaltimesum = (from DataRow dr in moninlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
203
-                    //本月去电    
204
-                    var monoutlist = dtConnect.Select("CallType='1' and yearmonths = '" + strMonth + "'").Count();
205
-                    var monoutlist_totaltimesum_0 = dtConnect.Select("CallType='1' and yearmonths = '" + strMonth + "'");
206
-                    var monoutlist_totaltimesum = (from DataRow dr in monoutlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
207
-                    //未接来电    
208
-                    var daynocon = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'").Count();
184
+                    //var dayinlist = bll.GetModelList(uwhere + " and CallType='0' and CONVERT(varchar(10),BeginTime, 23)='" + strDate + "' and CallState='1' ");
185
+                    //var dayoutlist = bll.GetModelList(uwhere + " and CallType='1' and CONVERT(varchar(10),BeginTime, 23)='" + strDate + "' and CallState='1' ");
186
+                    //var moninlist = bll.GetModelList(uwhere + " and CallType='0' and CONVERT(char(7),BeginTime,20)='" + strMonth + "' and CallState='1' ");
187
+                    //var monoutlist = bll.GetModelList(uwhere + " and CallType='1' and CONVERT(char(7),BeginTime,20)='" + strMonth + "' and CallState='1' ");
188
+                    //int daynocon = bll.GetList("CallType='0' and CONVERT(varchar(100),BeginTime, 23)='" + strDate + "' and CallState='0' ").Tables[0].Rows.Count;
189
+
190
+                    //2018-05-03 lihai 首页统计问题
191
+                    var dayinlist = bll.GetModelList(uwhere + " and CallType='0' and CONVERT(varchar(10),BeginTime, 23)='" + strDate + "' ");
192
+                    var dayoutlist = bll.GetModelList(uwhere + " and CallType='1' and CONVERT(varchar(10),BeginTime, 23)='" + strDate + "' ");
193
+                    var moninlist = bll.GetModelList(uwhere + " and CallType='0' and CONVERT(char(7),BeginTime,20)='" + strMonth + "' ");
194
+                    var monoutlist = bll.GetModelList(uwhere + " and CallType='1' and CONVERT(char(7),BeginTime,20)='" + strMonth + "' ");
195
+
196
+                    int daynocon = bll.GetList("CallType='0' and CallState='0' and datediff(day,BeginTime, '" + strDate + "')=0 ").Tables[0].Rows.Count;
197
+                    //int daynocon = bll.GetList("CallType='0' and CONVERT(varchar(100),BeginTime, 23)='" + strDate + "' ").Tables[0].Rows.Count;
209 198
 
210 199
                     var obj = new
211 200
                     {
212
-                        //// 今日来电
213
-                        //dayin = new { count = dayinlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayinlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
214
-                        ////今日去电    
215
-                        //dayout = new { count = dayoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
216
-                        ////本月来电    
217
-                        //monin = new { count = moninlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(moninlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
218
-                        ////本月去电    
219
-                        //monout = new { count = monoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(monoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
220
-                        ////未接来电    
221
-                        //daynocon = daynocon
222
-
223
-                        // 今日来电
224
-                        dayin = new { count = dayinlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayinlist_totaltimesum.ToString()), 0) },
225
-                        //今日去电    
226
-                        dayout = new { count = dayoutlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayoutlist_totaltimesum.ToString()), 0) },
227
-                        //本月来电    
228
-                        monin = new { count = moninlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(moninlist_totaltimesum.ToString()), 0) },
229
-                        //本月去电    
230
-                        monout = new { count = monoutlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(monoutlist_totaltimesum.ToString()), 0) },
231
-                        //未接来电    
201
+                        dayin = new { count = dayinlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayinlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
202
+                        dayout = new { count = dayoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
203
+                        monin = new { count = moninlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(moninlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
204
+                        monout = new { count = monoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(monoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
232 205
                         daynocon = daynocon
233 206
                     };
234
-                    return Success("成功", obj);
235
-                
236
-            }
207
+                    res = Success("成功", obj);
208
+                }
237 209
             }
238
-            return NoToken("未知错误,请重新登录");
210
+            return res;
239 211
         }
212
+        ///// <summary>
213
+        ///// 通话记录数量
214
+        ///// </summary>
215
+        ///// <returns></returns>
216
+        //public ActionResult GetTelRecordsTotal()
217
+        //{
218
+            
219
+        //    if (Request.IsAuthenticated)
220
+        //    {
221
+        //        int userId = CurrentUser.UserData.F_UserId;
222
+        //        Model.T_Sys_UserAccount userModel = new BLL.T_Sys_UserAccount().GetModel(userId);
223
+        //        if (userId != 0)
224
+        //        {
225
+        //            var date = DateTime.Now;
226
+        //            string strDate = date.ToString("yyyy-MM-dd");
227
+        //            string strMonth = date.ToString("yyyy-MM");
228
+
229
+        //            string uwhere = " 1=1  and ISNULL(groupcode,'') != '' AND CONVERT(char(7),BeginTime,20) = '" + strMonth + "' ";;
230
+        //            if (userModel.rolecode != "XTGLY")
231
+        //            {
232
+        //                uwhere += " and UserCode='" + userModel.F_UserCode + "' ";
233
+        //            }
234
+                   
235
+        //            if (!string.IsNullOrEmpty(userModel.groupcode))
236
+        //            {
237
+        //                uwhere += " and groupcode = '" + userModel.groupcode + "' ";
238
+        //            }
239
+
240
+        //            BLL.T_Call_CallRecords bll = new BLL.T_Call_CallRecords();
241
+        //            DataTable dtConnect = DbHelperSQL.Query("select CONVERT(varchar(10),BeginTime, 23) AS yearmonthdays,CONVERT(char(7),BeginTime,20) AS yearmonths,CallType,BeginTime,groupcode,UserCode,ISNULL(TalkLongTime,0) AS TalkLongTime FROM T_Call_CallRecords WITH(NOLOCK) where " + uwhere + "").Tables[0];
242
+
243
+        //            // 今日来电
244
+        //            var dayinlist = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'").Count();
245
+        //            var dayinlist_totaltimesum_0 = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'");
246
+        //            var dayinlist_totaltimesum = (from DataRow dr in dayinlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
247
+        //            //今日去电    
248
+        //            var dayoutlist = dtConnect.Select("CallType='1' and yearmonthdays = '" + strDate + "'").Count();
249
+        //            var dayoutlist_totaltimesum_0 = dtConnect.Select("CallType='1' and yearmonthdays = '" + strDate + "'");
250
+        //            var dayoutlist_totaltimesum = (from DataRow dr in dayoutlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
251
+        //            //本月来电    
252
+        //            var moninlist = dtConnect.Select("CallType='0' and yearmonths = '" + strMonth + "'").Count();
253
+        //            var moninlist_totaltimesum_0 = dtConnect.Select("CallType='0' and yearmonths = '" + strMonth + "'");
254
+        //            var moninlist_totaltimesum = (from DataRow dr in moninlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
255
+        //            //本月去电    
256
+        //            var monoutlist = dtConnect.Select("CallType='1' and yearmonths = '" + strMonth + "'").Count();
257
+        //            var monoutlist_totaltimesum_0 = dtConnect.Select("CallType='1' and yearmonths = '" + strMonth + "'");
258
+        //            var monoutlist_totaltimesum = (from DataRow dr in monoutlist_totaltimesum_0 select dr.Field<int>("TalkLongTime")).Sum();
259
+        //            //未接来电    
260
+        //            var daynocon = dtConnect.Select("CallType='0' and yearmonthdays = '" + strDate + "'").Count();
261
+
262
+        //            var obj = new
263
+        //            {
264
+        //                //// 今日来电
265
+        //                //dayin = new { count = dayinlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayinlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
266
+        //                ////今日去电    
267
+        //                //dayout = new { count = dayoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
268
+        //                ////本月来电    
269
+        //                //monin = new { count = moninlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(moninlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
270
+        //                ////本月去电    
271
+        //                //monout = new { count = monoutlist.Count, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(monoutlist.Select(p => p.TalkLongTime).Sum().ToString()), 0) },
272
+        //                ////未接来电    
273
+        //                //daynocon = daynocon
274
+
275
+        //                // 今日来电
276
+        //                dayin = new { count = dayinlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayinlist_totaltimesum.ToString()), 0) },
277
+        //                //今日去电    
278
+        //                dayout = new { count = dayoutlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(dayoutlist_totaltimesum.ToString()), 0) },
279
+        //                //本月来电    
280
+        //                monin = new { count = moninlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(moninlist_totaltimesum.ToString()), 0) },
281
+        //                //本月去电    
282
+        //                monout = new { count = monoutlist, totaltime = DateTimeConvert.parseTimeSeconds(int.Parse(monoutlist_totaltimesum.ToString()), 0) },
283
+        //                //未接来电    
284
+        //                daynocon = daynocon
285
+        //            };
286
+        //            return Success("成功", obj);
287
+                
288
+        //    }
289
+        //    }
290
+        //    return NoToken("未知错误,请重新登录");
291
+        //}
240 292
 
241 293
         /// <summary>
242 294
         /// 获取当月/当天的工单量(已完成,未完成)
@@ -263,35 +315,30 @@ namespace CallCenterApi.Interface.Controllers
263 315
                         //var list3 = bll.GetList(" F_USERID='" + userId + "' and CONVERT(char(7),F_CREATEDATE,20)='" + strMonth + "' and F_WORKORDERSTATEID in (0,8) ").Tables[0];
264 316
                         //var list4 = bll.GetList(" F_USERID='" + userId + "' and CONVERT(char(7),F_CREATEDATE,20)='" + strMonth + "' and F_WORKORDERSTATEID in (4,5,6,7,9,12,13) ").Tables[0];
265 317
 
266
-                        string uwhere = " 1=1 AND CONVERT(char(7),CreateTime,20) = '" + strMonth + "'"; ;
318
+                        string uwhere = " 1=1 AND CONVERT(char(7),F_CreateTime,20) = '" + strMonth + "'"; ;
267 319
                         if (userModel.rolecode != "XTGLY")
268 320
                         {
269
-                            uwhere += " and CreateUser='" + userModel.F_UserCode + "' ";
321
+                            uwhere += " and F_CreateUser='" + userModel.F_UserCode + "' ";
270 322
                         }
271 323
 
272
-                        BLL.T_Bus_WorkOrder bll = new BLL.T_Bus_WorkOrder();
324
+                     
273 325
                         //var list1 = bll.GetList(uwhere + " and CONVERT(varchar(10),CreateTime, 23)='" + strDate + "' and State =2 and IsDel=0 ").Tables[0];
274 326
                         //var list2 = bll.GetList(uwhere + " and CONVERT(varchar(10),CreateTime, 23)='" + strDate + "' and State in (0,1) and IsDel=0 ").Tables[0];
275 327
                         //var list3 = bll.GetList(uwhere + " and CONVERT(char(7),CreateTime,20)='" + strMonth + "' and State =2 and IsDel=0 ").Tables[0];
276 328
                         //var list4 = bll.GetList(uwhere + " and CONVERT(char(7),CreateTime,20)='" + strMonth + "' and State in (0,1) and IsDel=0 ").Tables[0];
277 329
 
278
-                        DataTable dtConnect = DbHelperSQL.Query("select CONVERT(varchar(10),CreateTime, 23) AS yearmonthdays,CONVERT(char(7),CreateTime,20) AS yearmonths,State,IsDel,CreateTime,CreateUser FROM T_Wo_WorkOrder WITH(NOLOCK) where " + uwhere + "").Tables[0];
279
-
280
-                        //日已完成
281
-                        int list1_count = dtConnect.Select(" yearmonthdays = '" + strDate + "' and State = 1 and IsDel = 0").Count();
282
-                        //日未完成
283
-                        int list2_count = dtConnect.Select(" yearmonthdays = '" + strDate + "' and State=0 and IsDel=0 ").Count();
284
-                        //月已完成
285
-                        var list3_count = dtConnect.Select(" yearmonths = '" + strMonth + "' and State =1 and IsDel=0 ").Count();
286
-                        //月未完成
287
-                        var list4_count = dtConnect.Select(" yearmonths = '" + strMonth + "' and State=0 and IsDel=0").Count();
330
+                        BLL.T_Bus_WorkOrder bll = new BLL.T_Bus_WorkOrder();
331
+                        var list1 = bll.GetList(uwhere + " and CONVERT(varchar(10),F_CreateTime, 23)='" + strDate + "' and F_State in(10) and F_IsDelete=0 ").Tables[0];
332
+                        var list2 = bll.GetList(uwhere + " and CONVERT(varchar(10),F_CreateTime, 23)='" + strDate + "' and F_State in (1,3,4,5,6) and F_IsDelete=0 ").Tables[0];
333
+                        var list3 = bll.GetList(uwhere + " and CONVERT(char(7),F_CreateTime,20)='" + strMonth + "' and F_State in(10) and F_IsDelete=0 ").Tables[0];
334
+                        var list4 = bll.GetList(uwhere + " and CONVERT(char(7),F_CreateTime,20)='" + strMonth + "' and F_State in (1,3,4,5,6) and F_IsDelete=0 ").Tables[0];
288 335
 
289 336
                         var obj = new
290 337
                         {
291
-                            daywc = list1_count,
292
-                            daywwc = list2_count,
293
-                            monwc = list3_count,
294
-                            monwwc = list4_count
338
+                            daywc = list1.Rows.Count,
339
+                            daywwc = list2.Rows.Count,
340
+                            monwc = list3.Rows.Count,
341
+                            monwwc = list4.Rows.Count
295 342
                         };
296 343
                         return Success("成功", obj);
297 344
                     }

+ 4 - 2
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/report/BusinessController.cs

@@ -181,7 +181,8 @@ namespace CallCenterApi.Interface.Controllers.report
181 181
                     date.total++;
182 182
                     if (!string.IsNullOrEmpty(modelList[j].F_ProductDate))
183 183
                     {
184
-                        var pronos = DateTime.ParseExact(modelList[j].F_ProductDate, "yyyyMMdd", null).Month;
184
+                        string result = modelList[j].F_ProductDate.Replace(".", "");
185
+                        var pronos = DateTime.ParseExact(result, "yyyyMMdd", null).Month;
185 186
                         if (timeslot.stime > timeslot.etime)
186 187
                         {
187 188
                             int t = 12 - timeslot.stime;
@@ -276,7 +277,8 @@ namespace CallCenterApi.Interface.Controllers.report
276 277
             {
277 278
                 if (!string.IsNullOrEmpty(modelList[j].F_ProductDate))
278 279
                 {
279
-                    var pronos = DateTime.ParseExact(modelList[j].F_ProductDate, "yyyyMMdd", null).Month ;
280
+                    string result = modelList[j].F_ProductDate.Replace(".", "");
281
+                    var pronos = DateTime.ParseExact(result, "yyyyMMdd", null).Month ;
280 282
                     if (timeslot.stime > timeslot.etime)
281 283
                     {
282 284
                         int t = 12 - timeslot.stime;

+ 26 - 30
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/report/ZuoXiWorkTotalController.cs

@@ -85,11 +85,9 @@ namespace CallCenterApi.Interface.Controllers.report
85 85
             DataColumn dc9 = new DataColumn("平均排队时间");
86 86
             DataColumn dc10 = new DataColumn("接听通话次数");
87 87
             DataColumn dc11 = new DataColumn("通话分钟数");
88
-            DataColumn dc12 = new DataColumn("通话秒数");
89
-            DataColumn dc13 = new DataColumn("平均接听通话秒数");
88
+            DataColumn dc13 = new DataColumn("平均接听通话分钟数");
90 89
             DataColumn dc14 = new DataColumn("平均振铃秒数");
91 90
             DataColumn dc15 = new DataColumn("呼入占有率");
92
-            DataColumn dc16 = new DataColumn("用户评价");
93 91
             DataColumn dc17 = new DataColumn("坐席登录次数");
94 92
             DataColumn dc18 = new DataColumn("登录时长分钟数");
95 93
             DataColumn dc19 = new DataColumn("工作时长分钟数");
@@ -99,7 +97,7 @@ namespace CallCenterApi.Interface.Controllers.report
99 97
             DataColumn dc23 = new DataColumn("休息时长分钟数");
100 98
             DataColumn dc24 = new DataColumn("平均每天休息时长");
101 99
             DataColumn dc25 = new DataColumn("置忙平均休息分钟数");
102
-            DataColumn dc26 = new DataColumn("质检平均成绩");
100
+           // DataColumn dc26 = new DataColumn("质检平均成绩");
103 101
 
104 102
             dtNew.Columns.Add(dc1);
105 103
             dtNew.Columns.Add(dc2);
@@ -112,11 +110,10 @@ namespace CallCenterApi.Interface.Controllers.report
112 110
             dtNew.Columns.Add(dc9);
113 111
             dtNew.Columns.Add(dc10);
114 112
             dtNew.Columns.Add(dc11);
115
-            dtNew.Columns.Add(dc12);
116 113
             dtNew.Columns.Add(dc13);
117 114
             dtNew.Columns.Add(dc14);
118 115
             dtNew.Columns.Add(dc15);
119
-            dtNew.Columns.Add(dc16);
116
+          
120 117
             dtNew.Columns.Add(dc17);
121 118
             dtNew.Columns.Add(dc18);
122 119
             dtNew.Columns.Add(dc19);
@@ -126,7 +123,7 @@ namespace CallCenterApi.Interface.Controllers.report
126 123
             dtNew.Columns.Add(dc23);
127 124
             dtNew.Columns.Add(dc24);
128 125
             dtNew.Columns.Add(dc25);
129
-            dtNew.Columns.Add(dc26);
126
+         //   dtNew.Columns.Add(dc26);
130 127
             #endregion
131 128
             int days = 30;
132 129
             string sqltimeCallRecords = "";
@@ -284,7 +281,7 @@ namespace CallCenterApi.Interface.Controllers.report
284 281
                         drNew["接听通话次数"] = ijtcs.ToString();
285 282
                         //drNew["通话分钟数"] = (ithms / 60).ToString();
286 283
                         drNew["通话分钟数"] = CallCenter.Utility.DateTimeConvert.parseTimeSeconds(ithms, 0);
287
-                        drNew["通话秒数"] = ithms.ToString();
284
+                       
288 285
 
289 286
                         if (ijtcs != 0)
290 287
                         {
@@ -296,8 +293,9 @@ namespace CallCenterApi.Interface.Controllers.report
296 293
                             ipjjtms = 0;//平均接通秒数
297 294
                             ipjzlms = 0;//平均振铃秒数
298 295
                         }
299
-                        drNew["平均接听通话秒数"] = ipjjtms.ToString();
300
-                        drNew["平均振铃秒数"] = ipjzlms.ToString();
296
+                   
297
+                    drNew["平均接听通话分钟数"] = CallCenter.Utility.DateTimeConvert.parseTimeSeconds(ipjjtms, 0);
298
+                    drNew["平均振铃秒数"] = ipjzlms.ToString();
301 299
 
302 300
                         //坐席登录次数
303 301
                         DataTable dtAgent = DbHelperSQL.Query("select COUNT(*) as dl,SUM(LoginTimes) as dlsc,SUM(reposenum) as zm,SUM(ReposeTimes) as xx from rep_agent_detail where AgentId=" + dt.Rows[i]["F_WorkNumber"] + " " + sqltimeCallRecords.Replace("TimeAlerting", "TimeLogin")).Tables[0];
@@ -367,16 +365,14 @@ namespace CallCenterApi.Interface.Controllers.report
367 365
                         drNew["呼入占有率"] = (ihrzyl * 100).ToString("0.00") + "%";
368 366
                         //用户评价
369 367
                         //未评价为0
370
-                        object obj = DbHelperSQL.GetSingle("select count(*) from T_Call_CallRecords  WITH(NOLOCK) where MYD is not null and myd<>0 and CallState=1 and userid=" + dt.Rows[i]["F_UserId"] + strsqlcall);
371
-                        string myd = "";
372
-                        if (obj != null)
373
-                        {
374
-                            myd = obj.ToString();
375
-                        }
376
-                        drNew["用户评价"] = myd;
368
+                       
377 369
                         drNew["坐席登录次数"] = izxdlcs.ToString();
378
-                        drNew["登录时长分钟数"] = (idlsc / 60).ToString();
379
-                        drNew["工作时长分钟数"] = (iWorktime / 60).ToString();
370
+                        float a = idlsc / 360;
371
+                        float  b=idlsc % 360/60;
372
+                    drNew["登录时长分钟数"] = string .Format ("{0}小时{1}分钟",a ,b );
373
+                    float c = idlsc / 360;
374
+                    float d = idlsc % 360 / 60;
375
+                    drNew["工作时长分钟数"] = drNew["工作时长分钟数"] = string.Format("{0}小时{1}分钟", c, d); ;
380 376
                         drNew["平均每天工作时长"] = Math.Round((double.Parse(iWorktime.ToString()) / 60 / 60 / days), 2).ToString();
381 377
                         drNew["平均操作分钟数"] = (ipjczsc / 60).ToString();
382 378
                         drNew["置忙次数"] = izmcs.ToString();
@@ -384,17 +380,17 @@ namespace CallCenterApi.Interface.Controllers.report
384 380
                         drNew["平均每天休息时长"] = Math.Round((double.Parse(ixxsc.ToString()) / 60 / 60 / days), 2).ToString();
385 381
                         drNew["置忙平均休息分钟数"] = (ipjzmxxsc / 60).ToString();
386 382
 
387
-                        DataSet dszj = DbHelperSQL.Query("select convert(int,SUM(f_qcscore)) as fs,COUNT(*) as fsct from T_Call_CallRecords  WITH(NOLOCK) where F_QCState=1 and UserId=" + dt.Rows[i]["F_UserId"] + strsqlcall);
388
-                        int zfs = 0;
389
-                        if (dszj != null && dszj.Tables.Count > 0)
390
-                        {
391
-                            DataTable dtzj = dszj.Tables[0];
392
-                            if (dtzj.Rows.Count > 0 && dtzj.Rows[0]["fs"].ToString() != "" && dtzj.Rows[0]["fsct"].ToString() != "")
393
-                            {
394
-                                zfs = Convert.ToInt32(dtzj.Rows[0]["fs"].ToString()) / int.Parse(dtzj.Rows[0]["fsct"].ToString());
395
-                            }
396
-                        }
397
-                        drNew["质检平均成绩"] = zfs.ToString();
383
+                      //  DataSet dszj = DbHelperSQL.Query("select convert(int,SUM(f_qcscore)) as fs,COUNT(*) as fsct from T_Call_CallRecords  WITH(NOLOCK) where F_QCState=1 and UserId=" + dt.Rows[i]["F_UserId"] + strsqlcall);
384
+                        //int zfs = 0;
385
+                        //if (dszj != null && dszj.Tables.Count > 0)
386
+                        //{
387
+                        //    DataTable dtzj = dszj.Tables[0];
388
+                        //    if (dtzj.Rows.Count > 0 && dtzj.Rows[0]["fs"].ToString() != "" && dtzj.Rows[0]["fsct"].ToString() != "")
389
+                        //    {
390
+                        //        zfs = Convert.ToInt32(dtzj.Rows[0]["fs"].ToString()) / int.Parse(dtzj.Rows[0]["fsct"].ToString());
391
+                        //    }
392
+                        //}
393
+                        //drNew["质检平均成绩"] = zfs.ToString();
398 394
 
399 395
                         dtNew.Rows.Add(drNew);
400 396
                     }

+ 4 - 4
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/tel/CallrecordsController.cs

@@ -36,10 +36,10 @@ namespace CallCenterApi.Interface.Controllers.tel
36 36
             string strpagesize = RequestString.GetQueryString("pagesize");
37 37
             int pagesize = 10;
38 38
           
39
-            if (!string.IsNullOrEmpty(userModel.groupcode))
40
-            {
41
-                sql += " and groupcode = '" + userModel.groupcode + "' ";
42
-            }
39
+            //if (!string.IsNullOrEmpty(userModel.groupcode))
40
+            //{
41
+            //    sql += " and groupcode = '" + userModel.groupcode + "' ";
42
+            //}
43 43
 
44 44
             if (usercode != null && usercode.Trim() != "")
45 45
             {

+ 119 - 7
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkOrderController.cs

@@ -23,7 +23,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
23 23
         //   private BLL.T_Sys_UserAccount userBLL = new BLL.T_Sys_UserAccount();
24 24
         //  private BLL.T_Bus_WorkOrder workorderBLL = new BLL.T_Bus_WorkOrder();
25 25
         //   private BLL.T_Sys_SystemConfig configBll = new BLL.T_Sys_SystemConfig();
26
-
26
+      
27 27
         /// <summary>
28 28
         /// 上传附件
29 29
         /// </summary>
@@ -198,20 +198,20 @@ namespace CallCenterApi.Interface.Controllers.workorder
198 198
                     str = DateTime.Parse(starttime).ToString("yyyy年MM月dd日") + "至" +
199 199
                         DateTime.Parse(endtime).ToString("yyyy年MM月dd日") + "消费者重复投诉表";
200 200
                 }
201
-                else if (istime == 0&&isdc >0)
201
+                else if (istime == 0&&isdc ==1)
202 202
                 {
203 203
                     sql +=  " and datediff(day,F_CreateTime,'" + DateTime.Now.ToString("yyyy-MM-dd") + "')<=0 ";
204 204
                     sql += " and datediff(day,F_CreateTime,'" + DateTime.Now.ToString("yyyy-MM-dd") + "')>=0   ";
205 205
                     str = DateTime.Now.ToString("yyyy年MM月dd日") + "消费者重复投诉表";
206 206
                 }
207
-                else if (istime> 0 && isdc > 0)
207
+                else if (istime> 0 && isdc == 1)
208 208
                 {
209 209
                     sql +=  " and datediff(day,F_CreateTime,'" + DateTime.Now.ToString("yyyy-MM")
210 210
                       +  "-01"+ "')<=0 ";
211 211
                     sql += " and datediff(day,F_CreateTime,'" + DateTime.Now.ToString("yyyy-MM-dd") + "')>=0   ";
212 212
                     str = DateTime.Now.ToString("yyyy年MM月") + "消费者重复投诉表";
213 213
                 }
214
-                if (isdc > 0)
214
+                if (isdc ==1)
215 215
                 {
216 216
                     var depts = new BLL.T_Bus_WorkOrder().GetModelList(sql);
217 217
                     #region 
@@ -264,6 +264,116 @@ namespace CallCenterApi.Interface.Controllers.workorder
264 264
 
265 265
                     }
266 266
                 }
267
+                else  if (isdc == 2)
268
+                {
269
+                    var depts = new BLL.T_Bus_WorkOrder().GetModelList(sql);
270
+                    #region 
271
+                    dt.Columns.Add("工单编号");
272
+                    dt.Columns.Add("大区");
273
+                    dt.Columns.Add("办事处");
274
+                    dt.Columns.Add("投诉时间");
275
+                    dt.Columns.Add("序号");
276
+                    dt.Columns.Add("姓名");
277
+                    dt.Columns.Add("地址");
278
+                    dt.Columns.Add("联系电话");
279
+                    dt.Columns.Add("产品代码");
280
+                    dt.Columns.Add("产品名称");
281
+                    dt.Columns.Add("规格");
282
+                    dt.Columns.Add("生产日期");
283
+                    dt.Columns.Add("产品编码");
284
+                    dt.Columns.Add("生产厂家");
285
+                    dt.Columns.Add("问题代码");
286
+                    dt.Columns.Add("质量问题");
287
+                    dt.Columns.Add("通知人");
288
+                    dt.Columns.Add("接听人");
289
+                    dt.Columns.Add("落实情况");
290
+                    dt.Columns.Add("处理进度");
291
+                    dt.Columns.Add("工单类别");
292
+                    dt.Columns.Add("重复工单");
293
+                    #endregion
294
+                    foreach (var it in depts)
295
+                    {
296
+                        DataRow drNew = dt.NewRow();
297
+                        #region 基本字段
298
+                        drNew["工单编号"] = it.F_WorkOrderId;//
299
+                        if (!string.IsNullOrEmpty(it.F_Area))
300
+                        {
301
+                            try
302
+                            {
303
+                                var dept = new BLL.T_Sys_Department().GetModel(int.Parse(it.F_Area));
304
+                                if (dept != null)
305
+                                    drNew["大区"]  = dept.F_DeptName;
306
+                            }
307
+                            catch
308
+                            {
309
+                                drNew["大区"] = "";
310
+                            }
311
+                        }
312
+                        if (!string.IsNullOrEmpty(it.F_Office))
313
+                        {
314
+                            try
315
+                            {
316
+                                var dept = new BLL.T_Sys_Department().GetModel(int.Parse(it.F_Office));
317
+                                if (dept != null)
318
+                                    drNew["办事处"]  = dept.F_DeptName;
319
+                            }
320
+                            catch
321
+                            {
322
+                                drNew["办事处"]  = "";
323
+                            }
324
+                        }
325
+                        drNew["投诉时间"] = it.F_CreateTime ;//
326
+                        drNew["序号"] = it.F_SerialNumber;//
327
+                        drNew["姓名"] = it.F_CusName;//姓名
328
+                        drNew["地址"] = it.F_AddRess;//地址
329
+                        drNew["联系电话"] = it.F_CusPhone;
330
+                        drNew["产品代码"] = it.F_ProductType;
331
+                        drNew["产品名称"] = it.F_ProductName;
332
+                        drNew["规格"] = it.F_Specifications;
333
+                        drNew["生产日期"] = it.F_ProductDate;
334
+                        drNew["产品编码"] = it.F_BatchNumber;
335
+                        drNew["生产厂家"] = it.F_Manufacturer;
336
+                        drNew["问题代码"] = it.F_ProblemCode;
337
+                        drNew["质量问题"] = it.F_QualityProblem;
338
+                        drNew["通知人"] = it.F_Notifications;
339
+                        drNew["接听人"] = it.F_ReceivingPerson;
340
+                        drNew["落实情况"] = it.F_DealResult;
341
+                        if (it.F_State == 0)
342
+                            drNew["处理进度"] = "待提交";
343
+                        else if (it.F_State == 1)
344
+                            drNew["处理进度"] = "待指派";
345
+                        else if (it.F_State == 3)
346
+                            drNew["处理进度"] = "待处理";
347
+                        else if (it.F_State == 4)
348
+                            drNew["处理进度"] = "处理中";
349
+                        else if (it.F_State == 5)
350
+                            drNew["处理进度"] = "退回待指派";
351
+                        else if (it.F_State == 6)
352
+                            drNew["处理进度"] = "退回待提交";
353
+                        else if (it.F_State == 10)
354
+                            drNew["处理进度"] = "已完结";
355
+                        if (it .F_Type==1)
356
+                        drNew["工单类别"] = "咨询";
357
+                        else
358
+                            drNew["工单类别"] = "投诉";
359
+                        if (it .F_Duplicate==0)
360
+                        drNew["重复工单"] = "未重复";
361
+                        else
362
+                            drNew["重复工单"] = "重复";
363
+                        dt.Rows.Add(drNew);
364
+                        #endregion
365
+                    }
366
+                    NPOIHelper npoi = new NPOIHelper();
367
+                    if (npoi.ExportToExcel("工单列表", dt) == "")
368
+                    {
369
+                        return Success("导出成功");
370
+                    }
371
+                    else
372
+                    {
373
+                        return Error("导出失败");
374
+
375
+                    }
376
+                }
267 377
                 else
268 378
                 {
269 379
                     sql = "and" + sql;
@@ -398,7 +508,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
398 508
                         model.F_OfficName = it.F_Office;
399 509
                     }
400 510
                 }
401
-                model.F_CreateTime = it.F_CreateTime;//投诉时间
511
+                model.F_CreateTime = DateTime .Parse (it.F_CreateTime.ToString ()).ToString ("dd日hh时mm分")  ;//投诉时间
402 512
                 model.F_DealTimely = it.F_DealTimely;//重要级别
403 513
                 model.F_Reason = it.F_Reason;//重要级别原因
404 514
                 model.F_SerialNumber = it.F_SerialNumber;//序号
@@ -519,7 +629,8 @@ namespace CallCenterApi.Interface.Controllers.workorder
519 629
                 {
520 630
                     try
521 631
                     {
522
-                        var pronos = DateTime.ParseExact(input.F_ProductDate, "yyyyMMdd", null).ToString("yyyy-MM-dd");
632
+                        string result = input.F_ProductDate.Replace(".", "");
633
+                        var pronos = DateTime.ParseExact(result, "yyyyMMdd", null).ToString("yyyy-MM-dd");
523 634
                         var protime = Convert.ToDateTime(pronos);
524 635
                         if (DateTime.Parse(pronos) > DateTime.Now)
525 636
                         {
@@ -583,7 +694,8 @@ namespace CallCenterApi.Interface.Controllers.workorder
583 694
                 {
584 695
                     try
585 696
                     {
586
-                        var pronos = DateTime.ParseExact(input.F_ProductDate, "yyyyMMdd", null).ToString("yyyy-MM-dd");
697
+                        string result = input.F_ProductDate.Replace(".", "");
698
+                        var pronos = DateTime.ParseExact(result, "yyyyMMdd", null).ToString("yyyy-MM-dd");
587 699
                         var protime = Convert.ToDateTime(pronos);
588 700
                         if (DateTime.Parse(pronos) > DateTime.Now)
589 701
                         {

File diff suppressed because it is too large
+ 6 - 4
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkorderAppController.cs


+ 1 - 1
codegit/CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/WorkOrderInput.cs

@@ -67,7 +67,7 @@ namespace CallCenterApi.Interface.Models.Input
67 67
         /// <summary>
68 68
         /// 投诉时间
69 69
         /// </summary>
70
-        public DateTime? F_CreateTime
70
+        public string  F_CreateTime
71 71
         {
72 72
             get; set;
73 73
         }

+ 1 - 0
codegit/CallCenterApi/CallCenterApi.Model/CallCenterApi.Model.csproj

@@ -88,6 +88,7 @@
88 88
     <Compile Include="T_SMS_SentSMS.cs" />
89 89
     <Compile Include="T_SMS_Template.cs" />
90 90
     <Compile Include="T_Sys_Accessories.cs" />
91
+    <Compile Include="T_Sys_ApplicationsVersion.cs" />
91 92
     <Compile Include="T_Sys_Area.cs" />
92 93
     <Compile Include="T_Sys_Department.cs" />
93 94
     <Compile Include="T_Sys_DictionaryBase.cs" />

+ 144 - 0
codegit/CallCenterApi/CallCenterApi.Model/T_Sys_ApplicationsVersion.cs

@@ -0,0 +1,144 @@
1
+using System;
2
+
3
+namespace CallCenterApi.Model
4
+{
5
+    /// <summary>
6
+    /// T_Sys_ApplicationsVersion:实体类(属性说明自动提取数据库字段的描述信息)
7
+    /// </summary>
8
+    [Serializable]
9
+    public partial class T_Sys_ApplicationsVersion
10
+    {
11
+        public T_Sys_ApplicationsVersion()
12
+        { }
13
+        #region Model
14
+        private int _f_id;
15
+        private long _f_type;
16
+        private string _f_versionname;
17
+        private string _f_versioncode;
18
+        private string _f_files;
19
+        private string _f_url;
20
+        private string _f_createuser;
21
+        private DateTime? _f_createtime;
22
+        private string _f_updateuser;
23
+        private DateTime? _f_updatetime;
24
+        private int _f_isdelete;
25
+        private DateTime? _f_deletetime;
26
+        private int? _f_sort;
27
+        private string _f_remarks;
28
+        /// <summary>
29
+        /// ID
30
+        /// </summary>
31
+        public int F_ID
32
+        {
33
+            set { _f_id = value; }
34
+            get { return _f_id; }
35
+        }
36
+        /// <summary>
37
+        /// 应用分类(0android 1ios)
38
+        /// </summary>
39
+        public long F_Type
40
+        {
41
+            set { _f_type = value; }
42
+            get { return _f_type; }
43
+        }
44
+        /// <summary>
45
+        /// 版本名称
46
+        /// </summary>
47
+        public string F_VersionName
48
+        {
49
+            set { _f_versionname = value; }
50
+            get { return _f_versionname; }
51
+        }
52
+        /// <summary>
53
+        /// 版本号
54
+        /// </summary>
55
+        public string F_VersionCode
56
+        {
57
+            set { _f_versioncode = value; }
58
+            get { return _f_versioncode; }
59
+        }
60
+        /// <summary>
61
+        /// android地址
62
+        /// </summary>
63
+        public string F_Files
64
+        {
65
+            set { _f_files = value; }
66
+            get { return _f_files; }
67
+        }
68
+        /// <summary>
69
+        /// ios链接地址
70
+        /// </summary>
71
+        public string F_Url
72
+        {
73
+            set { _f_url = value; }
74
+            get { return _f_url; }
75
+        }
76
+        /// <summary>
77
+        /// 添加人
78
+        /// </summary>
79
+        public string F_CreateUser
80
+        {
81
+            set { _f_createuser = value; }
82
+            get { return _f_createuser; }
83
+        }
84
+        /// <summary>
85
+        /// 添加时间
86
+        /// </summary>
87
+        public DateTime? F_CreateTime
88
+        {
89
+            set { _f_createtime = value; }
90
+            get { return _f_createtime; }
91
+        }
92
+        /// <summary>
93
+        /// 修改人
94
+        /// </summary>
95
+        public string F_UpdateUser
96
+        {
97
+            set { _f_updateuser = value; }
98
+            get { return _f_updateuser; }
99
+        }
100
+        /// <summary>
101
+        /// 修改时间
102
+        /// </summary>
103
+        public DateTime? F_UpdateTime
104
+        {
105
+            set { _f_updatetime = value; }
106
+            get { return _f_updatetime; }
107
+        }
108
+        /// <summary>
109
+        /// 是否删除
110
+        /// </summary>
111
+        public int F_IsDelete
112
+        {
113
+            set { _f_isdelete = value; }
114
+            get { return _f_isdelete; }
115
+        }
116
+        /// <summary>
117
+        /// 删除时间
118
+        /// </summary>
119
+        public DateTime? F_DeleteTime
120
+        {
121
+            set { _f_deletetime = value; }
122
+            get { return _f_deletetime; }
123
+        }
124
+        /// <summary>
125
+        /// 排序
126
+        /// </summary>
127
+        public int? F_Sort
128
+        {
129
+            set { _f_sort = value; }
130
+            get { return _f_sort; }
131
+        }
132
+        /// <summary>
133
+        /// 备注
134
+        /// </summary>
135
+        public string F_Remarks
136
+        {
137
+            set { _f_remarks = value; }
138
+            get { return _f_remarks; }
139
+        }
140
+        #endregion Model
141
+
142
+    }
143
+}
144
+

+ 0 - 1
codegit/CallCenterCommon/CallCenter.Utility/NPOI/NPOIHelper.cs

@@ -966,7 +966,6 @@ namespace CallCenter.Utility
966 966
                 IRow irow5 = sheet.CreateRow(t+1);
967 967
                 ICell cell7 = irow5.CreateCell(0);
968 968
                 cell7.SetCellValue("工\n厂\n投\n诉\n占\n比\n");
969
-        
970 969
                 cell7.CellStyle = cellStylebt;
971 970
                 cell7.CellStyle.WrapText=true ;
972 971
                 sheet.AddMergedRegion(new CellRangeAddress(t+1, t+ count, 0, 0));

+ 16 - 32
ivr/IVR_Auto.xml

@@ -13,13 +13,13 @@
13 13
 			groupcode:坐席组编号
14 14
 			插入通话记录示例:exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,1,'','KFZ' 
15 15
 		-->
16
-		<cell Name="CELL_BRANCH" Pos="2" Var="CalleeID" DefaultPos="2" Note="首次分支分支节点">
17
-			<Branch Value="8001" Pos="201" /><!--客服组正常流程:黑名单-节假日-坐席排队-->
18
-			<Branch Value="6800" Pos="202" /><!--市场组直接转坐席-->
16
+		<!--<cell Name="CELL_BRANCH" Pos="2" Var="CalleeID" DefaultPos="2" Note="首次分支分支节点"> -->
17
+			<!--<Branch Value="8001" Pos="201" />--><!--客服组正常流程:黑名单-节假日-坐席排队-->
18
+			<!--<Branch Value="6800" Pos="202" />--><!--市场组直接转坐席-->
19 19
 		</cell>
20
-		<cell Name="CELL_SQL" Pos="201" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','KFZ' " 
20
+		<cell Name="CELL_SQL" Pos="201" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','KFZ' " 
21 21
 		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-客服组" />
22
-		<cell Name="CELL_SQL" Pos="202" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','SCZ' " 
22
+		<cell Name="CELL_SQL" Pos="202" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=121.196.219.217" SqlStr="exec P_OptCallRecords '%[CallerID]','%[CallID]',1,0,'0','','SCZ' " 
23 23
 		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录-市场组" />
24 24
 		<cell Name="CELL_DEFINEVAR" Pos="3" Next="4" Note="定义变量节点">
25 25
 			<DefVar VarType="1" VarName="AgentNo" VarVal="0" />
@@ -31,12 +31,9 @@
31 31
 			<DefVar VarType="1" VarName="HolidayVerify" VarVal="0" />
32 32
 			<DefVar VarType="1" VarName="zbdh" VarVal="0" />
33 33
 		</cell>
34
-		<cell Name="CELL_BRANCH" Pos="4" Var="CalleeID" DefaultPos="1010" Note="流程不同分支节点">
35
-			<Branch Value="8001" Pos="104" /><!--客服组正常流程:黑名单-节假日-坐席排队-->
36
-			<Branch Value="6800" Pos="603" /><!--市场组直接转坐席--> 
37
-		</cell>
34
+		
38 35
 		<!--黑名单-->
39
-		<cell Name="CELL_SQL" Pos="104" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetBlacklist  '%[CallerID]','%[CallID]' " IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
36
+		<cell Name="CELL_SQL" Pos="4" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=." SqlStr="exec P_GetBlacklist  '%[CallerID]','%[CallID]' " IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
40 37
 		<cell Name="CELL_RECORDSET" Pos="5" LPos="6" EPos="6" GPos="6" Note="取黑名单结果">
41 38
 			<Map Var="BlackListVerify" />
42 39
 		</cell>
@@ -48,28 +45,28 @@
48 45
 		<!--黑名单-->
49 46
 		
50 47
 		<!--欢迎词-->
51
-		<!-- <cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="D:\Midware\wav\欢迎词.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50"  TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" /> -->
48
+		<cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="D:\双汇ShuangHui\Middle_shuanghui\wav\双汇欢迎词.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50"  TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" /> 
52 49
 		<!--欢迎词-->
53 50
 		
54 51
 		<!--节假日-->
55 52
 		<!--判断是否加班或节假日,是放节假日音后挂机,否转坐席-->
56
-		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetHolidays" IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
53
+		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=." SqlStr="exec P_GetHolidays" IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
57 54
 		<cell Name="CELL_RECORDSET" Pos="9" LPos="10" EPos="10" GPos="10" Note="取节假日结果">
58 55
 			<Map Var="HolidayVerify" />
59 56
 		</cell>
60
-		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603" FalsePos="29" Note="判断节假日" />
57
+		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603"  Note="判断节假日" />
61 58
 		<cell Name="CELL_AUDIODTMF" Pos="11" PlayType="2" ContentType="1" Content="D:\Midware\wav\假期提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音" />
62 59
 		<!--节假日-->
63 60
 		
64 61
 		
65 62
 		<!--排队,转坐席-->
66
-		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="exec P_GetSeatGroup '%[CallerID]','%[CalleeID]'" 
63
+		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=." SqlStr="exec P_GetSeatGroup '%[CallerID]','%[CalleeID]'" 
67 64
 		IsSaved="yes" SuccessPos="604" FailPos="24" Note="获取坐席组ID" />
68 65
 		<cell Name="CELL_RECORDSET" Pos="604" LPos="501" EPos="501" GPos="501" Note="获取坐席组ID结果">
69 66
 			<Map Var="GroupID" />
70 67
 		</cell>
71 68
 		
72
-		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',3,%[KeyGroup],'0','','' " IsSaved="no" SuccessPos="13" FailPos="13" Note="更新排队开始时间" />
69
+		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=." SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',3,%[KeyGroup],'0','','' " IsSaved="no" SuccessPos="13" FailPos="13" Note="更新排队开始时间" />
73 70
 		<!--坐席排队时,没有登录坐席直接转值班电话,无空闲坐席转坐席全忙放音,有空闲坐席继续播报-->
74 71
 		<!--Strategy:座席分配策略,1循环接听、2最大空闲接听、3最少接听接听、4指定坐席接听,指定多座席时,坐席工号之间用‘|’分隔,坐席数不要超过4个。-->
75 72
 		<cell Name="CELL_BRANCH" Pos="13" Var="CalleeID" DefaultPos="1013" Note="排队分支节点">
@@ -78,9 +75,9 @@
78 75
 		</cell>
79 76
 		
80 77
 		<cell Name="CELL_QUEUE" Pos="1013" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
81
-		NoAgentPos="29" NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点" />
78
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点" />
82 79
 		<cell Name="CELL_QUEUE" Pos="1014" Strategy="1" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
83
-		NoAgentPos="29" NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点-sc" />
80
+		 NoFreePos="14" SuccessPos="31" HangupPos="24" Note="排队节点-sc" />
84 81
 		<cell Name="CELL_AUDIODTMF" Pos="1015" PlayType="2" ContentType="1" Content="D:\Midware\wav\嘟嘟无人接听.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音-sc" />
85 82
 		
86 83
 		<cell Name="CELL_AUDIODTMF" Pos="14" PlayType="1" ContentType="1" Content="D:\Midware\wav\坐席全忙.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
@@ -97,23 +94,10 @@
97 94
 		  <BandData Var="CallID" />
98 95
 		</cell>
99 96
 		<!--排队,转坐席-->
100
-				
101
-		<!--转值班电话-->
102
-		<cell Name="CELL_AUDIODTMF" Pos="29" PlayType="2" ContentType="1" Content="D:\Midware\wav\转值班电话提示.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="701" FailPos="24" HangupPos="24" Note="转值班电话提示音" />
103
-		<cell Name="CELL_BRANCH" Pos="701" Var="CalleeID" DefaultPos="1013" Note="排队分支节点">
104
-			<Branch Value="8001" Pos="7011" /><!--客服组-->
105
-			<Branch Value="6800" Pos="7012" /><!--市场组-->
106
-		</cell>
107
-		<cell Name="CELL_SQL" Pos="7011" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="EXEC P_GetZBDH '%[CallID]',0 " IsSaved="yes" SuccessPos="702" FailPos="24" Note="获取值班电话-客服组" />
108
-		<cell Name="CELL_SQL" Pos="7012" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr="EXEC P_GetZBDH '%[CallID]',1 " IsSaved="yes" SuccessPos="702" FailPos="24" Note="获取值班电话-市场组" />
109
-		<cell Name="CELL_RECORDSET" Pos="702" LPos="30" EPos="30" GPos="30" Note="获取值班电话结果">
110
-			<Map Var="zbdh" />
111
-		</cell>
112
-		<cell Name="CELL_TRANSFEROUT" Pos="30" CalleeNumType="2" CalleeNum="zbdh" Timeout="60" SuccessPos="25" FailPos="24" Note="转值班电话" />
113
-		<!--转值班电话-->
97
+		
114 98
 		
115 99
 		<!---->
116
-		<cell Name="CELL_SQL" Pos="24" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_Anto;Data Source=192.168.209.5" SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',2,0,'0','','' " IsSaved="no" 
100
+		<cell Name="CELL_SQL" Pos="24" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ShuangHui;;Data Source=." SqlStr=" exec P_OptCallRecords '%[CallerID]','%[CallID]',2,0,'0','','' " IsSaved="no" 
117 101
 		SuccessPos="204" FailPos="25" Note="更新挂机时间" />
118 102
 		<cell Name="CELL_HANGUP" Pos="204" Next="25" Note="挂机节点" />
119 103
 		<cell Name="CELL_END" Pos="25" Note="结束节点" />