瀏覽代碼

关闭文件夹清空首字母(3154)

zhangxc 5 年之前
父節點
當前提交
9d57259d2b
共有 1 個文件被更改,包括 5 次插入4 次删除
  1. 5 4
      src/components/Operation/index.jsx

+ 5 - 4
src/components/Operation/index.jsx

@@ -217,8 +217,7 @@ class Operation extends Component {
     const { type } = this.state;
     if (type == 3){
       diagShowTmp(false)
-      this.setState({ title: '',deptId:"",value:"",folderListShow:false,folderNameVal:'未分类文件夹',folderId:'' })
-      this.setState({fstName:''})
+      this.setState({ title: '',deptId:"",value:"",folderListShow:false,folderNameVal:'未分类文件夹',folderId:'',fstName:'' })
     }
   }
   changeTitle() {
@@ -315,6 +314,7 @@ class Operation extends Component {
         that.context.scrollArea&&that.context.scrollArea.refresh();
       });
     } else if (type == 3) {
+      console.log('this.state.fstName',this.state.fstName)
       if (this.state.title.trim() == '') {
         Notify.error('请输入模板名称')
         return;
@@ -361,7 +361,8 @@ class Operation extends Component {
         this.setState({
           folderNameVal:'未分类文件夹',
           folderId:'',
-          fstName:''
+          fstName:'',
+          deptId:''
         })
       }else{
         saveDataAll(title,sex,fstName);
@@ -373,7 +374,7 @@ class Operation extends Component {
     const { type } = this.state;
     if (type == 3){
       diagShowTmp(false)
-      this.setState({ title: '',deptId:"",value:"",folderListShow:false,folderNameVal:'未分类文件夹',folderId:'' })
+      this.setState({ title: '',deptId:"",value:"",folderListShow:false,folderNameVal:'未分类文件夹',folderId:'',fstName:''})
     }
   }
   setDeptId(id,name){