...
|
...
|
@@ -5,6 +5,10 @@ |
|
|
*/
|
|
|
var $ = require('jquery');
|
|
|
|
|
|
var $footer = $('#yoho-footer');
|
|
|
|
|
|
var FOOTERHEIGHT = 120; //footer height
|
|
|
|
|
|
function cookie(name) {
|
|
|
var cookies = document.cookie,
|
|
|
cookieVal,
|
...
|
...
|
@@ -90,14 +94,26 @@ function getShoppingKey() { |
|
|
return JSON.parse(c).k;
|
|
|
}
|
|
|
|
|
|
//根据页面内容重新设置通用底部的显示
|
|
|
function rePosFooter() {
|
|
|
if ($footer.length === 0) {
|
|
|
return;
|
|
|
}
|
|
|
|
|
|
if ($('body').height() < $(window).height() - FOOTERHEIGHT) {
|
|
|
$footer.addClass('bottom');
|
|
|
} else {
|
|
|
$footer.removeClass('bottom');
|
|
|
}
|
|
|
}
|
|
|
|
|
|
//页面通用底部位置及status设置
|
|
|
(function () {
|
|
|
var $footer = $('#yoho-footer'),
|
|
|
$op = $footer.children('.op-row');
|
|
|
var $op = $footer.children('.op-row');
|
|
|
|
|
|
var user = getUser();
|
|
|
|
|
|
if ($('body').height() < $(window).height()) {
|
|
|
if ($('body').height() < $(window).height() - FOOTERHEIGHT) {
|
|
|
$footer.addClass('bottom');
|
|
|
}
|
|
|
|
...
|
...
|
@@ -132,3 +148,5 @@ window.getUser = getUser; |
|
|
window.getUid = getUid;
|
|
|
|
|
|
window.getShoppingKey = getShoppingKey;
|
|
|
|
|
|
window.rePosFooter = rePosFooter; |
...
|
...
|
|