Selaa lähdekoodia

部门IVR欢迎词

zhengbingbing 8 vuotta sitten
vanhempi
commit
8a47be6b7c

+ 1 - 0
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/CallCenterApi.Interface.csproj

@@ -295,6 +295,7 @@
295 295
     <Compile Include="Models\Filter\FilterCallPlan.cs" />
296 296
     <Compile Include="Models\Filter\FilterCustomer.cs" />
297 297
     <Compile Include="Models\Filter\FilterCustomerField.cs" />
298
+    <Compile Include="Models\Filter\FilterDepartment.cs" />
298 299
     <Compile Include="Models\Filter\FilterExcelTmp.cs" />
299 300
     <Compile Include="Models\Filter\FilterPagerInfo.cs" />
300 301
     <Compile Include="Models\Filter\FilterQuestion.cs" />

+ 36 - 0
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/DepartmentController.cs

@@ -1,6 +1,7 @@
1 1
 using CallCenter.Utility;
2 2
 using CallCenterApi.DB;
3 3
 using CallCenterApi.Interface.Controllers.Base;
4
+using CallCenterApi.Interface.Models.Filter;
4 5
 using CallCenterApi.Interface.Models.Input;
5 6
 using System;
6 7
 using System.Collections.Generic;
@@ -81,6 +82,7 @@ namespace CallCenterApi.Interface.Controllers
81 82
                 dModel.F_Sort = input.Sort;
82 83
                 dModel.F_DeptName = input.DeptName;
83 84
                 dModel.F_State = 1;
85
+                dModel.F_Remark = input.playivr;
84 86
                 int id = departmentBLL.Add(dModel);
85 87
                 if (id > 0)
86 88
                 {
@@ -121,6 +123,7 @@ namespace CallCenterApi.Interface.Controllers
121 123
                 }
122 124
                 dModel.F_Sort = input.Sort;
123 125
                 dModel.F_DeptName = input.DeptName;
126
+                dModel.F_Remark = input.playivr;
124 127
                 if (dBLL.Update(dModel))
125 128
                     return Success("编辑成功");
126 129
                 return Error("编辑失败");
@@ -173,6 +176,39 @@ namespace CallCenterApi.Interface.Controllers
173 176
             return NoToken("未知错误,请重新登录");
174 177
         }
175 178
 
179
+        public ActionResult GetDeptListRight(FilterDepartment filter )
180
+        {
181
+            if (Request.IsAuthenticated)
182
+            {
183
+                DataTable dt = new DataTable();
184
+                string sqlwhere = " and F_State=1 ";
185
+                if (!string.IsNullOrWhiteSpace(filter.Code))
186
+                {
187
+                    sqlwhere += " and F_ParentCode like '%" + filter.Code + "%' ";
188
+                }
189
+                if (!string.IsNullOrWhiteSpace(filter.playivr))
190
+                {
191
+                    sqlwhere += " and F_Remark like '%" + filter.playivr + "%' ";
192
+                }
193
+
194
+                int recordCount = 0;
195
+                dt = BLL.PagerBLL.GetListPager(
196
+                    "T_Sys_Department",
197
+                    "F_DeptId",
198
+                    "*",
199
+                    sqlwhere,
200
+                    "ORDER BY F_DeptId desc ",
201
+                    filter.PageSize,
202
+                    filter.PageIndex,
203
+                    true,
204
+                    out recordCount);
205
+                dt = new BLL.T_Sys_Department().GetList(sqlwhere).Tables[0];
206
+
207
+                return Success("加载成功", dt);
208
+            }
209
+            return NoToken("未知错误,请重新登录");
210
+        }
211
+
176 212
         /// <summary>
177 213
         /// 获取部门列表
178 214
         /// </summary>

+ 4 - 0
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Models/Input/DepartmentInput.cs

@@ -23,5 +23,9 @@ namespace CallCenterApi.Interface.Models.Input
23 23
         /// 部门排序
24 24
         /// </summary>
25 25
         public int Sort { get; set; }
26
+        /// <summary>
27
+        /// 此部门播放的语音文本
28
+        /// </summary>
29
+        public string playivr { get; set; }
26 30
     }
27 31
 }

+ 139 - 0
IVR/IVR_HX_new.xml

@@ -0,0 +1,139 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<ivr>
3
+	<flow Name="IVR_HX" Type="normal" MatchedNum="." MatchedLine="|-1|" Concurrency="1">
4
+		<cell Name="CELL_START" Pos="1" Next="2" Note="开始节点" />
5
+		<cell Name="CELL_SQL" Pos="2" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
6
+		SqlStr="INSERT INTO T_Call_CallRecords(CallId,CallNumber,CallType,CallState,DealType,BeginTime,IvrStartTime,IvrEndTime,EndTime,LongTime,IsDeal,OperateType,MYD) VALUES('%[CallID]','%[CallerID]',0,0,0,GETDATE(),GETDATE(),GETDATE(),GETDATE(),0,0,0,1)" 
7
+		IsSaved="no" SuccessPos="3" FailPos="3" Note="插入通话记录" />
8
+		<cell Name="CELL_DEFINEVAR" Pos="3" Next="4" Note="定义变量节点">
9
+			<DefVar VarType="1" VarName="AgentNo" VarVal="0" />
10
+			<DefVar VarType="1" VarName="AgentExtNo" VarVal="0" />
11
+			<DefVar VarType="1" VarName="KeyGroup" VarVal="0" /><!--坐席组按键值-->
12
+			<DefVar VarType="1" VarName="GroupID" VarVal="0" /><!--通过坐席组按键值 获取相应的坐席组ID-->
13
+			<DefVar VarType="1" VarName="Key" VarVal="0" />
14
+			<DefVar VarType="1" VarName="BlackListVerify" VarVal="0" />
15
+			<DefVar VarType="1" VarName="HolidayVerify" VarVal="0" />
16
+			<DefVar VarType="1" VarName="zbdh" VarVal="0" />
17
+			<DefVar VarType="1" VarName="AgentTel" VarVal="0" />
18
+		</cell>
19
+		<cell Name="CELL_SQL" Pos="4" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
20
+		SqlStr="select COUNT(*) FROM T_Call_Blacklist where F_TelPhone='%[CallerID]'" IsSaved="yes" SuccessPos="5" FailPos="5" Note="读取黑名单" />
21
+		<cell Name="CELL_RECORDSET" Pos="5" LPos="6" EPos="6" GPos="6" Note="取黑名单结果">
22
+			<Map Var="BlackListVerify" />
23
+		</cell>
24
+		<cell Name="CELL_COMPARE" Pos="6" Data1Type="2" Data2Type="1" Data3Type="1" Data1="BlackListVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="7" FalsePos="1201" Note="判断黑名单" />
25
+		<cell Name="CELL_SQL" Pos="7" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
26
+		SqlStr="update T_Call_CallRecords set CallState=1,DealType=1,IsDeal=1 where CallId='%[CallID]'" IsSaved="no" SuccessPos="26" FailPos="26" Note="黑名单通话记录" />
27
+		
28
+		<cell Name="CELL_AUDIODTMF" Pos="12" PlayType="2" ContentType="1" Content="D:\Midware\wav\欢迎词.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
29
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="8" FailPos="24" HangupPos="24" Note="放欢迎词" />
30
+		<!--
31
+			1.播放欢迎词-2.判断是否下班 是直接转入坐席,不是继续播报
32
+		-->
33
+		<!--
34
+		<cell Name="CELL_SQL" Pos="8" ConnStr="Provider=SQLOLEDB.1;Password=hykj800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZXZBNew;Data Source=192.168.4.18" 
35
+		SqlStr="SELECT count(*) FROM T_Sys_WorkCalendar WHERE getdate() between F_DateId and DATEADD(dd,1,F_DateId) AND F_WorkingFlag=1 AND Convert(varchar(20),getdate(),108)&gt;=Convert(varchar(20),'07:30:00',108) and Convert(varchar(20),getdate(),108)&lt;=Convert(varchar(20),'18:30:00',108)" 
36
+		IsSaved="yes" SuccessPos="9" FailPos="603" Note="节假日查询" />
37
+		<cell Name="CELL_RECORDSET" Pos="9" LPos="10" EPos="10" GPos="10" Note="取节假日结果">
38
+			<Map Var="HolidayVerify" />
39
+		</cell>
40
+		<cell Name="CELL_COMPARE" Pos="10" Data1Type="2" Data2Type="1" Data3Type="1" Data1="HolidayVerify" Data2="0" Data3="" VarType="1" CompareType="2" TruePos="603" FalsePos="11" Note="判断节假日" />
41
+		<cell Name="CELL_AUDIODTMF" Pos="11" PlayType="1" ContentType="1" Content="D:\Midware\wav\假期提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
42
+		TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="keyh" SuccessPos="24" FailPos="24" HangupPos="24" Note="放节假日音" />
43
+		-->
44
+		<!--根据不同的被叫号码获取对应的欢迎词-->
45
+		<cell Name="CELL_SQL" Pos="1201" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
46
+		SqlStr=" exec GetWelcomesByExtNo '%[CalleeID]'   " IsSaved="yes" SuccessPos="1202" FailPos="1202" Note="获取分机号对应的欢迎词文本" />
47
+		<cell Name="CELL_RECORDSET" Pos="1202" LPos="1203" EPos="1203" GPos="1203" Note="获取欢迎词文本">
48
+			<Map Var="ivrwords" />
49
+		</cell>
50
+		<cell Name="CELL_AUDIODTMF" Pos="1203" PlayType="2" ContentType="2" Content=" `vs40 您好,欢迎致电 `dig`vs30 %[ivrwords] `vs50 ." TTSNumMode="1" TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="603" FailPos="24" HangupPos="24" Note="播报欢迎词文本" />
51
+		<!--根据不同的被叫号码获取对应的欢迎词-->
52
+		
53
+		<!--通过按键值 拨打相应的坐席组-->
54
+		<cell Name="CELL_AUDIODTMF" Pos="601" PlayType="1" ContentType="1" Content=" D:\Midware\wav\主菜单.wav" TTSNumMode="1" 
55
+		TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="KeyGroup" SuccessPos="602" FailPos="24" HangupPos="24" Note="依据按键值拨打坐席组导航语音" />
56
+		<cell   Name="CELL_BRANCH"  Pos="602" Var="KeyGroup" DefaultPos="601" Note="依据按键值拨打坐席组导航语音-比较按键值" >
57
+			<Branch   Pos="603" Value="1" /><!--1.咨询-->
58
+			<Branch   Pos="603" Value="2" /><!--2.预约-->
59
+			<Branch   Pos="603" Value="3" /><!--3.救援-->
60
+			<Branch   Pos="603" Value="4" /><!--4.投诉-->
61
+		</cell>
62
+		
63
+		<cell Name="CELL_SQL" Pos="603" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
64
+		SqlStr="select top 1 F_ZXZID from T_Sys_SeatGroup where F_ZXZCode='ZXZ'" 
65
+		IsSaved="yes" SuccessPos="604" FailPos="24" Note="获取坐席组ID" />
66
+		<cell Name="CELL_RECORDSET" Pos="604" LPos="501" EPos="501" GPos="501" Note="获取坐席组ID结果">
67
+			<Map Var="GroupID" />
68
+		</cell>
69
+		
70
+		<cell Name="CELL_SQL" Pos="501" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
71
+		SqlStr=" update T_Call_CallRecords set BusinessType=%[KeyGroup], WaitStartTime=GETDATE() where callid='%[CallID]' " IsSaved="no" SuccessPos="13" FailPos="13" 
72
+		Note="更新排队开始时间" />
73
+		
74
+	
75
+		
76
+		<!--坐席排队时,没有登录坐席或无空闲直接转值班电话,无空闲坐席转坐席全忙放音,有空闲坐席继续播报-->
77
+		<cell Name="CELL_QUEUE" Pos="13" Strategy="11" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo" 
78
+		NoAgentPos="502" NoFreePos="502" SuccessPos="18" HangupPos="24" Note="排队节点" />
79
+		<!-- <cell Name="CELL_RECORDSET" Pos="505" LPos="502" EPos="502" GPos="502" Note="取AgentNo"> -->
80
+			<!-- <Map Var="CallID" /> -->
81
+		<!-- </cell> -->
82
+		<cell Name="CELL_SQL" Pos="502" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
83
+		SqlStr=" exec GetCallForwarding '%[CalleeID]'   " IsSaved="yes" SuccessPos="503" FailPos="503" Note="获取分机号对应的手机号码" />
84
+		<cell Name="CELL_RECORDSET" Pos="503" LPos="506" EPos="506" GPos="506" Note="获取转接手机号码">
85
+			<Map Var="iscall" />
86
+			<Map Var="AgentTel" />
87
+		</cell>
88
+		<cell Name="CELL_COMPARE" Pos="506" Data1Type="2" Data2Type="1" Data3Type="1" Data1="iscall" Data2="0" Data3="" VarType="1" CompareType="1" TruePos="14" FalsePos="507" Note="判断是否开启值班电话" />
89
+		<cell Name="CELL_COMPARE" Pos="507" Data1Type="2" Data2Type="1" Data3Type="1" Data1="AgentTel" Data2="" Data3="" VarType="3" CompareType="1" TruePos="14" FalsePos="509" Note="判断是否有值班电话" />
90
+		<cell Name="CELL_TRANSFEROUT" Pos="509" CalleeNumType="2" CalleeNum="AgentTel" Timeout="60" SuccessPos="25" FailPos="14" Note="转值班电话" />
91
+		
92
+		<!--坐席排队时,没有登录坐席直接转值班电话,无空闲坐席转坐席全忙放音,有空闲坐席继续播报-->
93
+		<!-- <cell Name="CELL_QUEUE" Pos="13" Strategy="11" VipLevelType="1" VipLevel="0" GroupType="2" Group="GroupID" AgentVar="AgentNo" ExtenVar="AgentExtNo"  -->
94
+		<!-- NoAgentPos="14" NoFreePos="14" SuccessPos="18" HangupPos="24" Note="排队节点" /> -->
95
+		
96
+		<cell Name="CELL_AUDIODTMF" Pos="14" PlayType="1" ContentType="1" Content="D:\Midware\wav\坐席全忙.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
97
+		TTSEngine="0" StopWhenDtmf="1" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="Key" SuccessPos="15" FailPos="24" HangupPos="24" Note="坐席全忙放音" />
98
+		<cell Name="CELL_BRANCH" Pos="15" Var="Key" DefaultPos="14" Note="分支节点">
99
+			<Branch Value="1" Pos="16" />
100
+			<!--<Branch Value="2" Pos="29" />-->
101
+		</cell>		
102
+		<cell Name="CELL_CONTINUEQUEUE" Pos="16" Agent="AgentNo" Exten="AgentExtNo" Audio="D:\Midware\wav\保持音.wav" Timeout="60" SuccessPos="18" HangupPos="24" TimeoutPos="14" Note="继续排队节点" />
103
+		<cell Name="CELL_CANCELQUEUE" Pos="17" Reason="等烦了" Next="24" Note="放弃排队节点" />		
104
+		<cell Name="CELL_AUDIODTMF" Pos="18" PlayType="2" ContentType="1" Content="D:\Midware\wav\通话录音提示音.wav" TTSNumMode="1" 
105
+		TTSSpeed="50" TTSVolume="50" TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="31" FailPos="24" HangupPos="24" Note="转接电话提示录音" />
106
+		<cell Name="CELL_AUDIODTMF" Pos="31" PlayType="2" ContentType="2" Content=" `vs40 您好,欢迎致电 `dig`vs30 %[ivrwords] `vs50 , `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="播报工号" />
107
+		<cell Name="CELL_TURNAGENT" Pos="19" Exten="AgentExtNo" SuccessPos="25" FailPos="17" HangupPos="24" Note="转座席节点">
108
+		  <BandData Var="CallID" />
109
+		</cell>
110
+		<cell Name="CELL_AUDIODTMF" Pos="20" PlayType="2" ContentType="1" Content="D:\Midware\wav\留言提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
111
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="21" FailPos="24" HangupPos="24" Note="留言开始放音" />
112
+		<cell Name="CELL_LEAVEWORD" Pos="21" Path="%[CallID]_%[CallerID]_%[StartTime].wav" FinishKey="#" Timeout="60" TimeoutPos="22" HangupPos="23" FinishPos="22" Note="留言节点" />
113
+		<cell Name="CELL_AUDIODTMF" Pos="22" PlayType="2" ContentType="1" Content="D:\Midware\wav\留言结束提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
114
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="23" FailPos="23" HangupPos="23" Note="留言结束放音" />
115
+		<cell Name="CELL_SQL" Pos="23" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" 
116
+		SqlStr="INSERT INTO T_Call_LeaveRecord(F_CallId,F_Phone,F_LeaveTime,F_Status,F_RecFileUrl) VALUES('%[CallID]','%[CallerID]',GETDATE(),0,'%[CallID]_%[CallerID]_%[StartTime].wav')" IsSaved="no" 
117
+		SuccessPos="24" FailPos="24" Note="留言入库" />
118
+		<cell Name="CELL_HANGUP" Pos="24" Next="25" Note="挂机节点" />
119
+		<cell Name="CELL_END" Pos="25" Note="结束节点" />	
120
+		
121
+		<!--黑名单提示音-->
122
+		<cell Name="CELL_AUDIODTMF" Pos="26" PlayType="2" ContentType="1" Content="D:\Midware\wav\黑名单提示音.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
123
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="3" FinishKey="#" KeyVar="" SuccessPos="25" FailPos="24" HangupPos="24" Note="黑名单提示音" />
124
+		<!--黑名单提示音-->
125
+		
126
+		<!--转值班电话-->
127
+		<cell   Name="CELL_BRANCH"  Pos="28" Var="keyh" DefaultPos="14" Note="是否转值班电话-比较按键值" >
128
+			<Branch   Pos="29" Value="1" />
129
+		</cell>
130
+		<cell Name="CELL_AUDIODTMF" Pos="29" PlayType="2" ContentType="1" Content="D:\Midware\wav\转值班电话提示.wav" TTSNumMode="1" TTSSpeed="50" TTSVolume="50" 
131
+		TTSEngine="0" StopWhenDtmf="2" MaxKeyCount="1" KeyPressInterval="0" FinishKey="#" KeyVar="" SuccessPos="701" FailPos="24" HangupPos="24" Note="转值班电话提示音" />
132
+		<cell Name="CELL_SQL" Pos="701" ConnStr="Provider=SQLOLEDB.1;Password=800100;Persist Security Info=True;User ID=sa;Initial Catalog=CallCenter_ZYKJ2;Data Source=192.168.4.18" SqlStr="EXEC proc_HR_ZZBDH " IsSaved="yes" SuccessPos="702" FailPos="24" Note="获取值班电话" />
133
+		<cell Name="CELL_RECORDSET" Pos="702" LPos="30" EPos="30" GPos="30" Note="获取值班电话结果">
134
+			<Map Var="zbdh" />
135
+		</cell>
136
+		<cell Name="CELL_TRANSFEROUT" Pos="30" CalleeNumType="2" CalleeNum="zbdh" Timeout="60" SuccessPos="25" FailPos="24" Note="转值班电话" />
137
+		<!--转值班电话-->
138
+	</flow>		
139
+</ivr>