forked from mt-fe-group/mt-yd-ui
update 对dialog进行改版之前
This commit is contained in:
@@ -91,9 +91,9 @@ export default {
|
||||
})
|
||||
.then(() => {
|
||||
this.$http
|
||||
.post(this.$http.adornUrl('/doLogout'))
|
||||
.post(this.$http.adornUrl('/logout'))
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 200) {
|
||||
if (res.code !== 0) {
|
||||
return this.$message.error(res.msg)
|
||||
}
|
||||
clearLoginInfo()
|
||||
|
||||
@@ -104,6 +104,8 @@ const addOrUpdateConfigs = {
|
||||
},
|
||||
{
|
||||
name: 'processTime',
|
||||
label: '加工时间',
|
||||
placeholder: '请输入加工时间',
|
||||
type: 'number', // type: number(input+number) | default(input) | textarea | select(options在父组件里获取) | datetime
|
||||
required: true,
|
||||
rules: [
|
||||
@@ -120,6 +122,10 @@ const addOrUpdateConfigs = {
|
||||
'specifications',
|
||||
{
|
||||
name: 'typeDictValue',
|
||||
// rules: [
|
||||
// {required: true, trigger: 'blur'}
|
||||
// ],
|
||||
label: '产品类型', // 对于非常见属性,最好自己指定label
|
||||
type: 'select',
|
||||
options: [
|
||||
// 动态获取
|
||||
@@ -129,6 +135,7 @@ const addOrUpdateConfigs = {
|
||||
},
|
||||
{
|
||||
name: 'unitDictValue',
|
||||
label: '单位',
|
||||
type: 'select',
|
||||
options: [
|
||||
// 动态获取
|
||||
|
||||
@@ -101,14 +101,20 @@ export default {
|
||||
this.$http
|
||||
.post(this.$http.adornUrl('/login'), this.dataForm)
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 200) {
|
||||
if (res.code !== 0) {
|
||||
// this.getCaptcha()
|
||||
return this.$message.error(res.msg)
|
||||
}
|
||||
Cookies.set('token', res.data.token)
|
||||
this.$router.replace({ name: 'home' })
|
||||
})
|
||||
.catch(() => {})
|
||||
.catch((err) => {
|
||||
this.$message({
|
||||
message: err.message,
|
||||
type: 'error',
|
||||
duration: 2000
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
1000,
|
||||
|
||||
Reference in New Issue
Block a user