3fc8b7b70b2727c6d7a67b9ebce0e14b340ab31c.svn-base 73 KB

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