Commit a060901e by lmf

优化详情预计交货时间bug

parent e55f9a62
......@@ -84,6 +84,38 @@
</div>
</div>
</div>
<script>
require(['jquery'],function($){
$('.mod-sizechart .content .sizechart-table').append($('.common-sizeinfo').clone());
let start = new Date();
start.setDate(start.getDate()+3);
let smonth = (start.getMonth()+1) < 10 ? "0"+ (start.getMonth()+1) : (start.getMonth()+1);
let sdate = start.getDate() < 10 ? "0"+ start.getDate() : start.getDate();
let end = new Date();
end.setDate(end.getDate()+15);
let emonth = (end.getMonth()+1) < 10 ? "0"+ (end.getMonth()+1) : (end.getMonth()+1);
let edate = end.getDate() < 10 ? "0"+ end.getDate() : end.getDate();
let startTime = smonth + "/" + sdate +"/" +(start.getFullYear());
let endTime = emonth + "/" + edate + "/" + (end.getFullYear());
$('#deliveredTime').text(startTime+"-"+endTime);
});
</script>
<span type="button" class="action" data-trigger="trigger">
<span>Size Chart</span>
</span>
<div data-bind="mageInit: {
'Magento_Ui/js/modal/modal':{
'type': 'popup',
'title': '',
'trigger': '[data-trigger=trigger]',
'responsive': true,
buttons: []
}}">
<div class="content">
<?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('product-intro-fast-delivery')->toHtml();?>
</div>
</div>
<style>
.product-intro__freeshipping-icon .svgicon {
width: 15px;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment