35088be648bfaf4f05f25bbfa51dc92fb64854ab.svn-base 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. <template>
  2. <a-card :bordered="false">
  3. <!-- 查询区域 -->
  4. <div class="table-page-search-wrapper">
  5. <a-modal
  6. title="请谨慎操作!"
  7. :visible="visible"
  8. :confirm-loading="confirmLoading"
  9. @ok="handleOk"
  10. @cancel="handleCancel">
  11. <p>{{ ModalText }}</p>
  12. </a-modal>
  13. <a-form layout="inline" @keyup.enter.native="searchQuery">
  14. <a-row :gutter="24">
  15. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  16. <a-form-item label="管线名称">
  17. <a-input placeholder="请输入管线名称" v-model="queryParam.gxmc"></a-input>
  18. </a-form-item>
  19. </a-col>
  20. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  21. <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
  22. <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
  23. <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
  24. <!-- <a @click="handleToggleSearch" style="margin-left: 8px">-->
  25. <!-- {{ toggleSearchStatus ? '收起' : '展开' }}-->
  26. <!-- <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>-->
  27. <!-- </a>-->
  28. </span>
  29. </a-col>
  30. </a-row>
  31. </a-form>
  32. </div>
  33. <!-- 查询区域-END -->
  34. <!-- 操作按钮区域 -->
  35. <div class="table-operator">
  36. <a-button @click="handleAdd" v-has="'gx:add'" type="primary" icon="plus">新增</a-button>
  37. <a-button type="primary" v-has="'gx:dc'" icon="download" @click="handleExportXls('管线情况统计表')">导出</a-button>
  38. <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
  39. <a-button type="primary" v-has="'gx:dr'" icon="import">导入</a-button>
  40. </a-upload>
  41. <a-button v-has="'gxgc:sctx'" type="primary" icon="download" @click="showModal">生成图形</a-button>
  42. <!-- 高级查询区域 -->
  43. <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query>
  44. <a-dropdown v-if="selectedRowKeys.length > 0">
  45. <a-menu slot="overlay">
  46. <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
  47. </a-menu>
  48. <a-button style="margin-left: 8px" v-has="'gx:pldelete'"> 批量操作 <a-icon type="down" /></a-button>
  49. </a-dropdown>
  50. </div>
  51. <!-- table区域-begin -->
  52. <div>
  53. <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
  54. <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
  55. <a style="margin-left: 24px" @click="onClearSelected">清空</a>
  56. </div>
  57. <a-table
  58. ref="table"
  59. size="middle"
  60. :scroll="{x:true}"
  61. bordered
  62. rowKey="id"
  63. :columns="columns"
  64. :dataSource="dataSource"
  65. :pagination="ipagination"
  66. :loading="loading"
  67. :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
  68. class="j-table-force-nowrap"
  69. @change="handleTableChange">
  70. <template slot="gxmc" slot-scope="text,record">
  71. <a @click="handleDetail(record)">{{ text }}</a>
  72. </template>
  73. <template slot="htmlSlot" slot-scope="text">
  74. <div v-html="text"></div>
  75. </template>
  76. <template slot="imgSlot" slot-scope="text">
  77. <span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
  78. <img v-else :src="getImgView(text)" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
  79. </template>
  80. <template slot="pcaSlot" slot-scope="text">
  81. <div>{{ getPcaText(text) }}</div>
  82. </template>
  83. <template slot="fileSlot" slot-scope="text">
  84. <span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
  85. <a-button
  86. v-else
  87. :ghost="true"
  88. type="primary"
  89. icon="download"
  90. size="small"
  91. @click="downloadFile(text)">
  92. 下载
  93. </a-button>
  94. </template>
  95. <span slot="action" slot-scope="text, record">
  96. <a-space>
  97. <a-button @click='handleEdit(record)' v-has="'gx:bj'" size='small' type='primary'>编辑</a-button>
  98. <a-popconfirm title='确定删除吗?' @confirm='() => handleDelete(record.id)'>
  99. <a-button size='small' v-has="'gx:delete'" type='danger'>删除</a-button>
  100. </a-popconfirm>
  101. </a-space>
  102. <!-- <a-divider type="vertical" />-->
  103. <!-- <a-dropdown>-->
  104. <!-- <a class="ant-dropdown-link">更多 <a-icon type="down" /></a>-->
  105. <!-- <a-menu slot="overlay">-->
  106. <!-- <a-menu-item>-->
  107. <!-- <a @click="handleDetail(record)">详情</a>-->
  108. <!-- </a-menu-item>-->
  109. <!-- <a-menu-item>-->
  110. <!-- <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">-->
  111. <!-- <a>删除</a>-->
  112. <!-- </a-popconfirm>-->
  113. <!-- </a-menu-item>-->
  114. <!-- </a-menu>-->
  115. <!-- </a-dropdown>-->
  116. </span>
  117. </a-table>
  118. </div>
  119. <rm-gxqktjb-modal ref="modalForm" @ok="modalFormOk"></rm-gxqktjb-modal>
  120. </a-card>
  121. </template>
  122. <script>
  123. import '@/assets/less/TableExpand.less'
  124. import { mixinDevice } from '@/utils/mixin'
  125. import { JeecgListMixin } from '@/mixins/JeecgListMixin'
  126. import RmGxqktjbModal from './modules/RmGxqktjbModal'
  127. import {filterMultiDictText} from '@/components/dict/JDictSelectUtil'
  128. import Area from '@/components/_util/Area'
  129. import {getAction} from "../../../../../api/manage";
  130. export default {
  131. name: 'RmGxqktjbList',
  132. mixins:[JeecgListMixin, mixinDevice],
  133. components: {
  134. RmGxqktjbModal
  135. },
  136. data () {
  137. return {
  138. ModalText: '',
  139. visible: false,
  140. confirmLoading: false,
  141. description: '管线情况统计表管理页面',
  142. // 表头
  143. columns: [
  144. {
  145. title: '序号',
  146. dataIndex: '',
  147. key:'rowIndex',
  148. width:60,
  149. align:"center",
  150. customRender:function (t,r,index) {
  151. return parseInt(index)+1;
  152. }
  153. },
  154. {
  155. title:'管线名称',
  156. align:"center",
  157. dataIndex: 'gxmc',
  158. scopedSlots: { customRender: 'gxmc'}
  159. },
  160. {
  161. title:'所在河流',
  162. align:"center",
  163. dataIndex: 'szhl'
  164. },
  165. {
  166. title:'管理单位',
  167. align:"center",
  168. dataIndex: 'gldw'
  169. },
  170. {
  171. title:'主管部门',
  172. align:"center",
  173. dataIndex: 'zgbm'
  174. },
  175. {
  176. title: '操作',
  177. dataIndex: 'action',
  178. align:"center",
  179. fixed:"right",
  180. width:147,
  181. scopedSlots: { customRender: 'action' }
  182. }
  183. ],
  184. url: {
  185. list: "/hzz.shjsgc.lhgc.gx/rmGxqktjb/list",
  186. delete: "/hzz.shjsgc.lhgc.gx/rmGxqktjb/delete",
  187. deleteBatch: "/hzz.shjsgc.lhgc.gx/rmGxqktjb/deleteBatch",
  188. exportXlsUrl: "/hzz.shjsgc.lhgc.gx/rmGxqktjb/exportXls",
  189. importExcelUrl: "hzz.shjsgc.lhgc.gx/rmGxqktjb/importExcel",
  190. },
  191. dictOptions:{},
  192. pcaData:'',
  193. superFieldList:[],
  194. }
  195. },
  196. created() {
  197. this.pcaData = new Area()
  198. this.getSuperFieldList();
  199. },
  200. computed: {
  201. importExcelUrl: function(){
  202. return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
  203. },
  204. },
  205. methods: {
  206. //显示模态框
  207. showModal() {
  208. this.visible = true;
  209. },
  210. //点击ok
  211. handleOk(e) {
  212. this.ModalText = '确定生成图形吗?';
  213. this.confirmLoading = true;
  214. this.xmjgsb();
  215. setTimeout(() => {
  216. this.visible = false;
  217. this.confirmLoading = false;
  218. }, 5000);
  219. this.loadData()
  220. },
  221. //点击cancel
  222. handleCancel(e) {
  223. console.log('Clicked cancel button');
  224. this.visible = false;
  225. },
  226. xmjgsb(){
  227. getAction("/hzz.shjsgc.lhgc.gx/rmGxqktjb/genarateGeo").then(res=>{
  228. if (res.success) {
  229. this.ModalText="生成图形成功"
  230. }else{
  231. this.ModalText="生成图形失败,请联系管理员"
  232. }
  233. })
  234. },
  235. getPcaText(code){
  236. return this.pcaData.getText(code);
  237. },
  238. initDictConfig(){
  239. },
  240. getSuperFieldList(){
  241. let fieldList=[];
  242. fieldList.push({type:'string',value:'gxmc',text:'管线名称',dictCode:''})
  243. fieldList.push({type:'string',value:'szhl',text:'所在河流',dictCode:''})
  244. fieldList.push({type:'string',value:'sjhz',text:'市级河长',dictCode:''})
  245. fieldList.push({type:'string',value:'xjhz',text:'县级河长',dictCode:''})
  246. fieldList.push({type:'pca',value:'xzwz',text:'行政位置(县、乡、村)'})
  247. fieldList.push({type:'string',value:'jd',text:'经度',dictCode:''})
  248. fieldList.push({type:'string',value:'wd',text:'纬度',dictCode:''})
  249. fieldList.push({type:'string',value:'sjsj',text:'始建时间',dictCode:''})
  250. fieldList.push({type:'string',value:'gxfsfs',text:'管线敷设方式',dictCode:''})
  251. fieldList.push({type:'string',value:'gxyhdjcfs',text:'管线与河道交叉方式',dictCode:''})
  252. fieldList.push({type:'double',value:'hdngxzc',text:'河道内管线总长(m)',dictCode:''})
  253. fieldList.push({type:'string',value:'gxyhdzxx',text:'管线与河道中心线交角(°)',dictCode:''})
  254. fieldList.push({type:'string',value:'gxczangn',text:'管线所在岸线功能区类型',dictCode:''})
  255. fieldList.push({type:'string',value:'gxjsfascsfqd',text:'管线建设方案审查许可是否取得',dictCode:'yn'})
  256. fieldList.push({type:'string',value:'gxjsfascspbm',text:'管线建设方案审查许可审批部门',dictCode:''})
  257. fieldList.push({type:'string',value:'gxjsfascspwh',text:'管线建设方案审查许可审批文号',dictCode:''})
  258. fieldList.push({type:'string',value:'gxjgyssxzzgsfcj',text:'管线竣工验收水行政主管部门是否参加',dictCode:'yn'})
  259. fieldList.push({type:'string',value:'gxjgyssxzzgcjbm',text:'管线竣工验收水行政主管部门参加部门',dictCode:''})
  260. fieldList.push({type:'string',value:'gxjgyssxzzgsftyys',text:'管线竣工验收水行政主管部门是否同意验收',dictCode:'yn'})
  261. fieldList.push({type:'string',value:'gldw',text:'管理单位',dictCode:''})
  262. fieldList.push({type:'string',value:'zgbm',text:'主管部门',dictCode:''})
  263. fieldList.push({type:'string',value:'jsgu',text:'架设高度(m)',dictCode:''})
  264. fieldList.push({type:'string',value:'fhpjrq',text:'防洪评价日期',dictCode:''})
  265. fieldList.push({type:'string',value:'sfwpgblxm',text:'是否为评估保留项目',dictCode:'yn'})
  266. fieldList.push({type:'string',value:'yjpg',text:'评估意见',dictCode:''})
  267. fieldList.push({type:'string',value:'bz',text:'备注',dictCode:''})
  268. fieldList.push({type:'string',value:'scwj',text:'上传审批文件',dictCode:''})
  269. this.superFieldList = fieldList
  270. }
  271. }
  272. }
  273. </script>
  274. <style scoped>
  275. @import '~@assets/less/common.less';
  276. </style>