@fonixtree/magic-design 1.0.42 → 1.0.43
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.
|
@@ -19,8 +19,6 @@ var _ImageLabel = _interopRequireDefault(require("../ImageLabel"));
|
|
|
19
19
|
|
|
20
20
|
var _components = require("../../../../meta-comp/components");
|
|
21
21
|
|
|
22
|
-
var _businessUtil = require("../../../../utils/businessUtil");
|
|
23
|
-
|
|
24
22
|
require("./index.less");
|
|
25
23
|
|
|
26
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -95,26 +93,26 @@ function (_super) {
|
|
|
95
93
|
}
|
|
96
94
|
|
|
97
95
|
ProductItem.prototype.render = function () {
|
|
98
|
-
var _a, _b, _c;
|
|
99
|
-
|
|
100
|
-
var
|
|
101
|
-
data =
|
|
102
|
-
panelProps =
|
|
103
|
-
onItemClick =
|
|
104
|
-
showProName =
|
|
105
|
-
showProgress =
|
|
106
|
-
fixHeight =
|
|
107
|
-
layout =
|
|
108
|
-
imgHeight =
|
|
109
|
-
imgWidth =
|
|
110
|
-
unknownPrice =
|
|
111
|
-
rest = __rest(
|
|
112
|
-
|
|
113
|
-
|
|
96
|
+
var _a, _b, _c, _d;
|
|
97
|
+
|
|
98
|
+
var _e = this.props,
|
|
99
|
+
data = _e.data,
|
|
100
|
+
panelProps = _e.panelProps,
|
|
101
|
+
onItemClick = _e.onItemClick,
|
|
102
|
+
showProName = _e.showProName,
|
|
103
|
+
showProgress = _e.showProgress,
|
|
104
|
+
fixHeight = _e.fixHeight,
|
|
105
|
+
layout = _e.layout,
|
|
106
|
+
imgHeight = _e.imgHeight,
|
|
107
|
+
imgWidth = _e.imgWidth,
|
|
108
|
+
unknownPrice = _e.unknownPrice,
|
|
109
|
+
rest = __rest(_e, ["data", "panelProps", "onItemClick", "showProName", "showProgress", "fixHeight", "layout", "imgHeight", "imgWidth", "unknownPrice"]); // const promotions = getPromotionList(data);
|
|
110
|
+
|
|
111
|
+
|
|
114
112
|
var price = (0, _currencyUtil.formatCurrency)(data.salesPrice);
|
|
115
113
|
/** 当是拼团时 显示价格 */
|
|
116
114
|
|
|
117
|
-
if (data.sppType
|
|
115
|
+
if (data.sppType) {
|
|
118
116
|
price = data.specialPrice !== null ? (0, _currencyUtil.formatCurrency)(data.specialPrice) : (0, _currencyUtil.formatCurrency)(data.salesPrice);
|
|
119
117
|
}
|
|
120
118
|
|
|
@@ -176,9 +174,9 @@ function (_super) {
|
|
|
176
174
|
small: true
|
|
177
175
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
178
176
|
className: "content-wrap"
|
|
179
|
-
}, panelProps.label.open && /*#__PURE__*/_react["default"].createElement("div", {
|
|
177
|
+
}, panelProps.label.open && ((_d = data === null || data === void 0 ? void 0 : data.cmpBuygetnLabels) === null || _d === void 0 ? void 0 : _d.length) > 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
180
178
|
className: "promotions-wrap"
|
|
181
|
-
},
|
|
179
|
+
}, data.cmpBuygetnLabels.map(function (promot, index) {
|
|
182
180
|
return /*#__PURE__*/_react["default"].createElement(_components.MetaButton, {
|
|
183
181
|
key: index,
|
|
184
182
|
className: "promotion-item",
|
|
@@ -19,8 +19,6 @@ var _ImageLabel = _interopRequireDefault(require("../ImageLabel"));
|
|
|
19
19
|
|
|
20
20
|
var _components = require("../../../../meta-comp/components");
|
|
21
21
|
|
|
22
|
-
var _businessUtil = require("../../../../utils/businessUtil");
|
|
23
|
-
|
|
24
22
|
require("./index.less");
|
|
25
23
|
|
|
26
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
@@ -95,26 +93,26 @@ function (_super) {
|
|
|
95
93
|
}
|
|
96
94
|
|
|
97
95
|
ProductItem.prototype.render = function () {
|
|
98
|
-
var _a, _b, _c;
|
|
99
|
-
|
|
100
|
-
var
|
|
101
|
-
data =
|
|
102
|
-
panelProps =
|
|
103
|
-
onItemClick =
|
|
104
|
-
showProName =
|
|
105
|
-
showProgress =
|
|
106
|
-
fixHeight =
|
|
107
|
-
layout =
|
|
108
|
-
imgHeight =
|
|
109
|
-
imgWidth =
|
|
110
|
-
unknownPrice =
|
|
111
|
-
rest = __rest(
|
|
112
|
-
|
|
113
|
-
|
|
96
|
+
var _a, _b, _c, _d;
|
|
97
|
+
|
|
98
|
+
var _e = this.props,
|
|
99
|
+
data = _e.data,
|
|
100
|
+
panelProps = _e.panelProps,
|
|
101
|
+
onItemClick = _e.onItemClick,
|
|
102
|
+
showProName = _e.showProName,
|
|
103
|
+
showProgress = _e.showProgress,
|
|
104
|
+
fixHeight = _e.fixHeight,
|
|
105
|
+
layout = _e.layout,
|
|
106
|
+
imgHeight = _e.imgHeight,
|
|
107
|
+
imgWidth = _e.imgWidth,
|
|
108
|
+
unknownPrice = _e.unknownPrice,
|
|
109
|
+
rest = __rest(_e, ["data", "panelProps", "onItemClick", "showProName", "showProgress", "fixHeight", "layout", "imgHeight", "imgWidth", "unknownPrice"]); // const promotions = getPromotionList(data);
|
|
110
|
+
|
|
111
|
+
|
|
114
112
|
var price = (0, _currencyUtil.formatCurrency)(data.salesPrice);
|
|
115
113
|
/** 当是拼团时 显示价格 */
|
|
116
114
|
|
|
117
|
-
if (data.sppType
|
|
115
|
+
if (data.sppType) {
|
|
118
116
|
price = data.specialPrice !== null ? (0, _currencyUtil.formatCurrency)(data.specialPrice) : (0, _currencyUtil.formatCurrency)(data.salesPrice);
|
|
119
117
|
}
|
|
120
118
|
|
|
@@ -176,9 +174,9 @@ function (_super) {
|
|
|
176
174
|
small: true
|
|
177
175
|
})), /*#__PURE__*/_react["default"].createElement("div", {
|
|
178
176
|
className: "content-wrap"
|
|
179
|
-
}, panelProps.label.open && /*#__PURE__*/_react["default"].createElement("div", {
|
|
177
|
+
}, panelProps.label.open && ((_d = data === null || data === void 0 ? void 0 : data.cmpBuygetnLabels) === null || _d === void 0 ? void 0 : _d.length) > 0 && /*#__PURE__*/_react["default"].createElement("div", {
|
|
180
178
|
className: "promotions-wrap"
|
|
181
|
-
},
|
|
179
|
+
}, data.cmpBuygetnLabels.map(function (promot, index) {
|
|
182
180
|
return /*#__PURE__*/_react["default"].createElement(_components.MetaButton, {
|
|
183
181
|
key: index,
|
|
184
182
|
className: "promotion-item",
|
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|