File tree Expand file tree Collapse file tree 3 files changed +6
-0
lines changed
views/system/professional Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change 66 "AI Model Configuration" : " AI Model Configuration"
77 },
88 "professional" : {
9+ "cannot_be_repeated" : " Term name, synonyms cannot be repeated" ,
910 "code_for_debugging" : " Copy the following code for debugging" ,
1011 "full_screen_mode" : " Full screen mode" ,
1112 "editing_terminology" : " Editing Terminology" ,
Original file line number Diff line number Diff line change 66 "AI Model Configuration" : " 模型配置"
77 },
88 "professional" : {
9+ "cannot_be_repeated" : " 术语名称,同义词不能重复" ,
910 "code_for_debugging" : " 复制以下代码进行调试" ,
1011 "full_screen_mode" : " 全屏模式" ,
1112 "editing_terminology" : " 编辑术语" ,
Original file line number Diff line number Diff line change @@ -222,6 +222,10 @@ const rules = {
222222const saveHandler = () => {
223223 termFormRef .value .validate ((res : any ) => {
224224 if (res ) {
225+ const arr = [... pageForm .value .other_words .filter ((ele ) => !! ele ), pageForm .value .word ]
226+ if (arr .length !== new Set (arr ).size ) {
227+ return ElMessage .error (t (' professional.cannot_be_repeated' ))
228+ }
225229 const obj = unref (pageForm )
226230 if (! obj .id ) {
227231 delete obj .id
You can’t perform that action at this time.
0 commit comments