detailPlan.vue 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <!--风险预案编辑-->
  2. <template>
  3. <div class="addPlan">
  4. <el-form :model="form" ref="form" :inline="true" label-width="100px" class="form-box">
  5. <p class="reset-button-one" @click="backPage"><i class="el-icon-arrow-left"></i>返回</p>
  6. <div class="plan-info-box">
  7. <p class="plan-title-p color_one">基本信息</p>
  8. <div class="plan_n">
  9. <div>
  10. <p style="width:100px;">预案名称:</p>
  11. <p>{{form.name}}</p>
  12. </div>
  13. <div>
  14. <p>同步执行疏散:</p>
  15. <p>{{form.evacuation==0?'否':'是'}}</p>
  16. </div>
  17. </div>
  18. </div>
  19. <div class="plan-info-box">
  20. <p class="plan-title-p color_one">启动条件</p>
  21. <div class="plan_n2" v-for="item in form.riskPlanSensorList">
  22. <li>
  23. <i>传感器类型:</i>
  24. <i>{{item.FuncName}}传感器</i>
  25. </li>
  26. <li>
  27. <i>异常值区间:</i>
  28. <i>{{item.minMonitor}}-{{item.maxMonitor}}</i>
  29. </li>
  30. </div>
  31. </div>
  32. <div class="plan-info-box">
  33. <p class="plan-title-p color_one">执行动作</p>
  34. <div class="plan_n2" v-for="item in form.riskPlanHardwareList">
  35. <li>
  36. <i>硬件:</i>
  37. <i>{{item.hardwareTypeName}}</i>
  38. </li>
  39. <li>
  40. <i>执行操作: </i>
  41. <i>{{item.operate==0?'关闭':'打开'}}</i>
  42. </li>
  43. <li>
  44. <i>结束操作: </i>
  45. <i>{{item.overAct==0?'关闭':'打开'}}</i>
  46. </li>
  47. </div>
  48. </div>
  49. </el-form>
  50. </div>
  51. </template>
  52. <script>
  53. import {getPlan} from "@/api/laboratory/plan";
  54. import {listDepartments} from "@/api/system/dept";
  55. export default {
  56. props:{
  57. pageData2:{},
  58. },
  59. name: "detailPlan",
  60. data() {
  61. return {
  62. form:{},
  63. };
  64. },
  65. created() {
  66. console.log(this.pageData2.id)
  67. this.getPlan()
  68. },
  69. methods: {
  70. //切换页面
  71. backPage(){
  72. this.$parent.handleClick('','','back');
  73. },
  74. /** 查询详情 */
  75. getPlan() {
  76. let _this=this;
  77. getPlan(_this.pageData2.id).then(response => {
  78. this.form = response.data;
  79. });
  80. },
  81. },
  82. beforeMount() {
  83. },
  84. };
  85. </script>
  86. <style scoped lang="scss">
  87. .addPlan{
  88. position: relative;
  89. margin-top:-11px;
  90. p{
  91. margin:0;
  92. }
  93. .reset-button-one{
  94. position: absolute;
  95. top:20px;
  96. right:20px;
  97. }
  98. .plan-info-box{
  99. width: 100%;
  100. height: auto;
  101. background: #FFFFFF;
  102. /*box-shadow: 0px 3px 8px 1px rgba(0, 0, 0, 0.1);*/
  103. border-radius: 20px;
  104. margin-bottom: 20px;
  105. /*padding: 30px 20px;*/
  106. box-sizing: border-box;
  107. .plan-title-p{
  108. height:80px;
  109. line-height:80px;
  110. font-size:18px;
  111. padding-left:20px;
  112. border-bottom:1px solid #E0E0E0;
  113. }
  114. .plan_n{
  115. width: 100%;
  116. display: flex;
  117. padding-left: 76px;
  118. box-sizing: border-box;
  119. margin-top:40px;
  120. div{
  121. list-style:none;
  122. width:370px;
  123. margin-right: 16px;
  124. display: flex;
  125. /*margin-right: 216px;*/
  126. p{
  127. font-style:normal;
  128. }
  129. p:nth-of-type(1){
  130. width:120px;
  131. font-size: 16px;
  132. font-family: Microsoft YaHei;
  133. font-weight: bold;
  134. color: #333333;
  135. line-height: 18px;
  136. margin-right: 16px;
  137. }
  138. p:nth-of-type(2){
  139. flex:1;
  140. font-size: 16px;
  141. font-family: Microsoft YaHei;
  142. font-weight: bold;
  143. color: #999999;
  144. line-height: 18px;
  145. }
  146. }
  147. }
  148. .plan_n2{
  149. width: 100%;
  150. height: 42px;
  151. display: flex;
  152. justify-content: flex-start;
  153. align-items: center;
  154. padding-left: 76px;
  155. box-sizing: border-box;
  156. >li{
  157. list-style:none;
  158. height: 42px;
  159. width:370px;
  160. margin-right: 16px;
  161. /*margin-right: 216px;*/
  162. >i{
  163. font-style:normal;
  164. }
  165. >i:nth-of-type(1){
  166. font-size: 16px;
  167. font-family: Microsoft YaHei;
  168. font-weight: bold;
  169. color: #333333;
  170. line-height: 70px;
  171. margin-right: 16px;
  172. }
  173. >i:nth-of-type(2){
  174. font-size: 16px;
  175. font-family: Microsoft YaHei;
  176. font-weight: bold;
  177. color: #999999;
  178. line-height: 70px;
  179. }
  180. }
  181. }
  182. }
  183. }
  184. </style>