SetNode.vue 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390
  1. <template>
  2. <div>
  3. <el-dialog
  4. width="300px"
  5. v-model="dialoglog"
  6. :modal="false"
  7. :close-on-click-modal="false"
  8. :append-to-body="true"
  9. draggable
  10. :fullscreen="false"
  11. :modal-append-to-body="false"
  12. modal-class="summary-dlg"
  13. @close='closeDialog'
  14. class="right log_class bgcolor tianjia asideg asidegbg leftbgimg"
  15. >
  16. <template #header="{ titleId, titleClass }">
  17. <div class="my-header">
  18. <el-image :src="icon" fit="contain"></el-image>
  19. <h4 :id="titleId" :class="titleClass">{{ texttitle }}</h4>
  20. </div>
  21. </template>
  22. <div class="mgstamkuang">
  23. <ul>
  24. <li><span>节点编号:</span>{{msg.id}}</li>
  25. <li><span>名称:</span>{{msg.name}}</li>
  26. <li><span>X:</span>{{msg.x}}</li>
  27. <li><span>y:</span>{{msg.y}}</li>
  28. <li><span>Z:</span>{{msg.z}}</li>
  29. </ul>
  30. </div>
  31. <div class="dialog-footer footer_div l_btn">
  32. <div class="footerbtn flex1">
  33. <div class="borderimg">
  34. <el-button @click=" closeDialog();dialoglog = false">取消</el-button>
  35. </div>
  36. </div>
  37. <div class="footerbtn flex1">
  38. <div class="borderimg">
  39. <el-button @click="textclick(); dialoglog = false"> 确定 </el-button>
  40. </div>
  41. </div>
  42. </div>
  43. </el-dialog>
  44. </div>
  45. </template>
  46. <script setup>
  47. import { ref, onMounted, onBeforeUnmount,reactive,onUnmounted } from "vue";
  48. import { RouterView, RouterLink } from "vue-router";
  49. import { request, uploadFile } from "@/utils/request";
  50. import { ElMessage, ElButton, ElDialog, ElSelect } from "element-plus";
  51. import icon from "@/assets/img/icon.png";
  52. import { vtkmodel } from "@/control/vtkModel.js";
  53. let emit = defineEmits(['Dtext',])
  54. let dialoglog = ref(false);
  55. let texttitle = ref("节点信息");
  56. let msg=ref({
  57. id: '',
  58. name: "",
  59. x:"",
  60. y: '',
  61. z: '',
  62. })
  63. let state=ref();
  64. defineExpose({ dialoglog,jgSelect});
  65. let timing = ref(null);
  66. //管道节点选择对象
  67. let selectObj = ref(null);
  68. const textclick=()=>{
  69. emit('Dtext',selectObj.value);
  70. state.value=sessionStorage.getItem("state");
  71. if(state.value=='1'){
  72. vtkmodel.clearModeAddJg();
  73. }else{
  74. vtkmodel.selectNoting();
  75. }
  76. clearInterval(timing.value);
  77. }
  78. const closeDialog=()=>{
  79. state.value=sessionStorage.getItem("state");
  80. if(state.value=='1'){
  81. vtkmodel.clearModeAddJg();
  82. }else{
  83. vtkmodel.selectNoting();
  84. }
  85. clearInterval(timing.value);
  86. }
  87. onBeforeUnmount(() => {
  88. clearInterval(timing.value);
  89. });
  90. onMounted(() => {
  91. });
  92. onUnmounted(() => {
  93. clearInterval(timing.value);
  94. })
  95. //选择结果定时器
  96. function jgSelect(){
  97. timing.value = setInterval(() => {//定时器
  98. selectObj.value=vtkmodel.selectObj;
  99. if(selectObj.value==null){
  100. }else{
  101. msg.value=selectObj.value;
  102. }
  103. }, 200);
  104. }
  105. </script>
  106. <style lang="scss" scoped>
  107. .vtk {
  108. position: absolute;
  109. z-index: 150;
  110. top: 70px;
  111. }
  112. .jc_padding .el-table tr {
  113. height: 30px !important;
  114. background: rgba(104, 173, 255, 0.3);
  115. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  116. border-radius: 0px 0px 0px 0px;
  117. border: 1px solid;
  118. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  119. 1;
  120. }
  121. .flex_a {
  122. flex: 1;
  123. padding: 0 19px;
  124. }
  125. .btns {
  126. width: 72px;
  127. height: 30px;
  128. background-image: url(../../assets/img/Rectangle399.png);
  129. background-repeat: no-repeat;
  130. line-height: 30px;
  131. overflow: hidden;
  132. margin: 10px 0;
  133. .spantext {
  134. font-weight: bold;
  135. font-size: 12px;
  136. color: #ffffff;
  137. text-align: left;
  138. font-style: normal;
  139. text-transform: none;
  140. }
  141. }
  142. .header_z {
  143. box-shadow: none !important;
  144. padding: 10px 20px !important;
  145. }
  146. .header_l {
  147. line-height: 10px;
  148. text-align: left;
  149. padding: 0 20px;
  150. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  151. 1;
  152. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  153. border-radius: 0px 0px 0px 0px;
  154. .el-image {
  155. padding: 10px 10px 0 0;
  156. }
  157. h4 {
  158. font-weight: bold;
  159. font-size: 12px;
  160. color: #68adff;
  161. line-height: 14px;
  162. text-align: left;
  163. font-style: normal;
  164. text-transform: none;
  165. }
  166. }
  167. .jc_padding {
  168. padding: 18px 10px;
  169. }
  170. .line {
  171. border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  172. box-sizing: border-box;
  173. }
  174. .L_aside {
  175. .iconimg {
  176. width: 37px;
  177. height: 36px;
  178. margin: 0 7px 0 24px;
  179. }
  180. }
  181. .ddd {
  182. margin-top: 20px;
  183. .ddd_div {
  184. padding: 20px 0;
  185. position: relative;
  186. }
  187. .class_btn {
  188. position: absolute;
  189. right: 0;
  190. top: 21px;
  191. }
  192. .header_l {
  193. line-height: 10px;
  194. text-align: left;
  195. padding: 0 20px;
  196. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48))
  197. 1 1;
  198. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  199. border-radius: 0px 0px 0px 0px;
  200. .el-image {
  201. padding: 10px 10px 0 0;
  202. }
  203. h4 {
  204. font-weight: bold;
  205. font-size: 12px;
  206. color: #68adff;
  207. line-height: 14px;
  208. text-align: left;
  209. font-style: normal;
  210. text-transform: none;
  211. }
  212. }
  213. }
  214. .el-dialog__title {
  215. display: inline-block;
  216. }
  217. .bgcolor {
  218. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  219. border-radius: 0px 0px 0px 0px;
  220. border: 1px solid;
  221. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  222. 1;
  223. }
  224. .log_class {
  225. .my-header {
  226. line-height: 10px;
  227. height: 40px;
  228. text-align: left;
  229. padding: 0 20px;
  230. border-bottom: 1px solid;
  231. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48))
  232. 1 1;
  233. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  234. border-radius: 0px 0px 0px 0px;
  235. .el-image {
  236. padding: 0px 10px 0 0;
  237. }
  238. h4 {
  239. font-weight: bold;
  240. font-size: 12px;
  241. color: #68adff;
  242. line-height: 14px;
  243. text-align: left;
  244. font-style: normal;
  245. text-transform: none;
  246. margin-top: 8px;
  247. }
  248. }
  249. .my_content {
  250. width: 100%;
  251. height: 90px;
  252. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  253. border-radius: 0px 0px 0px 0px;
  254. position: relative;
  255. .radio-group {
  256. display: flex;
  257. justify-content: center;
  258. .el-radio {
  259. flex: 1;
  260. justify-content: center;
  261. font-weight: bold;
  262. font-size: 12px;
  263. color: #ffffff;
  264. line-height: 14px;
  265. }
  266. }
  267. }
  268. .el-dialog__footer {
  269. position: absolute;
  270. bottom: 17px;
  271. display: flex;
  272. .footerbtn {
  273. flex: 1;
  274. text-align: center;
  275. }
  276. }
  277. }
  278. .my_content1 {
  279. .el-table .cell {
  280. font-weight: 400;
  281. font-size: 12px;
  282. color: #ffffff !important;
  283. line-height: 14px;
  284. text-align: left;
  285. font-style: normal;
  286. text-transform: none;
  287. }
  288. }
  289. .l_btn .borderimg {
  290. width: 70px;
  291. height: 30px;
  292. font-size: 12px;
  293. background: rgba(104, 173, 255, 0.3);
  294. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  295. /* border: 1px solid rgba(31, 107, 255, 1); */
  296. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  297. 1;
  298. font-weight: bold;
  299. border-radius: 4px;
  300. display: flex;
  301. display: inline-block;
  302. box-sizing: border-box;
  303. }
  304. .borderimg {
  305. width: 109px;
  306. height: 30px;
  307. background: rgba(104, 173, 255, 0.3);
  308. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  309. /* border: 1px solid rgba(31, 107, 255, 1); */
  310. -o-border-image: linear-gradient(
  311. 180deg,
  312. rgba(31, 107, 255, 1),
  313. rgba(31, 107, 255, 0.48)
  314. )
  315. 1 1;
  316. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  317. 1;
  318. border-radius: 4px;
  319. display: flex;
  320. display: inline-block;
  321. box-sizing: border-box;
  322. }
  323. .el-table,
  324. .el-table thead th {
  325. background-color: rgba(13, 22, 57, 0.96) !important;
  326. }
  327. .el-form-item__label {
  328. color: #ffffff !important;
  329. }
  330. .jiancedian {
  331. width: 380px;
  332. position: absolute;
  333. right: 0;
  334. top: 70px;
  335. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  336. border-radius: 4px 4px 4px 4px;
  337. border: 1px solid;
  338. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1
  339. 1;
  340. }
  341. </style>
  342. <style>
  343. .log_class {
  344. background-color: rgba(13, 22, 57, 0.96) !important;
  345. }
  346. .right {
  347. right: 0px;
  348. position: absolute;
  349. top: -7vh;
  350. }
  351. </style>