ludc
2023-12-13 16913ea709f434cfebe71fd0c66b0a6931398f3e
Source/UBCS-WEB/src/views/flow/manager.vue
@@ -25,8 +25,10 @@
        <el-button type="text"
                   size="small"
                   icon="el-icon-refresh"
                   :style="{color: scope.row.suspensionState === 1 ? '#67C23A' : '#F56C6C'}"
                   v-if="permissionList.state"
                   @click.stop="handleState(scope.row,scope.index)">变更状态
                   @click.stop="handleDoState(scope.row, scope.index)">
          {{ scope.row.suspensionState === 1 ? '激活' : '挂起' }}
        </el-button>
        <el-button type="text"
                   size="small"
@@ -205,7 +207,7 @@
        return {
          state:this.vaildData(this.permission.flow_manager.flow_manager_state, false),
          image:this.vaildData(this.permission.flow_manager.flow_manager_image, false),
          delBtn: this.vaildData(this.permission.flow_manager.flow_manager_remove, false),
          delBtn: this.vaildData(this.permission.flow_manager.flow_manager_delete, false),
        };
      },
      ids() {
@@ -292,15 +294,15 @@
        this.stateBox = true;
        this.selectionId = row.id;
      },
      handleDoState() {
        if (!this.flowState) {
          this.$message({
            type: "warn",
            message: "请先选择流程状态!"
          });
          return;
        }
        changeState({processId: this.selectionId, state: this.flowState}).then(res => {
      handleDoState(row) {
        // if (!this.flowState) {
        //   this.$message({
        //     type: "warn",
        //     message: "请先选择流程状态!"
        //   });
        //   return;
        // }
        changeState({processId: row.id, state: (row.suspensionState === 1 ? 'suspend' : 'active')}).then(res => {
          const data = res.data;
          if (data.success) {
            this.$message({