index.vue 34 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247
  1. <template>
  2. <div class="app-container">
  3. <!-- <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
  4. <el-form-item label="计划名称" prop="planName">
  5. <el-input
  6. v-model="queryParams.planName"
  7. placeholder="请输入计划名称"
  8. clearable
  9. size="small"
  10. @keyup.enter.native="handleQuery"
  11. />
  12. </el-form-item>
  13. <el-form-item label="计划开始时间" prop="planStartTime">
  14. <el-date-picker clearable size="small"
  15. v-model="queryParams.planStartTime"
  16. type="date"
  17. value-format="yyyy-MM-dd"
  18. placeholder="选择计划开始时间">
  19. </el-date-picker>
  20. </el-form-item>
  21. <el-form-item label="计划结束时间" prop="planEndTime">
  22. <el-date-picker clearable size="small"
  23. v-model="queryParams.planEndTime"
  24. type="date"
  25. value-format="yyyy-MM-dd"
  26. placeholder="选择计划结束时间">
  27. </el-date-picker>
  28. </el-form-item>
  29. <el-form-item label="计划简介" prop="planIntroduction">
  30. <el-input
  31. v-model="queryParams.planIntroduction"
  32. placeholder="请输入计划简介"
  33. clearable
  34. size="small"
  35. @keyup.enter.native="handleQuery"
  36. />
  37. </el-form-item>
  38. <el-form-item label="文件路径" prop="filePath">
  39. <el-input
  40. v-model="queryParams.filePath"
  41. placeholder="请输入文件路径"
  42. clearable
  43. size="small"
  44. @keyup.enter.native="handleQuery"
  45. />
  46. </el-form-item>
  47. <el-form-item label="文件名称" prop="fileName">
  48. <el-input
  49. v-model="queryParams.fileName"
  50. placeholder="请输入文件名称"
  51. clearable
  52. size="small"
  53. @keyup.enter.native="handleQuery"
  54. />
  55. </el-form-item>
  56. <el-form-item label="创建人" prop="createName">
  57. <el-input
  58. v-model="queryParams.createName"
  59. placeholder="请输入创建人"
  60. clearable
  61. size="small"
  62. @keyup.enter.native="handleQuery"
  63. />
  64. </el-form-item>
  65. <el-form-item label="创建人id" prop="createId">
  66. <el-input
  67. v-model="queryParams.createId"
  68. placeholder="请输入创建人id"
  69. clearable
  70. size="small"
  71. @keyup.enter.native="handleQuery"
  72. />
  73. </el-form-item>
  74. <el-form-item label="需响应计划数" prop="planNumber">
  75. <el-input
  76. v-model="queryParams.planNumber"
  77. placeholder="请输入需响应计划数"
  78. clearable
  79. size="small"
  80. @keyup.enter.native="handleQuery"
  81. />
  82. </el-form-item>
  83. <el-form-item label="已响应计划数" prop="responseNumber">
  84. <el-input
  85. v-model="queryParams.responseNumber"
  86. placeholder="请输入已响应计划数"
  87. clearable
  88. size="small"
  89. @keyup.enter.native="handleQuery"
  90. />
  91. </el-form-item>
  92. <el-form-item label="单位id" prop="unitId">
  93. <el-input
  94. v-model="queryParams.unitId"
  95. placeholder="请输入单位id"
  96. clearable
  97. size="small"
  98. @keyup.enter.native="handleQuery"
  99. />
  100. </el-form-item>
  101. <el-form-item label="计划状态(0进行中,1已完成,2已审批,3已驳回)" prop="state">
  102. <el-input
  103. v-model="queryParams.state"
  104. placeholder="请输入计划状态(0进行中,1已完成,2已审批,3已驳回)"
  105. clearable
  106. size="small"
  107. @keyup.enter.native="handleQuery"
  108. />
  109. </el-form-item>
  110. <el-form-item>
  111. <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
  112. <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
  113. </el-form-item>
  114. </el-form>-->
  115. <el-row :gutter="20">
  116. <el-col :span="4" :xs="24">
  117. <div class="dadui">
  118. <img src="../../../images/星星.png" alt />
  119. 大队
  120. </div>
  121. <div class="tree">
  122. <el-tree
  123. class="userAgrees"
  124. style="height: calc(100vh - 170px); overflow: auto"
  125. :data="deptOptions"
  126. :props="defaultProps"
  127. @node-click="handleNodeClick"
  128. default-expand-all
  129. highlight-current
  130. :expand-on-click-node="false"
  131. ></el-tree>
  132. </div>
  133. </el-col>
  134. <el-col :span="1.5" class="mb8">
  135. <!-- <el-button
  136. type="primary"
  137. plain
  138. icon="el-icon-plus"
  139. size="mini"
  140. @click="handleAdd"
  141. v-hasPermi="['thought:thoughtPlan:add']"
  142. >新增</el-button
  143. > -->
  144. </el-col>
  145. <el-col :span="1.5">
  146. <!-- <el-button
  147. type="success"
  148. plain
  149. icon="el-icon-edit"
  150. size="mini"
  151. :disabled="single"
  152. @click="handleUpdate"
  153. v-hasPermi="['thought:thoughtPlan:edit']"
  154. >修改</el-button
  155. > -->
  156. </el-col>
  157. <el-col :span="1.5">
  158. <!-- <el-button
  159. type="danger"
  160. plain
  161. icon="el-icon-delete"
  162. size="mini"
  163. :disabled="multiple"
  164. @click="handleDelete"
  165. v-hasPermi="['thought:thoughtPlan:remove']"
  166. >删除</el-button
  167. > -->
  168. </el-col>
  169. <el-col :span="1.5">
  170. <!-- <el-button
  171. type="warning"
  172. plain
  173. icon="el-icon-download"
  174. size="mini"
  175. :loading="exportLoading"
  176. @click="handleExport"
  177. v-hasPermi="['thought:thoughtPlan:export']"
  178. >导出</el-button
  179. > -->
  180. </el-col>
  181. <!-- </el-row> -->
  182. <el-col :span="20" :xs="24">
  183. <el-table
  184. v-loading="loading"
  185. :header-cell-style="{ background: '#003C69', color: 'white' }"
  186. :data="thoughtPlanList"
  187. max-width="10"
  188. @selection-change="handleSelectionChange"
  189. >
  190. <el-table-column type="selection" width="55" align="center" />
  191. <el-table-column label="序号" align="center" type="index" />
  192. <!-- <el-table-column label="主键id" align="center" prop="id" /> -->
  193. <el-table-column label="计划名称" align="center" prop="planName" />
  194. <el-table-column
  195. label="计划简介"
  196. align="center"
  197. prop="planIntroduction"
  198. show-overflow-tooltip
  199. />
  200. <el-table-column
  201. label="计划开始时间"
  202. align="center"
  203. prop="planStartTime"
  204. width="120"
  205. >
  206. <template slot-scope="scope">
  207. <span>{{
  208. parseTime(scope.row.planStartTime, "{y}-{m}-{d}")
  209. }}</span>
  210. </template>
  211. </el-table-column>
  212. <el-table-column
  213. label="计划结束时间"
  214. align="center"
  215. prop="planEndTime"
  216. width="120"
  217. >
  218. <template slot-scope="scope">
  219. <span>{{ parseTime(scope.row.planEndTime, "{y}-{m}-{d}") }}</span>
  220. </template>
  221. </el-table-column>
  222. <el-table-column label="计划个数" align="center" prop="planNumber" />
  223. <el-table-column
  224. label="需响应计划数"
  225. align="center"
  226. prop="planNumber"
  227. />
  228. <el-table-column
  229. label="已响应计划数"
  230. align="center"
  231. prop="responseNumber"
  232. />
  233. <el-table-column label="计划状态" align="center" prop="state">
  234. <template slot-scope="scope">
  235. <span v-if="scope.row.state == '0'" style="color: #00eaff"
  236. >未响应</span
  237. >
  238. <span v-if="scope.row.state == '1'" style="color: #13ce66"
  239. >已完成</span
  240. >
  241. <span v-if="scope.row.state == '2'" style="color: #ffba00"
  242. >已审批</span
  243. >
  244. <span
  245. v-if="scope.row.state == '3'"
  246. style="color: #ff4949"
  247. :title="scope.row.reasons"
  248. >已驳回</span
  249. >
  250. <span v-if="scope.row.state == '4'" style="color: #00eaff"
  251. >进行中</span
  252. >
  253. </template>
  254. </el-table-column>
  255. <el-table-column
  256. label="创建时间"
  257. align="center"
  258. prop="createTime"
  259. width="120"
  260. >
  261. <template slot-scope="scope">
  262. <span>{{ parseTime(scope.row.createTime, "{y}-{m}-{d}") }}</span>
  263. </template>
  264. </el-table-column>
  265. <el-table-column
  266. fixed="right"
  267. width="200"
  268. label="操作"
  269. align="center"
  270. class-name="small-padding fixed-width"
  271. >
  272. <template slot-scope="scope">
  273. <el-button
  274. v-if="scope.row.state == '1'"
  275. size="btc"
  276. type="text"
  277. @click="handleUpdate1(scope.row)"
  278. v-hasPermi="['thought:responses:edit']"
  279. >审批</el-button
  280. >
  281. <el-button
  282. size="btc"
  283. type="text"
  284. @click="handleUpdate(scope.row)"
  285. v-hasPermi="['thought:responses:edit']"
  286. >查看</el-button
  287. >
  288. <!-- <el-button
  289. size="btc"
  290. type="text"
  291. @click="handleDelete(scope.row)"
  292. v-hasPermi="['thought:thoughtPlan:remove']"
  293. >删除</el-button
  294. > -->
  295. </template>
  296. </el-table-column>
  297. </el-table>
  298. <pagination
  299. v-show="total > 0"
  300. :total="total"
  301. :page.sync="queryParams.pageNum"
  302. :limit.sync="queryParams.pageSize"
  303. @pagination="getList"
  304. />
  305. </el-col>
  306. </el-row>
  307. <!-- 添加或修改月教育计划对话框 -->
  308. <el-dialog
  309. :title="title"
  310. :visible.sync="open"
  311. width="1200px"
  312. append-to-body
  313. >
  314. <!-- <el-form
  315. ref="form"
  316. :model="form"
  317. :rules="rules"
  318. :inline="true"
  319. label-width="100px"
  320. >
  321. <div class="jiben">文档信息</div>
  322. <el-form-item label="计划名称" prop="planName">
  323. <el-input v-model="form.planName" placeholder="请输入计划名称" />
  324. </el-form-item>
  325. <el-form-item label="计划开始时间" prop="planStartTime">
  326. <el-date-picker
  327. clearable
  328. size="small"
  329. v-model="form.planStartTime"
  330. type="date"
  331. value-format="yyyy-MM-dd"
  332. placeholder="选择计划开始时间"
  333. ></el-date-picker>
  334. </el-form-item>
  335. <el-form-item label="计划结束时间" prop="planEndTime">
  336. <el-date-picker
  337. clearable
  338. size="small"
  339. v-model="form.planEndTime"
  340. type="date"
  341. value-format="yyyy-MM-dd"
  342. placeholder="选择计划结束时间"
  343. ></el-date-picker>
  344. </el-form-item>
  345. <el-form-item label="计划简介" prop="planIntroduction">
  346. <el-input
  347. type="textarea"
  348. v-model="form.planIntroduction"
  349. placeholder="请输入计划简介"
  350. />
  351. </el-form-item>
  352. <div class="jiben">计划条数</div>
  353. <div class="jiHua">
  354. <el-form v-for="(item1, e) in checkShop" :key="e">
  355. <el-form-item prop="remark">
  356. <el-input
  357. type="textarea"
  358. v-model="form.planIntroduction"
  359. placeholder="请输入计划详情"
  360. />
  361. <el-radio v-model="radio" label="1">是否需要响应</el-radio>
  362. <el-button
  363. type="primary"
  364. icon="el-icon-plus"
  365. size="mini"
  366. @click="addForms"
  367. v-if="e == checkShop.length - 1"
  368. ></el-button>
  369. <el-button
  370. type="primary"
  371. icon="el-icon-delete"
  372. size="mini"
  373. v-if="e > 0"
  374. @click="delForms(e)"
  375. ></el-button>
  376. </el-form-item>
  377. </el-form>
  378. </div>
  379. <div class="jiben">文件</div>
  380. <el-form-item>
  381. <FileUpload v-model="form.fileName" />
  382. </el-form-item>
  383. </el-form> -->
  384. <div slot="footer" class="dialog-footer">
  385. <el-button type="primary" @click="submitForm">确 定</el-button>
  386. <el-button @click="cancel">取 消</el-button>
  387. </div>
  388. </el-dialog>
  389. <!-- 审批月教育计划响应对话框 -->
  390. <el-dialog
  391. title="审批月教育计划"
  392. :visible.sync="open2"
  393. width="1064px"
  394. append-to-body
  395. :close-on-click-modal="false"
  396. >
  397. <el-form
  398. ref="form2"
  399. :model="form"
  400. :rules="rules2"
  401. :inline="true"
  402. label-width="100px"
  403. >
  404. <div class="jiben">文档信息</div>
  405. <el-form-item label="计划名称" prop="planName">
  406. <el-input
  407. v-model="form.planName"
  408. placeholder="请输入计划名称"
  409. readonly
  410. />
  411. </el-form-item>
  412. <el-form-item label="计划开始时间" prop="planStartTime">
  413. <el-date-picker
  414. clearable
  415. size="small"
  416. v-model="form.planStartTime"
  417. type="date"
  418. value-format="yyyy-MM-dd"
  419. placeholder="选择计划开始时间"
  420. readonly
  421. ></el-date-picker>
  422. </el-form-item>
  423. <el-form-item label="计划结束时间" prop="planEndTime">
  424. <el-date-picker
  425. clearable
  426. size="small"
  427. v-model="form.planEndTime"
  428. type="date"
  429. value-format="yyyy-MM-dd"
  430. placeholder="选择计划结束时间"
  431. readonly
  432. ></el-date-picker>
  433. </el-form-item>
  434. <div class="jiben">计划简介</div>
  435. <el-form-item label="" prop="planIntroduction">
  436. <el-input
  437. type="textarea"
  438. v-model="form.planIntroduction"
  439. placeholder="请输入计划简介"
  440. readonly
  441. />
  442. </el-form-item>
  443. <div class="jiben">计划条数</div>
  444. <div class="jiHua">
  445. <el-form v-for="(item, e) in checkShop" :key="e">
  446. <el-form-item prop="remark">
  447. <el-input
  448. type="textarea"
  449. v-model="item.planContent"
  450. placeholder="请输入计划详情"
  451. readonly
  452. />
  453. </el-form-item>
  454. </el-form>
  455. </div>
  456. <div class="jiben" v-if="planResponsefus.length != 0">文件</div>
  457. <el-form v-for="(item, i) in planResponsefus" :key="i">
  458. <el-form-item prop="file">
  459. <el-input
  460. label="附件名称"
  461. v-model="item.fileName"
  462. style="width: 260px"
  463. readonly
  464. />
  465. <a
  466. :href="item.filePath"
  467. download
  468. title="下载"
  469. style="color: white; margin-left: -58px"
  470. class="downloadfile"
  471. >下载附件</a
  472. >
  473. </el-form-item>
  474. </el-form>
  475. <div class="jiben">审批驳回原因</div>
  476. <el-form-item prop="reasons">
  477. <el-input v-model="form.reasons" type="textarea" />
  478. </el-form-item>
  479. </el-form>
  480. <div slot="footer" class="dialog-footer">
  481. <el-button type="primary" @click="submitForm1">通过</el-button>
  482. <el-button @click="submitFormBoHui" size="btn">驳回</el-button>
  483. </div>
  484. </el-dialog>
  485. <!-- 查看月教育计划响应对话框 -->
  486. <el-dialog
  487. title="查看月教育计划"
  488. :visible.sync="open3"
  489. width="1064px"
  490. append-to-body
  491. :close-on-click-modal="false"
  492. >
  493. <el-form
  494. ref="form3"
  495. :model="form"
  496. :rules="rules3"
  497. :inline="true"
  498. label-width="100px"
  499. >
  500. <div class="jiben">文档信息</div>
  501. <el-form-item label="计划名称" prop="planName">
  502. <el-input
  503. v-model="form.planName"
  504. placeholder="请输入计划名称"
  505. readonly
  506. />
  507. </el-form-item>
  508. <el-form-item label="计划开始时间" prop="planStartTime">
  509. <el-date-picker
  510. clearable
  511. size="small"
  512. v-model="form.planStartTime"
  513. type="date"
  514. value-format="yyyy-MM-dd"
  515. placeholder="选择计划开始时间"
  516. readonly
  517. ></el-date-picker>
  518. </el-form-item>
  519. <el-form-item label="计划结束时间" prop="planEndTime">
  520. <el-date-picker
  521. clearable
  522. size="small"
  523. v-model="form.planEndTime"
  524. type="date"
  525. value-format="yyyy-MM-dd"
  526. placeholder="选择计划结束时间"
  527. readonly
  528. ></el-date-picker>
  529. </el-form-item>
  530. <div class="jiben">计划简介</div>
  531. <el-form-item label="" prop="planIntroduction">
  532. <el-input
  533. type="textarea"
  534. v-model="form.planIntroduction"
  535. placeholder="请输入计划简介"
  536. readonly
  537. />
  538. </el-form-item>
  539. <div class="jiben">计划条数</div>
  540. <div class="jiHua">
  541. <el-form v-for="(item, e) in checkShop" :key="e">
  542. <el-form-item prop="remark">
  543. <el-input
  544. type="textarea"
  545. v-model="item.planContent"
  546. placeholder="请输入计划详情"
  547. readonly
  548. />
  549. <span style="color: #fff" v-if="item.isresponse == '1'"
  550. >此条计划需各单位配合执行</span
  551. >
  552. <span style="color: #fff" v-if="item.isresponse == '0'"
  553. >此条计划非必要,各单位根据实际执行</span
  554. >
  555. </el-form-item>
  556. </el-form>
  557. </div>
  558. <div class="jiben" v-if="planResponsefus.length != 0">文件</div>
  559. <el-form v-for="(item, i) in planResponsefus" :key="i">
  560. <el-form-item prop="file">
  561. <el-input
  562. label="附件名称"
  563. v-model="item.fileName"
  564. style="width: 260px"
  565. readonly
  566. />
  567. <a
  568. :href="item.filePath"
  569. download
  570. title="下载"
  571. style="color: white; margin-left: -58px"
  572. class="downloadfile"
  573. >下载附件</a
  574. >
  575. </el-form-item>
  576. </el-form>
  577. </el-form>
  578. </el-dialog>
  579. </div>
  580. </template>
  581. <script>
  582. import {
  583. listResponses,
  584. getResponses,
  585. delResponses,
  586. addResponses,
  587. updateResponses,
  588. exportResponses,
  589. } from "@/api/thought/responses";
  590. import { getWeiShu } from "@/api/grassrootsregistration/bdglmeeting";
  591. export default {
  592. name: "responses",
  593. data() {
  594. return {
  595. // 遮罩层
  596. loading: true,
  597. tiem: null,
  598. // 导出遮罩层
  599. exportLoading: false,
  600. url: process.env.VUE_APP_BASE_API,
  601. // 选中数组
  602. ids: [],
  603. // 非单个禁用
  604. single: true,
  605. // 非多个禁用
  606. multiple: true,
  607. // 显示搜索条件
  608. showSearch: true,
  609. // 总条数
  610. total: 0,
  611. // 月教育计划表格数据
  612. thoughtPlanList: [],
  613. // 弹出层标题
  614. title: "",
  615. // 是否显示弹出层
  616. open: false,
  617. // 查询参数
  618. queryParams: {
  619. pageNum: 1,
  620. pageSize: 10,
  621. planName: null,
  622. planStartTime: null,
  623. planEndTime: null,
  624. planIntroduction: null,
  625. filePath: null,
  626. fileName: null,
  627. createName: null,
  628. createId: null,
  629. planNumber: null,
  630. responseNumber: null,
  631. unitId: null,
  632. state: null,
  633. },
  634. // 表单参数
  635. form: {},
  636. // 表单校验
  637. rules: {},
  638. // 左侧树形
  639. deptOptions: [],
  640. //左侧时间选择
  641. pickerOptions: {
  642. disabledDate(time) {
  643. return time.getTime() > Date.now();
  644. },
  645. },
  646. // 树形配置
  647. defaultProps: {
  648. children: "children",
  649. label: "label",
  650. },
  651. //添加计划条数表格为空
  652. checkShop: [
  653. {
  654. planContent: null,
  655. responseStatus: null,
  656. },
  657. ],
  658. radio: "",
  659. // 查看弹出层的显示与隐藏
  660. open3: false,
  661. rules3: {},
  662. files: [],
  663. // 下载文件
  664. planResponsefus: [],
  665. // 审批弹出层的显示与隐藏
  666. open2: false,
  667. rules2: {
  668. reasons: [
  669. { required: true, message: "请输入驳回原因", trigger: "blur" },
  670. ],
  671. },
  672. };
  673. },
  674. created() {
  675. this.getList();
  676. this.treeselect();
  677. },
  678. methods: {
  679. // 审批确定提交操作
  680. submitForm1() {
  681. if (this.form.id != null) {
  682. this.form.state = "2";
  683. // console.log(this.form);
  684. updateResponses(this.form).then((response) => {
  685. this.$modal.msgSuccess("审批成功");
  686. this.open2 = false;
  687. this.getList();
  688. });
  689. }
  690. },
  691. // 驳回提交操作
  692. submitFormBoHui() {
  693. this.$refs["form2"].validate((valid) => {
  694. if (valid) {
  695. if (this.form.id != null) {
  696. this.form.state = "3";
  697. // console.log(this.form);
  698. updateResponses(this.form).then((response) => {
  699. this.$modal.msgSuccess("审批成功");
  700. this.open2 = false;
  701. this.getList();
  702. });
  703. }
  704. }
  705. });
  706. },
  707. // 审批按钮操作
  708. handleUpdate1(row) {
  709. this.reset();
  710. const id = row.id || this.ids;
  711. getResponses(id).then((response) => {
  712. this.form = response.data;
  713. this.form.reasons = null;
  714. this.checkShop = response.data.responseContents;
  715. response.data.planResponsefus.forEach((element) => {
  716. element.name = element.fileName;
  717. element.url = element.filePath;
  718. });
  719. // 附件下载的路径拼接
  720. if (response.data.planResponsefus.length != 0) {
  721. this.planResponsefus = response.data.planResponsefus;
  722. }
  723. this.planResponsefus.forEach((item) => {
  724. item.filePath = process.env.VUE_APP_BASE_API + item.filePath;
  725. });
  726. this.open2 = true;
  727. });
  728. },
  729. // 增加对话框
  730. addForms() {
  731. this.checkShop.push({
  732. planContent: null,
  733. responseStatus: null,
  734. });
  735. },
  736. // 删除对话框
  737. delForms(i) {
  738. this.checkShop.splice(i, 1);
  739. },
  740. /** 查询月教育计划列表 */
  741. getList() {
  742. this.loading = true;
  743. listResponses(this.queryParams).then((response) => {
  744. this.thoughtPlanList = response.rows;
  745. this.total = response.total;
  746. this.loading = false;
  747. });
  748. },
  749. // 取消按钮
  750. cancel() {
  751. this.open = false;
  752. this.reset();
  753. },
  754. // 表单重置
  755. reset() {
  756. this.form = {
  757. id: null,
  758. planName: null,
  759. planStartTime: null,
  760. planEndTime: null,
  761. planIntroduction: null,
  762. filePath: null,
  763. fileName: null,
  764. createTime: null,
  765. updateTime: null,
  766. createName: null,
  767. createId: null,
  768. remark: null,
  769. planNumber: null,
  770. responseNumber: null,
  771. unitId: null,
  772. state: null,
  773. };
  774. this.resetForm("form");
  775. },
  776. /** 搜索按钮操作 */
  777. handleQuery() {
  778. this.queryParams.pageNum = 1;
  779. this.getList();
  780. },
  781. /** 重置按钮操作 */
  782. resetQuery() {
  783. this.resetForm("queryForm");
  784. this.handleQuery();
  785. },
  786. // 多选框选中数据
  787. handleSelectionChange(selection) {
  788. this.ids = selection.map((item) => item.id);
  789. this.single = selection.length !== 1;
  790. this.multiple = !selection.length;
  791. },
  792. /** 新增按钮操作 */
  793. handleAdd() {
  794. this.reset();
  795. this.open = true;
  796. this.title = "添加月教育计划";
  797. },
  798. /** 查看按钮操作(修改) */
  799. handleUpdate(row) {
  800. this.reset();
  801. const id = row.id || this.ids;
  802. getResponses(id).then((response) => {
  803. this.form = response.data;
  804. this.checkShop = response.data.responseContents;
  805. response.data.planResponsefus.forEach((element) => {
  806. element.name = element.fileName;
  807. element.url = element.filePath;
  808. });
  809. // 附件下载的路径拼接
  810. if (response.data.planResponsefus.length != 0) {
  811. this.planResponsefus = response.data.planResponsefus;
  812. }
  813. this.planResponsefus.forEach((item) => {
  814. item.filePath = process.env.VUE_APP_BASE_API + item.filePath;
  815. });
  816. this.open3 = true;
  817. // this.title = "修改月教育计划";
  818. });
  819. },
  820. /** 提交按钮 */
  821. submitForm() {
  822. this.$refs["form"].validate((valid) => {
  823. if (valid) {
  824. if (this.form.id != null) {
  825. updateResponses(this.form).then((response) => {
  826. this.$modal.msgSuccess("修改成功");
  827. this.open = false;
  828. this.getList();
  829. });
  830. } else {
  831. addResponses(this.form).then((response) => {
  832. this.$modal.msgSuccess("新增成功");
  833. this.open = false;
  834. this.getList();
  835. });
  836. }
  837. }
  838. });
  839. },
  840. /** 删除按钮操作 */
  841. handleDelete(row) {
  842. const ids = row.id || this.ids;
  843. this.$modal
  844. .confirm("是否确认删除月教育计划的数据项?")
  845. .then(function () {
  846. return delResponses(ids);
  847. })
  848. .then(() => {
  849. this.getList();
  850. this.$modal.msgSuccess("删除成功");
  851. })
  852. .catch(() => {});
  853. },
  854. /** 导出按钮操作 */
  855. handleExport() {
  856. const queryParams = this.queryParams;
  857. this.$modal
  858. .confirm("是否确认导出所有月教育计划数据项?")
  859. .then(() => {
  860. this.exportLoading = true;
  861. return exportResponses(queryParams);
  862. })
  863. .then((response) => {
  864. this.$download.name(response.msg);
  865. this.exportLoading = false;
  866. })
  867. .catch(() => {});
  868. },
  869. // 获取部门数据
  870. getShuJu(data) {
  871. exportBdgShuju(data).then((res) => {
  872. this.DataTime = data;
  873. this.registrationData = res;
  874. this.cg = res.cg;
  875. this.sb = res.sb;
  876. this.tiems = res.time;
  877. });
  878. },
  879. // 搜索时间触发
  880. shiJian(data) {
  881. this.queryParams.diaryTime = data;
  882. this.timeDate = data;
  883. this.getList();
  884. this.getShuJu(data);
  885. },
  886. // 获取外面部门树形
  887. treeselect() {
  888. getWeiShu().then((res) => {
  889. this.deptOptions = res.data;
  890. });
  891. },
  892. //外面树形选择搜索
  893. handleNodeClick(data) {
  894. this.queryParams.unitId = data.id;
  895. this.getList();
  896. },
  897. },
  898. };
  899. </script>
  900. <style scoped>
  901. ::v-deep .el-pagination__sizes .el-input__suffix {
  902. right: 6px;
  903. }
  904. ::v-deep .ql-snow .ql-picker-options .ql-picker-item:focus {
  905. outline: none !important;
  906. }
  907. ::v-deep .ql-snow .ql-picker:focus {
  908. outline: none !important;
  909. }
  910. ::v-deep .ql-toolbar.ql-snow .ql-picker.ql-expanded .ql-picker-label:focus {
  911. outline: none !important;
  912. }
  913. ::v-deep .ql-toolbar.ql-snow .ql-picker-label {
  914. border: none !important;
  915. }
  916. ::v-deep .ql-formats:focus {
  917. outline: none !important;
  918. }
  919. ::v-deep .ql-toolbar.ql-snow .ql-picker.ql-expanded .ql-picker-options {
  920. border-color: none !important;
  921. color: black !important;
  922. }
  923. /* normal */
  924. ::v-deep .ql-active {
  925. outline: none !important;
  926. }
  927. /* 输入框 */
  928. ::v-deep .el-dialog .el-input__inner {
  929. background-color: #004d86 !important;
  930. width: 176px;
  931. color: white;
  932. margin-right: 20px;
  933. border: 1px solid white !important;
  934. }
  935. ::v-deep .el-input__inner {
  936. border: 1px solid white !important;
  937. }
  938. /* 表格样式 */
  939. ::v-deep .el-table .el-table__header-wrapper th {
  940. background-color: #004d86 !important;
  941. color: white;
  942. }
  943. /* 标题弹框 */
  944. ::v-deep .el-dialog__title {
  945. color: white;
  946. /* border-bottom: 1px solid white; */
  947. }
  948. /* 标题下划线 */
  949. ::v-deep .el-dialog__header {
  950. border-bottom: 1px solid white;
  951. }
  952. /* 日历样式 */
  953. ::v-deep .el-date-editor .el-input__inner {
  954. height: 36px !important;
  955. line-height: 36px;
  956. }
  957. ::v-deep .datesend .el-form-item__label {
  958. width: 115px !important;
  959. }
  960. /* 会议文本域样式 */
  961. ::v-deep .el-form-item__content .el-textarea {
  962. width: 1000px;
  963. /* height: 80px !important; */
  964. }
  965. ::v-deep .el-form-item__content .el-textarea .el-textarea__inner {
  966. /* width: 1000px; */
  967. width: 912px;
  968. min-height: 80px !important;
  969. }
  970. ::v-deep .el-dialog__body {
  971. padding-left: 76px !important;
  972. padding-right: 0px !important;
  973. padding-bottom: 20px !important;
  974. }
  975. /* 富文本内容 */
  976. /* ::v-deep .editor{
  977. width: 1010px;
  978. color: white;
  979. } */
  980. /* 富文本 */
  981. ::v-deep .ql-snow .ql-fill,
  982. .ql-snow .ql-stroke.ql-fill {
  983. fill: #fff !important;
  984. }
  985. ::v-deep .ql-snow .ql-stroke {
  986. stroke: #fff !important;
  987. }
  988. ::v-deep .ql-snow .ql-picker {
  989. color: #fff !important;
  990. }
  991. ::v-deep .ql-editor ql-blank {
  992. color: #fff !important;
  993. }
  994. ::v-deep .ql-snow .ql-picker-label {
  995. position: absolute;
  996. bottom: 5px;
  997. }
  998. ::v-deep .ql-snow .ql-picker:not(.ql-color-picker):not(.ql-icon-picker) svg {
  999. margin-top: -2px;
  1000. }
  1001. ::v-deep .ql-toolbar.ql-snow {
  1002. display: flex;
  1003. justify-content: space-around;
  1004. }
  1005. /* 富文本删除功能 */
  1006. /* 富文本删除功能 */
  1007. ::v-deep .ql-blockquote {
  1008. display: none !important;
  1009. }
  1010. ::v-deep .ql-strike {
  1011. display: none !important;
  1012. }
  1013. ::v-deep .ql-script {
  1014. display: none !important;
  1015. }
  1016. ::v-deep .ql-code-block {
  1017. display: none !important;
  1018. }
  1019. ::v-deep .ql-direction {
  1020. display: none !important;
  1021. }
  1022. .ql-toolbar.ql-snow .ql-formats {
  1023. margin-right: 7px !important;
  1024. }
  1025. ::v-deep .el-input__inner {
  1026. /* height: 36px !important; */
  1027. color: white;
  1028. background-color: #00365f !important;
  1029. }
  1030. /* 文字多余部分省略 */
  1031. ::v-deep .el-table__cell .cell {
  1032. overflow: hidden;
  1033. text-overflow: ellipsis;
  1034. white-space: nowrap;
  1035. }
  1036. ::v-deep .data .el-date-editor.el-input {
  1037. width: 100%;
  1038. border: none !important;
  1039. }
  1040. ::v-deep .data .el-input__inner {
  1041. width: 100% !important;
  1042. border: none !important;
  1043. }
  1044. ::v-deep .data .el-input--medium .el-input__icon {
  1045. line-height: 36px;
  1046. position: absolute;
  1047. right: -223px;
  1048. top: 2px;
  1049. }
  1050. ::v-deep .data .el-input__inner {
  1051. background-color: transparent !important;
  1052. color: #fff;
  1053. text-align: center;
  1054. margin-top: 2px;
  1055. }
  1056. ::v-deep .data .el-input__suffix {
  1057. position: absolute;
  1058. right: 281px;
  1059. }
  1060. .app-container .box-lfet .data {
  1061. height: 40px;
  1062. background: #003156;
  1063. margin-bottom: 12px;
  1064. color: #fff;
  1065. display: flex;
  1066. font-size: 13px;
  1067. line-height: 25px;
  1068. position: relative;
  1069. }
  1070. .box-lfet .data p {
  1071. position: absolute;
  1072. top: -5px;
  1073. left: 15px;
  1074. }
  1075. .box-lfet .data .a1 {
  1076. width: 128px;
  1077. height: 26px;
  1078. background: rgba(23, 74, 112, 0.4);
  1079. border-radius: 13px;
  1080. position: absolute;
  1081. top: 7px;
  1082. left: 60px;
  1083. }
  1084. ::v-deep .data .el-date-editor.el-input {
  1085. width: 100%;
  1086. border: none;
  1087. }
  1088. ::v-deep .data .el-input__inner {
  1089. width: 100% !important;
  1090. border: none;
  1091. }
  1092. ::v-deep .data .el-input--medium .el-input__icon {
  1093. line-height: 36px;
  1094. position: absolute;
  1095. right: -223px;
  1096. top: 2px;
  1097. }
  1098. ::v-deep .data .el-input__inner {
  1099. background-color: transparent;
  1100. color: #fff;
  1101. text-align: center;
  1102. margin-top: 2px;
  1103. }
  1104. ::v-deep .data .el-input__suffix {
  1105. position: absolute;
  1106. right: 281px;
  1107. }
  1108. /* 头部样式 */
  1109. .dadui {
  1110. height: 40px;
  1111. background: #003156;
  1112. /* border-bottom: 1px solid #718A9D ; */
  1113. background-image: url(../../../images/矩形底部边框.png);
  1114. background-repeat: no-repeat;
  1115. background-position: 0px 39px;
  1116. font-size: 16px;
  1117. color: #1d96ff;
  1118. }
  1119. .dadui img {
  1120. margin: 10px 10px 0px 10px;
  1121. }
  1122. .data p {
  1123. position: absolute;
  1124. top: -5px;
  1125. left: 15px;
  1126. }
  1127. .data .a1 {
  1128. width: 128px;
  1129. height: 26px;
  1130. background: rgba(23, 74, 112, 0.4);
  1131. border-radius: 13px;
  1132. position: absolute;
  1133. top: 7px;
  1134. left: 60px;
  1135. }
  1136. /* 划过效果 */
  1137. ::v-deep .el-tree-node__content:hover {
  1138. /* color: #fff; */
  1139. background-color: #003156;
  1140. background-image: url("../../../assets/images/选中.png");
  1141. background-size: 100% 100%;
  1142. background-repeat: no-repeat;
  1143. }
  1144. .app-container {
  1145. display: flex;
  1146. }
  1147. /* 左侧树状盒子 */
  1148. .app-container .box-lfet {
  1149. width: 15%;
  1150. min-height: 740px;
  1151. /* background: #003156; */
  1152. /* padding: 10px; */
  1153. margin-right: 10px;
  1154. /* border: 1px solid white; */
  1155. }
  1156. /* 右侧内容盒子 */
  1157. .app-container .box-right {
  1158. flex: 1;
  1159. }
  1160. .app-container .box-lfet .data {
  1161. height: 40px;
  1162. background: #003156;
  1163. margin-bottom: 12px;
  1164. color: #fff;
  1165. display: flex;
  1166. font-size: 13px;
  1167. line-height: 25px;
  1168. position: relative;
  1169. }
  1170. .el-tree {
  1171. background: #003156;
  1172. color: #fff;
  1173. margin-right: 2px;
  1174. padding-top: 7px;
  1175. }
  1176. ::v-deep .el-dialog {
  1177. background-color: #004d86 !important;
  1178. }
  1179. ::v-deep .el-input__suffix {
  1180. right: 60px;
  1181. }
  1182. ::v-deep .el-tree-node__content {
  1183. height: 32px;
  1184. }
  1185. ::v-deep
  1186. .el-tree--highlight-current
  1187. .el-tree-node.is-current
  1188. > .el-tree-node__content {
  1189. height: 32px;
  1190. color: #fff !important;
  1191. background-color: #003156;
  1192. background-image: url("../../../assets/images/选中.png");
  1193. background-size: 100% 100%;
  1194. background-repeat: no-repeat;
  1195. }
  1196. ::v-deep .canjiaren .el-input__inner {
  1197. width: 560px;
  1198. }
  1199. /* 计划附件 */
  1200. ::v-deep .el-upload__tip {
  1201. color: white;
  1202. position: absolute;
  1203. top: -5px;
  1204. width: 500px;
  1205. left: 90px;
  1206. color: white;
  1207. }
  1208. ::v-deep .el-link.el-link--default {
  1209. color: white;
  1210. text-indent: 0.5em;
  1211. }
  1212. ::v-deep .el-table__fixed-right {
  1213. height: 100% !important;
  1214. }
  1215. ::v-deep .el-dialog__footer {
  1216. margin-right: 54px;
  1217. }
  1218. ::v-deep th {
  1219. background: #004d86 !important;
  1220. }
  1221. /* 下载按钮 */
  1222. .downloadfile {
  1223. border: 1px solid white;
  1224. display: inline-block;
  1225. width: 100px;
  1226. height: 36px;
  1227. border-radius: 5px;
  1228. line-height: 33px;
  1229. text-align: center;
  1230. }
  1231. /* 卡片样式 */
  1232. .app-container {
  1233. height: calc(100vh - 108px) !important;
  1234. }
  1235. </style>