index.vue 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928
  1. <template>
  2. <div class="app-container">
  3. <el-form
  4. :model="queryParams"
  5. ref="queryForm"
  6. size="small"
  7. :inline="true"
  8. v-show="showSearch"
  9. label-width="88px"
  10. >
  11. <el-form-item label="部门名称" prop="deptId">
  12. <el-select filterable v-model="queryParams.deptId" placeholder="请选择">
  13. <el-option
  14. v-for="item in detpList"
  15. :key="item.value"
  16. :label="item.deptName"
  17. :value="item.deptId"
  18. >
  19. </el-option>
  20. </el-select>
  21. </el-form-item>
  22. <el-form-item label="法定代表人" prop="fddbr">
  23. <el-input v-model="queryParams.fddbr" placeholder="请输入"></el-input>
  24. </el-form-item>
  25. <el-form-item>
  26. <el-button
  27. type="primary"
  28. icon="el-icon-search"
  29. size="mini"
  30. @click="handleQuery"
  31. >搜索</el-button
  32. >
  33. <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
  34. >重置</el-button
  35. >
  36. </el-form-item>
  37. </el-form>
  38. <el-row :gutter="10" class="mb8">
  39. <el-col :span="1.5">
  40. <el-button
  41. type="primary"
  42. plain
  43. icon="el-icon-plus"
  44. size="mini"
  45. @click="handleAdd"
  46. v-hasPermi="['business:GARDENBASEDATA:add']"
  47. >新增</el-button
  48. >
  49. </el-col>
  50. <el-col :span="1.5">
  51. <el-button
  52. type="success"
  53. plain
  54. icon="el-icon-edit"
  55. size="mini"
  56. :disabled="single"
  57. @click="handleUpdate"
  58. v-hasPermi="['business:GARDENBASEDATA:edit']"
  59. >修改</el-button
  60. >
  61. </el-col>
  62. <el-col :span="1.5">
  63. <el-button
  64. type="danger"
  65. plain
  66. icon="el-icon-delete"
  67. size="mini"
  68. :disabled="multiple"
  69. @click="handleDelete"
  70. v-hasPermi="['business:GARDENBASEDATA:remove']"
  71. >删除</el-button
  72. >
  73. </el-col>
  74. <el-col :span="1.5">
  75. <el-button
  76. type="warning"
  77. plain
  78. icon="el-icon-download"
  79. size="mini"
  80. @click="handleExport"
  81. v-hasPermi="['business:GARDENBASEDATA:export']"
  82. >导出</el-button
  83. >
  84. </el-col>
  85. <right-toolbar
  86. :showSearch.sync="showSearch"
  87. @queryTable="getList"
  88. ></right-toolbar>
  89. </el-row>
  90. <el-table
  91. :data="GARDENBASEDATAList"
  92. @selection-change="handleSelectionChange"
  93. >
  94. <el-table-column type="selection" width="55" align="center" />
  95. <el-table-column label="园区内企业基础数据主键" align="center" prop="id">
  96. </el-table-column>
  97. <el-table-column label="部门主键" align="center" prop="deptId">
  98. </el-table-column>
  99. <el-table-column label="部门名称" align="center" prop="deptName">
  100. </el-table-column>
  101. <el-table-column label="法定代表人 " align="center" prop="fddbr">
  102. </el-table-column>
  103. <el-table-column label="企业代表联系方式 " align="center" prop="qydblxfs">
  104. </el-table-column>
  105. <el-table-column label="控股企业 " align="center" prop="kgqy">
  106. </el-table-column>
  107. <el-table-column label="注册资金" align="center" prop="zczj">
  108. </el-table-column>
  109. <el-table-column label="行业大类 " align="center" prop="hydl">
  110. </el-table-column>
  111. <el-table-column label="行业小类 " align="center" prop="hyxl">
  112. </el-table-column>
  113. <el-table-column label="企业类型 " align="center" prop="qylx">
  114. </el-table-column>
  115. <el-table-column label="是否外资企业 " align="center" prop="sfwzqy">
  116. </el-table-column>
  117. <el-table-column label="经营状态 " align="center" prop="jyzt">
  118. </el-table-column>
  119. <el-table-column label="统一社会信用代码 " align="center" prop="shtyxydm">
  120. </el-table-column>
  121. <el-table-column label="企业海关编码 " align="center" prop="qyhgbm">
  122. </el-table-column>
  123. <el-table-column label="人员规模" align="center" prop="rygm">
  124. </el-table-column>
  125. <el-table-column label="成立日期 " align="center" prop="clrq">
  126. </el-table-column>
  127. <el-table-column label="投产时间 " align="center" prop="tcsj">
  128. </el-table-column>
  129. <el-table-column label="经营期限自 " align="center" prop="jyqxz">
  130. </el-table-column>
  131. <el-table-column label="经营期限至 " align="center" prop="jyqxz1">
  132. </el-table-column>
  133. <el-table-column label="注册地址 " align="center" prop="zcdz" show-overflow-tooltip>
  134. </el-table-column>
  135. <el-table-column label="主营业务 " align="center" prop="zyyw" show-overflow-tooltip>
  136. </el-table-column>
  137. <el-table-column label="经营范围 " align="center" prop="jyfw" show-overflow-tooltip>
  138. </el-table-column>
  139. <el-table-column label="外汇等级 " align="center" prop="grade">
  140. <template slot-scope="scope">
  141. <span v-if="scope.row.grade == 1">A</span>
  142. <span v-if="scope.row.grade == 2">B</span>
  143. <span v-if="scope.row.grade == 3">C</span>
  144. <span v-if="scope.row.grade == 4">D</span>
  145. </template>
  146. </el-table-column>
  147. <el-table-column label="企业结构 " align="center" prop="enterpriseStructureValue">
  148. <template slot-scope="scope">
  149. <span>{{ selectDictLabel(dict.type.enterprise_structure, scope.row.enterpriseStructureValue) }}</span>
  150. </template>
  151. </el-table-column>
  152. <el-table-column label="企业资质 " align="center" prop="qyzz">
  153. </el-table-column>
  154. <el-table-column label="主要市场 " align="center" prop="zysc">
  155. </el-table-column>
  156. <el-table-column label="一般纳税人情况 " align="center" prop="ybnsrqk">
  157. </el-table-column>
  158. <el-table-column
  159. label="国家级奖项、发明专利 "
  160. align="center"
  161. prop="gjjjxfmzl"
  162. >
  163. </el-table-column>
  164. <el-table-column label="AEO情况 " align="center" prop="aeoqk">
  165. </el-table-column>
  166. <el-table-column
  167. label="检测、服务外包、文化服务创新 "
  168. align="center"
  169. prop="jcfwwbwhfwcx"
  170. >
  171. </el-table-column>
  172. <el-table-column label="创建时间" align="center" prop="createTime">
  173. </el-table-column>
  174. <el-table-column label="创建人" align="center" prop="createBy">
  175. </el-table-column>
  176. <el-table-column label="更新时间" align="center" prop="updateTime">
  177. </el-table-column>
  178. <el-table-column label="更新人" align="center" prop="updateBy">
  179. </el-table-column>
  180. <el-table-column
  181. fixed="right"
  182. label="操作"
  183. align="center"
  184. class-name="small-padding fixed-width"
  185. >
  186. <template slot-scope="scope">
  187. <el-button
  188. size="mini"
  189. type="text"
  190. icon="el-icon-edit"
  191. @click="handleUpdate(scope.row)"
  192. v-hasPermi="['business:GARDENBASEDATA:edit']"
  193. >修改</el-button
  194. >
  195. <el-button
  196. size="mini"
  197. type="text"
  198. icon="el-icon-delete"
  199. @click="handleDelete(scope.row)"
  200. v-hasPermi="['business:GARDENBASEDATA:remove']"
  201. >删除</el-button
  202. >
  203. </template>
  204. </el-table-column>
  205. </el-table>
  206. <pagination
  207. v-show="total > 0"
  208. :total="total"
  209. :page.sync="queryParams.pageNum"
  210. :limit.sync="queryParams.pageSize"
  211. @pagination="getList"
  212. />
  213. <!-- 添加或修改园区内企业基础数据对话框 -->
  214. <el-dialog :title="title" :visible.sync="open" :close-on-click-modal="false" width="65%" append-to-body>
  215. <el-tabs v-model="tabMsg" type="border-card">
  216. <el-tab-pane name="basicMsg" label="企业基本信息">
  217. <el-form ref="forms" :model="form" :rules="rules" label-width="180px">
  218. <el-row>
  219. <el-col :span="12">
  220. <el-form-item label="法定代表人" prop="fddbr">
  221. <el-input
  222. v-model="form.fddbr"
  223. placeholder="请输入法定代表人"
  224. ></el-input>
  225. </el-form-item>
  226. </el-col>
  227. <el-col :span="12">
  228. <el-form-item label="部门" prop="deptName">
  229. <!-- 树状结构组件引用 -->
  230. <select-tree :param="detpList" :placeholder="'请选择部门'" :modelValue="form.deptName" @setNodeValue="handleNodeClick" />
  231. </el-form-item>
  232. </el-col>
  233. </el-row>
  234. <el-row>
  235. <el-col :span="12">
  236. <el-form-item label="企业代表联系方式 " prop="qydblxfs">
  237. <el-input
  238. v-model="form.qydblxfs"
  239. placeholder="请输入企业代表联系方式 "
  240. ></el-input>
  241. </el-form-item>
  242. </el-col>
  243. <el-col :span="12">
  244. <el-form-item label="注册资金" prop="zczj">
  245. <el-input
  246. v-model="form.zczj"
  247. placeholder="请输入注册资金"
  248. ></el-input>
  249. </el-form-item>
  250. </el-col>
  251. </el-row>
  252. <el-row>
  253. <el-col :span="12">
  254. <el-form-item label="企业类型 " prop="qylx">
  255. <el-input
  256. v-model="form.qylx"
  257. placeholder="请输入企业类型 "
  258. ></el-input>
  259. </el-form-item>
  260. </el-col>
  261. <el-col :span="12">
  262. <el-form-item label="经营状态 " prop="jyzt">
  263. <el-input
  264. v-model="form.jyzt"
  265. placeholder="请输入经营状态 "
  266. ></el-input>
  267. </el-form-item>
  268. </el-col>
  269. </el-row>
  270. <el-row>
  271. <el-col :span="12">
  272. <el-form-item label="统一社会信用代码 " prop="shtyxydm">
  273. <el-input
  274. v-model="form.shtyxydm"
  275. placeholder="请输入统一社会信用代码 "
  276. ></el-input>
  277. </el-form-item>
  278. </el-col>
  279. <el-col :span="12">
  280. <el-form-item label="人员规模" prop="rygm">
  281. <el-input
  282. v-model="form.rygm"
  283. placeholder="请输入人员规模"
  284. ></el-input>
  285. </el-form-item>
  286. </el-col>
  287. </el-row>
  288. <el-row>
  289. <el-col :span="12">
  290. <el-form-item label="成立日期 " prop="clrq">
  291. <!-- <el-input v-model="form.clrq" placeholder="请输入成立日期 "></el-input> -->
  292. <el-date-picker
  293. style="width: 100%"
  294. value-format="yyyy-MM-dd"
  295. @change="setUpTimeSelect"
  296. v-model="form.clrq"
  297. type="date"
  298. placeholder="选择日期"
  299. >
  300. </el-date-picker>
  301. </el-form-item>
  302. </el-col>
  303. <el-col :span="12">
  304. <el-form-item label="注册地址 " prop="zcdz">
  305. <el-input
  306. v-model="form.zcdz"
  307. placeholder="请输入注册地址 "
  308. ></el-input>
  309. </el-form-item>
  310. </el-col>
  311. </el-row>
  312. <el-row>
  313. <el-col :span="12">
  314. <el-form-item label="经营范围 " prop="jyfw">
  315. <el-input
  316. v-model="form.jyfw"
  317. placeholder="请输入经营范围 "
  318. ></el-input>
  319. </el-form-item>
  320. </el-col>
  321. <el-col :span="12">
  322. <el-form-item label="外汇等级" prop="grade">
  323. <el-select v-model="form.grade" placeholder="请选择" style="width: 100%">
  324. <el-option
  325. v-for="item in options"
  326. :key="item.value"
  327. :label="item.label"
  328. :value="item.value"
  329. >
  330. </el-option>
  331. </el-select>
  332. </el-form-item>
  333. </el-col>
  334. </el-row>
  335. <el-row>
  336. <el-col :span="12">
  337. <el-form-item label="企业结构 " prop="enterpriseStructureValue">
  338. <el-select v-model="form.enterpriseStructureValue" placeholder="请选择" style="width: 100%">
  339. <el-option
  340. v-for="dict in dict.type.enterprise_structure"
  341. :key="dict.value"
  342. :label="dict.label"
  343. :value="dict.value"
  344. />
  345. </el-select>
  346. </el-form-item>
  347. </el-col>
  348. <el-col :span="12">
  349. <el-form-item label="业务构成 " prop="businessEventsValue">
  350. <el-select v-model="form.businessEventsValue" placeholder="请选择" style="width: 100%">
  351. <el-option
  352. v-for="dict in dict.type.business_events"
  353. :key="dict.value"
  354. :label="dict.label"
  355. :value="dict.value"
  356. />
  357. </el-select>
  358. </el-form-item>
  359. </el-col>
  360. </el-row>
  361. </el-form>
  362. </el-tab-pane>
  363. <!-- 额外信息 -->
  364. <el-tab-pane name="extraMsg" label="额外信息">
  365. <el-form ref="form" :model="form" :rules="rules" label-width="180px">
  366. <el-row>
  367. <el-col :span="12">
  368. <el-form-item label="控股企业 " prop="kgqy">
  369. <el-input
  370. v-model="form.kgqy"
  371. placeholder="请输入控股企业 "
  372. ></el-input>
  373. </el-form-item>
  374. </el-col>
  375. <el-col :span="12">
  376. <el-form-item label="行业大类 " prop="hydl">
  377. <el-input
  378. v-model="form.hydl"
  379. placeholder="请输入行业大类 "
  380. ></el-input>
  381. </el-form-item>
  382. </el-col>
  383. </el-row>
  384. <el-row>
  385. <el-col :span="12">
  386. <el-form-item label="行业小类 " prop="hyxl">
  387. <el-input
  388. v-model="form.hyxl"
  389. placeholder="请输入行业小类 "
  390. ></el-input>
  391. </el-form-item>
  392. </el-col>
  393. <el-col :span="12">
  394. <el-form-item label="是否外资企业 " prop="sfwzqy">
  395. <el-input
  396. v-model="form.sfwzqy"
  397. placeholder="请输入是否外资企业 "
  398. ></el-input>
  399. </el-form-item>
  400. </el-col>
  401. </el-row>
  402. <el-row>
  403. <el-col :span="12">
  404. <el-form-item label="企业海关编码 " prop="qyhgbm">
  405. <el-input
  406. v-model="form.qyhgbm"
  407. placeholder="请输入企业海关编码 "
  408. ></el-input>
  409. </el-form-item>
  410. </el-col>
  411. <el-col :span="12">
  412. <el-form-item label="投产时间 " prop="tcsj">
  413. <!-- <el-input v-model="form.tcsj" placeholder="请输入投产时间 "></el-input> -->
  414. <el-date-picker
  415. value-format="yyyy-MM-dd"
  416. @change="putTimeSelect"
  417. v-model="form.tcsj"
  418. type="date"
  419. placeholder="选择日期"
  420. >
  421. </el-date-picker>
  422. </el-form-item>
  423. </el-col>
  424. </el-row>
  425. <el-row>
  426. <el-col :span="12">
  427. <el-form-item label="经营期限自 " prop="jyqxz">
  428. <el-input
  429. v-model="form.jyqxz"
  430. placeholder="请输入经营期限自 "
  431. ></el-input>
  432. </el-form-item>
  433. </el-col>
  434. <el-col :span="12">
  435. <el-form-item label="经营期限至 " prop="jyqxz1">
  436. <el-input
  437. v-model="form.jyqxz1"
  438. placeholder="请输入经营期限至 "
  439. ></el-input>
  440. </el-form-item>
  441. </el-col>
  442. </el-row>
  443. <el-row>
  444. <el-col :span="12">
  445. <el-form-item label="主营业务 " prop="zyyw">
  446. <el-input
  447. v-model="form.zyyw"
  448. placeholder="请输入主营业务 "
  449. ></el-input>
  450. </el-form-item>
  451. </el-col>
  452. <el-col :span="12">
  453. <el-form-item label="企业资质 " prop="qyzz">
  454. <el-input
  455. v-model="form.qyzz"
  456. placeholder="请输入企业资质 "
  457. ></el-input>
  458. </el-form-item>
  459. </el-col>
  460. </el-row>
  461. <el-row>
  462. <el-col :span="12">
  463. <el-form-item label="主要市场 " prop="zysc">
  464. <el-input
  465. v-model="form.zysc"
  466. placeholder="请输入主要市场 "
  467. ></el-input>
  468. </el-form-item>
  469. </el-col>
  470. <el-col :span="12">
  471. <el-form-item label="一般纳税人情况 " prop="ybnsrqk">
  472. <el-input
  473. v-model="form.ybnsrqk"
  474. placeholder="请输入一般纳税人情况 "
  475. ></el-input>
  476. </el-form-item>
  477. </el-col>
  478. </el-row>
  479. <el-row>
  480. <el-col :span="12">
  481. <el-form-item label="国家级奖项、发明专利 " prop="gjjjxfmzl">
  482. <el-input
  483. v-model="form.gjjjxfmzl"
  484. placeholder="请输入国家级奖项、发明专利 "
  485. ></el-input>
  486. </el-form-item>
  487. </el-col>
  488. <el-col :span="12">
  489. <el-form-item label="AEO情况 " prop="aeoqk">
  490. <el-input
  491. v-model="form.aeoqk"
  492. placeholder="请输入AEO情况 "
  493. ></el-input>
  494. </el-form-item>
  495. </el-col>
  496. </el-row>
  497. <el-row>
  498. <el-col :span="12">
  499. <el-form-item
  500. label="检测、服务外包、文化服务创新 "
  501. prop="jcfwwbwhfwcx"
  502. >
  503. <el-input
  504. v-model="form.jcfwwbwhfwcx"
  505. placeholder="请输入检测、服务外包、文化服务创新 "
  506. ></el-input>
  507. </el-form-item>
  508. </el-col>
  509. <el-col :span="12"></el-col>
  510. </el-row>
  511. </el-form>
  512. </el-tab-pane>
  513. </el-tabs>
  514. <div slot="footer" class="dialog-footer">
  515. <el-button type="primary" @click="submitForm">确 定</el-button>
  516. <el-button @click="cancel">取 消</el-button>
  517. </div>
  518. </el-dialog>
  519. </div>
  520. </template>
  521. <script>
  522. import {
  523. listGARDENBASEDATA,
  524. getGARDENBASEDATA,
  525. delGARDENBASEDATA,
  526. addGARDENBASEDATA,
  527. updateGARDENBASEDATA,
  528. getEnterprise,
  529. } from "@/api/portal/GARDENBASEDATA/GARDENBASEDATA";
  530. import "@riophae/vue-treeselect/dist/vue-treeselect.css";
  531. import selectTree from '@/components/selectTree'
  532. export default {
  533. name: "GARDENBASEDATA",
  534. components: { selectTree },
  535. dicts: ['enterprise_structure', 'business_events'],
  536. data() {
  537. return {
  538. // 新增标签索引
  539. tabMsg: "basicMsg",
  540. // 部门列表
  541. detpList: [],
  542. // 根路径
  543. baseURL: process.env.VUE_APP_BASE_API,
  544. // 遮罩层
  545. loading: true,
  546. // 选中数组
  547. ids: [],
  548. // 非单个禁用
  549. single: true,
  550. // 非多个禁用
  551. multiple: true,
  552. // 显示搜索条件
  553. showSearch: true,
  554. // 总条数
  555. total: 0,
  556. // 园区内企业基础数据表格数据
  557. GARDENBASEDATAList: [],
  558. // 弹出层标题
  559. title: "",
  560. // 是否显示弹出层
  561. open: false,
  562. // 查询参数
  563. queryParams: {
  564. pageNum: 1,
  565. pageSize: 10,
  566. id: null,
  567. deptId: null,
  568. fddbr: null,
  569. qydblxfs: null,
  570. kgqy: null,
  571. zczj: null,
  572. hydl: null,
  573. hyxl: null,
  574. qylx: null,
  575. sfwzqy: null,
  576. jyzt: null,
  577. shtyxydm: null,
  578. qyhgbm: null,
  579. rygm: null,
  580. clrq: null,
  581. tcsj: null,
  582. jyqxz: null,
  583. jyqxz1: null,
  584. zcdz: null,
  585. zyyw: null,
  586. jyfw: null,
  587. qyzz: null,
  588. zysc: null,
  589. ybnsrqk: null,
  590. gjjjxfmzl: null,
  591. aeoqk: null,
  592. jcfwwbwhfwcx: null,
  593. createTime: null,
  594. createBy: null,
  595. updateTime: null,
  596. updateBy: null,
  597. },
  598. // 表单参数
  599. form: {},
  600. // 表单校验
  601. rules: {
  602. id: [
  603. {
  604. required: true,
  605. message: "园区内企业基础数据主键不能为空",
  606. trigger: "blur",
  607. },
  608. ],
  609. deptName: [
  610. { required: true, message: "部门不能为空", trigger: "blur" },
  611. ],
  612. fddbr: [
  613. { required: true, message: "法定代表人 不能为空", trigger: "blur" },
  614. ],
  615. qydblxfs: [
  616. {
  617. required: true,
  618. message: "企业代表联系方式 不能为空",
  619. trigger: "blur",
  620. },
  621. ],
  622. kgqy: [
  623. { required: true, message: "控股企业 不能为空", trigger: "blur" },
  624. ],
  625. zczj: [
  626. { required: true, message: "注册资金不能为空", trigger: "blur" },
  627. {
  628. pattern: /^[+]?(?:\d+(?:\.\d*)?|\.\d+)$/,
  629. message: "不能为负数",
  630. trigger: "blur"
  631. }
  632. ],
  633. hydl: [
  634. { required: true, message: "行业大类 不能为空", trigger: "blur" },
  635. ],
  636. hyxl: [
  637. { required: true, message: "行业小类 不能为空", trigger: "blur" },
  638. ],
  639. qylx: [
  640. { required: true, message: "企业类型 不能为空", trigger: "blur" },
  641. ],
  642. sfwzqy: [
  643. { required: true, message: "是否外资企业 不能为空", trigger: "blur" },
  644. ],
  645. jyzt: [
  646. { required: true, message: "经营状态 不能为空", trigger: "blur" },
  647. ],
  648. shtyxydm: [
  649. {
  650. required: true,
  651. message: "统一社会信用代码 不能为空",
  652. trigger: "blur",
  653. },
  654. ],
  655. qyhgbm: [
  656. { required: true, message: "企业海关编码 不能为空", trigger: "blur" },
  657. ],
  658. rygm: [
  659. { required: true, message: "人员规模不能为空", trigger: "blur" },
  660. {
  661. pattern: /^[1-9]\d*$/,
  662. message: "请输入正整数",
  663. trigger: "blur"
  664. }
  665. ],
  666. clrq: [
  667. { required: true, message: "成立日期 不能为空", trigger: "blur" },
  668. ],
  669. tcsj: [
  670. { required: true, message: "投产时间 不能为空", trigger: "blur" },
  671. ],
  672. jyqxz: [
  673. { required: true, message: "经营期限自 不能为空", trigger: "blur" },
  674. ],
  675. jyqxz1: [
  676. { required: true, message: "经营期限至 不能为空", trigger: "blur" },
  677. ],
  678. zcdz: [
  679. { required: true, message: "注册地址 不能为空", trigger: "blur" },
  680. ],
  681. zyyw: [
  682. { required: true, message: "主营业务 不能为空", trigger: "blur" },
  683. ],
  684. jyfw: [
  685. { required: true, message: "经营范围 不能为空", trigger: "blur" },
  686. ],
  687. qyzz: [
  688. { required: true, message: "企业资质 不能为空", trigger: "blur" },
  689. ],
  690. zysc: [
  691. { required: true, message: "主要市场 不能为空", trigger: "blur" },
  692. ],
  693. ybnsrqk: [
  694. {
  695. required: true,
  696. message: "一般纳税人情况 不能为空",
  697. trigger: "blur",
  698. },
  699. ],
  700. gjjjxfmzl: [
  701. {
  702. required: true,
  703. message: "国家级奖项、发明专利 不能为空",
  704. trigger: "blur",
  705. },
  706. ],
  707. aeoqk: [
  708. { required: true, message: "AEO情况 不能为空", trigger: "blur" },
  709. ],
  710. jcfwwbwhfwcx: [
  711. {
  712. required: true,
  713. message: "检测、服务外包、文化服务创新 不能为空",
  714. trigger: "blur",
  715. },
  716. ],
  717. grade: [
  718. { required: true, message: "外汇等级 不能为空", trigger: "blur" },
  719. ],
  720. enterpriseStructureValue: [
  721. { required: true, message: "企业结构 不能为空", trigger: "blur" },
  722. ],
  723. businessEventsValue: [
  724. { required: true, message: "业务构成 不能为空", trigger: "blur" },
  725. ]
  726. },
  727. options: [{
  728. value: 1,
  729. label: 'A'
  730. }, {
  731. value: 2,
  732. label: 'B'
  733. }, {
  734. value: 3,
  735. label: 'C'
  736. }],
  737. value: ''
  738. };
  739. },
  740. created() {
  741. this.getList();
  742. getEnterprise().then((res) => {
  743. this.detpList = res.data
  744. });
  745. },
  746. methods: {
  747. changeIsShowStatus(val) {
  748. this.isShowStatus = val;
  749. },
  750. handleNodeClick(data) {
  751. this.$set(this.form, 'deptId', data.deptId)
  752. this.$set(this.form, 'deptName', data.deptName)
  753. },
  754. setUpTimeSelect(val) {
  755. this.form.clrq = val;
  756. },
  757. putTimeSelect(val) {
  758. this.form.tcsj = val;
  759. },
  760. /** 查询园区内企业基础数据列表 */
  761. getList() {
  762. this.loading = true;
  763. listGARDENBASEDATA(this.queryParams).then((response) => {
  764. this.GARDENBASEDATAList = response.rows;
  765. this.total = response.total;
  766. this.loading = false;
  767. });
  768. },
  769. // 取消按钮
  770. cancel() {
  771. this.open = false;
  772. this.reset();
  773. },
  774. // 表单重置
  775. reset() {
  776. this.tabMsg = "basicMsg";
  777. this.form = {
  778. id: null,
  779. deptId: null,
  780. fddbr: null,
  781. qydblxfs: null,
  782. kgqy: null,
  783. zczj: null,
  784. hydl: null,
  785. hyxl: null,
  786. qylx: null,
  787. sfwzqy: null,
  788. jyzt: null,
  789. shtyxydm: null,
  790. qyhgbm: null,
  791. rygm: null,
  792. clrq: null,
  793. tcsj: null,
  794. jyqxz: null,
  795. jyqxz1: null,
  796. zcdz: null,
  797. zyyw: null,
  798. jyfw: null,
  799. qyzz: null,
  800. zysc: null,
  801. ybnsrqk: null,
  802. gjjjxfmzl: null,
  803. aeoqk: null,
  804. jcfwwbwhfwcx: null,
  805. };
  806. this.resetForm("form");
  807. this.resetForm("forms");
  808. },
  809. /** 搜索按钮操作 */
  810. handleQuery() {
  811. this.queryParams.pageNum = 1;
  812. this.getList();
  813. },
  814. /** 重置按钮操作 */
  815. resetQuery() {
  816. this.queryParams.deptId = null;
  817. this.resetForm("queryForm");
  818. this.handleQuery();
  819. },
  820. // 多选框选中数据
  821. handleSelectionChange(selection) {
  822. this.ids = selection.map((item) => item.id);
  823. this.single = selection.length !== 1;
  824. this.multiple = !selection.length;
  825. },
  826. /** 新增按钮操作 */
  827. handleAdd() {
  828. this.reset();
  829. this.open = true;
  830. this.title = "添加园区内企业基础数据";
  831. },
  832. /** 修改按钮操作 */
  833. handleUpdate(row) {
  834. this.reset();
  835. const id = row.id || this.ids;
  836. getGARDENBASEDATA(id).then((response) => {
  837. this.form = response.data;
  838. this.open = true;
  839. this.title = "修改园区内企业基础数据";
  840. });
  841. },
  842. /** 提交按钮 */
  843. submitForm() {
  844. let is;
  845. this.$refs["forms"].validate((valid)=>{
  846. if (valid) {
  847. }else{
  848. this.$message.error("请补齐企业基本信息")
  849. is = true;
  850. return;
  851. }
  852. });
  853. if (is) return;
  854. this.$refs["form"].validate((valid) => {
  855. if (valid) {
  856. // 获取企业结构 业务构成 label数据
  857. this.form.enterpriseStructure = this.dict.type.enterprise_structure.find(({value}) => value == this.form.enterpriseStructureValue).label
  858. this.form.businessEvents = this.dict.type.business_events.find(({value}) => value == this.form.businessEventsValue).label
  859. // 获取企业结构 业务构成 sort 排序数据
  860. this.form.enterpriseStructureSort = this.dict.type.enterprise_structure.find(({value}) => value == this.form.enterpriseStructureValue).raw.dictSort
  861. this.form.businessEventsSort = this.dict.type.business_events.find(({value}) => value == this.form.businessEventsValue).raw.dictSort
  862. if (this.form.id != null) {
  863. updateGARDENBASEDATA(this.form).then((response) => {
  864. this.$modal.msgSuccess("修改成功");
  865. this.open = false;
  866. this.getList();
  867. });
  868. } else {
  869. addGARDENBASEDATA(this.form).then((response) => {
  870. this.$modal.msgSuccess("新增成功");
  871. this.open = false;
  872. this.getList();
  873. });
  874. }
  875. } else {
  876. this.$message.error("请补齐额外信息");
  877. return;
  878. }
  879. });
  880. },
  881. /** 删除按钮操作 */
  882. handleDelete(row) {
  883. const ids = row.id || this.ids;
  884. this.$modal
  885. .confirm('是否确认删除园区内企业基础数据编号为"' + ids + '"的数据项?')
  886. .then(function () {
  887. return delGARDENBASEDATA(ids);
  888. })
  889. .then(() => {
  890. this.getList();
  891. this.$modal.msgSuccess("删除成功");
  892. })
  893. .catch(() => {});
  894. },
  895. /** 导出按钮操作 */
  896. handleExport() {
  897. this.download(
  898. "business/GARDENBASEDATA/export",
  899. {
  900. ...this.queryParams,
  901. },
  902. `GARDENBASEDATA_${new Date().getTime()}.xlsx`
  903. );
  904. },
  905. },
  906. };
  907. </script>
  908. <style>
  909. .el-tooltip__popper{font-size: 14px; max-width:40% }/* 设置显示隐藏部分内容,按40%显示 */
  910. </style>