...
|
...
|
@@ -2024,28 +2024,16 @@ $(function() { |
|
|
|
|
|
// 调整食品类商品信息的间距
|
|
|
let $productionTime = $('.description-content .basic span[data-key=生产日期]').parents('.justpostion');
|
|
|
let $releaseTime = $('.description-content .basic span[data-key=过期时间]').parents('.justpostion');
|
|
|
let releaseTimeIndex = $releaseTime.parents('li').index();
|
|
|
let productionTimeIndex = $productionTime.parents('li').index();
|
|
|
let postionLeft1 = '100px';
|
|
|
let postionLeft2 = '56px';
|
|
|
|
|
|
if ($releaseTime.length) {
|
|
|
if ((releaseTimeIndex + 1) % 3 === 1 && $productionTime.width() > 285) {
|
|
|
if ($productionTime.length) {
|
|
|
if ((productionTimeIndex + 1) % 3 === 2 && $productionTime.width() > 285) {
|
|
|
postionLeft2 = 0;
|
|
|
}
|
|
|
|
|
|
if ((releaseTimeIndex + 1) % 3 === 2) {
|
|
|
if ($releaseTime.width() > 285) {
|
|
|
postionLeft2 = 0;
|
|
|
}
|
|
|
|
|
|
if ($productionTime.width() > 285) {
|
|
|
postionLeft1 = 0;
|
|
|
postionLeft2 = 0;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
if ((releaseTimeIndex + 1) % 3 === 0 && $releaseTime.width() > 285) {
|
|
|
if ((productionTimeIndex + 1) % 3 === 0 && $productionTime.width() > 285) {
|
|
|
postionLeft1 = 0;
|
|
|
}
|
|
|
}
|
...
|
...
|
|