bxs-tools-ui 1.2.18 → 1.3.0
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/.DS_Store +0 -0
- package/lib/add-and-take/index.js +3 -3
- package/lib/adjust-baoe/index.js +3 -3
- package/lib/bxs-utils/index.js +3 -3
- package/lib/index.css +34 -2
- package/lib/index.js +109 -21
- package/lib/insure-calculate/index.js +3 -3
- package/lib/person-info/index.js +3 -3
- package/lib/product-info/index.css +34 -2
- package/lib/product-info/index.js +98 -10
- package/package.json +1 -1
- package/packages/bxs-utils/planbook/insurance.ts +2 -1
- package/packages/bxs-utils/planbook/product.ts +2 -2
- package/packages/planbook-input/components/product-table.vue +3 -0
- package/packages/planbook-input/index.vue +6 -0
- package/packages/product-info/demo/constant.js +993 -0
- package/packages/product-info/index.css +38 -2
- package/packages/product-info/index.vue +77 -2
- package/packages/product-info/readme.md +11 -74
|
@@ -1546,7 +1546,7 @@ function initInsuranceData(insData) {
|
|
|
1546
1546
|
e.opts = options;
|
|
1547
1547
|
}
|
|
1548
1548
|
if (e.opts && e.opts.length) {
|
|
1549
|
-
e.opts = e.opts.map(function (o) { return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, o), { isHide: o.isHide || null, isDisabled: o.isDisabled || null, isInvalid: o.isInvalid || null })); });
|
|
1549
|
+
e.opts = e.opts.map(function (o) { return (Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])(Object(tslib__WEBPACK_IMPORTED_MODULE_0__[/* __assign */ "a"])({}, o), { desc: o.desc || o.val, isHide: o.isHide || null, isDisabled: o.isDisabled || null, isInvalid: o.isInvalid || null })); });
|
|
1550
1550
|
}
|
|
1551
1551
|
});
|
|
1552
1552
|
}
|
|
@@ -3804,7 +3804,7 @@ function productDataHandler(prodData, productVerifyData, personData) {
|
|
|
3804
3804
|
var option = backupOpts_1.find(function (o) { return o.val == c.value; });
|
|
3805
3805
|
return {
|
|
3806
3806
|
val: c.value,
|
|
3807
|
-
desc: c.desc,
|
|
3807
|
+
desc: c.desc || c.value,
|
|
3808
3808
|
isHide: (option && option.isHide) || null,
|
|
3809
3809
|
isDisabled: (option && option.isDisabled) || null,
|
|
3810
3810
|
isInvalid: null
|
|
@@ -3862,7 +3862,7 @@ function productDataHandler(prodData, productVerifyData, personData) {
|
|
|
3862
3862
|
return elementVerify && elementVerify.some(function (c) { return c.value == eleData.value; });
|
|
3863
3863
|
}).map(function (v) { return ({
|
|
3864
3864
|
val: v.value,
|
|
3865
|
-
desc: v.desc,
|
|
3865
|
+
desc: v.desc || v.value,
|
|
3866
3866
|
isHide: null,
|
|
3867
3867
|
isDisabled: null,
|
|
3868
3868
|
isInvalid: null
|
|
@@ -12961,8 +12961,8 @@ function isSlowBuffer (obj) {
|
|
|
12961
12961
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
12962
12962
|
|
|
12963
12963
|
"use strict";
|
|
12964
|
-
/* harmony import */ var
|
|
12965
|
-
/* harmony import */ var
|
|
12964
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_node_modules_css_loader_dist_cjs_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_403daf62_prod_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(188);
|
|
12965
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_node_modules_css_loader_dist_cjs_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_403daf62_prod_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_node_modules_css_loader_dist_cjs_js_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_index_vue_vue_type_style_index_0_id_403daf62_prod_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
12966
12966
|
/* unused harmony reexport * */
|
|
12967
12967
|
|
|
12968
12968
|
|
|
@@ -12976,7 +12976,7 @@ function isSlowBuffer (obj) {
|
|
|
12976
12976
|
// ESM COMPAT FLAG
|
|
12977
12977
|
__webpack_require__.r(__webpack_exports__);
|
|
12978
12978
|
|
|
12979
|
-
// 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/product-info/index.vue?vue&type=template&id=
|
|
12979
|
+
// 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/product-info/index.vue?vue&type=template&id=403daf62&
|
|
12980
12980
|
var render = function render() {
|
|
12981
12981
|
var _vm = this,
|
|
12982
12982
|
_c = _vm._self._c,
|
|
@@ -12984,7 +12984,36 @@ var render = function render() {
|
|
|
12984
12984
|
|
|
12985
12985
|
return _vm.productData && _vm.productData.mulInsOrderList ? _c('div', {
|
|
12986
12986
|
staticClass: "bxt-product-info"
|
|
12987
|
-
}, [_vm.
|
|
12987
|
+
}, [_vm.params.allowCustomResult ? _c('section', {
|
|
12988
|
+
staticClass: "bxt-custom-result"
|
|
12989
|
+
}, [_c('div', {
|
|
12990
|
+
staticClass: "bxt-custom-result-title"
|
|
12991
|
+
}, [_c('span', {
|
|
12992
|
+
staticClass: "bxt-custom-result-title_desc",
|
|
12993
|
+
on: {
|
|
12994
|
+
"click": function click($event) {
|
|
12995
|
+
_vm.isShowCustomValueTips = !_vm.isShowCustomValueTips;
|
|
12996
|
+
}
|
|
12997
|
+
}
|
|
12998
|
+
}, [_vm._v("\n 自定义保费\n "), _c('i', {
|
|
12999
|
+
staticClass: "iconfont",
|
|
13000
|
+
class: _vm.isShowCustomValueTips ? 'icon-arrows_up' : 'icon-arrows_down'
|
|
13001
|
+
})]), _c('bxs-switch', {
|
|
13002
|
+
on: {
|
|
13003
|
+
"change": function change($event) {
|
|
13004
|
+
return _vm.createInsuranceInputResultEle();
|
|
13005
|
+
}
|
|
13006
|
+
},
|
|
13007
|
+
model: {
|
|
13008
|
+
value: _vm.productData.inputResultSwitch,
|
|
13009
|
+
callback: function callback($$v) {
|
|
13010
|
+
_vm.$set(_vm.productData, "inputResultSwitch", $$v);
|
|
13011
|
+
},
|
|
13012
|
+
expression: "productData.inputResultSwitch"
|
|
13013
|
+
}
|
|
13014
|
+
})], 1), _vm.isShowCustomValueTips ? _c('div', {
|
|
13015
|
+
staticClass: "bxt-custom-result-tips"
|
|
13016
|
+
}, [_vm._v("\n 保险公司会因非标准体等原因修改费率。"), _c('br'), _vm._v("\n 打开\"自定义保费\"功能,按保单填写实际保费/保额\n ")]) : _vm._e()]) : _vm._e(), _vm._l(_vm.filterInsuranceList, function (ins) {
|
|
12988
13017
|
return [_c('bxs-form', {
|
|
12989
13018
|
key: ins.key,
|
|
12990
13019
|
ref: "insuranceForm".concat(ins.key),
|
|
@@ -13262,7 +13291,7 @@ var render = function render() {
|
|
|
13262
13291
|
|
|
13263
13292
|
var staticRenderFns = [];
|
|
13264
13293
|
|
|
13265
|
-
// CONCATENATED MODULE: ./packages/product-info/index.vue?vue&type=template&id=
|
|
13294
|
+
// CONCATENATED MODULE: ./packages/product-info/index.vue?vue&type=template&id=403daf62&
|
|
13266
13295
|
|
|
13267
13296
|
// EXTERNAL MODULE: ./node_modules/tslib/tslib.es6.js
|
|
13268
13297
|
var tslib_es6 = __webpack_require__(0);
|
|
@@ -13872,6 +13901,7 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
13872
13901
|
_this.numberUnitStr = '';
|
|
13873
13902
|
_this.recommendValues = {};
|
|
13874
13903
|
_this.recommendValuesCache = {};
|
|
13904
|
+
_this.isShowCustomValueTips = true;
|
|
13875
13905
|
return _this;
|
|
13876
13906
|
}
|
|
13877
13907
|
Object.defineProperty(BxtProductInfo.prototype, "personData", {
|
|
@@ -13972,6 +14002,12 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
13972
14002
|
Object(bxs_utils["clearAddAndTakeAndAdjustBaoeData"])(productData);
|
|
13973
14003
|
}
|
|
13974
14004
|
Object(bxs_utils["productDataHandler"])(productData, this.verifyData && this.verifyData[productData.key], this.personData);
|
|
14005
|
+
if (options.type === 'change') {
|
|
14006
|
+
this.createInsuranceInputResultEle(options.insData, options.eleData);
|
|
14007
|
+
}
|
|
14008
|
+
else {
|
|
14009
|
+
this.createInsuranceInputResultEle();
|
|
14010
|
+
}
|
|
13975
14011
|
return Object(bxs_utils["verifyProductRules"])(Object(tslib_es6["a" /* __assign */])({ personData: this.personData, productData: productData }, options));
|
|
13976
14012
|
};
|
|
13977
14013
|
BxtProductInfo.prototype.isInsuranceChecked = function (ins) {
|
|
@@ -14170,6 +14206,51 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
14170
14206
|
}
|
|
14171
14207
|
});
|
|
14172
14208
|
};
|
|
14209
|
+
BxtProductInfo.prototype.createInsuranceInputResultEle = function (insData, eleData) {
|
|
14210
|
+
var _a = this, params = _a.params, productData = _a.productData;
|
|
14211
|
+
if (!params.allowCustomResult) {
|
|
14212
|
+
return;
|
|
14213
|
+
}
|
|
14214
|
+
productData.mulInsOrderList
|
|
14215
|
+
.filter(function (e) { return e.key !== 'common' || e.eleOrderList; })
|
|
14216
|
+
.forEach(function (ins) {
|
|
14217
|
+
if (ins.groupKey) {
|
|
14218
|
+
return;
|
|
14219
|
+
}
|
|
14220
|
+
if (insData && eleData && !insData.isGroup && insData.key === ins.key && eleData.key !== 'calMethod') {
|
|
14221
|
+
return;
|
|
14222
|
+
}
|
|
14223
|
+
var calMethod = ins.eleOrderList.find(function (e) { return e.key === 'calMethod'; });
|
|
14224
|
+
var baof = ins.eleOrderList.find(function (e) { return e.key === 'baof'; });
|
|
14225
|
+
var inputResult = ins.eleOrderList.find(function (e) { return e.key === 'inputResult'; });
|
|
14226
|
+
var labelName = calMethod ? (calMethod.value === 'baof2baoe' ? '保额' : '保费') : baof ? '保额' : '保费';
|
|
14227
|
+
var value = ins.inputResult === undefined ? null : ins.inputResult;
|
|
14228
|
+
if (inputResult) {
|
|
14229
|
+
value = inputResult.value;
|
|
14230
|
+
}
|
|
14231
|
+
if (insData && eleData && insData.key === ins.key && eleData.key === 'inputResult') {
|
|
14232
|
+
value = eleData.value;
|
|
14233
|
+
}
|
|
14234
|
+
inputResult = {
|
|
14235
|
+
componentName: 'cmCommonInput',
|
|
14236
|
+
placeholder: "\u6309\u7167\u4FDD\u5355\u586B\u5199" + labelName,
|
|
14237
|
+
isHide: !productData.inputResultSwitch,
|
|
14238
|
+
key: 'inputResult',
|
|
14239
|
+
labelName: "\u81EA\u5B9A\u4E49" + labelName,
|
|
14240
|
+
inputType: 'text',
|
|
14241
|
+
required: false,
|
|
14242
|
+
regExp: '/^\\d{1,}(\\.\\d{1,2})?$/',
|
|
14243
|
+
regExpMessage: '请输入1-2位小数的值',
|
|
14244
|
+
value: value
|
|
14245
|
+
};
|
|
14246
|
+
inputResult.rules = Object(bxs_utils["initElementValidateRules"])(inputResult);
|
|
14247
|
+
delete ins.inputResult;
|
|
14248
|
+
ins.eleOrderList = ins.eleOrderList.filter(function (e) { return e.key !== 'inputResult'; });
|
|
14249
|
+
if (productData.inputResultSwitch) {
|
|
14250
|
+
ins.eleOrderList.push(inputResult);
|
|
14251
|
+
}
|
|
14252
|
+
});
|
|
14253
|
+
};
|
|
14173
14254
|
Object(tslib_es6["c" /* __decorate */])([
|
|
14174
14255
|
Object(vue_property_decorator["c" /* Prop */])({
|
|
14175
14256
|
default: function () { return ({}); }
|
|
@@ -14194,6 +14275,12 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
14194
14275
|
}),
|
|
14195
14276
|
Object(tslib_es6["f" /* __metadata */])("design:type", Object)
|
|
14196
14277
|
], BxtProductInfo.prototype, "productKey", void 0);
|
|
14278
|
+
Object(tslib_es6["c" /* __decorate */])([
|
|
14279
|
+
Object(vue_property_decorator["c" /* Prop */])({
|
|
14280
|
+
default: function () { return ({}); }
|
|
14281
|
+
}),
|
|
14282
|
+
Object(tslib_es6["f" /* __metadata */])("design:type", Object)
|
|
14283
|
+
], BxtProductInfo.prototype, "params", void 0);
|
|
14197
14284
|
BxtProductInfo = Object(tslib_es6["c" /* __decorate */])([
|
|
14198
14285
|
Object(vue_property_decorator["a" /* Component */])({
|
|
14199
14286
|
name: 'BxtProductInfo',
|
|
@@ -14206,6 +14293,7 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
14206
14293
|
product_infovue_type_script_lang_ts_a[external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Input"].name] = external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Input"],
|
|
14207
14294
|
product_infovue_type_script_lang_ts_a[external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["RadioGroup"].name] = external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["RadioGroup"],
|
|
14208
14295
|
product_infovue_type_script_lang_ts_a[external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Radio"].name] = external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Radio"],
|
|
14296
|
+
product_infovue_type_script_lang_ts_a[external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Switch"].name] = external_root_bxs_commonjs_bxs_ui_vue_commonjs2_bxs_ui_vue_amd_bxs_ui_vue_["Switch"],
|
|
14209
14297
|
product_infovue_type_script_lang_ts_a)
|
|
14210
14298
|
})
|
|
14211
14299
|
], BxtProductInfo);
|
|
@@ -14215,8 +14303,8 @@ var product_infovue_type_script_lang_ts_BxtProductInfo = (function (_super) {
|
|
|
14215
14303
|
|
|
14216
14304
|
// CONCATENATED MODULE: ./packages/product-info/index.vue?vue&type=script&lang=ts&
|
|
14217
14305
|
/* harmony default export */ var packages_product_infovue_type_script_lang_ts_ = (product_infovue_type_script_lang_ts_);
|
|
14218
|
-
// EXTERNAL MODULE: ./packages/product-info/index.vue?vue&type=style&index=0&id=
|
|
14219
|
-
var
|
|
14306
|
+
// EXTERNAL MODULE: ./packages/product-info/index.vue?vue&type=style&index=0&id=403daf62&prod&lang=css&
|
|
14307
|
+
var product_infovue_type_style_index_0_id_403daf62_prod_lang_css_ = __webpack_require__(234);
|
|
14220
14308
|
|
|
14221
14309
|
// EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
|
|
14222
14310
|
var componentNormalizer = __webpack_require__(8);
|
package/package.json
CHANGED
|
@@ -66,6 +66,7 @@ export function initInsuranceData(insData : IProdInsurance) : void {
|
|
|
66
66
|
if (e.opts && e.opts.length) {
|
|
67
67
|
e.opts = e.opts.map(o => ({
|
|
68
68
|
...o,
|
|
69
|
+
desc: o.desc || o.val,
|
|
69
70
|
isHide: o.isHide || null,
|
|
70
71
|
isDisabled: o.isDisabled || null,
|
|
71
72
|
isInvalid: o.isInvalid || null
|
|
@@ -129,7 +130,7 @@ export function insuranceDataHandler(insData : IProdInsurance, productData : IPb
|
|
|
129
130
|
* @param {IPbProduct} productData 可不传。产品数据(单个)
|
|
130
131
|
* @returns {object} 元素的校验规则
|
|
131
132
|
*/
|
|
132
|
-
export function initElementValidateRules(ele : IInsElement, productData : IPbProduct) : any {
|
|
133
|
+
export function initElementValidateRules(ele : IInsElement, productData? : IPbProduct) : any {
|
|
133
134
|
let rules : any = [];
|
|
134
135
|
// 必填及正则校验
|
|
135
136
|
if (['cmCommonInput'].indexOf(String(ele.componentName)) !== -1) {
|
|
@@ -176,7 +176,7 @@ export function productDataHandler(prodData : IPbProduct, productVerifyData : an
|
|
|
176
176
|
const option = backupOpts.find(o => o.val == c.value);
|
|
177
177
|
return {
|
|
178
178
|
val: c.value,
|
|
179
|
-
desc: c.desc,
|
|
179
|
+
desc: c.desc || c.value,
|
|
180
180
|
isHide: (option && option.isHide) || null,
|
|
181
181
|
isDisabled: (option && option.isDisabled) || null,
|
|
182
182
|
isInvalid: null
|
|
@@ -243,7 +243,7 @@ export function productDataHandler(prodData : IPbProduct, productVerifyData : an
|
|
|
243
243
|
return elementVerify && elementVerify.some(c => c.value == eleData.value)
|
|
244
244
|
}).map(v => ({
|
|
245
245
|
val: v.value,
|
|
246
|
-
desc: v.desc,
|
|
246
|
+
desc: v.desc || v.value,
|
|
247
247
|
isHide: null,
|
|
248
248
|
isDisabled: null,
|
|
249
249
|
isInvalid: null
|
|
@@ -98,6 +98,7 @@ export default class BxtPlanbookInput extends Vue {
|
|
|
98
98
|
const parmas: any = {};
|
|
99
99
|
if (this.URL_PARAM.planbookId) {
|
|
100
100
|
parmas.insuranceTypeId = this.URL_PARAM.planbookId;
|
|
101
|
+
parmas.resultUuid = this.URL_PARAM.uuid;
|
|
101
102
|
} else if (this.URL_PARAM.publicPbUuid) {
|
|
102
103
|
parmas.publicPbUuid = this.URL_PARAM.publicPbUuid || '5d6499946bbb47bb8f6a286e9d4eee77';
|
|
103
104
|
}
|
|
@@ -124,6 +125,11 @@ export default class BxtPlanbookInput extends Vue {
|
|
|
124
125
|
initPageData(data);
|
|
125
126
|
initRecipientData(data.initData.inputData.personData.recipientInfo);
|
|
126
127
|
setPageDataBaseOnResult(data);
|
|
128
|
+
data.initData.inputData.productGroupList.map((g: IPbProductGroup) => {
|
|
129
|
+
g.prodOrderList.map((p: IPbProduct, pi) => {
|
|
130
|
+
p.inputResultSwitch = !!p.inputResultSwitch;
|
|
131
|
+
});
|
|
132
|
+
});
|
|
127
133
|
this.planbookData = data;
|
|
128
134
|
document.title = `DEMO:${this.planbookData.title}`;
|
|
129
135
|
this.autoImportData();
|