mySalary.vue 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260
  1. <template>
  2. <view class="content">
  3. <view class="top"></view>
  4. <view class="main">
  5. <view class="main-title flex">
  6. <view class="title-font">发放时间</view>
  7. <view class="title-font">实际发放</view>
  8. </view>
  9. <view class=" " v-for="(item,index) in list" :key="index">
  10. <view class="main-list flex" @click="more(item)">
  11. <view class="list-left">{{item.time}}</view>
  12. <view class="list-right">
  13. <view class="list-font red">
  14. ¥{{item.all}}
  15. </view>
  16. <image class="jt" v-if="item.more == 0" src="../../static/icon/downxia.png" mode=""></image>
  17. <image class="jt" v-if="item.more == 1" src="../../static/icon/downup.png" mode=""></image>
  18. </view>
  19. </view>
  20. <view class="child-list" v-if="item.more == 1">
  21. <view class="child-item">
  22. <view class="list-left">工资金额</view>
  23. <view class="list-right">
  24. <view class="list-font">
  25. ¥{{item.all}}
  26. </view>
  27. </view>
  28. </view>
  29. <view class="child-item">
  30. <view class="list-left">基本工资</view>
  31. <view class="list-right">
  32. <view class="list-font">
  33. ¥{{item.base}}
  34. </view>
  35. </view>
  36. </view>
  37. <view class="child-item" @click="navTo('/pages/salary/infoSalary?type=1')">
  38. <view class="list-left">扣款</view>
  39. <view class="list-right">
  40. <view class="list-font">
  41. ¥{{item.deduct}}
  42. </view>
  43. <image class="jtr" src="../../static/img/jt.png" mode=""></image>
  44. </view>
  45. </view>
  46. <view class="child-item" @click="navTo('/pages/salary/infoSalary?type=2')">
  47. <view class="list-left">奖励</view>
  48. <view class="list-right">
  49. <view class="list-font">
  50. ¥{{item.award}}
  51. </view>
  52. <image class="jtr" src="../../static/img/jt.png" mode=""></image>
  53. </view>
  54. </view>
  55. <view class="child-item" @click="navTo('/pages/salary/infoSalary?type=3')">
  56. <view class="list-left">其他</view>
  57. <view class="list-right">
  58. <view class="list-font">
  59. ¥{{item.other}}
  60. </view>
  61. <image class="jtr" src="../../static/img/jt.png" mode=""></image>
  62. </view>
  63. </view>
  64. </view>
  65. </view>
  66. </view>
  67. </view>
  68. </template>
  69. <script>
  70. export default {
  71. data() {
  72. return {
  73. list: [{
  74. time: '2022年11月15日',
  75. all: 5000,
  76. more: 0,
  77. base: 3000,
  78. deduct: 500,
  79. award: 500,
  80. other: 500
  81. },
  82. {
  83. time: '2022年11月15日',
  84. all: 5000,
  85. more: 0,
  86. base: 3000,
  87. deduct: 500,
  88. award: 500,
  89. other: 500
  90. },
  91. {
  92. time: '2022年11月15日',
  93. all: 5000,
  94. more: 0,
  95. base: 3000,
  96. deduct: 500,
  97. award: 500,
  98. other: 500
  99. },
  100. {
  101. time: '2022年11月15日',
  102. all: 5000,
  103. more: 0,
  104. base: 3000,
  105. deduct: 500,
  106. award: 500,
  107. other: 500
  108. },
  109. {
  110. time: '2022年11月15日',
  111. all: 5000,
  112. more: 0,
  113. base: 3000,
  114. deduct: 500,
  115. award: 500,
  116. other: 500
  117. },
  118. {
  119. time: '2022年11月15日',
  120. all: 5000,
  121. more: 0,
  122. base: 3000,
  123. deduct: 500,
  124. award: 500,
  125. other: 500
  126. },
  127. {
  128. time: '2022年11月15日',
  129. all: 5000,
  130. more: 0,
  131. base: 3000,
  132. deduct: 500,
  133. award: 500,
  134. other: 500
  135. },
  136. {
  137. time: '2022年11月15日',
  138. all: 5000,
  139. more: 0,
  140. base: 3000,
  141. deduct: 500,
  142. award: 500,
  143. other: 500
  144. },
  145. {
  146. time: '2022年11月15日',
  147. all: 5000,
  148. more: 0,
  149. base: 3000,
  150. deduct: 500,
  151. award: 500,
  152. other: 500
  153. }
  154. ]
  155. };
  156. },
  157. onLoad() {},
  158. onShow() {},
  159. onReachBottom() {},
  160. onReady() {},
  161. methods: {
  162. more(item) {
  163. if (item.more == 0) {
  164. item.more = 1
  165. } else {
  166. item.more = 0
  167. }
  168. },
  169. navTo(url) {
  170. uni.navigateTo({
  171. url
  172. })
  173. }
  174. }
  175. };
  176. </script>
  177. <style lang="scss">
  178. page,
  179. .content {
  180. min-height: 100%;
  181. height: auto;
  182. background: #ffffff;
  183. }
  184. .top {
  185. height: 20rpx;
  186. width: 750rpx;
  187. background: #f8f8f8;
  188. }
  189. .main {
  190. padding-bottom: 50rpx;
  191. .main-title {
  192. padding: 32rpx 34rpx 28rpx 28rpx;
  193. border-bottom: 1px solid #F2F2F2;
  194. .title-font {
  195. font-size: 30rpx;
  196. font-family: PingFang SC;
  197. font-weight: bold;
  198. color: #000000;
  199. }
  200. }
  201. .child-list {
  202. background: #f8f8f8;
  203. padding: 0 34rpx 0 28rpx;
  204. }
  205. .child-item {
  206. display: flex;
  207. justify-content: space-between;
  208. align-items: center;
  209. padding: 32rpx 0 28rpx 0;
  210. border-bottom: 1px solid #f2f2f2;
  211. }
  212. .main-list {
  213. padding: 32rpx 34rpx 28rpx 28rpx;
  214. }
  215. .list-left {
  216. font-size: 28rpx;
  217. font-family: PingFang SC;
  218. font-weight: bold;
  219. color: #000000;
  220. }
  221. .list-right {
  222. display: flex;
  223. justify-content: flex-end;
  224. align-items: center;
  225. .list-font {
  226. font-size: 32rpx;
  227. font-family: PingFang SC;
  228. font-weight: bold;
  229. color: #333333;
  230. margin-right: 10rpx;
  231. }
  232. .red {
  233. color: #FF4C4C;
  234. }
  235. .jt {
  236. width: 19rpx;
  237. height: 11rpx;
  238. }
  239. .jtr {
  240. width: 11rpx;
  241. height: 19rpx;
  242. }
  243. }
  244. }
  245. </style>