zhanghua
2024-12-20 320e75460d2f5e517c902b87fcc5c4d220472f6f
学生导入优化
3个文件已修改
434 ■■■■ 已修改文件
src/App.vue 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/student/components/upload-student.vue 427 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
vue.config.js 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/App.vue
@@ -19,8 +19,9 @@
    },
    created() {
        // localStorage.setItem("user", '{"id":25,"name":"微信用户","mobile":"18080857109","gender":"FEMALE","jwtToken":"eyJhbGciOiJIUzI1NiJ9.eyJleHBUaW1lIjoiMjAyNC8xMS8xOCAyMDo0MSIsInVzZXJJZCI6NDYsImp0aSI6ImM2MzE2NDJmLTQ1YzUtNDdhOC04MmRhLWQyMGMwNjg5NDRmOSIsImlhdCI6MTczMTkyNjQ3Miwic3ViIjoieWNsIiwiZXhwIjoxNzMxOTMzNjcyfQ.14nH_pdr4Nfd6Xq0StQ3sMHQz6cqLMEXEHhrSw5iHM4","avatars":[],"staffs":[{"id":1659,"createTime":"2023/11/16 09:58","createById":1,"modifyTime":"2023/11/16 09:58","modifyById":46,"name":"张华","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":25,"createTime":"2023/06/06 19:47","createById":0,"modifyTime":"2024/05/22 00:02","modifyById":1,"name":"叮当云服务","description":"","address":"成都市","addressDetail":"123","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"PLATFORM","companyName":"88","region":[],"logos":[{"url1":"dream/1/setting/20240320/2a7d900fc72878a774d3cd6aea2195e0.jpg","url2":"dream/1/setting/20240320/9ccea81dbfdcb8e4d0c86b978aca0e42.jpg","url3":"dream/1/setting/20240320/a78b9307b000b3ec4d6ecc9d276494ee.jpg","origin":"dream/1/setting/20240320/71fad2f4bcae8fc644dca5d95b98c08c.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20240403/f87b937eedaf8842c59bbdcecf60d94e.jpg","url2":"dream/1/setting/20240403/172dc3868484f8b88ad26e54bb51d737.jpg","url3":"dream/1/setting/20240403/b1ddd7a6a8433e6ebace1d5360e426a1.jpg","origin":"dream/1/setting/20240403/15ba95a920efb1353226863f2ba26b53.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13981970816","tel2":"","openTime":"10:00:00","closeTime":"20:00:00","mch":{"id":1,"name":"优创力直营店"}},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":427,"createTime":"2023/10/04 13:18","createById":22,"modifyTime":"2023/10/04 13:18","modifyById":22,"name":"管理员","description":"校长,管理员,助理","orgId":1,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1616,"createTime":"2023/11/04 11:23","createById":0,"modifyTime":"2023/12/08 14:10","modifyById":35,"name":"叮当上课-技术","description":"","mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":186,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2024/09/11 15:16","modifyById":35,"name":"拓世体育","description":"","address":"四川省成都市锦江区琉三路999号","addressDetail":"成都市锦江区水井坊锦江体育公园","lng":104.11273956298828,"lat":30.597631454467773,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"拓世体育","region":[],"logos":[{"url1":"dream/1/setting/20240911/35c21c25bdabe256e6d80a04443130bd.jpg","url2":"dream/1/setting/20240911/d147a21d1a515b8f1130f48131fb0fd0.jpg","url3":"dream/1/setting/20240911/4b377e21b8a24c326537b7033b3c5368.jpg","origin":"dream/1/setting/20240911/0fa9c2150e361d00a4c605477f355b72.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20231228//1fd0a04396e38f97154518976d2b9fcf.jpg","url2":"dream/1/setting/20231228//a8820bfd6b5b68430930308b138d07b8.jpg","url3":"dream/1/setting/20231228//4362c82baef5dd9114cc612275c5ef8b.jpg","origin":"dream/1/setting/20231228//19a648306dd555f044ae1321519d9765.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13880121131","tel2":"","openTime":"07:00:00","closeTime":"22:00:00","mch":{"id":81,"name":"拓世体育"}},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":886,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2023/11/04 11:22","modifyById":0,"name":"课程顾问","description":"销售顾问","orgId":186,"sys":1,"roleGroup":"org","roleName":"salesman","state":"USED"},"state":"USED"},{"id":1621,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":187,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"惠海琴行","description":null,"address":"龙泉驿区","addressDetail":"成都市龙泉驿区怡和新城F4区双龙路388号24栋附106、107号","lng":104.262856,"lat":30.572496,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"KS","region":[],"logos":[],"galleries":[],"tel1":"18884828287","tel2":"","openTime":"09:00:00","closeTime":"21:30:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":890,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":187,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1647,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":190,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"莱斯普乐艺术","description":null,"address":"锦江区锦丽路187号1楼","addressDetail":"","lng":104.09539,"lat":30.615751,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"莱斯普乐艺术培训学校","region":[],"logos":[],"galleries":[],"tel1":"15196265492","tel2":"","openTime":"09:00:00","closeTime":"21:00:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":905,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":190,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":2150,"createTime":"2024/09/13 19:15","createById":35,"modifyTime":"2024/10/15 09:15","modifyById":35,"name":"华老师","description":"","mobile":"","gender":"MALE","birthday":"2004/09/13","avatars":[],"org":{"id":192,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/10/25 09:32","modifyById":35,"name":"格斗馆","description":"","address":"四川省成都市锦江区中纱帽街8号","addressDetail":"商鼎国际2-1","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"巨石","region":[],"logos":[{"url1":"dream/1/setting/20240320/0e6dbe1029f347fd89eb5c99f287eaee.png","url2":"dream/1/setting/20240320/d1fca9110425cc02150b7c3f54298fbd.png","url3":"dream/1/setting/20240320/cdfd92ee8fd3da597be2144cd82f8788.png","origin":"dream/1/setting/20240320/86c0f4f1dfde36b0a9ea2b545ebc79c7.png","def":null,"ext":"png","duration":null}],"galleries":[{"url1":"dream/1/setting/20240809/d2b570eb5fc51f9e0a07106b96a0552c.jpg","url2":"dream/1/setting/20240809/4cfd9736bf2bc207cc50735f183fe6d7.jpg","url3":"dream/1/setting/20240809/8545384e4c2b8ccd0cba03833156884d.jpg","origin":"dream/1/setting/20240809/735f4daf8efc136ff4ab83d80dc9a79c.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"15002830891","tel2":null,"openTime":"08:00:00","closeTime":"21:00:00","mch":null},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":912,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/03/31 19:35","modifyById":1,"name":"教师","description":"教师","orgId":192,"sys":1,"roleGroup":"org","roleName":"staff","state":"USED"},"state":"USED"},{"id":1658,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:59","modifyById":46,"name":"张老师","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":193,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"测试机构1","description":null,"address":null,"addressDetail":null,"lng":null,"lat":null,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"测试机构1","region":[],"logos":[],"galleries":[],"tel1":null,"tel2":null,"openTime":"10:00:00","closeTime":"21:00:00","mch":null},"title":"管理员","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":920,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"管理员","description":"校长,管理员,助理","orgId":193,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"}],"sessionKey":null,"players":[{"id":3366,"name":"牛小二","orgId":193,"orgName":"测试机构1","mobile":"136780078","mgr":true,"state":"USED"},{"id":3372,"name":"张华","orgId":192,"orgName":"格斗馆","mobile":"","mgr":true,"state":"USED"}],"wxOpenid":"o4UBK6jiXYDPyeL3k54VI_3aNxN0","wxUnionid":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenid":"oApStw7I11L8uo1HoTWK4MUTBzkY"}');
        // localStorage.setItem("staffs", '[{"id":1636,"createTime":"2023/11/16 09:58","createById":1,"modifyTime":"2023/11/16 09:58","modifyById":46,"name":"张华","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":25,"createTime":"2023/06/06 19:47","createById":0,"modifyTime":"2024/05/22 00:02","modifyById":1,"name":"叮当云服务","description":"","address":"成都市","addressDetail":"123","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"PLATFORM","companyName":"88","region":[],"logos":[{"url1":"dream/1/setting/20240320/2a7d900fc72878a774d3cd6aea2195e0.jpg","url2":"dream/1/setting/20240320/9ccea81dbfdcb8e4d0c86b978aca0e42.jpg","url3":"dream/1/setting/20240320/a78b9307b000b3ec4d6ecc9d276494ee.jpg","origin":"dream/1/setting/20240320/71fad2f4bcae8fc644dca5d95b98c08c.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20240403/f87b937eedaf8842c59bbdcecf60d94e.jpg","url2":"dream/1/setting/20240403/172dc3868484f8b88ad26e54bb51d737.jpg","url3":"dream/1/setting/20240403/b1ddd7a6a8433e6ebace1d5360e426a1.jpg","origin":"dream/1/setting/20240403/15ba95a920efb1353226863f2ba26b53.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13981970816","tel2":"","openTime":"10:00:00","closeTime":"20:00:00","mch":{"id":1,"name":"优创力直营店"}},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":427,"createTime":"2023/10/04 13:18","createById":22,"modifyTime":"2023/10/04 13:18","modifyById":22,"name":"管理员","description":"校长,管理员,助理","orgId":1,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1616,"createTime":"2023/11/04 11:23","createById":0,"modifyTime":"2023/12/08 14:10","modifyById":35,"name":"叮当上课-技术","description":"","mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":186,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2024/09/11 15:16","modifyById":35,"name":"拓世体育","description":"","address":"四川省成都市锦江区琉三路999号","addressDetail":"成都市锦江区水井坊锦江体育公园","lng":104.11273956298828,"lat":30.597631454467773,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"拓世体育","region":[],"logos":[{"url1":"dream/1/setting/20240911/35c21c25bdabe256e6d80a04443130bd.jpg","url2":"dream/1/setting/20240911/d147a21d1a515b8f1130f48131fb0fd0.jpg","url3":"dream/1/setting/20240911/4b377e21b8a24c326537b7033b3c5368.jpg","origin":"dream/1/setting/20240911/0fa9c2150e361d00a4c605477f355b72.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20231228//1fd0a04396e38f97154518976d2b9fcf.jpg","url2":"dream/1/setting/20231228//a8820bfd6b5b68430930308b138d07b8.jpg","url3":"dream/1/setting/20231228//4362c82baef5dd9114cc612275c5ef8b.jpg","origin":"dream/1/setting/20231228//19a648306dd555f044ae1321519d9765.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13880121131","tel2":"","openTime":"07:00:00","closeTime":"22:00:00","mch":{"id":81,"name":"拓世体育"}},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":886,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2023/11/04 11:22","modifyById":0,"name":"课程顾问","description":"销售顾问","orgId":186,"sys":1,"roleGroup":"org","roleName":"salesman","state":"USED"},"state":"USED"},{"id":1621,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":187,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"惠海琴行","description":null,"address":"龙泉驿区","addressDetail":"成都市龙泉驿区怡和新城F4区双龙路388号24栋附106、107号","lng":104.262856,"lat":30.572496,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"KS","region":[],"logos":[],"galleries":[],"tel1":"18884828287","tel2":"","openTime":"09:00:00","closeTime":"21:30:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":890,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":187,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1647,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":190,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"莱斯普乐艺术","description":null,"address":"锦江区锦丽路187号1楼","addressDetail":"","lng":104.09539,"lat":30.615751,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"莱斯普乐艺术培训学校","region":[],"logos":[],"galleries":[],"tel1":"15196265492","tel2":"","openTime":"09:00:00","closeTime":"21:00:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":905,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":190,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":2150,"createTime":"2024/09/13 19:15","createById":35,"modifyTime":"2024/10/15 09:15","modifyById":35,"name":"华老师","description":"","mobile":"","gender":"MALE","birthday":"2004/09/13","avatars":[],"org":{"id":192,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/10/25 09:32","modifyById":35,"name":"格斗馆","description":"","address":"四川省成都市锦江区中纱帽街8号","addressDetail":"商鼎国际2-1","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"巨石","region":[],"logos":[{"url1":"dream/1/setting/20240320/0e6dbe1029f347fd89eb5c99f287eaee.png","url2":"dream/1/setting/20240320/d1fca9110425cc02150b7c3f54298fbd.png","url3":"dream/1/setting/20240320/cdfd92ee8fd3da597be2144cd82f8788.png","origin":"dream/1/setting/20240320/86c0f4f1dfde36b0a9ea2b545ebc79c7.png","def":null,"ext":"png","duration":null}],"galleries":[{"url1":"dream/1/setting/20240809/d2b570eb5fc51f9e0a07106b96a0552c.jpg","url2":"dream/1/setting/20240809/4cfd9736bf2bc207cc50735f183fe6d7.jpg","url3":"dream/1/setting/20240809/8545384e4c2b8ccd0cba03833156884d.jpg","origin":"dream/1/setting/20240809/735f4daf8efc136ff4ab83d80dc9a79c.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"15002830891","tel2":null,"openTime":"08:00:00","closeTime":"21:00:00","mch":null},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":912,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/03/31 19:35","modifyById":1,"name":"教师","description":"教师","orgId":192,"sys":1,"roleGroup":"org","roleName":"staff","state":"USED"},"state":"USED"},{"id":1658,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:59","modifyById":46,"name":"张老师","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":193,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"测试机构1","description":null,"address":null,"addressDetail":null,"lng":null,"lat":null,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"测试机构1","region":[],"logos":[],"galleries":[],"tel1":null,"tel2":null,"openTime":"10:00:00","closeTime":"21:00:00","mch":null},"title":"管理员","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":920,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"管理员","description":"校长,管理员,助理","orgId":193,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"}]');
        // localStorage.setItem("selectStaff", '{"id":1636,"createTime":"2023/11/16 09:58","createById":1,"modifyTime":"2023/11/16 09:58","modifyById":46,"name":"张华","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":25,"createTime":"2023/06/06 19:47","createById":0,"modifyTime":"2024/05/22 00:02","modifyById":1,"name":"叮当云服务","description":"","address":"成都市","addressDetail":"123","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"PLATFORM","companyName":"88","region":[],"logos":[{"url1":"dream/1/setting/20240320/2a7d900fc72878a774d3cd6aea2195e0.jpg","url2":"dream/1/setting/20240320/9ccea81dbfdcb8e4d0c86b978aca0e42.jpg","url3":"dream/1/setting/20240320/a78b9307b000b3ec4d6ecc9d276494ee.jpg","origin":"dream/1/setting/20240320/71fad2f4bcae8fc644dca5d95b98c08c.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20240403/f87b937eedaf8842c59bbdcecf60d94e.jpg","url2":"dream/1/setting/20240403/172dc3868484f8b88ad26e54bb51d737.jpg","url3":"dream/1/setting/20240403/b1ddd7a6a8433e6ebace1d5360e426a1.jpg","origin":"dream/1/setting/20240403/15ba95a920efb1353226863f2ba26b53.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13981970816","tel2":"","openTime":"10:00:00","closeTime":"20:00:00","mch":{"id":1,"name":"优创力直营店"}},"title":null,"user":{"id":25,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":427,"createTime":"2023/10/04 13:18","createById":22,"modifyTime":"2023/10/04 13:18","modifyById":22,"name":"管理员","description":"校长,管理员,助理","orgId":1,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"}');
        // localStorage.setItem("staffs", '[{"id":2569,"createTime":"2023/11/16 09:58","createById":1,"modifyTime":"2023/11/16 09:58","modifyById":46,"name":"张华","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":306,"createTime":"2023/06/06 19:47","createById":0,"modifyTime":"2024/05/22 00:02","modifyById":1,"name":"叮当云服务","description":"","address":"成都市","addressDetail":"123","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"PLATFORM","companyName":"88","region":[],"logos":[{"url1":"dream/1/setting/20240320/2a7d900fc72878a774d3cd6aea2195e0.jpg","url2":"dream/1/setting/20240320/9ccea81dbfdcb8e4d0c86b978aca0e42.jpg","url3":"dream/1/setting/20240320/a78b9307b000b3ec4d6ecc9d276494ee.jpg","origin":"dream/1/setting/20240320/71fad2f4bcae8fc644dca5d95b98c08c.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20240403/f87b937eedaf8842c59bbdcecf60d94e.jpg","url2":"dream/1/setting/20240403/172dc3868484f8b88ad26e54bb51d737.jpg","url3":"dream/1/setting/20240403/b1ddd7a6a8433e6ebace1d5360e426a1.jpg","origin":"dream/1/setting/20240403/15ba95a920efb1353226863f2ba26b53.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13981970816","tel2":"","openTime":"10:00:00","closeTime":"20:00:00","mch":{"id":1,"name":"优创力直营店"}},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":427,"createTime":"2023/10/04 13:18","createById":22,"modifyTime":"2023/10/04 13:18","modifyById":22,"name":"管理员","description":"校长,管理员,助理","orgId":1,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1616,"createTime":"2023/11/04 11:23","createById":0,"modifyTime":"2023/12/08 14:10","modifyById":35,"name":"叮当上课-技术","description":"","mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":186,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2024/09/11 15:16","modifyById":35,"name":"拓世体育","description":"","address":"四川省成都市锦江区琉三路999号","addressDetail":"成都市锦江区水井坊锦江体育公园","lng":104.11273956298828,"lat":30.597631454467773,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"拓世体育","region":[],"logos":[{"url1":"dream/1/setting/20240911/35c21c25bdabe256e6d80a04443130bd.jpg","url2":"dream/1/setting/20240911/d147a21d1a515b8f1130f48131fb0fd0.jpg","url3":"dream/1/setting/20240911/4b377e21b8a24c326537b7033b3c5368.jpg","origin":"dream/1/setting/20240911/0fa9c2150e361d00a4c605477f355b72.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20231228//1fd0a04396e38f97154518976d2b9fcf.jpg","url2":"dream/1/setting/20231228//a8820bfd6b5b68430930308b138d07b8.jpg","url3":"dream/1/setting/20231228//4362c82baef5dd9114cc612275c5ef8b.jpg","origin":"dream/1/setting/20231228//19a648306dd555f044ae1321519d9765.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13880121131","tel2":"","openTime":"07:00:00","closeTime":"22:00:00","mch":{"id":81,"name":"拓世体育"}},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":886,"createTime":"2023/11/04 11:22","createById":0,"modifyTime":"2023/11/04 11:22","modifyById":0,"name":"课程顾问","description":"销售顾问","orgId":186,"sys":1,"roleGroup":"org","roleName":"salesman","state":"USED"},"state":"USED"},{"id":1621,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":187,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"惠海琴行","description":null,"address":"龙泉驿区","addressDetail":"成都市龙泉驿区怡和新城F4区双龙路388号24栋附106、107号","lng":104.262856,"lat":30.572496,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"KS","region":[],"logos":[],"galleries":[],"tel1":"18884828287","tel2":"","openTime":"09:00:00","closeTime":"21:30:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":890,"createTime":"2023/11/04 11:43","createById":0,"modifyTime":"2023/11/04 11:43","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":187,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":1647,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"叮当技术支持","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":"1998/11/04","avatars":[],"org":{"id":190,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"莱斯普乐艺术","description":null,"address":"锦江区锦丽路187号1楼","addressDetail":"","lng":104.09539,"lat":30.615751,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"莱斯普乐艺术培训学校","region":[],"logos":[],"galleries":[],"tel1":"15196265492","tel2":"","openTime":"09:00:00","closeTime":"21:00:00","mch":null},"title":"老师","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":905,"createTime":"2023/11/04 13:09","createById":0,"modifyTime":"2023/11/04 13:09","modifyById":0,"name":"管理员","description":"校长,管理员,助理","orgId":190,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"},{"id":2150,"createTime":"2024/09/13 19:15","createById":35,"modifyTime":"2024/10/15 09:15","modifyById":35,"name":"华老师","description":"","mobile":"","gender":"MALE","birthday":"2004/09/13","avatars":[],"org":{"id":192,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/10/25 09:32","modifyById":35,"name":"格斗馆","description":"","address":"四川省成都市锦江区中纱帽街8号","addressDetail":"商鼎国际2-1","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"巨石","region":[],"logos":[{"url1":"dream/1/setting/20240320/0e6dbe1029f347fd89eb5c99f287eaee.png","url2":"dream/1/setting/20240320/d1fca9110425cc02150b7c3f54298fbd.png","url3":"dream/1/setting/20240320/cdfd92ee8fd3da597be2144cd82f8788.png","origin":"dream/1/setting/20240320/86c0f4f1dfde36b0a9ea2b545ebc79c7.png","def":null,"ext":"png","duration":null}],"galleries":[{"url1":"dream/1/setting/20240809/d2b570eb5fc51f9e0a07106b96a0552c.jpg","url2":"dream/1/setting/20240809/4cfd9736bf2bc207cc50735f183fe6d7.jpg","url3":"dream/1/setting/20240809/8545384e4c2b8ccd0cba03833156884d.jpg","origin":"dream/1/setting/20240809/735f4daf8efc136ff4ab83d80dc9a79c.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"15002830891","tel2":null,"openTime":"08:00:00","closeTime":"21:00:00","mch":null},"title":null,"user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":912,"createTime":"2023/11/10 09:17","createById":1,"modifyTime":"2024/03/31 19:35","modifyById":1,"name":"教师","description":"教师","orgId":192,"sys":1,"roleGroup":"org","roleName":"staff","state":"USED"},"state":"USED"},{"id":1658,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:59","modifyById":46,"name":"张老师","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":193,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"测试机构1","description":null,"address":null,"addressDetail":null,"lng":null,"lat":null,"pid":0,"versionType":"STANDARD","orgType":"NORMAL","companyName":"测试机构1","region":[],"logos":[],"galleries":[],"tel1":null,"tel2":null,"openTime":"10:00:00","closeTime":"21:00:00","mch":null},"title":"管理员","user":{"id":46,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":920,"createTime":"2023/11/16 09:57","createById":1,"modifyTime":"2023/11/16 09:57","modifyById":1,"name":"管理员","description":"校长,管理员,助理","orgId":193,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"}]');
        // localStorage.setItem("selectStaff", '{"id":2569,"createTime":"2023/11/16 09:58","createById":1,"modifyTime":"2023/11/16 09:58","modifyById":46,"name":"张华","description":"","mobile":"18080857109","gender":"MALE","birthday":"2003/11/16","avatars":[],"org":{"id":306,"createTime":"2023/06/06 19:47","createById":0,"modifyTime":"2024/05/22 00:02","modifyById":1,"name":"叮当云服务","description":"","address":"成都市","addressDetail":"123","lng":104.08373260498047,"lat":30.653186798095703,"pid":0,"versionType":"STANDARD","orgType":"PLATFORM","companyName":"88","region":[],"logos":[{"url1":"dream/1/setting/20240320/2a7d900fc72878a774d3cd6aea2195e0.jpg","url2":"dream/1/setting/20240320/9ccea81dbfdcb8e4d0c86b978aca0e42.jpg","url3":"dream/1/setting/20240320/a78b9307b000b3ec4d6ecc9d276494ee.jpg","origin":"dream/1/setting/20240320/71fad2f4bcae8fc644dca5d95b98c08c.jpg","def":null,"ext":"jpg","duration":null}],"galleries":[{"url1":"dream/1/setting/20240403/f87b937eedaf8842c59bbdcecf60d94e.jpg","url2":"dream/1/setting/20240403/172dc3868484f8b88ad26e54bb51d737.jpg","url3":"dream/1/setting/20240403/b1ddd7a6a8433e6ebace1d5360e426a1.jpg","origin":"dream/1/setting/20240403/15ba95a920efb1353226863f2ba26b53.jpg","def":null,"ext":"jpg","duration":null}],"tel1":"13981970816","tel2":"","openTime":"10:00:00","closeTime":"20:00:00","mch":{"id":1,"name":"优创力直营店"}},"title":null,"user":{"id":25,"createTime":"2023/11/16 09:44","createById":0,"modifyTime":"2023/11/16 09:44","modifyById":46,"name":"微信用户","description":null,"mobile":"18080857109","gender":"FEMALE","birthday":null,"avatars":[],"wxOpenId":"ossku41W2iaQstCmFjGuenxP7lUg","wxUnionId":"oI1DI1QIOZp2Q1s7YCeOGkoxMoys","wxOaOpenId":"oApStw7I11L8uo1HoTWK4MUTBzkY"},"role":{"id":427,"createTime":"2023/10/04 13:18","createById":22,"modifyTime":"2023/10/04 13:18","modifyById":22,"name":"管理员","description":"校长,管理员,助理","orgId":1,"sys":1,"roleGroup":"org","roleName":"admin","state":"USED"},"state":"USED"}');
        // // 正式库测试机构 orgid=306
    },
    mounted() {
        // 关闭浏览器窗口的时候清空浏览器缓存在localStorage的数据
src/views/student/components/upload-student.vue
@@ -1,230 +1,267 @@
<template>
  <el-form class="demo-ruleForm">
    <el-form-item label="" style="display: inline-block">
      <div class="uploading-center">
        <div class="uploading">
          <dragUpload
            :limit="1"
            :orgId="parseInt(orgId)"
            :staffId="parseInt(staffId)"
            @fileSuccess="fatherMethod"
            @file-uploading="showUploadProcess"
            :type="'AUDIENCE'"
            :action="'/dream/player/importPlayer'"
          >
            <div class="uploading-btn-to">
              <i class="iconfont iconAdd"></i> 上传
    <el-form class="demo-ruleForm">
        <el-form-item label="" style="display: inline-block">
            <div class="uploading-center">
                <div class="uploading">
                    <dragUpload
                        :limit="1"
                        :orgId="parseInt(orgId)"
                        :staffId="parseInt(staffId)"
                        @fileSuccess="fatherMethod"
                        @file-uploading="showUploadProcess"
                        :type="'AUDIENCE'"
                        :action="'/dream/player/importPlayer'"
                    >
                        <div class="uploading-btn-to">
                            <i class="iconfont iconAdd"></i> 上传
                        </div>
                        <div class="el-upload__tip" slot="tip">
                            只能上传.xls,.xlsx文件
                        </div>
                    </dragUpload>
                </div>
                <div class="download-file">
                    <i class="iconfont iconFile"></i>
                    <a href="/static/学员导入模板.xlsx" download
                        >下载学员模板</a
                    >
                </div>
            </div>
            <div class="el-upload__tip" slot="tip">只能上传.xls,.xlsx文件</div>
          </dragUpload>
        </div>
        <div class="download-file">
          <i class="iconfont iconFile"></i>
          <a href="/static/学员导入模板.xlsx" download>下载学员模板</a>
        </div>
      </div>
      <div style="font-size: 12px; color: #6993ff" v-if="hasAudience">
        已上传,如需修改直接点击上传
        <i class="el-icon-close" title="删除" @click="clearaudience"></i>
      </div>
    </el-form-item>
            <div style="font-size: 12px; color: #6993ff" v-if="hasAudience">
                已上传,如需修改直接点击上传
                <i
                    class="el-icon-close"
                    title="删除"
                    @click="clearaudience"
                ></i>
            </div>
        </el-form-item>
    <el-progress
      v-show="progress"
      type="circle"
      :percentage="percentage"
      :status="progressStatus"
    ></el-progress>
  </el-form>
        <el-progress
            v-show="progress"
            type="circle"
            :percentage="percentage"
            :status="progressStatus"
        ></el-progress>
    </el-form>
</template>
<script>
import dragUpload from "@/components/drag-upload";
var self = null;
var eventSource = null;
export default {
  inject: ["reload"],
  name: "Creation",
  data() {
    return {
      orgId: 0,
      staffId: 0,
      hasAudience: false,
      progress: false,
      percentage: 0,
      progressStatus: "",
    };
  },
  components: { dragUpload },
  methods: {
    downloadlist() {
      window.open("../../../assets/学员导入模板.xlsx", "_blank");
      // this.download('downPlayerTemplate', '学员导入模板.xlsx')
    inject: ["reload"],
    name: "Creation",
    data() {
        return {
            orgId: 0,
            staffId: 0,
            hasAudience: false,
            progress: false,
            percentage: 0,
            progressStatus: "",
            over: false
        };
    },
    clearaudience() {
      this.hasAudience = false;
    },
    fatherMethod(res, type) {
      this.progress = false;
      if (res.success) {
        var ojb = JSON.parse(res.message);
        if (ojb.falseLst === null) {
          this.$message.success("上传数据成功");
          this.$emit("load-success");
        } else if (ojb.falseLst.length >= 1) {
          let errortips = "";
          ojb.falseLst.map((item) => {
            errortips += (
              `${item.playerRoll}` +
              `${item.cause} </div><div style='line-height: 1.5;'>`
            ).replace("[]", "");
          });
          this.$message({
            dangerouslyUseHTMLString: true,
            message: `<div style='line-height: 1.5;'>导入数据成功导入${
              res.successNum || 0
            }条,错误信息:</div><div style='line-height: 1.5;'>${errortips}</div>`,
            type: "error",
            duration: 6000,
            showClose: true,
          });
        }
      } else {
        this.$message.error(res.message);
      }
      // if (res.falseLst === null) {
      //     this.$message.success("上传数据成功");
      //     this.$emit("load-success");
      // } else if (res.falseLst.length >= 1) {
      //     let errortips = "";
      //     res.falseLst.map((item) => {
      //         errortips += (`${item.playerRoll}` + `${item.cause} \r\n`).replace('[]', '');
      //     });
      //     this.$message({
      //         message: `导入数据成功导入${res.successNum}条,错误信息:${errortips}`,
      //         type: "error",
      //         duration: 6000,
      //     });
      // }
    },
    showUploadProcess() {
      self.progress = true;
      self.percentage = 0.1;
      self.progressStatus = "";
      setTimeout(function () {
        const eventSource = new EventSource(
          "/dream/sse-stream/" +
            JSON.parse(localStorage.getItem("selectStaff")).id
        );
    components: { dragUpload },
    methods: {
        downloadlist() {
            window.open("../../../assets/学员导入模板.xlsx", "_blank");
            // this.download('downPlayerTemplate', '学员导入模板.xlsx')
        },
        clearaudience() {
            this.hasAudience = false;
        },
        fatherMethod(res, type) {
            this.progress = false;
            // if (res.falseLst === null || res.falseLst.length === 0) {
            //     this.$message.success("上传数据成功");
            //     this.$emit("load-success");
            // }
            // else {
            //     let errortips = "";
            //     res.falseLst.map((item) => {
            //         errortips += (
            //             `${item.playerRoll}` +
            //             `${item.cause} </div><div style='line-height: 1.5;'>`
            //         ).replace("[]", "");
            //     });
            //     this.$message({
            //         dangerouslyUseHTMLString: true,
            //         message: `<div style='line-height: 1.5;'>导入数据成功导入${res.successNum || 0
            //             }条,错误信息:</div><div style='line-height: 1.5;'>${errortips}</div>`,
            //         type: "error",
            //         duration: 6000,
            //         showClose: true,
            //     });
            // }
        eventSource.onmessage = function (event) {
          const res = JSON.parse(event.data);
          self.percentage = Math.floor((res.current / res.total) * 10000) / 100;
          if (res.current == res.total) {
            self.progressStatus = "success";
            if (res.falseLst === null || res.falseLst.length === 0) {
              self.$message.success("上传数据成功");
              self.$emit("load-success");
              eventSource.close()
            if (res.success) {
                var ojb = JSON.parse(res.message);
                if (ojb.falseLst === null) {
                    this.$message.success("上传数据成功");
                    this.$emit("load-success");
                } else if (ojb.falseLst.length >= 1) {
                    let errortips = "";
                    ojb.falseLst.map((item) => {
                        errortips += (
                            `${item.playerRoll}` +
                            `${item.cause} </div><div style='line-height: 1.5;'>`
                        ).replace("[]", "");
                    });
                    this.$message({
                        dangerouslyUseHTMLString: true,
                        message: `<div style='line-height: 1.5;'>导入数据成功导入${ojb.successNum || 0
                            }条,错误信息:</div><div style='line-height: 1.5;'>${errortips}</div>`,
                        type: "error",
                        duration: 6000,
                        showClose: true,
                    });
                }
            } else {
                this.$message.error(res.message);
            }
            if (res.falseLst === null) {
                this.$message.success("上传数据成功");
                this.$emit("load-success");
            } else if (res.falseLst.length >= 1) {
              let errortips = "";
              res.falseLst.map((item) => {
                errortips += (
                  `${item.playerRoll}` +
                  `${item.cause} </div><div style='line-height: 1.5;'>`
                ).replace("[]", "");
              });
              self.$message({
                dangerouslyUseHTMLString: true,
                message: `<div style='line-height: 1.5;'>导入数据成功导入${
                  res.successNum || 0
                }条,错误信息:</div><div style='line-height: 1.5;'>${errortips}</div>`,
                type: "error",
                duration: 6000,
                showClose: true,
              });
                let errortips = "";
                res.falseLst.map((item) => {
                    errortips += (`${item.playerRoll}` + `${item.cause} \r\n`).replace('[]', '');
                });
                this.$message({
                    message: `导入数据成功导入${res.successNum}条,错误信息:${errortips}`,
                    type: "error",
                    duration: 6000,
                });
            }
            self.progress = false;
          }
        };
        eventSource.onerror = function (err) {
          console.error("EventSource failed:", err);
          eventSource.close();
          self.showUploadProcess();
        };
      }, 3 * 1000);
            setTimeout(function () {
                if (eventSource)
                    eventSource.close()
            }, 5 * 1000);
        },
        showUploadProcess() {
            self.progress = true;
            self.percentage = 0.1;
            self.progressStatus = "";
            setTimeout(function () {
                eventSource = new EventSource(
                    "/dream/sse-stream/" +
                    JSON.parse(localStorage.getItem("selectStaff")).id
                );
                eventSource.onmessage = function (event) {
                    const res = JSON.parse(event.data);
                    self.percentage = Math.floor((res.current / res.total) * 10000) / 100;
                    if (res.current == res.total) {
                        self.progressStatus = "success";
                        if ((res.falseLst === null || res.falseLst.length === 0) && self.progress) {
                            self.$message.success("上传数据成功");
                            self.$emit("load-success");
                        } else if (res.falseLst.length >= 1) {
                            let errortips = "";
                            res.falseLst.map((item) => {
                                errortips += (
                                    `${item.playerRoll}` +
                                    `${item.cause} </div><div style='line-height: 1.5;'>`
                                ).replace("[]", "");
                            });
                            self.$message({
                                dangerouslyUseHTMLString: true,
                                message: `<div style='line-height: 1.5;'>导入数据成功导入${res.successNum || 0
                                    }条,错误信息:</div><div style='line-height: 1.5;'>${errortips}</div>`,
                                type: "error",
                                duration: 6000,
                                showClose: true,
                            });
                        }
                        eventSource.close()
                        self.progress = false;
                    }
                };
                eventSource.onerror = function (err) {
                    console.error("EventSource failed:", err);
                    eventSource.close();
                    // self.showUploadProcess();
                };
            }, 2 * 1000);
        },
    },
  },
  created() {
    self = this;
    const selectStaff = JSON.parse(localStorage.getItem("selectStaff"));
    this.orgId = selectStaff.org.id;
    this.staffId = selectStaff.id;
  },
    created() {
        self = this;
        const selectStaff = JSON.parse(localStorage.getItem("selectStaff"));
        this.orgId = selectStaff.org.id;
        this.staffId = selectStaff.id;
    },
};
</script>
  
<style lang="scss" scoped>
.demo-ruleForm {
  text-align: center;
    text-align: center;
}
.creation-center {
  padding: 40px 40px 40px 40px;
    padding: 40px 40px 40px 40px;
}
.uploading-center {
  display: flex;
  flex-direction: row;
  > .uploading {
    min-height: 40px;
    line-height: 40px;
    box-sizing: border-box;
    border-radius: 4px;
  }
  .uploading-btn-to {
    width: 100px;
    line-height: 38px;
    height: 38px;
    border-radius: 3px;
    text-align: center;
    padding: 0 0px;
    cursor: pointer;
    user-select: none;
    margin-left: 0;
    color: #ffa800;
    font-size: 14px;
    border: 1px solid #ffbe41;
    > i {
      color: #ffbe41;
      font-size: 12px;
      margin-right: 5px;
    }
  }
  > .download-file {
    float: left;
    display: flex;
    flex-direction: row;
    margin-left: 20px;
    color: #6993ff;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
    height: 40px;
    > div {
      width: 117px;
      margin-left: 5px;
    > .uploading {
        min-height: 40px;
        line-height: 40px;
        box-sizing: border-box;
        border-radius: 4px;
    }
  }
    .uploading-btn-to {
        width: 100px;
        line-height: 38px;
        height: 38px;
        border-radius: 3px;
        text-align: center;
        padding: 0 0px;
        cursor: pointer;
        user-select: none;
        margin-left: 0;
        color: #ffa800;
        font-size: 14px;
        border: 1px solid #ffbe41;
        > i {
            color: #ffbe41;
            font-size: 12px;
            margin-right: 5px;
        }
    }
    > .download-file {
        float: left;
        display: flex;
        flex-direction: row;
        margin-left: 20px;
        color: #6993ff;
        font-size: 14px;
        cursor: pointer;
        user-select: none;
        height: 40px;
        > div {
            width: 117px;
            margin-left: 5px;
        }
    }
}
.uploading-center-style {
  ::v-deep .upload-demo {
    ::v-deep .el-upload {
      line-height: 38px;
    ::v-deep .upload-demo {
        ::v-deep .el-upload {
            line-height: 38px;
        }
    }
  }
}
::v-deep .uploading-center > .uploading {
  line-height: 37px;
    line-height: 37px;
}
</style>
vue.config.js
@@ -39,7 +39,7 @@
    proxy: {
      [process.env.VUE_APP_BASE_API]: {
        // 匹配所有以 '/dev-api'开头的请求路径
        target: "http://localhost:18080/dream", //类似于Nginx反向代理
        target: "http://127.0.0.1/dream", //类似于Nginx反向代理
        changeOrigin: true, // 支持跨域
        pathRewrite: {
          // 重写路径: 去掉路径中开头的'/dev-api'