index.vue 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847
  1. <!--定时排风-->
  2. <template>
  3. <div class="app-container timingExhaustAir">
  4. <div class="timingExhaustAirPage" v-if="pageType == 1">
  5. <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch">
  6. <el-form-item label="关键字" prop="searchValue" >
  7. <el-input
  8. maxlength="10"
  9. v-model="queryParams.searchValue"
  10. placeholder="任务名称/实验室/房间号"
  11. clearable
  12. />
  13. </el-form-item>
  14. <el-form-item label="学院" prop="deptId">
  15. <el-select v-model="queryParams.deptId" placeholder="请选择" clearable >
  16. <el-option
  17. v-for="dict in deptOptions"
  18. :key="dict.deptId"
  19. :label="dict.deptName"
  20. :value="dict.deptId"
  21. ></el-option>
  22. </el-select>
  23. </el-form-item>
  24. <el-form-item>
  25. <p class="inquire-button-one" @click="handleQuery">查询</p>
  26. <p class="reset-button-one" @click="resetQuery">重置</p>
  27. </el-form-item>
  28. <el-form-item style="float: right;margin-right:0;"
  29. v-hasPermi="['laboratory:exhaust:add']">
  30. <el-col :span="1.5">
  31. <p class="inquire-button-one" style="width:80px;margin:0;"
  32. @click="goPage(2)"
  33. ><i class="el-icon-plus"></i> 新增</p>
  34. </el-col>
  35. </el-form-item>
  36. </el-form>
  37. <el-table v-loading="loading" border :data="dataList">
  38. <el-table-column label="序号" width="100" align="left" type="index"/>
  39. <el-table-column label="定时排风任务" align="left" prop="taskName" show-overflow-tooltip/>
  40. <el-table-column label="是否启用" align="left" prop="exhaustType" width="200" show-overflow-tooltip>
  41. <template slot-scope="scope">
  42. <el-switch
  43. class="switch"
  44. @click.native="changeIsNeedCaptcha(scope.row)"
  45. v-model="scope.row.exhaustType"
  46. :active-value="1"
  47. :inactive-value="0"
  48. active-color="#0183FA"
  49. inactive-color="#E0E0E0"
  50. active-text="启用"
  51. inactive-text="停用"
  52. disabled
  53. ></el-switch>
  54. </template>
  55. </el-table-column>
  56. <el-table-column label="编辑时间" align="left" prop="updateTime" width="300" show-overflow-tooltip/>
  57. <el-table-column label="操作人" align="left" prop="updateBy" width="200" show-overflow-tooltip/>
  58. <el-table-column label="操作" align="left" prop="createTime" width="300" show-overflow-tooltip v-if="tableButtonType">
  59. <template slot-scope="scope">
  60. <div class="button-box">
  61. <p class="table-min-button" style="margin-left:20px!important;"
  62. v-hasPermiAnd="['laboratory:exhaust:query','laboratory:exjoinsub:add']"
  63. @click="correlationButton(scope.row.id)">关联实验室</p>
  64. <p class="table-min-button" style="margin-left:20px!important;"
  65. v-hasPermiAnd="['laboratory:exhaust:query','laboratory:exhaust:edit']"
  66. @click="goPage(3,scope.row.id)">编辑</p>
  67. <p class="table-min-button" style="margin-left:20px!important;"
  68. v-hasPermi="['laboratory:exhaust:remove']"
  69. @click="delExhaust(scope.row.id)">删除</p>
  70. </div>
  71. </template>
  72. </el-table-column>
  73. </el-table>
  74. <pagination
  75. v-show="total>0"
  76. :total="total"
  77. :page.sync="queryParams.pageNum"
  78. :limit.sync="queryParams.pageSize"
  79. @pagination="getList"
  80. />
  81. </div>
  82. <add-page v-if="pageType == 2" :propsData="propsData"></add-page>
  83. <el-dialog title="关联实验室" :visible.sync="exhaustPageType" v-if="exhaustPageType"
  84. width="1470px" append-to-body id="exhaust-correlation-dialog-box">
  85. <p class="exhaust-title-p" v-if="!correlationData.executionDate">任务执行时间 <span>(适用所有日期)</span></p>
  86. <div class="exhaust-title-box" v-else>
  87. <p class="title-p">任务执行时间</p>
  88. <div class="text-box">
  89. <span v-for="(item,index) in correlationData.executionDate" :key="index">{{item.beginDate}}至 {{item.endDate}}{{index!=correlationData.executionDate.length-1?',':''}}</span>
  90. </div>
  91. </div>
  92. <div class="time-max-box">
  93. <div class="for-time-box" v-for="(item,index) in correlationData.exhaustPeriodVoList" :key="index">
  94. <p class="for-title-p">{{item.beginTime}}~{{item.endTime}}</p>
  95. <div class="for-time-min-box" :class="item.timedType==3?'for-time-min-box-one':''">
  96. <p class="for-time-text-one" v-show="item.timedType==1">周一至周五</p>
  97. <p class="for-time-text-one" v-show="item.timedType==2">周一至周日</p>
  98. <p class="for-time-text-tow" v-show="item.timedType==3" v-for="(minItem,minIndex) in item.customTime" :key="minIndex">{{minItem==1?'周一':(minItem==2?'周二':(minItem==3?'周三':(minItem==4?'周四':(minItem==5?'周五':(minItem==6?'周六':minItem==7?'周日':'')))))}}{{minIndex!=item.customTime.length-1?'、':''}}</p>
  99. </div>
  100. </div>
  101. </div>
  102. <div class="exhaust-sub-max-box">
  103. <div class="left-sub-max-box">
  104. <div class="left-sub-max-title">
  105. <p>待选实验室</p>
  106. <p>{{leftIds.length?leftIds.length:0}}/{{leftTotal}}</p>
  107. </div>
  108. <div class="left-form-max-box">
  109. <el-form :model="leftQueryParams" :inline="true" v-show="leftShowSearch"
  110. ref="queryForm" style="display: flex">
  111. <el-form-item label="关键字" prop="searchValue" >
  112. <el-input
  113. style="width:150px;"
  114. maxlength="10"
  115. v-model="leftQueryParams.searchValue"
  116. placeholder="实验室"
  117. clearable
  118. />
  119. </el-form-item>
  120. <el-form-item label="学院" prop="deptId">
  121. <el-select v-model="leftQueryParams.deptId" placeholder="请选择" clearable
  122. style="width:130px;">
  123. <el-option
  124. v-for="dict in deptOptions"
  125. :key="dict.deptId"
  126. :label="dict.deptName"
  127. :value="dict.deptId"
  128. ></el-option>
  129. </el-select>
  130. </el-form-item>
  131. <el-form-item label="安全分类" prop="typeId">
  132. <el-select v-model="leftQueryParams.typeId" placeholder="请选择" clearable
  133. style="width:100px;">
  134. <el-option
  135. v-for="dict in typeList"
  136. :key="dict.id"
  137. :label="dict.typeName"
  138. :value="dict.id"
  139. ></el-option>
  140. </el-select>
  141. </el-form-item>
  142. <el-form-item label="安全分级" prop="level">
  143. <el-select v-model="leftQueryParams.level" placeholder="请选择" clearable
  144. style="width:100px;">
  145. <el-option
  146. v-for="dict in levelList"
  147. :key="dict.id"
  148. :label="dict.classifiedName"
  149. :value="dict.id"
  150. ></el-option>
  151. </el-select>
  152. </el-form-item>
  153. <el-form-item>
  154. <p class="inquire-button-one" @click="leftHandleQuery">查询</p>
  155. <p class="reset-button-one" @click="leftResetQuery">重置</p>
  156. </el-form-item>
  157. </el-form>
  158. <el-table ref="leftTable" v-loading="leftLoading" border :data="leftDataList" @selection-change="handleSelectionChangeLeft" :row-key="getRowKeysLeft">
  159. <el-table-column type="selection" width="59" align="left" :reserve-selection="true"/>
  160. <el-table-column label="实验室" align="left" prop="name" show-overflow-tooltip/>
  161. <el-table-column label="安全分类" align="left" prop="typeName" width="100" show-overflow-tooltip/>
  162. <el-table-column label="安全分级" align="left" prop="levelName" width="100" show-overflow-tooltip/>
  163. <el-table-column label="实验室位置" align="left" prop="posi" width="358" show-overflow-tooltip/>
  164. </el-table>
  165. <pagination
  166. v-show="leftTotal>0"
  167. :total="leftTotal"
  168. :page.sync="leftQueryParams.pageNum"
  169. :limit.sync="leftQueryParams.pageSize"
  170. @pagination="getLabExhaustNoJoinSub"
  171. />
  172. <p style="height:20px;" v-show="leftTotal==0"></p>
  173. </div>
  174. </div>
  175. <div class="button-sub-max-box">
  176. <img class="top-img" v-show="!rightIds.length" src="@/assets/ZDimages/icon_wxz_zuo.png">
  177. <img class="top-img" v-show="rightIds.length" @click="rightDataMoveLeft" src="@/assets/ZDimages/icon_yxz_zuo.png">
  178. <img class="bottom-img" v-show="!leftIds.length" src="@/assets/ZDimages/icon_wxz_yuo.png">
  179. <img class="bottom-img" v-show="leftIds.length" @click="leftDataMoveRight" src="@/assets/ZDimages/icon_yxz_yuo.png">
  180. </div>
  181. <div class="right-sub-max-box">
  182. <div class="right-sub-max-title">
  183. <p>已选择实验室</p>
  184. <p>{{rightIds.length?rightIds.length:0}}/{{rightTotal}}</p>
  185. </div>
  186. <div class="right-form-max-box">
  187. <el-form :inline="true" v-show="rightShowSearch"
  188. ref="queryForm" style="display: flex">
  189. <el-form-item label="" prop="searchValue" >
  190. <el-input placeholder="请输入实验室名称" style="width:288px;" v-model="inputNameText" class="input-with-select">
  191. <el-button slot="append" icon="el-icon-search" @click="rightTableButton"
  192. style="background:rgba(0,0,0,0);"></el-button>
  193. </el-input>
  194. </el-form-item>
  195. </el-form>
  196. <el-table ref="rightTable" v-loading="rightLoading" border @selection-change="handleSelectionChangeRight" :row-key="getRowKeysRight"
  197. :data="rightDataList.filter((v) => inputType?v.name.indexOf(inputName) != -1:v.name)">
  198. <el-table-column type="selection" width="80" align="left" :reserve-selection="true"/>
  199. <el-table-column label="实验室" align="left" prop="name" show-overflow-tooltip/>
  200. </el-table>
  201. </div>
  202. </div>
  203. </div>
  204. <div slot="footer" class="dialog-footer">
  205. <div class="exhaust-button-box">
  206. <p></p>
  207. <p @click="cancel">取消</p>
  208. <p @click="joinsubButton">确定</p>
  209. <p></p>
  210. </div>
  211. </div>
  212. </el-dialog>
  213. </div>
  214. </template>
  215. <script>
  216. import { delExhaust,exhaustList,operateExhaust,getExhaustInfo,getLabExhaustNoJoinSub,getLabExhaustJoinSub,joinsub } from "@/api/laboratory/exhaustTime";
  217. import { listClassifiedAll } from "@/api/laboratory/classified";
  218. import { listClasstypeAll } from "@/api/laboratory/classtype";
  219. import { listDepartments } from "@/api/system/dept";
  220. import addPage from "./addPage.vue";
  221. export default {
  222. name: 'index',
  223. components: {
  224. addPage
  225. },
  226. data() {
  227. return {
  228. tableButtonType:this.hasPermiDom(['laboratory:exhaust:query','laboratory:exhaust:edit','laboratory:exjoinsub:add','laboratory:exhaust:remove']),
  229. //关联实验室也页面状态
  230. exhaustPageType:false,
  231. //页面状态
  232. pageType:1,
  233. showSearch:true,
  234. loading:false,
  235. total:0,
  236. queryParams:{
  237. pageNum: 1,
  238. pageSize:20,
  239. searchValue:"",
  240. deptId:"",
  241. },
  242. //列表数据
  243. dataList:[],
  244. //学院数据
  245. deptOptions:[],
  246. //分类数据
  247. typeList:[],
  248. //分级数据
  249. levelList:[],
  250. propsData:{},
  251. //关联数据
  252. correlationData:{},
  253. //左列表数据
  254. leftShowSearch:true,
  255. leftLoading:false,
  256. leftTotal:0,
  257. leftQueryParams:{
  258. pageNum: 1,
  259. pageSize:10,
  260. searchValue:"",
  261. deptId:"",
  262. typeId:"",
  263. level:"",
  264. },
  265. leftDataList:[],
  266. leftSelectedNum:0,
  267. leftIds:[],
  268. leftMultiple:true,
  269. //右列表数据
  270. rightShowSearch:true,
  271. rightLoading:false,
  272. rightQueryParams:{
  273. searchValue:"",
  274. },
  275. rightDataList:[],
  276. rightTotal:0,
  277. rightSelectedNum:0,
  278. rightIds:[],
  279. rightMultiple:true,
  280. //删减减数据
  281. addList:[],
  282. reduceList:[],
  283. //原始数据
  284. primitiveList:[],
  285. //搜索内容
  286. inputNameText:'',
  287. //搜索匹配内容
  288. inputName:'',
  289. //搜索状态开关
  290. inputType:false,
  291. }
  292. },
  293. created() {
  294. this.listDepartments();
  295. this.getListClassifiedAll();
  296. this.getListClasstypeAll();
  297. this.getList();
  298. },
  299. mounted() {
  300. },
  301. methods: {
  302. //右侧查询过滤按钮
  303. rightTableButton(){
  304. if(this.inputNameText){
  305. this.$set(this,'inputName',this.inputNameText);
  306. this.$set(this,'inputType',true);
  307. }else{
  308. this.$set(this,'inputName','');
  309. this.$set(this,'inputType',false);
  310. }
  311. },
  312. //关联数据提交
  313. joinsubButton(){
  314. let self = this;
  315. let obj = {
  316. delSubIds:[],
  317. joinsubList:[],
  318. };
  319. for(let i=0;i<self.rightDataList.length;i++){
  320. let minObj = {
  321. timedExhaustId:self.correlationData.id,
  322. subId:self.rightDataList[i].id
  323. }
  324. obj.joinsubList.push(minObj)
  325. }
  326. for(let o=0;o<self.primitiveList.length;o++){
  327. let num = 0;
  328. for(let i=0;i<self.rightDataList.length;i++){
  329. if (self.rightDataList[i].id == self.primitiveList[o].id){
  330. num ++
  331. }
  332. }
  333. if(num == 0){
  334. obj.delSubIds.push(self.primitiveList[o].id)
  335. }
  336. }
  337. joinsub(obj).then( response => {
  338. self.msgSuccess(response.msg);
  339. self.$set(self,'exhaustPageType',false);
  340. });
  341. },
  342. //左侧数据移动到右
  343. leftDataMoveRight(){
  344. let self = this;
  345. if(this.leftIds[0]){
  346. for(let i=0;i<self.leftIds.length;i++){
  347. let num = 0;
  348. for(let o=0;o<self.addList.length;o++){
  349. if(self.leftIds[i] == self.addList[o]){
  350. num++
  351. }
  352. }
  353. if(num == 0){
  354. self.addList.push(self.leftIds[i])
  355. }
  356. for(let o=0;o<self.reduceList.length;o++){
  357. if(self.leftIds[i] == self.reduceList[o]){
  358. self.reduceList.splice(o,1);
  359. }
  360. }
  361. for(let x=0;x<self.leftDataList.length;x++){
  362. if(self.leftIds[i] == self.leftDataList[x].id){
  363. let age = 0;
  364. for(let o=0;o<self.rightDataList.length;o++){
  365. if(self.leftIds[i] == self.rightDataList[o].id){
  366. age++
  367. }
  368. }
  369. if(age == 0){
  370. self.rightDataList.push(self.leftDataList[x])
  371. }
  372. }
  373. }
  374. }
  375. }
  376. this.$refs.leftTable.clearSelection()
  377. this.getLabExhaustNoJoinSub();
  378. },
  379. //右侧数据移动到左
  380. rightDataMoveLeft(){
  381. let self = this;
  382. if(this.rightIds[0]){
  383. for(let i=0;i<self.rightIds.length;i++){
  384. let num = 0;
  385. for(let o=0;o<self.reduceList.length;o++){
  386. if(self.rightIds[i] == self.reduceList[o]){
  387. num++
  388. }
  389. }
  390. if(num == 0){
  391. self.reduceList.push(self.rightIds[i])
  392. }
  393. for(let o=0;o<self.rightDataList.length;o++){
  394. if(self.rightDataList[o].id == self.rightIds[i]){
  395. self.rightDataList.splice(o,1);
  396. }
  397. }
  398. for(let o=0;o<self.addList.length;o++){
  399. if(self.rightIds[i] == self.addList[o]){
  400. self.addList.splice(o,1);
  401. }
  402. }
  403. }
  404. this.$refs.rightTable.clearSelection()
  405. this.getLabExhaustNoJoinSub();
  406. }
  407. },
  408. //关联实验室
  409. correlationButton(id){
  410. this.$set(this,'leftSelectedNum',0);
  411. this.$set(this,'leftIds',[]);
  412. this.$set(this,'leftMultiple',true);
  413. this.$set(this,'rightSelectedNum',0);
  414. this.$set(this,'rightIds',[]);
  415. this.$set(this,'rightMultiple',true);
  416. this.$set(this,'addList',[]);
  417. this.$set(this,'reduceList',[]);
  418. this.$set(this,'primitiveList',[]);
  419. this.$set(this,'inputNameText','');
  420. this.$set(this,'inputName','');
  421. this.$set(this,'inputType',false);
  422. getExhaustInfo(id).then( response => {
  423. for(let i=0;i<response.data.exhaustPeriodVoList.length;i++){
  424. if(response.data.exhaustPeriodVoList[i].customTime){
  425. response.data.exhaustPeriodVoList[i].customTime = response.data.exhaustPeriodVoList[i].customTime.split(',');
  426. }
  427. }
  428. if(response.data.executionDate){
  429. response.data.executionDate = JSON.parse(response.data.executionDate);
  430. }
  431. this.$set(this,'correlationData',response.data);
  432. this.leftResetQuery();
  433. this.rightResetQuery();
  434. this.$set(this,'exhaustPageType',true);
  435. });
  436. },
  437. //页面状态切换
  438. goPage(type,id){
  439. let self = this;
  440. if(this.pageType != type){
  441. if(type == 1){
  442. this.pageType = 1;
  443. }else if(type == 2){
  444. this.$set(this,'propsData',{});
  445. this.pageType = 2;
  446. }else if(type == 3){
  447. getExhaustInfo(id).then( response => {
  448. for(let i=0;i<response.data.exhaustPeriodVoList.length;i++){
  449. if(response.data.exhaustPeriodVoList[i].customTime){
  450. response.data.exhaustPeriodVoList[i].customTime = response.data.exhaustPeriodVoList[i].customTime.split(',');
  451. }
  452. }
  453. this.$set(this,'propsData',response.data);
  454. this.pageType = 2;
  455. });
  456. }else if(type == 4){
  457. this.pageType = 1;
  458. this.resetQuery();
  459. this.$confirm('是否立即关联实验室,也可以稍后在列表中关联实验室.', "警告", {
  460. confirmButtonText: "关联",
  461. cancelButtonText: "取消",
  462. type: "warning"
  463. }).then(function() {
  464. self.correlationButton(id);
  465. }).then(() => {
  466. }).catch(() => {});
  467. }
  468. }
  469. },
  470. //删除任务
  471. delExhaust(id){
  472. let self = this;
  473. this.$confirm('确认删除该任务?', "警告", {
  474. confirmButtonText: "确认",
  475. cancelButtonText: "取消",
  476. type: "warning"
  477. }).then(function() {
  478. delExhaust(id).then( response => {
  479. self.msgSuccess(response.msg);
  480. self.getList();
  481. })
  482. }).then(() => {
  483. }).catch(() => {});
  484. },
  485. //启用停用方法
  486. changeIsNeedCaptcha(item){
  487. let self = this;
  488. let obj = {
  489. id:item.id,
  490. exhaustType:item.exhaustType==1?0:1
  491. }
  492. this.$confirm('确定'+(item.exhaustType==1?'停用排风任务吗?':'启用排风任务吗?'), "警告", {
  493. confirmButtonText: "确定",
  494. cancelButtonText: "取消",
  495. type: "warning"
  496. }).then(function() {
  497. operateExhaust(obj).then( response => {
  498. self.msgSuccess(response.msg);
  499. self.getList();
  500. });
  501. }).then(() => {
  502. }).catch(() => {});
  503. },
  504. //获取列表数据
  505. getList(){
  506. this.loading = true;
  507. exhaustList(this.queryParams).then( response => {
  508. this.dataList = response.rows;
  509. this.total = response.total;
  510. this.loading = false;
  511. });
  512. },
  513. //查询
  514. handleQuery(){
  515. this.queryParams.pageNum = 1;
  516. this.getList();
  517. },
  518. //重置
  519. resetQuery(){
  520. this.$set(this,'queryParams',{
  521. pageNum:1,
  522. pageSize:20,
  523. searchValue:"",
  524. deptId:"",
  525. });
  526. this.handleQuery();
  527. },
  528. //左查询
  529. leftHandleQuery(){
  530. this.leftQueryParams.pageNum = 1;
  531. this.getLabExhaustNoJoinSub();
  532. },
  533. //左重置
  534. leftResetQuery(){
  535. this.$set(this,'leftQueryParams',{
  536. pageNum: 1,
  537. pageSize:10,
  538. searchValue:"",
  539. deptId:"",
  540. typeId:"",
  541. level:"",
  542. });
  543. this.leftHandleQuery();
  544. },
  545. //左获取列表数据
  546. getLabExhaustNoJoinSub(){
  547. this.leftLoading = true;
  548. let obj = JSON.parse(JSON.stringify(this.leftQueryParams));
  549. obj.noSubIds = JSON.parse(JSON.stringify(this.addList));
  550. obj.subIds = JSON.parse(JSON.stringify(this.reduceList));
  551. getLabExhaustNoJoinSub(obj).then( response => {
  552. this.leftDataList = response.rows;
  553. this.leftTotal = response.total;
  554. this.$set(this,'rightTotal',this.rightDataList.length);
  555. this.leftLoading = false;
  556. this.$forceUpdate();
  557. });
  558. },
  559. //左多选框选中数据
  560. handleSelectionChangeLeft(selection) {
  561. this.leftSelectedNum = selection.length;
  562. this.leftIds = selection.map(item => item.id)
  563. this.leftMultiple = !selection.length
  564. },
  565. getRowKeysLeft(row) {
  566. return row.id
  567. },
  568. //右侧获取列表数据
  569. rightResetQuery(){
  570. this.rightLoading = true;
  571. console.log('this.correlationData.id',this.correlationData.id)
  572. getLabExhaustJoinSub({timedExhaustId:this.correlationData.id}).then( response => {
  573. this.rightDataList = JSON.parse(JSON.stringify(response.data.list));
  574. this.primitiveList = JSON.parse(JSON.stringify(response.data.list));
  575. this.rightTotal = response.data.total;
  576. this.rightLoading = false;
  577. });
  578. },
  579. //右多选框选中数据
  580. handleSelectionChangeRight(selection) {
  581. this.rightSelectedNum = selection.length;
  582. this.rightIds = selection.map(item => item.id)
  583. this.rightMultiple = !selection.length
  584. },
  585. getRowKeysRight(row) {
  586. return row.id
  587. },
  588. //关闭窗口
  589. cancel(){
  590. this.$set(this,'exhaustPageType',false);
  591. },
  592. //获取学院列表
  593. listDepartments(){
  594. listDepartments().then(response => {
  595. this.deptOptions = response.data;
  596. });
  597. },
  598. //获取分级
  599. getListClassifiedAll(){
  600. listClassifiedAll().then(response=>{
  601. if(response.code==200){
  602. this.levelList = response.data
  603. }
  604. })
  605. },
  606. //获取分类
  607. getListClasstypeAll(){
  608. listClasstypeAll().then(response=>{
  609. if(response.code==200){
  610. this.typeList = response.data;
  611. }
  612. });
  613. },
  614. }
  615. }
  616. </script>
  617. <style scoped lang="scss">
  618. .timingExhaustAir{
  619. flex:1;
  620. display: flex;
  621. flex-direction: column;
  622. .timingExhaustAirPage{
  623. flex:1;
  624. display: flex;
  625. flex-direction: column;
  626. padding:20px 20px 10px 20px!important;
  627. .button-box{
  628. display: flex;
  629. }
  630. }
  631. }
  632. </style>
  633. <style lang="scss">
  634. #exhaust-correlation-dialog-box{
  635. .el-form-item{
  636. display: flex;
  637. margin-right:10px;
  638. }
  639. .el-dialog__body{
  640. padding:0 55px;
  641. }
  642. .el-input-group__append{
  643. border:none;
  644. background: #fff!important;
  645. }
  646. .el-input-group--append .el-input__inner{
  647. border:none;
  648. }
  649. .el-form-item__content .el-input-group{
  650. border:1px solid #DCDFE6;
  651. border-radius:4px;
  652. }
  653. .exhaust-title-p{
  654. color:#0045AF;
  655. font-size:18px;
  656. line-height:60px;
  657. span{
  658. margin-left:20px;
  659. font-size:18px;
  660. }
  661. }
  662. .exhaust-title-box{
  663. color:#0045AF;
  664. display: flex;
  665. .title-p{
  666. width:130px;
  667. font-size:18px;
  668. line-height:60px;
  669. }
  670. .text-box{
  671. flex:1;
  672. padding:10px 0;
  673. span{
  674. display: inline-block;
  675. margin-right:20px;
  676. font-size:18px;
  677. line-height:40px;
  678. }
  679. }
  680. }
  681. .time-max-box{
  682. display: flex;
  683. .for-time-box{
  684. width:170px;
  685. height:140px;
  686. margin-right:11px;
  687. .for-title-p{
  688. width:170px;
  689. height:40px;
  690. line-height:40px;
  691. color:#0183FA;
  692. background: rgba(1,131,250,0.1);
  693. text-align: center;
  694. font-size:16px;
  695. }
  696. .for-time-min-box{
  697. width:170px;
  698. height:100px;
  699. color:#333;
  700. border: 1px solid #E0E0E0;
  701. font-size:14px;
  702. .for-time-text-one{
  703. text-align: center;
  704. line-height:100px;
  705. }
  706. .for-time-text-tow{
  707. display: inline-block;
  708. line-height:25px;
  709. }
  710. }
  711. .for-time-min-box-one{
  712. padding:10px 15px 10px 25px;
  713. }
  714. }
  715. }
  716. .exhaust-sub-max-box{
  717. margin:20px 0 28px;
  718. padding-top:20px;
  719. border-top:1px dashed #D8D8D8;
  720. display: flex;
  721. .left-sub-max-box{
  722. width:957px;
  723. height:440px;
  724. .el-table__empty-text{
  725. font-size:0;
  726. color:rgba(0,0,0,0);
  727. width:100%;
  728. height:100%;
  729. background: url("../../../../assets/ZDimages/null-data-1.png") no-repeat 50% 50%;
  730. background-size: 18%;
  731. }
  732. .left-sub-max-title{
  733. display: flex;
  734. background: rgba(1,131,250,0.1);
  735. color:#0183FA;
  736. line-height:40px;
  737. font-size:16px;
  738. p:nth-child(1){
  739. margin-left:29px;
  740. flex:1;
  741. }
  742. p:nth-child(2){
  743. margin-right:22px;
  744. }
  745. }
  746. .left-form-max-box{
  747. display: flex;
  748. flex-direction: column;
  749. width:957px;
  750. height:400px;
  751. border:1px solid #E0E0E0;
  752. padding:20px 20px 0 20px;
  753. }
  754. }
  755. .button-sub-max-box{
  756. width:74px;
  757. .top-img{
  758. cursor: pointer;
  759. display: block;
  760. margin-top:201px;
  761. width:30px;
  762. height:30px;
  763. margin-left:22px;
  764. }
  765. .bottom-img{
  766. cursor: pointer;
  767. display: block;
  768. margin-top:14px;
  769. width:30px;
  770. height:30px;
  771. margin-left:22px;
  772. }
  773. }
  774. .right-sub-max-box{
  775. height:440px;
  776. width:330px;
  777. .el-table__empty-text{
  778. font-size:0;
  779. color:rgba(0,0,0,0);
  780. width:100%;
  781. height:100%;
  782. background: url("../../../../assets/ZDimages/null-data-1.png") no-repeat 50% 50%;
  783. background-size: 55%;
  784. }
  785. .right-sub-max-title{
  786. display: flex;
  787. background: rgba(1,131,250,0.1);
  788. color:#0183FA;
  789. line-height:40px;
  790. font-size:16px;
  791. p:nth-child(1){
  792. margin-left:29px;
  793. flex:1;
  794. }
  795. p:nth-child(2){
  796. margin-right:22px;
  797. }
  798. }
  799. .right-form-max-box{
  800. display: flex;
  801. flex-direction: column;
  802. width:330px;
  803. height:400px;
  804. border:1px solid #E0E0E0;
  805. padding:20px;
  806. }
  807. }
  808. }
  809. .exhaust-button-box{
  810. display: flex;
  811. p:nth-child(1){
  812. flex:1;
  813. }
  814. p:nth-child(2){
  815. width:70px;
  816. height:30px;
  817. line-height:30px;
  818. margin-right:13px;
  819. font-size:12px;
  820. color:#999999;
  821. background: #E0E0E0;
  822. border-radius:6px;
  823. text-align: center;
  824. cursor: pointer;
  825. }
  826. p:nth-child(3){
  827. width:70px;
  828. height:30px;
  829. line-height:30px;
  830. font-size:12px;
  831. color:#ffffff;
  832. background: #0045AF;
  833. border-radius:6px;
  834. text-align: center;
  835. cursor: pointer;
  836. }
  837. p:nth-child(4){
  838. flex:1;
  839. }
  840. }
  841. }
  842. </style>