田源
2023-08-02 5adac0c4514f073ee27345c36a02de7f64fc2f56
主题库表格数据按状态搜索
已修改1个文件
32 ■■■■■ 文件已修改
Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue 32 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Source/UBCS-WEB/src/components/MasterCrud/VciMasterCrud.vue
@@ -18,6 +18,15 @@
              <el-input v-model="WupinFindValue" placeholder="请输入关键字按回车查询"
                        size="small" style="width: 180px; margin-left: 5px; margin-top: 10px"
                        @keyup.enter.native="tableFindInp"  v-if="tableData.length != 0"></el-input>
              <span style="margin-left: 10px" v-if="tableData.length != 0">
               <p style="font-size: 13px;display: inline-block;"> 状态:</p>
                <el-select v-model="statusSelect" slot="prepend" placeholder="请选择" size="small" @change="cellSelectHandler">
                <el-option label="全部" value="all"></el-option>
                <el-option label="已发布" value="Released"></el-option>
                <el-option label="编辑中" value="Editing"></el-option>
                <el-option label="已停用" value="Disabled"></el-option>
                <el-option label="审核中" value="Auditing"></el-option>
              </el-select></span>
            </div>
            <el-table  ref="dataTable" v-loading="isLoading" :data="tableData"
                      :height="tableHeight"
@@ -156,6 +165,7 @@
  },
  data() {
    return {
      statusSelect:"",
      searchResults: [],
      //首页右侧搜索
      WupinFindValue: "",
@@ -266,6 +276,7 @@
    },
    tableDataArray: {
      handler(newval, oldval) {
        this.statusSelect=''
        this.tableData = newval;
        this.searchResults = newval
        this.doLayout()
@@ -314,6 +325,10 @@
    }
  },
  methods: {
    //状态搜索
    cellSelectHandler(row){
      console.log(row)
    },
    //展开附件
    handleCollapse(activeNames) {
      if (activeNames.length > 0) {
@@ -400,11 +415,8 @@
                  cancelButtonText: '取消',
                  type: 'warning'
                }).then(() => {
                  const index = this.$route.query.id.indexOf('@');
                  const result = this.$route.query.id.substring(0, index);
                  console.log(this.$route.query)
                  const oid = this.selectRow.map(obj => obj.oid).join(",");
                  changeStatus({ oid: oid, btmname: result, lcStatus: 'Released' }).then(res => {
                  changeStatus({ oid: oid, btmname: this.result, lcStatus: 'Released' }).then(res => {
                    if(res.data.code == 200 ){
                      this.$message.success('发布成功')
                      this.onLoad()
@@ -455,10 +467,8 @@
                    cancelButtonText: '取消',
                    type: 'warning'
                  }).then(() => {
                    const index = this.$route.query.id.indexOf('@');
                    const result = this.$route.query.id.substring(0, index);
                    const oid = this.selectRow.map(obj => obj.oid).join(",");
                      changeStatus({ oid: oid, btmname: result, lcStatus: 'Disabled' }).then(res => {
                      changeStatus({ oid: oid, btmname: this.result, lcStatus: 'Disabled' }).then(res => {
                        if(res.data.code == 200 ){
                          this.$message.success('停用成功')
                          this.onLoad()
@@ -508,10 +518,8 @@
                    cancelButtonText: '取消',
                    type: 'warning'
                  }).then(() => {
                    const index = this.$route.query.id.indexOf('@');
                    const result = this.$route.query.id.substring(0, index);
                    const oid = this.selectRow.map(obj => obj.oid).join(",");
                    changeStatus({ oid: oid, btmname: result, lcStatus: 'Released' }).then(res => {
                    changeStatus({ oid: oid, btmname: this.result, lcStatus: 'Released' }).then(res => {
                      if(res.data.code == 200 ){
                        this.$message.success('启用成功')
                        this.onLoad()
@@ -567,10 +575,8 @@
                    cancelButtonText: '取消',
                    type: 'warning'
                  }).then(() => {
                    const index = this.$route.query.id.indexOf('@');
                    const result = this.$route.query.id.substring(0, index);
                    const oid = this.selectRow.map(obj => obj.oid).join(",");
                    changeStatus({ oid: oid, btmname: result, lcStatus: 'TakeBack' }).then(res => {
                    changeStatus({ oid: oid, btmname: this.result, lcStatus: 'TakeBack' }).then(res => {
                      if(res.data.code == 200 ){
                        this.$message.success('回收成功')
                        this.onLoad()