华西海圻ELN前端工程
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.3 KiB

  1. // 菜单语言适配
  2. let menuObj = {
  3. 个人中心: 'Home Page',
  4. 工作台: 'My Work',
  5. 试验管理: 'Study',
  6. 表单管理: 'Record',
  7. 非试验表单: 'Non-study',
  8. 麻精药表单: 'Controlled Drug',
  9. 资源库管理: 'Resources',
  10. 试剂管理: 'ReagentManage',
  11. 供试品管理: 'SpecimenManage',
  12. 给药制剂管理: 'Formulation Manage',
  13. 麻精药管理: 'DrugManage',
  14. 钥匙管理: 'KeyManage',
  15. 仪器管理: 'InstrumentManage',
  16. 档案管理: 'Archive',
  17. 试验档案管理: 'Study Archive',
  18. 非试验档案管理: 'Non-study Archive',
  19. 麻精药配置档案管理: 'Drug Archive',
  20. 供试品档案管理: 'Test Item Archive',
  21. 给药制剂档案管理: 'Formulation Archive',
  22. 麻精药档案管理: 'Controlled Drug Archive',
  23. 试剂档案管理: 'Reagent Archive',
  24. 档案记录: 'Archive Log',
  25. 系统管理: 'System',
  26. 菜单管理: 'Menu',
  27. 角色管理: 'Role',
  28. 用户管理: 'User',
  29. '部门/学科管理': 'Dep & Dis',
  30. 模板管理: 'Function',
  31. 字典管理: 'Term Book',
  32. 日志管理: 'Log'
  33. }
  34. export function getMenuName(menuName) {
  35. if (!this.$i18n.locale || this.$i18n.locale === 'zh_CN') {
  36. return menuName
  37. }
  38. if (menuName.indexOf(':') > -1) {
  39. return menuObj[menuName.split(':')[0]] + menuName.split(':')[1]
  40. }
  41. return menuObj[menuName] || menuName
  42. }