@@ -24,6 +24,20 @@ Page({ | |||||
this.setData({ | this.setData({ | ||||
id: options.id | id: options.id | ||||
}) | }) | ||||
if (options.id == "example") { | |||||
console.log(1); | |||||
const arr = [ | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" } | |||||
] | |||||
this.setData({ | |||||
swiperList: arr, | |||||
title: "示例" | |||||
}) | |||||
return | |||||
} | |||||
app.tokenCallBack = token => { | app.tokenCallBack = token => { | ||||
if (!token) { | if (!token) { | ||||
wx.redirectTo({ | wx.redirectTo({ | ||||
@@ -89,6 +103,14 @@ Page({ | |||||
}, | }, | ||||
downloadImage() { | downloadImage() { | ||||
const isLogin = wx.getStorageSync('token') | |||||
if (!isLogin) { | |||||
wx.redirectTo({ | |||||
url: '/pages/login/login', | |||||
}) | |||||
return | |||||
} | |||||
const index = this.data.currentIndex | const index = this.data.currentIndex | ||||
const list = this.data.swiperList | const list = this.data.swiperList | ||||
const filePath = "zhixiangImg.png" | const filePath = "zhixiangImg.png" | ||||
@@ -8,6 +8,19 @@ Page({ | |||||
data: { | data: { | ||||
isLogin: false, | isLogin: false, | ||||
itemList: [], | itemList: [], | ||||
tempList: [ | |||||
{ | |||||
title: "示例", | |||||
createDate: "2023-10-01 12:00:00", | |||||
id:"example", | |||||
photoList: [ | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" }, | |||||
{ image: "https://formall.oss-accelerate.aliyuncs.com/smartcapi/2023-09-27/5263476f945343bbab20e007bfd32c4b.jpg?x-oss-process=image/resize,w_10000/quality,q_60" } | |||||
] | |||||
} | |||||
], | |||||
showPrivacy: false, | showPrivacy: false, | ||||
currentIndex: 1, | currentIndex: 1, | ||||
avatarUrl: "../../asset/icon/logo-5.png", | avatarUrl: "../../asset/icon/logo-5.png", | ||||
@@ -125,7 +125,7 @@ page { | |||||
font-weight: 600; | font-weight: 600; | ||||
color: #ff4f00; | color: #ff4f00; | ||||
text-decoration: underline; | text-decoration: underline; | ||||
margin-top: 40rpx; | |||||
margin: 40rpx 0; | |||||
} | } | ||||
} | } | ||||
@@ -34,7 +34,24 @@ | |||||
</block> | </block> | ||||
<block wx:if="{{ !isLogin }}"> | <block wx:if="{{ !isLogin }}"> | ||||
<view class="goLogin" bindtap="goLogin">登录即可体验全部功能哦</view> | |||||
<view class="goLogin" bindtap="goLogin">登录即可体验云相册功能哦</view> | |||||
<scroll-view class="scrollView" type="list" scroll-y scroll-with-animatio scroll-top="{{ scrollTop }}" bindscrolltolower="loadMoreData"> | |||||
<view wx:for="{{tempList}}" class="item" wx:key="index"> | |||||
<view class="top"> | |||||
<view class="modelName">{{ item.title }}</view> | |||||
<view class="date">{{ item.createDate }}</view> | |||||
<view class="more" bindtap="showMore" data-id="{{ item.id }}"> | |||||
<image src="../../asset/icon/more.png" mode="widthFix" /> | |||||
</view> | |||||
</view> | |||||
<view class="photoList" bindtap="goCheckImage" data-id="{{ item.id }}"> | |||||
<image wx:for="{{ item.photoList }}" wx:for-index="childIndex" wx:for-item="chileItem" wx:key="childIndex" src="{{ chileItem.image }}" mode="widthFix" /> | |||||
</view> | |||||
</view> | |||||
<view class="placeHolder"></view> | |||||
</scroll-view> | |||||
</block> | </block> | ||||
</view> | </view> | ||||
@@ -227,7 +227,7 @@ Page({ | |||||
const that = this | const that = this | ||||
const data = { | const data = { | ||||
id: this.data.id, | id: this.data.id, | ||||
image: this.data.onlineFilePath | |||||
image: [this.data.onlineFilePath] | |||||
} | } | ||||
request.post({ | request.post({ | ||||
@@ -15,7 +15,7 @@ | |||||
<block wx:if="{{ isSuccess }}"> | <block wx:if="{{ isSuccess }}"> | ||||
<button class="uploadImgBtn" bindtap="confirmImage">就这张了</button> | <button class="uploadImgBtn" bindtap="confirmImage">就这张了</button> | ||||
<button class="reUpload" bindtap="chooseImage">重新上传</button> | |||||
<!-- <button class="reUpload" bindtap="chooseImage">重新上传</button> --> | |||||
</block> | </block> | ||||
<view class="notice"> | <view class="notice"> | ||||