当前位置:网站首页>上传图片/文件
上传图片/文件
2022-07-15 12:56:00 【kilito_01】
// 让这个input隐藏起来 用ref去调用他
// 在其他的方法中就可以调用这个上传的事件
this.$refs.photosFile.click();
<input type="file" ref="photosFile" @change="fileChange" style="display: none" multiple accept="image/*">
let files = e.target.files || e.dataTransfer.files;
let that = this;
for (let i = 0; i < files.length; i++) {
let size = files[i].size;
if (size > (20 * 1024 * 1024)) {
this.imgUploadTips = "图片大小不能超过20M";
this.isShowTips = true;
return false
}
}
以下就是调用自己的接口上传照片 返回照片的数据
。。。。。。
边栏推荐
- Polardb for PostgreSQL is based on shared storage, multi computing and single storage
- UTONMOS:社交元宇宙如何构建数字世界
- Between the virtual and the real 03 | with these technologies, you are the "magic pen Ma Liang" that makes digital people live
- 新汇成通过注册:年营收8亿 实控人郑瑞俊有超3亿负债
- 源码解析(个人收录,并不标准)
- JGG (if 5.733) special issue solicitation: Human Microbiome
- 【C语言】静态&动态&文件通讯录(超万字)
- Mise en œuvre du modèle proxy actif zabbix
- Unity engineering manages Pico and oculus projects in a unified manner
- Bufferedinputstream byte cache input stream and cache stream efficiency test_ Copy files
猜你喜欢

Layout meta universe social networking, and the digital economy will usher in new opportunities for development

Talking about some features of improving work efficiency supported by slack channel
![[Voforia] 通过识自己设定图片,显示特定AR模型](/img/4c/36a2009ea309379aa105a94f82b7ac.png)
[Voforia] 通过识自己设定图片,显示特定AR模型

How does Xishanju build a game industry assembly line with ones? | Ones industry practice

让企业数字化砸锅和IT主管背锅的软件供应链安全风险指北

Ordinary two graduated for five years and prepared for two months. Alibaba rated P7 on all sides

论文学习(一)——MWP-BERT: Numeracy-Augmented Pre-training for Math WordProblem Solving

OSPF知识点1

Unity engineering manages Pico and oculus projects in a unified manner

Clustered index and non clustered index
随机推荐
PKI: content of digital certificate
Codeforces round 804 (Div. 2) d. almost triple deletions time limit per test2 seconds (DP good questions)
让企业数字化砸锅和IT主管背锅的软件供应链安全风险指北
四面阿里offer定级P8,2022最新最实用阿里68道高级面试题,助你们面试成功!!
论文学习(一)——MWP-BERT: Numeracy-Augmented Pre-training for Math WordProblem Solving
As shown in the following figure, how to connect polardb for PostgreSQL?
Is polardb for PostgreSQL underlying PostgreSQL?
Shangyun boutique | cloud store helps Huike promote the combination of schools and enterprises and jointly cultivate talents
Indexedstack in shutter
360预计上半年扣非净亏4.5亿至6.3亿 广告投放预算不及预期
BufferedInputStream字节缓存输入流和缓存流的效率测试_复制文件
It's time to upgrade your JUnit, junit5 super detailed actual combat
UTONMOS:社交元宇宙如何构建数字世界
leetcode 605. Can place flowers planting problem (simple)
Speed of light raised more than $7billion miqun: increase the proportion of green technology and hard technology investment
Four sides Ali offer grading p82022 latest and most practical Ali 68 advanced interview questions to help you succeed in your interview!!
腾讯T4架构师带你“一窥”大型网站架构的主要技术挑战和解决方案
Hydropower station equipment can also be operated remotely
MGRE环境下的OSPF实验
Thesis learning (I) -- MWP bert: numerical augmented pre training for math wordproblem solving