Commit 95899c19 by 前端

Merge branch 'SAAS+V4.45' into 'master'

上线合并

See merge request !1
2 parents 6bfe146c 05335095
......@@ -15,6 +15,7 @@
"file-saver": "^2.0.5",
"glsx-vue-common": "^1.2.1",
"glsx-vue-components": "^1.0.13",
"glsx-common": "^2.10.1",
"moment": "^2.29.1",
"sass-loader": "^7.1.0",
"vue": "^2.5.17",
......
......@@ -7,11 +7,13 @@ import '@/styles/index.scss'
import { Request as request } from 'glsx-vue-common'
import moment from 'moment'
import XLSX from 'xlsx'
import { utils } from 'glsx-common'
// import axios from 'axios'
Vue.use(GlsxVueComponents)
Vue.use(XLSX)
// Vue.prototype.getAddrUrl = 'https://dj.test.glsx.com.cn/web-dj-site/common/address/getAddressByLngLat'
Vue.prototype.getAddrUrl = 'http://dj.glsx.com.cn/web-dj-site/common/address/getAddressByLngLat'
Vue.prototype.getAddrUrl =
'http://dj.glsx.com.cn/web-dj-site/common/address/getAddressByLngLat'
Vue.prototype.size = 'mini'
Vue.prototype.$moment = moment
moment.locale('zh-cn')
......@@ -38,15 +40,31 @@ var mixin = {
})
}
}
const URL = 'https://oss-config.test.glsx.com.cn/mock/5be17454f31545347559d499/config'
const getConfig = (url = URL + '/insurance') => {
// const URL = 'https://oss-config.test.glsx.com.cn/mock/5be17454f31545347559d499/config'
// const getConfig = (url = URL + '/insurance') => {
// return new Promise((resolve, reject) => {
// request({ url }).then(res => {
// if (res.status === 'success') {
// resolve({ 'vue': Vue, 'config': JSON.parse(res.data) })
// } else {
// reject('ERROR.')
// }
// })
// })
// }
const getConfig = () => {
let params = {
moduleName: 'glsx-oss-insurance',
mockUrl:
'https://oss-config.test.glsx.com.cn/mock/5be17454f31545347559d499/config/insurance',
httpOptions: {
Headers: { refererurl: location.href },
request: { timeout: 30000 }
}
}
return new Promise((resolve, reject) => {
request({ url }).then(res => {
if (res.status === 'success') {
resolve({ 'vue': Vue, 'config': JSON.parse(res.data) })
} else {
reject('ERROR.')
}
utils.getConfig(params).then(res => {
resolve({ vue: Vue, config: res })
})
})
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!