config.js 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. module.exports = {
  2. current: { server: "192.168.1.184", port: "60666" },
  3. defaultLicenseKey:
  4. "admin.jl2.smartcost.com.cn|admin.jlqa2.smartcost.com.cn|admin.jluat2.smartcost.com.cn|civil.smartcost.com.cn|cloud.smartcost.com.cn|glm.smartcost.com.cn|gluat.smartcost.com.cn|glum.smartcost.com.cn|glyun.smartcost.com.cn|gsm.smartcost.com.cn|gsqa.smartcost.com.cn|gsqm.smartcost.com.cn|gsuat.smartcost.com.cn|gsum.smartcost.com.cn|gsyun.smartcost.com.cn|jl.smartcost.com.cn|jl2.smartcost.com.cn|jladmin.smartcost.com.cnjlqaadmin.smartcost.com.cn|jlqa.smartcost.com.cn|jlqa2.smartcost.com.cn|jluat.smartcost.com.cn|jluat2.smartcost.com.cn|jluatadmin.smartcost.com.cn|pm.smartcost.com.cn|pmqa.smartcost.com.cn|pmuat.smartcost.com.cn|qa.smartcost.com.cn|qa.std.smartcost.com.cn|qm.smartcost.com.cn|std.smartcost.com.cn|uat.smartcost.com.cn|um.smartcost.com.cn|yhm.smartcost.com.cn|yhqa.smartcost.com.cn|yhqm.smartcost.com.cn|yhuat.smartcost.com.cn|yhum.smartcost.com.cn|yhyun.smartcost.com.cn|ym.smartcost.com.cn|yun.smartcost.com.cn|zb.smartcost.com.cn|zbqa.smartcost.com.cn|zbuat.smartcost.com.cn,681116852352674#A0KbwFWYxxmauNmLt36YuQ7cvNGdyFWbz9ibp5GZhxmas86Yu46bj9Cdz36Y4JXYtNnLywmas86Yu46bj9Cdz36Y4JXYtNnLspGLuNmLt36YuQ7cvNGdyFWbz9ib5l7cnxibj9SbvNmL4N7bjRnch56cu4WdzdGLuNmLt36YuQ7cvNGdyFWbz9Cdh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ga9xibj9SbvNmL4N7bjRnch56cu4Wds86Yu46bj9Cdz36Y4JXYtNnL4FWds86Yu46bj9Cdz36Y4JXYtNnLkR7cs86Yu46bj9Cdz36Y4JXYtNnLtFHLuNmLt36YuQ7cvNGdyFWbz9CZ4NnLhFHLuNmLt36YuQ7cvNGdyFWbz9SYxxibj9SbvNmL4N7bjRnch56cuQXY55Gcs86Yu46bj9Cdz36Y4JXYtNnLhFXbwxibj9SbvNmL4N7bjRnch56cu4Gcs86Yu46bj9Cdz36Y4JXYtNnLulWbkFGdhVHbqxibj9SbvNmL4N7bjRnch56cuIDdhVHbqxibj9SbvNmL4N7bjRnch56cuQXY5xmas86Yu46bj9Cdz36Y4JXYtNnLyEWcspGLuNmLt36YuQ7cvNGdyFWbz9SYxxmas86Yu46bj9Cdz36Y4JXYtNULNl",
  5. local: { server: "localhost", port: "27017" },
  6. qa: {
  7. server: "192.168.1.90",
  8. port: "60666",
  9. options: {
  10. user: "smartcost",
  11. pass: "smartcost3850888",
  12. auth: {
  13. authdb: "admin",
  14. },
  15. connectTimeoutMS: 100000,
  16. useMongoClient: true,
  17. },
  18. },
  19. qa_outer: {
  20. server: "smartcost.in.8866.org",
  21. port: "26904",
  22. options: {
  23. user: "smartcost",
  24. pass: "smartcost3850888",
  25. auth: {
  26. authdb: "admin",
  27. },
  28. connectTimeoutMS: 100000,
  29. useMongoClient: true,
  30. },
  31. importURL: "192.168.1.184:6050",
  32. },
  33. pp: {
  34. server: "172.18.111.231",
  35. port: "27017",
  36. options: {
  37. user: "smartcost",
  38. pass: "SmartCost3850888",
  39. auth: {
  40. authdb: "admin",
  41. },
  42. connectTimeoutMS: 50000,
  43. useMongoClient: true,
  44. },
  45. },
  46. uat: {
  47. server: "112.74.42.187",
  48. port: "27017",
  49. options: {
  50. user: "smartcost",
  51. pass: "SmartCost3850888",
  52. auth: {
  53. authdb: "admin",
  54. },
  55. connectTimeoutMS: 50000,
  56. useMongoClient: true,
  57. },
  58. },
  59. prod_s: {
  60. server: "112.74.42.187",
  61. port: "28066",
  62. options: {
  63. user: "smartcost",
  64. pass: "SmartCost3850888",
  65. auth: {
  66. authdb: "admin",
  67. },
  68. connectTimeoutMS: 50000,
  69. useMongoClient: true,
  70. },
  71. },
  72. prod: {
  73. dbURL:
  74. "mongodb://smartcost:SmartCost3850888@dds-wz9da4d5ca0fdd341.mongodb.rds.aliyuncs.com:3717,dds-wz9da4d5ca0fdd342.mongodb.rds.aliyuncs.com:3717/scConstruct?authSource=admin;replicaSet=mgset-7518601",
  75. LicenseKey:
  76. "civil.smartcost.com.cn|yun.smartcost.com.cn|cloud.smartcost.com.cn|qa.smartcost.com.cn|uat.smartcost.com.cn|zbqa.smartcost.com.cn|zbuat.smartcost.com.cn|jlqa.smartcost.com.cn|jluat.smartcost.com.cn|zb.smartcost.com.cn|jl.smartcost.com.cn|ym.smartcost.com.cn|qm.smartcost.com.cn|um.smartcost.com.cn,834986144349993#A0Jb6Rnch56cuEWcs86Yu46bj9Cdz36Y4JXYtNnLkV7bsNGLuNmLt36YuQ7cvNGdyFWbz9ib5lHLuNmLt36YuQ7cvNGdyFWbz9CbpZXajJiOiMXbEJCLig1jlzahlDZmpnInmb1uk/avoDrlmvJilrKqmXrunfbtmD0jnLiOiEmTDJCLiMTO9kDNzQDNxYDO9QzM8IiOiQWSiwSflNHbhZmOiI7ckJye0ICbuFkI1pjIEJCLi4TP7d4cY5WV4IkQlFVT6BHVPdjN8UUMNNUQ7lDVzNTMw3Wel94d6I7MOhFWLJXOzITcSl7cpVXZ4x6KWNHaURWWkJle54WQ5NlWr2WQFFHTaRFeG54KGJmI0IyUiwCO6IDN9ATNyAjM0IicfJye#4Xfd5nIzImNnJiOiMkIsISMx8idgMlSgQWYlJHcTJiOi8kI1tlOiQmcQJCLiYDMyMDMxAiMwEDM9EDMyIiOiQncDJCLi86Yu46bj9Cdz36Y4JXYtNnLtVHLuNmLt36YuQ7cvNGdyFWbz9Sbxxibj9SbvNmL4N7bjRnch56cu4Wes86Yu46bj9Cdz36Y4JXYtNnLspGLuNmLt36YuQ7cvNGdyFWbz9iY0xibj9SbvNmL4N7bjRnch56cuQXY5xmas86Yu46bj9Cdz36Y4JXYtNnLhFHbqxibj9SbvNmL4N7bjRnch56cuQXY5Jmes86Yu46bj9Cdz36Y4JXYtNnLhFnY0xibj9SbvNmL4N7bjRnch56cuQXY5xibj9SbvN1LMN",
  77. },
  78. prod_gs: {
  79. title: "概算云版后台",
  80. dbName: "gaisuan",
  81. dbURL:
  82. "mongodb://smartcost:SmartCost3850888@dds-wz9da4d5ca0fdd341.mongodb.rds.aliyuncs.com:3717,dds-wz9da4d5ca0fdd342.mongodb.rds.aliyuncs.com:3717/gaisuan?authSource=admin;replicaSet=mgset-7518601",
  83. LicenseKey:
  84. "admin.jl2.smartcost.com.cn|admin.jlqa2.smartcost.com.cn|admin.jluat2.smartcost.com.cn|civil.smartcost.com.cn|cloud.smartcost.com.cn|glm.smartcost.com.cn|gluat.smartcost.com.cn|glum.smartcost.com.cn|glyun.smartcost.com.cn|gsm.smartcost.com.cn|gsqa.smartcost.com.cn|gsqm.smartcost.com.cn|gsuat.smartcost.com.cn|gsum.smartcost.com.cn|gsyun.smartcost.com.cn|jl.smartcost.com.cn|jl2.smartcost.com.cn|jladmin.smartcost.com.cnjlqaadmin.smartcost.com.cn|jlqa.smartcost.com.cn|jlqa2.smartcost.com.cn|jluat.smartcost.com.cn|jluat2.smartcost.com.cn|jluatadmin.smartcost.com.cn|pm.smartcost.com.cn|pmqa.smartcost.com.cn|pmuat.smartcost.com.cn|qa.smartcost.com.cn|qa.std.smartcost.com.cn|qm.smartcost.com.cn|std.smartcost.com.cn|uat.smartcost.com.cn|um.smartcost.com.cn|yhm.smartcost.com.cn|yhqa.smartcost.com.cn|yhqm.smartcost.com.cn|yhuat.smartcost.com.cn|yhum.smartcost.com.cn|yhyun.smartcost.com.cn|ym.smartcost.com.cn|yun.smartcost.com.cn|zb.smartcost.com.cn|zbqa.smartcost.com.cn|zbuat.sm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j9SbvNmL4N7bjRnch56cu4Wes86Yu46bj9Cdz36Y4JXYtNnLuVXeolHLuNmLt36YuQ7cvNGdyFWbz9Sb5hWes86Yu46bj9Cdz36Y4JXYtNnL4FWdolHLuNmLt36YuQ7cvNGdyFWbz9SbxhWes86Yu46bj9Cdz36Y4JXYtNnLhFHa9xibj9SbvNmL4N7bjRnch56cu4Ga9xibj9SbvNmL4N7bjRnch56cu4Wds86Yu46bj9Cdz36Y4JXYtNnL4FWds86Yu46bj9Cdz36Y4JXYtNnLkR7cs86Yu46bj9Cdz36Y4JXYtNnLtFHLuNmLt36YuQ7cvNGdyFWbz9CZ4NnLhFHLuNmLt36YuQ7cvNGdyFWbz9SYxxibj9SbvNmL4N7bjRnch56cuQXY55Gcs86Yu46bj9Cdz36Y4JXYtNnLhFXbwxibj9SbvNmL4N7bjRnch56cu4Gcs86Yu46bj9Cdz36Y4JXYtNnLulWbkFGdhVHbqxibj9SbvNmL4N7bjRnch56cuIDdhVHbqxibj9SbvNmL4N7bjRnch56cuQXY5xmas86Yu46bj9Cdz36Y4JXYtNnLyEWcspGLuNmLt36YuQ7cvNGdyFWbz9SYxxmas86Yu46bj9Cdz36Y4JXYtNULNl",
  85. startPort: 7080,
  86. },
  87. qa_wc: {
  88. title: "大司空V2.0",
  89. startPort: 1002,
  90. server: "192.168.1.90",
  91. port: "60666",
  92. dbName: "stdBuilding",
  93. options: {
  94. user: "wisecost",
  95. pass: "Smartcost3850888",
  96. auth: {
  97. authSource: "admin",
  98. },
  99. connectTimeoutMS: 60000,
  100. useMongoClient: true,
  101. },
  102. },
  103. uat_wc: {
  104. title: "大司空V2.0",
  105. startPort: 1002,
  106. dbName: "stdBuilding",
  107. dbURL:
  108. "mongodb://wisecost:Smartcost3850888@dds-wz9691008169ac241.mongodb.rds.aliyuncs.com:3717,dds-wz9691008169ac242.mongodb.rds.aliyuncs.com:3717/stdBuilding?authSource=admin&replicaSet=mgset-61833418&maxPoolSize=10",
  109. },
  110. local2prod_wc: {
  111. title: "大司空V2.0",
  112. startPort: 1002,
  113. server: "112.74.42.187", //数据库ID
  114. port: "28033", //数据库端口
  115. dbName: "stdBuilding",
  116. options: {
  117. user: "wisecost",
  118. pass: "Smartcost3850888",
  119. auth: {
  120. authSource: "admin",
  121. },
  122. connectTimeoutMS: 60000,
  123. useMongoClient: true,
  124. },
  125. },
  126. prod_wc: {
  127. title: "大司空V2.0",
  128. startPort: 1002,
  129. dbName: "stdBuilding",
  130. dbURL:
  131. "mongodb://wisecost:Smartcost3850888@dds-wz9ec47d7af4a2e41.mongodb.rds.aliyuncs.com:3717,dds-wz9ec47d7af4a2e42.mongodb.rds.aliyuncs.com:3717/stdBuilding?authSource=admin;replicaSet=mgset-60527349",
  132. LicenseKey:
  133. "yun2.smartcost.com.cn|ym2.smartcost.com.cn|zhyun.smartcost.com.cn|zhym.smartcost.com.cn,681116852352674#A0AWS+mIWuqoaet0e+t5aOoPeuI0ISYONkIsICN7YjM5MjM5gjNxETM8YjI0ICZJJCL3V6csFmZ0IiczRmI1pjIs9WQisnOiQkIsISP3c6ZUVmbDRzcvcGaqZDSK36SWdmUzEEa7hlR8knNwEjZqVmTDhDctR4aaFlY7YGWwhVYQl6NWlUQP9kRHdHWoJmeBhHcRJzR79kMKZjclRnYjVGSPBFciojITJCL5MjMxgTNzQjM0IicfJye&Qf35VfiMjY6cmI0IyQiwiIxEjL6ByUKBCZhVmcwNlI0IiTis7W0ICZyBlIsISNyQDMwEDI8IDNwIjMwIjI0ICdyNkIsIibj9SbvNmL4N7bjRnch56cu4WeopHLuNmLt36YuQ7cvNGdyFWbz9ib5lHa0xibj9SbvNmL4N7bjRnch56cuITb9xibj9SbvNmL4N7bjRnch56cuIjb5lnI0IyctRkIsICuPWOrFWOkZmeicaut1S+I1RO",
  134. },
  135. setupDb: function (env = "local") {
  136. let me = this;
  137. me.current.server = me[env].server;
  138. me.current.port = me[env].port;
  139. },
  140. getSessionURL: function (env = "local") {
  141. let me = this;
  142. if (me[env].dbURL) {
  143. if (me[env].dbName) return me[env].dbURL;
  144. return me[env].dbURL.replace("scConstruct", "usersManagesOpr");
  145. }
  146. let manageDb = "usersManagesOpr";
  147. if (me[env].dbName) manageDb = me[env].dbName;
  148. if (me[env].options) {
  149. return (
  150. "mongodb://" +
  151. me[env].options.user +
  152. ":" +
  153. me[env].options.pass +
  154. "@" +
  155. me[env].server +
  156. ":" +
  157. me[env].port +
  158. "/" +
  159. manageDb +
  160. "?authSource=admin"
  161. );
  162. } else {
  163. return (
  164. "mongodb://" + me[env].server + ":" + me[env].port + "/" + manageDb
  165. ); //'mongodb://' + config.current.server + ':' + config.current.port + '/usersManagesOpr'
  166. }
  167. },
  168. getLicenseKey: function (env = "local") {
  169. let me = this;
  170. if (me[env].LicenseKey) {
  171. return me[env].LicenseKey;
  172. } else {
  173. return me.defaultLicenseKey;
  174. }
  175. },
  176. pageSize: 20,
  177. };