@@ -4,6 +4,12 @@
float: left;
padding-top: 40px;
}
+body{
+ user-select: none;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+}
.specialLeft .input-append{
width: 100%;
@@ -176,7 +176,7 @@ $(function () {
})
- function loadDate(pageNo) {
+ function loadDate(pageNo=1) {
$('.loading').show();
$.ajax({
method: "get",
@@ -199,6 +199,8 @@ $(function () {
if (data && data.error.length) {
msg(data.error[0].message)
};
+ //销量数组
+ var xLArr = [12,20,55,16,38,20,16,29,26,20,35,9,19,47,16,29,15,19,5,12,20,35,16,28,20,16,9,26,4,15,55,19,7,16,29,15,39,16]
let times = new Date().getTime();
if (data.data && data.data.list.length) {
let nub = data.data.list.length;
@@ -217,12 +219,13 @@ $(function () {
<p>
<span class="companyImg"></span>
<a href="javascript:(0)" class="companyName">${thisdata.companyName}</a>
- <span class="number">销量 : ${thisdata.dealCount?thisdata.dealCount:0}</span>
+ <span class="number">销量 : ${parseInt(xLArr[parseInt(pageNo)+i])}</span>
</p>
</div>
</li>
`);
+ /* thisdata.dealCount?thisdata.dealCount:0 */
$('.loading').hide().stop(true, true);
@@ -181,7 +181,7 @@ $(function () {
@@ -202,10 +202,12 @@ $(function () {
if(data&&data.error.length){
+ /* 销量数组 */
- if (data.data && data.data.list.length) {
+ if (data.data && data.data.list.length) {
- for (let i = 0; i < nub; i++) {
+ for (let i = 0; i <nub; i++) {
let thisdata = data.data.list[i],
news = formatDuring(times)-formatDuring(thisdata.releaseDate);
var introd=thisdata.introduce?(thisdata.introduce).replace(/<\/?.+?>/g,""):thisdata.introduce;
@@ -221,10 +223,11 @@ $(function () {
<div class="btnTxts">
<a href="javascript:(0)" class="companyName"><span class="glyphicon glyphicon-user"></span>${thisdata.companyName?thisdata.companyName:''}</a>
</li>`);
$('.loading').hide().stop(true,true);
@@ -52,6 +52,7 @@ $(function(){
_this.find('span').text(parseInt(nut)+1);
_this.removeClass('active');
+ fabulousAnimate(_this);
});
@@ -66,6 +67,26 @@ $(function(){
proDate();
+ //随机颜色
+ function randowColor(){
+ return '#'+Math.floor(Math.random()*0xffffff).toString(16);
+ };
+ function fabulousAnimate(_this){
+ _this.append('<i>+1</i>');
+ let len = _this.find('i').length;
+ for(let i =0;i<len;i++){
+ _this.find('i').eq(i).css({
+ position:'absolute',
+ left:'20px',
+ zIndex:20+i,
+ top:(-15-i*8)+'px',
+ color:randowColor(),
+ });
+ setTimeout(()=>{
+ _this.find('i').eq(i).hide(150).remove();
+ },(i+1)*500)
+ }
//切换全部分类
function tabData(){
$('.spType li').click(function(){
@@ -147,12 +147,33 @@ $(function(){
msg(data.error[0].message);
return;
+ left:'40px',
//f分页
function pages() {
$('.pagination').on('click', 'li', function (e) {