index.vue 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260
  1. <template>
  2. <view class="page-content complaintsdetails">
  3. <view class="complaintsdetails-content">
  4. <view class="complaintsdetails-item complaintsdetails-plauser">
  5. <view class="item-content">
  6. <view class="item-text">
  7. <view class="item-textlable">
  8. <text class="item-lable">真实姓名:</text>
  9. </view>
  10. <view class="item-textvalue">
  11. <text class="item-value">{{ complaintsDetailsObj.plaUser }}</text>
  12. </view>
  13. </view>
  14. </view>
  15. </view>
  16. <view class="complaintsdetails-item complaintsdetails-plaphone">
  17. <view class="item-content">
  18. <view class="item-text">
  19. <view class="item-textlable">
  20. <text class="item-lable">手机号码:</text>
  21. </view>
  22. <view class="item-textvalue">
  23. <text
  24. class="item-value"
  25. >{{ complaintsDetailsObj.plaPhone ? complaintsDetailsObj.plaPhone.toString().replace(/^(.{3})(.*)(.{4})$/, '$1-$2-$3') : '' }}</text>
  26. </view>
  27. </view>
  28. </view>
  29. </view>
  30. <view class="complaintsdetails-item complaintsdetails-planame">
  31. <view class="item-content">
  32. <view class="item-text">
  33. <view class="item-textlable">
  34. <text class="item-lable">投诉标题:</text>
  35. </view>
  36. <view class="item-textvalue">
  37. <text class="item-value">{{ complaintsDetailsObj.plaName }}</text>
  38. </view>
  39. </view>
  40. </view>
  41. </view>
  42. <view class="complaintsdetails-placontent">
  43. <view class="placontent-text">
  44. <view class="placontent-textlable">
  45. <text class="placontent-lable">投诉内容:</text>
  46. </view>
  47. <view class="placontent-textvalue">
  48. <text class="placontent-textarea">{{ complaintsDetailsObj.plaContent }}</text>
  49. </view>
  50. </view>
  51. </view>
  52. <template v-if="complaintsDetailsObj.plaRes != null && complaintsDetailsObj.plaRes != ''">
  53. <view class="complaintsdetails-plares">
  54. <view class="plares-text">
  55. <view class="plares-textlable">
  56. <text class="plares-lable">反馈内容:</text>
  57. </view>
  58. <view class="plares-textvalue">
  59. <text class="plares-textarea">{{ complaintsDetailsObj.plaRes }}</text>
  60. </view>
  61. </view>
  62. </view>
  63. </template>
  64. <template v-else>
  65. <view class="complaintsdetails-plares">
  66. <view class="plares-text">
  67. <view class="plares-textlable">
  68. <text class="plares-lable">反馈内容:</text>
  69. </view>
  70. <view class="plares-textnovalue">
  71. <text class="plares-value">暂无</text>
  72. </view>
  73. </view>
  74. </view>
  75. </template>
  76. </view>
  77. </view>
  78. </template>
  79. <script>
  80. import {
  81. complaintsViewData
  82. } from '@/agrcloud-api/complaints';
  83. export default {
  84. name: 'complaintsdetails',
  85. data() {
  86. return {
  87. complaintsDetailsObj: {
  88. plaUser: '',
  89. plaPhone: null,
  90. plaName: '',
  91. plaContent: '',
  92. plaRes: ''
  93. },
  94. custLabelStyle: {
  95. 'height': '42rpx',
  96. 'font-size': '30rpx',
  97. 'font-family': 'PingFangSC-Regular, PingFang SC',
  98. 'font-weight': '400',
  99. 'color': '#666666',
  100. 'line-height': '42rpx'
  101. },
  102. custPlaceholderStyle: 'font-size: 34rpx;font-family: PingFangSC-Regular, PingFang SC;font-weight: 400;'
  103. };
  104. },
  105. onLoad() {
  106. this.initData();
  107. },
  108. methods: {
  109. /** 初始化数据 */
  110. initData() {
  111. const currComplaintsDetailsItem = (this.$store.getters || {}).complaintsDetailsObj || {};
  112. complaintsViewData({
  113. id: currComplaintsDetailsItem.plaId
  114. }).then(res => {
  115. this.complaintsDetailsObj = res.data || {};
  116. }).catch(() => {
  117. this.complaintsDetailsObj = {};
  118. });
  119. }
  120. }
  121. }
  122. </script>
  123. <style lang="scss" scoped>
  124. .complaintsdetails {
  125. padding: 0;
  126. .complaintsdetails-content {
  127. width: 100%;
  128. padding-top: 24rpx;
  129. .complaintsdetails-item {
  130. height: 138rpx;
  131. padding-left: 24rpx;
  132. background-color: #ffffff;
  133. .item-content {
  134. height: 138rpx;
  135. border-bottom: 1px solid #eeeeee;
  136. .item-text {
  137. padding: 24rpx 24rpx 24rpx 0;
  138. .item-textlable {
  139. height: 42rpx;
  140. line-height: 42rpx;
  141. .item-lable {
  142. height: 42rpx;
  143. font-size: 30rpx;
  144. font-family: PingFangSC-Regular, PingFang SC;
  145. font-weight: 400;
  146. color: #666666;
  147. line-height: 42rpx;
  148. }
  149. }
  150. .item-textvalue {
  151. height: 48rpx;
  152. line-height: 48rpx;
  153. .item-value {
  154. height: 48rpx;
  155. font-size: 34rpx;
  156. font-family: PingFangSC-Regular, PingFang SC;
  157. font-weight: 400;
  158. color: #333333;
  159. line-height: 48rpx;
  160. }
  161. }
  162. }
  163. }
  164. }
  165. .complaintsdetails-placontent {
  166. margin-top: 24rpx;
  167. background-color: #ffffff;
  168. min-height: 154rpx;
  169. .placontent-text {
  170. padding: 24rpx;
  171. .placontent-textlable {
  172. height: 42rpx;
  173. line-height: 42rpx;
  174. .placontent-lable {
  175. height: 42rpx;
  176. font-size: 30rpx;
  177. font-family: PingFangSC-Regular, PingFang SC;
  178. font-weight: 400;
  179. color: #666666;
  180. line-height: 42rpx;
  181. }
  182. }
  183. .placontent-textvalue {
  184. .placontent-textarea {
  185. min-height: 48rpx;
  186. font-size: 34rpx;
  187. font-family: PingFangSC-Regular, PingFang SC;
  188. font-weight: 400;
  189. color: #333333;
  190. }
  191. }
  192. }
  193. }
  194. .complaintsdetails-plares {
  195. margin-top: 24rpx;
  196. background-color: #ffffff;
  197. min-height: 154rpx;
  198. .plares-text {
  199. padding: 24rpx;
  200. .plares-textlable {
  201. height: 42rpx;
  202. line-height: 42rpx;
  203. .plares-lable {
  204. height: 42rpx;
  205. font-size: 30rpx;
  206. font-family: PingFangSC-Regular, PingFang SC;
  207. font-weight: 400;
  208. color: #666666;
  209. line-height: 42rpx;
  210. }
  211. }
  212. .plares-textvalue {
  213. .plares-textarea {
  214. min-height: 48rpx;
  215. font-size: 34rpx;
  216. font-family: PingFangSC-Regular, PingFang SC;
  217. font-weight: 400;
  218. color: #333333;
  219. }
  220. }
  221. .plares-textnovalue {
  222. height: 48rpx;
  223. line-height: 48rpx;
  224. .plares-value {
  225. height: 48rpx;
  226. font-size: 34rpx;
  227. font-family: PingFangSC-Regular, PingFang SC;
  228. font-weight: 400;
  229. color: #333333;
  230. line-height: 48rpx;
  231. }
  232. }
  233. }
  234. }
  235. }
  236. }
  237. </style>