Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx-web
/
glsx-oss-configuration
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 78621d71
authored
Jul 15, 2024
by
王志慧
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改配置文件
1 parent
d030e1ee
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
7 deletions
package-lock.json
package.json
src/base.js
package-lock.json
View file @
78621d7
This diff is collapsed.
Click to expand it.
package.json
View file @
78621d7
...
@@ -12,6 +12,7 @@
...
@@ -12,6 +12,7 @@
"dependencies"
:
{
"dependencies"
:
{
"axios"
:
"^0.18.0"
,
"axios"
:
"^0.18.0"
,
"element-ui"
:
"^2.15.1"
,
"element-ui"
:
"^2.15.1"
,
"glsx-common"
:
"^2.10.1"
,
"glsx-table"
:
"^1.0.3"
,
"glsx-table"
:
"^1.0.3"
,
"glsx-vue-common"
:
"^2.0.5"
,
"glsx-vue-common"
:
"^2.0.5"
,
"lodash"
:
"^4.17.10"
,
"lodash"
:
"^4.17.10"
,
...
...
src/base.js
View file @
78621d7
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
import
Vue
from
'vue'
import
Vue
from
'vue'
import
ElementUI
from
'element-ui'
import
ElementUI
from
'element-ui'
import
glsxTable
from
'glsx-table'
import
glsxTable
from
'glsx-table'
import
{
Http
,
utils
}
from
'glsx-common'
import
'element-ui/lib/theme-chalk/index.css'
import
'element-ui/lib/theme-chalk/index.css'
// import GlsxVueComponents from 'glsx-vue-components'
// import GlsxVueComponents from 'glsx-vue-components'
// import 'glsx-vue-components/dist/glsx-vue-components.css'
// import 'glsx-vue-components/dist/glsx-vue-components.css'
...
@@ -79,17 +80,31 @@ var mixin = {
...
@@ -79,17 +80,31 @@ var mixin = {
}
}
}
}
const
URL
=
'http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
const
URL
=
'http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
const
getConfig
=
(
url
=
URL
+
'/switch-config'
)
=>
{
const
getConfig
=
()
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
// return new Promise((resolve, reject) => {
request
({
url
}).
then
(
res
=>
{
// request({ url }).then(res => {
if
(
res
.
status
===
'success'
)
{
// if (res.status === 'success') {
resolve
({
'vue'
:
Vue
,
'config'
:
JSON
.
parse
(
res
.
data
)
})
// resolve({ 'vue': Vue, 'config': JSON.parse(res.data) })
}
else
{
// } else {
reject
(
'ERROR.'
)
// reject('ERROR.')
// }
// })
// })
let
params
=
{
moduleName
:
'glsx-oss-configuration'
,
mockUrl
:
'http://192.168.3.171:7300/mock/5be17454f31545347559d499/config'
,
httpOptions
:
{
Headers
:
{
refererurl
:
location
.
href
},
request
:
{
timeout
:
30000
}
}
}
}
return
new
Promise
((
resolve
,
reject
)
=>
{
utils
.
getConfig
(
params
).
then
(
res
=>
{
resolve
({
vue
:
Vue
,
config
:
res
})
})
})
})
})
}
}
/* eslint-disable no-new */
/* eslint-disable no-new */
const
render
=
App
=>
{
const
render
=
App
=>
{
window
.
vm
=
new
Vue
({
window
.
vm
=
new
Vue
({
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment