Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
H
hsWebHttpClient
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
何虹
hsWebHttpClient
Commits
36dc1d11
Commit
36dc1d11
authored
Dec 07, 2021
by
何虹
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化
parent
b8a422d9
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
44 additions
and
24 deletions
+44
-24
hsWebHttpClient.js
dist/hsWebHttpClient.js
+7
-5
hsWebHttpClient.min.js
dist/hsWebHttpClient.min.js
+1
-1
commonModule.js
src/packages/common/commonModule.js
+23
-2
webChartConfig.js
src/packages/modules/webChartConfig.js
+13
-16
No files found.
dist/hsWebHttpClient.js
View file @
36dc1d11
...
...
@@ -21798,7 +21798,7 @@ __webpack_require__.r(__webpack_exports__);
/* harmony export */ "SEND_BILLS": function() { return /* binding */ SEND_BILLS; },
/* harmony export */ "UN_SEND_BILLS": function() { return /* binding */ UN_SEND_BILLS; },
/* harmony export */ "REJECT_BILLS": function() { return /* binding */ REJECT_BILLS; },
/* harmony export */ "CONFIG_
TOOL_API": function() { return /* binding */ CONFIG_TOOL
_API; }
/* harmony export */ "CONFIG_
API": function() { return /* binding */ CONFIG
_API; }
/* harmony export */ });
/* harmony import */ var _commonProxy__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(31);
...
...
@@ -21818,7 +21818,7 @@ const UN_CLOSE_BILLS = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.COMMON_UTIL_
const SEND_BILLS = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.COMMON_UTIL_PROXY}/send_bills/`
const UN_SEND_BILLS = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.COMMON_UTIL_PROXY}/un_send_bills/`
const REJECT_BILLS = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.COMMON_UTIL_PROXY}/reject_bills/`
const CONFIG_
TOOL_API = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.CONFIG_TOOL
_PROXY}/`
const CONFIG_
API = `${_commonProxy__WEBPACK_IMPORTED_MODULE_0__.CONFIG
_PROXY}/`
...
...
@@ -21837,7 +21837,7 @@ __webpack_require__.r(__webpack_exports__);
/* harmony export */ "GQL_PROXY": function() { return /* binding */ GQL_PROXY; },
/* harmony export */ "FILE_RESOURCE_PROXY": function() { return /* binding */ FILE_RESOURCE_PROXY; },
/* harmony export */ "SERVICE_PROXY": function() { return /* binding */ SERVICE_PROXY; },
/* harmony export */ "CONFIG_
TOOL_PROXY": function() { return /* binding */ CONFIG_TOOL
_PROXY; }
/* harmony export */ "CONFIG_
PROXY": function() { return /* binding */ CONFIG
_PROXY; }
/* harmony export */ });
const OAUTH_PROXY = 'OAUTH_PROXY' // `http://${api}/HSRight/api/`
const TOOL_PROXY = 'TOOL_PROXY' // `http://${api}/Tool/api/`
...
...
@@ -21847,7 +21847,7 @@ const COMMON_PROXY = 'COMMON_PROXY' // `http://${api}/`
const GQL_PROXY = 'GQL_PROXY' // `http://${api}/GQL/api/`
const FILE_RESOURCE_PROXY = 'FILE_RESOURCE_PROXY' // `http://${api}/fileresource/api/`
const SERVICE_PROXY = 'SERVICE_PROXY' // `SERVICE_PROXY`
const CONFIG_
TOOL_PROXY = 'CONFIG_TOOL
_PROXY' // `新模式toolconfig`
const CONFIG_
PROXY = 'CONFIG
_PROXY' // `新模式toolconfig`
/***/ }),
...
...
@@ -22116,7 +22116,9 @@ class Control {
return db_name
}
getConfigDbNameApiProxy () {
return config_db_name ? _common_commonModule__WEBPACK_IMPORTED_MODULE_0__.CONFIG_TOOL_API : ''
const str = config_db_name ? _common_commonModule__WEBPACK_IMPORTED_MODULE_0__.CONFIG_API : ''
console.log(str)
return str
}
getInitDbConfigParam () {
return config_db_name
...
...
dist/hsWebHttpClient.min.js
View file @
36dc1d11
This source diff could not be displayed because it is too large. You can
view the blob
instead.
src/packages/common/commonModule.js
View file @
36dc1d11
import
{
TOOL_PROXY
,
GQL_PROXY
,
COMMON_UTIL_PROXY
,
SERVICE_PROXY
,
CONFIG_PROXY
}
from
'./commonProxy'
import
{
TOOL_PROXY
,
GQL_PROXY
,
COMMON_UTIL_PROXY
,
SERVICE_PROXY
,
CONFIG_PROXY
}
from
'./commonProxy'
export
const
WEB_QUERY
=
`
${
TOOL_PROXY
}
/web_query/`
export
const
WEB_QUERY_QUERY
=
`
${
TOOL_PROXY
}
/web_query/query/`
export
const
WEB_QUERY_QUERY_VALUE
=
`
${
TOOL_PROXY
}
/web_query/query_value/`
...
...
@@ -16,4 +22,19 @@ export const SEND_BILLS = `${COMMON_UTIL_PROXY}/send_bills/`
export
const
UN_SEND_BILLS
=
`
${
COMMON_UTIL_PROXY
}
/un_send_bills/`
export
const
REJECT_BILLS
=
`
${
COMMON_UTIL_PROXY
}
/reject_bills/`
export
const
CONFIG_API
=
`
${
CONFIG_PROXY
}
/`
export
function
getWEB_QUERY
(
isConfig
)
{
const
start
=
isConfig
?
CONFIG_PROXY
:
TOOL_PROXY
return
`
${
start
}
/web_query/`
}
export
function
getWEB_QUERY_QUERY
(
isConfig
)
{
const
start
=
isConfig
?
CONFIG_PROXY
:
TOOL_PROXY
return
`
${
start
}
/web_query/query/`
}
export
function
getWEB_QUERY_QUERY_VALUE
(
isConfig
){
const
start
=
isConfig
?
CONFIG_PROXY
:
TOOL_PROXY
return
`
${
start
}
/web_query/query_value/`
}
export
function
getWEB_QUERY_PAGE
(
isConfig
){
const
start
=
isConfig
?
CONFIG_PROXY
:
TOOL_PROXY
return
`
${
start
}
/web_chart_config/query_page/`
}
\ No newline at end of file
src/packages/modules/webChartConfig.js
View file @
36dc1d11
import
{
WEB_QUERY
,
WEB_QUERY_QUERY
,
WEB_QUERY_QUERY_VALUE
,
WEB_QUERY_PAGE
,
CONFIG_API
getWEB_QUERY
,
getWEB_QUERY_QUERY
,
getWEB_QUERY_QUERY_VALUE
,
getWEB_QUERY_PAGE
}
from
'../common/commonModule'
import
hsUtil
from
'hs-util-js'
const
urlParam
=
hsUtil
.
SystemModule
.
getUrlParams
()
...
...
@@ -81,7 +80,7 @@ class Control {
}
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY
,
getWEB_QUERY
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -118,7 +117,7 @@ class Control {
db_code
:
dbCode
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY_QUERY
,
getWEB_QUERY_QUERY
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -133,7 +132,7 @@ class Control {
db_code
:
dbCode
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY_QUERY_VALUE
,
getWEB_QUERY_QUERY_VALUE
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -191,7 +190,7 @@ class Control {
db_code
:
dbCode
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY_QUERY
,
getWEB_QUERY_QUERY
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -205,7 +204,7 @@ class Control {
db_code
:
dbCode
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY_QUERY
,
getWEB_QUERY_QUERY
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -219,7 +218,7 @@ class Control {
db_code
:
dbCode
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY
,
getWEB_QUERY
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -251,7 +250,7 @@ class Control {
config_type
:
configType
}
return
this
.
requestClient
.
post
(
this
.
getConfigDbNameApiProxy
()
||
WEB_QUERY_PAGE
,
getWEB_QUERY_PAGE
(
this
.
hasConfigDb
())
,
postData
,
this
.
getInitDbConfigParam
()
)
...
...
@@ -260,10 +259,8 @@ class Control {
const
db_name
=
config_db_name
||
this
.
requestClient
.
getDbName
()
return
db_name
}
getConfigDbNameApiProxy
()
{
const
str
=
config_db_name
?
CONFIG_API
:
''
console
.
log
(
str
)
return
str
hasConfigDb
(){
return
!!
config_db_name
}
getInitDbConfigParam
()
{
return
config_db_name
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment