companyRel.vue 46 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438
  1. <template>
  2. <div class="app-container zap-main">
  3. <el-row v-if="activeName === '0'" class="zap-table-search">
  4. <right-toolbar style="margin-top: 4px;" :showSearch.sync="showSearch" @queryTable="getList">收起</right-toolbar>
  5. <span class="zap-table-search__title">所选条件:</span>
  6. <div style="float: right;margin-right:1%">
  7. <el-button type="cyan" icon="el-icon-search" @click="handleQuery">搜索</el-button>
  8. <el-button icon="el-icon-refresh" @click="resetQuery" style="float: ;">重置</el-button>
  9. <column-setting
  10. class="zap-column-setting"
  11. :checkList="checkList"
  12. :tableList="tableList"
  13. :selfDom="selfDom"
  14. :tableId="tableId"
  15. ></column-setting>
  16. </div>
  17. <hr style="margin-top: 16px;" />
  18. <el-form
  19. :model="queryParams"
  20. ref="queryForm"
  21. :inline="true"
  22. v-show="showSearch"
  23. label-width="auto"
  24. >
  25. <el-form-item label="企业名称" prop="companyName" size="large">
  26. <el-input
  27. maxlength="30"
  28. v-model="queryParams.companyName"
  29. placeholder="请输入企业名称"
  30. clearable
  31. @keyup.enter.native="handleQuery"
  32. />
  33. </el-form-item>
  34. <el-form-item label="社会统一代码" prop="scySocialCode" size="large">
  35. <el-input
  36. maxlength="30"
  37. v-model="queryParams.scySocialCode"
  38. placeholder="请输入社会统一代码"
  39. clearable
  40. @keyup.enter.native="handleQuery"
  41. />
  42. </el-form-item>
  43. <el-form-item label="链属状态" prop="scrStatus" size="large">
  44. <el-select v-model="queryParams.scrStatus" placeholder="链属状态" clearable>
  45. <el-option
  46. v-for="dict in scrStatusOptions"
  47. :key="dict.dictValue"
  48. :label="dict.dictLabel"
  49. :value="dict.dictValue"
  50. ></el-option>
  51. </el-select>
  52. </el-form-item>
  53. <el-form-item label="认证状态" prop="scpStatus" size="large">
  54. <el-select v-model="queryParams.scpStatus" placeholder="认证状态" clearable>
  55. <el-option
  56. v-for="dict in scpStatusOptions"
  57. :key="dict.dictValue"
  58. :label="dict.dictLabel"
  59. :value="dict.dictValue"
  60. ></el-option>
  61. </el-select>
  62. </el-form-item>
  63. <el-form-item label="链属关系" prop="scrType" size="large">
  64. <el-select v-model="queryParams.scrType" placeholder="链属关系" clearable>
  65. <el-option
  66. v-for="dict in scrTypeOptions"
  67. :key="dict.dictValue"
  68. :label="dict.dictLabel"
  69. :value="dict.dictValue"
  70. ></el-option>
  71. </el-select>
  72. </el-form-item>
  73. </el-form>
  74. </el-row>
  75. <!-- 未认证列表 -->
  76. <el-row v-else-if="activeName === '1'" class="zap-table-search">
  77. <right-toolbar
  78. style="margin-top: 4px;"
  79. :showSearch.sync="showSearch"
  80. @queryTable="getSpare"
  81. >收起</right-toolbar>
  82. <span class="zap-table-search__title">所选条件:</span>
  83. <div style="float: right;margin-right:1%">
  84. <el-button type="cyan" icon="el-icon-search" @click="handleSpareQuery">搜索</el-button>
  85. <el-button icon="el-icon-refresh" @click="resetSpareQuery" style="float: ;">重置</el-button>
  86. </div>
  87. <hr style="margin-top: 16px;" />
  88. <el-form
  89. :model="spareParams"
  90. ref="querySpareForm"
  91. :inline="true"
  92. v-show="showSearch"
  93. label-width="auto"
  94. >
  95. <el-form-item label="企业名称" prop="companyName" size="large">
  96. <el-input
  97. maxlength="30"
  98. v-model="spareParams.companyName"
  99. placeholder="请输入企业名称"
  100. clearable
  101. @keyup.enter.native="handleSpareQuery"
  102. />
  103. </el-form-item>
  104. <el-form-item label="社会统一代码" prop="scySocialCode" size="large">
  105. <el-input
  106. maxlength="30"
  107. v-model="spareParams.scySocialCode"
  108. placeholder="请输入社会统一代码"
  109. clearable
  110. @keyup.enter.native="handleSpareQuery"
  111. />
  112. </el-form-item>
  113. <el-form-item label="链属关系" prop="scrType" size="large">
  114. <el-select v-model="spareParams.scrType" placeholder="请选择链属关系" clearable>
  115. <el-option
  116. v-for="dict in scrTypeOptions"
  117. :key="dict.dictValue"
  118. :label="dict.dictLabel"
  119. :value="dict.dictValue"
  120. ></el-option>
  121. </el-select>
  122. </el-form-item>
  123. </el-form>
  124. </el-row>
  125. <el-row class="zap-margin-top">
  126. <div class="zap-credit__tabs zap-credit__content">
  127. <div class="zap-credit__buttons">
  128. <el-button
  129. type="primary"
  130. icon="el-icon-plus"
  131. @click="handleAdd"
  132. v-hasPermi="['service:rel:add']"
  133. >新增</el-button>
  134. <el-button
  135. type="success"
  136. icon="el-icon-upload2"
  137. @click="handleImport"
  138. v-hasPermi="['service:relImport:importData']"
  139. >导入</el-button>
  140. </div>
  141. <el-tabs v-model="activeName">
  142. <el-tab-pane label="我的链属">
  143. <el-table class="zap-margin-top" v-loading="loading" :data="companyRelList" stripe>
  144. <el-table-column label="序号" type="index" width="50" align="center">
  145. <template slot-scope="scope">
  146. <span>{{(queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1}}</span>
  147. </template>
  148. </el-table-column>
  149. <el-table-column
  150. label="社会统一代码"
  151. align="center"
  152. prop="companyCode"
  153. v-if="uncheckList.companyCode"
  154. show-overflow-tooltip
  155. >
  156. <template slot-scope="scope">
  157. <span v-if="scope.row.launch">{{scope.row.receiveScySocialCode}}</span>
  158. <span v-if="scope.row.receive">{{scope.row.launchScySocialCode}}</span>
  159. <span v-if="scope.row.spare">{{scope.row.scpSocialCode}}</span>
  160. </template>
  161. </el-table-column>
  162. <el-table-column
  163. label="企业名称"
  164. align="center"
  165. prop="companyName"
  166. v-if="uncheckList.companyName"
  167. show-overflow-tooltip
  168. >
  169. <template slot-scope="scope">
  170. <span v-if="scope.row.launch">{{scope.row.receiveScyName}}</span>
  171. <span v-if="scope.row.receive">{{scope.row.launchScyName}}</span>
  172. <span v-if="scope.row.spare">{{scope.row.scpName}}</span>
  173. </template>
  174. </el-table-column>
  175. <el-table-column
  176. label="链属关系"
  177. align="center"
  178. prop="companyType"
  179. v-if="uncheckList.companyType"
  180. >
  181. <template slot-scope="scope">
  182. <span
  183. v-if="scope.row.launch"
  184. >{{companyTypeFormat(scope.row.launchScrReceiveType)}}</span>
  185. <span
  186. v-if="scope.row.receive"
  187. >{{companyTypeFormat(scope.row.launchScrLaunchType)}}</span>
  188. <span v-if="scope.row.spare">{{companyTypeFormat(scope.row.scpType)}}</span>
  189. </template>
  190. </el-table-column>
  191. <!-- <el-table-column
  192. label="联系人"
  193. align="center"
  194. prop="scpContarct"
  195. v-if="uncheckList.scpContarct"
  196. ></el-table-column>
  197. <el-table-column
  198. label="联系电话"
  199. align="center"
  200. prop="scpContarctPhone"
  201. v-if="uncheckList.scpContarctPhone"
  202. ></el-table-column>
  203. <el-table-column
  204. label="邮箱"
  205. align="center"
  206. prop="scpContarctEmail"
  207. v-if="uncheckList.scpContarctEmail"
  208. show-overflow-tooltip
  209. ></el-table-column> -->
  210. <el-table-column
  211. label="链属状态"
  212. align="center"
  213. prop="launchScrStatus"
  214. v-if="uncheckList.launchScrStatus"
  215. :formatter="launchScrStatusFormat"
  216. ></el-table-column>
  217. <el-table-column
  218. label="认证状态"
  219. align="center"
  220. prop="scpStatus"
  221. v-if="uncheckList.scpStatus"
  222. :formatter="scpStatusFormat"
  223. ></el-table-column>
  224. <el-table-column
  225. label="操作"
  226. align="center"
  227. class-name="small-padding fixed-width"
  228. width="150"
  229. >
  230. <template slot-scope="scope">
  231. <el-button
  232. v-if="!scope.row.spare"
  233. size="mini"
  234. type="text"
  235. @click="handleCompanyQuery(scope.row)"
  236. v-hasPermi="['service:rel:query']"
  237. >详情</el-button>
  238. <el-button
  239. v-if="scope.row.launch && scope.row.launchScrStatus == '02'"
  240. size="mini"
  241. type="text"
  242. @click="handleRelInvite(scope.row)"
  243. v-hasPermi="['service:rel:again']"
  244. >重邀</el-button>
  245. <el-button
  246. v-if="handleRel && scope.row.launchScrStatus == '01'"
  247. size="mini"
  248. type="text"
  249. @click="handleDelete(scope.row)"
  250. v-hasPermi="['service:rel:delete']"
  251. >解绑</el-button>
  252. <el-button
  253. v-if="scope.row.spare && scope.row.scpStatus == '00'"
  254. size="mini"
  255. type="text"
  256. @click="handleSpareDelete(scope.row)"
  257. v-hasPermi="['service:spare:removeSpare']"
  258. >解绑</el-button>
  259. <el-button
  260. v-if="
  261. scope.row.scpInvite == '1' && scope.row.scpStatus == '00'
  262. && scope.row.scpContarct && scope.row.scpContarctPhone
  263. "
  264. size="mini"
  265. type="text"
  266. @click="handleInvite(scope.row)"
  267. v-hasPermi="['service:spare:invite']"
  268. >重邀</el-button>
  269. <el-button
  270. v-if="handleRel && scope.row.launchScrStatus =='00' && scope.row.receive"
  271. size="mini"
  272. type="text"
  273. @click="handleSuccess(scope.row)"
  274. v-hasPermi="['service:rel:update']"
  275. >确认链属</el-button>
  276. <el-button
  277. v-if="handleRel && scope.row.launchScrStatus =='00' && scope.row.receive"
  278. size="mini"
  279. type="text"
  280. @click="handleRefuse(scope.row)"
  281. v-hasPermi="['service:rel:update']"
  282. >拒绝</el-button>
  283. </template>
  284. </el-table-column>
  285. </el-table>
  286. <pagination
  287. v-show="total > 0"
  288. :total="total"
  289. :page.sync="queryParams.pageNum"
  290. :limit.sync="queryParams.pageSize"
  291. @pagination="getList"
  292. />
  293. </el-tab-pane>
  294. <el-tab-pane label="链属未认证">
  295. <!-- 未认证企业信息列表 -->
  296. <el-table v-loading="loading" :data="spareOwnlist" stripe>
  297. <el-table-column label="序号" type="index" width="50" align="center">
  298. <template slot-scope="scope">
  299. <span>{{(spareParams.pageNum - 1) * spareParams.pageSize + scope.$index + 1}}</span>
  300. </template>
  301. </el-table-column>
  302. <el-table-column
  303. label="企业名称"
  304. align="center"
  305. prop="scpName"
  306. show-overflow-tooltip
  307. />
  308. <el-table-column
  309. label="社会统一代码"
  310. align="center"
  311. prop="scpSocialCode"
  312. show-overflow-tooltip
  313. />
  314. <el-table-column
  315. label="链属关系"
  316. align="center"
  317. prop="scpType"
  318. :formatter="scpTypeFormat"
  319. />
  320. <!-- <el-table-column label="联系人" align="center" width="83" prop="scpContarct" /> -->
  321. <!-- <el-table-column
  322. label="联系电话"
  323. align="center"
  324. width="109"
  325. prop="scpContarctPhone"
  326. show-overflow-tooltip
  327. />
  328. <el-table-column
  329. label="邮箱"
  330. align="center"
  331. width="187"
  332. prop="scpContarctEmail"
  333. show-overflow-tooltip
  334. /> -->
  335. <el-table-column
  336. label="状态"
  337. align="center"
  338. prop="scpStatus"
  339. :formatter="scpStatusFormat"
  340. />
  341. <el-table-column
  342. label="操作"
  343. align="center"
  344. class-name="small-padding fixed-width"
  345. >
  346. <template slot-scope="scope">
  347. <el-button
  348. v-if="scope.row.scpInvite == '1' && scope.row.scpContarct && scope.row.scpContarctPhone"
  349. size="mini"
  350. type="text"
  351. @click="handleInvite(scope.row)"
  352. v-hasPermi="['service:spare:invite']"
  353. >重邀</el-button>
  354. <el-button
  355. size="mini"
  356. type="text"
  357. @click="handleSpareDelete(scope.row)"
  358. v-hasPermi="['service:spare:removeSpare']"
  359. >解绑</el-button>
  360. </template>
  361. </el-table-column>
  362. </el-table>
  363. <pagination
  364. v-show="spareTitol > 0"
  365. :total="spareTitol"
  366. :page.sync="spareParams.pageNum"
  367. :limit.sync="spareParams.pageSize"
  368. @pagination="getSpare"
  369. />
  370. </el-tab-pane>
  371. <!-- 添加链属框 -->
  372. <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
  373. <el-form ref="form" :model="form" :rules="rules" label-width="auto" :inline="true">
  374. <el-form-item label="企业编号" prop="scyId" style="display:none" size="large">
  375. <el-input v-model="form.scyId" disabled />
  376. </el-form-item>
  377. <el-form-item label="链属关系" prop="scrReceiveType" size="large">
  378. <el-select v-model="form.scrReceiveType" placeholder="请选择链属关系" clearable>
  379. <el-option
  380. v-for="dict in scrTypeOptions"
  381. :key="dict.dictValue"
  382. :label="dict.dictLabel"
  383. :value="dict.dictValue"
  384. ></el-option>
  385. </el-select>
  386. </el-form-item>
  387. <el-form-item label="企业名称" prop="scyName" size="large">
  388. <el-select
  389. v-model="form.scyName"
  390. filterable
  391. allow-create
  392. clearable
  393. @clear="clearRemote"
  394. @change="choice"
  395. remote
  396. reserve-keyword
  397. placeholder="请输入关键词"
  398. :remote-method="remoteMethod"
  399. >
  400. <el-option
  401. v-for="item in companyList"
  402. :key="item.value"
  403. :label="item.label"
  404. :value="item.label"
  405. ></el-option>
  406. </el-select>
  407. </el-form-item>
  408. <el-form-item label="企业统一代码" prop="scySocialCode" size="large">
  409. <el-input
  410. v-model="form.scySocialCode"
  411. placeholder="请输入企业统一代码"
  412. maxlength="18"
  413. show-word-limit
  414. />
  415. </el-form-item>
  416. <el-form-item label="联系人" prop="scrContarct" size="large">
  417. <el-input
  418. v-model="form.scrContarct"
  419. placeholder="请输入联系人"
  420. maxlength="10"
  421. show-word-limit
  422. />
  423. </el-form-item>
  424. <el-form-item label="联系人手机号" prop="scrContarctPhone" size="large">
  425. <el-input
  426. v-model="form.scrContarctPhone"
  427. placeholder="请输入联系人手机号"
  428. maxlength="11"
  429. show-word-limit
  430. />
  431. </el-form-item>
  432. <el-form-item label="邮箱" prop="scrContarctEmail" size="large">
  433. <el-input
  434. v-model="form.scrContarctEmail"
  435. placeholder="请输入邮箱"
  436. maxlength="60"
  437. show-word-limit
  438. />
  439. </el-form-item>
  440. </el-form>
  441. <el-row style="height: 109px;" type="flex" align="middle" justify="center">
  442. <el-button type="primary" plain @click="cancel">取 消</el-button>
  443. <el-button type="primary" @click="submitForm">确 定</el-button>
  444. </el-row>
  445. </el-dialog>
  446. <!-- 企业详情对话框 -->
  447. <el-dialog :title="titleDetail" :visible.sync="openDetail" width="800px" append-to-body>
  448. <el-form ref="formDetail" :model="formDetail" label-width="140px" :inline="true">
  449. <el-form-item label="企业名称" prop="scyName">
  450. <el-input
  451. v-model="formDetail.scyName"
  452. placeholder="请输入企业名称"
  453. disabled
  454. style="width:560px"
  455. maxlength="20"
  456. show-word-limit
  457. />
  458. </el-form-item>
  459. <el-form-item label="企业统一代码" prop="scySocialCode">
  460. <el-input
  461. v-model="formDetail.scySocialCode"
  462. placeholder="请输入企业统一代码"
  463. disabled
  464. maxlength="18"
  465. show-word-limit
  466. />
  467. </el-form-item>
  468. <el-form-item label="联系人" prop="scyLegal">
  469. <el-input
  470. v-model="formDetail.scyLegal"
  471. placeholder="请输入联系人"
  472. disabled
  473. maxlength="5"
  474. show-word-limit
  475. />
  476. </el-form-item>
  477. <el-form-item label="联系人手机号" prop="scyPhone">
  478. <el-input
  479. v-model="formDetail.scyPhone"
  480. placeholder="请输入联系人手机号"
  481. disabled
  482. maxlength="11"
  483. show-word-limit
  484. />
  485. </el-form-item>
  486. </el-form>
  487. <div slot="footer" class="dialog-footer">
  488. <el-button @click="cancelDetail">取 消</el-button>
  489. </div>
  490. </el-dialog>
  491. <!-- 导入窗口 -->
  492. <el-dialog
  493. class="zap-upload-invoice"
  494. :visible.sync="upload.open"
  495. width="600px"
  496. :show-close="false"
  497. append-to-body
  498. >
  499. <el-row
  500. slot="title"
  501. class="zap-upload-invoice__title"
  502. type="flex"
  503. align="middle"
  504. justify="space-between"
  505. >
  506. <span class="title">{{upload.title}}</span>
  507. <i class="el-icon-close" @click="upload.open = false"></i>
  508. </el-row>
  509. <el-row class="zap-upload-invoice__top">
  510. <span class="zap-upload-invoice__top-text">提示:仅允许导入“xls”或“xlsx”格式文件!</span>
  511. </el-row>
  512. <el-row type="flex" align="middle" justify="center">
  513. <el-upload
  514. class="zap-upload-invoice__form"
  515. ref="upload"
  516. :limit="1"
  517. accept=".xlsx, .xls"
  518. :headers="upload.headers"
  519. :action="upload.url + '?updateSupport=' + upload.updateSupport"
  520. :disabled="upload.isUploading"
  521. :on-progress="handleFileUploadProgress"
  522. :on-success="handleFileSuccess"
  523. :auto-upload="false"
  524. drag
  525. >
  526. <div class="zap-upload-invoce__inner">
  527. <i class="el-icon-upload" style="font-size: 64px;color: #21b24b"></i>
  528. <div class="zap-upload-invoice__text">
  529. 将文件拖到此处,或
  530. <span>点击上传</span>
  531. </div>
  532. <div class="zap-upload-invoice__tip">按住Ctrl可同时多选,单个文件不能超过2mb</div>
  533. <div class="zap-upload-invoice__tip">严禁上传包含色情、暴力、反动等相关违法信息的文件。</div>
  534. </div>
  535. <div class="el-upload__tip" slot="tip">
  536. <el-link type="info" style="font-size:12px" @click="importTemplate">下载模板</el-link>
  537. </div>
  538. </el-upload>
  539. </el-row>
  540. <el-row style="height: 109px;" type="flex" align="middle" justify="center">
  541. <el-button type="primary" @click="submitFileForm">确 定</el-button>
  542. <el-button @click="upload.open = false">取 消</el-button>
  543. </el-row>
  544. </el-dialog>
  545. </el-tabs>
  546. </div>
  547. </el-row>
  548. </div>
  549. </template>
  550. <script>
  551. import {
  552. listRel,
  553. sparelist,
  554. listCompany,
  555. addRel,
  556. updateRel,
  557. listAllCompany,
  558. againRel,
  559. delRel,
  560. removeSpare,
  561. listCompanyQuery,
  562. getUser,
  563. againInvite,
  564. getListRel
  565. } from "@/api/service/rel/companyRel";
  566. import { uploadFileNew } from "@/api/common/file";
  567. import { getToken } from "@/utils/auth";
  568. import { columnQuery, columnfilter } from "@/api/common/columnSetting";
  569. import ColumnSetting from "../../../components/Table/columnSetting.vue";
  570. import Cookies from "js-cookie";
  571. export default {
  572. name: "companyRel",
  573. components: {
  574. ColumnSetting
  575. },
  576. data() {
  577. return {
  578. activeName: "",
  579. //操作员企业Id
  580. loginId: "",
  581. userId: "",
  582. scyTypeNow: "",
  583. handleRel: false,
  584. // 遮罩层
  585. loading: true,
  586. // 选中数组
  587. ids: [],
  588. // 非单个禁用
  589. single: true,
  590. rel: true,
  591. spare: false,
  592. // 非多个禁用
  593. multiple: true,
  594. // 显示搜索条件
  595. showSearch: true,
  596. // 总条数
  597. total: 0,
  598. spareTitol: 0,
  599. // 公司数据
  600. companyList: [],
  601. //链属表格数据
  602. companyRelList: [],
  603. //链属未认证列表数据
  604. spareOwnlist: [],
  605. // 状态数据字典
  606. scrStatusOptions: [],
  607. scrTypeOptions: [],
  608. scpStatusOptions: [],
  609. listCom: [],
  610. comlist: [],
  611. // 弹出层标题
  612. title: "",
  613. templateTitle: "",
  614. titleDetail: "",
  615. // 是否显示弹出层
  616. open: false,
  617. templateOpen: false,
  618. openDetail: false,
  619. idShow: true,
  620. // 导入参数
  621. upload: {
  622. // 是否显示弹出层(导入)
  623. open: false,
  624. // 弹出层标题(导入)
  625. title: "",
  626. // 是否禁用上传
  627. isUploading: false,
  628. // 是否更新已经存在的用户数据
  629. updateSupport: 0,
  630. // 设置上传的请求头部
  631. headers: { Authorization: "Bearer " + getToken() },
  632. // 上传的地址
  633. url: process.env.VUE_APP_BASE_API + "/sc-service/relImport/importData"
  634. },
  635. // 链属查询参数
  636. queryParams: {
  637. pageNum: 1,
  638. pageSize: 10,
  639. companyName: null,
  640. scySocialCode: null,
  641. scrStatus: null,
  642. scrType: null,
  643. scpStatus: null
  644. },
  645. //未认证列表查询参数
  646. spareParams: {
  647. pageNum: 1,
  648. pageSize: 10,
  649. scySocialCode: null,
  650. companyName: null,
  651. scrType: null
  652. },
  653. //企业列表查询参数
  654. companyQueryParams: {
  655. pageNum: 1,
  656. pageSize: 10,
  657. scyName: null
  658. },
  659. //筛选按钮的数据列表,与table表头的数据一致 --显示隐藏列用
  660. tableList: [
  661. {
  662. label: "companyCode",
  663. value: "社会统一代码"
  664. },
  665. {
  666. label: "companyName",
  667. value: "企业名称"
  668. },
  669. {
  670. label: "companyType",
  671. value: "链属关系"
  672. },
  673. // {
  674. // label: "scpContarct",
  675. // value: "联系人"
  676. // },
  677. // {
  678. // label: "scpContarctPhone",
  679. // value: "联系电话"
  680. // },
  681. // {
  682. // label: "scpContarctEmail",
  683. // value: "邮箱"
  684. // },
  685. {
  686. label: "launchScrStatus",
  687. value: "链属状态"
  688. },
  689. {
  690. label: "scpStatus",
  691. value: "认证状态"
  692. }
  693. ],
  694. checkList: [], //筛选列选中的数据列表--显示隐藏列用
  695. uncheckList: {}, //控制筛选列显示隐藏--显示隐藏列用
  696. selfDom: this,
  697. tableId: "/sc-service/rel/list",
  698. // 表单参数
  699. form: {
  700. scyId: null,
  701. scrReceiveType: null,
  702. scyName: null,
  703. scySocialCode: null,
  704. scrContarct: null,
  705. scrContarctPhone: null,
  706. scrContarctEmail: null
  707. },
  708. templateForm: {
  709. scyId: null
  710. },
  711. formDetail: {
  712. scyName: null,
  713. scySocialCode: null,
  714. scyLegal: null,
  715. scyPhone: null
  716. },
  717. companyId: null,
  718. // 表单校验
  719. rules: {
  720. scyName: [
  721. {
  722. required: true,
  723. message: "企业名称不能为空",
  724. trigger: ["blur", "change"]
  725. },
  726. {
  727. pattern: /^[0-9A-Z\u4E00-\u9FFF《》()()-]+$/,
  728. message: "企业名称不能带有特殊字符",
  729. trigger: ["blur", "change"]
  730. }
  731. ],
  732. scrReceiveType: [
  733. {
  734. required: true,
  735. message: "链属关系不能为空",
  736. trigger: ["blur", "change"]
  737. }
  738. ],
  739. scrContarct: [
  740. {
  741. pattern: /^[A-Za-z\u4e00-\u9fa5]+$/,
  742. message: "联系人不能带有特殊字符",
  743. trigger: ["blur", "change"]
  744. }
  745. ],
  746. scrContarctPhone: [
  747. {
  748. pattern: /^((\d{3}-\d{7,8}|\d{4}-\d{7,8})|(1[3465789]\d{9}))$/,
  749. message: "手机号格式不正确",
  750. trigger: ["blur", "change"]
  751. }
  752. ],
  753. scySocialCode: [
  754. { required: true, message: "企业统一代码不能为空", trigger: "blur" },
  755. {
  756. pattern: /^([0-9A-HJ-NPQRTUWXY]{2}\d{6}[0-9A-HJ-NPQRTUWXY]{10}|[1-9]\d{14})$/,
  757. message: "企业统一代码格式不正确",
  758. trigger: ["blur", "change"]
  759. }
  760. ],
  761. scrContarctEmail: [
  762. {
  763. pattern: /^([a-z0-9A-Z]+[-|_|\.]?)+[a-z0-9A-Z]@([a-z0-9A-Z]+(-[a-z0-9A-Z]+)?\.)+[a-zA-Z]{2,}$/,
  764. message: "邮箱格式不正确",
  765. trigger: ["blur", "change"]
  766. }
  767. ]
  768. },
  769. templateRules: {
  770. scyId: [
  771. { required: true, message: "核心企业不能为空", trigger: "blur" }
  772. ]
  773. }
  774. };
  775. },
  776. created() {
  777. this.getDicts("sys_scr_status").then(response => {
  778. this.scrStatusOptions = response.data;
  779. });
  780. this.getDicts("sys_scr_type").then(response => {
  781. this.scrTypeOptions = response.data;
  782. });
  783. this.getDicts("sys_scp_status").then(response => {
  784. this.scpStatusOptions = response.data;
  785. });
  786. this.getUser();
  787. this.getSpare();
  788. this.getCompanyList();
  789. },
  790. mounted() {
  791. this.columnQuery();
  792. },
  793. methods: {
  794. //获取当前客户是否之前设置过列展示隐藏
  795. columnQuery() {
  796. //获取页面路径
  797. var psfPagePath = window.location.pathname;
  798. //用请求后台的url作为唯一标识
  799. var psfTableName = this.tableId;
  800. var columnForm = {};
  801. columnForm.psfPagePath = psfPagePath;
  802. columnForm.psfTableName = psfTableName;
  803. columnQuery(columnForm).then(response => {
  804. if (response.data && response.data.psfShowData) {
  805. this.checkList = response.data.psfShowData;
  806. }
  807. this.filter();
  808. });
  809. },
  810. //控制隐藏显示的函数
  811. filter(checkList) {
  812. if (!!checkList) {
  813. this.checkList = checkList;
  814. }
  815. columnfilter(this.selfDom);
  816. },
  817. // 菜单状态字典翻译
  818. companyTypeFormat(companyType) {
  819. return this.selectDictLabel(this.scrTypeOptions, companyType);
  820. },
  821. scpTypeFormat(row, column) {
  822. return this.selectDictLabel(this.scrTypeOptions, row.scpType);
  823. },
  824. scpStatusFormat(row, column) {
  825. return this.selectDictLabel(this.scpStatusOptions, row.scpStatus);
  826. },
  827. launchScrStatusFormat(row, column) {
  828. return this.selectDictLabel(this.scrStatusOptions, row.launchScrStatus);
  829. },
  830. //平台导出模板
  831. submitTemplateForm() {
  832. this.$refs["templateForm"].validate(valid => {
  833. let fd = new FormData();
  834. for (var key in self.form) {
  835. fd.append(key, self.form[key]);
  836. }
  837. if (valid) {
  838. this.download(
  839. "/sc-service/relImport/importTemplate",
  840. {
  841. ...this.templateForm
  842. },
  843. `链属模板_${new Date().getTime()}.xls`
  844. );
  845. this.cancelTemplateForm();
  846. }
  847. });
  848. },
  849. //取消导出模板选择企业
  850. cancelTemplateForm() {
  851. this.templateOpen = false;
  852. this.templateForm = {};
  853. },
  854. /** 导入按钮操作 */
  855. handleImport() {
  856. this.upload.title = "链属导入";
  857. this.upload.open = true;
  858. },
  859. /** 下载模板操作 */
  860. importTemplate() {
  861. this.download(
  862. "/sc-service/relImport/importTemplate",
  863. {
  864. ...this.queryParams
  865. },
  866. `链属模板_${new Date().getTime()}.xls`
  867. );
  868. },
  869. /* 平台下载模板操作 */
  870. importAdminTemplate() {
  871. this.templateTitle = "核心企业";
  872. this.templateOpen = true;
  873. },
  874. // 文件上传中处理
  875. handleFileUploadProgress(event, file, fileList) {
  876. this.upload.isUploading = true;
  877. },
  878. // 文件上传成功处理
  879. handleFileSuccess(response, file, fileList) {
  880. this.upload.open = false;
  881. this.upload.isUploading = false;
  882. this.$refs.upload.clearFiles();
  883. this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
  884. this.getUser();
  885. this.getSpare();
  886. this.getCompanyList();
  887. },
  888. // 提交上传文件
  889. submitFileForm() {
  890. this.$refs.upload.submit();
  891. },
  892. /** 查询链属列表 */
  893. getList() {
  894. this.loading = true;
  895. if (this.companyId == "000000") {
  896. getListRel(this.queryParams).then(response => {
  897. let list = response.data.records;
  898. this.loginId = response.msg;
  899. for (let i = 0; i < list.length; i++) {
  900. if (list[i].launchCompanyId == response.msg) {
  901. list[i].receive = false;
  902. list[i].launch = true;
  903. list[i].spare = false;
  904. } else if (list[i].launchReceiveScrCompanyId == response.msg) {
  905. list[i].launch = false;
  906. list[i].receive = true;
  907. list[i].spare = false;
  908. } else if (list[i].scpCompanyId == response.msg) {
  909. list[i].launch = false;
  910. list[i].receive = false;
  911. list[i].spare = true;
  912. }
  913. }
  914. this.companyRelList = list;
  915. console.log(12312313123);
  916. console.log(this.companyRelList);
  917. this.total = response.data.total;
  918. this.loading = false;
  919. });
  920. } else {
  921. listRel(this.queryParams).then(response => {
  922. let list = response.data.records;
  923. this.loginId = response.msg;
  924. for (let i = 0; i < list.length; i++) {
  925. if (list[i].launchCompanyId == response.msg) {
  926. list[i].receive = false;
  927. list[i].launch = true;
  928. list[i].spare = false;
  929. } else if (list[i].launchReceiveScrCompanyId == response.msg) {
  930. list[i].launch = false;
  931. list[i].receive = true;
  932. list[i].spare = false;
  933. } else if (list[i].scpCompanyId == response.msg) {
  934. list[i].launch = false;
  935. list[i].receive = false;
  936. list[i].spare = true;
  937. }
  938. }
  939. this.companyRelList = list;
  940. console.log(12312313123);
  941. console.log(this.companyRelList);
  942. this.total = response.data.total;
  943. this.loading = false;
  944. });
  945. }
  946. },
  947. // 未认证列表
  948. getSpare() {
  949. this.loading = true;
  950. sparelist(this.spareParams).then(response => {
  951. this.spareOwnlist = response.data.records;
  952. this.spareTitol = response.data.total;
  953. this.loading = false;
  954. });
  955. },
  956. //查询所有企业
  957. getCompanyList() {
  958. this.loading = true;
  959. listAllCompany().then(response => {
  960. this.comlist = response.data;
  961. this.listCom = this.comlist.map(item => {
  962. return { value: item.scyId, label: item.scyName };
  963. });
  964. });
  965. },
  966. clearRemote() {
  967. let query = "";
  968. this.form.scyId = "";
  969. this.form.scyName = "";
  970. this.form.scySocialCode = "";
  971. this.idShow = true;
  972. this.remoteMethod(query);
  973. },
  974. //选择企业
  975. remoteMethod(query) {
  976. if (query) {
  977. this.loading = true;
  978. setTimeout(() => {
  979. this.loading = false;
  980. this.companyList = this.listCom.filter(item => {
  981. return item.label.toLowerCase().indexOf(query.toLowerCase()) > -1;
  982. });
  983. }, 200);
  984. } else {
  985. this.companyList = [];
  986. }
  987. },
  988. //选择企业后反显
  989. choice(item) {
  990. if (item) {
  991. let scyId;
  992. for (var company of this.companyList) {
  993. if (company.label == item) {
  994. scyId = company.value;
  995. break;
  996. }
  997. }
  998. if (scyId) {
  999. listCompanyQuery(scyId).then(response => {
  1000. if (response.data.length > 0) {
  1001. this.$set(this.form, "scyName", response.data[0].scyName);
  1002. this.$set(
  1003. this.form,
  1004. "scySocialCode",
  1005. response.data[0].scySocialCode
  1006. );
  1007. }
  1008. });
  1009. }
  1010. }
  1011. },
  1012. // 取消按钮
  1013. cancel() {
  1014. this.open = false;
  1015. this.clearRemote();
  1016. this.reset();
  1017. },
  1018. cancelDetail() {
  1019. this.openDetail = false;
  1020. this.reset();
  1021. },
  1022. // 表单重置
  1023. reset() {
  1024. this.clearRemote();
  1025. this.resetForm("form");
  1026. this.resetForm("formDetail");
  1027. },
  1028. /** 搜索按钮操作 */
  1029. handleQuery() {
  1030. this.queryParams.pageNum = 1;
  1031. this.getUser();
  1032. },
  1033. /** 未认证搜索按钮操作 */
  1034. handleSpareQuery() {
  1035. this.spareParams.pageNum = 1;
  1036. this.getSpare();
  1037. },
  1038. /** 重置按钮操作 */
  1039. resetQuery() {
  1040. this.resetForm("queryForm");
  1041. this.handleQuery();
  1042. },
  1043. /** 未认证重置按钮操作 */
  1044. resetSpareQuery() {
  1045. this.resetForm("querySpareForm");
  1046. this.handleSpareQuery();
  1047. },
  1048. /** 新增按钮操作 */
  1049. handleAdd() {
  1050. this.reset();
  1051. this.open = true;
  1052. this.title = "新增链属";
  1053. },
  1054. //查询企业详情
  1055. handleCompanyQuery(row) {
  1056. this.resetForm("queryForm");
  1057. this.resetForm("querySpareForm");
  1058. if (row.receive == true) {
  1059. const scyId = row.launchCompanyId;
  1060. listCompanyQuery(scyId).then(response => {
  1061. if (response.data[0].scyStatus == "00") {
  1062. Cookies.set(
  1063. "/rel/detailComPany/" + scyId + "/",
  1064. this.$route.fullPath
  1065. );
  1066. this.$router.push("/rel/detailComPany/" + scyId + "/");
  1067. } else {
  1068. this.formDetail = response.data[0];
  1069. this.openDetail = true;
  1070. this.titleDetail = "详情企业信息";
  1071. }
  1072. });
  1073. } else if (row.launch == true) {
  1074. const scyId = row.launchReceiveScrCompanyId;
  1075. listCompanyQuery(scyId).then(response => {
  1076. if (response.data[0].scyStatus == "00") {
  1077. Cookies.set(
  1078. "/rel/detailComPany/" + scyId + "/",
  1079. this.$route.fullPath
  1080. );
  1081. this.$router.push("/rel/detailComPany/" + scyId + "/");
  1082. } else {
  1083. this.formDetail = response.data[0];
  1084. this.openDetail = true;
  1085. this.titleDetail = "详情企业信息";
  1086. }
  1087. });
  1088. }
  1089. },
  1090. /** 提交按钮 */
  1091. submitForm() {
  1092. var self = this;
  1093. this.$refs["form"].validate(valid => {
  1094. let fd = new FormData();
  1095. for (var key in self.form) {
  1096. fd.append(key, self.form[key]);
  1097. }
  1098. if (valid) {
  1099. const loading = this.$loading({
  1100. lock: true,
  1101. text: "Loading",
  1102. spinner: "el-icon-loading",
  1103. background: "rgba(0, 0, 0, 0.7)"
  1104. });
  1105. // for (var company of this.companyList) {
  1106. // if (company.value == self.form.scyId) {
  1107. // self.form.scyName = company.label;
  1108. // break;
  1109. // }
  1110. // }
  1111. console.log(self.form, "提交表单");
  1112. debugger;
  1113. addRel(self.form)
  1114. .then(response => {
  1115. this.msgSuccess("新增成功");
  1116. loading.close();
  1117. this.open = false;
  1118. this.getUser();
  1119. this.getSpare();
  1120. this.getCompanyList();
  1121. })
  1122. .catch(response => {
  1123. loading.close();
  1124. });
  1125. }
  1126. });
  1127. },
  1128. /* 同意链属 */
  1129. handleSuccess(row) {
  1130. const launchScrId = row.launchScrId || this.ids;
  1131. if (row.launchCompanyId == this.loginId) {
  1132. const scyName = row.receiveScyName;
  1133. this.$confirm('确认与"' + scyName + '"的链属关系?', "确认链属", {
  1134. confirmButtonText: "确定",
  1135. cancelButtonText: "取消",
  1136. type: "success"
  1137. })
  1138. .then(function() {
  1139. const state = "01";
  1140. return updateRel(launchScrId, state);
  1141. })
  1142. .then(() => {
  1143. this.msgSuccess("链属成功");
  1144. this.getUser();
  1145. this.getSpare();
  1146. this.getCompanyList();
  1147. })
  1148. .catch(() => {
  1149. this.$message({
  1150. type: "warning",
  1151. message: "已取消链属"
  1152. });
  1153. });
  1154. } else if (row.launchReceiveScrCompanyId == this.loginId) {
  1155. const scyName = row.launchScyName;
  1156. this.$confirm('确认与"' + scyName + '"的链属关系?', "确认链属", {
  1157. confirmButtonText: "确定",
  1158. cancelButtonText: "取消",
  1159. type: "success"
  1160. })
  1161. .then(function() {
  1162. const state = "01";
  1163. return updateRel(launchScrId, state);
  1164. })
  1165. .then(() => {
  1166. this.msgSuccess("链属成功");
  1167. this.getUser();
  1168. this.getSpare();
  1169. this.getCompanyList();
  1170. })
  1171. .catch(() => {
  1172. this.$message({
  1173. type: "warning",
  1174. message: "已取消链属"
  1175. });
  1176. });
  1177. }
  1178. },
  1179. //重邀拒绝链属
  1180. handleRelInvite(row) {
  1181. const launchScrId = row.launchScrId || this.ids;
  1182. if (row.launchCompanyId == this.loginId) {
  1183. const scyName = row.receiveScyName;
  1184. this.$confirm('邀请与"' + scyName + '"的链属关系?', "邀请", {
  1185. confirmButtonText: "确定",
  1186. cancelButtonText: "取消",
  1187. type: "info"
  1188. })
  1189. .then(function() {
  1190. const state = "00";
  1191. return againRel(launchScrId, state);
  1192. })
  1193. .then(() => {
  1194. this.msgSuccess("邀请成功");
  1195. this.getUser();
  1196. this.getSpare();
  1197. this.getCompanyList();
  1198. })
  1199. .catch(() => {
  1200. this.$message({
  1201. type: "warning",
  1202. message: "已取消邀请"
  1203. });
  1204. });
  1205. } else if (row.launchReceiveScrCompanyId == this.loginId) {
  1206. const scyName = row.launchScyName;
  1207. this.$confirm('邀请与"' + scyName + '"的链属关系?', "邀请", {
  1208. confirmButtonText: "确定",
  1209. cancelButtonText: "取消",
  1210. type: "info"
  1211. })
  1212. .then(function() {
  1213. const state = "01";
  1214. return updateRel(launchScrId, state);
  1215. })
  1216. .then(() => {
  1217. this.msgSuccess("邀请成功");
  1218. this.getUser();
  1219. this.getSpare();
  1220. this.getCompanyList();
  1221. })
  1222. .catch(() => {
  1223. this.$message({
  1224. type: "warning",
  1225. message: "已取消邀请"
  1226. });
  1227. });
  1228. }
  1229. },
  1230. /* 拒绝链属 */
  1231. handleRefuse(row) {
  1232. const launchScrId = row.launchScrId || this.ids;
  1233. if (row.launchCompanyId == this.loginId) {
  1234. const scyName = row.receiveScyName;
  1235. this.$confirm('拒绝与"' + scyName + '"的链属关系?', "警告", {
  1236. confirmButtonText: "确定",
  1237. cancelButtonText: "取消",
  1238. type: "warning"
  1239. })
  1240. .then(function() {
  1241. const state = "02";
  1242. return updateRel(launchScrId, state);
  1243. })
  1244. .then(() => {
  1245. this.msgSuccess("拒绝成功");
  1246. this.getUser();
  1247. this.getSpare();
  1248. this.getCompanyList();
  1249. })
  1250. .catch(() => {
  1251. this.$message({
  1252. type: "warning",
  1253. message: "已拒绝链属"
  1254. });
  1255. });
  1256. } else if (row.launchReceiveScrCompanyId == this.loginId) {
  1257. const scyName = row.launchScyName;
  1258. this.$confirm('拒绝与"' + scyName + '"的链属关系?', "警告", {
  1259. confirmButtonText: "确定",
  1260. cancelButtonText: "取消",
  1261. type: "warning"
  1262. })
  1263. .then(function() {
  1264. const state = "02";
  1265. return updateRel(launchScrId, state);
  1266. })
  1267. .then(() => {
  1268. this.msgSuccess("拒绝成功");
  1269. this.getUser();
  1270. this.getSpare();
  1271. this.getCompanyList();
  1272. })
  1273. .catch(() => {
  1274. this.$message({
  1275. type: "warning",
  1276. message: "已拒绝链属"
  1277. });
  1278. });
  1279. }
  1280. },
  1281. /** 解绑按钮操作 */
  1282. handleDelete(row) {
  1283. const launchScrId = row.launchScrId || this.ids;
  1284. if (row.launchCompanyId == this.loginId) {
  1285. const scyName = row.receiveScyName;
  1286. this.$confirm('是否确认解绑与"' + scyName + '"的链属关系?', "警告", {
  1287. confirmButtonText: "确定",
  1288. cancelButtonText: "取消",
  1289. type: "warning"
  1290. })
  1291. .then(function() {
  1292. return delRel(launchScrId);
  1293. })
  1294. .then(() => {
  1295. this.msgSuccess("解绑成功");
  1296. this.getUser();
  1297. this.getSpare();
  1298. this.getCompanyList();
  1299. })
  1300. .catch(() => {
  1301. this.$message({
  1302. type: "warning",
  1303. message: "已取消解绑"
  1304. });
  1305. });
  1306. } else if (row.launchReceiveScrCompanyId == this.loginId) {
  1307. const scyName = row.launchScyName;
  1308. this.$confirm('是否确认解绑与"' + scyName + '"的链属关系?', "警告", {
  1309. confirmButtonText: "确定",
  1310. cancelButtonText: "取消",
  1311. type: "warning"
  1312. })
  1313. .then(function() {
  1314. return delRel(launchScrId);
  1315. })
  1316. .then(() => {
  1317. this.msgSuccess("解绑成功");
  1318. this.getUser();
  1319. this.getSpare();
  1320. this.getCompanyList();
  1321. })
  1322. .catch(() => {
  1323. this.$message({
  1324. type: "warning",
  1325. message: "已取消解绑"
  1326. });
  1327. });
  1328. }
  1329. },
  1330. /* 解绑链属企业信息数据 */
  1331. handleSpareDelete(row) {
  1332. const scpId = row.scpId || this.ids;
  1333. const scpName = row.scpName;
  1334. this.$confirm('是否确认解绑"' + scpName + '"的信息?', "警告", {
  1335. confirmButtonText: "确定",
  1336. cancelButtonText: "取消",
  1337. type: "warning"
  1338. })
  1339. .then(function() {
  1340. return removeSpare(scpId);
  1341. })
  1342. .then(() => {
  1343. this.msgSuccess("解绑成功");
  1344. this.getUser();
  1345. this.getSpare();
  1346. this.getCompanyList();
  1347. })
  1348. .catch(() => {
  1349. this.$message({
  1350. type: "warning",
  1351. message: "已取消解绑"
  1352. });
  1353. });
  1354. },
  1355. //重邀操作
  1356. handleInvite(row) {
  1357. const loading = this.$loading({
  1358. lock: true,
  1359. text: "Loading",
  1360. spinner: "el-icon-loading",
  1361. background: "rgba(0, 0, 0, 0.7)"
  1362. });
  1363. againInvite(row)
  1364. .then(response => {})
  1365. .then(() => {
  1366. this.msgSuccess("重邀成功");
  1367. this.getUser();
  1368. this.getSpare();
  1369. this.getCompanyList();
  1370. loading.close();
  1371. })
  1372. .catch(e => {
  1373. loading.close();
  1374. });
  1375. },
  1376. //获取操作员Id
  1377. getUser() {
  1378. getUser().then(response => {
  1379. this.userId = response.data.userId;
  1380. this.scyTypeNow = response.data.scyType;
  1381. this.companyId = response.data.companyId;
  1382. if (this.scyTypeNow == "01") {
  1383. this.handleRel = true;
  1384. } else {
  1385. this.handleRel = false;
  1386. }
  1387. this.getList();
  1388. });
  1389. }
  1390. }
  1391. };
  1392. </script>
  1393. </style><style lang="scss" scoped>
  1394. ::v-deep .el-tabs__item {
  1395. width: 105px;
  1396. height: 55px;
  1397. padding: 0;
  1398. line-height: 55px;
  1399. text-align: center;
  1400. font-size: 16px;
  1401. }
  1402. .zap-credit__content {
  1403. position: relative;
  1404. padding: 0 13px 25px;
  1405. background-color: #ffffff;
  1406. }
  1407. .zap-credit__tabs {
  1408. position: relative;
  1409. }
  1410. .zap-credit__buttons {
  1411. position: absolute;
  1412. top: 0;
  1413. right: 13px;
  1414. display: flex;
  1415. align-items: center;
  1416. height: 55px;
  1417. z-index: 99;
  1418. }
  1419. </style>