Commit ce021df1 authored by yyh's avatar yyh

删除无用代码

parent 5ffcfcf3
...@@ -60,9 +60,7 @@ ...@@ -60,9 +60,7 @@
v-model="currentFolder.folder_name" v-model="currentFolder.folder_name"
/> />
</van-dialog> </van-dialog>
<transition name="van-slide-up"> <add-folder :show.sync="showAddFolder" @cancel="showAddFolder = false" @next="addFolder"></add-folder>
<add-folder v-if="showAddFolder" @cancel="showAddFolder = false" @next="addFolder"></add-folder>
</transition>
</div> </div>
</template> </template>
......
...@@ -115,7 +115,7 @@ export default class ProofItem extends Vue { ...@@ -115,7 +115,7 @@ export default class ProofItem extends Vue {
const { const {
showIncrementList, showIncrementList,
incrementList: { length }, incrementList: { length },
proof: { increment_num } proof: { increment_num },
} = this; } = this;
this.showIncrementList = !showIncrementList; this.showIncrementList = !showIncrementList;
if (this.showIncrementList && length <= 0) { if (this.showIncrementList && length <= 0) {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<van-dialog <van-dialog
use-slot use-slot
title="添加文件夹" title="添加文件夹"
v-model="show" v-model="showSelf"
show-cancel-button show-cancel-button
confirm-button-open-type="getUserInfo" confirm-button-open-type="getUserInfo"
@close="cancel" @close="cancel"
...@@ -14,45 +14,20 @@ ...@@ -14,45 +14,20 @@
placeholder="请输入文件夹名称" placeholder="请输入文件夹名称"
/> />
</van-dialog> </van-dialog>
<!-- <van-popup
v-model="show"
position="bottom"
:close-on-click-overlay="false"
:style="{height: '80%'}"
class="base-info">
<div style="position:relative;margin-bottom:26px;">
<common-svg
@click.native="cancel"
name="moban-quxiao"
style="position:absolute;left:17px;"></common-svg>
<span>创建文件夹</span>
</div>
<van-field v-model="folderName" placeholder="填写文件夹名称"></van-field>
<div class="btn-group">
<div @click="next" class="slc-btn-common next">确定</div>
</div>
</van-popup> -->
</template> </template>
<script lang="ts"> <script lang="ts">
import { Component, Prop, Vue, Emit } from 'vue-property-decorator'; import { Component, Prop, Vue, Emit, PropSync } from 'vue-property-decorator';
import { Field, Popup } from 'vant';
import { TEMPLATETYPE } from '@/const/enum'; import { TEMPLATETYPE } from '@/const/enum';
@Component({ @Component({
components: {
[Field.name]: Field,
[Popup.name]: Popup,
},
}) })
export default class AddFolder extends Vue { export default class AddFolder extends Vue {
private show: boolean = true; @PropSync('show', { type: Boolean, required: true })
private showSelf!: boolean;
private folderName: string = ''; private folderName: string = '';
private imgUrl: string = '';
private defaultFolderIndex: number = 0;
private defaultFolderName: string = '未分类文件夹';
@Emit('next') @Emit('next')
private next() { private next() {
this.show = false; this.showSelf = false;
const { folderName} = this; const { folderName} = this;
return { return {
folderName, folderName,
...@@ -60,48 +35,9 @@ export default class AddFolder extends Vue { ...@@ -60,48 +35,9 @@ export default class AddFolder extends Vue {
} }
@Emit('cancel') @Emit('cancel')
private cancel() { private cancel() {
this.show = false; this.showSelf = false;
}
private handleFileChange(e: any) {
const input = e.target;
const files = input.files;
if (files && files[0]) {
this.$api.file.upload(files[0]).then((res: any) => {
this.imgUrl = res.url;
});
}
} }
} }
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.base-info{
padding: 17px 0 0;
.file-input{
display: grid;
grid-template-columns: 20px auto 10px;
place-items: center;
padding: 7px 17px;
background:#F9F9FB;
color:#444444;
font-size:14px;
span{
place-self: start;
}
}
.btn-group{
color:#B6B5BA;
font-size: 14px;
.classify{
color: #3F79FE;
}
.next{
flex: auto;
padding: 10px 37px;
border-radius: 4px;
background: #3F79FE;
color: #FFFFFF;
font-size: 16px;
}
}
}
</style> </style>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment