PipeIine.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443
  1. <template>
  2. <div >
  3. <el-dialog
  4. v-model="dialogVisiblenode"
  5. width="700"
  6. class="log_class bgcolor tianjia asideg asidegbg leftbgimg"
  7. >
  8. <template #header="{titleId, titleClass }">
  9. <div class="my-header ">
  10. <el-image :src="icon" fit="contain" ></el-image>
  11. <h4 :id="titleId" :class="titleClass"> 选择巷道</h4>
  12. </div>
  13. </template>
  14. <div class="demo-input-suffix firsttitle leftbgimg2 my_content1">
  15. <div class="guand_1">
  16. <el-form-item label="节点选择" :label-width="formLabelWidth5">
  17. <el-input v-model="searchtaggd"
  18. class="w-50 m-2"
  19. placeholder="巷道"
  20. />
  21. </el-form-item>
  22. <div class="asdis_btn">
  23. <div class="flex_a"><div class="btns" @click="searchgd"><span class="spantext">搜索</span></div></div>
  24. </div>
  25. </div>
  26. <el-table
  27. :row-class-name="tableRowClassName"
  28. :max-height="tableHeight"
  29. ref="multipleTableRef"
  30. :data="tableData2"
  31. style="width: 100%"
  32. @select="projectsSelectionSelect"
  33. :header-cell-style="{'background':'rgba(13, 22, 57, 0.96) '}"
  34. >
  35. <el-table-column type="selection" width="55" />
  36. <el-table-column property="snId" label="开始节点"/>
  37. <el-table-column property="enId" label="结束节点"/>
  38. <el-table-column property="id" label="编号" width="70"/>
  39. <el-table-column property="name" label="名称" width="70"/>
  40. <el-table-column property="sectionType" label="截面类型" width="120"/>
  41. <el-table-column property="roughCoe" label="粗糙系数"/>
  42. <el-table-column property="sectionPara1" label="截面参数1" width="90"/>
  43. <el-table-column property="sectionPara2" label="截面参数2" width="90" />
  44. <el-table-column property="sectionPara3" label="截面参数3" width="90"/>
  45. <el-table-column property="sectionPara4" label="截面参数4" width="90"/>
  46. <el-table-column property="sectionPara5" label="截面参数5" width="90"/>
  47. </el-table>
  48. <div class="demo-pagination-block" style="margin-top: 20px;">
  49. <el-pagination
  50. v-model:current-page="currentPage4"
  51. v-model:page-size="pageSize4"
  52. small
  53. background
  54. layout="prev, total,pager, next, jumpe,"
  55. :total="parseInt(total)"
  56. class="mt-4"
  57. @current-change="handleCurrentChange"
  58. />
  59. </div>
  60. <div class="dialog-footer footer_div l_btn">
  61. <div class="footerbtn flex1"><div class="borderimg"><el-button @click="dialogVisiblenode = false">取消</el-button></div></div>
  62. <div class="footerbtn flex1"><div class="borderimg"><el-button @click="queding();dialogVisiblenode = false">
  63. 确定
  64. </el-button></div></div>
  65. </div>
  66. </div>
  67. </el-dialog>
  68. </div>
  69. </template>
  70. <script setup>
  71. import { ref, onMounted, reactive, } from "vue";
  72. import {RouterView,RouterLink } from "vue-router"
  73. import { request, uploadFile } from "@/utils/request";
  74. import { ElMessage, ElButton, ElDialog, ElSelect } from 'element-plus'
  75. import icon from "@/assets/img/icon.png";
  76. const props= defineProps({ });
  77. let emit = defineEmits(['pipelineapi'])
  78. let sdialog=ref({
  79. dianadddialog:false,
  80. })
  81. let formLabelWidth5=ref(99)
  82. let tableHeight=ref(500);
  83. let tableData2 =ref([]);
  84. const multipleTableRef = ref()
  85. const multipleSelection = ref([])
  86. let dialogVisiblenode=ref(false);
  87. let total = ref(1);
  88. let searchtaggd = ref("");
  89. let searchtag=ref("");
  90. const currentPage4 = ref(1);
  91. const pageSize4 = ref(5)
  92. onMounted(()=>{
  93. })
  94. // 巷道方法
  95. // 选择巷道
  96. const fireclick = () => {
  97. pipelinedata('');
  98. }
  99. const tableRowClassName = ({ row, rowIndex }) => {
  100. if (rowIndex % 2 != 0) {
  101. return 'evenRow';
  102. }
  103. return 'oddRow';
  104. }
  105. // 管道搜索
  106. function searchgd() {
  107. searchtag.value=searchtaggd.value;
  108. pipelinedata( searchtaggd.value);
  109. }
  110. // 管道分页查询
  111. const handleCurrentChange = (val) => {
  112. pipelinedata()
  113. }
  114. //管道数据查询
  115. const pipelinedata = (searchtag) => {
  116. const params = {
  117. transCode: 'D00001',
  118. count: pageSize4.value,
  119. page: currentPage4.value,
  120. searchtag: searchtag,
  121. }
  122. request(params)
  123. .then((res) => {
  124. tableData2.value = res.rows;
  125. total.value = res.total;
  126. })
  127. .catch((err) => {
  128. ElMessage.error(err.returnMsg)
  129. })
  130. }
  131. //选中项
  132. const projectsSelectionSelect=(selection, row)=>{
  133. if(selection.length>1){
  134. multipleTableRef.value.clearSelection();
  135. multipleTableRef.value.toggleRowSelection(row,true);
  136. multipleSelection.value=selection[1];
  137. return;
  138. }
  139. if(selection.length==1){
  140. multipleSelection.value=selection;
  141. }else if(selection.length==0){
  142. }
  143. }
  144. const selectfun=()=>{
  145. emit('pipelineapi', '');
  146. currentPage4.value=1;
  147. if(multipleSelection.value.length!=0){
  148. // firepid.value=multipleSelection.value[0].id;
  149. emit('pipelineapi',multipleSelection.value[0]);
  150. // console.log(multipleSelection.value[0])
  151. }else{
  152. }
  153. }
  154. // 确定
  155. const queding=()=>{
  156. selectfun();
  157. }
  158. defineExpose({dialogVisiblenode,pipelinedata,searchtaggd});
  159. </script>
  160. <style lang="scss" scoped>
  161. .vtk{
  162. position: absolute;
  163. z-index: 150;
  164. top:70px;
  165. }
  166. .jc_padding .el-table tr {
  167. height: 30px !important;
  168. background: rgba(104, 173, 255, 0.3);
  169. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  170. border-radius: 0px 0px 0px 0px;
  171. border: 1px solid;
  172. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  173. }
  174. .flex_a {
  175. flex: 1;
  176. padding: 0 19px;
  177. }
  178. .btns {
  179. width: 72px;
  180. height: 30px;
  181. background-image: url(../../assets/img/Rectangle399.png);
  182. background-repeat: no-repeat;
  183. line-height: 30px;
  184. overflow: hidden;
  185. margin: 10px 0;
  186. .spantext {
  187. font-weight: bold;
  188. font-size: 12px;
  189. color: #FFFFFF;
  190. text-align: left;
  191. font-style: normal;
  192. text-transform: none;
  193. }
  194. }
  195. .header_z {
  196. box-shadow: none !important;
  197. padding: 10px 20px !important;
  198. }
  199. .header_l {
  200. line-height: 10px;
  201. text-align: left;
  202. padding: 0 20px;
  203. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  204. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  205. border-radius: 0px 0px 0px 0px;
  206. .el-image {
  207. padding: 10px 10px 0 0;
  208. }
  209. h4 {
  210. font-weight: bold;
  211. font-size: 12px;
  212. color: #68ADFF;
  213. line-height: 14px;
  214. text-align: left;
  215. font-style: normal;
  216. text-transform: none;
  217. }
  218. }
  219. .jc_padding {
  220. padding: 18px 10px;
  221. }
  222. .line {
  223. border-bottom: 1px solid rgba(255, 255, 255, 0.20);
  224. box-sizing: border-box;
  225. }
  226. .L_aside {
  227. .iconimg {
  228. width: 37px;
  229. height: 36px;
  230. margin: 0 7px 0 24px;
  231. }
  232. }
  233. .ddd {
  234. margin-top: 20px;
  235. .ddd_div {
  236. padding: 20px 0;
  237. position: relative;
  238. }
  239. .class_btn {
  240. position: absolute;
  241. right: 0;
  242. top: 21px;
  243. }
  244. .header_l {
  245. line-height: 10px;
  246. text-align: left;
  247. padding: 0 20px;
  248. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  249. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  250. border-radius: 0px 0px 0px 0px;
  251. .el-image {
  252. padding: 10px 10px 0 0;
  253. }
  254. h4 {
  255. font-weight: bold;
  256. font-size: 12px;
  257. color: #68ADFF;
  258. line-height: 14px;
  259. text-align: left;
  260. font-style: normal;
  261. text-transform: none;
  262. }
  263. }
  264. }
  265. .el-dialog__title {
  266. display: inline-block;
  267. }
  268. .bgcolor {
  269. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  270. border-radius: 0px 0px 0px 0px;
  271. border: 1px solid;
  272. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  273. }
  274. .log_class {
  275. .my-header {
  276. line-height: 10px;
  277. height: 40px;
  278. text-align: left;
  279. padding: 0 20px;
  280. border-bottom: 1px solid;
  281. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  282. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  283. border-radius: 0px 0px 0px 0px;
  284. .el-image {
  285. padding: 10px 10px 0 0;
  286. }
  287. h4 {
  288. font-weight: bold;
  289. font-size: 12px;
  290. color: #68ADFF;
  291. line-height: 14px;
  292. text-align: left;
  293. font-style: normal;
  294. text-transform: none;
  295. }
  296. }
  297. .my_content {
  298. width: 100%;
  299. height: 90px;
  300. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  301. border-radius: 0px 0px 0px 0px;
  302. position: relative;
  303. .radio-group {
  304. display: flex;
  305. justify-content: center;
  306. .el-radio {
  307. flex: 1;
  308. justify-content: center;
  309. font-weight: bold;
  310. font-size: 12px;
  311. color: #FFFFFF;
  312. line-height: 14px;
  313. }
  314. }
  315. }
  316. .el-dialog__footer {
  317. position: absolute;
  318. bottom: 17px;
  319. display: flex;
  320. .footerbtn {
  321. flex: 1;
  322. text-align: center;
  323. }
  324. }
  325. }
  326. .my_content1 {
  327. .el-table .cell {
  328. font-weight: 400;
  329. font-size: 12px;
  330. color: #FFFFFF !important;
  331. line-height: 14px;
  332. text-align: left;
  333. font-style: normal;
  334. text-transform: none;
  335. }
  336. }
  337. .l_btn .borderimg {
  338. width: 70px;
  339. height: 30px;
  340. font-size: 12px;
  341. background: rgba(104, 173, 255, 0.3);
  342. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  343. /* border: 1px solid rgba(31, 107, 255, 1); */
  344. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  345. font-weight: bold;
  346. border-radius: 4px;
  347. display: flex;
  348. display: inline-block;
  349. box-sizing: border-box;
  350. }
  351. .borderimg {
  352. width: 109px;
  353. height: 30px;
  354. background: rgba(104, 173, 255, 0.3);
  355. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  356. /* border: 1px solid rgba(31, 107, 255, 1); */
  357. -o-border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  358. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  359. border-radius: 4px;
  360. display: flex;
  361. display: inline-block;
  362. box-sizing: border-box
  363. }
  364. .el-table,
  365. .el-table thead th {
  366. background-color: rgba(13, 22, 57, 0.96) !important;
  367. }
  368. .L_aside {
  369. height: calc(100vh - 70px);
  370. position: absolute;
  371. top: 70px;
  372. overflow: hidden;
  373. }
  374. .el-form-item__label {
  375. color: #FFFFFF !important;
  376. }
  377. .jiancedian {
  378. width: 380px;
  379. position: absolute;
  380. right: 0;
  381. top: 70px;
  382. box-shadow: inset 0px 0px 17px 5px rgba(12, 97, 197, 0.2);
  383. border-radius: 4px 4px 4px 4px;
  384. border: 1px solid;
  385. border-image: linear-gradient(180deg, rgba(31, 107, 255, 1), rgba(31, 107, 255, 0.48)) 1 1;
  386. }
  387. </style>
  388. <style>
  389. .log_class{
  390. background-color: rgba(13, 22, 57, 0.96) !important;
  391. }
  392. </style>