| | |
| | | <template> |
| | | <div class="myModal" ref="test"> |
| | | <a-modal v-drag-modal v-model="visible" title="日志添加" on-ok="handleOk" |
| | | :bodyStyle="{'overflow':'overlay','maxHeight': '550px'}"> |
| | | <div class="myModal"> |
| | | <a-modal v-drag-modal ref="blogAddModal" v-model="visible" title="日志添加" on-ok="handleOk" |
| | | :bodyStyle="{'overflow':'overlay','maxHeight': '550px'}" :destroyOnClose="destroyOnClose"> |
| | | <template slot="footer"> |
| | | <a-button key="reset" @click="reset" type="danger"> |
| | | 擦掉重来 |
| | |
| | | return { |
| | | visible: false, |
| | | loading: false, |
| | | destroyOnClose: false, |
| | | } |
| | | }, |
| | | methods: { |
| | |
| | | |
| | | let tempData = this.$refs.modalBox.form; |
| | | var param = { |
| | | introduce: tempData.introduce, |
| | | secret: tempData.secret, |
| | | title: tempData.title, |
| | | articleTypeId: tempData.class, |
| | |
| | | articleFileId: tempData.fileId, |
| | | content: tempData.content, |
| | | articleFileType: tempData.blogType, |
| | | introduce: "", |
| | | coverFileId: tempData.coverFile, |
| | | pictureIds: tempData.pictureIds, |
| | | videoIds: tempData.videoIds, |
| | | publishDate: tempData.publishDate, |
| | | isTop: tempData.top ? 1 : 0, |
| | | topValue: tempData.sliderValue, |
| | |
| | | // }, 3000); |
| | | }, |
| | | reset(e) { |
| | | var res = this.$refs.modalBox.$refs.myForm.resetFields(); |
| | | // var res = this.$refs.modalBox.$refs.myForm.resetFields(); |
| | | //this.$refs.modalBox.reset(); |
| | | this.destroyOnClose = true; |
| | | this.visible = false; |
| | | setTimeout(() => { |
| | | this.destroyOnClose = false; |
| | | }, 500) |
| | | }, |
| | | handleCancel(e) { |
| | | this.visible = false; |