kucservice 1.2.4 → 1.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8894,6 +8894,9 @@ var es_object_assign = __webpack_require__("cca6");
8894
8894
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.json.stringify.js
8895
8895
  var es_json_stringify = __webpack_require__("e9c4");
8896
8896
 
8897
+ // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.index-of.js
8898
+ var es_array_index_of = __webpack_require__("c975");
8899
+
8897
8900
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.for-each.js
8898
8901
  var es_array_for_each = __webpack_require__("4160");
8899
8902
 
@@ -8969,9 +8972,6 @@ var es_number_constructor = __webpack_require__("a9e3");
8969
8972
  // EXTERNAL MODULE: ./node_modules/core-js/modules/web.timers.js
8970
8973
  var web_timers = __webpack_require__("4795");
8971
8974
 
8972
- // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.index-of.js
8973
- var es_array_index_of = __webpack_require__("c975");
8974
-
8975
8975
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.test.js
8976
8976
  var es_regexp_test = __webpack_require__("00b4");
8977
8977
 
@@ -10058,6 +10058,7 @@ var phoneClient_j = /*#__PURE__*/function () {
10058
10058
 
10059
10059
 
10060
10060
 
10061
+
10061
10062
 
10062
10063
  /**
10063
10064
  * 接口请求通用方法
@@ -10105,7 +10106,7 @@ var initWsBaseTheme = function initWsBaseTheme(socket, _ref) {
10105
10106
  });
10106
10107
  };
10107
10108
 
10108
- var common_request_getH265PlayerObj = function getH265PlayerObj(rtcServe, doceProUrl, videoConfig) {
10109
+ var common_request_getH265PlayerObj = function getH265PlayerObj(rtcServe, doceProUrl, videoConfig, callBack) {
10109
10110
  var videoConfigdefault = {
10110
10111
  showBand: true,
10111
10112
  //网速显示
@@ -10125,6 +10126,7 @@ var common_request_getH265PlayerObj = function getH265PlayerObj(rtcServe, docePr
10125
10126
  }
10126
10127
 
10127
10128
  var h265Play = new h265({
10129
+ callBack: callBack,
10128
10130
  rtcServe: rtcServe,
10129
10131
  decUrl: doceProUrl || './decoder/decoder-pro.js',
10130
10132
  videoConfig: videoConfigdefault
@@ -10161,7 +10163,8 @@ var common_request_wsClass = /*#__PURE__*/function () {
10161
10163
  var _onOpen = _ref2.onOpen,
10162
10164
  _onClose = _ref2.onClose,
10163
10165
  _onMessage = _ref2.onMessage,
10164
- _onError = _ref2.onError;
10166
+ _onError = _ref2.onError,
10167
+ initAction = _ref2.initAction;
10165
10168
 
10166
10169
  Object(classCallCheck["a" /* default */])(this, wsClass);
10167
10170
 
@@ -10194,9 +10197,11 @@ var common_request_wsClass = /*#__PURE__*/function () {
10194
10197
  _onClose && _onClose(e);
10195
10198
  },
10196
10199
  onMessage: function onMessage(e) {
10197
- if (e.data === 'Back_Login') {
10200
+ if (e.data.indexOf('Back_Login(') === 0) {
10198
10201
  // 设置坐席
10199
- _this.config.AgentGroupName && _this.send("SetGroupRole", _this.config.AgentGroupName);
10202
+ _this.config.AgentGroupName && _this.send("SetGroupRole", _this.config.AgentGroupName); // 初始化操作
10203
+
10204
+ initAction && initAction();
10200
10205
  return;
10201
10206
  }
10202
10207
 
@@ -10218,10 +10223,10 @@ var common_request_wsClass = /*#__PURE__*/function () {
10218
10223
  }
10219
10224
  }, {
10220
10225
  key: "getPlayer",
10221
- value: function getPlayer(rtcServe, doceProUrl, videoConfig) {
10226
+ value: function getPlayer(rtcServe, doceProUrl, videoConfig, callBack) {
10222
10227
  if (_classPrivateFieldGet(this, _player)) return _classPrivateFieldGet(this, _player);
10223
10228
 
10224
- _classPrivateFieldSet(this, _player, common_request_getH265PlayerObj(rtcServe, doceProUrl, videoConfig));
10229
+ _classPrivateFieldSet(this, _player, common_request_getH265PlayerObj(rtcServe, doceProUrl, videoConfig, callBack));
10225
10230
 
10226
10231
  return _classPrivateFieldGet(this, _player);
10227
10232
  }
@@ -10263,13 +10268,15 @@ var useKUcservice = function useKUcservice(options, _ref3) {
10263
10268
  var onOpen = _ref3.onOpen,
10264
10269
  onClose = _ref3.onClose,
10265
10270
  onMessage = _ref3.onMessage,
10266
- onError = _ref3.onError;
10271
+ onError = _ref3.onError,
10272
+ initAction = _ref3.initAction;
10267
10273
  if (!window.WebSocket) return console.error('您的浏览器不支持WebSocket, 请更换浏览器!');
10268
10274
  return new common_request_wsClass(options, {
10269
10275
  onOpen: onOpen,
10270
10276
  onClose: onClose,
10271
10277
  onMessage: onMessage,
10272
- onError: onError
10278
+ onError: onError,
10279
+ initAction: initAction
10273
10280
  });
10274
10281
  };
10275
10282
  // CONCATENATED MODULE: ./index.js
Binary file