|
|
@@ -1056,21 +1056,33 @@ namespace YTSoft.BaseCallCenter.MVCWeb.Controllers
|
|
1056
|
1056
|
//工单类型 F_HOUSING select F_WORKORDERTYPEID,F_CONTENT,F_HOUSING from T_Wo_WorkOrderBase where 1=1 and F_CONTENT like '%'++'%'
|
|
1057
|
1057
|
|
|
1058
|
1058
|
|
|
1059
|
|
- if (F_WORKORDERTYPEID>0)
|
|
1060
|
|
- {
|
|
1061
|
|
- sql += " AND F_WorkOrderTypeId IS NOT null and F_WORKORDERTYPEID=" + F_WORKORDERTYPEID;
|
|
1062
|
|
- } //工单内容 F_CONTENT
|
|
1063
|
|
- if (!string.IsNullOrEmpty(F_CONTENT))
|
|
1064
|
|
- {
|
|
1065
|
|
- sql += string.Format(" AND F_WorkOrderTypeId IS NOT null and T2.F_CONTENT like '%{0}%'", F_CONTENT);
|
|
1066
|
|
- }
|
|
|
1059
|
+
|
|
1067
|
1060
|
//工单类型
|
|
1068
|
1061
|
if (!string.IsNullOrEmpty(F_HOUSING))
|
|
1069
|
1062
|
{
|
|
1070
|
|
- sql += string.Format(" AND F_WorkOrderTypeId IS NOT null and T2.F_HOUSING='{0}'", F_HOUSING);
|
|
|
1063
|
+ //sql += string.Format(" AND F_WorkOrderTypeId IS NOT null and T2.F_HOUSING='{0}'", F_HOUSING);
|
|
|
1064
|
+ string F_HOUSINGint = "0";
|
|
|
1065
|
+ switch (F_HOUSING)
|
|
|
1066
|
+ {
|
|
|
1067
|
+ case "咨询":
|
|
|
1068
|
+ F_HOUSINGint = "1";
|
|
|
1069
|
+ break;
|
|
|
1070
|
+ case "投诉":
|
|
|
1071
|
+ F_HOUSINGint = "2";
|
|
|
1072
|
+ break;
|
|
|
1073
|
+ case "建议":
|
|
|
1074
|
+ F_HOUSINGint = "3";
|
|
|
1075
|
+ break;
|
|
|
1076
|
+ case "表扬":
|
|
|
1077
|
+ F_HOUSINGint = "4";
|
|
|
1078
|
+ break;
|
|
|
1079
|
+ case "挂失":
|
|
|
1080
|
+ F_HOUSINGint = "5";
|
|
|
1081
|
+ break;
|
|
|
1082
|
+ }
|
|
|
1083
|
+ sql += string.Format("AND F_ServiceType={0} ", F_HOUSINGint);
|
|
1071
|
1084
|
}
|
|
1072
|
1085
|
|
|
1073
|
|
-
|
|
1074
|
1086
|
|
|
1075
|
1087
|
//呼叫状态,0:未接通电话1已接通电话
|
|
1076
|
1088
|
if (!string.IsNullOrEmpty(callStatus))
|
|
|
@@ -1083,11 +1095,45 @@ namespace YTSoft.BaseCallCenter.MVCWeb.Controllers
|
|
1083
|
1095
|
//BLL.T_Call_CallRecords busCall_CallRecords = new BLL.T_Call_CallRecords();
|
|
1084
|
1096
|
//busCall_CallRecords.GetListByPage();
|
|
1085
|
1097
|
Model.PageData<Model.T_Call_CallRecords_All> pageModel = new Model.PageData<Model.T_Call_CallRecords_All>();
|
|
1086
|
|
- dt = BLL.PagerBLL.GetTableList(
|
|
1087
|
|
- " (T_Call_CallRecords T1 LEFT JOIN T_Wo_WorkOrderBase T2 ON T1.CallId=T2.F_KSHADDRESSCODE ) ",
|
|
1088
|
|
- "CallRecordsId",
|
|
1089
|
|
- "T1.*,F_WORKORDERID,F_HOUSING,CONVERT(varchar,BeginTime, 120 ) as BeginTimeNew,CONVERT(varchar,TalkStartTime, 120 ) as TalkStartTimeNew,CONVERT(varchar,TalkEndTime, 120 ) as TalkEndTimeNew"
|
|
1090
|
|
- + @",(select top 1 F_ScaleResume from T_Cus_CustomerBase n where
|
|
|
1098
|
+// dt = BLL.PagerBLL.GetTableList(
|
|
|
1099
|
+// " (T_Call_CallRecords T1 LEFT JOIN T_Wo_WorkOrderBase T2 ON T1.CallId=T2.F_KSHADDRESSCODE ) ",
|
|
|
1100
|
+// "CallRecordsId",
|
|
|
1101
|
+// "T1.*,F_WORKORDERID,F_HOUSING,CONVERT(varchar,BeginTime, 120 ) as BeginTimeNew,CONVERT(varchar,TalkStartTime, 120 ) as TalkStartTimeNew,CONVERT(varchar,TalkEndTime, 120 ) as TalkEndTimeNew"
|
|
|
1102
|
+// + @",(select top 1 F_ScaleResume from T_Cus_CustomerBase n where
|
|
|
1103
|
+//CallNumber=F_Telephone) as F_ScaleResume,
|
|
|
1104
|
+//replace(replace(FilePath,'\','/'),'" + GetSysconfig("newFilePath") + "','" + GetSysconfig("newPlayPath") + "')" +
|
|
|
1105
|
+//@" as fileurl,case
|
|
|
1106
|
+// when BusinessType=1 then '咨询'
|
|
|
1107
|
+// when BusinessType=2 then '建议'
|
|
|
1108
|
+// when BusinessType=3 then '表扬'
|
|
|
1109
|
+// when BusinessType=4 then '挂失'
|
|
|
1110
|
+// when BusinessType=9 then '投诉'
|
|
|
1111
|
+
|
|
|
1112
|
+// when T1.F_ServiceType=1 then '咨询'
|
|
|
1113
|
+// when T1.F_ServiceType = 2 then '投诉'
|
|
|
1114
|
+// when T1.F_ServiceType = 3 then '建议'
|
|
|
1115
|
+// when T1.F_ServiceType = 4 then '表扬'
|
|
|
1116
|
+// when T1.F_ServiceType = 5 then '挂失'
|
|
|
1117
|
+// else '' end as
|
|
|
1118
|
+//BType, case when (isnull(BusinessType,0)>0 or isnull(T1.F_ServiceType,0)>0) then '人工服务' else '' end as ywtype ",
|
|
|
1119
|
+// sql,
|
|
|
1120
|
+// // "ORDER BY LongTime,CallRecordsId desc",
|
|
|
1121
|
+// string.IsNullOrEmpty(sort) ? " BeginTime desc": sort + " desc"
|
|
|
1122
|
+// ,
|
|
|
1123
|
+
|
|
|
1124
|
+// limit,
|
|
|
1125
|
+// page,
|
|
|
1126
|
+// out recordCount);
|
|
|
1127
|
+
|
|
|
1128
|
+
|
|
|
1129
|
+
|
|
|
1130
|
+ dt = BLL.PagerBLL.GetListPager(
|
|
|
1131
|
+ " T_Call_CallRecords ",
|
|
|
1132
|
+ "CallRecordsId",
|
|
|
1133
|
+ "*," +
|
|
|
1134
|
+ "(select top 1 F_WORKORDERID from T_Wo_WorkOrderBase where F_KSHADDRESSCODE=CallId) as F_WORKORDERID," +
|
|
|
1135
|
+ "CONVERT(varchar,BeginTime, 120 ) as BeginTimeNew,CONVERT(varchar,TalkStartTime, 120 ) as TalkStartTimeNew,CONVERT(varchar,TalkEndTime, 120 ) as TalkEndTimeNew"
|
|
|
1136
|
+ + @",(select top 1 F_ScaleResume from T_Cus_CustomerBase n where
|
|
1091
|
1137
|
CallNumber=F_Telephone) as F_ScaleResume,
|
|
1092
|
1138
|
replace(replace(FilePath,'\','/'),'" + GetSysconfig("newFilePath") + "','" + GetSysconfig("newPlayPath") + "')" +
|
|
1093
|
1139
|
@" as fileurl,case
|
|
|
@@ -1097,21 +1143,21 @@ replace(replace(FilePath,'\','/'),'" + GetSysconfig("newFilePath") + "','" + Get
|
|
1097
|
1143
|
when BusinessType=4 then '挂失'
|
|
1098
|
1144
|
when BusinessType=9 then '投诉'
|
|
1099
|
1145
|
|
|
1100
|
|
- when T1.F_ServiceType=1 then '咨询'
|
|
1101
|
|
- when T1.F_ServiceType = 2 then '投诉'
|
|
1102
|
|
- when T1.F_ServiceType = 3 then '建议'
|
|
1103
|
|
- when T1.F_ServiceType = 4 then '表扬'
|
|
1104
|
|
- when T1.F_ServiceType = 5 then '挂失'
|
|
|
1146
|
+ when F_ServiceType=1 then '咨询'
|
|
|
1147
|
+ when F_ServiceType = 2 then '投诉'
|
|
|
1148
|
+ when F_ServiceType = 3 then '建议'
|
|
|
1149
|
+ when F_ServiceType = 4 then '表扬'
|
|
|
1150
|
+ when F_ServiceType = 5 then '挂失'
|
|
1105
|
1151
|
else '' end as
|
|
1106
|
|
-BType, case when (isnull(BusinessType,0)>0 or isnull(T1.F_ServiceType,0)>0) then '人工服务' else '' end as ywtype ",
|
|
1107
|
|
- sql,
|
|
1108
|
|
- // "ORDER BY LongTime,CallRecordsId desc",
|
|
1109
|
|
- string.IsNullOrEmpty(sort) ? " BeginTime desc": sort + " desc"
|
|
1110
|
|
- ,
|
|
1111
|
|
-
|
|
1112
|
|
- limit,
|
|
1113
|
|
- page,
|
|
1114
|
|
- out recordCount);
|
|
|
1152
|
+ BType, case when (isnull(BusinessType,0)>0 or isnull(F_ServiceType,0)>0) then '人工服务' else '' end as ywtype ",
|
|
|
1153
|
+ sql,
|
|
|
1154
|
+ // "ORDER BY LongTime,CallRecordsId desc",
|
|
|
1155
|
+ string.IsNullOrEmpty(sort) ? "ORDER BY BeginTime desc" : "ORDER BY "+ sort + " desc"
|
|
|
1156
|
+ ,
|
|
|
1157
|
+ limit,
|
|
|
1158
|
+ page,
|
|
|
1159
|
+ true,
|
|
|
1160
|
+ out recordCount);
|
|
1115
|
1161
|
|
|
1116
|
1162
|
|
|
1117
|
1163
|
dataModel.code = 0;
|