index.vue 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307
  1. <template>
  2. <view class="page" :style="{'padding-top':mt+'px'}">
  3. <c-nav-bar title="统计" :showIcon="false"></c-nav-bar>
  4. <view class="hander">
  5. <!-- 2024年1月 -->
  6. <view
  7. class="tn-flex tn-flex-col-center justify-content-item tn-margin-right tn-padding-xs tn-text-sm tn-bg-gray--light tn-radius tn-color-gray--dark"
  8. style="border-radius: 12rpx;">
  9. <picker @change="bindDateChange" mode="date" :value="date" :start="startDate" :end="endDate"
  10. fields="month">
  11. <text class="tn-padding-left-xs tn-padding-right-xs">{{date}}</text>
  12. </picker>
  13. </view>
  14. </view>
  15. <view class="hander-price">
  16. <view class="one">
  17. <view class="left">
  18. 总营业额
  19. </view>
  20. <view class="right">
  21. 共124笔
  22. </view>
  23. </view>
  24. <view class="two">
  25. <text>¥</text>
  26. <text>15424.00</text>
  27. </view>
  28. </view>
  29. <view class="echarts-one">
  30. <view class="title">
  31. 营业概况
  32. </view>
  33. <view class="hander-content">
  34. <view class="list">
  35. <view class="title">
  36. 房费
  37. </view>
  38. <view class="price">
  39. {{}}¥21964.00
  40. </view>
  41. </view>
  42. <view class="list">
  43. <view class="title">
  44. 商品
  45. </view>
  46. <view class="price">
  47. {{}}¥6514.00
  48. </view>
  49. </view>
  50. <view class="list">
  51. <view class="title">
  52. 其他
  53. </view>
  54. <view class="price">
  55. {{}}¥2514.00
  56. </view>
  57. </view>
  58. </view>
  59. <view class="Pie_charts">
  60. <PieCharts></PieCharts>
  61. </view>
  62. </view>
  63. <view class="echarts-two">
  64. <view class="title">
  65. 交易趋势
  66. </view>
  67. <view class="title1">
  68. 单位:元
  69. </view>
  70. <view class="line_charts_one">
  71. <LineOne />
  72. </view>
  73. </view>
  74. <view class="echarts-three">
  75. <view>
  76. <view class="title">
  77. 入住率
  78. </view>
  79. <view class="title1">
  80. 入住率(%)
  81. </view>
  82. </view>
  83. <view class="line_charts_two">
  84. <LineTwo />
  85. </view>
  86. </view>
  87. <Tabbar :tabbarIndex="2"></Tabbar>
  88. </view>
  89. </template>
  90. <script>
  91. // import uCharts from '@/utils/u-charts.js';
  92. import PieCharts from "@/components/Charts/PieCharts.vue"
  93. import LineOne from "@/components/Charts/LineOne.vue"
  94. import LineTwo from "@/components/Charts/LineTwo.vue"
  95. export default {
  96. components: {
  97. PieCharts,
  98. LineOne,
  99. LineTwo
  100. },
  101. data() {
  102. return {
  103. h: uni.getSystemInfoSync().windowHeight,
  104. mt: uni.getSystemInfoSync().statusBarHeight + 54,
  105. date: '2023-07',
  106. }
  107. },
  108. onReady() {},
  109. methods: {
  110. bindDateChange(e) {
  111. this.date = e.detail.value
  112. },
  113. // 时间
  114. startDate() {
  115. return this.getDate('start');
  116. },
  117. endDate() {
  118. return this.getDate('end');
  119. },
  120. }
  121. };
  122. </script>
  123. <style scoped lang="less">
  124. // .charts {
  125. // width: 700rpx;
  126. // height: 630rpx;
  127. // }
  128. .charts-box {
  129. width: 100%;
  130. height: 630rpx;
  131. }
  132. .page {
  133. background: #F3F4F4;
  134. padding-bottom: 40rpx;
  135. box-sizing: border-box;
  136. // overflow-y: auto;
  137. padding: 20rpx 30rpx;
  138. // height: 100%;
  139. }
  140. .hander {
  141. height: 48rpx;
  142. width: 216rpx;
  143. border-radius: 8rpx;
  144. background-color: #fff;
  145. text-align: center;
  146. line-height: 48rpx;
  147. }
  148. .hander-price {
  149. margin-top: 20rpx;
  150. width: 100%;
  151. height: 192rpx;
  152. padding: 30rpx;
  153. box-sizing: border-box;
  154. border-radius: 10rpx;
  155. background-color: #fff;
  156. .one {
  157. display: flex;
  158. justify-content: space-between;
  159. .left {
  160. font-size: 32rpx;
  161. color: #333333;
  162. font-weight: Heavy;
  163. font-family: PingFang SC-Heavy;
  164. }
  165. .right {
  166. font-size: 24rpx;
  167. color: #333333;
  168. font-weight: Regular;
  169. font-family: PingFang SC-Regular;
  170. }
  171. }
  172. .two {
  173. margin-top: 20rpx;
  174. font-size: 48rpx;
  175. color: #1372FF;
  176. font-weight: Heavy;
  177. font-family: PingFang SC-Heavy;
  178. }
  179. }
  180. .echarts-one {
  181. box-sizing: border-box;
  182. width: 100%;
  183. height: 829rpx;
  184. background-color: #fff;
  185. margin: 20rpx 0;
  186. border-radius: 10rpx;
  187. padding: 30rpx;
  188. .title {
  189. font-size: 32rpx;
  190. color: #333333;
  191. font-weight: Heavy;
  192. font-family: PingFang SC-Heavy;
  193. }
  194. .hander-content {
  195. margin-top: 40rpx;
  196. display: flex;
  197. justify-content: space-between;
  198. height: 110rpx;
  199. .title {
  200. font-size: 28rpx;
  201. color: #777777;
  202. font-weight: Regular;
  203. font-family: PingFang SC-Regular;
  204. }
  205. .price {
  206. margin-top: 10rpx;
  207. font-size: 28rpx;
  208. color: #333;
  209. font-weight: Bold;
  210. font-family: PingFang SC-Bold;
  211. }
  212. }
  213. .Pie_charts {
  214. height: 95%;
  215. width: 100%;
  216. // background-color: aqua;
  217. }
  218. }
  219. .echarts-two {
  220. box-sizing: border-box;
  221. width: 100%;
  222. height: 543rpx;
  223. background-color: #fff;
  224. margin: 20rpx 0;
  225. border-radius: 10rpx;
  226. padding: 30rpx;
  227. .title {
  228. font-size: 32rpx;
  229. color: #333333;
  230. font-weight: Heavy;
  231. font-family: PingFang SC-Heavy;
  232. }
  233. .title1 {
  234. margin-left: 20rpx;
  235. margin-top: 20rpx;
  236. font-size: 20rpx;
  237. color: #333333;
  238. font-weight: Regular;
  239. font-family: PingFang SC-Regular;
  240. }
  241. .line_charts_one {
  242. height: 95%;
  243. width: 100%;
  244. // background-color: aqua;
  245. }
  246. }
  247. .echarts-three {
  248. box-sizing: border-box;
  249. width: 100%;
  250. height: 540rpx;
  251. background-color: #fff;
  252. margin: 20rpx 0;
  253. border-radius: 10rpx;
  254. padding: 30rpx;
  255. .title {
  256. font-size: 32rpx;
  257. color: #333333;
  258. font-weight: Heavy;
  259. font-family: PingFang SC-Heavy;
  260. }
  261. .title1 {
  262. margin-left: 20rpx;
  263. margin-top: 20rpx;
  264. font-size: 20rpx;
  265. color: #333333;
  266. font-weight: Regular;
  267. font-family: PingFang SC-Regular;
  268. }
  269. .line_charts_two {
  270. height: 95%;
  271. width: 100%;
  272. // background-color: aqua;
  273. }
  274. }
  275. </style>