| | |
| | | <template> |
| | | <basic-container> |
| | | <avue-crud :option="option" :table-loading="loading" :data="data" :page.sync="page" ref="crud" @row-del="rowDel" |
| | | v-model="form" :permission="permissionList" @row-update="rowUpdate" @row-save="rowSave" |
| | | :before-open="beforeOpen" @search-change="searchChange" @search-reset="searchReset" |
| | | @selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange" |
| | | @refresh-change="refreshChange" @on-load="onLoad"> |
| | | v-model="form" :permission="permissionList" @row-update="rowUpdate" @row-save="rowSave" :before-open="beforeOpen" |
| | | @search-change="searchChange" @search-reset="searchReset" @selection-change="selectionChange" |
| | | @current-change="currentChange" @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad"> |
| | | <template slot="menuLeft"> |
| | | <el-button size="small" icon="el-icon-delete" plain v-if="permission.article_delete" @click="handleDelete">删 |
| | | 除 |
| | |
| | | </template> |
| | | |
| | | <template slot-scope="{type,size,row }" slot="menu"> |
| | | <!-- <el-button icon="el-icon-circle-plus-outline" :size="size" :type="type" @click.stop="openDilog(row, 1)"> |
| | | 创建议题 |
| | | </el-button> --> |
| | | <el-button icon="el-icon-s-tools" :size="size" :type="type" @click.stop="openDilog(row, 1)"> |
| | | 设置 |
| | | </el-button> |
| | | |
| | | <el-button icon="el-icon-edit" :size="size" :type="type" @click.stop="openEditPopup(row, 1)"> |
| | | 编辑议题 |
| | |
| | | 参与用户 |
| | | </el-button> |
| | | |
| | | <el-button v-if="row.publish == '1'" icon="el-icon-close" :size="size" :type="type" |
| | | @click.stop="updateFb(row)"> |
| | | <el-button v-if="row.publish == '1'" icon="el-icon-close" :size="size" :type="type" @click.stop="updateFb(row)"> |
| | | 撤销 |
| | | </el-button> |
| | | |
| | | <el-button v-if="row.publish == '0'" icon="el-icon-check" :size="size" :type="type" |
| | | @click.stop="updateFb(row)"> |
| | | <el-button v-if="row.publish == '0'" icon="el-icon-check" :size="size" :type="type" @click.stop="updateFb(row)"> |
| | | 发布 |
| | | </el-button> |
| | | </template> |
| | |
| | | <deitDiscussion ref="DeitDiscussion"> |
| | | </deitDiscussion> |
| | | |
| | | <el-dialog title="" append-to-body :visible.sync="dialogVisibles" width="80%" :before-close="handleClose"> |
| | | <discussionManageChild ref="discussionManageChild" /> |
| | | <!-- <span slot="title" class="dialog-footer"> |
| | | {{discussForm.ontitle}} |
| | | </span> --> |
| | | <!-- <div id="" v-if="discussForm.eventType == 1"> |
| | | <avue-form @submit="handleSubmit" :option="optionDiscuss" v-model="discussForm"></avue-form> |
| | | </div> --> |
| | | |
| | | <!-- <div id="" v-else> |
| | | <avue-form @submit="handleSubmit" :option="optionEnroll" v-model="discussForm"> |
| | | </avue-form> |
| | | </div> --> |
| | | </el-dialog> |
| | | </basic-container> |
| | | </template> |
| | | |
| | |
| | | userIds: '', |
| | | eventType: 1, |
| | | }, |
| | | dialogVisibles: false, |
| | | form: {}, |
| | | query: {}, |
| | | loading: true, |
| | |
| | | tip: false, |
| | | searchShow: true, |
| | | searchMenuSpan: 3, |
| | | menuWidth: 450, |
| | | menuWidth: 500, |
| | | border: false, |
| | | //stripe:true, |
| | | index: true, |
| | | viewBtn: true, |
| | | viewBtn: false, |
| | | selection: true, |
| | | excelBtn: true, |
| | | dialogClickModal: false, |
| | |
| | | |
| | | openDilog (row, type) { |
| | | var that = this |
| | | this.dialogVisibles = true |
| | | this.$nextTick(() => { |
| | | that.$refs.discussionManageChild.init(row) |
| | | }) |
| | | // this.discussForm.eventType = type |
| | | // this.discussForm.articleId = row.id |
| | | // this.discussForm.title = row.title |
| | | // if (type == 0) { |
| | | // this.discussForm.ontitle = '公益报名' |
| | | // } else { |
| | | // this.discussForm.ontitle = '创建议题' |
| | | // } |
| | | }, |
| | | |
| | | handleSubmit (form, done) { |
| | | done() |
| | | addPd(form).then( |
| | | () => { |
| | | this.$message({ |
| | | type: "success", |
| | | message: "操作成功!", |
| | | }) |
| | | this.dialogVisibles = false |
| | | done() |
| | | }, |
| | | (error) => { |
| | | window.console.log(error) |
| | | // loading(); |
| | | } |
| | | ) |
| | | }, |
| | | |
| | | handleClose (done) { |
| | | done() |
| | | // this.$confirm('确认关闭?') |
| | | // .then(_ => { |
| | | // done(); |
| | | // }) |
| | | // .catch(_ => {}); |
| | | }, |
| | | rowSave (row, done, loading) { |
| | | console.log(row, 9999) |
| | | if (row.videoUrl.length == 0) { |
| | | row.videoUrl = "" |
| | | } |