config.js 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. // var host = window.location.protocol + '//' + window.location.hostname
  2. // 当前后端不在同一个服务器时,需要指定host地址
  3. // var host = 'http://10.7.13.26' // 以前
  4. // var host = 'http://116.204.117.33' //基本用这个
  5. //var host = 'http://116.204.117.33' // 测试
  6. // var host = 'http://b463f4b7.natappfree.cc' // 后端服务海鹏
  7. // var host = 'http://5jrgep.ipx.wanziwk.cn' // 后端服务译文
  8. var host = 'http://127.0.0.1' // 后端服务译文
  9. // var host = 'http://1.71.9.215'
  10. // var host = 'http://5jrgep.ipx.wanziwk.cn'
  11. // combine为true时五合一部署, 为false时分五个服务部署
  12. var combine = true
  13. // var gateway = '8280/stage-api'
  14. var gateway = '9506/stage-api'
  15. var defaultModulePortMap = {
  16. form: gateway + '/form',
  17. portal: gateway + '/portal',
  18. bpmRunTime: gateway + '/bpmRunTime',
  19. bpmModel: gateway + '/bpmModel',
  20. uc: gateway + '/uc',
  21. auth: gateway + '/auth',
  22. commonSign: gateway,
  23. }
  24. window.getModuleRootUrl = function (module) {
  25. // 默认是全部服务合一的端口
  26. //var modulePort = '8089' // 以前
  27. var modulePort = '9506' // 基本用这个
  28. // var modulePort = '8088' //测试
  29. // var modulePort = '9801'
  30. // var modulePort = ''
  31. if (!combine) {
  32. modulePort = defaultModulePortMap[module]
  33. }
  34. return "http://5jrgep.ipx.wanziwk.cn";
  35. //return host + ':' + modulePort
  36. // return host + modulePort
  37. }
  38. window.context = {
  39. manage: host + ':8280/mvue', //管理端页面
  40. front: host + ':8280/front', //前端页面
  41. mobile: host + ':8280/mobile', //手机端页面
  42. form: getModuleRootUrl('form'),
  43. portal: getModuleRootUrl('portal'),
  44. bpmRunTime: getModuleRootUrl('bpmRunTime'),
  45. bpmModel: getModuleRootUrl('bpmModel'),
  46. uc: getModuleRootUrl('uc'),
  47. auth: getModuleRootUrl('auth'),
  48. commonSign: 'http://10.7.14.215:8280/stage-api/',
  49. //后台接口是新开的端口 8082
  50. // costAudit: host + ':8082'
  51. }
  52. // 单点配置
  53. window.ssoConfig = {
  54. // mode: 'oauth', // 空则不使用单点 支持的模式有 cas oauth basic
  55. // url: 'http://10.7.14.215:8280/auth',
  56. // clientId: 'workbench', // oauth模式下需要提供
  57. // logout: 'http://10.7.14.215:8280/auth'
  58. }