...
|
...
|
@@ -13,23 +13,41 @@ |
|
|
<script type="text/javascript" src="js/jquery.min.js"></script>
|
|
|
<script type="text/javascript" src="js/autoSize.js"></script>
|
|
|
<script>
|
|
|
var uid;//用户ID
|
|
|
$(
|
|
|
function () {
|
|
|
|
|
|
//判定登录
|
|
|
var dataRequestUrl="http://m.yohobuy.com/passport/login/user";
|
|
|
$.getJSON(dataRequestUrl+"?callback=?",
|
|
|
function(json) {
|
|
|
if (json.code === 200) {
|
|
|
uid=json.data;
|
|
|
} else {
|
|
|
var url ='https://m.yohobuy.com/signin.html?openby:yohobuy={"action":"go.weblogin","params":{"jumpurl":{"url":'
|
|
|
+'/activity/favoriteAct/index.html'+'","param":{"from":"app"}},"requesturl":{"url":"","param":{}},"priority":"Y"}}';
|
|
|
window.location.href=url;
|
|
|
}
|
|
|
}
|
|
|
);
|
|
|
|
|
|
$(".good-c .add-btn").click(
|
|
|
function () {
|
|
|
$.ajax({
|
|
|
url: '/activity/favorite/addFavorite?productSkn=234234&uid=234234',
|
|
|
type: "get",
|
|
|
dataType: 'json',
|
|
|
success: function (data) {
|
|
|
if (data.code === 200) {
|
|
|
alert(data.message);
|
|
|
} else {
|
|
|
alert(data.message);
|
|
|
}
|
|
|
function () {
|
|
|
var skn = $(this).parents("li").attr("sknNum");
|
|
|
alert (skn);
|
|
|
$.ajax({
|
|
|
url: '/activity/favorite/addFavorite?productSkn=' + skn +'&uid=' + uid,
|
|
|
type: "get",
|
|
|
dataType: 'json',
|
|
|
success: function (data) {
|
|
|
if (data.code === 200) {
|
|
|
alert(data.message);
|
|
|
} else {
|
|
|
alert(data.message);
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
});
|
|
|
}
|
|
|
);
|
|
|
}
|
|
|
);
|
...
|
...
|
@@ -44,7 +62,7 @@ |
|
|
<img src="images/tip-pic-1.jpg"/>
|
|
|
</div>
|
|
|
<ul class="good-ul clearfix">
|
|
|
<li>
|
|
|
<li sknNum="001">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -64,7 +82,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="002">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -84,7 +102,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="003">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -104,7 +122,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="004">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -124,7 +142,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="005">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -144,7 +162,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="006">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -164,7 +182,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="007">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -184,7 +202,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="008">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -204,7 +222,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="009">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -224,7 +242,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="010">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
@@ -244,7 +262,7 @@ |
|
|
<img src="images/good-dot.jpg"/>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li>
|
|
|
<li sknNum="011">
|
|
|
<div class="good-c">
|
|
|
<div class="pic-c">
|
|
|
<img src="images/good.jpg"/>
|
...
|
...
|
|