1.解决vue项目中import @/符号下有波浪线的问题

https://blog.csdn.net/weixin_48095370/article/details/115477678
1.首先打开webstorm中file->setting,之后找到language&frameworks中javascript的webpack选项
2.之后点开找到项目目录\node_modules\@vue\cli-service\webpack.config.js 后点应用即可。

1、根据子id 找出完整的父级数组

  1. // 查找父元素
  2. getParentNodes(id, tree) {
  3. this._getParentNodes([], id, tree);
  4. return this.nodes;
  5. },
  6. _getParentNodes(his, targetId, tree) {
  7. tree.some((list) => {
  8. const children = list.childVO || [];
  9. if (list.id == targetId) {
  10. his.push(list.id);
  11. this.nodes = his;
  12. return true;
  13. } else if (children.length > 0) {
  14. const history = [...his];
  15. history.push(list.id);
  16. return this._getParentNodes(history, targetId, children);
  17. }
  18. })
  19. },
  20. this.postOrGroupId1 = this.getParentNodes(this.form1.groupId,this.postList);

1、多个文件下载用window.open不行

https://blog.csdn.net/m0_37792830/article/details/103992796

单个文件下载

  1. window.open(url)

多个文件下载
多个文件下载用window.open不行,你会发现他只下载了一个,并不是所有。

  1. let triggerDelay = 100;
  2. let removeDelay = 1000;
  3. this.urlList.forEach((url, index) => {
  4. this.createIFrame(url, index * triggerDelay, removeDelay);
  5. });
  6. // 这里是创建iframe的方法
  7. function createIFrame(url, triggerDelay, removeDelay) {
  8. //动态添加iframe,设置src,然后删除
  9. setTimeout(function() {
  10. var frame = document.createElement("iframe");
  11. frame.src = url;
  12. frame.style.display = "none";
  13. document.body.appendChild(frame);
  14. setTimeout(function() {
  15. frame.remove();
  16. }, removeDelay);
  17. }, triggerDelay);
  18. },

2、解决element-ui 中upload组件使用多个时无法绑定对应的元素

https://www.jianshu.com/p/6a4d0c6e26c2

3、vue项目添加Cropper.js实现裁剪功能

https://www.cnblogs.com/xingzoudecd/p/14028622.html

3.element-ui日期组件DatePicker设置日期选择范围Picker Options

https://www.cnblogs.com/steamed-twisted-roll/p/9755651.html