帧视界壹通告,付费看视频的微信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

134 lines
2.1 KiB

11 months ago
10 months ago
11 months ago
10 months ago
10 months ago
11 months ago
10 months ago
11 months ago
10 months ago
10 months ago
10 months ago
11 months ago
10 months ago
10 months ago
10 months ago
11 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
10 months ago
11 months ago
10 months ago
11 months ago
  1. <template>
  2. <view class="controls">
  3. <view class="bell"
  4. @click="bell">
  5. <uv-icon size="35rpx" name="bell"></uv-icon>
  6. 举报
  7. </view>
  8. <view class=""
  9. @click="thumbUp">
  10. <uv-icon size="35rpx"
  11. color="#f40"
  12. name="thumb-up"
  13. v-if="up"></uv-icon>
  14. <uv-icon v-else size="35rpx" name="thumb-up"></uv-icon>
  15. 点赞
  16. </view>
  17. <view class="">
  18. <button
  19. border="none"
  20. open-type="share" class="share">
  21. <uv-icon size="35rpx" name="share"></uv-icon>
  22. 分享
  23. </button>
  24. </view>
  25. <view class=""
  26. v-if="!isWork"
  27. @click="thumbDown">
  28. <uv-icon
  29. v-if="down"
  30. color="#f40"
  31. size="35rpx" name="thumb-down"></uv-icon>
  32. <uv-icon
  33. v-else
  34. size="35rpx" name="thumb-down"></uv-icon>
  35. </view>
  36. </view>
  37. </template>
  38. <script>
  39. export default {
  40. name:"contentControls",
  41. props : {
  42. type : {
  43. default : 0
  44. },
  45. detail : {
  46. default : {}
  47. },
  48. up : {
  49. default : false,
  50. },
  51. down : {
  52. default : false,
  53. },
  54. isWork : {
  55. default : false,
  56. }
  57. },
  58. data() {
  59. return {
  60. };
  61. },
  62. methods : {
  63. // 举报
  64. bell(){
  65. this.$api('infoReport', {
  66. type : this.type,
  67. id : this.detail.id,
  68. }, res => {
  69. if(res.code == 200){
  70. this.$emit('loadData')
  71. uni.showToast({
  72. title: res.message
  73. })
  74. }
  75. })
  76. },
  77. // 点赞
  78. thumbUp(){
  79. this.$api('infoLike', {
  80. type : this.type,
  81. id : this.detail.id,
  82. }, res => {
  83. if(res.code == 200){
  84. this.$emit('loadData')
  85. uni.showToast({
  86. title: res.message
  87. })
  88. }
  89. })
  90. },
  91. // 分享
  92. share(){
  93. },
  94. // 踩
  95. thumbDown(){
  96. this.$api('infoDislike', {
  97. type : this.type,
  98. id : this.detail.id,
  99. }, res => {
  100. if(res.code == 200){
  101. this.$emit('loadData')
  102. uni.showToast({
  103. title: res.message
  104. })
  105. }
  106. })
  107. },
  108. },
  109. }
  110. </script>
  111. <style lang="scss" scoped>
  112. .controls {
  113. display: flex;
  114. &>view {
  115. display: flex;
  116. justify-content: center;
  117. align-items: center;
  118. margin-right: 40rpx;
  119. }
  120. .share{
  121. display: flex;
  122. justify-content: center;
  123. align-items: center;
  124. }
  125. .share::after{
  126. border: none;
  127. }
  128. }
  129. </style>