routerConfig.ts 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737
  1. /**头部路由一级菜单点击逻辑 */
  2. function headrRouter(initialState: any, history: any) {
  3. let ok = true
  4. let u = navigator?.userAgent
  5. let isPhone = !!u.match(/AppleWebKit.*Mobile.*/) || u?.indexOf('iPad') > -1
  6. //登录时指向/辅助处理看当前用户的一级菜单有哪些,找到第一个符合的跳转
  7. initialState?.menu?.data.forEach((item: { roles: string[], path: string, routes: { path: string, routes: any[] }[] }) => {
  8. if (ok) {
  9. ok = false
  10. let path = item?.routes?.length > 0 ? item?.routes[0]?.routes?.length > 0 ? item?.routes[0]?.routes[0]?.path ? item?.routes[0]?.routes[0]?.path : item?.routes[0].path : item?.routes[0].path : item?.routes[0].path
  11. if (history?.location?.pathname === '/') {
  12. history.push(path)
  13. }
  14. }
  15. })
  16. if (history?.location?.pathname === '/operatePage') { //当切换一级菜单的辅助跳转
  17. history?.goBack()
  18. initialState?.menu?.data.forEach((item: { roles: string[], path: string, routes: { path: string, routes: any[] }[] }) => {
  19. if (item?.routes?.some((i: { path: string }) => i.path?.includes('/operatePage'))) {
  20. let path = item?.routes?.length > 0 ? (item?.routes[0]?.routes?.length > 0 && item?.routes[0]?.routes[0]?.path) ? item?.routes[0]?.routes[0]?.path : item?.routes[0].path : item?.routes[0].path
  21. // history.push(path)
  22. isPhone ? history.push(path) : window.open(location.origin+'/#'+path)
  23. // window.open(location.origin+'/#'+path)
  24. }
  25. })
  26. // localStorage.setItem('bg', 'light')
  27. }
  28. if (history?.location?.pathname === '/dataStatistics') { //当切换一级菜单的辅助跳转
  29. history?.goBack()
  30. initialState?.menu?.data.forEach((item: { roles: string[], path: string, routes: { path: string, routes: any[] }[] }) => {
  31. if (item?.routes?.some((i: { path: string }) => i.path?.includes('/dataStatistics'))) {
  32. let path = item?.routes?.length > 0 ? (item?.routes[0]?.routes?.length > 0 && item?.routes[0]?.routes[0]?.path) ? item?.routes[0]?.routes[0]?.path : item?.routes[0].path : item?.routes[0].path
  33. // history.push(path)
  34. // window.open(location.origin+'/#'+path)
  35. isPhone ? history.push(path) : window.open(location.origin+'/#'+path)
  36. }
  37. })
  38. // localStorage.setItem('bg', 'dark')
  39. }
  40. if (history?.location?.pathname === '/launchSystem') { //当切换一级菜单的辅助跳转
  41. history?.goBack()
  42. initialState?.menu?.data.forEach((item: { roles: string[], path: string, routes: { path: string, routes: any[] }[] }) => {
  43. if (item?.routes?.some((i: { path: string }) => i.path?.includes('/launchSystem'))) {
  44. let path = item?.routes?.length > 0 ? (item?.routes[0]?.routes?.length > 0 && item?.routes[0]?.routes[0]?.path) ? item?.routes[0]?.routes[0]?.path : item?.routes[0].path : item?.routes[0].path
  45. // history.push(path)
  46. // window.open(location.origin+'/#'+path)
  47. isPhone ? history.push(path) : window.open(location.origin+'/#'+path)
  48. }
  49. })
  50. // localStorage.setItem('bg', 'dark')
  51. }
  52. if (history?.location?.pathname === '/enterpriseWeChat') { //当切换一级菜单的辅助跳转
  53. history?.goBack()
  54. initialState?.menu?.data.forEach((item: { roles: string[], path: string, routes: { path: string, routes: any[] }[] }) => {
  55. if (item?.routes?.some((i: { path: string }) => i.path?.includes('/enterpriseWeChat'))) {
  56. let path = item?.routes?.length > 0 ? (item?.routes[0]?.routes?.length > 0 && item?.routes[0]?.routes[0]?.path) ? item?.routes[0]?.routes[0]?.path : item?.routes[0].path : item?.routes[0].path
  57. // history.push(path)
  58. // window.open(location.origin+'/#'+path)
  59. isPhone ? history.push(path) : window.open(location.origin+'/#'+path)
  60. }
  61. })
  62. // localStorage.setItem('bg', 'dark')
  63. }
  64. }
  65. //返回按钮路由
  66. function btnFun(items: any) {
  67. return items?.childrenBtn?.map((btn: any,) => {
  68. return { name: btn.meta.title, key: btn?.menuId }
  69. })
  70. }
  71. //返回子路由
  72. function routeFun(items: any) {
  73. return items.children.map((route: any) => {//循环重组
  74. if (route?.children?.length > 0) {
  75. let arr = routeFun(route)
  76. return { path: route.path, name: route.meta.title, component: route.component, routes: arr, icon: route.meta.icon, key: route?.menuId }
  77. }
  78. if (route?.childrenBtn?.length > 0) {
  79. let arr = btnFun(route)
  80. return { path: route.path, name: route.meta.title, component: route.component, routes: arr, icon: route.meta.icon, key: route?.menuId }
  81. }
  82. return { path: route.path, name: route.meta.title, component: route.component, icon: items.meta.icon, key: route?.menuId }
  83. })
  84. }
  85. /**获取线上菜单并重组路由格式和权限*/
  86. function getMyMenu(code: any, data: any,) {
  87. let newData: any = []
  88. // let roles = userInfo?.roles.map((role: any) => role.roleKey)//权限从个人信息中取,以防路由列表中有错误
  89. if (code === 200) {
  90. let new_data: any[] = []
  91. // 循环判断不为空的主菜单加入
  92. Object.keys(data).reverse().map((key) => {
  93. if (Array.isArray(data[key]) && data[key]?.length > 0) {
  94. new_data.push(data[key][0])
  95. }
  96. })
  97. // 处理顺序
  98. new_data = new_data.sort((a, b) => {
  99. let v1 = a.orderNum
  100. let v2 = b.orderNum
  101. return v1 - v2
  102. })
  103. new_data.forEach((items: any) => {
  104. if (items?.children?.length === 0) {//假如路由的子路由只有一个代表当前组件没有子路由,将children中的component组件路径给外层component
  105. newData.push({ path: items.children[0].path, name: items.meta.title, icon: items.meta.icon, component: items.children[0].component, key: items.menuId }) // roles: roles
  106. }
  107. if (items?.children?.length >= 0) {//假如路由的子路由个数大于1代表有子路由
  108. let arr: any[] = routeFun(items)
  109. newData.push({ path: items.path, name: items.meta.title, icon: items.meta.icon, routes: arr, key: items.menuId })//最后添加进routes , roles: roles
  110. }
  111. })
  112. }
  113. return newData
  114. }
  115. /**本地运营路由配置 */
  116. let operatePage = {
  117. path: '/operatePage',
  118. access: 'operatePage',
  119. name: '运营',
  120. routes: [
  121. {
  122. path: '/operatePage/account/wxcode',
  123. layout: false,
  124. routes: [
  125. {
  126. name: 'wxcode',
  127. path: '/operatePage/account/wxcode',
  128. component: './operatePage/account/wxcode',
  129. },
  130. ],
  131. },
  132. {
  133. path: '/operatePage/operate',
  134. name: '运营中心',
  135. access: 'operate',
  136. icon: 'DesktopOutlined',
  137. component: './operatePage/operate',
  138. },
  139. {
  140. path: '/operatePage/interact',
  141. name: '智能互动',
  142. access: 'interact',
  143. icon: 'MessageOutlined',
  144. routes: [
  145. {
  146. name: '智能推送',
  147. path: '/operatePage/interact/push',
  148. access: 'push',
  149. component: './operatePage/interact/push',
  150. },
  151. {
  152. name: '关注回复',
  153. path: '/operatePage/interact/reply',
  154. access: 'reply',
  155. component: './operatePage/interact/reply',
  156. },
  157. {
  158. name: '关键字回复',
  159. path: '/operatePage/interact/keyword',
  160. access: 'keyword',
  161. component: './operatePage/interact/keyword',
  162. },
  163. {
  164. name: '自定义菜单',
  165. path: '/operatePage/interact/custommenu',
  166. access: 'custommenu',
  167. component: './operatePage/interact/custommenu',
  168. }
  169. ]
  170. },
  171. {
  172. path: '/operatePage/news',
  173. name: '群发推送',
  174. access: 'news',
  175. icon: 'SendOutlined',
  176. routes: [
  177. {
  178. name: '客服消息',
  179. path: '/operatePage/news/aservice',
  180. access: 'aservice',
  181. component: './operatePage/news/aservice',
  182. },
  183. {
  184. name: '模板消息',
  185. path: '/operatePage/news/atemplate',
  186. access: 'atemplate',
  187. component: './operatePage/news/atemplate',
  188. },
  189. {
  190. name: '高级群发',
  191. path: '/operatePage/news/advanced',
  192. access: 'advanced',
  193. component: './operatePage/news/advanced',
  194. }
  195. ]
  196. },
  197. {
  198. path: '/operatePage/fans',
  199. name: '粉丝管理',
  200. access: 'fans',
  201. icon: 'TeamOutlined',
  202. routes: [
  203. {
  204. name: '粉丝消息',
  205. path: '/operatePage/fans/message',
  206. access: 'message',
  207. component: './operatePage/fans/message',
  208. },
  209. {
  210. name: '粉丝列表',
  211. path: '/operatePage/fans/list',
  212. access: 'list',
  213. component: './operatePage/fans/list',
  214. },
  215. {
  216. name: '粉丝标签',
  217. path: '/operatePage/fans/tag',
  218. access: 'tag',
  219. component: './operatePage/fans/tag',
  220. }
  221. ]
  222. },
  223. {
  224. path: '/operatePage/material',
  225. name: '素材管理',
  226. access: 'material',
  227. icon: 'DatabaseOutlined',
  228. routes: [
  229. {
  230. name: '本地素材',
  231. path: '/operatePage/material/cloud',
  232. access: 'cloud',
  233. component: './operatePage/material/cloud',
  234. },
  235. {
  236. name: '微信素材',
  237. path: '/operatePage/material/weChat',
  238. access: 'weChat',
  239. component: './operatePage/material/weChat',
  240. }
  241. ],
  242. },
  243. {
  244. path: '/operatePage/account',
  245. name: '公众号管理',
  246. access: 'account',
  247. icon: 'QrcodeOutlined',
  248. component: './operatePage/account',
  249. },
  250. {
  251. path: '/operatePage/weMenu',
  252. name: '公众号菜单管理',
  253. access: 'weMenu',
  254. icon: 'MobileOutlined',
  255. component: './operatePage/weMenu',
  256. },
  257. {
  258. path: '/operatePage/books',
  259. name: '小说平台管理',
  260. access: 'books',
  261. icon: 'ReadOutlined',
  262. routes: [
  263. {
  264. name: '小说平台管理',
  265. path: '/operatePage/books/bookcity',
  266. access: 'bookcity',
  267. component: './operatePage/books/bookcity',
  268. },
  269. {
  270. name: '小说分类管理',
  271. path: '/operatePage/books/bookify',
  272. access: 'bookify',
  273. component: './operatePage/books/bookify',
  274. },
  275. {
  276. name: '书籍管理',
  277. path: '/operatePage/books/book',
  278. access: 'book',
  279. component: './operatePage/books/book',
  280. },
  281. ],
  282. },
  283. {
  284. path: '/operatePage/automation',
  285. name: '自动化管理',
  286. access: 'automation',
  287. icon: 'ReadOutlined',
  288. routes: [
  289. {
  290. name: '自动化创建',
  291. path: '/operatePage/automation/create',
  292. access: 'automationCreate',
  293. component: './operatePage/automation/create',
  294. },
  295. {
  296. name: '书城链接',
  297. path: '/operatePage/automation/links',
  298. access: 'automationLinks',
  299. component: './operatePage/automation/links',
  300. },
  301. ],
  302. },
  303. {
  304. path: '/operatePage/advertisements',
  305. name: '广告',
  306. access: 'advertisements',
  307. icon: 'DesktopOutlined',
  308. routes: [
  309. {
  310. name: '广告变现说明',
  311. path: '/operatePage/advertisements/course',
  312. access: 'course',
  313. component: './operatePage/advertisements/course'
  314. },
  315. {
  316. name: '广告数据统计',
  317. path: '/operatePage/advertisements/dataCensus',
  318. access: 'course',
  319. component: './operatePage/advertisements/dataCensus'
  320. },
  321. ],
  322. },
  323. {
  324. path: '/operatePage/examine',
  325. name: '消息审查',
  326. access: 'examine',
  327. icon: 'DesktopOutlined',
  328. routes: [
  329. {
  330. name: '高级群发',
  331. path: '/operatePage/examine/examineAdvanced',
  332. access: 'examineAdvanced',
  333. component: './operatePage/examine/examineAdvanced'
  334. },
  335. {
  336. name: '客服消息',
  337. path: '/operatePage/examine/examineAservice',
  338. access: 'examineAservice',
  339. component: './operatePage/examine/examineAservice'
  340. },
  341. {
  342. name: '模板消息',
  343. path: '/operatePage/examine/examineAtemplate',
  344. access: 'examineAtemplate',
  345. component: './operatePage/examine/examineAtemplate'
  346. },
  347. {
  348. name: '立即/延迟消息',
  349. path: '/operatePage/examine/examineInteract',
  350. access: 'examineInteract',
  351. component: './operatePage/examine/examineInteract'
  352. },
  353. ],
  354. },
  355. {
  356. path: '/operatePage/accountyyb',
  357. name: '账号管理',
  358. access: 'accountyyb',
  359. icon: 'ReadOutlined',
  360. component: './operatePage/accountyyb',
  361. },
  362. {
  363. path: '/operatePage/kyyBoxManage',
  364. name: '快应用包管理',
  365. access: 'kyyBoxManage',
  366. icon: 'ReadOutlined',
  367. component: './operatePage/kyyBoxManage',
  368. },
  369. {
  370. path: '/operatePage/apitest',
  371. name: 'api测试',
  372. access: 'apitest',
  373. icon: 'ReadOutlined',
  374. component: './operatePage/apitest',
  375. },
  376. ]
  377. }
  378. /**本地数据中心路由配置 */
  379. const dataStatistics = {
  380. path: '/dataStatistics',
  381. routes: [
  382. {
  383. path: '/dataStatistics/weChat',
  384. name: '公众号数据',
  385. access: 'weChat',
  386. routes: [
  387. {
  388. path: '/dataStatistics/weChat/weChatList',
  389. name: '公众号总数据',
  390. access: 'weChatList',
  391. component: './dataStatistics/weChat/weChatList',
  392. },
  393. {
  394. path: '/dataStatistics/weChat/advertising',
  395. name: '广告投放数据',
  396. access: 'advertising',
  397. component: './dataStatistics/weChat/advertising',
  398. },
  399. {
  400. path: '/dataStatistics/weChat/ChannelAnalysis',
  401. name: '公众号用户充值查询',
  402. access: 'ChannelAnalysis',
  403. component: './dataStatistics/weChat/ChannelAnalysis',
  404. },
  405. {
  406. path: '/dataStatistics/weChat/todayRanking',
  407. name: '今日消耗排行',
  408. access: 'todayRanking',
  409. component: './dataStatistics/weChat/todayRanking',
  410. },
  411. {
  412. path: '/dataStatistics/weChat/sevenDay',
  413. name: '公众号7日复充趋势',
  414. access: 'sevenDay',
  415. component: './dataStatistics/weChat/sevenDay',
  416. },
  417. {
  418. path: '/dataStatistics/weChat/payFans',
  419. name: '公众号付费粉丝激活数据',
  420. access: 'payFans',
  421. component: './dataStatistics/weChat/payFans',
  422. },
  423. {
  424. path: '/dataStatistics/weChat/payTrend',
  425. name: '公众号付费趋势表',
  426. access: 'payTrend',
  427. component: './dataStatistics/weChat/payTrend',
  428. },
  429. {
  430. path: '/dataStatistics/weChat/payTrendCom',
  431. name: '公众号付费趋势(含赔付金)',
  432. access: 'payTrend',
  433. component: './dataStatistics/weChat/payTrendCom',
  434. },
  435. {
  436. path: '/dataStatistics/weChat/osoRoi',
  437. name: '公众号回收查询',
  438. access: 'osoRoi',
  439. component: './dataStatistics/weChat/osoRoi',
  440. },
  441. ]
  442. },
  443. {
  444. path: '/dataStatistics/pitcher',
  445. name: '投手数据',
  446. access: 'pitcher',
  447. routes: [
  448. {
  449. path: '/dataStatistics/pitcher/pitcherPay',
  450. name: '投手付费趋势表',
  451. access: 'pitcherPay',
  452. component: './dataStatistics/pitcher/pitcherPay',
  453. },
  454. {
  455. path: '/dataStatistics/pitcher/dataCenter',
  456. name: '投手概况',
  457. access: 'dataCenter',
  458. component: './dataStatistics/pitcher/dataCenter',
  459. },
  460. {
  461. path: '/dataStatistics/pitcher/overview',
  462. name: '投手总数据',
  463. access: 'overview',
  464. component: './dataStatistics/pitcher/overview',
  465. },
  466. {
  467. path: '/dataStatistics/pitcher/pitcherChannel',
  468. name: '投手投放号',
  469. access: 'pitcherChannel',
  470. component: './dataStatistics/pitcher/pitcherChannel',
  471. },
  472. {
  473. path: '/dataStatistics/pitcher/recoveryQuery',
  474. name: '投手回收查询',
  475. access: 'recoveryQuery',
  476. component: './dataStatistics/pitcher/recoveryQuery',
  477. },
  478. ]
  479. },
  480. {
  481. path: '/dataStatistics/book',
  482. name: '小说数据',
  483. access: 'novel',
  484. routes: [
  485. {
  486. path: '/dataStatistics/book/payTrend',
  487. name: '小说付费趋势',
  488. access: 'payTrend',
  489. component: './dataStatistics/book/payTrend',
  490. },
  491. {
  492. path: '/dataStatistics/book/summarizing',
  493. name: '小说总数据',
  494. access: 'summarizing',
  495. component: './dataStatistics/book/summarizing',
  496. },
  497. ]
  498. },
  499. {
  500. path: '/dataStatistics/imageRank',
  501. name: '素材数据',
  502. access: 'imageRank',
  503. routes: [
  504. {
  505. path: '/dataStatistics/imageRank/imageLibrary',
  506. name: '素材库',
  507. access: 'imageLibrary',
  508. component: './dataStatistics/imageRank/imageLibrary',
  509. },
  510. {
  511. path: '/dataStatistics/imageRank/adCost',
  512. name: '素材消耗排行榜',
  513. access: 'adCost',
  514. component: './dataStatistics/imageRank/adCost',
  515. },
  516. ]
  517. },
  518. {
  519. path: '/dataStatistics/rechargeMonitor',
  520. name: '充值监控',
  521. access: 'rechargeMonitor',
  522. routes: [
  523. {
  524. path: '/dataStatistics/rechargeMonitor/rechargeHis',
  525. name: '充值历史',
  526. access: 'rechargeHis',
  527. component: './dataStatistics/rechargeMonitor/rechargeHis',
  528. },
  529. {
  530. path: '/dataStatistics/rechargeMonitor/rechargeHisYear',
  531. name: '充值历史(年)',
  532. access: 'rechargeHisYear',
  533. component: './dataStatistics/rechargeMonitor/rechargeHisYear',
  534. },
  535. ]
  536. },
  537. {
  538. path: '/dataStatistics/allSurvey',
  539. name: '整体概况',
  540. access: 'allSurvey',
  541. component: './dataStatistics/allSurvey',
  542. },
  543. ]
  544. }
  545. /** 投放系统 */
  546. const launchSystem = {
  547. path: '/launchSystem',
  548. routes: [
  549. {
  550. path: '/launchSystem/adMonitor',
  551. name: '广告监控',
  552. access: 'adMonitor',
  553. routes: [
  554. {
  555. path: '/launchSystem/adMonitor/adMonitorList',
  556. name: '广告监控',
  557. access: 'adMonitorList',
  558. component: './launchSystem/adMonitor/adMonitorList',
  559. },
  560. {
  561. path: '/launchSystem/adMonitor/monitorDataSource',
  562. name: '监控数据源',
  563. access: 'monitorDataSource',
  564. component: './launchSystem/adMonitor/monitorDataSource',
  565. },
  566. ]
  567. },
  568. {
  569. path: '/launchSystem/launchManage',
  570. name: '广告投放',
  571. access: 'launchManage',
  572. routes: [
  573. {
  574. path: '/launchSystem/launchManage/adAuthorize',
  575. name: '授权',
  576. access: 'adAuthorize',
  577. component: './launchSystem/launchManage/adAuthorize',
  578. },
  579. {
  580. path: '/launchSystem/launchManage/weChat',
  581. name: '微信',
  582. access: 'weChat',
  583. component: './launchSystem/launchManage/weChat',
  584. },
  585. {
  586. path: '/launchSystem/launchManage/taskList',
  587. name: '任务列表',
  588. access: 'taskList',
  589. component: './launchSystem/launchManage/taskList',
  590. },
  591. ]
  592. },
  593. {
  594. path: '/launchSystem/launchManageNew',
  595. name: '广告投放(new)',
  596. access: 'launchManageNew',
  597. routes: [
  598. {
  599. path: '/launchSystem/launchManageNew/weChatNew',
  600. name: '微信',
  601. access: 'weChatNew',
  602. component: './launchSystem/launchManageNew/weChatNew',
  603. },
  604. {
  605. path: '/launchSystem/launchManageNew/taskList',
  606. name: '任务列表',
  607. access: 'taskList',
  608. component: './launchSystem/launchManageNew/taskList',
  609. }
  610. ]
  611. },
  612. {
  613. path: '/launchSystem/launchManageAdq',
  614. name: '广告投放(ADQ)',
  615. access: 'launchManageAdq',
  616. routes: [
  617. {
  618. path: '/launchSystem/launchManageAdq/weChatAdq',
  619. name: '微信',
  620. access: 'weChatAdq',
  621. component: './launchSystem/launchManageAdq/weChatAdq',
  622. }
  623. ]
  624. },
  625. {
  626. path: '/launchSystem/materialManage',
  627. name: '云素材管理中心',
  628. access: 'materialManage',
  629. routes: [
  630. {
  631. path: '/launchSystem/materialManage/adOriginality',
  632. name: '广告创意',
  633. access: 'adOriginality',
  634. component: './launchSystem/materialManage/adOriginality',
  635. },
  636. {
  637. path: '/launchSystem/materialManage/adMaterial',
  638. name: '广告图片/视频',
  639. access: 'adMaterial',
  640. component: './launchSystem/materialManage/adMaterial',
  641. },
  642. {
  643. path: '/launchSystem/materialManage/adTitle',
  644. name: '广告标题/文案',
  645. access: 'adTitle',
  646. component: './launchSystem/materialManage/adTitle',
  647. },
  648. // {
  649. // path: '/launchSystem/materialManage/tagManage',
  650. // name: '标签管理',
  651. // access: 'tagManage',
  652. // component: './launchSystem/materialManage/tagManage',
  653. // },
  654. ]
  655. },
  656. {
  657. path: '/launchSystem/materialManageBd',
  658. name: '本地素材管理中心',
  659. access: 'materialManage',
  660. routes: [
  661. {
  662. path: '/launchSystem/materialManageBd/adOriginality',
  663. name: '广告创意',
  664. access: 'adOriginality',
  665. component: './launchSystem/materialManageBd/adOriginality',
  666. },
  667. {
  668. path: '/launchSystem/materialManageBd/adMaterial',
  669. name: '广告图片/视频',
  670. access: 'adMaterial',
  671. component: './launchSystem/materialManageBd/adMaterial',
  672. },
  673. {
  674. path: '/launchSystem/materialManageBd/adTitle',
  675. name: '广告标题/文案',
  676. access: 'adTitle',
  677. component: './launchSystem/materialManageBd/adTitle',
  678. },
  679. {
  680. path: '/launchSystem/materialManageBd/tagManage',
  681. name: '标签管理',
  682. access: 'tagManage',
  683. component: './launchSystem/materialManageBd/tagManage',
  684. },
  685. ]
  686. },
  687. {
  688. path: '/launchSystem/headline/staticHtml',
  689. name: '头条落地页',
  690. access: 'staticHtml',
  691. component: './launchSystem/headline/staticHtml',
  692. },
  693. {
  694. path: '/launchSystem/material',
  695. name: '素材管理',
  696. access: 'material',
  697. icon: 'DatabaseOutlined',
  698. routes: [
  699. {
  700. name: '本地素材',
  701. path: '/launchSystem/material/cloud',
  702. access: 'cloud',
  703. component: './launchSystem/material/cloud',
  704. },
  705. ],
  706. },
  707. ]
  708. }
  709. /** 企业微信 */
  710. const enterpriseWeChat = {
  711. path: '/enterpriseWeChat',
  712. routes: [
  713. {
  714. path: '/enterpriseWeChat/userManage',
  715. name: '账号管理',
  716. access: 'enterpriseWeChatUserManage',
  717. component: './enterpriseWeChat/userManage'
  718. },
  719. {
  720. path: '/enterpriseWeChat/complaint',
  721. name: '投诉信息',
  722. access: 'enterpriseWeChatComplaint',
  723. component: './enterpriseWeChat/complaint'
  724. },
  725. ]
  726. }
  727. export {
  728. headrRouter,
  729. getMyMenu,
  730. operatePage,
  731. dataStatistics,
  732. launchSystem,
  733. enterpriseWeChat
  734. }