|
30 | 30 | </view> |
31 | 31 | <view v-if="moreInfo.uid>0" class="row text-center font-lv4 text-muted reading-time"> |
32 | 32 | <view class="col-4"> |
33 | | - <view><text class="font-lv3">{{moreInfo.today_reading_hour}}</text> 时 <text class="font-lv3">{{moreInfo.today_reading_min}}</text> |
| 33 | + <view><text class="font-lv3">{{moreInfo.today_reading_hour}}</text> 时 <text |
| 34 | + class="font-lv3">{{moreInfo.today_reading_min}}</text> |
34 | 35 | 分</view> |
35 | 36 | <view class="font-lv5">今日阅读</view> |
36 | 37 | </view> |
37 | 38 | <view class="col-4"> |
38 | | - <view><text class="font-lv3">{{moreInfo.month_reading_hour}}</text> 时 <text class="font-lv3">{{moreInfo.month_reading_min}}</text> |
| 39 | + <view><text class="font-lv3">{{moreInfo.month_reading_hour}}</text> 时 <text |
| 40 | + class="font-lv3">{{moreInfo.month_reading_min}}</text> |
39 | 41 | 分</view> |
40 | 42 | <view class="font-lv5">本月阅读</view> |
41 | 43 | </view> |
42 | 44 | <view class="col-4"> |
43 | | - <view><text class="font-lv3">{{moreInfo.total_reading_hour}}</text> 时 <text class="font-lv3">{{moreInfo.total_reading_min}}</text> |
| 45 | + <view><text class="font-lv3">{{moreInfo.total_reading_hour}}</text> 时 <text |
| 46 | + class="font-lv3">{{moreInfo.total_reading_min}}</text> |
44 | 47 | 分</view> |
45 | 48 | <view class="font-lv5">累计阅读</view> |
46 | 49 | </view> |
|
59 | 62 |
|
60 | 63 | </view> |
61 | 64 | <view class='base-padding row base-info font-lv2'> |
62 | | - |
| 65 | + |
63 | 66 | <navigator url='/pages/search/search' class='col-12'> |
64 | 67 | <image class="me-icon" src='../../static/images/search.png'></image> |
65 | 68 | <text>书籍搜索</text> |
|
207 | 210 | util.request(config.api.logout) // 只需调用,不需要处理返回结果 |
208 | 211 | util.clearUser() |
209 | 212 | util.toastSuccess('退出成功') |
210 | | - that.initUser() |
| 213 | + that.initUser() |
211 | 214 | util.setSignedAt(0) |
212 | 215 | let sysInfo = util.getSysInfo() |
213 | 216 | sysInfo.bookshelfChanged = true |
|
223 | 226 | url: '/pages/login/login?redirect=' + this.redirect |
224 | 227 | }) |
225 | 228 | } |
226 | | - }, |
227 | | - sign: function(){ |
228 | | - let that = this |
229 | | - util.request(config.api.userSign, {}, 'POST').then(function(res){ |
230 | | - util.setSignedAt(res.data.signed_at) |
231 | | - uni.showToast({ |
232 | | - title: res.data.message, |
233 | | - duration: 5000, |
234 | | - icon: 'none', |
235 | | - }) |
236 | | - that.isSignedToday = util.isSignedToday() |
237 | | - }).catch(function(e){ |
238 | | - console.log(e) |
239 | | - util.toastError(e.data.message || e.errMsg) |
240 | | - }) |
| 229 | + }, |
| 230 | + sign: function() { |
| 231 | + let that = this |
| 232 | + util.request(config.api.userSign, {}, 'POST').then(function(res) { |
| 233 | + util.setSignedAt(res.data.signed_at) |
| 234 | + uni.showToast({ |
| 235 | + title: res.data.message, |
| 236 | + duration: 5000, |
| 237 | + icon: 'none', |
| 238 | + }) |
| 239 | + that.isSignedToday = util.isSignedToday() |
| 240 | + }).catch(function(e) { |
| 241 | + console.log(e) |
| 242 | + util.toastError(e.data.message || e.errMsg) |
| 243 | + }) |
241 | 244 | }, |
242 | 245 | getUserMoreInfo: function() { |
243 | 246 | let that = this |
|
283 | 286 |
|
284 | 287 | .row { |
285 | 288 | background-color: #fff; |
286 | | - margin-bottom: 10upx; |
287 | | - padding: 30upx; |
| 289 | + margin-bottom: 5px; |
| 290 | + padding: 15px; |
288 | 291 | } |
289 | 292 |
|
290 | 293 | .row:last-of-type { |
291 | | - margin-bottom: 0upx; |
| 294 | + margin-bottom: 0; |
292 | 295 | } |
293 | 296 |
|
294 | 297 | .user { |
|
316 | 319 | } |
317 | 320 |
|
318 | 321 | .username { |
319 | | - margin: 15upx auto; |
| 322 | + margin: 15px auto; |
320 | 323 | } |
321 | 324 |
|
322 | 325 | .user image { |
323 | | - width: 180upx; |
324 | | - height: 180upx; |
325 | | - border-radius: 90upx; |
| 326 | + width: 90px; |
| 327 | + height: 90px; |
| 328 | + border-radius: 45px; |
326 | 329 | border: 1px solid #ddd; |
327 | 330 | margin: 0 auto; |
328 | 331 | display: block; |
329 | 332 | } |
330 | 333 |
|
331 | 334 | .base-info image { |
332 | | - margin-right: 30upx !important; |
| 335 | + margin-right: 15px !important; |
333 | 336 | } |
334 | 337 |
|
335 | 338 | .base-info image.pull-right { |
|
344 | 347 |
|
345 | 348 | .base-info .col-12 { |
346 | 349 | border-bottom: 1px solid #f6f6f6; |
347 | | - padding-bottom: 30upx; |
348 | | - padding-top: 30upx; |
| 350 | + padding-bottom: 15px; |
| 351 | + padding-top: 15px; |
349 | 352 | color: #666; |
350 | 353 | } |
351 | 354 |
|
|
360 | 363 | } |
361 | 364 |
|
362 | 365 | .user-func { |
363 | | - line-height: 40upx; |
| 366 | + line-height: 20px; |
364 | 367 | border: 1px solid #000000; |
365 | 368 | } |
366 | 369 |
|
|
372 | 375 | } |
373 | 376 |
|
374 | 377 | .user-func .color-red { |
375 | | - margin-right: 8upx; |
| 378 | + margin-right: 4px; |
376 | 379 | } |
377 | 380 |
|
378 | 381 | .reading-time text { |
379 | | - margin: auto 8upx; |
| 382 | + margin: auto 4px; |
380 | 383 | color: red; |
381 | 384 | } |
382 | 385 |
|
|
388 | 391 | .reading-time .col-4:nth-child(2), |
389 | 392 | .reading-time .col-4:nth-child(3) { |
390 | 393 | border-bottom: 1px solid #f6f6f6; |
391 | | - padding-bottom: 16upx; |
| 394 | + padding-bottom: 8px; |
392 | 395 | } |
393 | 396 |
|
394 | 397 | .reading-time .col-4:nth-child(4), |
395 | 398 | .reading-time .col-4:nth-child(5), |
396 | 399 | .reading-time .col-4:nth-child(6) { |
397 | | - padding-top: 16upx; |
| 400 | + padding-top: 8px; |
398 | 401 | } |
399 | 402 |
|
400 | 403 | .reading-time .col-4:nth-child(2), |
|
404 | 407 | } |
405 | 408 |
|
406 | 409 | image.me-icon { |
407 | | - width: 40upx; |
408 | | - height: 40upx; |
| 410 | + width: 20px; |
| 411 | + height: 20px; |
409 | 412 | vertical-align: middle; |
410 | | - margin-right: 6upx; |
| 413 | + margin-right: 3px; |
411 | 414 | position: relative; |
412 | | - top: -4upx; |
| 415 | + top: -2px; |
413 | 416 | } |
414 | 417 |
|
415 | 418 | .signed image { |
416 | | - width: 25upx; |
417 | | - height: 25upx; |
| 419 | + width: 13px; |
| 420 | + height: 13px; |
418 | 421 | } |
419 | 422 |
|
420 | 423 | .signed.text-muted { |
|
431 | 434 | } |
432 | 435 |
|
433 | 436 | @media (min-width: 768px) { |
434 | | -
|
435 | 437 | .base-info image, |
436 | 438 | image.me-icon { |
437 | 439 | max-width: 20px; |
|
0 commit comments