chao 1 month ago
parent
commit
727f530730
3 changed files with 11 additions and 5 deletions
  1. 2 1
      .gitignore
  2. 8 2
      public/index.html
  3. 1 2
      routes/router.js

+ 2 - 1
.gitignore

@@ -1 +1,2 @@
-node_modules/ 
+node_modules/ 
+getEmail.py

+ 8 - 2
public/index.html

@@ -1246,10 +1246,16 @@
                 e.target.value = ''; // 清空已选择的文件
                 return;
             }
-            if (uploadFileUrl1 == "" || uploadFileUrl1 == "") {
-                alert('请上传报名文件和视频');
+            if (uploadFileUrl1 == "") {
+                alert('请上传报名文件');
                 return;
             }
+            if(selectedCompetitionId == 2){
+                if (uploadFileUrl1 == "") {
+                    alert('请上传智能体视频');
+                    return;
+                }
+            }
             if (!confirm('如已上传过文件,本次上传会覆盖之前上传,是否确定提交吗?')) {
                 return;
             }

+ 1 - 2
routes/router.js

@@ -13,7 +13,7 @@ router.route('/user').post(async function (req, res) {
     const uuid = crypto.randomUUID();
 
     let userData = JSON.parse(reqData.user);
-    await mysql.usselect([_mysqluser[0], _mysqluser[1], "select_registration_user", reqData.idCard], function (r) {
+    await mysql.usselect([_mysqluser[0], _mysqluser[1], "select_registration_user", reqData.idCard,reqData.type], function (r) {
         if (r[0] && r[0][0] && r[0][0]['count(id)'] != 0) {
             res.send({ status: 'error', message: '选手报名失败,选手身份证号已存在' });
         } else {
@@ -79,7 +79,6 @@ router.route('/exportData').get(async function (req, res) {
                     user_group = item.user_group == 1?"小学低龄":item.user_group == 2?"小学高龄":item.user_group == 3?"中学":"高校"
                 }else{
                     user_group = item.user_group == 1?"小学组(4-6年级)":item.user_group == 2?"初中组(7-9年级)":item.user_group == 3?"高中组(10-12年级,含中职)":"高校组(含高职)"
-
                 }
                 return {
                     小组id: item.user_groupid,