|
|
@ -2,22 +2,43 @@ |
|
|
<view class="container"> |
|
|
<view class="container"> |
|
|
<view class="top"> |
|
|
<view class="top"> |
|
|
<uni-swiper-dot class="uni-swiper-dot-box" @clickItem=clickItem :info="info" :current="current" :mode="mode" |
|
|
<uni-swiper-dot class="uni-swiper-dot-box" @clickItem=clickItem :info="info" :current="current" :mode="mode" |
|
|
field="content"> |
|
|
field="content"> |
|
|
<swiper class="swiper-box" @change="change" :current="swiperDotIndex" :autoplay="autoplay" |
|
|
<swiper class="swiper-box" @change="change" :current="swiperDotIndex" :autoplay="autoplay" |
|
|
:interval="interval" :duration="duration"> |
|
|
:interval="interval" :duration="duration"> |
|
|
<swiper-item v-for="(item, index) in 3" :key="index"> |
|
|
<swiper-item v-for="(item, index) in 3" :key="index"> |
|
|
<view class="swiper-item" :class="'swiper-item' + index"> |
|
|
<view class="swiper-item" :class="'swiper-item' + index"> |
|
|
<text style="color: #fff; font-size: 32px;">{{index+1}}</text> |
|
|
<text style="color: #fff; font-size: 32px;">{{index+1}}</text> |
|
|
</view> |
|
|
</view> |
|
|
</swiper-item> |
|
|
</swiper-item> |
|
|
</swiper> |
|
|
</swiper> |
|
|
</uni-swiper-dot> |
|
|
</uni-swiper-dot> |
|
|
</view> |
|
|
</view> |
|
|
<view class="middle"> |
|
|
<view class="middle"> |
|
|
素材管理、上传图片 |
|
|
<uni-group mode="card"> |
|
|
|
|
|
<uni-grid :column="2" :square="true" :highlight="false" @change="change" :showBorder="false"> |
|
|
|
|
|
<uni-grid-item v-for="(item, index) in funcList" :index="index" :key="index"> |
|
|
|
|
|
<view class="grid-item-box"> |
|
|
|
|
|
<!-- <image :src="item.url" class="image" mode="aspectFill" /> --> |
|
|
|
|
|
<uni-icons type="image" :size="30" color="#777" /> |
|
|
|
|
|
<text class="text">{{ item.title }}</text> |
|
|
|
|
|
</view> |
|
|
|
|
|
</uni-grid-item> |
|
|
|
|
|
</uni-grid> |
|
|
|
|
|
</uni-group> |
|
|
</view> |
|
|
</view> |
|
|
<view class="foot"> |
|
|
<view class="foot"> |
|
|
表格展示艺术家上传的图片数据 |
|
|
<uni-group mode="card" title="素材数据" style="text-align:center;"> |
|
|
|
|
|
<uni-grid :column="3" :square="true" :highlight="false" @change="change"> |
|
|
|
|
|
<uni-grid-item v-for="(item, index) in list" :index="index" :key="index"> |
|
|
|
|
|
<view class="grid-item-box"> |
|
|
|
|
|
<!-- <image :src="item.url" class="image" mode="aspectFill" /> --> |
|
|
|
|
|
<uni-icons type="image" :size="30" color="#777" /> |
|
|
|
|
|
<text class="text">{{ item.text }}</text> |
|
|
|
|
|
<text class="text">{{ item.num }}</text> |
|
|
|
|
|
</view> |
|
|
|
|
|
</uni-grid-item> |
|
|
|
|
|
</uni-grid> |
|
|
|
|
|
</uni-group> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</template> |
|
|
</template> |
|
|
@ -37,18 +58,65 @@ |
|
|
mode: 'nav', |
|
|
mode: 'nav', |
|
|
swiperDotIndex: 0, |
|
|
swiperDotIndex: 0, |
|
|
autoplay: true, |
|
|
autoplay: true, |
|
|
interval: 5000, |
|
|
interval: 5000, |
|
|
duration: 500 |
|
|
duration: 500, |
|
|
|
|
|
pageUrl:'', |
|
|
|
|
|
funcList: [{ |
|
|
|
|
|
title: '素材管理', |
|
|
|
|
|
url: '/pages/index/material/material' |
|
|
|
|
|
}, { |
|
|
|
|
|
title: '上传素材', |
|
|
|
|
|
url: '/pages/index/upload/upload' |
|
|
|
|
|
}], |
|
|
|
|
|
list: [{ |
|
|
|
|
|
url: '/static/c1.png', |
|
|
|
|
|
text: '头像', |
|
|
|
|
|
num: '16' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
url: '/static/c2.png', |
|
|
|
|
|
text: '背景图', |
|
|
|
|
|
num: '1' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
url: '/static/c3.png', |
|
|
|
|
|
text: '手机壁纸', |
|
|
|
|
|
num: '99' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
url: '/static/c4.png', |
|
|
|
|
|
text: '动态壁纸', |
|
|
|
|
|
num: '23', |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
url: '/static/c5.png', |
|
|
|
|
|
text: 'apple watch', |
|
|
|
|
|
num: '15' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
url: '/static/c6.png', |
|
|
|
|
|
text: '表情包', |
|
|
|
|
|
num: '31' |
|
|
|
|
|
} |
|
|
|
|
|
] |
|
|
}; |
|
|
}; |
|
|
}, |
|
|
}, |
|
|
methods:{ |
|
|
methods: { |
|
|
change(e) { |
|
|
change(e) { |
|
|
this.current = e.detail.current; |
|
|
let { |
|
|
//console.log('this.current',this.current) |
|
|
index |
|
|
|
|
|
} = e.detail |
|
|
|
|
|
this.funcList[index].badge && this.funcList[index].badge++ |
|
|
|
|
|
this.pageUrl = this.funcList[index].url |
|
|
|
|
|
console.log('this.pageUrl',this.pageUrl) |
|
|
|
|
|
/** 跳转指定页面*/ |
|
|
|
|
|
uni.navigateTo({ |
|
|
|
|
|
url: this.pageUrl |
|
|
|
|
|
}); |
|
|
}, |
|
|
}, |
|
|
clickItem(e) { |
|
|
clickItem(e) { |
|
|
this.swiperDotIndex = e |
|
|
this.swiperDotIndex = e |
|
|
console.log('this.swiperDotIndex',this.swiperDotIndex) |
|
|
console.log('this.swiperDotIndex', this.swiperDotIndex) |
|
|
}, |
|
|
}, |
|
|
// 获取用户信息 |
|
|
// 获取用户信息 |
|
|
getUserInfo() { |
|
|
getUserInfo() { |
|
|
@ -64,7 +132,7 @@ |
|
|
iv: userInfo.iv |
|
|
iv: userInfo.iv |
|
|
} |
|
|
} |
|
|
// 用户授权登录 |
|
|
// 用户授权登录 |
|
|
console.log('params',params); |
|
|
console.log('params', params); |
|
|
loginWx(params).then(res => { |
|
|
loginWx(params).then(res => { |
|
|
if (res.data.code === 200) { |
|
|
if (res.data.code === 200) { |
|
|
uni.setStorage({ |
|
|
uni.setStorage({ |
|
|
@ -96,89 +164,35 @@ |
|
|
</script> |
|
|
</script> |
|
|
|
|
|
|
|
|
<style lang="scss"> |
|
|
<style lang="scss"> |
|
|
// .container { |
|
|
.container{ |
|
|
// .top { |
|
|
font-family:‘Franklin Gothic Medium’, ‘Arial Narrow’, Arial, sans-serif; |
|
|
// width: 100vw; |
|
|
} |
|
|
|
|
|
.grid-item-box { |
|
|
// image { |
|
|
flex: 1; |
|
|
// width: 100vw; |
|
|
// position: relative; |
|
|
// height: 400rpx; |
|
|
/* #ifndef APP-NVUE */ |
|
|
// } |
|
|
display: flex; |
|
|
|
|
|
/* #endif */ |
|
|
// .uni-searchbar { |
|
|
flex-direction: column; |
|
|
// border: 1px solid #11A8FD; |
|
|
align-items: center; |
|
|
// margin: 0 40rpx; |
|
|
justify-content: center; |
|
|
// border-radius: 16rpx; |
|
|
padding: 10px 0; |
|
|
// padding: 0; |
|
|
} |
|
|
|
|
|
|
|
|
// .uni-searchbar__box { |
|
|
.grid-item-box-row { |
|
|
// padding: 0; |
|
|
flex: 1; |
|
|
// border-radius: 16rpx !important; |
|
|
// position: relative; |
|
|
// } |
|
|
/* #ifndef APP-NVUE */ |
|
|
// } |
|
|
display: flex; |
|
|
|
|
|
/* #endif */ |
|
|
// >text { |
|
|
flex-direction: row; |
|
|
// font-weight: bold; |
|
|
align-items: center; |
|
|
// font-size: 14px; |
|
|
justify-content: center; |
|
|
// display: block; |
|
|
padding: 10px 0; |
|
|
// text-align: center; |
|
|
} |
|
|
// padding-top: 40rpx; |
|
|
|
|
|
// padding-bottom: 20rpx; |
|
|
.swiper-box { |
|
|
// } |
|
|
height: 150px; |
|
|
|
|
|
|
|
|
// .user-list { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// justify-content: flex-start; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// overflow-x: auto; |
|
|
|
|
|
|
|
|
|
|
|
// .user-list-box { |
|
|
|
|
|
// width: 140rpx; |
|
|
|
|
|
// padding: 20rpx; |
|
|
|
|
|
// text-align: center; |
|
|
|
|
|
|
|
|
|
|
|
// image { |
|
|
|
|
|
// width: 100rpx; |
|
|
|
|
|
// height: 100rpx; |
|
|
|
|
|
// border-radius: 100rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// text { |
|
|
|
|
|
// font-size: 24rpx; |
|
|
|
|
|
// color: #1E1E1E; |
|
|
|
|
|
// text-align: center; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .middle { |
|
|
|
|
|
// text-align: center; |
|
|
|
|
|
// height: calc(100vh - 248rpx); |
|
|
|
|
|
// padding-top: 40rpx; |
|
|
|
|
|
|
|
|
|
|
|
// text { |
|
|
|
|
|
// font-weight: bold; |
|
|
|
|
|
// font-size: 14px; |
|
|
|
|
|
// display: block; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// image { |
|
|
|
|
|
// width: 40rpx; |
|
|
|
|
|
// height: 40rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
.middle{ |
|
|
|
|
|
margin-top: 100px; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.foot{ |
|
|
|
|
|
margin-top: 100px; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.swiper-box { |
|
|
|
|
|
height: 180px; |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.swiper-item { |
|
|
.swiper-item { |
|
|
|