dolphin-weex-bc 0.0.25 → 0.0.26

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/CHANGELOG.md CHANGED
@@ -1,4 +1,9 @@
1
1
  # 升级日志
2
+ ## 0.0.26
3
+
4
+ - [ ! ] 耗材业务组件增加搜索列表页跳转逻辑判断
5
+ - [ ! ] date: 2026/01/21
6
+
2
7
  ## 0.0.25
3
8
 
4
9
  - [ ! ] colmo耗材业务组件,修复ios样式和midea-progresscycle-view在ios无法点击问题
@@ -3839,6 +3839,30 @@ var MaterialEvent = {
3839
3839
  // 都有type=4的保持原顺序
3840
3840
  return 0;
3841
3841
  },
3842
+
3843
+
3844
+ //处理跳转到搜索列表的跳转逻辑
3845
+ handleSearchLinkUrlJump: function handleSearchLinkUrlJump(searchLinkUrl) {
3846
+ searchLinkUrl = decodeURIComponent(searchLinkUrl);
3847
+ var searchLinkUrlPart1 = searchLinkUrl.split('url=')[1];
3848
+ var searchLinkUrlPart0 = searchLinkUrl.split('url=')[0] + 'url=';
3849
+ searchLinkUrlPart1 = searchLinkUrlPart1.includes('?') ? searchLinkUrlPart1 + '&entrance=consumables' : searchLinkUrlPart1 + '?entrance=consumables';
3850
+ console.log('searchLinkUrlPart1' + searchLinkUrl);
3851
+ var url = searchLinkUrlPart0 + encodeURIComponent(searchLinkUrlPart1);
3852
+ console.log('最终的搜索列表链接:' + url);
3853
+ this.jumpElecBusinessWeex(url);
3854
+ },
3855
+ jumpElecBusinessWeex: function jumpElecBusinessWeex(url) {
3856
+ var _this22 = this;
3857
+
3858
+ _dolphinNativeBridge.Bridge.goToPage({
3859
+ url: url
3860
+ }).then(function (res) {
3861
+ // this.$alert(res)
3862
+ }).catch(function (err) {
3863
+ _this22.$toast(err.errorMessage || err.errorMsg || '跳转失败');
3864
+ });
3865
+ },
3842
3866
  setChartData: function setChartData(it) {
3843
3867
  var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
3844
3868
 
@@ -3957,7 +3981,7 @@ var MaterialEvent = {
3957
3981
 
3958
3982
  //分层排序
3959
3983
  sortHierarchical: function sortHierarchical(data) {
3960
- var _this22 = this;
3984
+ var _this23 = this;
3961
3985
 
3962
3986
  var categorizedDeviceMaterialList = {
3963
3987
  insufficient: [],
@@ -3988,7 +4012,7 @@ var MaterialEvent = {
3988
4012
 
3989
4013
  if (categorizedConsumables.insufficient.length > 0) {
3990
4014
  categorizedDeviceMaterialList.insufficient.push(_extends({}, device, {
3991
- consumables: _this22.sortConsumables(categorizedConsumables.insufficient)
4015
+ consumables: _this23.sortConsumables(categorizedConsumables.insufficient)
3992
4016
  }));
3993
4017
  }
3994
4018
 
@@ -4000,7 +4024,7 @@ var MaterialEvent = {
4000
4024
 
4001
4025
  if (categorizedConsumables.sufficient.length > 0) {
4002
4026
  categorizedDeviceMaterialList.sufficient.push(_extends({}, device, {
4003
- consumables: _this22.sortConsumables(categorizedConsumables.sufficient)
4027
+ consumables: _this23.sortConsumables(categorizedConsumables.sufficient)
4004
4028
  }));
4005
4029
  }
4006
4030
  });
@@ -65643,6 +65667,10 @@ exports.default = {
65643
65667
  type: Boolean,
65644
65668
  default: false
65645
65669
  },
65670
+ needCustomGoToDetail: {
65671
+ type: Boolean,
65672
+ default: false
65673
+ },
65646
65674
  isFilterShow: {
65647
65675
  type: Boolean,
65648
65676
  default: false // 是否是分层模式
@@ -65844,6 +65872,10 @@ exports.default = {
65844
65872
  }, 2000, { leading: true, trailing: false }),
65845
65873
  // 跳转耗材详情
65846
65874
  goDetail: function goDetail(item, device) {
65875
+ if (this.needCustomGoToDetail) {
65876
+ this.$emit('customGoToDetail', { item: item, device: device });
65877
+ return;
65878
+ }
65847
65879
  console.log('跳转前itemmmm===' + JSON.stringify(item));
65848
65880
  console.log('跳转前device===' + JSON.stringify(device));
65849
65881
  _utils2.default.setItem('previous_materialDetail', item);
@@ -65853,8 +65885,8 @@ exports.default = {
65853
65885
  _utils2.default.setItem('previous_consumables', consumables);
65854
65886
  // applianceCode: device.applianceCode,
65855
65887
  // consumablesCode: item.consumablesCode,
65856
- var url = 'customer-service/materialDetail.js?from=externalPage&applianceCode=' + device.applianceCode + '&consumablesCode=' + item.consumablesCode;
65857
- // let url = 'customer-service/materialDetail.js?from=externalPage'
65888
+ // let url = `customer-service/materialDetail.js?from=externalPage&applianceCode=${device.applianceCode}&consumablesCode=${item.consumablesCode}`
65889
+ var url = 'customer-service/materialDetail.js?from=externalPage';
65858
65890
  var params = {
65859
65891
  type: 'jumpWeex',
65860
65892
  param: {
@@ -65876,8 +65908,7 @@ exports.default = {
65876
65908
  var activeUrl = it.purchaseInfo ? it.purchaseInfo.linkUrl : '';
65877
65909
  var searchLinkUrl = it.purchaseInfo ? it.purchaseInfo.searchLinkUrl : '';
65878
65910
  if (searchLinkUrl) {
65879
- searchLinkUrl = searchLinkUrl.includes('?') ? searchLinkUrl + '&entrance=consumables' : searchLinkUrl + '?entrance=consumables';
65880
- this.goodsjumpWebViewNew(searchLinkUrl);
65911
+ _index2.default.handleSearchLinkUrlJump(searchLinkUrl);
65881
65912
  } else if (it.purchaseInfo && it.purchaseInfo.skuId) {
65882
65913
  this.goToGoodsDetail(it.purchaseInfo);
65883
65914
  } else if (it.goodsInfo && (it.goodsInfo.skulink || it.goodsInfo.skuId)) {
@@ -65972,8 +66003,7 @@ exports.default = {
65972
66003
  var activeUrl = it.serviceSupport.washingService.serviceUrl;
65973
66004
  var searchLinkUrl = it.serviceSupport.washingService.searchLinkUrl;
65974
66005
  if (searchLinkUrl) {
65975
- searchLinkUrl = searchLinkUrl.includes('?') ? searchLinkUrl + '&entrance=consumables' : searchLinkUrl + '?entrance=consumables';
65976
- this.goodsjumpWebViewNew(searchLinkUrl);
66006
+ _index2.default.handleSearchLinkUrlJump(searchLinkUrl);
65977
66007
  } else if (it.serviceSupport.washingService.skuId) {
65978
66008
  this.goToGoodsDetail(it.serviceSupport.washingService);
65979
66009
  } else if (it.washingServiceGoodsInfo && (it.washingServiceGoodsInfo.skulink || it.washingServiceGoodsInfo.skuId)) {
@@ -65987,7 +66017,6 @@ exports.default = {
65987
66017
  var _this6 = this;
65988
66018
 
65989
66019
  setTimeout(function () {
65990
- _this6.$emit('consumablesInfo', { deviceMaterialList: deviceMaterialList });
65991
66020
  dom.getComponentRect(_this6.$refs.materialBox, function (data) {
65992
66021
  _this6.$emit('renderEnd', data.size.height);
65993
66022
  });