bxs-tools-ui 2.0.4 → 2.0.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.
- package/lib/add-and-take/index.js +1301 -1231
- package/lib/adjust-baoe/index.js +1297 -1269
- package/lib/business-card/index.js +2 -2
- package/lib/bxs-utils/index.js +1292 -1253
- package/lib/canvas-poster/index.js +2 -2
- package/lib/index.js +1603 -1569
- package/lib/insure-calculate/index.js +1303 -1262
- package/lib/person-info/index.js +1298 -1259
- package/lib/product-info/index.js +694 -651
- package/package.json +1 -1
- package/packages/add-and-take/api.ts +2 -3
- package/packages/adjust-baoe/demo/index.vue +4 -14
- package/packages/adjust-baoe/index.vue +6 -30
- package/packages/bxs-utils/planbook/product.ts +12 -2
- package/packages/bxs-utils/trade/insureCalculate.js +3 -16
- package/packages/insure-calculate/demo/index.vue +1 -1
- package/packages/insure-calculate/index.vue +11 -40
- package/packages/person-info/demo/index.vue +3 -7
- package/packages/planbook-input/api.js +2 -1
- package/packages/planbook-input/components/product-table.vue +0 -1
- package/packages/planbook-input/helper.js +5 -11
- package/packages/planbook-input/index.vue +16 -20
- package/packages/product-info/demo/index.vue +4 -10
- package/packages/product-info/index.vue +2 -2
- package/src/js/variables.js +34 -8
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
var a = typeof exports === 'object' ? factory(require("vue"), require("vant")) : factory(root["Vue"], root["vant"]);
|
|
8
8
|
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
|
9
9
|
}
|
|
10
|
-
})(window, function(__WEBPACK_EXTERNAL_MODULE__5__,
|
|
10
|
+
})(window, function(__WEBPACK_EXTERNAL_MODULE__5__, __WEBPACK_EXTERNAL_MODULE__25__) {
|
|
11
11
|
return /******/ (function(modules) { // webpackBootstrap
|
|
12
12
|
/******/ // The module cache
|
|
13
13
|
/******/ var installedModules = {};
|
|
@@ -17873,7 +17873,7 @@ function formatNumberToThousand(n) {
|
|
|
17873
17873
|
else {}
|
|
17874
17874
|
}.call(this));
|
|
17875
17875
|
|
|
17876
|
-
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(
|
|
17876
|
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(26), __webpack_require__(38)(module)))
|
|
17877
17877
|
|
|
17878
17878
|
/***/ }),
|
|
17879
17879
|
/* 4 */,
|
|
@@ -17887,6 +17887,63 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__5__;
|
|
|
17887
17887
|
/* 7 */
|
|
17888
17888
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
17889
17889
|
|
|
17890
|
+
"use strict";
|
|
17891
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return IS_PRODUCT_ENV; });
|
|
17892
|
+
/* unused harmony export IS_DEVELOP_ENV */
|
|
17893
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return IS_LOCALHOST_ENV; });
|
|
17894
|
+
/* unused harmony export IS_UAT_ENV */
|
|
17895
|
+
/* unused harmony export IS_ENABLE_DEBUG */
|
|
17896
|
+
/* unused harmony export MAIN_DOMAIN */
|
|
17897
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return APP_HOSTNAME; });
|
|
17898
|
+
/* unused harmony export CONTENT_HOSTNAME */
|
|
17899
|
+
/* unused harmony export CLIENT_HOSTNAME */
|
|
17900
|
+
/* unused harmony export TOOL_API_HOSTNAME */
|
|
17901
|
+
/* unused harmony export INTERACTION_HOSTNAME */
|
|
17902
|
+
/* unused harmony export PBF_HOSTNAME */
|
|
17903
|
+
/* unused harmony export POLICY_INSPECTION_HOSTNAME */
|
|
17904
|
+
/* unused harmony export BROKER_HOSTNAME */
|
|
17905
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return PLANBOOK_API_HOSTNAME; });
|
|
17906
|
+
/* unused harmony export CRM_HOSTNAME */
|
|
17907
|
+
/* unused harmony export WX_HOSTNAME */
|
|
17908
|
+
/* unused harmony export URL_PARAM */
|
|
17909
|
+
/* unused harmony export getUrlParams */
|
|
17910
|
+
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(15);
|
|
17911
|
+
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(qs__WEBPACK_IMPORTED_MODULE_0__);
|
|
17912
|
+
|
|
17913
|
+
var hostname = window && window.location && window.location.hostname || '';
|
|
17914
|
+
var IS_PRODUCT_ENV = hostname.search(/(winbaoxian|ai-baoxiaozhu)\.com/) !== -1;
|
|
17915
|
+
var IS_DEVELOP_ENV = hostname.search(/(winbaoxian|ai-baoxiaozhu)\.cn/) !== -1;
|
|
17916
|
+
var IS_LOCALHOST_ENV = hostname.search(/localhost|192\.168|127\.0\.0\.1|dev\.winbaoxian\.cn/) !== -1;
|
|
17917
|
+
var IS_UAT_ENV = hostname.includes("pbf-uat.");
|
|
17918
|
+
var IS_ENABLE_DEBUG = !IS_PRODUCT_ENV;
|
|
17919
|
+
if (IS_ENABLE_DEBUG) {
|
|
17920
|
+
console.error("\u975E\u7EBF\u4E0A\u73AF\u5883\uFF0C\u9ED8\u8BA4\u5F00\u542F\u8C03\u8BD5\u6A21\u5F0F");
|
|
17921
|
+
}
|
|
17922
|
+
var topDomain = IS_PRODUCT_ENV ? 'com' : 'cn';
|
|
17923
|
+
var secondDomain = hostname.includes('ai-baoxiaozhu') ? 'ai-baoxiaozhu' : 'winbaoxian';
|
|
17924
|
+
var MAIN_DOMAIN = "".concat(secondDomain, ".").concat(topDomain);
|
|
17925
|
+
var APP_HOSTNAME = "https://app.".concat(MAIN_DOMAIN);
|
|
17926
|
+
var CONTENT_HOSTNAME = "https://content.".concat(MAIN_DOMAIN);
|
|
17927
|
+
var CLIENT_HOSTNAME = "https://client.".concat(MAIN_DOMAIN);
|
|
17928
|
+
var TOOL_API_HOSTNAME = "https://tool-api.".concat(MAIN_DOMAIN);
|
|
17929
|
+
var INTERACTION_HOSTNAME = "https://interaction-api.".concat(MAIN_DOMAIN);
|
|
17930
|
+
var PBF_HOSTNAME = "https://pbf.".concat(MAIN_DOMAIN);
|
|
17931
|
+
var POLICY_INSPECTION_HOSTNAME = "https://policy-inspection.".concat(MAIN_DOMAIN);
|
|
17932
|
+
var BROKER_HOSTNAME = "https://broker-2a.wyins.net".concat(IS_PRODUCT_ENV ? '' : '.cn');
|
|
17933
|
+
var PLANBOOK_API_HOSTNAME = "https://bxs-planbook-api".concat(IS_UAT_ENV ? '-uat' : '', ".").concat(MAIN_DOMAIN);
|
|
17934
|
+
var CRM_HOSTNAME = "https://wechat-crm.".concat(MAIN_DOMAIN);
|
|
17935
|
+
var WX_HOSTNAME = "https://wx.".concat(MAIN_DOMAIN);
|
|
17936
|
+
var URL_PARAM = getUrlParams();
|
|
17937
|
+
function getUrlParams(url) {
|
|
17938
|
+
var _url = url || location.search || '';
|
|
17939
|
+
var _searchStr = _url.split('?')[1];
|
|
17940
|
+
return _searchStr ? qs__WEBPACK_IMPORTED_MODULE_0___default.a.parse(_searchStr) : {};
|
|
17941
|
+
}
|
|
17942
|
+
|
|
17943
|
+
/***/ }),
|
|
17944
|
+
/* 8 */
|
|
17945
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
17946
|
+
|
|
17890
17947
|
"use strict";
|
|
17891
17948
|
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
|
|
17892
17949
|
/* globals __VUE_SSR_CONTEXT__ */
|
|
@@ -17988,8 +18045,8 @@ function normalizeComponent(
|
|
|
17988
18045
|
|
|
17989
18046
|
|
|
17990
18047
|
/***/ }),
|
|
17991
|
-
/*
|
|
17992
|
-
/*
|
|
18048
|
+
/* 9 */,
|
|
18049
|
+
/* 10 */
|
|
17993
18050
|
/***/ (function(module, exports, __webpack_require__) {
|
|
17994
18051
|
|
|
17995
18052
|
"use strict";
|
|
@@ -18000,7 +18057,7 @@ module.exports = TypeError;
|
|
|
18000
18057
|
|
|
18001
18058
|
|
|
18002
18059
|
/***/ }),
|
|
18003
|
-
/*
|
|
18060
|
+
/* 11 */
|
|
18004
18061
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
18005
18062
|
|
|
18006
18063
|
"use strict";
|
|
@@ -18268,7 +18325,7 @@ function restrictElementsInInsurance(_a) {
|
|
|
18268
18325
|
|
|
18269
18326
|
|
|
18270
18327
|
/***/ }),
|
|
18271
|
-
/*
|
|
18328
|
+
/* 12 */
|
|
18272
18329
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
18273
18330
|
|
|
18274
18331
|
"use strict";
|
|
@@ -18580,8 +18637,8 @@ function convertPersonData(allPersonsData, type) {
|
|
|
18580
18637
|
|
|
18581
18638
|
|
|
18582
18639
|
/***/ }),
|
|
18583
|
-
/*
|
|
18584
|
-
/*
|
|
18640
|
+
/* 13 */,
|
|
18641
|
+
/* 14 */
|
|
18585
18642
|
/***/ (function(module, exports) {
|
|
18586
18643
|
|
|
18587
18644
|
function _typeof(o) {
|
|
@@ -18596,7 +18653,25 @@ function _typeof(o) {
|
|
|
18596
18653
|
module.exports = _typeof, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
18597
18654
|
|
|
18598
18655
|
/***/ }),
|
|
18599
|
-
/*
|
|
18656
|
+
/* 15 */
|
|
18657
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
18658
|
+
|
|
18659
|
+
"use strict";
|
|
18660
|
+
|
|
18661
|
+
|
|
18662
|
+
var stringify = __webpack_require__(39);
|
|
18663
|
+
var parse = __webpack_require__(68);
|
|
18664
|
+
var formats = __webpack_require__(23);
|
|
18665
|
+
|
|
18666
|
+
module.exports = {
|
|
18667
|
+
formats: formats,
|
|
18668
|
+
parse: parse,
|
|
18669
|
+
stringify: stringify
|
|
18670
|
+
};
|
|
18671
|
+
|
|
18672
|
+
|
|
18673
|
+
/***/ }),
|
|
18674
|
+
/* 16 */
|
|
18600
18675
|
/***/ (function(module, exports, __webpack_require__) {
|
|
18601
18676
|
|
|
18602
18677
|
/* WEBPACK VAR INJECTION */(function(global) {var hasMap = typeof Map === 'function' && Map.prototype;
|
|
@@ -19144,10 +19219,10 @@ function arrObjKeys(obj, inspect) {
|
|
|
19144
19219
|
return xs;
|
|
19145
19220
|
}
|
|
19146
19221
|
|
|
19147
|
-
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(
|
|
19222
|
+
/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(26)))
|
|
19148
19223
|
|
|
19149
19224
|
/***/ }),
|
|
19150
|
-
/*
|
|
19225
|
+
/* 17 */
|
|
19151
19226
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19152
19227
|
|
|
19153
19228
|
"use strict";
|
|
@@ -19159,7 +19234,7 @@ module.exports = Function.prototype.bind || implementation;
|
|
|
19159
19234
|
|
|
19160
19235
|
|
|
19161
19236
|
/***/ }),
|
|
19162
|
-
/*
|
|
19237
|
+
/* 18 */
|
|
19163
19238
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19164
19239
|
|
|
19165
19240
|
// TODO(Babel 8): Remove this file.
|
|
@@ -19180,7 +19255,7 @@ try {
|
|
|
19180
19255
|
|
|
19181
19256
|
|
|
19182
19257
|
/***/ }),
|
|
19183
|
-
/*
|
|
19258
|
+
/* 19 */
|
|
19184
19259
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19185
19260
|
|
|
19186
19261
|
var toPropertyKey = __webpack_require__(118);
|
|
@@ -19195,7 +19270,7 @@ function _defineProperty(e, r, t) {
|
|
|
19195
19270
|
module.exports = _defineProperty, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
19196
19271
|
|
|
19197
19272
|
/***/ }),
|
|
19198
|
-
/*
|
|
19273
|
+
/* 20 */
|
|
19199
19274
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
19200
19275
|
|
|
19201
19276
|
"use strict";
|
|
@@ -19216,7 +19291,7 @@ module.exports = _defineProperty, module.exports.__esModule = true, module.expor
|
|
|
19216
19291
|
|
|
19217
19292
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "m", function() { return _common__WEBPACK_IMPORTED_MODULE_0__["h"]; });
|
|
19218
19293
|
|
|
19219
|
-
/* harmony import */ var _person__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(
|
|
19294
|
+
/* harmony import */ var _person__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(12);
|
|
19220
19295
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "e", function() { return _person__WEBPACK_IMPORTED_MODULE_1__["a"]; });
|
|
19221
19296
|
|
|
19222
19297
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "l", function() { return _person__WEBPACK_IMPORTED_MODULE_1__["b"]; });
|
|
@@ -19227,7 +19302,7 @@ module.exports = _defineProperty, module.exports.__esModule = true, module.expor
|
|
|
19227
19302
|
|
|
19228
19303
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "z", function() { return _person__WEBPACK_IMPORTED_MODULE_1__["e"]; });
|
|
19229
19304
|
|
|
19230
|
-
/* harmony import */ var _product__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(
|
|
19305
|
+
/* harmony import */ var _product__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(36);
|
|
19231
19306
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "b", function() { return _product__WEBPACK_IMPORTED_MODULE_2__["a"]; });
|
|
19232
19307
|
|
|
19233
19308
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "f", function() { return _product__WEBPACK_IMPORTED_MODULE_2__["b"]; });
|
|
@@ -19248,7 +19323,7 @@ module.exports = _defineProperty, module.exports.__esModule = true, module.expor
|
|
|
19248
19323
|
|
|
19249
19324
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "A", function() { return _product__WEBPACK_IMPORTED_MODULE_2__["j"]; });
|
|
19250
19325
|
|
|
19251
|
-
/* harmony import */ var _insurance__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(
|
|
19326
|
+
/* harmony import */ var _insurance__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(11);
|
|
19252
19327
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "n", function() { return _insurance__WEBPACK_IMPORTED_MODULE_3__["a"]; });
|
|
19253
19328
|
|
|
19254
19329
|
/* harmony reexport (safe) */ __webpack_require__.d(__webpack_exports__, "o", function() { return _insurance__WEBPACK_IMPORTED_MODULE_3__["b"]; });
|
|
@@ -19267,7 +19342,7 @@ if (document && document.cookie && document.cookie.match('LIZHAO_DEBUG_CONSOLE_F
|
|
|
19267
19342
|
|
|
19268
19343
|
|
|
19269
19344
|
/***/ }),
|
|
19270
|
-
/*
|
|
19345
|
+
/* 21 */
|
|
19271
19346
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19272
19347
|
|
|
19273
19348
|
"use strict";
|
|
@@ -19275,14 +19350,14 @@ if (document && document.cookie && document.cookie.match('LIZHAO_DEBUG_CONSOLE_F
|
|
|
19275
19350
|
|
|
19276
19351
|
var undefined;
|
|
19277
19352
|
|
|
19278
|
-
var $Object = __webpack_require__(
|
|
19353
|
+
var $Object = __webpack_require__(28);
|
|
19279
19354
|
|
|
19280
19355
|
var $Error = __webpack_require__(43);
|
|
19281
19356
|
var $EvalError = __webpack_require__(44);
|
|
19282
19357
|
var $RangeError = __webpack_require__(45);
|
|
19283
19358
|
var $ReferenceError = __webpack_require__(46);
|
|
19284
19359
|
var $SyntaxError = __webpack_require__(47);
|
|
19285
|
-
var $TypeError = __webpack_require__(
|
|
19360
|
+
var $TypeError = __webpack_require__(10);
|
|
19286
19361
|
var $URIError = __webpack_require__(48);
|
|
19287
19362
|
|
|
19288
19363
|
var abs = __webpack_require__(49);
|
|
@@ -19302,7 +19377,7 @@ var getEvalledConstructor = function (expressionSyntax) {
|
|
|
19302
19377
|
} catch (e) {}
|
|
19303
19378
|
};
|
|
19304
19379
|
|
|
19305
|
-
var $gOPD = __webpack_require__(
|
|
19380
|
+
var $gOPD = __webpack_require__(29);
|
|
19306
19381
|
var $defineProperty = __webpack_require__(58);
|
|
19307
19382
|
|
|
19308
19383
|
var throwTypeError = function () {
|
|
@@ -19328,11 +19403,11 @@ var ThrowTypeError = $gOPD
|
|
|
19328
19403
|
var hasSymbols = __webpack_require__(59)();
|
|
19329
19404
|
|
|
19330
19405
|
var getProto = __webpack_require__(61);
|
|
19331
|
-
var $ObjectGPO = __webpack_require__(
|
|
19332
|
-
var $ReflectGPO = __webpack_require__(
|
|
19406
|
+
var $ObjectGPO = __webpack_require__(31);
|
|
19407
|
+
var $ReflectGPO = __webpack_require__(30);
|
|
19333
19408
|
|
|
19334
|
-
var $apply = __webpack_require__(
|
|
19335
|
-
var $call = __webpack_require__(
|
|
19409
|
+
var $apply = __webpack_require__(33);
|
|
19410
|
+
var $call = __webpack_require__(22);
|
|
19336
19411
|
|
|
19337
19412
|
var needsEval = {};
|
|
19338
19413
|
|
|
@@ -19513,7 +19588,7 @@ var LEGACY_ALIASES = {
|
|
|
19513
19588
|
'%WeakSetPrototype%': ['WeakSet', 'prototype']
|
|
19514
19589
|
};
|
|
19515
19590
|
|
|
19516
|
-
var bind = __webpack_require__(
|
|
19591
|
+
var bind = __webpack_require__(17);
|
|
19517
19592
|
var hasOwn = __webpack_require__(66);
|
|
19518
19593
|
var $concat = bind.call($call, Array.prototype.concat);
|
|
19519
19594
|
var $spliceApply = bind.call($apply, Array.prototype.splice);
|
|
@@ -19652,7 +19727,7 @@ module.exports = function GetIntrinsic(name, allowMissing) {
|
|
|
19652
19727
|
|
|
19653
19728
|
|
|
19654
19729
|
/***/ }),
|
|
19655
|
-
/*
|
|
19730
|
+
/* 22 */
|
|
19656
19731
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19657
19732
|
|
|
19658
19733
|
"use strict";
|
|
@@ -19663,7 +19738,7 @@ module.exports = Function.prototype.call;
|
|
|
19663
19738
|
|
|
19664
19739
|
|
|
19665
19740
|
/***/ }),
|
|
19666
|
-
/*
|
|
19741
|
+
/* 23 */
|
|
19667
19742
|
/***/ (function(module, exports, __webpack_require__) {
|
|
19668
19743
|
|
|
19669
19744
|
"use strict";
|
|
@@ -19693,25 +19768,7 @@ module.exports = {
|
|
|
19693
19768
|
|
|
19694
19769
|
|
|
19695
19770
|
/***/ }),
|
|
19696
|
-
/*
|
|
19697
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
19698
|
-
|
|
19699
|
-
"use strict";
|
|
19700
|
-
|
|
19701
|
-
|
|
19702
|
-
var stringify = __webpack_require__(39);
|
|
19703
|
-
var parse = __webpack_require__(68);
|
|
19704
|
-
var formats = __webpack_require__(21);
|
|
19705
|
-
|
|
19706
|
-
module.exports = {
|
|
19707
|
-
formats: formats,
|
|
19708
|
-
parse: parse,
|
|
19709
|
-
stringify: stringify
|
|
19710
|
-
};
|
|
19711
|
-
|
|
19712
|
-
|
|
19713
|
-
/***/ }),
|
|
19714
|
-
/* 23 */
|
|
19771
|
+
/* 24 */
|
|
19715
19772
|
/***/ (function(module, exports) {
|
|
19716
19773
|
|
|
19717
19774
|
function asyncGeneratorStep(n, t, e, r, o, a, c) {
|
|
@@ -19742,13 +19799,13 @@ function _asyncToGenerator(n) {
|
|
|
19742
19799
|
module.exports = _asyncToGenerator, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
19743
19800
|
|
|
19744
19801
|
/***/ }),
|
|
19745
|
-
/*
|
|
19802
|
+
/* 25 */
|
|
19746
19803
|
/***/ (function(module, exports) {
|
|
19747
19804
|
|
|
19748
|
-
module.exports =
|
|
19805
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE__25__;
|
|
19749
19806
|
|
|
19750
19807
|
/***/ }),
|
|
19751
|
-
/*
|
|
19808
|
+
/* 26 */
|
|
19752
19809
|
/***/ (function(module, exports) {
|
|
19753
19810
|
|
|
19754
19811
|
var g;
|
|
@@ -19774,1234 +19831,1244 @@ module.exports = g;
|
|
|
19774
19831
|
|
|
19775
19832
|
|
|
19776
19833
|
/***/ }),
|
|
19777
|
-
/* 26 */,
|
|
19778
19834
|
/* 27 */
|
|
19779
|
-
/***/ (function(module,
|
|
19835
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19780
19836
|
|
|
19781
19837
|
"use strict";
|
|
19782
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return initProductData; });
|
|
19783
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return productDataHandler; });
|
|
19784
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getElementVerifyFromProductVerify; });
|
|
19785
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return setCommonInfo; });
|
|
19786
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return setGroupInsurance; });
|
|
19787
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return isHideProduct; });
|
|
19788
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "j", function() { return verifyProductRules; });
|
|
19789
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return restrictInsurancesInProduct; });
|
|
19790
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return convertProductData; });
|
|
19791
|
-
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return clearAddAndTakeAndAdjustBaoeData; });
|
|
19792
|
-
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
|
19793
|
-
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(22);
|
|
19794
|
-
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(qs__WEBPACK_IMPORTED_MODULE_1__);
|
|
19795
|
-
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
|
|
19796
|
-
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__);
|
|
19797
|
-
/* harmony import */ var _common__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1);
|
|
19798
|
-
/* harmony import */ var _person__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(11);
|
|
19799
|
-
/* harmony import */ var _insurance__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(10);
|
|
19800
19838
|
|
|
19801
19839
|
|
|
19840
|
+
var GetIntrinsic = __webpack_require__(21);
|
|
19841
|
+
var callBound = __webpack_require__(34);
|
|
19842
|
+
var inspect = __webpack_require__(16);
|
|
19843
|
+
|
|
19844
|
+
var $TypeError = __webpack_require__(10);
|
|
19845
|
+
var $Map = GetIntrinsic('%Map%', true);
|
|
19802
19846
|
|
|
19847
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => V} */
|
|
19848
|
+
var $mapGet = callBound('Map.prototype.get', true);
|
|
19849
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K, value: V) => void} */
|
|
19850
|
+
var $mapSet = callBound('Map.prototype.set', true);
|
|
19851
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => boolean} */
|
|
19852
|
+
var $mapHas = callBound('Map.prototype.has', true);
|
|
19853
|
+
/** @type {<K, V>(thisArg: Map<K, V>, key: K) => boolean} */
|
|
19854
|
+
var $mapDelete = callBound('Map.prototype.delete', true);
|
|
19855
|
+
/** @type {<K, V>(thisArg: Map<K, V>) => number} */
|
|
19856
|
+
var $mapSize = callBound('Map.prototype.size', true);
|
|
19803
19857
|
|
|
19858
|
+
/** @type {import('.')} */
|
|
19859
|
+
module.exports = !!$Map && /** @type {Exclude<import('.'), false>} */ function getSideChannelMap() {
|
|
19860
|
+
/** @typedef {ReturnType<typeof getSideChannelMap>} Channel */
|
|
19861
|
+
/** @typedef {Parameters<Channel['get']>[0]} K */
|
|
19862
|
+
/** @typedef {Parameters<Channel['set']>[1]} V */
|
|
19804
19863
|
|
|
19864
|
+
/** @type {Map<K, V> | undefined} */ var $m;
|
|
19805
19865
|
|
|
19806
|
-
|
|
19807
|
-
|
|
19808
|
-
|
|
19809
|
-
|
|
19810
|
-
|
|
19811
|
-
|
|
19812
|
-
|
|
19813
|
-
|
|
19814
|
-
|
|
19815
|
-
|
|
19816
|
-
|
|
19817
|
-
|
|
19818
|
-
|
|
19819
|
-
|
|
19866
|
+
/** @type {Channel} */
|
|
19867
|
+
var channel = {
|
|
19868
|
+
assert: function (key) {
|
|
19869
|
+
if (!channel.has(key)) {
|
|
19870
|
+
throw new $TypeError('Side channel does not contain ' + inspect(key));
|
|
19871
|
+
}
|
|
19872
|
+
},
|
|
19873
|
+
'delete': function (key) {
|
|
19874
|
+
if ($m) {
|
|
19875
|
+
var result = $mapDelete($m, key);
|
|
19876
|
+
if ($mapSize($m) === 0) {
|
|
19877
|
+
$m = void undefined;
|
|
19878
|
+
}
|
|
19879
|
+
return result;
|
|
19880
|
+
}
|
|
19881
|
+
return false;
|
|
19882
|
+
},
|
|
19883
|
+
get: function (key) { // eslint-disable-line consistent-return
|
|
19884
|
+
if ($m) {
|
|
19885
|
+
return $mapGet($m, key);
|
|
19886
|
+
}
|
|
19887
|
+
},
|
|
19888
|
+
has: function (key) {
|
|
19889
|
+
if ($m) {
|
|
19890
|
+
return $mapHas($m, key);
|
|
19891
|
+
}
|
|
19892
|
+
return false;
|
|
19893
|
+
},
|
|
19894
|
+
set: function (key, value) {
|
|
19895
|
+
if (!$m) {
|
|
19896
|
+
// @ts-expect-error TS can't handle narrowing a variable inside a closure
|
|
19897
|
+
$m = new $Map();
|
|
19898
|
+
}
|
|
19899
|
+
$mapSet($m, key, value);
|
|
19900
|
+
}
|
|
19901
|
+
};
|
|
19902
|
+
|
|
19903
|
+
// @ts-expect-error TODO: figure out why TS is erroring here
|
|
19904
|
+
return channel;
|
|
19905
|
+
};
|
|
19906
|
+
|
|
19907
|
+
|
|
19908
|
+
/***/ }),
|
|
19909
|
+
/* 28 */
|
|
19910
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19911
|
+
|
|
19912
|
+
"use strict";
|
|
19913
|
+
|
|
19914
|
+
|
|
19915
|
+
/** @type {import('.')} */
|
|
19916
|
+
module.exports = Object;
|
|
19917
|
+
|
|
19918
|
+
|
|
19919
|
+
/***/ }),
|
|
19920
|
+
/* 29 */
|
|
19921
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19922
|
+
|
|
19923
|
+
"use strict";
|
|
19924
|
+
|
|
19925
|
+
|
|
19926
|
+
/** @type {import('.')} */
|
|
19927
|
+
var $gOPD = __webpack_require__(57);
|
|
19928
|
+
|
|
19929
|
+
if ($gOPD) {
|
|
19930
|
+
try {
|
|
19931
|
+
$gOPD([], 'length');
|
|
19932
|
+
} catch (e) {
|
|
19933
|
+
// IE 8 has a broken gOPD
|
|
19934
|
+
$gOPD = null;
|
|
19935
|
+
}
|
|
19820
19936
|
}
|
|
19821
|
-
|
|
19822
|
-
|
|
19823
|
-
|
|
19824
|
-
|
|
19825
|
-
|
|
19826
|
-
|
|
19827
|
-
|
|
19828
|
-
|
|
19829
|
-
|
|
19830
|
-
|
|
19831
|
-
|
|
19832
|
-
|
|
19833
|
-
|
|
19834
|
-
|
|
19835
|
-
|
|
19836
|
-
|
|
19837
|
-
|
|
19838
|
-
|
|
19839
|
-
|
|
19840
|
-
|
|
19841
|
-
|
|
19842
|
-
|
|
19843
|
-
|
|
19844
|
-
|
|
19845
|
-
|
|
19846
|
-
|
|
19847
|
-
|
|
19848
|
-
|
|
19849
|
-
|
|
19850
|
-
|
|
19851
|
-
|
|
19852
|
-
|
|
19853
|
-
|
|
19854
|
-
|
|
19855
|
-
|
|
19856
|
-
|
|
19857
|
-
|
|
19858
|
-
|
|
19859
|
-
|
|
19860
|
-
|
|
19861
|
-
|
|
19862
|
-
|
|
19863
|
-
|
|
19864
|
-
|
|
19865
|
-
|
|
19866
|
-
|
|
19867
|
-
|
|
19868
|
-
|
|
19869
|
-
|
|
19870
|
-
|
|
19871
|
-
|
|
19872
|
-
|
|
19873
|
-
|
|
19874
|
-
|
|
19875
|
-
|
|
19876
|
-
|
|
19877
|
-
|
|
19878
|
-
|
|
19879
|
-
|
|
19880
|
-
|
|
19881
|
-
|
|
19882
|
-
|
|
19883
|
-
|
|
19884
|
-
|
|
19885
|
-
|
|
19886
|
-
|
|
19887
|
-
|
|
19888
|
-
|
|
19889
|
-
|
|
19890
|
-
|
|
19891
|
-
|
|
19892
|
-
|
|
19893
|
-
|
|
19894
|
-
|
|
19895
|
-
|
|
19896
|
-
|
|
19897
|
-
|
|
19898
|
-
|
|
19899
|
-
|
|
19900
|
-
|
|
19901
|
-
|
|
19902
|
-
|
|
19903
|
-
|
|
19904
|
-
|
|
19905
|
-
|
|
19906
|
-
|
|
19907
|
-
|
|
19908
|
-
|
|
19909
|
-
|
|
19910
|
-
|
|
19911
|
-
|
|
19912
|
-
|
|
19913
|
-
|
|
19914
|
-
|
|
19915
|
-
|
|
19916
|
-
|
|
19917
|
-
|
|
19918
|
-
|
|
19919
|
-
|
|
19920
|
-
|
|
19921
|
-
|
|
19922
|
-
|
|
19923
|
-
|
|
19924
|
-
refInsData = insList[0].key === 'common' ? insList[1] : insList[0];
|
|
19925
|
-
}
|
|
19926
|
-
else {
|
|
19927
|
-
refInsData = insList.find(function (ins) { return ins.key == ins.refInsuranceId; });
|
|
19928
|
-
}
|
|
19929
|
-
var refEleData = refInsData && refInsData.eleOrderList && refInsData.eleOrderList.find(function (e) { return e.key === eleData.key; });
|
|
19930
|
-
if (refEleData) {
|
|
19931
|
-
if (ins.huomian && eleData.key == 'pPeriod') {
|
|
19932
|
-
eleData.value = Object(_common__WEBPACK_IMPORTED_MODULE_3__[/* getHuomianPeriodValue */ "g"])(refEleData.value, ins.pMinus, ins.huomian === 'touHuomian' ? insuredInfo.age : targetPerson.age);
|
|
19933
|
-
}
|
|
19934
|
-
else {
|
|
19935
|
-
eleData.value = refEleData.value;
|
|
19936
|
-
}
|
|
19937
|
-
}
|
|
19938
|
-
else {
|
|
19939
|
-
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
19940
|
-
console.log("".concat(ins.name, "-").concat(ins.key, "\uFF1A\u5173\u8054\u9669\u79CD").concat(ins.refInsuranceId, "\u4E0D\u5B58\u5728"));
|
|
19941
|
-
}
|
|
19942
|
-
}
|
|
19943
|
-
}
|
|
19944
|
-
else {
|
|
19945
|
-
var backupOpts_1 = eleData.opts && eleData.opts.length ? eleData.opts.slice(0) : [];
|
|
19946
|
-
eleData.opts = eleCondi.filter(function (c) { return c.value !== undefined && c.desc !== undefined; }).map(function (c) {
|
|
19947
|
-
var option = backupOpts_1.find(function (o) { return o.val == c.value; });
|
|
19948
|
-
return {
|
|
19949
|
-
val: c.value,
|
|
19950
|
-
desc: c.desc || c.value,
|
|
19951
|
-
isHide: (option && option.isHide) || null,
|
|
19952
|
-
isDisabled: (option && option.isDisabled) || null,
|
|
19953
|
-
isInvalid: null
|
|
19954
|
-
};
|
|
19955
|
-
});
|
|
19956
|
-
var isNoOption = eleData.opts && eleData.opts.length && eleData.opts.every(function (ele) { return ele.val != eleData.value; });
|
|
19957
|
-
if (isNoOption) {
|
|
19958
|
-
if (eleData.key === 'pPeriod') {
|
|
19959
|
-
var filterOpts = (_c = eleData.opts) === null || _c === void 0 ? void 0 : _c.filter(function (opt) { return !opt.isHide && !opt.isDisabled; });
|
|
19960
|
-
if (filterOpts && filterOpts.length) {
|
|
19961
|
-
eleData.value = filterOpts[filterOpts.length - 1].val;
|
|
19962
|
-
}
|
|
19963
|
-
}
|
|
19964
|
-
else {
|
|
19965
|
-
if (eleData.opts && eleData.opts.length) {
|
|
19966
|
-
eleData.value = eleData.opts[0].val;
|
|
19967
|
-
}
|
|
19968
|
-
}
|
|
19969
|
-
}
|
|
19970
|
-
}
|
|
19971
|
-
curCondition = eleCondi.find(function (eleCondi) { return eleCondi.value == eleData.value; });
|
|
19972
|
-
var eleIndex = ins.eleOrderList.findIndex(function (ele) { return ele.key === eleData.key; });
|
|
19973
|
-
var prevElement;
|
|
19974
|
-
if (eleIndex >= 1) {
|
|
19975
|
-
prevElement = ins.eleOrderList[eleIndex - 1];
|
|
19976
|
-
}
|
|
19977
|
-
if (prevElement) {
|
|
19978
|
-
if (!curCondition) {
|
|
19979
|
-
var prevEleVerify = getElementVerifyFromProductVerify(personCondition, insList, { insuranceKey: ins.key, elementKey: prevElement.key });
|
|
19980
|
-
var onePrevEleVerify = prevEleVerify === null || prevEleVerify === void 0 ? void 0 : prevEleVerify.find(function (v) { return v[eleData.key] && v[eleData.key].some(function (condi) { return condi.value === eleData.value; }); });
|
|
19981
|
-
if (onePrevEleVerify) {
|
|
19982
|
-
prevElement.value = onePrevEleVerify.value;
|
|
19983
|
-
curCondition = onePrevEleVerify[eleData.key];
|
|
19984
|
-
}
|
|
19985
|
-
}
|
|
19986
|
-
if (!curCondition) {
|
|
19987
|
-
eleTitle.isDisabled = true;
|
|
19988
|
-
eleTitle.value = false;
|
|
19989
|
-
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
19990
|
-
console.log("".concat(eleTitle.labelName, "-").concat(ins.key, ": \u8D39\u7387\u4E0D\u5B58\u5728\uFF01"));
|
|
19991
|
-
}
|
|
19992
|
-
}
|
|
19993
|
-
var isNeedReverseFilter = eleData.isHide && !eleData.isDisabled && prevElement.opts && prevElement.opts.length;
|
|
19994
|
-
if (isNeedReverseFilter) {
|
|
19995
|
-
var prevEleVerify = getElementVerifyFromProductVerify(personCondition, insList, { insuranceKey: ins.key, elementKey: prevElement.key });
|
|
19996
|
-
if (prevEleVerify) {
|
|
19997
|
-
prevElement.opts = prevEleVerify.filter(function (v) {
|
|
19998
|
-
var _a;
|
|
19999
|
-
var elementVerify = getElementVerifyFromProductVerify(personCondition, insList, (_a = {
|
|
20000
|
-
insuranceKey: ins.key,
|
|
20001
|
-
elementKey: eleData.key
|
|
20002
|
-
},
|
|
20003
|
-
_a[prevElement.key] = v.value,
|
|
20004
|
-
_a));
|
|
20005
|
-
return elementVerify && elementVerify.some(function (c) { return c.value == eleData.value; });
|
|
20006
|
-
}).map(function (v) { return ({
|
|
20007
|
-
val: v.value,
|
|
20008
|
-
desc: v.desc || v.value,
|
|
20009
|
-
isHide: null,
|
|
20010
|
-
isDisabled: null,
|
|
20011
|
-
isInvalid: null
|
|
20012
|
-
}); });
|
|
20013
|
-
}
|
|
20014
|
-
}
|
|
20015
|
-
}
|
|
20016
|
-
};
|
|
20017
|
-
do {
|
|
20018
|
-
var state_1 = _loop_1();
|
|
20019
|
-
if (state_1 === "break")
|
|
20020
|
-
break;
|
|
20021
|
-
} while (curCondition && curCondition.key && curCondition[curCondition.key]);
|
|
20022
|
-
});
|
|
20023
|
-
}
|
|
20024
|
-
setGroupInsurance(prodData);
|
|
20025
|
-
isHideProduct(prodData, productVerifyData, personOrderList);
|
|
20026
|
-
return [2, prodData];
|
|
20027
|
-
}
|
|
20028
|
-
});
|
|
20029
|
-
});
|
|
20030
|
-
}
|
|
20031
|
-
function multipleInsuredHandler(personData) {
|
|
20032
|
-
var personOrderList = personData.personOrderList;
|
|
20033
|
-
if (!(personOrderList && personOrderList.length)) {
|
|
20034
|
-
return null;
|
|
19937
|
+
|
|
19938
|
+
module.exports = $gOPD;
|
|
19939
|
+
|
|
19940
|
+
|
|
19941
|
+
/***/ }),
|
|
19942
|
+
/* 30 */
|
|
19943
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19944
|
+
|
|
19945
|
+
"use strict";
|
|
19946
|
+
|
|
19947
|
+
|
|
19948
|
+
/** @type {import('./Reflect.getPrototypeOf')} */
|
|
19949
|
+
module.exports = (typeof Reflect !== 'undefined' && Reflect.getPrototypeOf) || null;
|
|
19950
|
+
|
|
19951
|
+
|
|
19952
|
+
/***/ }),
|
|
19953
|
+
/* 31 */
|
|
19954
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19955
|
+
|
|
19956
|
+
"use strict";
|
|
19957
|
+
|
|
19958
|
+
|
|
19959
|
+
var $Object = __webpack_require__(28);
|
|
19960
|
+
|
|
19961
|
+
/** @type {import('./Object.getPrototypeOf')} */
|
|
19962
|
+
module.exports = $Object.getPrototypeOf || null;
|
|
19963
|
+
|
|
19964
|
+
|
|
19965
|
+
/***/ }),
|
|
19966
|
+
/* 32 */
|
|
19967
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19968
|
+
|
|
19969
|
+
"use strict";
|
|
19970
|
+
|
|
19971
|
+
|
|
19972
|
+
var bind = __webpack_require__(17);
|
|
19973
|
+
var $TypeError = __webpack_require__(10);
|
|
19974
|
+
|
|
19975
|
+
var $call = __webpack_require__(22);
|
|
19976
|
+
var $actualApply = __webpack_require__(64);
|
|
19977
|
+
|
|
19978
|
+
/** @type {(args: [Function, thisArg?: unknown, ...args: unknown[]]) => Function} TODO FIXME, find a way to use import('.') */
|
|
19979
|
+
module.exports = function callBindBasic(args) {
|
|
19980
|
+
if (args.length < 1 || typeof args[0] !== 'function') {
|
|
19981
|
+
throw new $TypeError('a function is required');
|
|
19982
|
+
}
|
|
19983
|
+
return $actualApply(bind, $call, args);
|
|
19984
|
+
};
|
|
19985
|
+
|
|
19986
|
+
|
|
19987
|
+
/***/ }),
|
|
19988
|
+
/* 33 */
|
|
19989
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
19990
|
+
|
|
19991
|
+
"use strict";
|
|
19992
|
+
|
|
19993
|
+
|
|
19994
|
+
/** @type {import('./functionApply')} */
|
|
19995
|
+
module.exports = Function.prototype.apply;
|
|
19996
|
+
|
|
19997
|
+
|
|
19998
|
+
/***/ }),
|
|
19999
|
+
/* 34 */
|
|
20000
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
20001
|
+
|
|
20002
|
+
"use strict";
|
|
20003
|
+
|
|
20004
|
+
|
|
20005
|
+
var GetIntrinsic = __webpack_require__(21);
|
|
20006
|
+
|
|
20007
|
+
var callBindBasic = __webpack_require__(32);
|
|
20008
|
+
|
|
20009
|
+
/** @type {(thisArg: string, searchString: string, position?: number) => number} */
|
|
20010
|
+
var $indexOf = callBindBasic([GetIntrinsic('%String.prototype.indexOf%')]);
|
|
20011
|
+
|
|
20012
|
+
/** @type {import('.')} */
|
|
20013
|
+
module.exports = function callBoundIntrinsic(name, allowMissing) {
|
|
20014
|
+
/* eslint no-extra-parens: 0 */
|
|
20015
|
+
|
|
20016
|
+
var intrinsic = /** @type {(this: unknown, ...args: unknown[]) => unknown} */ (GetIntrinsic(name, !!allowMissing));
|
|
20017
|
+
if (typeof intrinsic === 'function' && $indexOf(name, '.prototype.') > -1) {
|
|
20018
|
+
return callBindBasic(/** @type {const} */ ([intrinsic]));
|
|
20019
|
+
}
|
|
20020
|
+
return intrinsic;
|
|
20021
|
+
};
|
|
20022
|
+
|
|
20023
|
+
|
|
20024
|
+
/***/ }),
|
|
20025
|
+
/* 35 */
|
|
20026
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
20027
|
+
|
|
20028
|
+
"use strict";
|
|
20029
|
+
|
|
20030
|
+
|
|
20031
|
+
var formats = __webpack_require__(23);
|
|
20032
|
+
|
|
20033
|
+
var has = Object.prototype.hasOwnProperty;
|
|
20034
|
+
var isArray = Array.isArray;
|
|
20035
|
+
|
|
20036
|
+
var hexTable = (function () {
|
|
20037
|
+
var array = [];
|
|
20038
|
+
for (var i = 0; i < 256; ++i) {
|
|
20039
|
+
array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
|
|
20035
20040
|
}
|
|
20036
|
-
|
|
20037
|
-
|
|
20038
|
-
|
|
20039
|
-
|
|
20040
|
-
|
|
20041
|
-
|
|
20042
|
-
|
|
20043
|
-
|
|
20044
|
-
|
|
20045
|
-
|
|
20046
|
-
|
|
20047
|
-
|
|
20041
|
+
|
|
20042
|
+
return array;
|
|
20043
|
+
}());
|
|
20044
|
+
|
|
20045
|
+
var compactQueue = function compactQueue(queue) {
|
|
20046
|
+
while (queue.length > 1) {
|
|
20047
|
+
var item = queue.pop();
|
|
20048
|
+
var obj = item.obj[item.prop];
|
|
20049
|
+
|
|
20050
|
+
if (isArray(obj)) {
|
|
20051
|
+
var compacted = [];
|
|
20052
|
+
|
|
20053
|
+
for (var j = 0; j < obj.length; ++j) {
|
|
20054
|
+
if (typeof obj[j] !== 'undefined') {
|
|
20055
|
+
compacted.push(obj[j]);
|
|
20048
20056
|
}
|
|
20049
|
-
}
|
|
20050
|
-
|
|
20051
|
-
|
|
20052
|
-
}
|
|
20053
|
-
return personData;
|
|
20054
|
-
}
|
|
20055
|
-
function getSingleInsurancesVerifyData(prodData, personData, parmas) {
|
|
20056
|
-
var _a, _b;
|
|
20057
|
-
if (parmas === void 0) { parmas = {}; }
|
|
20058
|
-
var personOrderList = personData.personOrderList;
|
|
20059
|
-
if (!(personOrderList && personOrderList.length)) {
|
|
20060
|
-
return null;
|
|
20061
|
-
}
|
|
20062
|
-
var pbId = prodData.isTemp || (prodData.policyType === 'single_insurance') ? null : parmas.planbookId;
|
|
20063
|
-
var productId = prodData.policyType === 'single_insurance' ? null : prodData.key;
|
|
20064
|
-
var insuredList = personOrderList
|
|
20065
|
-
.filter(function (p) { return ['insuredInfo', 'insured2Info'].includes(p.key) && p.eleOrderList; })
|
|
20066
|
-
.filter(function (p) {
|
|
20067
|
-
var _a;
|
|
20068
|
-
var title = (_a = p.eleOrderList) === null || _a === void 0 ? void 0 : _a.find(function (e) { return e.key === 'title'; });
|
|
20069
|
-
return title && title.value;
|
|
20070
|
-
})
|
|
20071
|
-
.map(function (p) {
|
|
20072
|
-
var _a, _b;
|
|
20073
|
-
return {
|
|
20074
|
-
key: p.key,
|
|
20075
|
-
sex: (_a = (p.eleOrderList || []).find(function (e) { return e.key === 'sex'; })) === null || _a === void 0 ? void 0 : _a.value,
|
|
20076
|
-
age: (_b = (p.eleOrderList || []).find(function (e) { return e.key === 'age'; })) === null || _b === void 0 ? void 0 : _b.value
|
|
20077
|
-
};
|
|
20078
|
-
});
|
|
20079
|
-
var insuranceIdList = (_a = convertProductData(prodData).mulInsOrderList) === null || _a === void 0 ? void 0 : _a.map(function (ins) { return ins.key; });
|
|
20080
|
-
(_b = prodData === null || prodData === void 0 ? void 0 : prodData.mulInsOrderList) === null || _b === void 0 ? void 0 : _b.reduce(function (list, ins) {
|
|
20081
|
-
return ins.key === 'common' || ins.isGroup ? list : list.concat(ins.key);
|
|
20082
|
-
}, []);
|
|
20083
|
-
return getAndCacheInsurancesVerifyData({
|
|
20084
|
-
pbId: pbId,
|
|
20085
|
-
productId: productId,
|
|
20086
|
-
insuredList: insuredList,
|
|
20087
|
-
insuranceIdList: insuranceIdList
|
|
20088
|
-
});
|
|
20089
|
-
}
|
|
20090
|
-
var getAndCacheInsurancesVerifyData = Object(lodash__WEBPACK_IMPORTED_MODULE_2__["memoize"])(function (params) {
|
|
20091
|
-
var IS_PRODUCT_ENV = location.hostname.search(/winbaoxian\.com/) !== -1;
|
|
20092
|
-
var url = "https://app.winbaoxian.".concat(IS_PRODUCT_ENV ? 'com' : 'cn', "/planBook/input/insurance/verifyData");
|
|
20093
|
-
return fetch(url, {
|
|
20094
|
-
method: 'POST',
|
|
20095
|
-
credentials: 'include',
|
|
20096
|
-
headers: {
|
|
20097
|
-
Accept: 'application/json, text/plain, */*',
|
|
20098
|
-
'Content-Type': 'application/json;'
|
|
20099
|
-
},
|
|
20100
|
-
body: JSON.stringify(params)
|
|
20101
|
-
})
|
|
20102
|
-
.then(function (response) { return response.json(); })
|
|
20103
|
-
.then(function (_a) {
|
|
20104
|
-
var success = _a.success, data = _a.data;
|
|
20105
|
-
if (!success || !data) {
|
|
20106
|
-
return Promise.reject();
|
|
20057
|
+
}
|
|
20058
|
+
|
|
20059
|
+
item.obj[item.prop] = compacted;
|
|
20107
20060
|
}
|
|
20108
|
-
return Promise.resolve(data);
|
|
20109
|
-
})
|
|
20110
|
-
.catch(function () { });
|
|
20111
|
-
}, function (params) { return qs__WEBPACK_IMPORTED_MODULE_1___default.a.stringify(params); });
|
|
20112
|
-
function getElementVerifyFromProductVerify(verify, insurances, option) {
|
|
20113
|
-
if (!verify || !verify.key || !verify[verify.key] || !insurances || !option) {
|
|
20114
|
-
return verify;
|
|
20115
20061
|
}
|
|
20116
|
-
|
|
20117
|
-
|
|
20118
|
-
|
|
20119
|
-
|
|
20120
|
-
|
|
20121
|
-
|
|
20122
|
-
|
|
20123
|
-
var temp = verify;
|
|
20124
|
-
var hasElementKey = verify.key === option.elementKey;
|
|
20125
|
-
while (temp && temp.key && temp.key !== option.elementKey) {
|
|
20126
|
-
temp = temp[temp.key].find(function (v) { return v.value == insuranceInfo[temp.key]; });
|
|
20127
|
-
if (temp && temp.key === option.elementKey) {
|
|
20128
|
-
hasElementKey = true;
|
|
20062
|
+
};
|
|
20063
|
+
|
|
20064
|
+
var arrayToObject = function arrayToObject(source, options) {
|
|
20065
|
+
var obj = options && options.plainObjects ? { __proto__: null } : {};
|
|
20066
|
+
for (var i = 0; i < source.length; ++i) {
|
|
20067
|
+
if (typeof source[i] !== 'undefined') {
|
|
20068
|
+
obj[i] = source[i];
|
|
20129
20069
|
}
|
|
20130
20070
|
}
|
|
20131
|
-
|
|
20132
|
-
|
|
20133
|
-
|
|
20134
|
-
|
|
20135
|
-
|
|
20136
|
-
|
|
20137
|
-
|
|
20138
|
-
|
|
20139
|
-
function setCommonInfo(prodData) {
|
|
20140
|
-
if (!prodData || !prodData.mulInsOrderList) {
|
|
20141
|
-
return prodData;
|
|
20071
|
+
|
|
20072
|
+
return obj;
|
|
20073
|
+
};
|
|
20074
|
+
|
|
20075
|
+
var merge = function merge(target, source, options) {
|
|
20076
|
+
/* eslint no-param-reassign: 0 */
|
|
20077
|
+
if (!source) {
|
|
20078
|
+
return target;
|
|
20142
20079
|
}
|
|
20143
|
-
|
|
20144
|
-
|
|
20145
|
-
|
|
20146
|
-
|
|
20147
|
-
|
|
20148
|
-
|
|
20149
|
-
|
|
20150
|
-
|
|
20151
|
-
|
|
20152
|
-
|
|
20153
|
-
common.eleOrderList.push(ele);
|
|
20080
|
+
|
|
20081
|
+
if (typeof source !== 'object' && typeof source !== 'function') {
|
|
20082
|
+
if (isArray(target)) {
|
|
20083
|
+
target.push(source);
|
|
20084
|
+
} else if (target && typeof target === 'object') {
|
|
20085
|
+
if (
|
|
20086
|
+
(options && (options.plainObjects || options.allowPrototypes))
|
|
20087
|
+
|| !has.call(Object.prototype, source)
|
|
20088
|
+
) {
|
|
20089
|
+
target[source] = true;
|
|
20154
20090
|
}
|
|
20155
|
-
}
|
|
20156
|
-
|
|
20157
|
-
|
|
20158
|
-
|
|
20159
|
-
return
|
|
20160
|
-
}
|
|
20161
|
-
prodData.mulInsOrderList = prodData.mulInsOrderList.filter(function (ins) { return ins.key !== 'common'; });
|
|
20162
|
-
prodData.mulInsOrderList.unshift(common);
|
|
20163
|
-
if (prodData.mulInsOrderList[1]) {
|
|
20164
|
-
prodData.mulInsOrderList[1].isFollowing = true;
|
|
20091
|
+
} else {
|
|
20092
|
+
return [target, source];
|
|
20093
|
+
}
|
|
20094
|
+
|
|
20095
|
+
return target;
|
|
20165
20096
|
}
|
|
20166
|
-
|
|
20167
|
-
|
|
20168
|
-
|
|
20169
|
-
if (!prodData.mulInsOrderList) {
|
|
20170
|
-
return prodData;
|
|
20097
|
+
|
|
20098
|
+
if (!target || typeof target !== 'object') {
|
|
20099
|
+
return [target].concat(source);
|
|
20171
20100
|
}
|
|
20172
|
-
|
|
20173
|
-
|
|
20174
|
-
|
|
20101
|
+
|
|
20102
|
+
var mergeTarget = target;
|
|
20103
|
+
if (isArray(target) && !isArray(source)) {
|
|
20104
|
+
mergeTarget = arrayToObject(target, options);
|
|
20175
20105
|
}
|
|
20176
|
-
|
|
20177
|
-
|
|
20178
|
-
|
|
20179
|
-
|
|
20180
|
-
|
|
20181
|
-
|
|
20182
|
-
|
|
20183
|
-
|
|
20184
|
-
|
|
20185
|
-
oldInsuranceIdEle = oldGroupIns.eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20186
|
-
}
|
|
20187
|
-
if (ins.groupKey) {
|
|
20188
|
-
newGroupInsMap[ins.groupKey] = newGroupInsMap[ins.groupKey] || {
|
|
20189
|
-
key: ins.groupKey,
|
|
20190
|
-
name: ins.groupName,
|
|
20191
|
-
huomian: ins.huomian,
|
|
20192
|
-
isGroup: true,
|
|
20193
|
-
eleOrderList: [
|
|
20194
|
-
{
|
|
20195
|
-
key: 'title',
|
|
20196
|
-
value: (oldTitleEle && oldTitleEle.value) || false,
|
|
20197
|
-
isDisabled: false,
|
|
20198
|
-
componentName: 'cmCommonTitle',
|
|
20199
|
-
labelName: ins.groupName
|
|
20200
|
-
},
|
|
20201
|
-
{
|
|
20202
|
-
key: 'insuranceId',
|
|
20203
|
-
value: (oldInsuranceIdEle && oldInsuranceIdEle.value) || (ins.isCheckbox ? [] : ''),
|
|
20204
|
-
componentName: ins.isCheckbox ? 'cmCommonCheckbox' : 'cmCommonRadio',
|
|
20205
|
-
opts: []
|
|
20206
|
-
}
|
|
20207
|
-
]
|
|
20208
|
-
};
|
|
20209
|
-
var titleEle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20210
|
-
var insuranceIdEle = newGroupInsMap[ins.groupKey].eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20211
|
-
insuranceIdEle.opts.push({
|
|
20212
|
-
val: ins.key,
|
|
20213
|
-
code: ins.code,
|
|
20214
|
-
desc: titleEle.labelName,
|
|
20215
|
-
isDisabled: titleEle.isDisabled
|
|
20216
|
-
});
|
|
20217
|
-
}
|
|
20218
|
-
});
|
|
20219
|
-
var _loop_2 = function (k) {
|
|
20220
|
-
var nGroupTitle = newGroupInsMap[k].eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20221
|
-
var nGroupInsuranceId = newGroupInsMap[k].eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20222
|
-
if (nGroupTitle && nGroupInsuranceId) {
|
|
20223
|
-
if (nGroupInsuranceId.opts && nGroupInsuranceId.opts.length) {
|
|
20224
|
-
if (nGroupInsuranceId.opts.every(function (opt) { return !!opt.isDisabled; })) {
|
|
20225
|
-
nGroupTitle.value = false;
|
|
20226
|
-
nGroupTitle.isDisabled = true;
|
|
20227
|
-
}
|
|
20228
|
-
else {
|
|
20229
|
-
nGroupTitle.isDisabled = false;
|
|
20230
|
-
}
|
|
20231
|
-
}
|
|
20232
|
-
var groupInsList = prodData.mulInsOrderList.filter(function (ins) { return ins.groupKey == k; });
|
|
20233
|
-
if (groupInsList && groupInsList.length) {
|
|
20234
|
-
if (groupInsList.some(function (ins) {
|
|
20235
|
-
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20236
|
-
return ins.required && subTitle && !subTitle.isDisabled;
|
|
20237
|
-
})) {
|
|
20238
|
-
nGroupTitle.value = true;
|
|
20239
|
-
nGroupTitle.isDisabled = true;
|
|
20240
|
-
}
|
|
20241
|
-
var notDisabledInsurances = groupInsList.filter(function (ins) {
|
|
20242
|
-
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20243
|
-
return subTitle && !subTitle.isDisabled;
|
|
20244
|
-
});
|
|
20245
|
-
var checkedInsurances = notDisabledInsurances.find(function (ins) {
|
|
20246
|
-
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20247
|
-
return subTitle && subTitle.value;
|
|
20248
|
-
});
|
|
20249
|
-
if (!nGroupInsuranceId.value) {
|
|
20250
|
-
if (checkedInsurances) {
|
|
20251
|
-
nGroupInsuranceId.value = checkedInsurances.key;
|
|
20252
|
-
nGroupTitle.value = true;
|
|
20253
|
-
}
|
|
20254
|
-
else if (nGroupTitle.value) {
|
|
20255
|
-
if (notDisabledInsurances[0]) {
|
|
20256
|
-
nGroupInsuranceId.value = notDisabledInsurances[0].key;
|
|
20257
|
-
}
|
|
20258
|
-
}
|
|
20106
|
+
|
|
20107
|
+
if (isArray(target) && isArray(source)) {
|
|
20108
|
+
source.forEach(function (item, i) {
|
|
20109
|
+
if (has.call(target, i)) {
|
|
20110
|
+
var targetItem = target[i];
|
|
20111
|
+
if (targetItem && typeof targetItem === 'object' && item && typeof item === 'object') {
|
|
20112
|
+
target[i] = merge(targetItem, item, options);
|
|
20113
|
+
} else {
|
|
20114
|
+
target.push(item);
|
|
20259
20115
|
}
|
|
20116
|
+
} else {
|
|
20117
|
+
target[i] = item;
|
|
20260
20118
|
}
|
|
20119
|
+
});
|
|
20120
|
+
return target;
|
|
20121
|
+
}
|
|
20122
|
+
|
|
20123
|
+
return Object.keys(source).reduce(function (acc, key) {
|
|
20124
|
+
var value = source[key];
|
|
20125
|
+
|
|
20126
|
+
if (has.call(acc, key)) {
|
|
20127
|
+
acc[key] = merge(acc[key], value, options);
|
|
20128
|
+
} else {
|
|
20129
|
+
acc[key] = value;
|
|
20261
20130
|
}
|
|
20262
|
-
|
|
20263
|
-
|
|
20264
|
-
|
|
20265
|
-
|
|
20266
|
-
|
|
20267
|
-
|
|
20268
|
-
|
|
20269
|
-
|
|
20270
|
-
|
|
20271
|
-
|
|
20272
|
-
|
|
20273
|
-
|
|
20274
|
-
|
|
20131
|
+
return acc;
|
|
20132
|
+
}, mergeTarget);
|
|
20133
|
+
};
|
|
20134
|
+
|
|
20135
|
+
var assign = function assignSingleSource(target, source) {
|
|
20136
|
+
return Object.keys(source).reduce(function (acc, key) {
|
|
20137
|
+
acc[key] = source[key];
|
|
20138
|
+
return acc;
|
|
20139
|
+
}, target);
|
|
20140
|
+
};
|
|
20141
|
+
|
|
20142
|
+
var decode = function (str, defaultDecoder, charset) {
|
|
20143
|
+
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
20144
|
+
if (charset === 'iso-8859-1') {
|
|
20145
|
+
// unescape never throws, no try...catch needed:
|
|
20146
|
+
return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
|
|
20147
|
+
}
|
|
20148
|
+
// utf-8
|
|
20149
|
+
try {
|
|
20150
|
+
return decodeURIComponent(strWithoutPlus);
|
|
20151
|
+
} catch (e) {
|
|
20152
|
+
return strWithoutPlus;
|
|
20153
|
+
}
|
|
20154
|
+
};
|
|
20155
|
+
|
|
20156
|
+
var limit = 1024;
|
|
20157
|
+
|
|
20158
|
+
/* eslint operator-linebreak: [2, "before"] */
|
|
20159
|
+
|
|
20160
|
+
var encode = function encode(str, defaultEncoder, charset, kind, format) {
|
|
20161
|
+
// This code was originally written by Brian White (mscdex) for the io.js core querystring library.
|
|
20162
|
+
// It has been adapted here for stricter adherence to RFC 3986
|
|
20163
|
+
if (str.length === 0) {
|
|
20164
|
+
return str;
|
|
20165
|
+
}
|
|
20166
|
+
|
|
20167
|
+
var string = str;
|
|
20168
|
+
if (typeof str === 'symbol') {
|
|
20169
|
+
string = Symbol.prototype.toString.call(str);
|
|
20170
|
+
} else if (typeof str !== 'string') {
|
|
20171
|
+
string = String(str);
|
|
20172
|
+
}
|
|
20173
|
+
|
|
20174
|
+
if (charset === 'iso-8859-1') {
|
|
20175
|
+
return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
|
|
20176
|
+
return '%26%23' + parseInt($0.slice(2), 16) + '%3B';
|
|
20177
|
+
});
|
|
20178
|
+
}
|
|
20179
|
+
|
|
20180
|
+
var out = '';
|
|
20181
|
+
for (var j = 0; j < string.length; j += limit) {
|
|
20182
|
+
var segment = string.length >= limit ? string.slice(j, j + limit) : string;
|
|
20183
|
+
var arr = [];
|
|
20184
|
+
|
|
20185
|
+
for (var i = 0; i < segment.length; ++i) {
|
|
20186
|
+
var c = segment.charCodeAt(i);
|
|
20187
|
+
if (
|
|
20188
|
+
c === 0x2D // -
|
|
20189
|
+
|| c === 0x2E // .
|
|
20190
|
+
|| c === 0x5F // _
|
|
20191
|
+
|| c === 0x7E // ~
|
|
20192
|
+
|| (c >= 0x30 && c <= 0x39) // 0-9
|
|
20193
|
+
|| (c >= 0x41 && c <= 0x5A) // a-z
|
|
20194
|
+
|| (c >= 0x61 && c <= 0x7A) // A-Z
|
|
20195
|
+
|| (format === formats.RFC1738 && (c === 0x28 || c === 0x29)) // ( )
|
|
20196
|
+
) {
|
|
20197
|
+
arr[arr.length] = segment.charAt(i);
|
|
20198
|
+
continue;
|
|
20275
20199
|
}
|
|
20276
|
-
|
|
20277
|
-
|
|
20278
|
-
|
|
20279
|
-
|
|
20280
|
-
if (!['code', 'groupKey', 'groupName', 'isFollowing', 'key', 'name', 'accountData', 'reduceBaofData'].includes(ck)) {
|
|
20281
|
-
if (ck === 'eleOrderList') {
|
|
20282
|
-
newGroupInsMap[k][ck] = newGroupInsMap[k][ck].concat(checkedIns[ck].filter(function (ele) { return ele.key !== 'title'; }));
|
|
20283
|
-
}
|
|
20284
|
-
else {
|
|
20285
|
-
newGroupInsMap[k][ck] = checkedIns[ck];
|
|
20286
|
-
}
|
|
20287
|
-
}
|
|
20288
|
-
}
|
|
20289
|
-
}
|
|
20200
|
+
|
|
20201
|
+
if (c < 0x80) {
|
|
20202
|
+
arr[arr.length] = hexTable[c];
|
|
20203
|
+
continue;
|
|
20290
20204
|
}
|
|
20291
|
-
|
|
20292
|
-
|
|
20293
|
-
|
|
20294
|
-
|
|
20295
|
-
|
|
20205
|
+
|
|
20206
|
+
if (c < 0x800) {
|
|
20207
|
+
arr[arr.length] = hexTable[0xC0 | (c >> 6)]
|
|
20208
|
+
+ hexTable[0x80 | (c & 0x3F)];
|
|
20209
|
+
continue;
|
|
20296
20210
|
}
|
|
20297
|
-
|
|
20298
|
-
|
|
20299
|
-
|
|
20211
|
+
|
|
20212
|
+
if (c < 0xD800 || c >= 0xE000) {
|
|
20213
|
+
arr[arr.length] = hexTable[0xE0 | (c >> 12)]
|
|
20214
|
+
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
|
20215
|
+
+ hexTable[0x80 | (c & 0x3F)];
|
|
20216
|
+
continue;
|
|
20217
|
+
}
|
|
20218
|
+
|
|
20219
|
+
i += 1;
|
|
20220
|
+
c = 0x10000 + (((c & 0x3FF) << 10) | (segment.charCodeAt(i) & 0x3FF));
|
|
20221
|
+
|
|
20222
|
+
arr[arr.length] = hexTable[0xF0 | (c >> 18)]
|
|
20223
|
+
+ hexTable[0x80 | ((c >> 12) & 0x3F)]
|
|
20224
|
+
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
|
20225
|
+
+ hexTable[0x80 | (c & 0x3F)];
|
|
20300
20226
|
}
|
|
20301
|
-
|
|
20302
|
-
|
|
20303
|
-
_loop_2(k);
|
|
20227
|
+
|
|
20228
|
+
out += arr.join('');
|
|
20304
20229
|
}
|
|
20305
|
-
|
|
20306
|
-
|
|
20307
|
-
|
|
20308
|
-
|
|
20309
|
-
|
|
20310
|
-
|
|
20311
|
-
|
|
20312
|
-
|
|
20313
|
-
|
|
20314
|
-
|
|
20315
|
-
|
|
20316
|
-
|
|
20317
|
-
|
|
20318
|
-
|
|
20319
|
-
|
|
20320
|
-
|
|
20321
|
-
|
|
20322
|
-
|
|
20323
|
-
|
|
20324
|
-
|
|
20325
|
-
});
|
|
20326
|
-
}
|
|
20327
|
-
var _a = personOrderList.find(function (p) { return p.key === 'insuredInfo'; }), sex = _a.sex, age = _a.age;
|
|
20328
|
-
if (ageRangeProd[sex] && age >= ageRangeProd[sex][0] && age <= ageRangeProd[sex][1]) {
|
|
20329
|
-
prodData.hide = false;
|
|
20230
|
+
|
|
20231
|
+
return out;
|
|
20232
|
+
};
|
|
20233
|
+
|
|
20234
|
+
var compact = function compact(value) {
|
|
20235
|
+
var queue = [{ obj: { o: value }, prop: 'o' }];
|
|
20236
|
+
var refs = [];
|
|
20237
|
+
|
|
20238
|
+
for (var i = 0; i < queue.length; ++i) {
|
|
20239
|
+
var item = queue[i];
|
|
20240
|
+
var obj = item.obj[item.prop];
|
|
20241
|
+
|
|
20242
|
+
var keys = Object.keys(obj);
|
|
20243
|
+
for (var j = 0; j < keys.length; ++j) {
|
|
20244
|
+
var key = keys[j];
|
|
20245
|
+
var val = obj[key];
|
|
20246
|
+
if (typeof val === 'object' && val !== null && refs.indexOf(val) === -1) {
|
|
20247
|
+
queue.push({ obj: obj, prop: key });
|
|
20248
|
+
refs.push(val);
|
|
20249
|
+
}
|
|
20330
20250
|
}
|
|
20331
|
-
|
|
20332
|
-
|
|
20333
|
-
|
|
20334
|
-
|
|
20251
|
+
}
|
|
20252
|
+
|
|
20253
|
+
compactQueue(queue);
|
|
20254
|
+
|
|
20255
|
+
return value;
|
|
20256
|
+
};
|
|
20257
|
+
|
|
20258
|
+
var isRegExp = function isRegExp(obj) {
|
|
20259
|
+
return Object.prototype.toString.call(obj) === '[object RegExp]';
|
|
20260
|
+
};
|
|
20261
|
+
|
|
20262
|
+
var isBuffer = function isBuffer(obj) {
|
|
20263
|
+
if (!obj || typeof obj !== 'object') {
|
|
20264
|
+
return false;
|
|
20265
|
+
}
|
|
20266
|
+
|
|
20267
|
+
return !!(obj.constructor && obj.constructor.isBuffer && obj.constructor.isBuffer(obj));
|
|
20268
|
+
};
|
|
20269
|
+
|
|
20270
|
+
var combine = function combine(a, b) {
|
|
20271
|
+
return [].concat(a, b);
|
|
20272
|
+
};
|
|
20273
|
+
|
|
20274
|
+
var maybeMap = function maybeMap(val, fn) {
|
|
20275
|
+
if (isArray(val)) {
|
|
20276
|
+
var mapped = [];
|
|
20277
|
+
for (var i = 0; i < val.length; i += 1) {
|
|
20278
|
+
mapped.push(fn(val[i]));
|
|
20335
20279
|
}
|
|
20280
|
+
return mapped;
|
|
20336
20281
|
}
|
|
20337
|
-
return
|
|
20338
|
-
}
|
|
20339
|
-
|
|
20340
|
-
|
|
20341
|
-
|
|
20342
|
-
|
|
20343
|
-
|
|
20344
|
-
|
|
20345
|
-
|
|
20346
|
-
|
|
20347
|
-
|
|
20348
|
-
|
|
20349
|
-
|
|
20282
|
+
return fn(val);
|
|
20283
|
+
};
|
|
20284
|
+
|
|
20285
|
+
module.exports = {
|
|
20286
|
+
arrayToObject: arrayToObject,
|
|
20287
|
+
assign: assign,
|
|
20288
|
+
combine: combine,
|
|
20289
|
+
compact: compact,
|
|
20290
|
+
decode: decode,
|
|
20291
|
+
encode: encode,
|
|
20292
|
+
isBuffer: isBuffer,
|
|
20293
|
+
isRegExp: isRegExp,
|
|
20294
|
+
maybeMap: maybeMap,
|
|
20295
|
+
merge: merge
|
|
20296
|
+
};
|
|
20297
|
+
|
|
20298
|
+
|
|
20299
|
+
/***/ }),
|
|
20300
|
+
/* 36 */
|
|
20301
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
20302
|
+
|
|
20303
|
+
"use strict";
|
|
20304
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "d", function() { return initProductData; });
|
|
20305
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "f", function() { return productDataHandler; });
|
|
20306
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "c", function() { return getElementVerifyFromProductVerify; });
|
|
20307
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "h", function() { return setCommonInfo; });
|
|
20308
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "i", function() { return setGroupInsurance; });
|
|
20309
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "e", function() { return isHideProduct; });
|
|
20310
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "j", function() { return verifyProductRules; });
|
|
20311
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "g", function() { return restrictInsurancesInProduct; });
|
|
20312
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return convertProductData; });
|
|
20313
|
+
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return clearAddAndTakeAndAdjustBaoeData; });
|
|
20314
|
+
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
|
|
20315
|
+
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(15);
|
|
20316
|
+
/* harmony import */ var qs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(qs__WEBPACK_IMPORTED_MODULE_1__);
|
|
20317
|
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3);
|
|
20318
|
+
/* harmony import */ var lodash__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(lodash__WEBPACK_IMPORTED_MODULE_2__);
|
|
20319
|
+
/* harmony import */ var _src_js_variables_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7);
|
|
20320
|
+
/* harmony import */ var _common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1);
|
|
20321
|
+
/* harmony import */ var _person__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(12);
|
|
20322
|
+
/* harmony import */ var _insurance__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(11);
|
|
20323
|
+
|
|
20324
|
+
|
|
20325
|
+
|
|
20326
|
+
|
|
20327
|
+
|
|
20328
|
+
|
|
20329
|
+
|
|
20330
|
+
function initProductData(prodData) {
|
|
20331
|
+
prodData.hadChoice = false;
|
|
20332
|
+
prodData.insShowArr = null;
|
|
20333
|
+
prodData.totalBaof = null;
|
|
20334
|
+
if (!prodData.mulInsOrderList) {
|
|
20335
|
+
return prodData;
|
|
20350
20336
|
}
|
|
20351
|
-
if (
|
|
20352
|
-
|
|
20353
|
-
if (ins.eleOrderList) {
|
|
20354
|
-
ins.eleOrderList.forEach(function (ele) {
|
|
20355
|
-
errorMsg =
|
|
20356
|
-
errorMsg ||
|
|
20357
|
-
Object(_insurance__WEBPACK_IMPORTED_MODULE_5__[/* restrictElementsInInsurance */ "d"])({
|
|
20358
|
-
personOrderList: personOrderList,
|
|
20359
|
-
insData: ins,
|
|
20360
|
-
eleData: ele
|
|
20361
|
-
});
|
|
20362
|
-
});
|
|
20363
|
-
}
|
|
20364
|
-
});
|
|
20337
|
+
if (prodData.mulInsOrderList.some(function (ins) { return !!ins.adjustBaoe; })) {
|
|
20338
|
+
prodData.adjustBaoeData = prodData.adjustBaoeData || null;
|
|
20365
20339
|
}
|
|
20366
|
-
|
|
20340
|
+
prodData.mulInsOrderList.forEach(function (ins) {
|
|
20341
|
+
Object(_insurance__WEBPACK_IMPORTED_MODULE_6__[/* initInsuranceData */ "b"])(ins);
|
|
20342
|
+
});
|
|
20343
|
+
return prodData;
|
|
20367
20344
|
}
|
|
20368
|
-
function
|
|
20369
|
-
var
|
|
20370
|
-
|
|
20371
|
-
|
|
20372
|
-
|
|
20373
|
-
|
|
20374
|
-
|
|
20375
|
-
|
|
20376
|
-
|
|
20377
|
-
|
|
20378
|
-
|
|
20379
|
-
|
|
20380
|
-
|
|
20381
|
-
|
|
20382
|
-
|
|
20383
|
-
|
|
20384
|
-
|
|
20385
|
-
|
|
20386
|
-
|
|
20387
|
-
|
|
20388
|
-
|
|
20389
|
-
|
|
20390
|
-
|
|
20391
|
-
|
|
20392
|
-
|
|
20393
|
-
|
|
20394
|
-
|
|
20395
|
-
|
|
20396
|
-
|
|
20397
|
-
|
|
20398
|
-
|
|
20399
|
-
|
|
20400
|
-
|
|
20401
|
-
|
|
20402
|
-
|
|
20403
|
-
|
|
20404
|
-
|
|
20405
|
-
|
|
20406
|
-
|
|
20345
|
+
function productDataHandler(prodData, prodVerifyData, personData, parmas) {
|
|
20346
|
+
var _a;
|
|
20347
|
+
return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __awaiter */ "b"])(this, void 0, Promise, function () {
|
|
20348
|
+
var productVerifyData, hasProduct, hasVerifyData, hasPersonData, personOrderList;
|
|
20349
|
+
return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __generator */ "e"])(this, function (_b) {
|
|
20350
|
+
switch (_b.label) {
|
|
20351
|
+
case 0:
|
|
20352
|
+
if (!prodData) {
|
|
20353
|
+
return [2, prodData];
|
|
20354
|
+
}
|
|
20355
|
+
productVerifyData = null;
|
|
20356
|
+
if (prodData.multipleInsured) {
|
|
20357
|
+
multipleInsuredHandler(personData);
|
|
20358
|
+
}
|
|
20359
|
+
if (!(prodData.feeValidateMode === 'single')) return [3, 2];
|
|
20360
|
+
return [4, getSingleInsurancesVerifyData(prodData, personData, parmas).catch(function () { })];
|
|
20361
|
+
case 1:
|
|
20362
|
+
productVerifyData = _b.sent();
|
|
20363
|
+
return [3, 3];
|
|
20364
|
+
case 2:
|
|
20365
|
+
productVerifyData = prodVerifyData;
|
|
20366
|
+
_b.label = 3;
|
|
20367
|
+
case 3:
|
|
20368
|
+
hasProduct = prodData.mulInsOrderList;
|
|
20369
|
+
hasVerifyData = productVerifyData && Object.keys(productVerifyData).length;
|
|
20370
|
+
hasPersonData = personData && personData.personOrderList;
|
|
20371
|
+
personOrderList = null;
|
|
20372
|
+
if (hasProduct && hasVerifyData && hasPersonData) {
|
|
20373
|
+
personOrderList = Object(_person__WEBPACK_IMPORTED_MODULE_5__[/* convertPersonData */ "a"])(personData, personData.personOrderList.map(function (p) { return p.key; }));
|
|
20374
|
+
setCommonInfo(prodData);
|
|
20375
|
+
(_a = prodData.mulInsOrderList) === null || _a === void 0 ? void 0 : _a.forEach(function (ins, ii, insList) {
|
|
20376
|
+
var _a, _b, _c;
|
|
20377
|
+
Object(_insurance__WEBPACK_IMPORTED_MODULE_6__[/* insuranceDataHandler */ "c"])(ins, prodData);
|
|
20378
|
+
var insuranceVerifyData = productVerifyData[ins.key];
|
|
20379
|
+
if (!insuranceVerifyData) {
|
|
20380
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20381
|
+
console.log("".concat(prodData.titleName, "-").concat(prodData.key, " -> ").concat(ins.name, "-").concat(ins.key, ": \u5F53\u524D\u9669\u79CD\u6CA1\u6709\u8D39\u7387\u8868"));
|
|
20382
|
+
}
|
|
20383
|
+
return;
|
|
20407
20384
|
}
|
|
20408
|
-
|
|
20409
|
-
|
|
20385
|
+
var isTouHuomianIns = ins.huomian === 'touHuomian' || ins.huomian === 'shuangHuomian';
|
|
20386
|
+
var insuredInfo = personOrderList.find(function (p) { return p.key === 'insuredInfo'; });
|
|
20387
|
+
var applicantInfo = personOrderList.find(function (p) { return p.key === 'applicantInfo'; });
|
|
20388
|
+
var personType = isTouHuomianIns ? 'applicantInfo' : 'insuredInfo';
|
|
20389
|
+
if (isTouHuomianIns && ins.allowSamePerson) {
|
|
20390
|
+
personType = applicantInfo && applicantInfo.title ? 'applicantInfo' : 'insuredInfo';
|
|
20410
20391
|
}
|
|
20411
|
-
|
|
20412
|
-
|
|
20392
|
+
var targetPerson = personOrderList.find(function (p) { return p.key === personType; });
|
|
20393
|
+
var personCondition = null;
|
|
20394
|
+
if (targetPerson) {
|
|
20395
|
+
personCondition = insuranceVerifyData.find(function (v) {
|
|
20396
|
+
return targetPerson.sex === v.sex && targetPerson.age >= v.minAge && targetPerson.age <= v.maxAge;
|
|
20397
|
+
});
|
|
20398
|
+
if (personCondition) {
|
|
20399
|
+
personCondition = personCondition.conditionData;
|
|
20400
|
+
var isSamePerson = isTouHuomianIns && ins.allowSamePerson && personCondition.key === 'samePerson';
|
|
20401
|
+
if (isSamePerson) {
|
|
20402
|
+
personCondition = personCondition.samePerson.find(function (c) { return c.value == (applicantInfo.title ? 0 : 1); });
|
|
20403
|
+
}
|
|
20404
|
+
}
|
|
20413
20405
|
}
|
|
20414
|
-
|
|
20415
|
-
|
|
20416
|
-
|
|
20417
|
-
|
|
20418
|
-
|
|
20419
|
-
|
|
20420
|
-
|
|
20421
|
-
|
|
20422
|
-
|
|
20423
|
-
|
|
20424
|
-
|
|
20425
|
-
|
|
20426
|
-
|
|
20427
|
-
|
|
20428
|
-
|
|
20429
|
-
|
|
20430
|
-
|
|
20431
|
-
|
|
20432
|
-
(
|
|
20406
|
+
var curCondition = personCondition;
|
|
20407
|
+
var eleTitle = (_a = ins.eleOrderList) === null || _a === void 0 ? void 0 : _a.find(function (e) { return e.key === 'title'; });
|
|
20408
|
+
var _loop_1 = function () {
|
|
20409
|
+
var isNotAllowSelect = !curCondition ||
|
|
20410
|
+
(isTouHuomianIns && !ins.allowSamePerson && (!targetPerson.title || targetPerson.applicantAndInsuredSame));
|
|
20411
|
+
if (isNotAllowSelect) {
|
|
20412
|
+
eleTitle.isDisabled = true;
|
|
20413
|
+
eleTitle.value = false;
|
|
20414
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20415
|
+
console.log(curCondition ? "".concat(eleTitle.labelName, "-").concat(ins.key, ": \u8D39\u7387\u5B58\u5728\uFF01\u4F46\u6295\u4FDD\u4EBA\u672A\u9009\u4E2D\u6216\u6295\u88AB\u4FDD\u4EBA\u4E3A\u540C\u4E00\u4EBA\uFF0C\u8BE5\u8C41\u514D\u9669\uFF08\u4E0D\u80FD\u9644\u52A0\u5230\u88AB\u4FDD\u4EBA\uFF09\u4E0D\u53EF\u9009") : "".concat(eleTitle.labelName, "-").concat(ins.key, ": \u8D39\u7387\u4E0D\u5B58\u5728\uFF01"));
|
|
20416
|
+
}
|
|
20417
|
+
}
|
|
20418
|
+
else {
|
|
20419
|
+
eleTitle.isDisabled = false;
|
|
20420
|
+
if (ins.required && (!ins.groupKey || ins.isCheckbox)) {
|
|
20421
|
+
eleTitle.value = true;
|
|
20422
|
+
eleTitle.isDisabled = true;
|
|
20423
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20424
|
+
console.log("".concat(eleTitle.labelName, "-").concat(ins.key, ": \u8D39\u7387\u5B58\u5728\uFF0C\u9669\u79CD\u4E3A\u5FC5\u9009\u9669\u4E14(\u4E3A\u975E\u7EC4\u5408\u9669\u6216\u4E3A\u591A\u9009\u4E00\u9669\u79CD)"));
|
|
20425
|
+
}
|
|
20426
|
+
}
|
|
20427
|
+
}
|
|
20428
|
+
if (!curCondition) {
|
|
20429
|
+
return "break";
|
|
20430
|
+
}
|
|
20431
|
+
var eleData = (_b = ins.eleOrderList) === null || _b === void 0 ? void 0 : _b.find(function (e) { return e.key === curCondition.key; });
|
|
20432
|
+
var commonData = insList.find(function (ins) { return ins.key === 'common'; });
|
|
20433
|
+
if (!eleData && commonData && commonData.eleOrderList) {
|
|
20434
|
+
eleData = commonData.eleOrderList.find(function (e) { return e.key === curCondition.key; });
|
|
20435
|
+
}
|
|
20436
|
+
if (!eleData) {
|
|
20437
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20438
|
+
console.log("".concat(ins.name, " - ").concat(curCondition && curCondition.key, "\u5143\u7D20\u4E0D\u5B58\u5728\uFF1A"));
|
|
20439
|
+
}
|
|
20440
|
+
curCondition = null;
|
|
20441
|
+
return "break";
|
|
20442
|
+
}
|
|
20443
|
+
var eleCondi = curCondition[curCondition.key];
|
|
20444
|
+
var isBeGovernedEle = eleData.isHide && !eleData.isDisabled && ins.refInsuranceId && Number(ins.refInsuranceId) !== -2;
|
|
20445
|
+
if (isBeGovernedEle) {
|
|
20446
|
+
var refInsData = null;
|
|
20447
|
+
if (Number(ins.refInsuranceId) === -1) {
|
|
20448
|
+
refInsData = insList[0].key === 'common' ? insList[1] : insList[0];
|
|
20433
20449
|
}
|
|
20434
20450
|
else {
|
|
20435
|
-
|
|
20451
|
+
refInsData = insList.find(function (ins) { return ins.key == ins.refInsuranceId; });
|
|
20452
|
+
}
|
|
20453
|
+
var refEleData = refInsData && refInsData.eleOrderList && refInsData.eleOrderList.find(function (e) { return e.key === eleData.key; });
|
|
20454
|
+
if (refEleData) {
|
|
20455
|
+
if (ins.huomian && eleData.key == 'pPeriod') {
|
|
20456
|
+
eleData.value = Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* getHuomianPeriodValue */ "g"])(refEleData.value, ins.pMinus, ins.huomian === 'touHuomian' ? insuredInfo.age : targetPerson.age);
|
|
20457
|
+
}
|
|
20458
|
+
else {
|
|
20459
|
+
eleData.value = refEleData.value;
|
|
20460
|
+
}
|
|
20461
|
+
}
|
|
20462
|
+
else {
|
|
20463
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20464
|
+
console.log("".concat(ins.name, "-").concat(ins.key, "\uFF1A\u5173\u8054\u9669\u79CD").concat(ins.refInsuranceId, "\u4E0D\u5B58\u5728"));
|
|
20465
|
+
}
|
|
20436
20466
|
}
|
|
20437
20467
|
}
|
|
20438
|
-
|
|
20439
|
-
|
|
20440
|
-
|
|
20441
|
-
|
|
20442
|
-
|
|
20443
|
-
|
|
20468
|
+
else {
|
|
20469
|
+
var backupOpts_1 = eleData.opts && eleData.opts.length ? eleData.opts.slice(0) : [];
|
|
20470
|
+
eleData.opts = eleCondi.filter(function (c) { return c.value !== undefined && c.desc !== undefined; }).map(function (c) {
|
|
20471
|
+
var option = backupOpts_1.find(function (o) { return o.val == c.value; });
|
|
20472
|
+
return {
|
|
20473
|
+
val: c.value,
|
|
20474
|
+
desc: c.desc || c.value,
|
|
20475
|
+
isHide: (option && option.isHide) || null,
|
|
20476
|
+
isDisabled: (option && option.isDisabled) || null,
|
|
20477
|
+
isInvalid: null
|
|
20478
|
+
};
|
|
20479
|
+
});
|
|
20480
|
+
var isNoOption = eleData.opts && eleData.opts.length && eleData.opts.every(function (ele) { return ele.val != eleData.value; });
|
|
20481
|
+
if (isNoOption) {
|
|
20482
|
+
if (eleData.key === 'pPeriod') {
|
|
20483
|
+
var filterOpts = (_c = eleData.opts) === null || _c === void 0 ? void 0 : _c.filter(function (opt) { return !opt.isHide && !opt.isDisabled; });
|
|
20484
|
+
if (filterOpts && filterOpts.length) {
|
|
20485
|
+
eleData.value = filterOpts[filterOpts.length - 1].val;
|
|
20486
|
+
}
|
|
20487
|
+
}
|
|
20488
|
+
else {
|
|
20489
|
+
if (eleData.opts && eleData.opts.length) {
|
|
20490
|
+
eleData.value = eleData.opts[0].val;
|
|
20491
|
+
}
|
|
20492
|
+
}
|
|
20493
|
+
}
|
|
20494
|
+
}
|
|
20495
|
+
curCondition = eleCondi.find(function (eleCondi) { return eleCondi.value == eleData.value; });
|
|
20496
|
+
var eleIndex = ins.eleOrderList.findIndex(function (ele) { return ele.key === eleData.key; });
|
|
20497
|
+
var prevElement;
|
|
20498
|
+
if (eleIndex >= 1) {
|
|
20499
|
+
prevElement = ins.eleOrderList[eleIndex - 1];
|
|
20444
20500
|
}
|
|
20445
|
-
|
|
20446
|
-
|
|
20447
|
-
|
|
20448
|
-
|
|
20449
|
-
|
|
20450
|
-
|
|
20451
|
-
|
|
20452
|
-
|
|
20453
|
-
var rangeVal = eval(restrict.rCondition);
|
|
20454
|
-
if (rangeVal !== undefined && rangeVal !== null) {
|
|
20455
|
-
if (rangeVal.constructor === Array) {
|
|
20456
|
-
if (rangeVal[0] && curEle.value && curEle.value < rangeVal[0]) {
|
|
20457
|
-
errorMsg =
|
|
20458
|
-
restrict.rMsg || "".concat(curIns.name, "\u7684").concat(curEle.labelName, "\u4E0D\u5F97\u5C0F\u4E8E").concat(Object(_common__WEBPACK_IMPORTED_MODULE_3__[/* converUnit10000 */ "b"])(rangeVal[0]));
|
|
20501
|
+
if (prevElement) {
|
|
20502
|
+
if (!curCondition) {
|
|
20503
|
+
var prevEleVerify = getElementVerifyFromProductVerify(personCondition, insList, { insuranceKey: ins.key, elementKey: prevElement.key });
|
|
20504
|
+
var onePrevEleVerify = prevEleVerify === null || prevEleVerify === void 0 ? void 0 : prevEleVerify.find(function (v) { return v[eleData.key] && v[eleData.key].some(function (condi) { return condi.value === eleData.value; }); });
|
|
20505
|
+
if (onePrevEleVerify) {
|
|
20506
|
+
prevElement.value = onePrevEleVerify.value;
|
|
20507
|
+
curCondition = onePrevEleVerify[eleData.key];
|
|
20508
|
+
}
|
|
20459
20509
|
}
|
|
20460
|
-
if (
|
|
20461
|
-
|
|
20462
|
-
|
|
20510
|
+
if (!curCondition) {
|
|
20511
|
+
eleTitle.isDisabled = true;
|
|
20512
|
+
eleTitle.value = false;
|
|
20513
|
+
if (window.DEBUG_TEMP_CONSOLE_FLAG) {
|
|
20514
|
+
console.log("".concat(eleTitle.labelName, "-").concat(ins.key, ": \u8D39\u7387\u4E0D\u5B58\u5728\uFF01"));
|
|
20515
|
+
}
|
|
20463
20516
|
}
|
|
20464
|
-
|
|
20465
|
-
|
|
20466
|
-
|
|
20467
|
-
|
|
20517
|
+
var isNeedReverseFilter = eleData.isHide && !eleData.isDisabled && prevElement.opts && prevElement.opts.length;
|
|
20518
|
+
if (isNeedReverseFilter) {
|
|
20519
|
+
var prevEleVerify = getElementVerifyFromProductVerify(personCondition, insList, { insuranceKey: ins.key, elementKey: prevElement.key });
|
|
20520
|
+
if (prevEleVerify) {
|
|
20521
|
+
prevElement.opts = prevEleVerify.filter(function (v) {
|
|
20522
|
+
var _a;
|
|
20523
|
+
var elementVerify = getElementVerifyFromProductVerify(personCondition, insList, (_a = {
|
|
20524
|
+
insuranceKey: ins.key,
|
|
20525
|
+
elementKey: eleData.key
|
|
20526
|
+
},
|
|
20527
|
+
_a[prevElement.key] = v.value,
|
|
20528
|
+
_a));
|
|
20529
|
+
return elementVerify && elementVerify.some(function (c) { return c.value == eleData.value; });
|
|
20530
|
+
}).map(function (v) { return ({
|
|
20531
|
+
val: v.value,
|
|
20532
|
+
desc: v.desc || v.value,
|
|
20533
|
+
isHide: null,
|
|
20534
|
+
isDisabled: null,
|
|
20535
|
+
isInvalid: null
|
|
20536
|
+
}); });
|
|
20537
|
+
}
|
|
20468
20538
|
}
|
|
20469
20539
|
}
|
|
20470
|
-
}
|
|
20471
|
-
|
|
20472
|
-
|
|
20540
|
+
};
|
|
20541
|
+
do {
|
|
20542
|
+
var state_1 = _loop_1();
|
|
20543
|
+
if (state_1 === "break")
|
|
20544
|
+
break;
|
|
20545
|
+
} while (curCondition && curCondition.key && curCondition[curCondition.key]);
|
|
20546
|
+
});
|
|
20473
20547
|
}
|
|
20474
|
-
|
|
20548
|
+
setGroupInsurance(prodData);
|
|
20549
|
+
isHideProduct(prodData, productVerifyData, personOrderList);
|
|
20550
|
+
return [2, prodData];
|
|
20475
20551
|
}
|
|
20476
20552
|
});
|
|
20477
|
-
}
|
|
20478
|
-
return errorMsg;
|
|
20479
|
-
}
|
|
20480
|
-
function convertProductData(prodData) {
|
|
20481
|
-
if (!prodData) {
|
|
20482
|
-
return prodData;
|
|
20483
|
-
}
|
|
20484
|
-
if (!prodData.mulInsOrderList) {
|
|
20485
|
-
return prodData;
|
|
20486
|
-
}
|
|
20487
|
-
var productData = Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, prodData), { common: {}, mulInsOrderList: [] });
|
|
20488
|
-
prodData.mulInsOrderList.forEach(function (insurance) {
|
|
20489
|
-
var insuranceData = Object(_common__WEBPACK_IMPORTED_MODULE_3__[/* convertEleOrderListToObj */ "c"])(insurance);
|
|
20490
|
-
if (insuranceData.key == 'common') {
|
|
20491
|
-
productData.common = insuranceData;
|
|
20492
|
-
return;
|
|
20493
|
-
}
|
|
20494
|
-
if (insuranceData.title && !insuranceData.groupKey) {
|
|
20495
|
-
if (insuranceData.isGroup) {
|
|
20496
|
-
var insuranceId = insuranceData.insuranceId.constructor == Array ? insuranceData.insuranceId : [insuranceData.insuranceId];
|
|
20497
|
-
insuranceId.forEach(function (insId) {
|
|
20498
|
-
var checkedIns = prodData.mulInsOrderList.find(function (p) { return p.key === insId; });
|
|
20499
|
-
if (checkedIns) {
|
|
20500
|
-
var checkedInsData_1 = Object(_common__WEBPACK_IMPORTED_MODULE_3__[/* convertEleOrderListToObj */ "c"])(checkedIns);
|
|
20501
|
-
insurance.eleOrderList &&
|
|
20502
|
-
insurance.eleOrderList.forEach(function (ele) {
|
|
20503
|
-
if (!['title', 'insuranceId'].includes(ele.key)) {
|
|
20504
|
-
checkedInsData_1[ele.key] = insuranceData[ele.key];
|
|
20505
|
-
}
|
|
20506
|
-
});
|
|
20507
|
-
productData.mulInsOrderList.push(Object(_common__WEBPACK_IMPORTED_MODULE_3__[/* deepCopy */ "d"])(checkedInsData_1));
|
|
20508
|
-
}
|
|
20509
|
-
});
|
|
20510
|
-
return;
|
|
20511
|
-
}
|
|
20512
|
-
productData.mulInsOrderList.push(insuranceData);
|
|
20513
|
-
}
|
|
20514
20553
|
});
|
|
20515
|
-
return productData;
|
|
20516
20554
|
}
|
|
20517
|
-
function
|
|
20518
|
-
|
|
20519
|
-
|
|
20520
|
-
|
|
20521
|
-
if (!productData.mulInsOrderList) {
|
|
20522
|
-
return productData;
|
|
20555
|
+
function multipleInsuredHandler(personData) {
|
|
20556
|
+
var personOrderList = personData.personOrderList;
|
|
20557
|
+
if (!(personOrderList && personOrderList.length)) {
|
|
20558
|
+
return null;
|
|
20523
20559
|
}
|
|
20524
|
-
|
|
20525
|
-
|
|
20526
|
-
|
|
20527
|
-
|
|
20528
|
-
|
|
20529
|
-
|
|
20530
|
-
|
|
20531
|
-
|
|
20532
|
-
|
|
20533
|
-
|
|
20560
|
+
var insured2Info = personOrderList.find(function (p) { return p.key === 'insured2Info'; });
|
|
20561
|
+
if (!insured2Info) {
|
|
20562
|
+
var insuredInfo = personOrderList.find(function (p) { return p.key === 'insuredInfo'; });
|
|
20563
|
+
var insuredIndex = personOrderList.findIndex(function (p) { return p.key === 'insuredInfo'; });
|
|
20564
|
+
if (insuredIndex >= 0) {
|
|
20565
|
+
var person = Object(lodash__WEBPACK_IMPORTED_MODULE_2__["cloneDeep"])(insuredInfo);
|
|
20566
|
+
person.key = 'insured2Info';
|
|
20567
|
+
person.eleOrderList.forEach(function (e) {
|
|
20568
|
+
if (e.key === 'title') {
|
|
20569
|
+
e.isDisabled = false;
|
|
20570
|
+
e.value = true;
|
|
20571
|
+
e.label = '第二被保人信息';
|
|
20572
|
+
}
|
|
20534
20573
|
});
|
|
20574
|
+
personOrderList.splice(insuredIndex + 1, 0, person);
|
|
20535
20575
|
}
|
|
20536
|
-
}
|
|
20537
|
-
return
|
|
20576
|
+
}
|
|
20577
|
+
return personData;
|
|
20538
20578
|
}
|
|
20539
|
-
|
|
20540
|
-
|
|
20541
|
-
|
|
20542
|
-
|
|
20543
|
-
|
|
20544
|
-
|
|
20545
|
-
|
|
20546
|
-
|
|
20547
|
-
|
|
20548
|
-
var
|
|
20549
|
-
|
|
20550
|
-
|
|
20551
|
-
|
|
20552
|
-
var
|
|
20553
|
-
|
|
20554
|
-
|
|
20555
|
-
|
|
20556
|
-
var
|
|
20557
|
-
|
|
20558
|
-
|
|
20559
|
-
|
|
20560
|
-
|
|
20561
|
-
|
|
20562
|
-
|
|
20563
|
-
|
|
20564
|
-
var
|
|
20565
|
-
|
|
20566
|
-
|
|
20567
|
-
|
|
20568
|
-
|
|
20569
|
-
|
|
20570
|
-
|
|
20571
|
-
|
|
20572
|
-
|
|
20573
|
-
|
|
20574
|
-
|
|
20575
|
-
|
|
20576
|
-
|
|
20577
|
-
|
|
20578
|
-
|
|
20579
|
-
|
|
20580
|
-
|
|
20581
|
-
|
|
20582
|
-
|
|
20583
|
-
var result = $mapDelete($m, key);
|
|
20584
|
-
if ($mapSize($m) === 0) {
|
|
20585
|
-
$m = void undefined;
|
|
20586
|
-
}
|
|
20587
|
-
return result;
|
|
20588
|
-
}
|
|
20589
|
-
return false;
|
|
20590
|
-
},
|
|
20591
|
-
get: function (key) { // eslint-disable-line consistent-return
|
|
20592
|
-
if ($m) {
|
|
20593
|
-
return $mapGet($m, key);
|
|
20594
|
-
}
|
|
20595
|
-
},
|
|
20596
|
-
has: function (key) {
|
|
20597
|
-
if ($m) {
|
|
20598
|
-
return $mapHas($m, key);
|
|
20599
|
-
}
|
|
20600
|
-
return false;
|
|
20601
|
-
},
|
|
20602
|
-
set: function (key, value) {
|
|
20603
|
-
if (!$m) {
|
|
20604
|
-
// @ts-expect-error TS can't handle narrowing a variable inside a closure
|
|
20605
|
-
$m = new $Map();
|
|
20606
|
-
}
|
|
20607
|
-
$mapSet($m, key, value);
|
|
20608
|
-
}
|
|
20609
|
-
};
|
|
20610
|
-
|
|
20611
|
-
// @ts-expect-error TODO: figure out why TS is erroring here
|
|
20612
|
-
return channel;
|
|
20613
|
-
};
|
|
20614
|
-
|
|
20615
|
-
|
|
20616
|
-
/***/ }),
|
|
20617
|
-
/* 29 */
|
|
20618
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20619
|
-
|
|
20620
|
-
"use strict";
|
|
20621
|
-
|
|
20622
|
-
|
|
20623
|
-
/** @type {import('.')} */
|
|
20624
|
-
module.exports = Object;
|
|
20625
|
-
|
|
20626
|
-
|
|
20627
|
-
/***/ }),
|
|
20628
|
-
/* 30 */
|
|
20629
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20630
|
-
|
|
20631
|
-
"use strict";
|
|
20632
|
-
|
|
20633
|
-
|
|
20634
|
-
/** @type {import('.')} */
|
|
20635
|
-
var $gOPD = __webpack_require__(57);
|
|
20636
|
-
|
|
20637
|
-
if ($gOPD) {
|
|
20638
|
-
try {
|
|
20639
|
-
$gOPD([], 'length');
|
|
20640
|
-
} catch (e) {
|
|
20641
|
-
// IE 8 has a broken gOPD
|
|
20642
|
-
$gOPD = null;
|
|
20643
|
-
}
|
|
20579
|
+
function getSingleInsurancesVerifyData(prodData, personData, parmas) {
|
|
20580
|
+
var _a, _b, _c, _d;
|
|
20581
|
+
if (parmas === void 0) { parmas = {}; }
|
|
20582
|
+
var personOrderList = personData.personOrderList;
|
|
20583
|
+
if (!(personOrderList && personOrderList.length)) {
|
|
20584
|
+
return null;
|
|
20585
|
+
}
|
|
20586
|
+
var pbId = prodData.isTemp || (prodData.policyType === 'single_insurance') ? null : parmas.planbookId;
|
|
20587
|
+
var productId = prodData.policyType === 'single_insurance' ? null : prodData.key;
|
|
20588
|
+
var insuredList = personOrderList
|
|
20589
|
+
.filter(function (p) { return ['insuredInfo', 'insured2Info'].includes(p.key) && p.eleOrderList; })
|
|
20590
|
+
.filter(function (p) {
|
|
20591
|
+
var _a;
|
|
20592
|
+
var title = (_a = p.eleOrderList) === null || _a === void 0 ? void 0 : _a.find(function (e) { return e.key === 'title'; });
|
|
20593
|
+
return title && title.value;
|
|
20594
|
+
})
|
|
20595
|
+
.map(function (p) {
|
|
20596
|
+
var _a, _b;
|
|
20597
|
+
return {
|
|
20598
|
+
key: p.key,
|
|
20599
|
+
sex: (_a = (p.eleOrderList || []).find(function (e) { return e.key === 'sex'; })) === null || _a === void 0 ? void 0 : _a.value,
|
|
20600
|
+
age: (_b = (p.eleOrderList || []).find(function (e) { return e.key === 'age'; })) === null || _b === void 0 ? void 0 : _b.value
|
|
20601
|
+
};
|
|
20602
|
+
});
|
|
20603
|
+
var applicant = null;
|
|
20604
|
+
var applicantItem = personData.personOrderList.find(function (p) { return p.key === 'applicantInfo' && p.eleOrderList; });
|
|
20605
|
+
if (applicantItem) {
|
|
20606
|
+
applicant = {
|
|
20607
|
+
key: applicantItem.key,
|
|
20608
|
+
sex: (_a = (applicantItem.eleOrderList || []).find(function (e) { return e.key === 'sex'; })) === null || _a === void 0 ? void 0 : _a.value,
|
|
20609
|
+
age: (_b = (applicantItem.eleOrderList || []).find(function (e) { return e.key === 'age'; })) === null || _b === void 0 ? void 0 : _b.value
|
|
20610
|
+
};
|
|
20611
|
+
}
|
|
20612
|
+
var insuranceIdList = (_c = convertProductData(prodData).mulInsOrderList) === null || _c === void 0 ? void 0 : _c.map(function (ins) { return ins.key; });
|
|
20613
|
+
(_d = prodData === null || prodData === void 0 ? void 0 : prodData.mulInsOrderList) === null || _d === void 0 ? void 0 : _d.reduce(function (list, ins) {
|
|
20614
|
+
return ins.key === 'common' || ins.isGroup ? list : list.concat(ins.key);
|
|
20615
|
+
}, []);
|
|
20616
|
+
return getAndCacheInsurancesVerifyData({
|
|
20617
|
+
pbId: pbId,
|
|
20618
|
+
productId: productId,
|
|
20619
|
+
insuredList: insuredList,
|
|
20620
|
+
applicant: applicant,
|
|
20621
|
+
insuranceIdList: insuranceIdList
|
|
20622
|
+
});
|
|
20644
20623
|
}
|
|
20645
|
-
|
|
20646
|
-
|
|
20647
|
-
|
|
20648
|
-
|
|
20649
|
-
|
|
20650
|
-
|
|
20651
|
-
|
|
20652
|
-
|
|
20653
|
-
|
|
20654
|
-
|
|
20655
|
-
|
|
20656
|
-
|
|
20657
|
-
|
|
20658
|
-
|
|
20659
|
-
|
|
20660
|
-
|
|
20661
|
-
|
|
20662
|
-
|
|
20663
|
-
|
|
20664
|
-
|
|
20665
|
-
|
|
20666
|
-
|
|
20667
|
-
|
|
20668
|
-
|
|
20669
|
-
/** @type {import('./Object.getPrototypeOf')} */
|
|
20670
|
-
module.exports = $Object.getPrototypeOf || null;
|
|
20671
|
-
|
|
20672
|
-
|
|
20673
|
-
/***/ }),
|
|
20674
|
-
/* 33 */
|
|
20675
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20676
|
-
|
|
20677
|
-
"use strict";
|
|
20678
|
-
|
|
20679
|
-
|
|
20680
|
-
var bind = __webpack_require__(15);
|
|
20681
|
-
var $TypeError = __webpack_require__(9);
|
|
20682
|
-
|
|
20683
|
-
var $call = __webpack_require__(20);
|
|
20684
|
-
var $actualApply = __webpack_require__(64);
|
|
20685
|
-
|
|
20686
|
-
/** @type {(args: [Function, thisArg?: unknown, ...args: unknown[]]) => Function} TODO FIXME, find a way to use import('.') */
|
|
20687
|
-
module.exports = function callBindBasic(args) {
|
|
20688
|
-
if (args.length < 1 || typeof args[0] !== 'function') {
|
|
20689
|
-
throw new $TypeError('a function is required');
|
|
20690
|
-
}
|
|
20691
|
-
return $actualApply(bind, $call, args);
|
|
20692
|
-
};
|
|
20693
|
-
|
|
20694
|
-
|
|
20695
|
-
/***/ }),
|
|
20696
|
-
/* 34 */
|
|
20697
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20698
|
-
|
|
20699
|
-
"use strict";
|
|
20700
|
-
|
|
20701
|
-
|
|
20702
|
-
/** @type {import('./functionApply')} */
|
|
20703
|
-
module.exports = Function.prototype.apply;
|
|
20704
|
-
|
|
20705
|
-
|
|
20706
|
-
/***/ }),
|
|
20707
|
-
/* 35 */
|
|
20708
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20709
|
-
|
|
20710
|
-
"use strict";
|
|
20711
|
-
|
|
20712
|
-
|
|
20713
|
-
var GetIntrinsic = __webpack_require__(19);
|
|
20714
|
-
|
|
20715
|
-
var callBindBasic = __webpack_require__(33);
|
|
20716
|
-
|
|
20717
|
-
/** @type {(thisArg: string, searchString: string, position?: number) => number} */
|
|
20718
|
-
var $indexOf = callBindBasic([GetIntrinsic('%String.prototype.indexOf%')]);
|
|
20719
|
-
|
|
20720
|
-
/** @type {import('.')} */
|
|
20721
|
-
module.exports = function callBoundIntrinsic(name, allowMissing) {
|
|
20722
|
-
/* eslint no-extra-parens: 0 */
|
|
20723
|
-
|
|
20724
|
-
var intrinsic = /** @type {(this: unknown, ...args: unknown[]) => unknown} */ (GetIntrinsic(name, !!allowMissing));
|
|
20725
|
-
if (typeof intrinsic === 'function' && $indexOf(name, '.prototype.') > -1) {
|
|
20726
|
-
return callBindBasic(/** @type {const} */ ([intrinsic]));
|
|
20727
|
-
}
|
|
20728
|
-
return intrinsic;
|
|
20729
|
-
};
|
|
20730
|
-
|
|
20731
|
-
|
|
20732
|
-
/***/ }),
|
|
20733
|
-
/* 36 */
|
|
20734
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
20735
|
-
|
|
20736
|
-
"use strict";
|
|
20737
|
-
|
|
20738
|
-
|
|
20739
|
-
var formats = __webpack_require__(21);
|
|
20740
|
-
|
|
20741
|
-
var has = Object.prototype.hasOwnProperty;
|
|
20742
|
-
var isArray = Array.isArray;
|
|
20743
|
-
|
|
20744
|
-
var hexTable = (function () {
|
|
20745
|
-
var array = [];
|
|
20746
|
-
for (var i = 0; i < 256; ++i) {
|
|
20747
|
-
array.push('%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase());
|
|
20624
|
+
var getAndCacheInsurancesVerifyData = Object(lodash__WEBPACK_IMPORTED_MODULE_2__["memoize"])(function (params) {
|
|
20625
|
+
var url = "".concat(_src_js_variables_js__WEBPACK_IMPORTED_MODULE_3__[/* APP_HOSTNAME */ "a"], "/planBook/input/insurance/verifyData");
|
|
20626
|
+
return fetch(url, {
|
|
20627
|
+
method: 'POST',
|
|
20628
|
+
credentials: 'include',
|
|
20629
|
+
headers: {
|
|
20630
|
+
Accept: 'application/json, text/plain, */*',
|
|
20631
|
+
'Content-Type': 'application/json;'
|
|
20632
|
+
},
|
|
20633
|
+
body: JSON.stringify(params)
|
|
20634
|
+
})
|
|
20635
|
+
.then(function (response) { return response.json(); })
|
|
20636
|
+
.then(function (_a) {
|
|
20637
|
+
var success = _a.success, data = _a.data;
|
|
20638
|
+
if (!success || !data) {
|
|
20639
|
+
return Promise.reject();
|
|
20640
|
+
}
|
|
20641
|
+
return Promise.resolve(data);
|
|
20642
|
+
})
|
|
20643
|
+
.catch(function () { });
|
|
20644
|
+
}, function (params) { return qs__WEBPACK_IMPORTED_MODULE_1___default.a.stringify(params); });
|
|
20645
|
+
function getElementVerifyFromProductVerify(verify, insurances, option) {
|
|
20646
|
+
if (!verify || !verify.key || !verify[verify.key] || !insurances || !option) {
|
|
20647
|
+
return verify;
|
|
20748
20648
|
}
|
|
20749
|
-
|
|
20750
|
-
|
|
20751
|
-
|
|
20752
|
-
|
|
20753
|
-
|
|
20754
|
-
|
|
20755
|
-
|
|
20756
|
-
|
|
20757
|
-
|
|
20758
|
-
|
|
20759
|
-
|
|
20760
|
-
|
|
20761
|
-
|
|
20762
|
-
|
|
20763
|
-
|
|
20649
|
+
var insuranceInfo = {};
|
|
20650
|
+
insurances.forEach(function (ins) {
|
|
20651
|
+
if (['common', option.insuranceKey].includes(ins.key)) {
|
|
20652
|
+
insuranceInfo = Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, insuranceInfo), Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* convertEleOrderListToObj */ "c"])(ins));
|
|
20653
|
+
}
|
|
20654
|
+
});
|
|
20655
|
+
insuranceInfo = Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, insuranceInfo), option);
|
|
20656
|
+
var temp = verify;
|
|
20657
|
+
var hasElementKey = verify.key === option.elementKey;
|
|
20658
|
+
while (temp && temp.key && temp.key !== option.elementKey) {
|
|
20659
|
+
temp = temp[temp.key].find(function (v) { return v.value == insuranceInfo[temp.key]; });
|
|
20660
|
+
if (temp && temp.key === option.elementKey) {
|
|
20661
|
+
hasElementKey = true;
|
|
20662
|
+
}
|
|
20663
|
+
}
|
|
20664
|
+
if (!hasElementKey) {
|
|
20665
|
+
return null;
|
|
20666
|
+
}
|
|
20667
|
+
if (temp && temp[option.elementKey]) {
|
|
20668
|
+
return temp[option.elementKey];
|
|
20669
|
+
}
|
|
20670
|
+
return temp ? [temp] : null;
|
|
20671
|
+
}
|
|
20672
|
+
function setCommonInfo(prodData) {
|
|
20673
|
+
if (!prodData || !prodData.mulInsOrderList) {
|
|
20674
|
+
return prodData;
|
|
20675
|
+
}
|
|
20676
|
+
var common = {
|
|
20677
|
+
key: 'common',
|
|
20678
|
+
eleOrderList: []
|
|
20679
|
+
};
|
|
20680
|
+
prodData.mulInsOrderList.forEach(function (ins) {
|
|
20681
|
+
if (!ins.eleOrderList) {
|
|
20682
|
+
return;
|
|
20683
|
+
}
|
|
20684
|
+
ins.eleOrderList.forEach(function (ele) {
|
|
20685
|
+
if (ele.common && common.eleOrderList.every(function (e) { return e.key !== ele.key; })) {
|
|
20686
|
+
common.eleOrderList.push(ele);
|
|
20687
|
+
}
|
|
20688
|
+
});
|
|
20689
|
+
ins.eleOrderList = ins.eleOrderList.filter(function (ele) { return !ele.common; });
|
|
20690
|
+
});
|
|
20691
|
+
if (!common.eleOrderList.length) {
|
|
20692
|
+
return prodData;
|
|
20693
|
+
}
|
|
20694
|
+
prodData.mulInsOrderList = prodData.mulInsOrderList.filter(function (ins) { return ins.key !== 'common'; });
|
|
20695
|
+
prodData.mulInsOrderList.unshift(common);
|
|
20696
|
+
if (prodData.mulInsOrderList[1]) {
|
|
20697
|
+
prodData.mulInsOrderList[1].isFollowing = true;
|
|
20698
|
+
}
|
|
20699
|
+
return prodData;
|
|
20700
|
+
}
|
|
20701
|
+
function setGroupInsurance(prodData) {
|
|
20702
|
+
if (!prodData.mulInsOrderList) {
|
|
20703
|
+
return prodData;
|
|
20704
|
+
}
|
|
20705
|
+
var groupInsuranceList = prodData && prodData.mulInsOrderList && prodData.mulInsOrderList.filter(function (ins) { return !!ins.groupKey; });
|
|
20706
|
+
if (!groupInsuranceList || !groupInsuranceList.length) {
|
|
20707
|
+
return prodData;
|
|
20708
|
+
}
|
|
20709
|
+
var oldGroupInsList = prodData.mulInsOrderList.filter(function (ins) { return ins.isGroup; });
|
|
20710
|
+
var newGroupInsMap = {};
|
|
20711
|
+
prodData.mulInsOrderList = prodData.mulInsOrderList.filter(function (ins) { return !ins.isGroup; });
|
|
20712
|
+
groupInsuranceList.forEach(function (ins) {
|
|
20713
|
+
var oldGroupIns = oldGroupInsList.find(function (gIns) { return gIns.key === ins.groupKey; });
|
|
20714
|
+
var oldTitleEle = {};
|
|
20715
|
+
var oldInsuranceIdEle = {};
|
|
20716
|
+
if (oldGroupIns && oldGroupIns.eleOrderList) {
|
|
20717
|
+
oldTitleEle = oldGroupIns.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20718
|
+
oldInsuranceIdEle = oldGroupIns.eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20719
|
+
}
|
|
20720
|
+
if (ins.groupKey) {
|
|
20721
|
+
newGroupInsMap[ins.groupKey] = newGroupInsMap[ins.groupKey] || {
|
|
20722
|
+
key: ins.groupKey,
|
|
20723
|
+
name: ins.groupName,
|
|
20724
|
+
huomian: ins.huomian,
|
|
20725
|
+
isGroup: true,
|
|
20726
|
+
eleOrderList: [
|
|
20727
|
+
{
|
|
20728
|
+
key: 'title',
|
|
20729
|
+
value: (oldTitleEle && oldTitleEle.value) || false,
|
|
20730
|
+
isDisabled: false,
|
|
20731
|
+
componentName: 'cmCommonTitle',
|
|
20732
|
+
labelName: ins.groupName
|
|
20733
|
+
},
|
|
20734
|
+
{
|
|
20735
|
+
key: 'insuranceId',
|
|
20736
|
+
value: (oldInsuranceIdEle && oldInsuranceIdEle.value) || (ins.isCheckbox ? [] : ''),
|
|
20737
|
+
componentName: ins.isCheckbox ? 'cmCommonCheckbox' : 'cmCommonRadio',
|
|
20738
|
+
opts: []
|
|
20739
|
+
}
|
|
20740
|
+
]
|
|
20741
|
+
};
|
|
20742
|
+
var titleEle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20743
|
+
var insuranceIdEle = newGroupInsMap[ins.groupKey].eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20744
|
+
insuranceIdEle.opts.push({
|
|
20745
|
+
val: ins.key,
|
|
20746
|
+
code: ins.code,
|
|
20747
|
+
desc: titleEle.labelName,
|
|
20748
|
+
isDisabled: titleEle.isDisabled
|
|
20749
|
+
});
|
|
20750
|
+
}
|
|
20751
|
+
});
|
|
20752
|
+
var _loop_2 = function (k) {
|
|
20753
|
+
var nGroupTitle = newGroupInsMap[k].eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20754
|
+
var nGroupInsuranceId = newGroupInsMap[k].eleOrderList.find(function (e) { return e.key === 'insuranceId'; });
|
|
20755
|
+
if (nGroupTitle && nGroupInsuranceId) {
|
|
20756
|
+
if (nGroupInsuranceId.opts && nGroupInsuranceId.opts.length) {
|
|
20757
|
+
if (nGroupInsuranceId.opts.every(function (opt) { return !!opt.isDisabled; })) {
|
|
20758
|
+
nGroupTitle.value = false;
|
|
20759
|
+
nGroupTitle.isDisabled = true;
|
|
20760
|
+
}
|
|
20761
|
+
else {
|
|
20762
|
+
nGroupTitle.isDisabled = false;
|
|
20763
|
+
}
|
|
20764
|
+
}
|
|
20765
|
+
var groupInsList = prodData.mulInsOrderList.filter(function (ins) { return ins.groupKey == k; });
|
|
20766
|
+
if (groupInsList && groupInsList.length) {
|
|
20767
|
+
if (groupInsList.some(function (ins) {
|
|
20768
|
+
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20769
|
+
return ins.required && subTitle && !subTitle.isDisabled;
|
|
20770
|
+
})) {
|
|
20771
|
+
nGroupTitle.value = true;
|
|
20772
|
+
nGroupTitle.isDisabled = true;
|
|
20773
|
+
}
|
|
20774
|
+
var notDisabledInsurances = groupInsList.filter(function (ins) {
|
|
20775
|
+
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20776
|
+
return subTitle && !subTitle.isDisabled;
|
|
20777
|
+
});
|
|
20778
|
+
var checkedInsurances = notDisabledInsurances.find(function (ins) {
|
|
20779
|
+
var subTitle = ins.eleOrderList.find(function (e) { return e.key === 'title'; });
|
|
20780
|
+
return subTitle && subTitle.value;
|
|
20781
|
+
});
|
|
20782
|
+
if (!nGroupInsuranceId.value) {
|
|
20783
|
+
if (checkedInsurances) {
|
|
20784
|
+
nGroupInsuranceId.value = checkedInsurances.key;
|
|
20785
|
+
nGroupTitle.value = true;
|
|
20786
|
+
}
|
|
20787
|
+
else if (nGroupTitle.value) {
|
|
20788
|
+
if (notDisabledInsurances[0]) {
|
|
20789
|
+
nGroupInsuranceId.value = notDisabledInsurances[0].key;
|
|
20790
|
+
}
|
|
20791
|
+
}
|
|
20764
20792
|
}
|
|
20765
20793
|
}
|
|
20766
|
-
|
|
20767
|
-
item.obj[item.prop] = compacted;
|
|
20768
20794
|
}
|
|
20769
|
-
|
|
20770
|
-
|
|
20771
|
-
|
|
20772
|
-
|
|
20773
|
-
|
|
20774
|
-
|
|
20775
|
-
|
|
20776
|
-
|
|
20795
|
+
if (nGroupInsuranceId) {
|
|
20796
|
+
if (nGroupInsuranceId.value) {
|
|
20797
|
+
if (nGroupInsuranceId.value.constructor === Array) {
|
|
20798
|
+
if (nGroupInsuranceId.opts) {
|
|
20799
|
+
nGroupInsuranceId.opts = nGroupInsuranceId.opts.filter(function (opt) { return nGroupInsuranceId.value.indexOf(opt.val) !== -1 && !opt.isDisabled; });
|
|
20800
|
+
}
|
|
20801
|
+
}
|
|
20802
|
+
else {
|
|
20803
|
+
var opt = nGroupInsuranceId.opts.find(function (o) { return o.val === nGroupInsuranceId.value; });
|
|
20804
|
+
if (opt && opt.isDisabled) {
|
|
20805
|
+
nGroupInsuranceId.value = '';
|
|
20806
|
+
}
|
|
20807
|
+
}
|
|
20808
|
+
}
|
|
20809
|
+
if (nGroupInsuranceId.value) {
|
|
20810
|
+
var checkedIns = prodData.mulInsOrderList.find(function (ins) { return ins.key === nGroupInsuranceId.value; });
|
|
20811
|
+
if (checkedIns) {
|
|
20812
|
+
for (var ck in checkedIns) {
|
|
20813
|
+
if (!['code', 'groupKey', 'groupName', 'isFollowing', 'key', 'name', 'accountData', 'reduceBaofData'].includes(ck)) {
|
|
20814
|
+
if (ck === 'eleOrderList') {
|
|
20815
|
+
newGroupInsMap[k][ck] = newGroupInsMap[k][ck].concat(checkedIns[ck].filter(function (ele) { return ele.key !== 'title'; }));
|
|
20816
|
+
}
|
|
20817
|
+
else {
|
|
20818
|
+
newGroupInsMap[k][ck] = checkedIns[ck];
|
|
20819
|
+
}
|
|
20820
|
+
}
|
|
20821
|
+
}
|
|
20822
|
+
}
|
|
20823
|
+
}
|
|
20777
20824
|
}
|
|
20778
|
-
|
|
20779
|
-
|
|
20780
|
-
|
|
20781
|
-
|
|
20782
|
-
|
|
20783
|
-
var merge = function merge(target, source, options) {
|
|
20784
|
-
/* eslint no-param-reassign: 0 */
|
|
20785
|
-
if (!source) {
|
|
20786
|
-
return target;
|
|
20787
|
-
}
|
|
20788
|
-
|
|
20789
|
-
if (typeof source !== 'object' && typeof source !== 'function') {
|
|
20790
|
-
if (isArray(target)) {
|
|
20791
|
-
target.push(source);
|
|
20792
|
-
} else if (target && typeof target === 'object') {
|
|
20793
|
-
if (
|
|
20794
|
-
(options && (options.plainObjects || options.allowPrototypes))
|
|
20795
|
-
|| !has.call(Object.prototype, source)
|
|
20796
|
-
) {
|
|
20797
|
-
target[source] = true;
|
|
20825
|
+
var index = -1;
|
|
20826
|
+
prodData.mulInsOrderList.forEach(function (ins, i) {
|
|
20827
|
+
if (ins.groupKey === k) {
|
|
20828
|
+
index = i;
|
|
20798
20829
|
}
|
|
20799
|
-
}
|
|
20800
|
-
|
|
20830
|
+
});
|
|
20831
|
+
if (index >= 0) {
|
|
20832
|
+
prodData.mulInsOrderList.splice(index + 1, 0, newGroupInsMap[k]);
|
|
20801
20833
|
}
|
|
20802
|
-
|
|
20803
|
-
|
|
20834
|
+
};
|
|
20835
|
+
for (var k in newGroupInsMap) {
|
|
20836
|
+
_loop_2(k);
|
|
20804
20837
|
}
|
|
20805
|
-
|
|
20806
|
-
|
|
20807
|
-
|
|
20838
|
+
return prodData;
|
|
20839
|
+
}
|
|
20840
|
+
function isHideProduct(prodData, productVerifyData, personOrderList) {
|
|
20841
|
+
var ageRangeProd = {};
|
|
20842
|
+
if (prodData && productVerifyData && Object.keys(productVerifyData).length && personOrderList) {
|
|
20843
|
+
if (prodData.mulInsOrderList) {
|
|
20844
|
+
var hasRequiredIns_1 = prodData.mulInsOrderList.some(function (ins) { return !!ins.required && productVerifyData[ins.key]; });
|
|
20845
|
+
prodData.mulInsOrderList.forEach(function (ins) {
|
|
20846
|
+
var insuranceVerifyData = productVerifyData[ins.key];
|
|
20847
|
+
if (insuranceVerifyData) {
|
|
20848
|
+
if ((!ins.huomian || ins.huomian == 'beiHuomian') && (!hasRequiredIns_1 || (hasRequiredIns_1 && ins.required))) {
|
|
20849
|
+
insuranceVerifyData.forEach(function (verify) {
|
|
20850
|
+
ageRangeProd[verify.sex] = ageRangeProd[verify.sex] || [];
|
|
20851
|
+
ageRangeProd[verify.sex] = [
|
|
20852
|
+
Math.min(ageRangeProd[verify.sex][0] === undefined ? verify.minAge : ageRangeProd[verify.sex][0], verify.minAge),
|
|
20853
|
+
Math.max(ageRangeProd[verify.sex][1] === undefined ? verify.maxAge : ageRangeProd[verify.sex][1], verify.maxAge)
|
|
20854
|
+
];
|
|
20855
|
+
});
|
|
20856
|
+
}
|
|
20857
|
+
}
|
|
20858
|
+
});
|
|
20859
|
+
}
|
|
20860
|
+
var _a = personOrderList.find(function (p) { return p.key === 'insuredInfo'; }), sex = _a.sex, age = _a.age;
|
|
20861
|
+
if (ageRangeProd[sex] && age >= ageRangeProd[sex][0] && age <= ageRangeProd[sex][1]) {
|
|
20862
|
+
prodData.hide = false;
|
|
20863
|
+
}
|
|
20864
|
+
else {
|
|
20865
|
+
prodData.hadChoice = false;
|
|
20866
|
+
prodData.hide = true;
|
|
20867
|
+
prodData.totalBaof = null;
|
|
20868
|
+
}
|
|
20808
20869
|
}
|
|
20809
|
-
|
|
20810
|
-
|
|
20811
|
-
|
|
20812
|
-
|
|
20870
|
+
return ageRangeProd;
|
|
20871
|
+
}
|
|
20872
|
+
function verifyProductRules(_a) {
|
|
20873
|
+
var personData = _a.personData, productData = _a.productData, insData = _a.insData, eleData = _a.eleData;
|
|
20874
|
+
var errorMsg = '';
|
|
20875
|
+
var personOrderList = Object(_person__WEBPACK_IMPORTED_MODULE_5__[/* convertPersonData */ "a"])(personData, personData.personOrderList.map(function (p) { return p.key; }));
|
|
20876
|
+
if (productData.restrictList && productData.restrictList.length) {
|
|
20877
|
+
errorMsg = restrictInsurancesInProduct({
|
|
20878
|
+
personOrderList: personOrderList,
|
|
20879
|
+
productData: productData,
|
|
20880
|
+
insData: insData,
|
|
20881
|
+
eleData: eleData
|
|
20882
|
+
});
|
|
20813
20883
|
}
|
|
20814
|
-
|
|
20815
|
-
|
|
20816
|
-
|
|
20817
|
-
|
|
20818
|
-
|
|
20819
|
-
|
|
20820
|
-
|
|
20821
|
-
|
|
20822
|
-
|
|
20884
|
+
if (!errorMsg && productData.mulInsOrderList) {
|
|
20885
|
+
productData.mulInsOrderList.forEach(function (ins) {
|
|
20886
|
+
if (ins.eleOrderList) {
|
|
20887
|
+
ins.eleOrderList.forEach(function (ele) {
|
|
20888
|
+
errorMsg =
|
|
20889
|
+
errorMsg ||
|
|
20890
|
+
Object(_insurance__WEBPACK_IMPORTED_MODULE_6__[/* restrictElementsInInsurance */ "d"])({
|
|
20891
|
+
personOrderList: personOrderList,
|
|
20892
|
+
insData: ins,
|
|
20893
|
+
eleData: ele
|
|
20894
|
+
});
|
|
20895
|
+
});
|
|
20896
|
+
}
|
|
20897
|
+
});
|
|
20898
|
+
}
|
|
20899
|
+
return errorMsg;
|
|
20900
|
+
}
|
|
20901
|
+
function restrictInsurancesInProduct(_a) {
|
|
20902
|
+
var personOrderList = _a.personOrderList, productData = _a.productData, insData = _a.insData, eleData = _a.eleData;
|
|
20903
|
+
var errorMsg = '';
|
|
20904
|
+
var restrictList = productData.restrictList;
|
|
20905
|
+
if (restrictList && restrictList.length) {
|
|
20906
|
+
restrictList.forEach(function (restrict) {
|
|
20907
|
+
var insuredInfo = personOrderList.find(function (p) { return p.key === 'insuredInfo'; });
|
|
20908
|
+
var productInfo = convertProductData(productData);
|
|
20909
|
+
var prodVerifyData = {
|
|
20910
|
+
age: insuredInfo.age,
|
|
20911
|
+
sex: insuredInfo.sex,
|
|
20912
|
+
common: productInfo.common
|
|
20913
|
+
};
|
|
20914
|
+
productInfo.mulInsOrderList.forEach(function (ins) {
|
|
20915
|
+
prodVerifyData['i' + ins.key] = ins;
|
|
20916
|
+
});
|
|
20917
|
+
restrict.rCondition = restrict.rCondition.replace(/(%)(\d+)(\.*\w*)(%)/g, 'prodVerifyData.i$2$3');
|
|
20918
|
+
restrict.rCondition = restrict.rCondition.replace(/(%)(\w*\.*\w*)(%)/g, 'prodVerifyData.$2');
|
|
20919
|
+
var curIns = productData.mulInsOrderList.find(function (ins) { return ins.key === restrict.rInsKey; });
|
|
20920
|
+
var curEle = curIns ? {} : null;
|
|
20921
|
+
if (curIns) {
|
|
20922
|
+
curEle = curIns.eleOrderList.find(function (e) { return e.key === restrict.rEleKey; });
|
|
20923
|
+
}
|
|
20924
|
+
if (curEle) {
|
|
20925
|
+
switch (restrict.rType) {
|
|
20926
|
+
case 1:
|
|
20927
|
+
var isDisabled = curEle.isDisabled;
|
|
20928
|
+
var value = curEle.value;
|
|
20929
|
+
if (eval(restrict.rCondition)) {
|
|
20930
|
+
isDisabled = false;
|
|
20931
|
+
if (restrict.other && restrict.other.includes('required')) {
|
|
20932
|
+
value = true;
|
|
20933
|
+
isDisabled = true;
|
|
20934
|
+
}
|
|
20935
|
+
}
|
|
20936
|
+
else {
|
|
20937
|
+
isDisabled = true;
|
|
20938
|
+
if (restrict.other && restrict.other.includes('optional')) {
|
|
20939
|
+
isDisabled = false;
|
|
20940
|
+
}
|
|
20941
|
+
if (isDisabled) {
|
|
20942
|
+
value = false;
|
|
20943
|
+
}
|
|
20944
|
+
if (insData && eleData && restrict.rCondition.search(insData.key + '.' + eleData.key) !== -1) {
|
|
20945
|
+
value = false;
|
|
20946
|
+
}
|
|
20947
|
+
}
|
|
20948
|
+
curEle.isDisabled = isDisabled;
|
|
20949
|
+
curEle.value = value;
|
|
20950
|
+
break;
|
|
20951
|
+
case 2: {
|
|
20952
|
+
var rangeSelect_1 = eval(restrict.rCondition);
|
|
20953
|
+
if (rangeSelect_1 !== undefined && rangeSelect_1 !== null) {
|
|
20954
|
+
curEle.opts.forEach(function (opt) {
|
|
20955
|
+
var optNum = Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* getNumberFromYear */ "h"])(opt.val, prodVerifyData.age);
|
|
20956
|
+
var rangeSelectNum = rangeSelect_1.constructor === Array
|
|
20957
|
+
? [
|
|
20958
|
+
rangeSelect_1[0] && Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* getNumberFromYear */ "h"])(rangeSelect_1[0], prodVerifyData.age),
|
|
20959
|
+
rangeSelect_1[1] && Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* getNumberFromYear */ "h"])(rangeSelect_1[1], prodVerifyData.age)
|
|
20960
|
+
]
|
|
20961
|
+
: Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* getNumberFromYear */ "h"])(rangeSelect_1, prodVerifyData.age);
|
|
20962
|
+
if (rangeSelect_1) {
|
|
20963
|
+
if (rangeSelect_1.constructor === Array) {
|
|
20964
|
+
opt.isHide =
|
|
20965
|
+
(rangeSelect_1[0] && optNum < rangeSelectNum[0]) || (rangeSelect_1[1] && optNum > rangeSelectNum[1]);
|
|
20966
|
+
}
|
|
20967
|
+
else {
|
|
20968
|
+
opt.isHide = optNum > rangeSelectNum;
|
|
20969
|
+
}
|
|
20970
|
+
}
|
|
20971
|
+
});
|
|
20972
|
+
if (!(curEle.isHide && !curEle.isDisabled) && curEle.opts) {
|
|
20973
|
+
var validOptions = curEle.opts.filter(function (o) { return !o.isDisabled && !o.isHide && !o.isInvalid; });
|
|
20974
|
+
var activeOption = validOptions.find(function (o) { return o.val === curEle.value; });
|
|
20975
|
+
if (!activeOption && validOptions.length) {
|
|
20976
|
+
curEle.value = validOptions[0].val;
|
|
20977
|
+
}
|
|
20978
|
+
}
|
|
20979
|
+
}
|
|
20980
|
+
break;
|
|
20981
|
+
}
|
|
20982
|
+
case 3: {
|
|
20983
|
+
if ((!insData && !eleData) ||
|
|
20984
|
+
(restrict.rInsKey === insData.key && restrict.rEleKey === eleData.key) ||
|
|
20985
|
+
restrict.rCondition.search("prodVerifyData.i".concat(insData.key, ".").concat(eleData.key)) !== -1) {
|
|
20986
|
+
var rangeVal = eval(restrict.rCondition);
|
|
20987
|
+
if (rangeVal !== undefined && rangeVal !== null) {
|
|
20988
|
+
if (rangeVal.constructor === Array) {
|
|
20989
|
+
if (rangeVal[0] && curEle.value && curEle.value < rangeVal[0]) {
|
|
20990
|
+
errorMsg =
|
|
20991
|
+
restrict.rMsg || "".concat(curIns.name, "\u7684").concat(curEle.labelName, "\u4E0D\u5F97\u5C0F\u4E8E").concat(Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* converUnit10000 */ "b"])(rangeVal[0]));
|
|
20992
|
+
}
|
|
20993
|
+
if (rangeVal[1] && curEle.value && curEle.value > rangeVal[1]) {
|
|
20994
|
+
errorMsg =
|
|
20995
|
+
restrict.rMsg || "".concat(curIns.name, "\u7684").concat(curEle.labelName, "\u4E0D\u5F97\u5927\u4E8E").concat(Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* converUnit10000 */ "b"])(rangeVal[1]));
|
|
20996
|
+
}
|
|
20997
|
+
}
|
|
20998
|
+
else if (rangeVal.constructor === String || rangeVal.constructor === Number) {
|
|
20999
|
+
if (rangeVal) {
|
|
21000
|
+
curEle.value = rangeVal;
|
|
21001
|
+
}
|
|
21002
|
+
}
|
|
21003
|
+
}
|
|
21004
|
+
}
|
|
21005
|
+
break;
|
|
21006
|
+
}
|
|
20823
21007
|
}
|
|
20824
|
-
} else {
|
|
20825
|
-
target[i] = item;
|
|
20826
21008
|
}
|
|
20827
21009
|
});
|
|
20828
|
-
return target;
|
|
20829
|
-
}
|
|
20830
|
-
|
|
20831
|
-
return Object.keys(source).reduce(function (acc, key) {
|
|
20832
|
-
var value = source[key];
|
|
20833
|
-
|
|
20834
|
-
if (has.call(acc, key)) {
|
|
20835
|
-
acc[key] = merge(acc[key], value, options);
|
|
20836
|
-
} else {
|
|
20837
|
-
acc[key] = value;
|
|
20838
|
-
}
|
|
20839
|
-
return acc;
|
|
20840
|
-
}, mergeTarget);
|
|
20841
|
-
};
|
|
20842
|
-
|
|
20843
|
-
var assign = function assignSingleSource(target, source) {
|
|
20844
|
-
return Object.keys(source).reduce(function (acc, key) {
|
|
20845
|
-
acc[key] = source[key];
|
|
20846
|
-
return acc;
|
|
20847
|
-
}, target);
|
|
20848
|
-
};
|
|
20849
|
-
|
|
20850
|
-
var decode = function (str, defaultDecoder, charset) {
|
|
20851
|
-
var strWithoutPlus = str.replace(/\+/g, ' ');
|
|
20852
|
-
if (charset === 'iso-8859-1') {
|
|
20853
|
-
// unescape never throws, no try...catch needed:
|
|
20854
|
-
return strWithoutPlus.replace(/%[0-9a-f]{2}/gi, unescape);
|
|
20855
|
-
}
|
|
20856
|
-
// utf-8
|
|
20857
|
-
try {
|
|
20858
|
-
return decodeURIComponent(strWithoutPlus);
|
|
20859
|
-
} catch (e) {
|
|
20860
|
-
return strWithoutPlus;
|
|
20861
|
-
}
|
|
20862
|
-
};
|
|
20863
|
-
|
|
20864
|
-
var limit = 1024;
|
|
20865
|
-
|
|
20866
|
-
/* eslint operator-linebreak: [2, "before"] */
|
|
20867
|
-
|
|
20868
|
-
var encode = function encode(str, defaultEncoder, charset, kind, format) {
|
|
20869
|
-
// This code was originally written by Brian White (mscdex) for the io.js core querystring library.
|
|
20870
|
-
// It has been adapted here for stricter adherence to RFC 3986
|
|
20871
|
-
if (str.length === 0) {
|
|
20872
|
-
return str;
|
|
20873
21010
|
}
|
|
20874
|
-
|
|
20875
|
-
|
|
20876
|
-
|
|
20877
|
-
|
|
20878
|
-
|
|
20879
|
-
string = String(str);
|
|
21011
|
+
return errorMsg;
|
|
21012
|
+
}
|
|
21013
|
+
function convertProductData(prodData) {
|
|
21014
|
+
if (!prodData) {
|
|
21015
|
+
return prodData;
|
|
20880
21016
|
}
|
|
20881
|
-
|
|
20882
|
-
|
|
20883
|
-
return escape(string).replace(/%u[0-9a-f]{4}/gi, function ($0) {
|
|
20884
|
-
return '%26%23' + parseInt($0.slice(2), 16) + '%3B';
|
|
20885
|
-
});
|
|
21017
|
+
if (!prodData.mulInsOrderList) {
|
|
21018
|
+
return prodData;
|
|
20886
21019
|
}
|
|
20887
|
-
|
|
20888
|
-
|
|
20889
|
-
|
|
20890
|
-
|
|
20891
|
-
|
|
20892
|
-
|
|
20893
|
-
for (var i = 0; i < segment.length; ++i) {
|
|
20894
|
-
var c = segment.charCodeAt(i);
|
|
20895
|
-
if (
|
|
20896
|
-
c === 0x2D // -
|
|
20897
|
-
|| c === 0x2E // .
|
|
20898
|
-
|| c === 0x5F // _
|
|
20899
|
-
|| c === 0x7E // ~
|
|
20900
|
-
|| (c >= 0x30 && c <= 0x39) // 0-9
|
|
20901
|
-
|| (c >= 0x41 && c <= 0x5A) // a-z
|
|
20902
|
-
|| (c >= 0x61 && c <= 0x7A) // A-Z
|
|
20903
|
-
|| (format === formats.RFC1738 && (c === 0x28 || c === 0x29)) // ( )
|
|
20904
|
-
) {
|
|
20905
|
-
arr[arr.length] = segment.charAt(i);
|
|
20906
|
-
continue;
|
|
20907
|
-
}
|
|
20908
|
-
|
|
20909
|
-
if (c < 0x80) {
|
|
20910
|
-
arr[arr.length] = hexTable[c];
|
|
20911
|
-
continue;
|
|
20912
|
-
}
|
|
20913
|
-
|
|
20914
|
-
if (c < 0x800) {
|
|
20915
|
-
arr[arr.length] = hexTable[0xC0 | (c >> 6)]
|
|
20916
|
-
+ hexTable[0x80 | (c & 0x3F)];
|
|
20917
|
-
continue;
|
|
20918
|
-
}
|
|
20919
|
-
|
|
20920
|
-
if (c < 0xD800 || c >= 0xE000) {
|
|
20921
|
-
arr[arr.length] = hexTable[0xE0 | (c >> 12)]
|
|
20922
|
-
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
|
20923
|
-
+ hexTable[0x80 | (c & 0x3F)];
|
|
20924
|
-
continue;
|
|
20925
|
-
}
|
|
20926
|
-
|
|
20927
|
-
i += 1;
|
|
20928
|
-
c = 0x10000 + (((c & 0x3FF) << 10) | (segment.charCodeAt(i) & 0x3FF));
|
|
20929
|
-
|
|
20930
|
-
arr[arr.length] = hexTable[0xF0 | (c >> 18)]
|
|
20931
|
-
+ hexTable[0x80 | ((c >> 12) & 0x3F)]
|
|
20932
|
-
+ hexTable[0x80 | ((c >> 6) & 0x3F)]
|
|
20933
|
-
+ hexTable[0x80 | (c & 0x3F)];
|
|
21020
|
+
var productData = Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, prodData), { common: {}, mulInsOrderList: [] });
|
|
21021
|
+
prodData.mulInsOrderList.forEach(function (insurance) {
|
|
21022
|
+
var insuranceData = Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* convertEleOrderListToObj */ "c"])(insurance);
|
|
21023
|
+
if (insuranceData.key == 'common') {
|
|
21024
|
+
productData.common = insuranceData;
|
|
21025
|
+
return;
|
|
20934
21026
|
}
|
|
20935
|
-
|
|
20936
|
-
|
|
20937
|
-
|
|
20938
|
-
|
|
20939
|
-
|
|
20940
|
-
|
|
20941
|
-
|
|
20942
|
-
|
|
20943
|
-
|
|
20944
|
-
|
|
20945
|
-
|
|
20946
|
-
|
|
20947
|
-
|
|
20948
|
-
|
|
20949
|
-
|
|
20950
|
-
|
|
20951
|
-
|
|
20952
|
-
var key = keys[j];
|
|
20953
|
-
var val = obj[key];
|
|
20954
|
-
if (typeof val === 'object' && val !== null && refs.indexOf(val) === -1) {
|
|
20955
|
-
queue.push({ obj: obj, prop: key });
|
|
20956
|
-
refs.push(val);
|
|
21027
|
+
if (insuranceData.title && !insuranceData.groupKey) {
|
|
21028
|
+
if (insuranceData.isGroup) {
|
|
21029
|
+
var insuranceId = insuranceData.insuranceId.constructor == Array ? insuranceData.insuranceId : [insuranceData.insuranceId];
|
|
21030
|
+
insuranceId.forEach(function (insId) {
|
|
21031
|
+
var checkedIns = prodData.mulInsOrderList.find(function (p) { return p.key === insId; });
|
|
21032
|
+
if (checkedIns) {
|
|
21033
|
+
var checkedInsData_1 = Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* convertEleOrderListToObj */ "c"])(checkedIns);
|
|
21034
|
+
insurance.eleOrderList &&
|
|
21035
|
+
insurance.eleOrderList.forEach(function (ele) {
|
|
21036
|
+
if (!['title', 'insuranceId'].includes(ele.key)) {
|
|
21037
|
+
checkedInsData_1[ele.key] = insuranceData[ele.key];
|
|
21038
|
+
}
|
|
21039
|
+
});
|
|
21040
|
+
productData.mulInsOrderList.push(Object(_common__WEBPACK_IMPORTED_MODULE_4__[/* deepCopy */ "d"])(checkedInsData_1));
|
|
21041
|
+
}
|
|
21042
|
+
});
|
|
21043
|
+
return;
|
|
20957
21044
|
}
|
|
21045
|
+
productData.mulInsOrderList.push(insuranceData);
|
|
20958
21046
|
}
|
|
21047
|
+
});
|
|
21048
|
+
return productData;
|
|
21049
|
+
}
|
|
21050
|
+
function clearAddAndTakeAndAdjustBaoeData(productData) {
|
|
21051
|
+
if (!productData) {
|
|
21052
|
+
return productData;
|
|
20959
21053
|
}
|
|
20960
|
-
|
|
20961
|
-
|
|
20962
|
-
|
|
20963
|
-
return value;
|
|
20964
|
-
};
|
|
20965
|
-
|
|
20966
|
-
var isRegExp = function isRegExp(obj) {
|
|
20967
|
-
return Object.prototype.toString.call(obj) === '[object RegExp]';
|
|
20968
|
-
};
|
|
20969
|
-
|
|
20970
|
-
var isBuffer = function isBuffer(obj) {
|
|
20971
|
-
if (!obj || typeof obj !== 'object') {
|
|
20972
|
-
return false;
|
|
21054
|
+
if (!productData.mulInsOrderList) {
|
|
21055
|
+
return productData;
|
|
20973
21056
|
}
|
|
20974
|
-
|
|
20975
|
-
|
|
20976
|
-
|
|
20977
|
-
|
|
20978
|
-
|
|
20979
|
-
|
|
20980
|
-
};
|
|
20981
|
-
|
|
20982
|
-
var maybeMap = function maybeMap(val, fn) {
|
|
20983
|
-
if (isArray(val)) {
|
|
20984
|
-
var mapped = [];
|
|
20985
|
-
for (var i = 0; i < val.length; i += 1) {
|
|
20986
|
-
mapped.push(fn(val[i]));
|
|
21057
|
+
productData.adjustBaoeData = null;
|
|
21058
|
+
productData.mulInsOrderList.forEach(function (ins) {
|
|
21059
|
+
if (ins.accountData && ins.accountData.addAndTakeData) {
|
|
21060
|
+
ins.accountData.addAndTakeData.forEach(function (aat) {
|
|
21061
|
+
aat.adjustData = [];
|
|
21062
|
+
});
|
|
20987
21063
|
}
|
|
20988
|
-
|
|
20989
|
-
|
|
20990
|
-
|
|
20991
|
-
};
|
|
20992
|
-
|
|
20993
|
-
|
|
20994
|
-
|
|
20995
|
-
|
|
20996
|
-
combine: combine,
|
|
20997
|
-
compact: compact,
|
|
20998
|
-
decode: decode,
|
|
20999
|
-
encode: encode,
|
|
21000
|
-
isBuffer: isBuffer,
|
|
21001
|
-
isRegExp: isRegExp,
|
|
21002
|
-
maybeMap: maybeMap,
|
|
21003
|
-
merge: merge
|
|
21004
|
-
};
|
|
21064
|
+
if (ins.reduceBaof && ins.reduceBaofData) {
|
|
21065
|
+
ins.reduceBaofData.addAndTakeData.forEach(function (aat) {
|
|
21066
|
+
aat.adjustData = [];
|
|
21067
|
+
});
|
|
21068
|
+
}
|
|
21069
|
+
});
|
|
21070
|
+
return productData;
|
|
21071
|
+
}
|
|
21005
21072
|
|
|
21006
21073
|
|
|
21007
21074
|
/***/ }),
|
|
@@ -21041,8 +21108,8 @@ module.exports = function(module) {
|
|
|
21041
21108
|
|
|
21042
21109
|
|
|
21043
21110
|
var getSideChannel = __webpack_require__(40);
|
|
21044
|
-
var utils = __webpack_require__(
|
|
21045
|
-
var formats = __webpack_require__(
|
|
21111
|
+
var utils = __webpack_require__(35);
|
|
21112
|
+
var formats = __webpack_require__(23);
|
|
21046
21113
|
var has = Object.prototype.hasOwnProperty;
|
|
21047
21114
|
|
|
21048
21115
|
var arrayPrefixGenerators = {
|
|
@@ -21403,10 +21470,10 @@ module.exports = function (object, opts) {
|
|
|
21403
21470
|
"use strict";
|
|
21404
21471
|
|
|
21405
21472
|
|
|
21406
|
-
var $TypeError = __webpack_require__(
|
|
21407
|
-
var inspect = __webpack_require__(
|
|
21473
|
+
var $TypeError = __webpack_require__(10);
|
|
21474
|
+
var inspect = __webpack_require__(16);
|
|
21408
21475
|
var getSideChannelList = __webpack_require__(42);
|
|
21409
|
-
var getSideChannelMap = __webpack_require__(
|
|
21476
|
+
var getSideChannelMap = __webpack_require__(27);
|
|
21410
21477
|
var getSideChannelWeakMap = __webpack_require__(67);
|
|
21411
21478
|
|
|
21412
21479
|
var makeChannel = getSideChannelWeakMap || getSideChannelMap || getSideChannelList;
|
|
@@ -21459,9 +21526,9 @@ module.exports = function getSideChannel() {
|
|
|
21459
21526
|
"use strict";
|
|
21460
21527
|
|
|
21461
21528
|
|
|
21462
|
-
var inspect = __webpack_require__(
|
|
21529
|
+
var inspect = __webpack_require__(16);
|
|
21463
21530
|
|
|
21464
|
-
var $TypeError = __webpack_require__(
|
|
21531
|
+
var $TypeError = __webpack_require__(10);
|
|
21465
21532
|
|
|
21466
21533
|
/*
|
|
21467
21534
|
* This function traverses the list returning the node corresponding to the given key.
|
|
@@ -21847,8 +21914,8 @@ module.exports = function hasSymbols() {
|
|
|
21847
21914
|
"use strict";
|
|
21848
21915
|
|
|
21849
21916
|
|
|
21850
|
-
var reflectGetProto = __webpack_require__(
|
|
21851
|
-
var originalGetProto = __webpack_require__(
|
|
21917
|
+
var reflectGetProto = __webpack_require__(30);
|
|
21918
|
+
var originalGetProto = __webpack_require__(31);
|
|
21852
21919
|
|
|
21853
21920
|
var getDunderProto = __webpack_require__(62);
|
|
21854
21921
|
|
|
@@ -21881,8 +21948,8 @@ module.exports = reflectGetProto
|
|
|
21881
21948
|
"use strict";
|
|
21882
21949
|
|
|
21883
21950
|
|
|
21884
|
-
var callBind = __webpack_require__(
|
|
21885
|
-
var gOPD = __webpack_require__(
|
|
21951
|
+
var callBind = __webpack_require__(32);
|
|
21952
|
+
var gOPD = __webpack_require__(29);
|
|
21886
21953
|
|
|
21887
21954
|
var hasProtoAccessor;
|
|
21888
21955
|
try {
|
|
@@ -22009,10 +22076,10 @@ module.exports = function bind(that) {
|
|
|
22009
22076
|
"use strict";
|
|
22010
22077
|
|
|
22011
22078
|
|
|
22012
|
-
var bind = __webpack_require__(
|
|
22079
|
+
var bind = __webpack_require__(17);
|
|
22013
22080
|
|
|
22014
|
-
var $apply = __webpack_require__(
|
|
22015
|
-
var $call = __webpack_require__(
|
|
22081
|
+
var $apply = __webpack_require__(33);
|
|
22082
|
+
var $call = __webpack_require__(22);
|
|
22016
22083
|
var $reflectApply = __webpack_require__(65);
|
|
22017
22084
|
|
|
22018
22085
|
/** @type {import('./actualApply')} */
|
|
@@ -22039,7 +22106,7 @@ module.exports = typeof Reflect !== 'undefined' && Reflect && Reflect.apply;
|
|
|
22039
22106
|
|
|
22040
22107
|
var call = Function.prototype.call;
|
|
22041
22108
|
var $hasOwn = Object.prototype.hasOwnProperty;
|
|
22042
|
-
var bind = __webpack_require__(
|
|
22109
|
+
var bind = __webpack_require__(17);
|
|
22043
22110
|
|
|
22044
22111
|
/** @type {import('.')} */
|
|
22045
22112
|
module.exports = bind.call(call, $hasOwn);
|
|
@@ -22052,12 +22119,12 @@ module.exports = bind.call(call, $hasOwn);
|
|
|
22052
22119
|
"use strict";
|
|
22053
22120
|
|
|
22054
22121
|
|
|
22055
|
-
var GetIntrinsic = __webpack_require__(
|
|
22056
|
-
var callBound = __webpack_require__(
|
|
22057
|
-
var inspect = __webpack_require__(
|
|
22058
|
-
var getSideChannelMap = __webpack_require__(
|
|
22122
|
+
var GetIntrinsic = __webpack_require__(21);
|
|
22123
|
+
var callBound = __webpack_require__(34);
|
|
22124
|
+
var inspect = __webpack_require__(16);
|
|
22125
|
+
var getSideChannelMap = __webpack_require__(27);
|
|
22059
22126
|
|
|
22060
|
-
var $TypeError = __webpack_require__(
|
|
22127
|
+
var $TypeError = __webpack_require__(10);
|
|
22061
22128
|
var $WeakMap = GetIntrinsic('%WeakMap%', true);
|
|
22062
22129
|
|
|
22063
22130
|
/** @type {<K extends object, V>(thisArg: WeakMap<K, V>, key: K) => V} */
|
|
@@ -22143,7 +22210,7 @@ module.exports = $WeakMap
|
|
|
22143
22210
|
"use strict";
|
|
22144
22211
|
|
|
22145
22212
|
|
|
22146
|
-
var utils = __webpack_require__(
|
|
22213
|
+
var utils = __webpack_require__(35);
|
|
22147
22214
|
|
|
22148
22215
|
var has = Object.prototype.hasOwnProperty;
|
|
22149
22216
|
var isArray = Array.isArray;
|
|
@@ -22486,7 +22553,7 @@ module.exports = function (str, opts) {
|
|
|
22486
22553
|
/* 80 */
|
|
22487
22554
|
/***/ (function(module, exports, __webpack_require__) {
|
|
22488
22555
|
|
|
22489
|
-
var _typeof = __webpack_require__(
|
|
22556
|
+
var _typeof = __webpack_require__(14)["default"];
|
|
22490
22557
|
function _regeneratorRuntime() {
|
|
22491
22558
|
"use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
|
|
22492
22559
|
module.exports = _regeneratorRuntime = function _regeneratorRuntime() {
|
|
@@ -22800,7 +22867,7 @@ module.exports = _regeneratorRuntime, module.exports.__esModule = true, module.e
|
|
|
22800
22867
|
/* 118 */
|
|
22801
22868
|
/***/ (function(module, exports, __webpack_require__) {
|
|
22802
22869
|
|
|
22803
|
-
var _typeof = __webpack_require__(
|
|
22870
|
+
var _typeof = __webpack_require__(14)["default"];
|
|
22804
22871
|
var toPrimitive = __webpack_require__(119);
|
|
22805
22872
|
function toPropertyKey(t) {
|
|
22806
22873
|
var i = toPrimitive(t, "string");
|
|
@@ -22812,7 +22879,7 @@ module.exports = toPropertyKey, module.exports.__esModule = true, module.exports
|
|
|
22812
22879
|
/* 119 */
|
|
22813
22880
|
/***/ (function(module, exports, __webpack_require__) {
|
|
22814
22881
|
|
|
22815
|
-
var _typeof = __webpack_require__(
|
|
22882
|
+
var _typeof = __webpack_require__(14)["default"];
|
|
22816
22883
|
function toPrimitive(t, r) {
|
|
22817
22884
|
if ("object" != _typeof(t) || !t) return t;
|
|
22818
22885
|
var e = t[Symbol.toPrimitive];
|
|
@@ -23134,15 +23201,15 @@ var staticRenderFns = [];
|
|
|
23134
23201
|
// CONCATENATED MODULE: ./packages/add-and-take/index.vue?vue&type=template&id=97071088
|
|
23135
23202
|
|
|
23136
23203
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/defineProperty.js
|
|
23137
|
-
var defineProperty = __webpack_require__(
|
|
23204
|
+
var defineProperty = __webpack_require__(19);
|
|
23138
23205
|
var defineProperty_default = /*#__PURE__*/__webpack_require__.n(defineProperty);
|
|
23139
23206
|
|
|
23140
23207
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/asyncToGenerator.js
|
|
23141
|
-
var asyncToGenerator = __webpack_require__(
|
|
23208
|
+
var asyncToGenerator = __webpack_require__(24);
|
|
23142
23209
|
var asyncToGenerator_default = /*#__PURE__*/__webpack_require__.n(asyncToGenerator);
|
|
23143
23210
|
|
|
23144
23211
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/regenerator/index.js
|
|
23145
|
-
var regenerator = __webpack_require__(
|
|
23212
|
+
var regenerator = __webpack_require__(18);
|
|
23146
23213
|
var regenerator_default = /*#__PURE__*/__webpack_require__.n(regenerator);
|
|
23147
23214
|
|
|
23148
23215
|
// EXTERNAL MODULE: external {"root":"Vue","commonjs":"vue","commonjs2":"vue","amd":"vue"}
|
|
@@ -23150,15 +23217,18 @@ var external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_ = __webpack_require__(
|
|
|
23150
23217
|
var external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_default = /*#__PURE__*/__webpack_require__.n(external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_);
|
|
23151
23218
|
|
|
23152
23219
|
// EXTERNAL MODULE: external "vant"
|
|
23153
|
-
var external_vant_ = __webpack_require__(
|
|
23220
|
+
var external_vant_ = __webpack_require__(25);
|
|
23154
23221
|
var external_vant_default = /*#__PURE__*/__webpack_require__.n(external_vant_);
|
|
23155
23222
|
|
|
23156
23223
|
// EXTERNAL MODULE: ./node_modules/lodash/lodash.js
|
|
23157
23224
|
var lodash = __webpack_require__(3);
|
|
23158
23225
|
|
|
23226
|
+
// EXTERNAL MODULE: ./src/js/variables.js
|
|
23227
|
+
var variables = __webpack_require__(7);
|
|
23228
|
+
|
|
23159
23229
|
// CONCATENATED MODULE: ./packages/add-and-take/api.ts
|
|
23160
|
-
|
|
23161
|
-
var apiBaseUrl = "
|
|
23230
|
+
|
|
23231
|
+
var apiBaseUrl = "".concat(variables["d" /* PLANBOOK_API_HOSTNAME */], "/planBook");
|
|
23162
23232
|
function initInsuranceInterest(reqParams, options) {
|
|
23163
23233
|
if (options === void 0) { options = {}; }
|
|
23164
23234
|
var scene = options.scene;
|
|
@@ -23467,7 +23537,7 @@ var interest_formvue_type_template_id_40f87902_staticRenderFns = [];
|
|
|
23467
23537
|
// CONCATENATED MODULE: ./packages/add-and-take/components/interest-form.vue?vue&type=template&id=40f87902
|
|
23468
23538
|
|
|
23469
23539
|
// EXTERNAL MODULE: ./packages/bxs-utils/planbook/index.ts
|
|
23470
|
-
var planbook = __webpack_require__(
|
|
23540
|
+
var planbook = __webpack_require__(20);
|
|
23471
23541
|
|
|
23472
23542
|
// CONCATENATED MODULE: ./node_modules/babel-loader/lib??ref--1!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/vue-loader/lib??vue-loader-options!./packages/components/common-radio.vue?vue&type=template&id=f3f6bf82
|
|
23473
23543
|
var common_radiovue_type_template_id_f3f6bf82_render = function render() {
|
|
@@ -23576,7 +23646,7 @@ var common_radiovue_type_template_id_f3f6bf82_staticRenderFns = [];
|
|
|
23576
23646
|
var common_radiovue_type_style_index_0_id_f3f6bf82_prod_lang_css = __webpack_require__(169);
|
|
23577
23647
|
|
|
23578
23648
|
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
|
|
23579
|
-
var componentNormalizer = __webpack_require__(
|
|
23649
|
+
var componentNormalizer = __webpack_require__(8);
|
|
23580
23650
|
|
|
23581
23651
|
// CONCATENATED MODULE: ./packages/components/common-radio.vue
|
|
23582
23652
|
|