Commit af9f585f authored by 郭铭瑶's avatar 郭铭瑶 🤘

源要素目标要素判断修改

parent ba70837e
......@@ -733,7 +733,7 @@ const rules = {
targetSubjectId: [
{
validator(_, value) {
return value !== subjectData.value.sourceSubjectId
return value && value !== subjectData.value.sourceSubjectId
},
trigger: ['blur', 'change'],
message: '目标要素不能与源要素相同',
......@@ -742,7 +742,7 @@ const rules = {
sourceSubjectId: [
{
validator(_, value) {
return value !== subjectData.value.targetSubjectId
return value && value !== subjectData.value.targetSubjectId
},
trigger: ['blur', 'change'],
message: '源要素不能与目标要素相同',
......
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