useColumns.tsx 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679
  1. import { useCountryInfoStore } from '/@/stores/countryInfo';
  2. import { useResponse } from '/@/utils/useResponse';
  3. import * as api from '/@/views/shop-information/api';
  4. const countryInfoStore = useCountryInfoStore();
  5. export const companySelect: Ref<any[]> = ref([]);
  6. const ret = await useResponse({}, api.getCompanySelect);
  7. companySelect.value = ret.data;
  8. export const platformColumns = [
  9. { type: 'seq', width: 50, align: 'center', fixed: 'left' },
  10. {
  11. field: 'operatorName', title: '运营', minWidth: 'auto', align: 'center', fixed: 'left',
  12. slots: {
  13. default({ row }: any) {
  14. return <span class={ 'font-medium' }>{ row.operatorName ? row.operatorName : '--' }</span>;
  15. }
  16. }
  17. },
  18. {
  19. field: 'platformNumber', title: '平台编号', minWidth: 'auto', align: 'center', slots: { default: 'platformNumber' }
  20. },
  21. {
  22. field: 'platformName', title: '平台名称', minWidth: 'auto', align: 'center', slots: {
  23. default({ row }: any) {
  24. return <span class={ 'font-medium' }
  25. style={ { color: '#303133' } }>{ row.platformName ? row.platformName : '--' }</span>;
  26. }
  27. }
  28. },
  29. {
  30. field: 'country', title: '国家', minWidth: 'auto', align: 'center',
  31. slots: {
  32. default({ row }: any) {
  33. const country = countryInfoStore.countries.find(c => c.name === row.country);
  34. const color = country ? country.color : '#3875F6';
  35. return <el-tag effect="plain" round
  36. style={ { color: color, borderColor: color } }>{ row.country ? row.country : '--' }</el-tag>;
  37. }
  38. }
  39. },
  40. {
  41. field: 'brandName', title: '品牌名称', minWidth: 'auto', align: 'center',
  42. slots: {
  43. default({ row }: any) {
  44. return <span class={ 'font-medium' }>{ row.brandName ? row.brandName : '--' }</span>;
  45. }
  46. }
  47. },
  48. {
  49. field: 'currencyCode', title: '货币代码', minWidth: 'auto', align: 'center',
  50. slots: {
  51. default({ row }: any) {
  52. return <span class={ 'font-medium' }>{ row.currencyCode ? row.currencyCode : '--' }</span>;
  53. }
  54. }
  55. },
  56. {
  57. field: 'status', title: '状态', minWidth: 'auto', align: 'center',
  58. slots: {
  59. default({ row }: any) {
  60. return <span class={ 'font-medium' }>{ row.status ? row.status : '--' }</span>;
  61. }
  62. }
  63. },
  64. {
  65. field: 'platform', title: '平台', minWidth: 'auto', align: 'center',
  66. slots: {
  67. default({ row }: any) {
  68. return <span class={ 'font-medium' }>{ row.platform ? row.platform : '--' }</span>;
  69. }
  70. }
  71. },
  72. {
  73. field: 'line', title: '线路', minWidth: 'auto', align: 'center',
  74. slots: {
  75. default({ row }: any) {
  76. return <span class={ 'font-medium' }>{ row.line ? row.line : '--' }</span>;
  77. }
  78. }
  79. },
  80. {
  81. field: 'ipaddress', title: 'IP地址', minWidth: 'auto', align: 'center',
  82. slots: {
  83. default({ row }: any) {
  84. return <span class={ 'font-medium' }>{ row.ipaddress ? row.ipaddress : '--' }</span>;
  85. }
  86. }
  87. },
  88. {
  89. field: 'company', title: '公司名称', minWidth: 'auto', align: 'center',
  90. slots: {
  91. default({ row }: any) {
  92. return <span class={ 'font-medium' }>{ row.company ? row.company : '--' }</span>;
  93. }
  94. }
  95. },
  96. {
  97. field: 'companyEnglishName', title: '公司英文名称', minWidth: 'auto', align: 'center',
  98. slots: {
  99. default({ row }: any) {
  100. return <span class={ 'font-medium' }>{ row.companyEnglishName ? row.companyEnglishName : '--' }</span>;
  101. }
  102. }
  103. },
  104. {
  105. field: 'address', title: '公司地址', minWidth: 'auto', align: 'center',
  106. slots: {
  107. default({ row }: any) {
  108. return <span class={ 'font-medium' }>{ row.address ? row.address : '--' }</span>;
  109. }
  110. }
  111. },
  112. {
  113. field: 'juridicalPerson', title: '法人', minWidth: 'auto', align: 'center',
  114. slots: {
  115. default({ row }: any) {
  116. return <span class={ 'font-medium' }>{ row.juridicalPerson ? row.juridicalPerson : '--' }</span>;
  117. }
  118. }
  119. },
  120. {
  121. field: 'juridicalPersonCreditCard', title: '法人信用卡', minWidth: 'auto', align: 'center',
  122. slots: {
  123. default({ row }: any) {
  124. return <span
  125. class={ 'font-medium' }>{ row.juridicalPersonCreditCard ? row.juridicalPersonCreditCard : '--' }</span>;
  126. }
  127. }
  128. },
  129. {
  130. field: 'juridicalPersonCreditCardAddress', title: '法人信用卡地址', minWidth: 'auto', align: 'center',
  131. slots: {
  132. default({ row }: any) {
  133. return <span
  134. class={ 'font-medium' }>{ row.juridicalPersonCreditCardAddress ? row.juridicalPersonCreditCardAddress : '--' }</span>;
  135. }
  136. }
  137. },
  138. {
  139. field: 'receivablesAccount', title: '收款账户', minWidth: 'auto', align: 'center',
  140. slots: {
  141. default({ row }: any) {
  142. return <span class={ 'font-medium' }>{ row.receivablesAccount ? row.receivablesAccount : '--' }</span>;
  143. }
  144. }
  145. },
  146. {
  147. field: 'receivablesAccountCompany', title: '收款账户公司', minWidth: 'auto', align: 'center',
  148. slots: {
  149. default({ row }: any) {
  150. return <span
  151. class={ 'font-medium' }>{ row.receivablesAccountCompany ? row.receivablesAccountCompany : '--' }</span>;
  152. }
  153. }
  154. },
  155. {
  156. field: 'vatNumber', title: 'VAT税号', minWidth: 200, align: 'center',
  157. slots: {
  158. default({ row }: any) {
  159. return <span class={ 'font-medium' }>{ row.vatNumber ? row.vatNumber : '--' }</span>;
  160. }
  161. }
  162. },
  163. {
  164. field: 'vatCompany', title: 'VAT公司', minWidth: 'auto', align: 'center',
  165. slots: {
  166. default({ row }: any) {
  167. return <span class={ 'font-medium' }>{ row.vatCompany ? row.vatCompany : '--' }</span>;
  168. }
  169. }
  170. },
  171. {
  172. field: 'shopPhoneEmail', title: '店铺电话与邮箱', minWidth: 'auto', align: 'center',
  173. slots: {
  174. default({ row }: any) {
  175. return <span class={ 'font-medium' }>{ row.shopPhoneEmail ? row.shopPhoneEmail : '--' }</span>;
  176. }
  177. }
  178. }
  179. ];
  180. export const shopCurrentColumns = [
  181. { type: 'seq', width: 50, align: 'center', fixed: 'left' },
  182. {
  183. field: 'operatorName', title: '运营', minWidth: 'auto', align: 'center', fixed: 'left',
  184. slots: {
  185. default({ row }: any) {
  186. return <span class={ 'font-medium' }>{ row.operatorName ? row.operatorName : '--' }</span>;
  187. }
  188. }
  189. },
  190. {
  191. field: 'platformNumber', title: '平台编号', minWidth: 'auto', align: 'center',
  192. slots: {
  193. default({ row }: any) {
  194. return <span class={ 'font-medium' }>{ row.platformNumber ? row.platformNumber : '--' }</span>;
  195. }
  196. }
  197. },
  198. {
  199. field: 'platformName', title: '平台名称', minWidth: 'auto', align: 'center',
  200. slots: {
  201. default({ row }: any) {
  202. return <span class={ 'font-medium' }>{ row.platformName ? row.platformName : '--' }</span>;
  203. }
  204. }
  205. },
  206. {
  207. field: 'country', title: '国家', minWidth: 'auto', align: 'center',
  208. slots: {
  209. default({ row }: any) {
  210. const country = countryInfoStore.countries.find(c => c.name === row.country);
  211. const color = country ? country.color : '#3875F6';
  212. return <el-tag effect="plain" round
  213. style={ { color: color, borderColor: color } }>{ row.country ? row.country : '--' }</el-tag>;
  214. }
  215. }
  216. },
  217. {
  218. field: 'brandName', title: '品牌名称', minWidth: 'auto', align: 'center',
  219. slots: {
  220. default({ row }: any) {
  221. return <span class={ 'font-medium' }>{ row.brandName ? row.brandName : '--' }</span>;
  222. }
  223. }
  224. },
  225. {
  226. field: 'currencyCode', title: '货币代码', minWidth: 'auto', align: 'center',
  227. slots: {
  228. default({ row }: any) {
  229. return <span class={ 'font-medium' }>{ row.currencyCode ? row.currencyCode : '--' }</span>;
  230. }
  231. }
  232. },
  233. {
  234. field: 'status', title: '状态', minWidth: 'auto', align: 'center',
  235. slots: {
  236. default({ row }: any) {
  237. return (
  238. <el-tag
  239. class="font-medium"
  240. type={ row.status === 1 ? 'success' : 'danger' } // 动态绑定 type
  241. >
  242. { row.status === 1 ? '启用' : '暂停' }
  243. </el-tag>
  244. );
  245. }
  246. }
  247. },
  248. {
  249. field: 'platform', title: '平台', minWidth: 'auto', align: 'center',
  250. slots: {
  251. default({ row }: any) {
  252. return <span class={ 'font-medium' }>{ row.platform ? row.platform : '--' }</span>;
  253. }
  254. }
  255. },
  256. {
  257. field: 'line', title: '线路', minWidth: 'auto', align: 'center',
  258. slots: {
  259. default({ row }: any) {
  260. return <span class={ 'font-medium' }>{ row.line ? row.line : '--' }</span>;
  261. }
  262. }
  263. },
  264. {
  265. field: 'ipaddress', title: 'IP地址', minWidth: 'auto', align: 'center',
  266. slots: {
  267. default({ row }: any) {
  268. return <span class={ 'font-medium' }>{ row.ipaddress ? row.ipaddress : '--' }</span>;
  269. }
  270. }
  271. },
  272. {
  273. field: 'belongsCompany', title: '关联公司', minWidth: 'auto', align: 'center',
  274. slots: {
  275. default({ row }: any) {
  276. const company = companySelect.value.find(c => c.id === row.belongsCompany);
  277. return <span class="font-medium">{ company ? company.company : '--' }</span>;
  278. }
  279. }
  280. },
  281. {
  282. field: 'company', title: '公司名称', minWidth: 'auto', align: 'center',
  283. slots: {
  284. default({ row }: any) {
  285. return <span class={ 'font-medium' }>{ row.company ? row.company : '--' }</span>;
  286. }
  287. }
  288. },
  289. {
  290. field: 'companyEnglishName', title: '公司英文名称', minWidth: 'auto', align: 'center',
  291. slots: {
  292. default({ row }: any) {
  293. return <span class={ 'font-medium' }>{ row.companyEnglishName ? row.companyEnglishName : '--' }</span>;
  294. }
  295. }
  296. },
  297. {
  298. field: 'address', title: '公司地址', minWidth: 'auto', align: 'center',
  299. slots: {
  300. default({ row }: any) {
  301. return <span class={ 'font-medium' }>{ row.address ? row.address : '--' }</span>;
  302. }
  303. }
  304. },
  305. {
  306. field: 'juridicalPerson', title: '法人', minWidth: 'auto', align: 'center',
  307. slots: {
  308. default({ row }: any) {
  309. return <span class={ 'font-medium' }>{ row.juridicalPerson ? row.juridicalPerson : '--' }</span>;
  310. }
  311. }
  312. },
  313. {
  314. field: 'juridicalPersonCreditCard', title: '法人信用卡', minWidth: 'auto', align: 'center',
  315. slots: {
  316. default({ row }: any) {
  317. return <span
  318. class={ 'font-medium' }>{ row.juridicalPersonCreditCard ? row.juridicalPersonCreditCard : '--' }</span>;
  319. }
  320. }
  321. },
  322. {
  323. field: 'juridicalPersonCreditCardAddress', title: '法人信用卡地址', minWidth: 'auto', align: 'center',
  324. slots: {
  325. default({ row }: any) {
  326. return <span
  327. class={ 'font-medium' }>{ row.juridicalPersonCreditCardAddress ? row.juridicalPersonCreditCardAddress : '--' }</span>;
  328. }
  329. }
  330. },
  331. {
  332. field: 'receivablesAccount', title: '收款账户', minWidth: 'auto', align: 'center',
  333. slots: {
  334. default({ row }: any) {
  335. return <span class={ 'font-medium' }>{ row.receivablesAccount ? row.receivablesAccount : '--' }</span>;
  336. }
  337. }
  338. },
  339. {
  340. field: 'receivablesAccountCompany', title: '收款账户公司', minWidth: 'auto', align: 'center',
  341. slots: {
  342. default({ row }: any) {
  343. return <span
  344. class={ 'font-medium' }>{ row.receivablesAccountCompany ? row.receivablesAccountCompany : '--' }</span>;
  345. }
  346. }
  347. },
  348. {
  349. field: 'vatNumber', title: 'VAT税号', minWidth: 'auto', align: 'center',
  350. slots: {
  351. default({ row }: any) {
  352. return <span class={ 'font-medium' }>{ row.vatNumber ? row.vatNumber : '--' }</span>;
  353. }
  354. }
  355. },
  356. {
  357. field: 'vatCompany', title: 'VAT公司', minWidth: 'auto', align: 'center',
  358. slots: {
  359. default({ row }: any) {
  360. return <span class={ 'font-medium' }>{ row.vatCompany ? row.vatCompany : '--' }</span>;
  361. }
  362. }
  363. },
  364. {
  365. field: 'shopPhoneAndName', title: '主账户电话', minWidth: 'auto', align: 'center',
  366. slots: {
  367. default({ row }: any) {
  368. return <span class={ 'font-medium' }>{ row.shopPhoneAndName !== null ? row.shopPhoneAndName : '--' }</span>;
  369. }
  370. }
  371. },
  372. {
  373. field: 'shopEmail', title: '主账户邮箱', minWidth: 'auto', align: 'center',
  374. slots: {
  375. default({ row }: any) {
  376. return <span class={ 'font-medium' }>{ row.shopEmail ? row.shopEmail : '--' }</span>;
  377. }
  378. }
  379. },
  380. {
  381. field: 'subShopPhoneAndName', title: '子账户电话', minWidth: 'auto', align: 'center',
  382. slots: {
  383. default({ row }: any) {
  384. return <span class={ 'font-medium' }>{ row.subShopPhoneAndName ? row.subShopPhoneAndName : '--' }</span>;
  385. }
  386. }
  387. },
  388. {
  389. field: 'subShopEmail', title: '子账户邮箱', minWidth: 'auto', align: 'center',
  390. slots: {
  391. default({ row }: any) {
  392. return <span class={ 'font-medium' }>{ row.subShopEmail ? row.subShopEmail : '--' }</span>;
  393. }
  394. }
  395. }
  396. ];
  397. export const historyColumns: any = [
  398. { type: 'seq', width: 50, align: 'center', fixed: 'left' },
  399. {
  400. field: 'operatorName', title: '运营', minWidth: 'auto', align: 'center', fixed: 'left',
  401. slots: {
  402. default({ row }: any) {
  403. return <span class={ 'font-medium' }>{ row.operatorName ? row.operatorName : '--' }</span>;
  404. }
  405. }
  406. },
  407. {
  408. field: 'platformNumber', title: '平台编号', minWidth: 'auto', align: 'center',
  409. slots: {
  410. default({ row }: any) {
  411. return <span class={ 'font-medium' }>{ row.platformNumber ? row.platformNumber : '--' }</span>;
  412. }
  413. }
  414. },
  415. {
  416. field: 'platformName', title: '平台名称', minWidth: 'auto', align: 'center',
  417. slots: {
  418. default({ row }: any) {
  419. return <span class={ 'font-medium' }>{ row.platformName ? row.platformName : '--' }</span>;
  420. }
  421. }
  422. },
  423. {
  424. field: 'country', title: '国家', minWidth: 'auto', align: 'center',
  425. slots: {
  426. default({ row }: any) {
  427. const country = countryInfoStore.countries.find(c => c.name === row.country);
  428. const color = country ? country.color : '#3875F6';
  429. return <el-tag effect="plain" round
  430. style={ { color: color, borderColor: color } }>{ row.country ? row.country : '--' }</el-tag>;
  431. }
  432. }
  433. },
  434. {
  435. field: 'brandName', title: '品牌名称', minWidth: 'auto', align: 'center',
  436. slots: {
  437. default({ row }: any) {
  438. return <span class={ 'font-medium' }>{ row.brandName ? row.brandName : '--' }</span>;
  439. }
  440. }
  441. },
  442. {
  443. field: 'currencyCode', title: '货币代码', minWidth: 'auto', align: 'center',
  444. slots: {
  445. default({ row }: any) {
  446. return <span class={ 'font-medium' }>{ row.currencyCode ? row.currencyCode : '--' }</span>;
  447. }
  448. }
  449. },
  450. {
  451. field: 'status', title: '状态', minWidth: 'auto', align: 'center',
  452. slots: {
  453. default({ row }: any) {
  454. return (
  455. <el-tag
  456. class="font-medium"
  457. type={ row.status === 1 ? 'success' : 'danger' } // 动态绑定 type
  458. >
  459. { row.status === 1 ? '启用' : '暂停' }
  460. </el-tag>
  461. );
  462. }
  463. }
  464. },
  465. {
  466. field: 'platform', title: '平台', minWidth: 'auto', align: 'center',
  467. slots: {
  468. default({ row }: any) {
  469. return <span class={ 'font-medium' }>{ row.platform ? row.platform : '--' }</span>;
  470. }
  471. }
  472. },
  473. {
  474. field: 'line', title: '线路', minWidth: 'auto', align: 'center',
  475. slots: {
  476. default({ row }: any) {
  477. return <span class={ 'font-medium' }>{ row.line ? row.line : '--' }</span>;
  478. }
  479. }
  480. },
  481. {
  482. field: 'ipaddress', title: 'IP地址', minWidth: 'auto', align: 'center',
  483. slots: {
  484. default({ row }: any) {
  485. return <span class={ 'font-medium' }>{ row.ipaddress ? row.ipaddress : '--' }</span>;
  486. }
  487. }
  488. },
  489. {
  490. field: 'company', title: '公司名称', minWidth: 'auto', align: 'center',
  491. slots: {
  492. default({ row }: any) {
  493. return <span class={ 'font-medium' }>{ row.company ? row.company : '--' }</span>;
  494. }
  495. }
  496. },
  497. {
  498. field: 'companyEnglishName', title: '公司英文名称', minWidth: 'auto', align: 'center',
  499. slots: {
  500. default({ row }: any) {
  501. return <span class={ 'font-medium' }>{ row.companyEnglishName ? row.companyEnglishName : '--' }</span>;
  502. }
  503. }
  504. },
  505. {
  506. field: 'address', title: '公司地址', minWidth: 'auto', align: 'center',
  507. slots: {
  508. default({ row }: any) {
  509. return <span class={ 'font-medium' }>{ row.address ? row.address : '--' }</span>;
  510. }
  511. }
  512. },
  513. {
  514. field: 'juridicalPerson', title: '法人', minWidth: 'auto', align: 'center',
  515. slots: {
  516. default({ row }: any) {
  517. return <span class={ 'font-medium' }>{ row.juridicalPerson ? row.juridicalPerson : '--' }</span>;
  518. }
  519. }
  520. },
  521. {
  522. field: 'juridicalPersonCreditCard', title: '法人信用卡', minWidth: 'auto', align: 'center',
  523. slots: {
  524. default({ row }: any) {
  525. return <span
  526. class={ 'font-medium' }>{ row.juridicalPersonCreditCard ? row.juridicalPersonCreditCard : '--' }</span>;
  527. }
  528. }
  529. },
  530. {
  531. field: 'juridicalPersonCreditCardAddress', title: '法人信用卡地址', minWidth: 'auto', align: 'center',
  532. slots: {
  533. default({ row }: any) {
  534. return <span
  535. class={ 'font-medium' }>{ row.juridicalPersonCreditCardAddress ? row.juridicalPersonCreditCardAddress : '--' }</span>;
  536. }
  537. }
  538. },
  539. {
  540. field: 'receivablesAccount', title: '收款账户', minWidth: 'auto', align: 'center',
  541. slots: {
  542. default({ row }: any) {
  543. return <span class={ 'font-medium' }>{ row.receivablesAccount ? row.receivablesAccount : '--' }</span>;
  544. }
  545. }
  546. },
  547. {
  548. field: 'receivablesAccountCompany', title: '收款账户公司', minWidth: 'auto', align: 'center',
  549. slots: {
  550. default({ row }: any) {
  551. return <span
  552. class={ 'font-medium' }>{ row.receivablesAccountCompany ? row.receivablesAccountCompany : '--' }</span>;
  553. }
  554. }
  555. },
  556. {
  557. field: 'vatNumber', title: 'VAT税号', minWidth: 'auto', align: 'center',
  558. slots: {
  559. default({ row }: any) {
  560. return <span class={ 'font-medium' }>{ row.vatNumber ? row.vatNumber : '--' }</span>;
  561. }
  562. }
  563. },
  564. {
  565. field: 'vatCompany', title: 'VAT公司', minWidth: 'auto', align: 'center',
  566. slots: {
  567. default({ row }: any) {
  568. return <span class={ 'font-medium' }>{ row.vatCompany ? row.vatCompany : '--' }</span>;
  569. }
  570. }
  571. },
  572. {
  573. field: 'create_datetime', title: '创建时间', minWidth: 'auto', align: 'center',
  574. slots: {
  575. default({ row }: any) {
  576. return <span class={ 'font-medium' }>{ row.create_datetime ? row.create_datetime : '--' }</span>;
  577. }
  578. }
  579. },
  580. {
  581. field: 'approveNum', title: '审批数量', minWidth: 'auto', align: 'center',
  582. slots: {
  583. default({ row }: any) {
  584. return <span class={ 'font-medium' }>{ row.approveNum ? row.approveNum : '--' }</span>;
  585. }
  586. }
  587. },
  588. {
  589. field: 'shopPhoneAndName', title: '主账户电话', minWidth: 'auto', align: 'center',
  590. slots: {
  591. default({ row }: any) {
  592. return <span class={ 'font-medium' }>{ row.shopPhoneAndName !== null ? row.shopPhoneAndName : '--' }</span>;
  593. }
  594. }
  595. },
  596. {
  597. field: 'shopEmail', title: '主账户邮箱', minWidth: 'auto', align: 'center',
  598. slots: {
  599. default({ row }: any) {
  600. return <span class={ 'font-medium' }>{ row.shopEmail ? row.shopEmail : '--' }</span>;
  601. }
  602. }
  603. },
  604. {
  605. field: 'subShopPhoneAndName', title: '子账户电话', minWidth: 'auto', align: 'center',
  606. slots: {
  607. default({ row }: any) {
  608. return <span class={ 'font-medium' }>{ row.subShopPhoneAndName ? row.subShopPhoneAndName : '--' }</span>;
  609. }
  610. }
  611. },
  612. {
  613. field: 'subShopEmail', title: '子账户邮箱', minWidth: 'auto', align: 'center',
  614. slots: {
  615. default({ row }: any) {
  616. return <span class={ 'font-medium' }>{ row.subShopEmail ? row.subShopEmail : '--' }</span>;
  617. }
  618. }
  619. }
  620. ];
  621. export const computerColumns: any = [
  622. { type: 'seq', width: 50, align: 'center', fixed: 'left' },
  623. {
  624. field: 'operatorName', title: '使用人', minWidth: 'auto', align: 'center',
  625. slots: {
  626. default({ row }: any) {
  627. return <span class={ 'font-medium' }>{ row.operatorName ? row.operatorName : '--' }</span>;
  628. }
  629. }
  630. },
  631. {
  632. field: 'computerNumber', title: '电脑编号', minWidth: 'auto', align: 'center',
  633. slots: {
  634. default({ row }: any) {
  635. return <span class={ 'font-medium' }>{ row.computerNumber ? row.computerNumber : '--' }</span>;
  636. }
  637. }
  638. },
  639. {
  640. field: 'computerType', title: '计算机类型', minWidth: 'auto', align: 'center',
  641. slots: {
  642. default({ row }: any) {
  643. return <span class={ 'font-medium' }>{ row.computerType ? row.computerType : '--' }</span>;
  644. }
  645. }
  646. },
  647. {
  648. field: 'station', title: '位置', minWidth: 'auto', align: 'center',
  649. slots: {
  650. default({ row }: any) {
  651. return <span class={ 'font-medium' }>{ row.station ? row.station : '--' }</span>;
  652. }
  653. }
  654. },
  655. {
  656. field: 'ipaddress', title: 'IP地址', minWidth: 'auto', align: 'center',
  657. slots: {
  658. default({ row }: any) {
  659. return <span class={ 'font-medium' }>{ row.ipaddress ? row.ipaddress : '--' }</span>;
  660. }
  661. }
  662. },
  663. {
  664. field: 'macaddress', title: 'MAC地址', minWidth: 'auto', align: 'center',
  665. slots: {
  666. default({ row }: any) {
  667. return <span class={ 'font-medium' }>{ row.macaddress ? row.macaddress : '--' }</span>;
  668. }
  669. }
  670. }
  671. ];