Commit 5edb945f by 潘际乾

任务列表的查询检验清除

parent a313c613
......@@ -398,6 +398,7 @@ export default {
type: 'success'
});
}
this.$refs.paramsForm.clearValidate();
Utils.positioningErrorMsg(res.fieldErrors, this.$refs.paramsForm.fields)
},
......
import Utils from "~/utils";
const state = {
operateFuns: {},
};
......@@ -18,7 +20,7 @@ const actions = {
setOperateFuns({ commit }, funs) {
return new Promise(resolve => {
// const id = Symbol("transaction-id");
const id = new Date().valueOf();
const id = Utils.generateUUID();
commit('ADD_OPERATE_FUN', { id, funs })
resolve(id)
});
......
......@@ -231,4 +231,18 @@ export default class Utils {
}
}
}
static generateUUID() {
var d = new Date().getTime();
if (window.performance && typeof window.performance.now === "function") {
d += performance.now(); //use high-precision timer if available
}
var uuid = 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
var r = (d + Math.random() * 16) % 16 | 0;
d = Math.floor(d / 16);
return (c == 'x' ? r : (r & 0x3 | 0x8)).toString(16);
});
return uuid;
}
}
\ No newline at end of file
......@@ -401,7 +401,7 @@
fixed="right"
prop="display"
label="操作"
width="150px"
width="auto"
>
<template slot="header">
<c-col :span="11" style="text-align:left"><span>操作</span></c-col>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment