Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYWAP
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
王水玲
9 years ago
Commit
781a774ef402cc25041baeb2a32d97318c023f37
1 parent
b4944a6e
星潮教室
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
33 additions
and
17 deletions
static/js/guang/calendar.js
static/js/guang/collocation-list.js
static/js/guang/star-classroom.js
static/sass/guang/_star-classroom.scss
template/m.yohobuy.com/partials/guang/pop-intimacy.phtml
static/js/guang/calendar.js
View file @
781a774
...
...
@@ -115,3 +115,5 @@ var CalendarHandler = {
$
(
document
).
ready
(
function
()
{
CalendarHandler
.
initialize
();
});
exports
.
calculateMonthDays
=
CalendarHandler
.
calculateMonthDays
;
...
...
static/js/guang/collocation-list.js
View file @
781a774
...
...
@@ -51,7 +51,7 @@ function scrollHandler() {
// function successShare() {
// $.ajax({
// type: 'POST',
// url: '',
// url: '
/guang/starclass/forward
',
// success: function(data) {
// var code = data.code;
...
...
@@ -105,7 +105,10 @@ $(document).on('click', '.collection', function() {
}
$that
.
find
(
'.collected-num'
).
html
(
data
.
num
);
}
if
(
code
===
201
)
{
window
.
location
=
data
.
data
;
}
},
error
:
function
()
{
...
...
static/js/guang/star-classroom.js
View file @
781a774
...
...
@@ -6,12 +6,11 @@
var
$
=
require
(
'jquery'
),
Swiper
=
require
(
'yoho.iswiper'
),
calendar
=
require
(
'../guang/calendar'
),
tip
=
require
(
'../plugin/tip'
);
var
bannerSwiper
,
collocationSwiper
;
var
nowDaysNub
=
0
;
// 日历弹出框显示及粉丝排行榜数据组装
function
intimacyData
(
data
)
{
var
$ul
=
$
(
'.fan-charts-cont'
),
...
...
@@ -19,7 +18,11 @@ function intimacyData(data) {
$increased
=
$
(
'.increased'
),
signDay
=
data
.
signDay
,
html
=
''
,
style
=
''
;
style
=
''
,
nowDate
=
new
Date
(),
nowYear
=
nowDate
.
getFullYear
(),
nowMonth
=
nowDate
.
getMonth
(),
nowDaysNub
=
calendar
.
calculateMonthDays
(
nowMonth
,
nowYear
);
var
i
;
...
...
@@ -49,11 +52,19 @@ function intimacyData(data) {
$ul
.
html
(
html
);
$myIntimacy
.
find
(
'span'
).
html
(
data
.
intimacyNum
);
$increased
.
find
(
'span'
).
html
(
data
.
intimacyNum
);
$myIntimacy
.
find
(
'span'
).
html
(
data
.
todayIntimacy
);
$increased
.
find
(
'span'
).
html
(
data
.
todayIntimacy
);
if
(
data
.
intimacyNum
===
0
)
{
$
(
'.my-intimacy'
).
hide
();
$
(
'.increased'
).
show
();
}
else
{
$
(
'.my-intimacy'
).
show
();
$
(
'.increased'
).
hide
();
}
$
(
'.pop-intimacy'
).
show
();
$
(
'.mask'
).
show
();
$
(
'.
classroom-
mask'
).
show
();
$
(
'body'
).
css
({
overflow
:
'hidden'
});
...
...
@@ -185,12 +196,11 @@ $('.add-intimacy').on('click', function() {
var
code
=
data
.
code
;
if
(
code
===
200
)
{
if
(
data
.
intimacyNum
===
0
)
{
$
(
'.my-intimacy'
).
hide
();
$
(
'.increased'
).
show
();
}
else
{
intimacyData
(
data
.
data
);
}
intimacyData
(
data
.
data
);
}
if
(
code
===
201
)
{
window
.
location
=
data
.
data
;
}
},
error
:
function
()
{
...
...
@@ -200,9 +210,9 @@ $('.add-intimacy').on('click', function() {
});
// 关闭日历弹出窗事件
$
(
'.pop-intimacy .pop-close, .mask'
).
on
(
'click'
,
function
()
{
$
(
'.pop-intimacy .pop-close, .
classroom-
mask'
).
on
(
'click'
,
function
()
{
$
(
'.pop-intimacy'
).
hide
();
$
(
'.mask'
).
hide
();
$
(
'.
classroom-
mask'
).
hide
();
$
(
'body'
).
css
({
overflow
:
'visible'
...
...
static/sass/guang/_star-classroom.scss
View file @
781a774
...
...
@@ -308,7 +308,7 @@ body {
.pop-intimacy
{
width
:
580rem
/
$pxConvertRem
;
height
:
9
1
0rem
/
$pxConvertRem
;
height
:
9
2
0rem
/
$pxConvertRem
;
background
:
#fff
;
border-radius
:
10rem
/
$pxConvertRem
;
position
:
fixed
;
...
...
@@ -501,6 +501,7 @@ body {
}
.fans-intimacy
{
width
:
150rem
/
$pxConvertRem
;
float
:
right
;
font-size
:
20rem
/
$pxConvertRem
;
color
:
#444
;
...
...
template/m.yohobuy.com/partials/guang/pop-intimacy.phtml
View file @
781a774
...
...
@@ -4,7 +4,7 @@
<h1 class="cur-year"></h1>
<h4 class="cur-month"></h4>
<div class="my-intimacy">亲密度 <span></span></div>
<div class="increased">今日已增加<span></span>
,
明日再来哦!</div>
<div class="increased">今日已增加<span></span>
,
明日再来哦!</div>
</div>
<div class="calendar">
<input type="hidden" value="{{signDay}}" class="sign-day" />
...
...
Please
register
or
login
to post a comment