Преглед на файлове

fix: 😀修复模板内容为空时无法打卡新增对话框的bug

喵你个旺呀 преди 1 година
родител
ревизия
a694ac7603
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      Web/src/views/system/template/component/editTemplate.vue

+ 1 - 1
Web/src/views/system/template/component/editTemplate.vue

@@ -174,7 +174,7 @@ const submit = () => {
 watch(
 		() => state.ruleForm.content,
 		() => {
-			state.ruleForm.content.match(/@\((.*?)\)/g)?.forEach((pa: string, index) => {
+			state.ruleForm.content?.match(/@\((.*?)\)/g)?.forEach((pa: string, index) => {
 				const key = pa.substring(2, pa.length - 1);
 				if (!state.renderData.find((e: [string, string]) => e[0] === key)) {
 					state.renderData.push([key, '参数' + (index + 1)]);