monitorLiveList.vue 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. <template>
  2. <div class="main-data data-week-foods">
  3. <div class="title-area">实时监控</div>
  4. <!-- 选择日期 -->
  5. <div class="close-btn" @click="close"></div>
  6. <div class="content-area">
  7. <div class="content">
  8. <div class="monitor-cont">
  9. <div class="monitor-list" v-for="(item,index) in monitorList" :key="index" @click="chooseItem(index)">
  10. <img src="@/assets/images/building_guarantee/img_12.png" class="img" />
  11. <div class="monitor-info">
  12. <div class="name">{{item.cameraName}}</div>
  13. </div>
  14. </div>
  15. </div>
  16. </div>
  17. </div>
  18. </div>
  19. </template>
  20. <script>
  21. import {getCameraList} from "@/api/screen/service";
  22. export default {
  23. name: "MonitorLiveList",
  24. props: {
  25. monitorName:{
  26. type: String,
  27. default: "",
  28. required: true,
  29. },
  30. curCompanMonth:{
  31. type: Number,
  32. default: "",
  33. }
  34. },
  35. data() {
  36. return {
  37. monitorList: [],
  38. };
  39. },
  40. created() {
  41. this.getCameraList();
  42. },
  43. destroyed() {},
  44. beforeDestroy() {},
  45. mounted() {},
  46. methods: {
  47. //统一视频(工程现场监控)
  48. // videoList() {
  49. // let code = "";
  50. // videoList(code).then((res) => {
  51. // if (Number(res.code) === 200) {
  52. // this.monitorList = res.data
  53. // }
  54. // });
  55. // },
  56. getCameraList(){
  57. getCameraList(this.$props.curCompanMonth).then((res) => {
  58. if (Number(res.code) === 200) {
  59. this.monitorList = res.data;
  60. }
  61. });
  62. },
  63. close(){
  64. this.$emit("closeMonitor")
  65. },
  66. //选择单个摄像头
  67. chooseItem(index){
  68. this.$emit("chooseMonitor", this.monitorList[index]);
  69. }
  70. },
  71. };
  72. </script>
  73. <style lang="scss">
  74. .el-scrollbar{
  75. background: #15696B;
  76. border: 1px solid #00ffff;
  77. ul{
  78. li{
  79. color: #FFF;
  80. }
  81. }
  82. }
  83. .el-select-dropdown__item.hover, .el-select-dropdown__item:hover{
  84. background: #15696B;
  85. color: #00FFFF;
  86. }
  87. .el-select-dropdown__item.selected{
  88. color: #00FFFF;
  89. }
  90. .el-select .el-input .el-select__caret{
  91. display: none;
  92. }
  93. .data-week-foods {
  94. position: relative;
  95. width: 890px;
  96. height: 576px;
  97. background: url("../../../assets/images/main/dialog-bg.png") no-repeat;
  98. background-size: cover;
  99. .close-btn{
  100. position: absolute;
  101. right: 0;
  102. top: 0;
  103. width: 50px;
  104. height: 50px;
  105. cursor: pointer;
  106. }
  107. .choose-area{
  108. position: absolute;
  109. right: 100px;
  110. top: 7px;
  111. width: 80.05px;
  112. height: 30px;
  113. line-height: 30px;
  114. padding-left: 15px;
  115. font-size: 14px;
  116. color: #00FFFF;
  117. background: url("../../../assets/images/main/choose_short.png") no-repeat;
  118. cursor: pointer;
  119. }
  120. .content-area {
  121. display: flex;
  122. flex-direction: column;
  123. padding: 15px 20px 0 15px;
  124. }
  125. .content-title {
  126. width: 515px;
  127. height: 26px;
  128. background: url("../../../assets/images/main/title_pro_long.png") no-repeat;
  129. background-size: 100% 100%;
  130. font-family: PingFang SC;
  131. font-size: 16px;
  132. font-weight: bold;
  133. color: #00ffff;
  134. padding-left: 17px;
  135. .title {
  136. display: block;
  137. }
  138. }
  139. .content {
  140. width: 100%;
  141. display: flex;
  142. flex-direction: row;
  143. align-items: center;
  144. .data-list {
  145. background: radial-gradient(190% 71% at 50% 49%, rgba(21, 105, 107, 0.54) 0%, rgba(27, 95, 97, 0) 100%);
  146. width: 100%;
  147. height: 492px;
  148. padding: 20px;
  149. overflow: auto;
  150. white-space: pre-wrap;
  151. .data-item {
  152. display: inline-block;
  153. color: #00FFFF;
  154. font-weight: bold;
  155. margin: 0 40px 28px 0;
  156. font-size: 14px;
  157. }
  158. }
  159. }
  160. .title-format {
  161. display: flex;
  162. flex-direction: row;
  163. align-items: center;
  164. img {
  165. width: 6px;
  166. height: 24px;
  167. margin-right: 6px;
  168. }
  169. .title-info {
  170. display: flex;
  171. flex-direction: column;
  172. font-size: 12px;
  173. color: #ffffff;
  174. .title-en {
  175. font-size: 8px;
  176. color: #ffffff;
  177. opacity: 0.4;
  178. }
  179. }
  180. }
  181. .choose-area{
  182. .el-select{
  183. width: 50%;
  184. }
  185. .el-input{
  186. input{
  187. background: rgba(255, 255, 255, 0);
  188. color: #00FFFF;
  189. border: none;
  190. padding: 0;
  191. width: 30px;
  192. }
  193. }
  194. }
  195. .monitor-cont{
  196. width:100%;
  197. display: flex;
  198. flex-wrap: wrap;
  199. padding:0 15px 20px;
  200. background: url("../../../assets/images/main/data_bg6.png") no-repeat;
  201. background-size: 100% 100%;
  202. .monitor-list{
  203. width:151px;
  204. position: relative;
  205. margin:0 10px 10px 0;
  206. cursor: pointer;
  207. .img{
  208. display: block;
  209. width:151px;
  210. height:104px;
  211. }
  212. .monitor-info{
  213. position: absolute;
  214. left:0;
  215. bottom: 0;
  216. width: 100%;
  217. height: 25px;
  218. opacity: 0.55;
  219. background: #000000;
  220. display: flex;
  221. justify-content: space-between;
  222. align-items: center;
  223. padding: 0 8px;
  224. .name{
  225. font-size: 13px;
  226. color: #FFFFFF;
  227. font-weight: 500;
  228. }
  229. .online{
  230. font-size: 12px;
  231. color: #00F6EC;
  232. font-weight: 500;
  233. }
  234. .offline{
  235. font-size: 12px;
  236. color: #F60000;
  237. font-weight: 500;
  238. }
  239. }
  240. }
  241. .monitor-list:nth-child(5n){
  242. margin-right: 0;
  243. }
  244. }
  245. .title-area{
  246. padding-left: 40px !important;
  247. }
  248. ::-webkit-scrollbar {
  249. width: 3px;
  250. height: 3px;
  251. }
  252. ::-webkit-scrollbar-thumb {
  253. //滑块部分
  254. // border-radius: 5px;
  255. background-color: #58cbbb;
  256. }
  257. ::-webkit-scrollbar-track {
  258. //轨道部分
  259. // box-shadow: inset 0 0 5px #ddd;
  260. background: #ddd;
  261. // border-radius: 5px;
  262. }
  263. }
  264. </style>