ItdmWeituoshenheInfoList.vue 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. <template>
  2. <a-card :bordered="false">
  3. <!-- 查询区域 -->
  4. <div class="table-page-search-wrapper">
  5. <a-form layout="inline" @keyup.enter.native="searchQuery">
  6. <a-row :gutter="24">
  7. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  8. <a-form-item label="委托单位名称">
  9. <a-input placeholder="请输入委托单位名称" v-model="queryParam.weituoClient"></a-input>
  10. </a-form-item>
  11. </a-col>
  12. <!-- <a-col :xl="6" :lg="7" :md="8" :sm="24">
  13. <a-form-item label="委托单位地址">
  14. <a-input placeholder="请输入委托单位地址" v-model="queryParam.weituoAddress"></a-input>
  15. </a-form-item>
  16. </a-col> -->
  17. <a-col :xl="6" :lg="7" :md="8" :sm="24">
  18. <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
  19. <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
  20. <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
  21. <a @click="handleToggleSearch" style="margin-left: 8px">
  22. {{ toggleSearchStatus ? '收起' : '展开' }}
  23. <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
  24. </a>
  25. </span>
  26. </a-col>
  27. </a-row>
  28. </a-form>
  29. </div>
  30. <!-- 查询区域-END -->
  31. <!-- 操作按钮区域 -->
  32. <!-- <div class="table-operator">
  33. <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
  34. <a-button type="primary" icon="download" @click="handleExportXls('委托信息')">导出</a-button>
  35. <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl" @change="handleImportExcel">
  36. <a-button type="primary" icon="import">导入</a-button>
  37. </a-upload> -->
  38. <!-- 高级查询区域 -->
  39. <!-- <j-super-query :fieldList="superFieldList" ref="superQueryModal" @handleSuperQuery="handleSuperQuery"></j-super-query> -->
  40. <a-dropdown v-if="selectedRowKeys.length > 0">
  41. <a-menu slot="overlay">
  42. <a-menu-item key="1" @click="batchDel"><a-icon type="delete"/>删除</a-menu-item>
  43. </a-menu>
  44. <a-button style="margin-left: 8px"> 批量操作 <a-icon type="down" /></a-button>
  45. </a-dropdown>
  46. </div>
  47. <!-- table区域-begin -->
  48. <div>
  49. <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
  50. <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{ selectedRowKeys.length }}</a>项
  51. <a style="margin-left: 24px" @click="onClearSelected">清空</a>
  52. </div>
  53. <a-table
  54. ref="table"
  55. size="middle"
  56. :scroll="{x:true}"
  57. bordered
  58. rowKey="id"
  59. :columns="columns"
  60. :dataSource="dataSource"
  61. :pagination="ipagination"
  62. :loading="loading"
  63. :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
  64. class="j-table-force-nowrap"
  65. @change="handleTableChange">
  66. <template slot="htmlSlot" slot-scope="text">
  67. <div v-html="text"></div>
  68. </template>
  69. <template slot="imgSlot" slot-scope="text,record">
  70. <span v-if="!text" style="font-size: 12px;font-style: italic;">无图片</span>
  71. <img v-else :src="getImgView(text)" :preview="record.id" height="25px" alt="" style="max-width:80px;font-size: 12px;font-style: italic;"/>
  72. </template>
  73. <template slot="fileSlot" slot-scope="text">
  74. <span v-if="!text" style="font-size: 12px;font-style: italic;">无文件</span>
  75. <a-button
  76. v-else
  77. :ghost="true"
  78. type="primary"
  79. icon="download"
  80. size="small"
  81. @click="downloadFile(text)">
  82. 下载
  83. </a-button>
  84. </template>
  85. <span slot="action" slot-scope="text, record">
  86. <a @click="handleEdit(record)">审核</a>
  87. <a-divider type="vertical" />
  88. <a-dropdown>
  89. <a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
  90. <a-menu slot="overlay">
  91. <a-menu-item>
  92. <a @click="handleDetail(record)">详情</a>
  93. </a-menu-item>
  94. <a-menu-item>
  95. <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
  96. <a>删除</a>
  97. </a-popconfirm>
  98. </a-menu-item>
  99. </a-menu>
  100. </a-dropdown>
  101. </span>
  102. </a-table>
  103. </div>
  104. <itdm-weituo-info-modal ref="modalForm" @ok="modalFormOk"></itdm-weituo-info-modal>
  105. </a-card>
  106. </template>
  107. <script>
  108. import '@/assets/less/TableExpand.less'
  109. import { mixinDevice } from '@/utils/mixin'
  110. import { JeecgListMixin } from '@/mixins/JeecgListMixin'
  111. import ItdmWeituoInfoModal from './modules/ItdmWeituoInfoModal'
  112. import { ajaxGetDictItems, loadCategoryData } from '@/api/api'
  113. import { filterMultiDictText } from '@comp/dict/JDictSelectUtil'
  114. export default {
  115. name: 'ItdmWeituoInfoList',
  116. mixins:[JeecgListMixin, mixinDevice],
  117. components: {
  118. ItdmWeituoInfoModal
  119. },
  120. data () {
  121. return {
  122. description: '委托信息管理页面',
  123. // 表头
  124. columns: [
  125. {
  126. title: '#',
  127. dataIndex: '',
  128. key:'rowIndex',
  129. width:60,
  130. align:"center",
  131. customRender:function (t,r,index) {
  132. return parseInt(index)+1;
  133. }
  134. },
  135. {
  136. title:'委托单位名称',
  137. align:"center",
  138. dataIndex: 'weituoClient'
  139. },
  140. // {
  141. // title:'委托单位地址',
  142. // align:"center",
  143. // dataIndex: 'weituoAddress'
  144. // },
  145. {
  146. title:'委托联系人',
  147. align:"center",
  148. dataIndex: 'weituoLxr'
  149. },
  150. // {
  151. // title:'委托电话',
  152. // align:"center",
  153. // dataIndex: 'weituoPhone'
  154. // },
  155. {
  156. title:'委托编号',
  157. align:"center",
  158. dataIndex: 'weituoNo'
  159. },
  160. // {
  161. // title:'委托邮箱',
  162. // align:"center",
  163. // dataIndex: 'weituoEmail'
  164. // },
  165. // {
  166. // title:'报告用章',
  167. // align:"center",
  168. // dataIndex: 'bgyz',
  169. // customRender: (text) => (text ? filterMultiDictText(this.dictOptions['bgyz'], text) : '')
  170. // },
  171. // {
  172. // title:'报告形式',
  173. // align:"center",
  174. // dataIndex: 'bgxs',
  175. // customRender: (text) => (text ? filterMultiDictText(this.dictOptions['bgxs'], text) : '')
  176. // },
  177. // {
  178. // title:'特殊要求',
  179. // align:"center",
  180. // dataIndex: 'teshuyaoqiu'
  181. // },
  182. {
  183. title:'审核时间',
  184. align:"center",
  185. dataIndex: 'shenheTime'
  186. },
  187. {
  188. title:'审核拒绝原因',
  189. align:"center",
  190. dataIndex: 'shenheMsg'
  191. },
  192. {
  193. title:'审核状态',
  194. align:"center",
  195. dataIndex: 'shenheStatus_dictText'
  196. },
  197. {
  198. title:'试验条件文件地址',
  199. align:"center",
  200. dataIndex: 'tiaojianFile',
  201. scopedSlots: {customRender: 'fileSlot'}
  202. },
  203. {
  204. title: '操作',
  205. dataIndex: 'action',
  206. align:"center",
  207. fixed:"right",
  208. width:147,
  209. scopedSlots: { customRender: 'action' }
  210. }
  211. ],
  212. url: {
  213. list: "/weituo/itdmWeituoShenhe/list",
  214. delete: "/weituo/itdmWeituoInfo/delete",
  215. deleteBatch: "/weituo/itdmWeituoInfo/deleteBatch",
  216. exportXlsUrl: "/weituo/itdmWeituoInfo/exportXls",
  217. importExcelUrl: "weituo/itdmWeituoInfo/importExcel",
  218. edit: "/weituo/itdmWeituoInfo/saveOrUpdateWeituo"
  219. },
  220. dictOptions:{},
  221. superFieldList:[],
  222. }
  223. },
  224. created() {
  225. this.getSuperFieldList();
  226. },
  227. computed: {
  228. importExcelUrl: function(){
  229. return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
  230. },
  231. },
  232. methods: {
  233. initDictConfig(){
  234. ajaxGetDictItems('weituo.bgyz').then((res) => {
  235. if (res.success) {
  236. console.log(res.result)
  237. this.$set(this.dictOptions, 'bgyz', res.result)
  238. }
  239. })
  240. ajaxGetDictItems('weituo.bgxs').then((res) => {
  241. if (res.success) {
  242. console.log(res.result)
  243. this.$set(this.dictOptions, 'bgxs', res.result)
  244. }
  245. })
  246. },
  247. getSuperFieldList(){
  248. let fieldList=[];
  249. fieldList.push({type:'string',value:'weituoClient',text:'委托单位名称',dictCode:''})
  250. fieldList.push({type:'string',value:'weituoAddress',text:'委托单位地址',dictCode:''})
  251. fieldList.push({type:'string',value:'weituoLxr',text:'委托联系人',dictCode:''})
  252. fieldList.push({type:'string',value:'weituoPhone',text:'委托电话',dictCode:''})
  253. fieldList.push({type:'string',value:'weituoEmail',text:'委托邮箱',dictCode:''})
  254. fieldList.push({type:'string',value:'shenheTime',text:'审核时间',dictCode:''})
  255. fieldList.push({type:'string',value:'shenheMsg',text:'审核拒绝原因',dictCode:''})
  256. fieldList.push({type:'string',value:'shenheStatus_dictText',text:'审核状态',dictCode:''})
  257. fieldList.push({type:'string',value:'bgyz',text:'报告用章'})
  258. fieldList.push({type:'string',value:'bgxs',text:'报告形式'})
  259. fieldList.push({type:'string',value:'teshuyaoqiu',text:'特殊要求',dictCode:''})
  260. fieldList.push({type:'string',value:'tiaojianFile',text:'试验条件文件地址',dictCode:''})
  261. this.superFieldList = fieldList
  262. }
  263. }
  264. }
  265. </script>
  266. <style scoped>
  267. @import '~@assets/less/common.less';
  268. </style>