Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
smart-web-tabs
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
SVI
svi-templates
smart-web-tabs
Commits
6fd667ef
Commit
6fd667ef
authored
Apr 01, 2020
by
曾沂轮
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature-addAnounceAndStyleLogin' into 'master'
Feat: 添加公告功能并调整登陆授权 See merge request
!6
parents
182365ea
2c78b6c0
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
31 additions
and
28 deletions
+31
-28
config.js
template/config/config.js
+5
-11
package.json
template/package.json
+2
-2
config.js
template/src/api/config.js
+5
-11
businessConfig.js
template/src/plugins/routes/businessConfig.js
+1
-0
announce.vue
template/src/views/businessConfig/announce.vue
+16
-0
workflowDesign.vue
template/src/views/systemSetup/workflowDesign.vue
+2
-4
No files found.
template/config/config.js
View file @
6fd667ef
...
@@ -12,6 +12,7 @@ axios.defaults.retry = 1;
...
@@ -12,6 +12,7 @@ axios.defaults.retry = 1;
axios
.
defaults
.
retryDelay
=
1000
;
axios
.
defaults
.
retryDelay
=
1000
;
// 设置defaults.baseURL
// 设置defaults.baseURL
axios
.
defaults
.
baseURL
=
_config
.
baseUrl
;
axios
.
defaults
.
baseURL
=
_config
.
baseUrl
;
axios
.
defaults
.
headers
.
common
[
'auth-token'
]
=
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
)
||
''
;
// 请求超时拦截,重新请求
// 请求超时拦截,重新请求
axios
.
interceptors
.
response
.
use
(
function
(
response
)
{
axios
.
interceptors
.
response
.
use
(
function
(
response
)
{
...
@@ -24,17 +25,10 @@ axios.interceptors.response.use(function(response) {
...
@@ -24,17 +25,10 @@ axios.interceptors.response.use(function(response) {
message
:
'请求服务好像出错了,'
+
status
message
:
'请求服务好像出错了,'
+
status
});
});
return
Promise
.
reject
(
response
);
return
Promise
.
reject
(
response
);
}
/* else if (data.status === 2) {
}
else
if
(
response
.
data
.
data
&&
response
.
data
.
data
.
hasOwnProperty
(
'token'
))
{
Message({
window
.
localStorage
.
setItem
(
'south-samrtweb-token'
,
response
.
data
.
data
.
token
);
type: 'error',
axios
.
defaults
.
headers
.
common
[
'auth-token'
]
=
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
)
||
''
;
message: '请求服务后台处理出现了错误'
}
});
} else if (data.status === 1) {
Message({
type: 'warning',
message: '请求服务处理出现了异常,' + data.message
});
} */
return
Promise
.
resolve
(
response
);
return
Promise
.
resolve
(
response
);
},
function
axiosRetryInterceptor
(
err
)
{
},
function
axiosRetryInterceptor
(
err
)
{
...
...
template/package.json
View file @
6fd667ef
...
@@ -12,8 +12,8 @@
...
@@ -12,8 +12,8 @@
},
},
"dependencies"
:
{
"dependencies"
:
{
"core-js"
:
"^2.6.5"
,
"core-js"
:
"^2.6.5"
,
"smart-charts"
:
"^1.0.0
-alpha
"
,
"smart-charts"
:
"^1.0.0"
,
"smart-web"
:
"^2.
2.3
"
,
"smart-web"
:
"^2.
3.0
"
,
"vue"
:
"^2.6.10"
,
"vue"
:
"^2.6.10"
,
"vue-progressbar"
:
"^0.7.5"
,
"vue-progressbar"
:
"^0.7.5"
,
"vue-router"
:
"^3.1.3"
,
"vue-router"
:
"^3.1.3"
,
...
...
template/src/api/config.js
View file @
6fd667ef
...
@@ -12,6 +12,7 @@ axios.defaults.retry = 1;
...
@@ -12,6 +12,7 @@ axios.defaults.retry = 1;
axios
.
defaults
.
retryDelay
=
1000
;
axios
.
defaults
.
retryDelay
=
1000
;
// 设置defaults.baseURL
// 设置defaults.baseURL
axios
.
defaults
.
baseURL
=
_config
.
baseUrl
;
axios
.
defaults
.
baseURL
=
_config
.
baseUrl
;
axios
.
defaults
.
headers
.
common
[
'auth-token'
]
=
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
)
||
''
;
// 请求超时拦截,重新请求
// 请求超时拦截,重新请求
axios
.
interceptors
.
response
.
use
(
function
(
response
)
{
axios
.
interceptors
.
response
.
use
(
function
(
response
)
{
...
@@ -24,17 +25,10 @@ axios.interceptors.response.use(function(response) {
...
@@ -24,17 +25,10 @@ axios.interceptors.response.use(function(response) {
message
:
'请求服务好像出错了,'
+
status
message
:
'请求服务好像出错了,'
+
status
});
});
return
Promise
.
reject
(
response
);
return
Promise
.
reject
(
response
);
}
/* else if (data.status === 2) {
}
else
if
(
response
.
data
.
data
&&
response
.
data
.
data
.
hasOwnProperty
(
'token'
))
{
Message({
window
.
localStorage
.
setItem
(
'south-samrtweb-token'
,
response
.
data
.
data
.
token
);
type: 'error',
axios
.
defaults
.
headers
.
common
[
'auth-token'
]
=
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
)
||
''
;
message: '请求服务后台处理出现了错误'
}
});
} else if (data.status === 1) {
Message({
type: 'warning',
message: '请求服务处理出现了异常,' + data.message
});
} */
return
Promise
.
resolve
(
response
);
return
Promise
.
resolve
(
response
);
},
function
axiosRetryInterceptor
(
err
)
{
},
function
axiosRetryInterceptor
(
err
)
{
...
...
template/src/plugins/routes/businessConfig.js
View file @
6fd667ef
import
{
cb
}
from
'../extend'
;
import
{
cb
}
from
'../extend'
;
export
default
{
export
default
{
announce
:
()
=>
import
(
'@/views/businessConfig/announce'
).
then
(
cb
),
businessConfiguration
:
()
=>
import
(
'@/views/businessConfig/businessConfiguration'
).
then
(
cb
)
businessConfiguration
:
()
=>
import
(
'@/views/businessConfig/businessConfiguration'
).
then
(
cb
)
};
};
template/src/views/businessConfig/announce.vue
0 → 100644
View file @
6fd667ef
<
template
>
<sw-announce></sw-announce>
</
template
>
<
script
>
import
SwAnnounce
from
'smart-web/packages/announce'
;
import
'smart-web/packages/styles/src/announce.scss'
;
export
default
{
name
:
'announce'
,
components
:
{
SwAnnounce
}
};
</
script
>
template/src/views/systemSetup/workflowDesign.vue
View file @
6fd667ef
...
@@ -29,7 +29,7 @@ export default {
...
@@ -29,7 +29,7 @@ export default {
name
:
'新建流程'
,
name
:
'新建流程'
,
componentName
:
'appIframe'
componentName
:
'appIframe'
};
};
const
url
=
baseUrl
+
'/modeler.html?modelId='
+
modelId
;
const
url
=
baseUrl
+
'/modeler.html?modelId='
+
modelId
+
'&token='
+
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
)
;
openTab
(
data
,
{
url
:
url
});
openTab
(
data
,
{
url
:
url
});
},
},
...
@@ -39,9 +39,7 @@ export default {
...
@@ -39,9 +39,7 @@ export default {
name
:
'编辑流程'
,
name
:
'编辑流程'
,
componentName
:
'editProcess'
componentName
:
'editProcess'
};
};
const
url
=
baseUrl
+
'/modeler.html?modelId='
+
modelId
;
const
url
=
baseUrl
+
'/modeler.html?modelId='
+
modelId
+
'&token='
+
window
.
localStorage
.
getItem
(
'south-samrtweb-token'
);
// let url = process.env.NODE_ENV === 'development' ? serviceUrl + '/smartweb2' : '.'
// url += '/workflow-designer/index.html?modelId=' + this.currentNode.id
openTab
(
data
,
{
url
:
url
,
reload
:
true
});
openTab
(
data
,
{
url
:
url
,
reload
:
true
});
},
},
}
}
...
...
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