daea2d9d79be6ae44dc91440cc59c55a3018476f.svn-base 74 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773
  1. <template>
  2. <!-- 问题处置-2020人饮问题编辑 -->
  3. <div style="height:100%;width:100%" id="wenTiContainer_sk">
  4. <el-container>
  5. <el-aside
  6. width="318px"
  7. style="border-right:2px solid #d5d5ff;float:left"
  8. :style="{'max-height':testHeight+'px','height':testHeight+'px'}"
  9. v-show="!rowId"
  10. >
  11. <wt-left-tree orgType="084" @treeNodeClickHandler="treeNodeClickHandler" @changeYear="changeYear"
  12. @organList="getAllTreeData" @changeTabType="changeTabType"></wt-left-tree>
  13. </el-aside>
  14. <!-- 主要窗口 -->
  15. <el-main style="margin:0px;padding:0px;overflow-y:hidden;" class="shuiku" v-loading="exportLoading">
  16. <!-- <el-card> -->
  17. <div class="pages" :style="{'max-height':testHeight+'px'}">
  18. <!-- 为什么要根据rowId来判断过滤条件的显示或者隐藏? -->
  19. <div style="padding: 12px 0 0 0">
  20. <el-row type="flex" justify="space-between">
  21. <el-col :span="24">
  22. <el-form :inline="true" size="mini" class="demo-form-inline"
  23. style="padding-left: 10px;">
  24. <el-form-item label="行政区划:">
  25. <el-input
  26. resize="none"
  27. type="input"
  28. :rows="3"
  29. placeholder="请输入行政区划名称"
  30. v-model.trim="findParams.adFullName"
  31. clearable
  32. ></el-input>
  33. </el-form-item>
  34. <el-form-item label="督查对象名称:">
  35. <el-input
  36. resize="none"
  37. type="input"
  38. :rows="3"
  39. placeholder="请输入名称"
  40. v-model.trim="findParams.nm"
  41. clearable
  42. ></el-input>
  43. </el-form-item>
  44. </el-form>
  45. </el-col>
  46. </el-row>
  47. <el-row type="flex" justify="space-between" v-show="showExpandSearchPanel">
  48. <el-col :span="24">
  49. <el-form :inline="true" size="mini" class="demo-form-inline"
  50. style="padding-left: 10px;">
  51. <el-form-item label="问题类别:">
  52. <el-select v-model="findParams.inspPblmName" clearable placeholder="请选择">
  53. <el-option
  54. v-for="item in problemList"
  55. :key="item.guid"
  56. :label="item.inspPblmsName"
  57. :value="item.inspPblmsName"
  58. ></el-option>
  59. </el-select>
  60. </el-form-item>
  61. <el-form-item label="问题筛选:">
  62. <el-select v-model="pblscr" clearable placeholder="请选择">
  63. <el-option
  64. v-for="item in pblscrList"
  65. :key="item.value"
  66. :label="item.lable"
  67. :value="item.value"
  68. ></el-option>
  69. </el-select>
  70. </el-form-item>
  71. <el-form-item label="上报人员:">
  72. <el-input
  73. resize="none"
  74. type="input"
  75. :rows="3"
  76. placeholder="请输入名称"
  77. v-model.trim="findParams.persName"
  78. ></el-input>
  79. </el-form-item>
  80. <el-form-item label="发现时间:">
  81. <el-date-picker
  82. style="width: 200px;"
  83. v-model="value6"
  84. type="daterange"
  85. value-format="yyyy-MM-dd"
  86. range-separator="至"
  87. start-placeholder="开始日期"
  88. end-placeholder="结束日期"
  89. ></el-date-picker>
  90. </el-form-item>
  91. <el-form-item label="所在组:">
  92. <el-input
  93. resize="none"
  94. type="input"
  95. :rows="3"
  96. placeholder="请输入所在组名称"
  97. v-model.trim="pblscrGroup"
  98. clearable
  99. ></el-input>
  100. </el-form-item>
  101. <el-form-item label="是否包含多媒体文件:">
  102. <el-select v-model="findParams.hasVedio" clearable placeholder="请选择">
  103. <el-option
  104. v-for="item in hasVedio1"
  105. :key="item.value"
  106. :label="item.label"
  107. :value="item.value"
  108. ></el-option>
  109. </el-select>
  110. </el-form-item>
  111. <el-form-item label="问题督查状态:">
  112. <el-select v-model="findParams.state" clearable placeholder="请选择">
  113. <el-option
  114. v-for="item in stateList"
  115. :key="item.value"
  116. :label="item.label"
  117. :value="item.value"
  118. ></el-option>
  119. </el-select>
  120. </el-form-item>
  121. </el-form>
  122. </el-col>
  123. </el-row>
  124. <el-row type="flex" justify="space-between" style="border-top:1px solid #0014ff2e;">
  125. <el-col style='padding-bottom:10px;' :span="12">
  126. <el-button style="float:right;margin-right:10px;border: 1px solid #0014ff2e;
  127. border-radius: 0px 0px 5px 5px;border-top: 0px;" type="info" plain
  128. size="mini"
  129. @click="showExpandSearchPanel = !showExpandSearchPanel"
  130. >
  131. {{showExpandSearchPanel?'收起':'更多条件'}}
  132. <i class="el-icon-arrow-down el-icon--right" v-show="!showExpandSearchPanel"/>
  133. <i class="el-icon-arrow-up el-icon--right" v-show="showExpandSearchPanel"/>
  134. </el-button>
  135. </el-col>
  136. <el-col :span="12">
  137. <el-button
  138. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  139. type="success"
  140. @click="submitBtn"
  141. >问题提交
  142. </el-button>
  143. <el-button
  144. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  145. type="primary"
  146. icon="el-icon-search"
  147. @click="search"
  148. >&nbsp;查&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;询&nbsp;
  149. </el-button>
  150. <el-button
  151. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  152. type="success"
  153. icon="el-icon-download"
  154. @click="exportExcel"
  155. >导出EXCEL
  156. </el-button>
  157. <el-button
  158. v-if="isGd"
  159. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  160. type="success"
  161. icon="el-icon-download"
  162. @click="toForm"
  163. >导出一表一单
  164. </el-button>
  165. <shuiKuWentiPl v-if="showShuiKuTianBaoPl"
  166. :showShuiKuTianBaoPl="showShuiKuTianBaoPl"
  167. titleName="小水库"
  168. @closePlDialog="closePlDialog">
  169. </shuiKuWentiPl>
  170. </el-col>
  171. </el-row>
  172. </div>
  173. <!-- 查询展示 -->
  174. <div class="search" style="margin-top:10px;">
  175. <el-table
  176. v-loading="loading"
  177. border
  178. ref="multipleTable"
  179. :height="tableHeight"
  180. :data="searchResult"
  181. tooltip-effect="dark"
  182. style="width: 100%"
  183. @selection-change="handleSelectionChange"
  184. >
  185. <el-table-column
  186. type="selection"
  187. min-width="55">
  188. </el-table-column>
  189. <el-table-column align="center" type="index" label="序号" min-width="25">
  190. <template slot-scope="scope">{{ (currentPage - 1) * pageSize + (scope.$index + 1) }}
  191. </template>
  192. </el-table-column>
  193. <!-- <el-table-column header-align="center" align="center" min-width="140" prop="inspPblmName" label="小水库问题类别"></el-table-column> -->
  194. <el-table-column
  195. header-align="center"
  196. align="center"
  197. min-width="60"
  198. prop="province"
  199. label="省" v-if="isXj"
  200. show-overflow-tooltip
  201. ></el-table-column>
  202. <el-table-column
  203. header-align="center"
  204. align="center"
  205. min-width="60"
  206. prop="city"
  207. :label="ownAdName"
  208. show-overflow-tooltip
  209. ></el-table-column>
  210. <el-table-column
  211. header-align="center"
  212. align="center"
  213. min-width="60"
  214. prop="country"
  215. label="县"
  216. v-if="isXj"
  217. show-overflow-tooltip
  218. ></el-table-column>
  219. <el-table-column
  220. header-align="center"
  221. align="center"
  222. min-width="110"
  223. prop="nm"
  224. label="督查对象名称"
  225. show-overflow-tooltip
  226. ></el-table-column>
  227. <el-table-column
  228. header-align="center"
  229. align="center"
  230. min-width="140"
  231. prop="inspPblmName"
  232. label="督查问题类别"
  233. show-overflow-tooltip
  234. ></el-table-column>
  235. <el-table-column
  236. header-align="center"
  237. align="center"
  238. min-width="100"
  239. prop="checkPoint"
  240. label="检查项目"
  241. show-overflow-tooltip>
  242. </el-table-column>
  243. <el-table-column
  244. header-align="center"
  245. align="center"
  246. min-width="100"
  247. prop="pblmDescBz"
  248. label="问题描述"
  249. show-overflow-tooltip>
  250. </el-table-column>
  251. <el-table-column
  252. header-align="center"
  253. align="center"
  254. min-width="70"
  255. prop="persName"
  256. label="上报人"
  257. ></el-table-column>
  258. <el-table-column
  259. header-align="center"
  260. align="center"
  261. min-width="80"
  262. show-overflow-tooltip
  263. prop="orgNm"
  264. label="所在组"
  265. ></el-table-column>
  266. <el-table-column
  267. prop="collTime"
  268. label="上报时间"
  269. :formatter="timestampToTime"
  270. sortable
  271. align="center"
  272. min-width="110"
  273. show-overflow-tooltip
  274. ></el-table-column>
  275. <el-table-column
  276. header-align="center"
  277. align="center"
  278. min-width="150"
  279. prop="hasVedio"
  280. label="是否包含多媒体文件"
  281. >
  282. <template slot-scope="scope">
  283. <p v-if="scope.row.hasVedio == 1">是</p>
  284. <p v-if="scope.row.hasVedio == 0">否</p>
  285. </template>
  286. </el-table-column>
  287. <el-table-column
  288. header-align="center"
  289. align="center"
  290. min-width="100"
  291. prop="state"
  292. label="问题督查状态">
  293. <template slot-scope="scope">
  294. <p v-if="Number(scope.row.state) === 0"><span class="inspPblmCate"
  295. style="background: #F56C6C;">未提交</span>
  296. </p>
  297. <p v-if="scope.row.state == 2"><span class="inspPblmCate"
  298. style="background: #409EFF;">已提交</span>
  299. </p>
  300. <p v-if="scope.row.state == 3"><span class="inspPblmCate"
  301. style="background: #67C23A;">已发布</span>
  302. </p>
  303. </template>
  304. </el-table-column>
  305. <el-table-column
  306. fixed="right"
  307. label="操作"
  308. min-width="130"
  309. >
  310. <template slot-scope="scope">
  311. <!-- <span style="margin-right:10px;" v-if="ownPriv('manage')">-->
  312. <!-- <el-button icon="el-icon-s-flag" type="text" v-if="scope.row.quote == '1'" title="已被督查简报引用"-->
  313. <!-- @click="changeSfYy(scope.row.pblmId,1)"></el-button>-->
  314. <!-- <i class="el-icon-s-flag" v-else title="未被督查简报引用" @click="changeSfYy(scope.row.pblmId,0)"-->
  315. <!-- style="cursor: pointer;"></i>-->
  316. <!-- </span>-->
  317. <el-button icon="el-icon-view" title="查看详情" type="text"
  318. @click="showDetails(scope.row.pblmId)"></el-button>
  319. <el-button icon="el-icon-edit" type="text" title="修改问题"
  320. @click="changeSup(scope.row.pblmId)"
  321. v-if="ownPriv('manage')"></el-button>
  322. <el-button
  323. icon="el-icon-delete"
  324. type="text"
  325. v-if="ownPriv('manage')"
  326. title="删除问题" @click="removeSuperviseOne(scope.row.pblmId)"
  327. ></el-button>
  328. </template>
  329. </el-table-column>
  330. </el-table>
  331. <!-- 分页 -->
  332. <div class="paginationWarpper">
  333. <el-pagination
  334. class="paginationCenter"
  335. background
  336. @size-change="handleSizeChange"
  337. @current-change="search"
  338. :current-page.sync="currentPage"
  339. :page-sizes="[10, 20, 50, 100]"
  340. :page-size="pageSize"
  341. layout="total, sizes, prev, pager, next, jumper"
  342. :total="total"
  343. ></el-pagination>
  344. </div>
  345. </div>
  346. <!-- 详情弹框 -->
  347. <el-dialog
  348. class="outerDialog custom_dialog"
  349. title="问题详情"
  350. width="60%"
  351. v-if="supervisionDetailsVisible"
  352. :visible.sync="supervisionDetailsVisible"
  353. >
  354. <supervision-details ref="xianqing" :problemId="currentProblemId"
  355. :objType="84"></supervision-details>
  356. <span slot="footer">
  357. <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
  358. </span>
  359. </el-dialog>
  360. <!-- 删除的弹窗 -->
  361. <el-dialog class="deleteDialog" title="问题删除描述" :visible.sync="problemDeleteVisible">
  362. <Problem-delete
  363. ref="deleteMiaoShu"
  364. :deleteProblemId="deleteId"
  365. @deleteSuccess="deleteSuccess"
  366. ></Problem-delete>
  367. <span slot="footer">
  368. <el-button @click="problemDeleteVisible = false">返回</el-button>
  369. </span>
  370. </el-dialog>
  371. </div>
  372. </el-main>
  373. </el-container>
  374. <EditPicOnline
  375. ref="editPicWeakupEvnent"
  376. v-if="editPicDialog"
  377. :picUrl="picUrl"
  378. @cancelHandler="cancelHandler"
  379. @editPicData="editPicDataEvent"
  380. ></EditPicOnline>
  381. <el-dialog
  382. class="outerDialog custom_dialog"
  383. title="类型"
  384. width="20%"
  385. :visible.sync="isToFormVisible">
  386. <span>
  387. <p style="display: flex;align-items: center;">
  388. 类型 <el-select v-model="oneForm" placeHolder="请选择一表一单类型" style="width:calc(100% - 60px)!important;padding-left: 10px;">
  389. <el-option label="问题(现场)确认单" value="wtxcqrd-1"></el-option>
  390. <el-option label="问题提交单(流域机构督查办)" value="wttjd-2"></el-option>
  391. </el-select>
  392. </p>
  393. </span>
  394. <span slot="footer">
  395. <el-button type="primary" @click="toFormOk">确定</el-button>
  396. </span>
  397. </el-dialog>
  398. <!-- 修改组件 -->
  399. <problem-edit :editId="editId" @closeEditDialog="closeEditDialog" v-if="changeSupervisionVisible"
  400. :pType="pType"></problem-edit>
  401. </div>
  402. </template>
  403. <script>
  404. import axios from 'axios';
  405. import {
  406. deleteFileById,
  407. findProblemPageInfo,
  408. getSupervisdByID,
  409. showDetailsXq,
  410. submitUpload,
  411. updatelist,
  412. pblmSubmit
  413. } from "@api/duChaAPI.js";
  414. import {exportModel} from "@util/gw_exportModel";
  415. import request from "@util/gw_ajax_request.js";
  416. import elaudio from "@widget/elAudioShort.vue";
  417. import inuptWithDuChaTreeNode from "@widget/inuptWithDuChaTreeNode.vue";
  418. import inputWidthDuChaNodes from "@widget/inputWithDuChaNodes.vue";
  419. import inputWidthDuChaShuiKu from "@widget/inputWith_sk.vue";
  420. import problemDialog from "./problemDialog.vue";
  421. import shuiKuWentiPl from "./problemBatchImp/tongYongWenti_piliang.vue"
  422. import wtLeftTree from "./wtcz_lefttree.vue"
  423. import { hostUrl } from "@util/global_variable.js";
  424. export default {
  425. props: ["codeId", "rowId"],
  426. components: {
  427. upload: resolve => {
  428. require(["@widget/uploadFile.vue"], resolve);
  429. },
  430. //详情页
  431. supervisionDetails: resolve => {
  432. require(["../duChaWenTi/supervisionDetails_xskcxjg.vue"], resolve);
  433. },
  434. // 删除描述页
  435. ProblemDelete: resolve => {
  436. require(["./problemDelete.vue"], resolve);
  437. },
  438. EditPicOnline: resolve => {
  439. require(["@widget/EditPicOnline/EditPicOnline.vue"], resolve);
  440. },
  441. // addPicDialog: resolve => {
  442. // require(["./addPicDialog.vue"], resolve);
  443. // },
  444. elaudio: elaudio,
  445. inuptWithDuChaTreeNode: inuptWithDuChaTreeNode,
  446. inputWidthDuChaNodes: inputWidthDuChaNodes,
  447. inputWidthDuChaShuiKu: inputWidthDuChaShuiKu,
  448. problemDialog: problemDialog,
  449. shuiKuWentiPl: shuiKuWentiPl,
  450. wtLeftTree: wtLeftTree,
  451. // 修改问题
  452. problemEdit: resolve => {
  453. require(["../duChaWenTi/xskcxjgProblemModify.vue"], resolve);
  454. },
  455. },
  456. data() {
  457. var validatePass1 = (rules1, value, callback) => {
  458. if (this.newSupervision.startTime > this.newSupervision.endTime) {
  459. callback(new Error("结束时间不能早于开始时间"));
  460. } else {
  461. callback();
  462. }
  463. };
  464. var validatePass2 = (rules1, value, callback) => {
  465. let startTime = this.changeSupervision.startTime.slice(0, 10);
  466. if (startTime > this.changeSupervision.endTime) {
  467. callback(new Error("结束时间不能早于开始时间"));
  468. } else {
  469. callback();
  470. }
  471. };
  472. var divisionList = (rules1, value, callback) => {
  473. if (this.newGroup.divisionList.length) {
  474. callback();
  475. } else {
  476. callback(new Error("至少要添加一个地区"));
  477. }
  478. };
  479. return {
  480. oneForm:"wtxcqrd-1",
  481. isToFormVisible:false,
  482. ids:"",
  483. tabType: "0",//0全部,1当前数据,2历史数据
  484. editPicRefresh: true,
  485. showExpandSearchPanel: false,
  486. tableHeight: window.innerHeight - 291,
  487. globoId: "",
  488. addPicPanel: false,
  489. currentDate: new Date(),
  490. deleteId: "",
  491. treeNodeArray: [],
  492. treeNodeSelectVisible: false,
  493. adNodeArray: [],
  494. adNodeSelectVisible: false,
  495. areaSelectVisible: false,
  496. rsvrNodeArray: [],
  497. rsvrNodeSelectVisible: false,
  498. skSelectVisible: false,
  499. currentProblemId: "",
  500. updateIdXiuGai: "",
  501. rules1: {
  502. inspPblmName: [
  503. {
  504. required: true,
  505. message: "请输入问题名称",
  506. trigger: "blur"
  507. },
  508. {
  509. min: 1,
  510. max: 999,
  511. message: "不超过100字符",
  512. trigger: "blur"
  513. }
  514. ],
  515. inspPblmDesc: [
  516. {
  517. required: true,
  518. message: "请输入问题描述",
  519. trigger: "blur"
  520. }
  521. ],
  522. recPers: [
  523. {
  524. required: true,
  525. message: "请输入记录人",
  526. trigger: "blur"
  527. },
  528. {
  529. min: 1,
  530. max: 999,
  531. message: "不超过100字符",
  532. trigger: "blur"
  533. }
  534. ],
  535. objType: [
  536. {
  537. required: true,
  538. message: "请选择督查对象类型",
  539. trigger: "change"
  540. }
  541. ],
  542. objId: [
  543. {
  544. required: true,
  545. message: "请选择督查对象类型",
  546. trigger: "change"
  547. }
  548. ],
  549. inspPblmType: [
  550. {
  551. required: true,
  552. message: "请选择督查问题类型",
  553. trigger: "change"
  554. }
  555. ],
  556. dataStat: [
  557. {
  558. required: true,
  559. message: "请选择数据状态",
  560. trigger: "change"
  561. }
  562. ],
  563. collTime: [
  564. {
  565. required: true,
  566. message: "请选择采集时间",
  567. trigger: "change"
  568. }
  569. ],
  570. ifCasePblm: [
  571. {
  572. required: true,
  573. message: "请选择是否典型",
  574. trigger: "change"
  575. }
  576. ],
  577. pblmStat: [
  578. {
  579. required: true,
  580. message: "请选择问题类型",
  581. trigger: "change"
  582. }
  583. ],
  584. inspPblmCate: [
  585. {
  586. required: true,
  587. message: "请选择问题程度",
  588. trigger: "change"
  589. },
  590. {
  591. trigger: "change"
  592. }
  593. ]
  594. },
  595. dxdcAsideHeight: window.innerHeight - 220,
  596. maxHeight: window.innerHeight - 120,
  597. testHeight: window.innerHeight - 120,
  598. supervisionStateList: [
  599. {
  600. value: "0",
  601. label: "暂存"
  602. },
  603. {
  604. value: "1",
  605. label: "上报"
  606. }
  607. ],
  608. supervisionState: [
  609. {
  610. value: "0",
  611. label: "一般"
  612. },
  613. {
  614. value: "1",
  615. label: "较重"
  616. },
  617. {
  618. value: "2",
  619. label: "严重"
  620. },
  621. {
  622. value: "3",
  623. label: "特别严重"
  624. }
  625. ],
  626. supervision: [
  627. {
  628. value: "1",
  629. label: "是"
  630. },
  631. {
  632. value: "0",
  633. label: "否"
  634. }
  635. ],
  636. hasVedio1: [
  637. {
  638. value: "1",
  639. label: "是"
  640. },
  641. {
  642. value: "0",
  643. label: "否"
  644. }
  645. ],
  646. findUseOrgArray: [],
  647. areaInputValue: {},
  648. memberInputValue: {},
  649. multipleSelection: [], // 已选
  650. selectionType: {
  651. remove: 0,
  652. befor: 0,
  653. now: 0,
  654. after: 0
  655. },
  656. // 根据客户点击的督查类型查找督查对象ID
  657. // 新增
  658. listobjId: [],
  659. userId: localStorage.getItem("userid"),
  660. treeData: [],
  661. // 修改督查
  662. pictureArray: [],
  663. audioArray: [],
  664. videoArray: [],
  665. fileArray: [],
  666. audiotabName: "",
  667. videotabName: "",
  668. picturetabName: "",
  669. filetabName: "",
  670. playerOptions: {
  671. height: "120",
  672. autoplay: true,
  673. muted: true,
  674. language: "en",
  675. playbackRates: [0.7, 1.0, 1.5, 2.0],
  676. sources: [
  677. {
  678. type: "video/mp4",
  679. // mp4
  680. src: "http://vjs.zencdn.net/v/oceans.mp4"
  681. // webm
  682. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  683. },
  684. {
  685. type: "video/mp4",
  686. // mp4
  687. src: "http://vjs.zencdn.net/v/oceans.mp4"
  688. // webm
  689. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  690. },
  691. {
  692. type: "video/mp4",
  693. // mp4
  694. src: "http://vjs.zencdn.net/v/oceans.mp4"
  695. // webm
  696. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  697. },
  698. {
  699. type: "video/mp4",
  700. // mp4
  701. src: "http://vjs.zencdn.net/v/oceans.mp4"
  702. // webm
  703. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  704. }
  705. ]
  706. },
  707. changeSupervisionVisible: false,
  708. changeSupervisionLoading: false,
  709. changeSupervision: {
  710. nm: "",
  711. presId: localStorage.getItem("userid"),
  712. endTime: "",
  713. pblmId: "",
  714. objId: "",
  715. pType: "",
  716. inspGroupId: "",
  717. inspPblmName: "",
  718. inspPblmDesc: "",
  719. pblmLong: "",
  720. pblmLat: "",
  721. pblmStat: "",
  722. ifCasePblm: "",
  723. inspPblmOrgName: "",
  724. pblmPersName: "",
  725. inspPblmCate: "",
  726. reviOpin: "",
  727. reviConc: "",
  728. reviOrgGuid: "",
  729. collTime: "",
  730. recPers: "",
  731. gwComFiles: [
  732. {
  733. id: "",
  734. filePath: "",
  735. bizId: ""
  736. }
  737. ]
  738. },
  739. flash: false,
  740. // 督查类型
  741. supervisionTypeList: [
  742. {
  743. value: "1",
  744. label: "小水库"
  745. }
  746. ],
  747. // 查询
  748. value6: [],
  749. findParams: {
  750. hasVedio: "",
  751. adCode: "",
  752. pblmStat: "",
  753. nm: "",
  754. adFullName: "",
  755. startTime: "",
  756. endTime: "",
  757. pType: 84,
  758. inspPblmName: "",
  759. state: "",
  760. persId: localStorage.getItem("userid")
  761. },
  762. stateList: [
  763. {
  764. label: '未提交',
  765. value: '0'
  766. },
  767. {
  768. label: '已提交',
  769. value: '2'
  770. },
  771. {
  772. label: '已发布',
  773. value: '3'
  774. }
  775. ],
  776. currentPage: 1, // 页码
  777. pageSize: 20, // 条数
  778. loading: false,
  779. total: 0, // 总数
  780. searchResult: [], // 结果
  781. crId: "", // 当前督查id
  782. // 督查详情
  783. userid: localStorage.getItem("userid"),
  784. supervisionDetailsVisible: false,
  785. problemDeleteVisible: false,
  786. supervisionDetails: {},
  787. pblmId: "",
  788. gwComFiles: [],
  789. pblscr: "",
  790. pblscrList: [
  791. {
  792. lable: "我的问题",
  793. value: localStorage.getItem("userid")
  794. }
  795. ],
  796. pblscrGroup: "",
  797. t1: {},
  798. t2: {},
  799. t3: {},
  800. problemList: [],
  801. currentCheckPointList: [],
  802. currentProblemDescList: [],
  803. xiangqingmiaoshu: '',
  804. wenTiLeiBie: "",
  805. jianChaXiangMu: "",
  806. actionUrl: "",
  807. fileList: [],
  808. header: {
  809. 'persId': localStorage.getItem('userid'),
  810. 'accessToken': localStorage.getItem('accessToken')
  811. },
  812. fileListLength: 0,
  813. showShuiKuTianBaoPl: false,
  814. uploadDisabled: true,
  815. exportLoading: false,
  816. datas: {},
  817. orgIds: '001',
  818. editPicDialog: false,
  819. picUrl: "",
  820. picId: "",
  821. downloadIcon: "el-icon-download",
  822. buttonLoading: false,
  823. treeAllData: [],
  824. newYear: "",
  825. editId: "",
  826. pType: 84,
  827. };
  828. },
  829. computed: {
  830. hostUrl() {
  831. return hostUrl
  832. },
  833. isGd(){
  834. if(localStorage.getItem('currentRlcode').substring(0,2)=="44"){
  835. return true;
  836. }else{
  837. return false;
  838. }
  839. }
  840. },
  841. created() {
  842. if (this.userId) {
  843. console.log("已经登录");
  844. this.search();
  845. } else {
  846. this.$router.push("/login");
  847. }
  848. this.getproblemSmallType();
  849. this.addPicPanel = false;
  850. },
  851. activated() {
  852. },
  853. methods: {
  854. changeTabType(tabType) {
  855. this.treeNodeArray = [];
  856. this.tabType = tabType;
  857. this.search();
  858. },
  859. //图片编辑
  860. editPicEvent(item) {
  861. this.picUrl = this.hostUrl + "/" + item.filePath;
  862. this.editPicDialog = true;
  863. this.editPicRefresh = false;
  864. this.picId = item.id;
  865. },
  866. cancelHandler() {
  867. this.editPicDialog = false;
  868. this.editPicRefresh = true;
  869. },
  870. editPicDataEvent(item) {
  871. request.post(`/file/updateFile?bizId=${this.changeSupervision.pblmId}&id=${this.picId}`, item, {headers: {'Content-Type': 'multipart/form-data'}}).then(res => {
  872. console.log(res);
  873. if (res.success) {
  874. this.pictureArray = [];
  875. showDetailsXq(this.updateIdXiuGai).then(res => {
  876. res.data.gwComFiles.forEach(item => {
  877. this.pictureArray.push(item);
  878. this.editPicDialog = false;
  879. this.editPicRefresh = true;
  880. });
  881. this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  882. });
  883. }
  884. });
  885. },
  886. // 操作成功反馈
  887. successInfo() {
  888. this.$message({
  889. type: "success",
  890. message: "操作成功!"
  891. });
  892. },
  893. // 操作失败反馈
  894. failInfo(val) {
  895. this.$message.error(val);
  896. },
  897. // 已选择项
  898. handleSelectionChange(val) {
  899. this.multipleSelection = val;
  900. },
  901. // 查询
  902. async search() {
  903. this.loading = true;
  904. let _self = this;
  905. let orgAllNode = this.treeAllData;
  906. _self.loading = true;
  907. let data = _self.findParams;
  908. data.startTime = _self.value6 && _self.value6.length > 0 ? _self.value6[0] : '';
  909. data.endTime = _self.value6 && _self.value6.length > 0 ? _self.value6[1] : '';
  910. data.pageNum = _self.currentPage;
  911. data.recPers = _self.pblscr;
  912. data.orgNm = _self.pblscrGroup;
  913. data.pageSize = _self.pageSize;
  914. data.villType = "";
  915. _self.findUseOrgArray = [];
  916. _self.treeNodeArray.forEach(item => {
  917. if (item.id.length < 12) {
  918. orgAllNode.forEach(orgItem => {
  919. if (orgItem.id.startsWith(item.code)) {
  920. _self.findUseOrgArray.push(orgItem.id);
  921. }
  922. });
  923. }
  924. _self.findUseOrgArray.push(item.id);
  925. });
  926. if (_self.findUseOrgArray.length > 0) {
  927. data["orgIds"] = _self.findUseOrgArray.join(",");
  928. this.orgIds = _self.findUseOrgArray.join(",");
  929. } else {
  930. data["orgIds"] = "";
  931. }
  932. if (this.rowId) {
  933. data["orgIds"] = this.rowId;
  934. }
  935. data["year"] = this.newYear;
  936. data.tabType = this.tabType;
  937. findProblemPageInfo(data).then(res => {
  938. _self.loading = false;
  939. _self.multipleSelection = [];
  940. if (res.success) {
  941. _self.searchResult = res.data.list;
  942. // console.log( "绝对是"+searchResult)
  943. _self.total = res.data.total;
  944. } else {
  945. _self.failInfo();
  946. }
  947. });
  948. },
  949. async submitBtn() {
  950. if (this.multipleSelection.length === 0) {
  951. this.$message.warning('请至少选择一条问题');
  952. return;
  953. }
  954. let newArray = this.multipleSelection.map((item) => {
  955. return {
  956. "objId": item.objId,
  957. "objType": item.objType,
  958. "state": "3"
  959. }
  960. });
  961. const {success, message} = await pblmSubmit(newArray);
  962. if (success) {
  963. this.$message.success('问题发布成功');
  964. this.search();
  965. } else {
  966. this.$message.warning(message);
  967. }
  968. },
  969. toForm(){
  970. var idArr = [];
  971. if(this.multipleSelection && this.multipleSelection.length==0){
  972. this.$message.warning("请选择数据");
  973. return false;
  974. }else{
  975. this.multipleSelection.forEach((item)=>{
  976. idArr.push(item.pblmId);
  977. })
  978. }
  979. this.ids = idArr.join(",");
  980. this.isToFormVisible = true;
  981. },
  982. toFormOk(){
  983. let host = hostUrl;
  984. let nginx = '/pageofficePath/';
  985. var params = {
  986. ids:this.ids
  987. }
  988. axios.post('/pageofficePath/pageoffice/pblm/list/sendIds',params).then((res)=> {
  989. if(res.status==200){
  990. let href = 'pageoffice://|' + host + nginx + '/pageoffice/pblm/list/word?filename='+this.oneForm+'|width=1100px;height=800px;ismodal=false;||91A4EE66EC1921F376873E85D6C74FFA|A890649B44577C32CE1930797E1299F9';
  991. let a = document.createElement('a'); // 创建a标签
  992. a.setAttribute('href', href);// href链接
  993. a.click();// 自执行点击事件
  994. }
  995. })
  996. },
  997. async exportExcel() {
  998. this.exportLoading = true;
  999. let _self = this;
  1000. let orgAllNode = _self.treeAllData;
  1001. let data = _self.findParams;
  1002. data.pageNum = _self.currentPage;
  1003. data.pageSize = _self.pageSize;
  1004. data.villType = "";
  1005. _self.datas = JSON.stringify(data);
  1006. _self.treeNodeArray.forEach(item => {
  1007. console.log(item);
  1008. if (item.id.length < 12) {
  1009. orgAllNode.forEach(orgItem => {
  1010. if (orgItem.id.startsWith(item.id)) {
  1011. _self.findUseOrgArray.push(orgItem.id);
  1012. }
  1013. });
  1014. } else {
  1015. _self.findUseOrgArray.push(item.id);
  1016. }
  1017. });
  1018. let url = "/pdcApi/dc/insp/pblm/page/export";
  1019. let type = "post";
  1020. let exportName = "小水库除险加固问题列表.xls"
  1021. let result = await exportModel(type, url, exportName, this.datas);
  1022. _self.exportLoading = result;
  1023. },
  1024. async exportWord() {
  1025. let _self = this;
  1026. _self.exportLoading = true;
  1027. let orgAllNode = _self.treeAllData;
  1028. let data = _self.findParams;
  1029. data.pageNum = _self.currentPage;
  1030. data.pageSize = _self.pageSize;
  1031. data.villType = "";
  1032. this.datas = data;
  1033. _self.treeNodeArray.forEach(item => {
  1034. if (item.id.length < 12) {
  1035. orgAllNode.forEach(orgItem => {
  1036. if (orgItem.id.startsWith(item.id)) {
  1037. _self.findUseOrgArray.push(orgItem.id);
  1038. }
  1039. });
  1040. } else {
  1041. _self.findUseOrgArray.push(item.id);
  1042. }
  1043. });
  1044. //下载word文档2
  1045. await request.post('/rever/doc', this.datas).then(res => {
  1046. if (res.success) {
  1047. console.log(this.response)
  1048. var a = document.createElement('a');
  1049. a.href = `${this.hostUrl}${res.data.downloadPath}`;
  1050. //设置文件名称
  1051. a.download = '小水库问题详情.doc';
  1052. a.click();
  1053. // window.open(`${this.hostUrl}${res.data.downloadPath}`)
  1054. _self.exportLoading = false;
  1055. } else {
  1056. _self.$mesage.error(res.message)
  1057. }
  1058. }).catch(res => {
  1059. _self.$mesage.error(res.message)
  1060. })
  1061. },
  1062. downFile(blob, fileName) {
  1063. // 非IE下载
  1064. if ("download" in document.createElement("a")) {
  1065. let link = document.createElement("a");
  1066. link.href = window.URL.createObjectURL(blob); // 创建下载的链接
  1067. link.download = fileName; // 下载后文件名
  1068. link.style.display = "none";
  1069. document.body.appendChild(link);
  1070. link.click(); // 点击下载
  1071. window.URL.revokeObjectURL(link.href); // 释放掉blob对象
  1072. document.body.removeChild(link); // 下载完成移除元素
  1073. } else {
  1074. // IE10+下载
  1075. window.navigator.msSaveBlob(blob, fileName);
  1076. }
  1077. },
  1078. // 下载模板
  1079. async downloadTemplate() {
  1080. await this.search();
  1081. await this.downloadTemplateSet();
  1082. this.uploadDisabled = false;
  1083. },
  1084. downloadTemplateSet() {
  1085. let _this = this;
  1086. _this.downloadIcon = "el-icon-loading"
  1087. // 使用POST传值下载文件,可以看到请求参数和避免请求参数过长导致请求失败
  1088. let xhr = new XMLHttpRequest();
  1089. this.findParams.orgIds = '';
  1090. let datas = JSON.stringify(this.findParams);
  1091. xhr.open('post', '/api/dc/imp/pblm/download', true);
  1092. xhr.responseType = 'blob';
  1093. // data传值方式和Content-Type要对应
  1094. let data = 'userId=' + this.userId + '&orgType=001&orgIds=' + this.orgIds + '&datas=' + datas;
  1095. xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
  1096. // xhr.setRequestHeader('Content-Type', 'application/json;charset=utf-8');
  1097. xhr.setRequestHeader('persId', localStorage.getItem('userid') ? localStorage.getItem('userid') : '');
  1098. xhr.onload = function () {
  1099. if (this.status == 200) {
  1100. let blob = this.response;
  1101. let a = document.createElement('a');
  1102. let url = window.URL.createObjectURL(blob);
  1103. a.href = url;
  1104. //设置文件名称
  1105. a.download = '小水库问题.xls';
  1106. a.click();
  1107. }
  1108. _this.downloadIcon = "el-icon-download"
  1109. }
  1110. xhr.send(data);
  1111. },
  1112. showPlDialog() {
  1113. this.showShuiKuTianBaoPl = true
  1114. },
  1115. closePlDialog(val) {
  1116. this.showShuiKuTianBaoPl = false
  1117. this.search();
  1118. },
  1119. handleSizeChange(pageSize) {
  1120. this.pageSize = pageSize;
  1121. this.search();
  1122. },
  1123. // 新增
  1124. getDuChaId() {
  1125. //新增中 获取督查对象id
  1126. getSupervisdByID(this.userid, 1).then(res => {
  1127. if (res.success) {
  1128. // alert(1)
  1129. this.listobjId = res.data;
  1130. } else {
  1131. this.failInfo();
  1132. }
  1133. });
  1134. },
  1135. // 取消
  1136. removeNewSupervision(arg) {
  1137. this.gwComFiles = [];
  1138. if (arg) {
  1139. this.gwComFiles = arg;
  1140. this.$refs.uploadFile.init();
  1141. }
  1142. },
  1143. // 详情弹框
  1144. showDetails(id) {
  1145. this.currentProblemId = id;
  1146. this.supervisionDetailsVisible = true;
  1147. },
  1148. // 删除弹窗
  1149. removeSuperviseOne(id) {
  1150. this.deleteId = id;
  1151. this.problemDeleteVisible = true;
  1152. // showDetailsXq(id).then(res => {
  1153. // // console.log("123" + res.data)
  1154. // this.persNameRen = res.data.persName;
  1155. // });
  1156. },
  1157. deleteSuccess() {
  1158. this.problemDeleteVisible = false;
  1159. this.search();
  1160. this.$emit("problemCount");
  1161. },
  1162. // 修改弹窗显示
  1163. // changeSup(id) {
  1164. // this.currentProblemId = '';
  1165. // this.pictureArray = [];
  1166. // this.audioArray = [];
  1167. // this.videoArray = [];
  1168. // this.fileArray = [];
  1169. // this.updateIdXiuGai = id;
  1170. // showDetailsXq(this.updateIdXiuGai).then(res => {
  1171. // this.changeSupervision = res.data;
  1172. // this.fileList = this.changeSupervision.gwComFiles;
  1173. // this.t1['inspPblmsName'] = this.changeSupervision.inspPblmsName
  1174. // this.problemList.forEach(ele => {
  1175. // if (ele.inspPblmsName == this.t1.inspPblmsName) {
  1176. // this.problemListChange(ele)
  1177. // }
  1178. // })
  1179. // this.t2['checkPointName'] = this.changeSupervision.checkPoint
  1180. // this.currentCheckPointList.forEach(ele => {
  1181. // if (ele.checkPointName == this.t2.checkPointName) {
  1182. // this.currentCheckPointListChange(ele)
  1183. // }
  1184. // })
  1185. // this.t3['pblmDesc'] = this.changeSupervision.pblmDesc
  1186. // this.changeSupervisionVisible = true;
  1187. // res.data.gwComFiles.forEach(item => {
  1188. // if (
  1189. // item.fileExt == "mp3" ||
  1190. // item.fileExt == "MP3" ||
  1191. // item.fileExt == "m4a"
  1192. // ) {
  1193. // this.audioArray.push(item);
  1194. // } else if (
  1195. // item.fileExt == "jpg" ||
  1196. // item.fileExt == "JPG" ||
  1197. // item.fileExt == "png" ||
  1198. // item.fileExt == "PNG" ||
  1199. // item.fileExt == "JPEG" ||
  1200. // item.fileExt == "jpeg"
  1201. // ) {
  1202. // this.pictureArray.push(item);
  1203. // } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  1204. // this.videoArray.push({
  1205. // id: item.id,
  1206. // bizId: item.bizId,
  1207. // width: "130",
  1208. // height: "130",
  1209. // autoplay: false,
  1210. // muted: true,
  1211. // language: "en",
  1212. // playbackRates: [0.7, 1.0, 1.5, 2.0],
  1213. // sources: [
  1214. // {
  1215. // type: "video/mp4",
  1216. // // mp4
  1217. // src: this.hostUrl + item.filePath
  1218. // // webm
  1219. // // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  1220. // }
  1221. // ]
  1222. // });
  1223. // } else {
  1224. // this.fileArray.push(item);
  1225. // }
  1226. // });
  1227. //
  1228. // this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  1229. // this.audiotabName = "音频资料(" + this.audioArray.length + ")";
  1230. // this.videotabName = "视频资料(" + this.videoArray.length + ")";
  1231. // this.filetabName = "其它资料(" + this.fileArray.length + ")";
  1232. // });
  1233. // },
  1234. changeSup(pblmId) {
  1235. this.editId = pblmId;
  1236. this.changeSupervisionVisible = true
  1237. },
  1238. // 提交修改信息
  1239. changeSupervisionInfo() {
  1240. this.$refs.changeSupFrom.validate(valid => {
  1241. if (valid) {
  1242. this.$nextTick(() => {
  1243. this.buttonLoading = true;
  1244. if (this.$refs.uploadFile.submitUpload(this.changeSupervision.pblmId)) {
  1245. this.removeNewSupervision();
  1246. }
  1247. setTimeout(() => {
  1248. this.changeSupervisionLoading = true;
  1249. this.changeSupervision.gwComFiles = this.gwComFiles;
  1250. let data = this.changeSupervision;
  1251. updatelist(data).then(res => {
  1252. this.pblmId = res.data.pblmId;
  1253. this.gwComFiles = res.data.gwComFiles;
  1254. this.changeSupervisionLoading = false;
  1255. if (res.success) {
  1256. this.buttonLoading = false;
  1257. this.search();
  1258. this.successInfo();
  1259. this.addPicPanel = false;
  1260. this.changeSupervisionVisible = false;
  1261. } else {
  1262. this.failInfo();
  1263. }
  1264. });
  1265. }, 1000)
  1266. })
  1267. }
  1268. });
  1269. },
  1270. // 时间格式化
  1271. timestampToTime(row, column) {
  1272. var date = new Date(row.collTime);
  1273. var Y = date.getFullYear() + "-";
  1274. var M =
  1275. (date.getMonth() + 1 < 10
  1276. ? "0" + (date.getMonth() + 1)
  1277. : date.getMonth() + 1) + "-";
  1278. var D =
  1279. (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()) + " ";
  1280. var h =
  1281. (date.getHours() < 10 ? "0" + date.getHours() : date.getHours()) + ":";
  1282. var m =
  1283. date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
  1284. return Y + M + D;
  1285. },
  1286. // 删除图片文件
  1287. removeFile(id, index) {
  1288. var _self = this;
  1289. this.$confirm("此操作将永久删除该文件, 是否继续?", "提示", {
  1290. confirmButtonText: "确定",
  1291. cancelButtonText: "返回",
  1292. type: "warning"
  1293. }).then(
  1294. res => {
  1295. if (res === "confirm") {
  1296. deleteFileById(id, this.userId).then(res => {
  1297. if (res.success) {
  1298. this.fileListLength = 0;
  1299. this.fileList.forEach(item => {
  1300. if (
  1301. item.fileExt == "mp3" ||
  1302. item.fileExt == "MP3" ||
  1303. item.fileExt == "m4a"
  1304. ) {
  1305. this.audioArray.splice(index, 1);
  1306. } else if (
  1307. item.fileExt == "jpg" ||
  1308. item.fileExt == "JPG" ||
  1309. item.fileExt == "png" ||
  1310. item.fileExt == "PNG" ||
  1311. item.fileExt == "JPEG" ||
  1312. item.fileExt == "jpeg"
  1313. ) {
  1314. this.pictureArray.splice(index, 1);
  1315. } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  1316. this.videoArray.splice(index, 1);
  1317. }
  1318. });
  1319. _self.changeSup(this.updateIdXiuGai);
  1320. } else {
  1321. this.failInfo();
  1322. }
  1323. });
  1324. }
  1325. },
  1326. res => {
  1327. console.log("返回");
  1328. }
  1329. );
  1330. },
  1331. changeSupervisionVisiblefalse() {
  1332. this.$nextTick(() => {
  1333. if (this.flash) {
  1334. this.flash = false;
  1335. this.search();
  1336. }
  1337. });
  1338. this.changeSupervisionVisible = false;
  1339. this.changeSupervision = {
  1340. dataStat: "",
  1341. nm: "",
  1342. endTime: "",
  1343. pblmId: "",
  1344. objId: "",
  1345. pType: "",
  1346. inspGroupId: "",
  1347. inspPblmCate: "",
  1348. inspPblmName: "",
  1349. inspPblmDesc: "",
  1350. pblmLong: "",
  1351. pblmLat: "",
  1352. pblmStat: "",
  1353. ifCasePblm: "",
  1354. inspPblmOrgName: "",
  1355. pblmPersName: "",
  1356. reviOpin: "",
  1357. reviConc: "",
  1358. reviOrgGuid: "",
  1359. collTime: "",
  1360. recPers: "",
  1361. note: "",
  1362. gwComFiles: [
  1363. {
  1364. id: "",
  1365. filePath: "",
  1366. bizId: ""
  1367. }
  1368. ]
  1369. };
  1370. // this.$refs.uploadFile.init();
  1371. this.addPicPanel = false;
  1372. },
  1373. addPic() {
  1374. this.addPicPanel = !this.addPicPanel;
  1375. },
  1376. getproblemSmallType() {
  1377. let result = [];
  1378. request.get('/dc/insp/pblms/getPblmType', {
  1379. params: {
  1380. type: '84',
  1381. pguid: '00000000000000000000000000000000'
  1382. }
  1383. }).then(res => {
  1384. if (res.success) {
  1385. res.data.forEach((ele) => {
  1386. let haveinspPblmsName = false;
  1387. result.forEach((inspPblm) => {
  1388. if (inspPblm['inspPblmsName'] == ele.inspPblmsName) {
  1389. //
  1390. let havechekPoint = false;
  1391. inspPblm['checkPoints'].forEach((chekPoint) => {
  1392. if (chekPoint['checkPointName'] == ele.checkPoint) {
  1393. havechekPoint = true;
  1394. }
  1395. });
  1396. if (!havechekPoint) {
  1397. let newCheckPoint = {};
  1398. newCheckPoint['checkPointName'] = ele.checkPoint;
  1399. newCheckPoint['sort2'] = ele.sort2;
  1400. newCheckPoint['guid'] = ele.guid;
  1401. inspPblm['checkPoints'].push(newCheckPoint);
  1402. }
  1403. haveinspPblmsName = true;
  1404. }
  1405. });
  1406. if (!haveinspPblmsName) {
  1407. let haveinspPblmsObj = {};
  1408. haveinspPblmsObj['inspPblmsName'] = ele.inspPblmsName;
  1409. haveinspPblmsObj['sort1'] = ele.sort1;
  1410. haveinspPblmsObj['checkPoints'] = [{
  1411. checkPointName: ele.checkPoint,
  1412. sort2: ele.sort2,
  1413. guid: ele.guid
  1414. }];
  1415. result.push(haveinspPblmsObj);
  1416. }
  1417. })
  1418. this.problemList = result;
  1419. console.log(this.problemList);
  1420. }
  1421. })
  1422. },
  1423. problemListChange: function (item) {
  1424. this.t1 = item;
  1425. this.wenTiLeiBie = item.inspPblmsName;
  1426. this.currentCheckPointList = item.checkPoints;
  1427. },
  1428. currentCheckPointListChange: function (item) {
  1429. this.jianChaXiangMu = item.checkPointName;
  1430. this.currentProblemDescList = item.pblmDescs;
  1431. },
  1432. currentProblemDescListChange: function (item) {
  1433. this.xiangqingmiaoshu = item.pblmDesc;
  1434. console.log(item);
  1435. },
  1436. fileUpErr(err, file, fileList) {
  1437. this.$message.error("上传出错,请修改文件!");
  1438. this.fileList = [];
  1439. },
  1440. fileSuccess(item) {
  1441. this.fileList.push(item.data);
  1442. console.log(this.fileList);
  1443. },
  1444. // onChangeDialog() {
  1445. // this.changeSupervisionVisible = true;
  1446. // this.$refs.changeSupFrom.validate(valid => {
  1447. // if (valid) {
  1448. // this.changeSupervisionLoading = true;
  1449. // this.changeSupervision.inspPblmsName = this.wenTiLeiBie
  1450. // this.changeSupervision.checkPoint = this.jianChaXiangMu
  1451. // this.changeSupervision.inspPblmName = this.wenTiLeiBie //后台只需要这一个字段和问题id inspPblmsName和checkPoint可不传
  1452. // this.changeSupervision.inspPlbmType = this.t2.sort2;
  1453. // this.changeSupervision.pblmsTypeId = this.t2.guid;
  1454. // this.changeSupervision.gwComFiles = this.fileList;
  1455. // let data = this.changeSupervision;
  1456. // updatelist(data).then(res => {
  1457. // this.pblmId = res.data.pblmId;
  1458. // this.gwComFiles = res.data.gwComFiles;
  1459. // if (res.success) {
  1460. // if (this.$refs.uploadFile.submitUpload(data.pblmId)) {
  1461. // this.removeNewSupervision();
  1462. // this.successInfo();
  1463. // this.addPicPanel = false;
  1464. // this.changeSupervisionLoading = false;
  1465. // }
  1466. // } else {
  1467. // _self.failInfo();
  1468. // }
  1469. // });
  1470. // }
  1471. // });
  1472. // },
  1473. addFile(file, fileList) {
  1474. this.fileListLength = fileList.length;
  1475. },
  1476. UploadUrl: function () {
  1477. return `/pdcApi/file/insert?bizId=${this.changeSupervision.pblmId}`
  1478. },
  1479. beforeAvatarUpload(file) {
  1480. console.log(file);
  1481. },
  1482. //切换问题是否被督查简报调用
  1483. changeSfYy(row, val) {
  1484. this.$confirm('此问题将切换是否被督查简报引用, 是否继续?', '提示', {
  1485. confirmButtonText: '确定',
  1486. cancelButtonText: '取消',
  1487. type: 'warning'
  1488. }).then(() => {
  1489. if (val) {
  1490. request.post(`/dc/insp/pblm/update`, {
  1491. "pblmId": row,
  1492. "quote": 0
  1493. }).then(res => {
  1494. if (res.success) {
  1495. this.search();
  1496. }
  1497. })
  1498. } else {
  1499. request.post(`/dc/insp/pblm/update`, {
  1500. "pblmId": row,
  1501. "quote": 1
  1502. }).then(res => {
  1503. if (res.success) {
  1504. this.search();
  1505. }
  1506. })
  1507. }
  1508. }).catch(() => {
  1509. this.$message({
  1510. type: 'info',
  1511. message: '已取消切换'
  1512. });
  1513. });
  1514. },
  1515. treeNodeClickHandler(data) {
  1516. this.treeNodeArray = data;
  1517. },
  1518. changeYear(val) {
  1519. this.newYear = val;
  1520. this.search();
  1521. },
  1522. getAllTreeData(data) {
  1523. this.treeAllData = data;
  1524. },
  1525. closeEditDialog() {
  1526. this.changeSupervisionVisible = false
  1527. setTimeout(() => {
  1528. this.search()
  1529. }, 800)
  1530. }
  1531. },
  1532. watch: {
  1533. codeId: function () {
  1534. this.search();
  1535. },
  1536. showExpandSearchPanel: function (val) {
  1537. if (val) {
  1538. this.tableHeight = window.innerHeight - 390;
  1539. } else {
  1540. this.tableHeight = window.innerHeight - 291;
  1541. }
  1542. },
  1543. rowId(val) {
  1544. if (val) {
  1545. this.search();
  1546. }
  1547. }
  1548. },
  1549. };
  1550. </script>
  1551. <style rel="stylesheet/scss" lang="scss" scoped>
  1552. @import "./base.css";
  1553. @import url("/src/assets/iconfont/iconfont.css");
  1554. @import url("/src/assets/css/mixin.scss");
  1555. .upload-container {
  1556. width: 100%;
  1557. position: relative;
  1558. .image-uploader {
  1559. width: 35%;
  1560. float: left;
  1561. }
  1562. .image-preview {
  1563. width: 200px;
  1564. height: 200px;
  1565. position: relative;
  1566. border: 1px dashed #d9d9d9;
  1567. float: left;
  1568. // margin-left: 50px;
  1569. .image-preview-wrapper {
  1570. position: relative;
  1571. width: 100%;
  1572. height: 100%;
  1573. img {
  1574. width: 100%;
  1575. height: 100%;
  1576. }
  1577. }
  1578. .image-preview-action {
  1579. position: absolute;
  1580. width: 100%;
  1581. height: 100%;
  1582. left: 0;
  1583. top: 0;
  1584. cursor: default;
  1585. text-align: center;
  1586. color: #fff;
  1587. opacity: 0;
  1588. font-size: 20px;
  1589. background-color: rgba(0, 0, 0, 0.5);
  1590. transition: opacity 0.3s;
  1591. cursor: pointer;
  1592. text-align: center;
  1593. line-height: 200px;
  1594. .el-icon-delete {
  1595. font-size: 36px;
  1596. }
  1597. .el-icon-edit-outline {
  1598. font-size: 36px;
  1599. }
  1600. }
  1601. &:hover {
  1602. .image-preview-action {
  1603. opacity: 1;
  1604. }
  1605. }
  1606. }
  1607. .image-app-preview {
  1608. margin-bottom: 10px;
  1609. width: 40vh;
  1610. height: 180px;
  1611. position: relative;
  1612. border: 1px dashed #d9d9d9;
  1613. float: left;
  1614. // margin-left: 50px;
  1615. .app-fake-conver {
  1616. height: 44px;
  1617. position: absolute;
  1618. width: 100%; // background: rgba(0, 0, 0, .1);
  1619. text-align: center;
  1620. line-height: 64px;
  1621. color: #fff;
  1622. }
  1623. }
  1624. }
  1625. .bottom {
  1626. margin-top: 13px;
  1627. line-height: 12px;
  1628. }
  1629. .button {
  1630. padding: 0;
  1631. float: right;
  1632. }
  1633. .image {
  1634. width: 100%;
  1635. display: block;
  1636. }
  1637. .clearfix:before,
  1638. .clearfix:after {
  1639. display: table;
  1640. content: "";
  1641. }
  1642. .clearfix:after {
  1643. clear: both;
  1644. }
  1645. #wenTiContainer_sk .el-tree-node {
  1646. /* overflow: auto; */
  1647. }
  1648. #wenTiContainer_sk .el-tree-node > .el-tree-node__children {
  1649. overflow: auto;
  1650. }
  1651. .shuiku .el-date-editor.el-input {
  1652. min-width: 180px !important;
  1653. }
  1654. .shuiku .header {
  1655. padding: 0px 10px;
  1656. }
  1657. .shuiku .el-row {
  1658. margin-bottom: 5px;
  1659. }
  1660. .shuiku .content {
  1661. margin: 10px;
  1662. }
  1663. /* .search .el-table>>>.el-tooltip {
  1664. white-space: pre-wrap !important;
  1665. line-height: 30px;
  1666. font-size: 0;
  1667. } */
  1668. .shuiku .search > > > .el-table .el-button:nth-child(odd) {
  1669. margin-left: 0 !important;
  1670. }
  1671. .custom_dialog .el-dialog {
  1672. width: 60% !important;
  1673. }
  1674. .custom_dialog .scroll300 {
  1675. max-height: 60vh !important;
  1676. }
  1677. .scroll300 .el-form {
  1678. padding-top: 5px;
  1679. padding-right: 5px;
  1680. }
  1681. .shuiku .el-tag + .el-tag {
  1682. margin-left: 10px;
  1683. }
  1684. .shuiku .button-new-tag {
  1685. margin-left: 10px;
  1686. height: 29px;
  1687. line-height: 29px;
  1688. padding-top: 0;
  1689. padding-bottom: 0;
  1690. }
  1691. .shuiku .input-new-tag {
  1692. width: 90px;
  1693. margin-left: 10px;
  1694. vertical-align: bottom;
  1695. }
  1696. .inspPblmCate {
  1697. padding: 2px 10px;
  1698. border-radius: 10px;
  1699. color: #ffffff;
  1700. -webkit-border-radius: 10px;
  1701. -moz-border-radius: 10px;
  1702. border-radius: 10px;
  1703. }
  1704. #wenTiContainer_sk .el-select, #wenTiContainer_sk .el-input {
  1705. width: 140px !important;
  1706. }
  1707. </style>