shareStation.vue 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311
  1. <template>
  2. <div class="main-data data-share-station">
  3. <!-- <div class="title-area">共享驿站</div> -->
  4. <div class="content-area">
  5. <div class="content-left">
  6. <div class="content-title">
  7. <div class="title">建设完成达标率</div>
  8. </div>
  9. <div class="content">
  10. <div class="data-content">
  11. <div class="data-left">
  12. <div class="data-item">
  13. <div class="data-fir">
  14. <img src="@/assets/images/service_new/img_1.png" class="icon" />
  15. <div class="name">{{constructionQuantityNum.name}}</div>
  16. </div>
  17. <div class="data-snd">
  18. <div class="num">{{constructionQuantityNum.value}}</div>
  19. <div class="unit">个</div>
  20. </div>
  21. </div>
  22. <div class="data-item">
  23. <div class="data-fir">
  24. <img src="@/assets/images/service_new/img_2.png" class="icon" />
  25. <div class="name">{{completedNum.name}}</div>
  26. </div>
  27. <div class="data-snd">
  28. <div class="num">{{completedNum.value}}</div>
  29. <div class="unit">个</div>
  30. </div>
  31. </div>
  32. </div>
  33. <div class="data-right">
  34. <div class="circle">
  35. <div class="value">
  36. <div>{{parseFloat(participateProportionRate.value).toFixed(0)}}</div>
  37. <div class="unit">%</div>
  38. </div>
  39. <div class="revo">
  40. <div class="name">完成</div>
  41. <div class="name">达标率</div>
  42. </div>
  43. </div>
  44. </div>
  45. </div>
  46. </div>
  47. </div>
  48. <div class="content-right">
  49. <div class="content-title">
  50. <div class="title">服务内容</div>
  51. </div>
  52. <div class="content">
  53. <!-- <pie-chart
  54. :chart-data="pieData"
  55. :legend="pieLegend"
  56. :title="pieTitle"
  57. width="220px"
  58. height="180px"
  59. /> -->
  60. <div class="data-content">
  61. <div class="imgPos">
  62. <img src="@/assets/images/service_new/helath_self.png">
  63. </div>
  64. <div class="imgPos">
  65. <img src="@/assets/images/service_new/remote_consultation.png">
  66. </div>
  67. </div>
  68. </div>
  69. </div>
  70. </div>
  71. </div>
  72. </template>
  73. <script>
  74. import {getOverviewData, getToolsChartsList} from "@/api/screen/service";
  75. import PieChart from "@/components/Echarts/PieChart.vue";
  76. export default {
  77. name: "ShareStation",
  78. components: {PieChart},
  79. props: {
  80. appOrg: {
  81. type: String,
  82. default: "0000",
  83. },
  84. },
  85. watch:{
  86. appOrg(newValue,oldValue){
  87. //建设完成率
  88. this.getOverviewData();
  89. //工具箱二具数量
  90. this.getToolsChartsList();
  91. },
  92. },
  93. data() {
  94. return {
  95. pieData: [],
  96. pieLegend: {
  97. top: 50,
  98. orient: "vertical",
  99. right: 0,
  100. itemWidth: 8, // 设置图例标记的宽度
  101. itemHeight: 8, // 设置图例标记的高度
  102. textStyle: {
  103. color: "#FFF",
  104. },
  105. },
  106. pieTitle: {},
  107. constructionQuantityNum: {},
  108. completedNum: {},
  109. participateProportionRate: {
  110. value:0
  111. },
  112. };
  113. },
  114. created() {
  115. //建设完成率
  116. this.getOverviewData();
  117. //工具箱二具数量
  118. this.getToolsChartsList();
  119. },
  120. destroyed() {},
  121. beforeDestroy() {},
  122. mounted() {},
  123. methods: {
  124. //建设完成率
  125. getOverviewData() {
  126. getOverviewData(this.$props.appOrg).then((res) => {
  127. if (Number(res.code) === 200) {
  128. this.constructionQuantityNum = res.data.constructionQuantityNum;
  129. this.completedNum = res.data.completedNum;
  130. this.participateProportionRate = res.data.participateProportionRate;
  131. }
  132. });
  133. },
  134. //工具箱二具数量
  135. getToolsChartsList() {
  136. getToolsChartsList(this.$props.appOrg).then((res) => {
  137. if (Number(res.code) === 200) {
  138. this.pieData = res.data;
  139. }
  140. });
  141. },
  142. },
  143. };
  144. </script>
  145. <style lang="scss">
  146. .data-share-station {
  147. overflow: hidden;
  148. .content-area {
  149. display: flex;
  150. flex-direction: row;
  151. align-items: flex-start;
  152. justify-content: space-between;
  153. padding: 15px 20px 0 15px;
  154. .content-left, .content-right{
  155. width:calc(50% - 20px);
  156. }
  157. }
  158. .content-title {
  159. width: 230px;
  160. height: 26px;
  161. background: url("../../../assets/images/main/title_pro.png") no-repeat;
  162. background-size: 100% 100%;
  163. font-family: "PingFangSC";
  164. font-size: 16px;
  165. font-weight: bold;
  166. color: #00ffff;
  167. padding-left: 25px;
  168. .title {
  169. display: block;
  170. position: relative;
  171. top:-5px;
  172. }
  173. }
  174. .content {
  175. margin-top: 20px;
  176. .data-content{
  177. display: flex;
  178. justify-content: space-between;
  179. // padding-top:10px;
  180. .mar{
  181. margin-bottom: 15px;
  182. }
  183. .data-left{
  184. width: auto;
  185. .data-item{
  186. width:auto;
  187. margin-bottom: 23px;
  188. .data-fir{
  189. display: flex;
  190. align-items: center;
  191. .icon{
  192. width: 15px;
  193. height: 15px;
  194. margin-right: 6px;
  195. }
  196. .name{
  197. font-size: 14px;
  198. color:#FFFFFF;
  199. }
  200. }
  201. .data-snd{
  202. display: flex;
  203. align-items: center;
  204. padding-top:2px;
  205. .num{
  206. font-size: 32px;
  207. color:#00FFFF;
  208. font-family: 'electronicFont';
  209. }
  210. .unit{
  211. font-size:12px;
  212. color:#00FFFF;
  213. font-weight: 500;
  214. position: relative;
  215. top:5px;
  216. left:2px;
  217. }
  218. }
  219. }
  220. }
  221. .data-right{
  222. display: flex;
  223. flex-direction: column;
  224. align-items: center;
  225. margin-top: -50px;
  226. .name{
  227. font-size:13px;
  228. color:#fff;
  229. }
  230. .circle{
  231. width: 100px;
  232. height:100px;
  233. background: url("../../../assets/images/service_new/circle_2.png") no-repeat;
  234. background-size: 100% 100%;
  235. display: flex;
  236. justify-content: space-around;
  237. align-items:center;
  238. flex-direction: column;
  239. .revo{
  240. display: flex;
  241. flex-direction: column;
  242. align-items: center;
  243. }
  244. .value{
  245. display: flex;
  246. align-items: center;
  247. font-size: 32px;
  248. color:#00FFFF;
  249. font-family: 'electronicFont';
  250. position: relative;
  251. top:15px;
  252. }
  253. .unit{
  254. font-size:12px;
  255. color:#00FFFF;
  256. font-weight: 500;
  257. position: relative;
  258. top:5px;
  259. left:2px;
  260. }
  261. }
  262. }
  263. }
  264. }
  265. .data-content{
  266. display: flex;
  267. justify-content:space-around;
  268. align-items: center;
  269. overflow: visible;
  270. padding:10px 0px 0px 0px;
  271. margin-left: 10px;
  272. .imgPos{
  273. padding-left: 15px;
  274. padding-right: 15px;
  275. }
  276. }
  277. ::-webkit-scrollbar {
  278. width: 3px;
  279. height: 3px;
  280. }
  281. ::-webkit-scrollbar-thumb {
  282. //滑块部分
  283. // border-radius: 5px;
  284. background-color: #58cbbb;
  285. }
  286. ::-webkit-scrollbar-track {
  287. //轨道部分
  288. // box-shadow: inset 0 0 5px #ddd;
  289. background: #ddd;
  290. // border-radius: 5px;
  291. }
  292. }
  293. </style>