refactor(接口定义): 优化获取当前用户名称的方法
This commit is contained in:
parent
b04b7703b8
commit
17dc11a340
|
@ -281,7 +281,6 @@ import { TYPE_TO_C } from '@/business/automation/scenario/Setting';
|
||||||
import ApiCaseHeader from './ApiCaseHeader';
|
import ApiCaseHeader from './ApiCaseHeader';
|
||||||
import { deepClone } from 'metersphere-frontend/src/utils/tableUtils';
|
import { deepClone } from 'metersphere-frontend/src/utils/tableUtils';
|
||||||
import { useApiStore } from '@/store';
|
import { useApiStore } from '@/store';
|
||||||
import {TokenKey} from "metersphere-frontend/src/utils/constants";
|
|
||||||
|
|
||||||
const store = useApiStore();
|
const store = useApiStore();
|
||||||
export default {
|
export default {
|
||||||
|
@ -701,8 +700,7 @@ export default {
|
||||||
row.createTime = data.createTime;
|
row.createTime = data.createTime;
|
||||||
row.updateTime = data.updateTime;
|
row.updateTime = data.updateTime;
|
||||||
this.compare = [];
|
this.compare = [];
|
||||||
let user = JSON.parse(localStorage.getItem(TokenKey));
|
row.updateUser = getCurrentUser().name;
|
||||||
row.updateUser = user.name;
|
|
||||||
row.type = null;
|
row.type = null;
|
||||||
this.$success(this.$t('commons.save_success'));
|
this.$success(this.$t('commons.save_success'));
|
||||||
this.tagCount = 0;
|
this.tagCount = 0;
|
||||||
|
|
Loading…
Reference in New Issue