ZhangXianQiang
2024-04-26 5e67283dee0f09a1236d3b8c816369a7fd610ed2
src/views/system/calculate/report/index.vue
@@ -146,6 +146,7 @@
                :precision="2" :step="0.1"
                :min="0" :max="1000000"
                v-model="scope.row.money"
                        disabled
                placeholder="请输入扣减金额">
              </el-input>
            </template>
@@ -170,7 +171,7 @@
</template>
<script>
import { listCheckResult, getCheckResult, delCheckResult, addCheckResult, updateCheckResult,manualScore, publishCheckResult } from "@/api/platform/check-result";
import { getCalculateReports, getCalculateReportById, deleteCalculateReportByIds, addCalculateReport, editCalculateReport } from "@/api/platform/calculate-report";
export default {
  name: "CheckResult",
@@ -187,14 +188,14 @@
        score: '94',
        value: '1%',
        ruleName: '<95',
        money: '',
        money: '10',
        description: '每少1分扣当月总服务费的1%。例如:当月考核得分91.5分,扣除当月服务费3.5%的金额',
      }, {
        time: '2024-04-03',
        score: '95',
        value: '0',
        ruleName: '≥95',
        money: '',
        money: '0',
        description: '不扣款',
      }, ],
      manualScoreOpen: false,
@@ -261,7 +262,7 @@
        this.queryParams["start"] = this.daterangeCheckTime[0];
        this.queryParams["end"] = this.daterangeCheckTime[1];
      }
      listCheckResult(this.queryParams).then(response => {
      getCalculateReports(this.queryParams).then(response => {
        this.checkResultList = response.rows;
        this.total = response.total;
        this.loading = false;
@@ -298,11 +299,11 @@
        this.$modal.msgWarning("请填写分数");
        return
      }
      manualScore(this.manualScoreForm).then(res => {
        this.$modal.msgSuccess("操作成功");
        this.cancelManualScore();
        this.getList();
      })
      // manualScore(this.manualScoreForm).then(res => {
      //   this.$modal.msgSuccess("操作成功");
      //   this.cancelManualScore();
      //   this.getList();
      // })
    },
    handleDetail(row) {
      console.log("row", row)
@@ -316,7 +317,7 @@
      let text = row.publish == 1 ? '取消发布' : '发布';
      const ids = row.id || this.ids;
      this.$modal.confirm('是否确认' + text + '考核结果编号为"' + ids + '"的数据项?').then(function() {
        return publishCheckResult(ids);
        // return publishCheckResult(ids);
      }).then(() => {
        this.getList();
        this.$modal.msgSuccess(text + "成功");
@@ -350,7 +351,7 @@
    handleUpdate(row) {
      this.reset();
      const id = row.id || this.ids
      getCheckResult(id).then(response => {
      getCalculateReportById(id).then(response => {
        this.form = response.data;
        this.open = true;
        this.title = "修改考核结果";
@@ -362,13 +363,13 @@
      this.$refs["form"].validate(valid => {
        if (valid) {
          if (this.form.id != null) {
            updateCheckResult(this.form).then(response => {
            editCalculateReport(this.form).then(response => {
              this.$modal.msgSuccess("修改成功");
              this.open = false;
              this.getList();
            });
          } else {
            addCheckResult(this.form).then(response => {
            addCalculateReport(this.form).then(response => {
              this.$modal.msgSuccess("新增成功");
              this.open = false;
              this.getList();
@@ -381,7 +382,7 @@
    handleDelete(row) {
      const ids = row.id || this.ids;
      this.$modal.confirm('是否确认删除考核结果编号为"' + ids + '"的数据项?').then(function() {
        return delCheckResult(ids);
        return deleteCalculateReportByIds(ids);
      }).then(() => {
        this.getList();
        this.$modal.msgSuccess("删除成功");