manage-client 3.2.138 → 3.2.139-tcc

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,176 +1,176 @@
1
- var express = require('express')
2
- var webpack = require('webpack')
3
- var config = require('./webpack.dev.conf')
4
- var proxyMiddleware = require('http-proxy-middleware')
5
- // var httpProxy = require('http-proxy')
6
-
7
- var app = express()
8
- var compiler = webpack(config)
9
- // var proxy = httpProxy.createProxyServer()
10
-
11
- // Define HTTP proxies to your custom API backend
12
- // https://github.com/chimurai/http-proxy-middleware
13
- // var bendi = 'http://127.0.0.1:8089/manage', fuwu = 'http://36.103.224.217:6300/'
14
- var shaoguan='http://119.146.1.106:8300/'
15
- var qtx='http://36.103.222.144:6300/'
16
- var bendi = 'http://127.0.0.1:8090'
17
- // var bendi = 'http://172.168.1.11:9001'
18
- var fuwu = 'http://121.36.106.17:8400'
19
- // var fuwu = 'http://203.57.101.233:9001'
20
- var system = 'http://192.168.50.4:8400'
21
- //192.168.
22
- // var str = 'http://127.0.0.1:8080/manage', str2 = 'http://192.168.50.199:8300'
23
- // var str = 'http://192.168.10.233:8300', str2 = 'http://192.168.10.14:8300'
24
- var proxyTable = {
25
- '/rs/logic/exportfile': {
26
- target: fuwu
27
- },
28
- '/files': {
29
- target: fuwu
30
- },
31
- // 查找资源服务数据
32
- '/rs/search': {
33
- target: fuwu
34
- },
35
- // 查找资源服务数据
36
- '/rs/logic/getLogin': {
37
- target: fuwu
38
- },
39
- // 查找资源服务数据
40
- '/rs/logic/getInitData': {
41
- target: fuwu
42
- },
43
- '/rs/logic/getSaleInitData':{
44
- target: fuwu
45
- },
46
- // 用户登录服务地址
47
- '/rs/user': {
48
- target: fuwu
49
- },
50
- '/rs/path/getParams': {
51
- target: fuwu
52
- },
53
- '/rs/data': {
54
- target: fuwu
55
- },
56
- '/rs/license': {
57
- target: fuwu
58
- },
59
- '/rs/db': {
60
- target: fuwu
61
- },
62
- '/excel': {
63
- target: fuwu
64
- },
65
- '/rs/config': {
66
- target: fuwu
67
- },
68
- '/rs/sql/getLicenseById': {
69
- target: fuwu
70
- },
71
- '/rs/report': {
72
- target: bendi
73
- },
74
- '/rs/vue': {
75
- target: fuwu
76
- },
77
- '/rs/file': {
78
- target: bendi
79
- },
80
- '/rs/logic/SumSettleFileImport': {
81
- target: 'http://127.0.0.1:8080'
82
- },
83
- '/rs': {
84
- target: fuwu
85
- }
86
- }
87
-
88
- var devMiddleware = require('webpack-dev-middleware')(compiler, {
89
- publicPath: config.output.publicPath,
90
- stats: {
91
- colors: true,
92
- chunks: false
93
- }
94
- })
95
-
96
- var hotMiddleware = require('webpack-hot-middleware')(compiler)
97
- // force page reload when html-webpack-plugin template changes
98
- compiler.plugin('compilation', function (compilation) {
99
- compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
100
- hotMiddleware.publish({action: 'reload'})
101
- cb()
102
- })
103
- })
104
-
105
- // proxy api requests
106
- Object.keys(proxyTable).forEach(function (context) {
107
- var options = proxyTable[context]
108
- if (typeof options === 'string') {
109
- options = {target: options}
110
- }
111
- app.use(proxyMiddleware(context, options))
112
- })
113
-
114
- // handle fallback for HTML5 history API
115
- app.use(require('connect-history-api-fallback')())
116
- // app.use(function (req, res, next) {
117
- // res.header('Access-Control-Allow-Origin', '*')
118
- // res.header('Access-Control-Allow-Headers', 'X-Requested-With')
119
- // res.header('Access-Control-Allow-Methods', 'PUT, POST, GET,DELETE, OPTIONS')
120
- // res.header('X-Powered-By', '3,2,1')
121
- // res.header('Access-Control-Allow-Credentials', 'true')
122
- // res.header('Content-Type', 'application/json;charset=utf-8')
123
- // next()
124
- // })
125
-
126
- // serve webpack bundle output
127
- app.use(devMiddleware)
128
-
129
- // enable hot-reload and state-preserving
130
- // compilation error display
131
- app.use(hotMiddleware)
132
-
133
- // serve pure static assets
134
- app.use('/static', express.static('./static'))
135
-
136
- // app.all('/rs/*', function (req, res) {
137
- // proxy.web(req, res, {
138
- // target: 'http://127.0.0.1:8081/reports'
139
- // })
140
- // })
141
-
142
- // app.all('/rs/*', function (req, res) {
143
- // proxy.web(req, res, {
144
- // target: 'http://127.0.0.1:8081/ldap'
145
- // })
146
- // })
147
- // app.all('/excel/*', function (req, res) {
148
- // proxy.web(req, res, {
149
- // target: 'http://127.0.0.1:8081/charge'
150
- // })
151
- // })
152
-
153
- // app.all('/rs/*', function (req, res) {
154
- // proxy.web(req, res, {
155
- // target: 'http://127.0.0.1:82/charge'
156
- // })
157
- // })
158
-
159
- // app.all('/*', function (req, res) {
160
- // proxy.web(req, res, {
161
- // target: 'http://127.0.0.1:82'
162
- // })
163
- // })
164
- // app.all('/rs/user', function (req, res) {
165
- // proxy.web(req, res, {
166
- // target: 'http://127.0.0.1:82'
167
- // })
168
- // })
169
-
170
- module.exports = app.listen(8085, function (err) {
171
- if (err) {
172
- console.log(err)
173
- return
174
- }
175
- console.log('Listening at http://localhost:8085')
176
- })
1
+ var express = require('express')
2
+ var webpack = require('webpack')
3
+ var config = require('./webpack.dev.conf')
4
+ var proxyMiddleware = require('http-proxy-middleware')
5
+ // var httpProxy = require('http-proxy')
6
+
7
+ var app = express()
8
+ var compiler = webpack(config)
9
+ // var proxy = httpProxy.createProxyServer()
10
+
11
+ // Define HTTP proxies to your custom API backend
12
+ // https://github.com/chimurai/http-proxy-middleware
13
+ // var bendi = 'http://127.0.0.1:8089/manage', fuwu = 'http://36.103.224.217:6300/'
14
+ var shaoguan='http://119.146.1.106:8300/'
15
+ var qtx='http://36.103.222.144:6300/'
16
+ var bendi = 'http://192.168.50.4:8400'
17
+ // var bendi = 'http://172.168.1.11:9001'
18
+ var fuwu = 'http://192.168.50.4:8400'
19
+ // var fuwu = 'http://203.57.101.233:9001'
20
+ var system = 'http://192.168.50.4:8400'
21
+ //192.168.
22
+ // var str = 'http://127.0.0.1:8080/manage', str2 = 'http://192.168.50.199:8300'
23
+ // var str = 'http://192.168.10.233:8300', str2 = 'http://192.168.10.14:8300'
24
+ var proxyTable = {
25
+ '/rs/logic/exportfile': {
26
+ target: fuwu
27
+ },
28
+ '/files': {
29
+ target: fuwu
30
+ },
31
+ // 查找资源服务数据
32
+ '/rs/search': {
33
+ target: fuwu
34
+ },
35
+ // 查找资源服务数据
36
+ '/rs/logic/getLogin': {
37
+ target: fuwu
38
+ },
39
+ // 查找资源服务数据
40
+ '/rs/logic/getInitData': {
41
+ target: fuwu
42
+ },
43
+ '/rs/logic/getSaleInitData':{
44
+ target: fuwu
45
+ },
46
+ // 用户登录服务地址
47
+ '/rs/user': {
48
+ target: fuwu
49
+ },
50
+ '/rs/path/getParams': {
51
+ target: fuwu
52
+ },
53
+ '/rs/data': {
54
+ target: fuwu
55
+ },
56
+ '/rs/license': {
57
+ target: fuwu
58
+ },
59
+ '/rs/db': {
60
+ target: fuwu
61
+ },
62
+ '/excel': {
63
+ target: fuwu
64
+ },
65
+ '/rs/config': {
66
+ target: fuwu
67
+ },
68
+ '/rs/sql/getLicenseById': {
69
+ target: fuwu
70
+ },
71
+ '/rs/report': {
72
+ target: bendi
73
+ },
74
+ '/rs/vue': {
75
+ target: fuwu
76
+ },
77
+ '/rs/file': {
78
+ target: bendi
79
+ },
80
+ '/rs/logic/SumSettleFileImport': {
81
+ target: 'http://127.0.0.1:8080'
82
+ },
83
+ '/rs': {
84
+ target: fuwu
85
+ }
86
+ }
87
+
88
+ var devMiddleware = require('webpack-dev-middleware')(compiler, {
89
+ publicPath: config.output.publicPath,
90
+ stats: {
91
+ colors: true,
92
+ chunks: false
93
+ }
94
+ })
95
+
96
+ var hotMiddleware = require('webpack-hot-middleware')(compiler)
97
+ // force page reload when html-webpack-plugin template changes
98
+ compiler.plugin('compilation', function (compilation) {
99
+ compilation.plugin('html-webpack-plugin-after-emit', function (data, cb) {
100
+ hotMiddleware.publish({action: 'reload'})
101
+ cb()
102
+ })
103
+ })
104
+
105
+ // proxy api requests
106
+ Object.keys(proxyTable).forEach(function (context) {
107
+ var options = proxyTable[context]
108
+ if (typeof options === 'string') {
109
+ options = {target: options}
110
+ }
111
+ app.use(proxyMiddleware(context, options))
112
+ })
113
+
114
+ // handle fallback for HTML5 history API
115
+ app.use(require('connect-history-api-fallback')())
116
+ // app.use(function (req, res, next) {
117
+ // res.header('Access-Control-Allow-Origin', '*')
118
+ // res.header('Access-Control-Allow-Headers', 'X-Requested-With')
119
+ // res.header('Access-Control-Allow-Methods', 'PUT, POST, GET,DELETE, OPTIONS')
120
+ // res.header('X-Powered-By', '3,2,1')
121
+ // res.header('Access-Control-Allow-Credentials', 'true')
122
+ // res.header('Content-Type', 'application/json;charset=utf-8')
123
+ // next()
124
+ // })
125
+
126
+ // serve webpack bundle output
127
+ app.use(devMiddleware)
128
+
129
+ // enable hot-reload and state-preserving
130
+ // compilation error display
131
+ app.use(hotMiddleware)
132
+
133
+ // serve pure static assets
134
+ app.use('/static', express.static('./static'))
135
+
136
+ // app.all('/rs/*', function (req, res) {
137
+ // proxy.web(req, res, {
138
+ // target: 'http://127.0.0.1:8081/reports'
139
+ // })
140
+ // })
141
+
142
+ // app.all('/rs/*', function (req, res) {
143
+ // proxy.web(req, res, {
144
+ // target: 'http://127.0.0.1:8081/ldap'
145
+ // })
146
+ // })
147
+ // app.all('/excel/*', function (req, res) {
148
+ // proxy.web(req, res, {
149
+ // target: 'http://127.0.0.1:8081/charge'
150
+ // })
151
+ // })
152
+
153
+ // app.all('/rs/*', function (req, res) {
154
+ // proxy.web(req, res, {
155
+ // target: 'http://127.0.0.1:82/charge'
156
+ // })
157
+ // })
158
+
159
+ // app.all('/*', function (req, res) {
160
+ // proxy.web(req, res, {
161
+ // target: 'http://127.0.0.1:82'
162
+ // })
163
+ // })
164
+ // app.all('/rs/user', function (req, res) {
165
+ // proxy.web(req, res, {
166
+ // target: 'http://127.0.0.1:82'
167
+ // })
168
+ // })
169
+
170
+ module.exports = app.listen(8085, function (err) {
171
+ if (err) {
172
+ console.log(err)
173
+ return
174
+ }
175
+ console.log('Listening at http://localhost:8085')
176
+ })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "manage-client",
3
- "version": "3.2.138",
3
+ "version": "3.2.139-tcc",
4
4
  "description": "经营管控模块前台组件",
5
5
  "main": "src/index.js",
6
6
  "directories": {