d986a7541e6cb9ff036b8baedac7250de6056403.svn-base 74 KB

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