소스 검색

流标重新招标

fan0987 5 일 전
부모
커밋
c23c8922c6

+ 1 - 1
ruoyi-ui/src/api/system/plan.js

@@ -31,7 +31,7 @@ export function addPlan(data) {
 export function updatePlan(data) {
   return request({
     url: "/ppm/plan/edit",
-    method: "post",
+    method: "put",
     data: data,
   });
 }

+ 25 - 0
ruoyi-ui/src/api/system/tender/tender.js

@@ -115,3 +115,28 @@ export function openTenderTwo(data) {
     data: data,
   });
 }
+
+// 查询流标项目列表
+export function reloadFailList(query) {
+  return request({
+    url: "/bidding/tender/reloadFailList",
+    method: "get",
+    params: query,
+  });
+}
+// 审批流标项目重新开标
+export function tenderExamine(data) {
+  return request({
+    url: "/bidding/tender/tenderExamine",
+    method: "put",
+    data: data,
+  });
+}
+// 查询流标项目审批记录
+export function tenderRecordList(query) {
+  return request({
+    url: "/bidding/tenderRecord/list",
+    method: "get",
+    params: query,
+  });
+}

+ 144 - 11
ruoyi-ui/src/views/tender/tender1/details.vue

@@ -1,16 +1,80 @@
 <template>
-  <div>
-    <tender-details v-if="caigou && caigou.aid" :caigou="caigou" :plan="plan"></tender-details>
-    <!-- <device-details></device-details> -->
-    <CompPlanDetails v-if="plan && plan.aid" :plan="plan" />
-    <div style="margin: 10px 0px 10px 20px">
-      <el-button @click="over">取消</el-button>
-    </div>
+  <div class="app-container">
+    <el-tabs v-model="paneName">
+      <el-tab-pane label="基础资料" name="basic">
+        <div v-if="canReTender && failStatus == 0" class="top-right-btn">
+          <el-button type="primary" @click="reTender(1)">重新招标</el-button>
+          <el-button @click="over">返回</el-button>
+        </div>
+        <tender-details v-if="caigou && caigou.aid" :caigou="caigou" :plan="plan"></tender-details>
+        <CompPlanDetails v-if="plan && plan.aid" :plan="plan" />
+
+        <div v-if="failStatus == 1">
+          <el-card ref="card" style="margin-top: 20px" class="never">
+            <div slot="header" class="clearfix">
+              <span>审核意见</span>
+              <el-button @click="item.show = !item.show" style="float: right; padding: 3px 0" type="text">
+                {{ item.show ? '隐藏意见' : '显示意见' }}
+              </el-button>
+            </div>
+            <div v-if="item.show" class="text item">
+              <editor v-model="form.editor" :min-height="120" />
+            </div>
+          </el-card>
+          <div style="text-align: right;margin-top: 10px;">
+            <el-button v-hasPermi="['system:procurement:allow']" type="primary" @click="reTender(2)"
+              v-loading.fullscreen.lock="fullscreenLoading">审核
+            </el-button>
+            <el-button v-hasPermi="['system:procurement:reject']" type="danger" @click="rejectPlan"
+              v-loading.fullscreen.lock="fullscreenLoading">驳回
+            </el-button>
+            <el-button @click="over">返 回</el-button>
+          </div>
+        </div>
+      </el-tab-pane>
+      <el-tab-pane v-if="canReTender" label="审批记录" name="record_approval">
+        <el-steps space="200" simple :active="failStatus + 1">
+          <el-step title="待提交"></el-step>
+          <el-step title="待审核"></el-step>
+          <el-step title="已生效"></el-step>
+        </el-steps>
+
+        <el-table style="margin-top: 20px" max-height="800" :data="record_approval">
+          <el-table-column type="expand">
+            <template slot-scope="scope">
+              <el-card class="box-card">
+                <div slot="header" class="clearfix">
+                  <span>意见详情</span>
+                  <el-button @click="expand(scope.row.opinionDetails)" style="float: right; padding: 3px 0"
+                    type="text">查看更多
+                  </el-button>
+                </div>
+                <div style="height: 100px" v-html="scope.row.opinionDetails" class="text item"></div>
+              </el-card>
+            </template>
+          </el-table-column>
+          <el-table-column label="序号" align="center" prop="rid">
+            <template slot-scope="scope">
+              {{ scope.$index + 1 }}
+            </template>
+          </el-table-column>
+          <el-table-column label="流程节点" align="center" prop="node" width="135" />
+          <el-table-column label="处理人" align="center" prop="processedBy" />
+          <el-table-column label="所属部门" align="center" prop="depnt" />
+          <el-table-column label="处理时间" align="center" prop="updateTime" width="180">
+            <template slot-scope="scope">
+              <span>{{ scope.row.updateTime }}</span>
+            </template>
+          </el-table-column>
+          <el-table-column label="状态" align="center" prop="opinion" />
+        </el-table>
+      </el-tab-pane>
+    </el-tabs>
   </div>
 </template>
 
 <script>
-import { getTender } from '@/api/system/tender/tender'
+import { getTender, tenderExamine, tenderRecordList } from '@/api/system/tender/tender'
 import { getPlan } from '@/api/system/plan'
 import { getMateriel } from "@/api/mast/materiel";
 import { getPlanProfileByAid } from "@/api/system/planprofile"
@@ -25,15 +89,33 @@ export default {
   },
   data () {
     return {
+      fullscreenLoading: false,
+
+      paneName: 'basic',
+
       plan: {
         aid: null,
         buyingMode: null
       },
 
-      caigou: {}
+      caigou: {},
+
+      sProjectState: null,
+
+      canReTender: false,
+      record_approval: [],
+      failStatus: null,
+
+      form: {
+        editor: '',
+      },
+      item: {
+        show: true
+      },
     }
   },
   created () {
+    this.canReTender = this.$route.query.loss
     this.getData()
   },
   methods: {
@@ -42,16 +124,67 @@ export default {
     },
     async getData () {
       const res = await getTender(this.$route.query.sid)
-
       const res1 = await getPlan(res.data.xyId)
       const caigou = await getPlanProfileByAid(res1.data.aid)
 
       this.plan = res1.data
       this.caigou = caigou.data
-
       getMateriel(this.plan.materialId).then(resMateriel => {
         this.plan.materialName = resMateriel.data.materielName
       })
+      this.sProjectState = res.data.sProjectState
+      this.failStatus = res.data.failStatus
+
+      if (this.canReTender) {
+        this.tenderRecordList()
+      }
+    },
+
+    // 审批记录
+    tenderRecordList() {
+      tenderRecordList({sid: this.$route.query.sid})
+      .then(res => {
+        this.record_approval = res.rows;
+      })
+    },
+    
+    // 申请/审核重新招标
+    reTender(state) {
+      const plan = this.plan
+      this.$modal.confirm(`确认${plan.aName}项目进行重新招标?`).then(() => {
+        this.ComUpdatePlan(state)
+      })
+    },
+
+    // 驳回请求
+    rejectPlan() {
+      if (!this.form.editor) {
+        this.$modal.msgError("请输入审核意见")
+        return;
+      }
+      this.$modal.confirm("确定要驳回吗?").then(() => {
+        this.ComUpdatePlan(0);
+      })
+    },
+
+    // 重新招标
+    ComUpdatePlan(state) {
+      this.fullscreenLoading = true;
+      const sid  = this.$route.query.sid
+      let obj = {};
+      obj['status'] = state;
+      obj['sid'] = sid;
+      obj['opinionDetails'] = this.form.editor
+      
+      tenderExamine(obj).then(res => {
+        this.fullscreenLoading = false;
+        this.$message.success("操作成功!!");
+        this.$tab.closePage()
+
+      }).catch(err => {
+        this.fullscreenLoading = false;
+        this.$modal.msgError("服务器出错,请联系管理员!!!");
+      })
     },
   }
 }

+ 133 - 0
ruoyi-ui/src/views/tender/tender1/lossTender.vue

@@ -0,0 +1,133 @@
+<template>
+    <div class="app-container loss-tender">
+        <div>
+            <el-row :gutter="15">
+                <el-form ref="elForm" :inline="true" label-width="72px">
+                    <el-form-item label="项目编号" prop="sCode">
+                        <el-input v-model.trim="query.sCode" placeholder="请输入项目编号" clearable></el-input>
+                    </el-form-item>
+                    <el-form-item label="项目名称" prop="sName">
+                        <el-input v-model.trim="query.sName" placeholder="请输入项目名称" clearable></el-input>
+                    </el-form-item>
+                    <el-form-item>
+                        <el-button type="primary" @click="handleQuery">查询</el-button>
+                        <el-button @click="resetQuery">重置</el-button>
+                    </el-form-item>
+                </el-form>
+            </el-row>
+        </div>
+
+        <el-tabs v-model="activeName" @tab-click="handleClick">
+            <el-tab-pane v-for="dict in dict.type.bid_fail_tender" :key="dict.value" :label="dict.label"
+                :name="dict.value">
+            </el-tab-pane>
+        </el-tabs>
+
+        <el-table v-loading="loading" :data="tenderList" :default-sort="{prop: 'uKaiTime', order: 'descending'}">
+            <el-table-column label="序号" align="center" prop="orderNum" width="60" />
+            <el-table-column label="项目编号" align="center" prop="sCode" width="170" />
+            <el-table-column label="项目名称" align="center" prop="sName" min-width="150" />
+            <el-table-column label="采购单位" align="center" prop="sUnit" min-width="150" />
+            <el-table-column label="工程项目" align="center" prop="projectName" min-width="150" />
+            <el-table-column label="采购方式" align="center" prop="buyingMode">
+                <template slot-scope="scope">
+                    <dict-tag :options="dict.type.buying_mode" :value="scope.row.buyingMode" />
+                </template>
+            </el-table-column>
+            <el-table-column label="报价方式" align="center" prop="quoteMode">
+                <template slot-scope="scope">
+                    <dict-tag :options="dict.type.quote_mode" :value="scope.row.quoteMode" />
+                </template>
+            </el-table-column>
+            <el-table-column label="开标时间" align="center" prop="uKaiTime" width="100" sortable />
+            <el-table-column label="项目状态" align="center" prop="sProjectState">
+                <template slot-scope="scope">
+                    <dict-tag :options="dict.type.bid_tender_state" :value="scope.row.sProjectState" />
+                </template>
+            </el-table-column>
+            <el-table-column label="操作" align="center" class-name="small-padding fixed-width" fixed="right">
+                <template slot-scope="scope">
+                    <router-link :to="'/tender/bidding?type=bidding&sid=' + scope.row.sid">
+                        <el-button v-if="scope.row.sProjectState != 1" size="mini" type="text"
+                            icon="el-icon-delete">进入项目</el-button>
+                    </router-link>
+                    <router-link :to="'/tender/details?type=details&loss=true&sid=' + scope.row.sid">
+                        <el-button size="mini" type="text" icon="el-icon-view">查看</el-button>
+                    </router-link>
+                </template>
+            </el-table-column>
+        </el-table>
+
+        <pagination v-show="total > 0" :total="total" :page.sync="query.pageNum" :limit.sync="query.pageSize"
+            @pagination="getList" />
+    </div>
+</template>
+
+<script>
+import { reloadFailList } from '@/api/system/tender/tender'
+
+export default {
+    name: 'LossTender',
+
+    dicts: ["bid_tender_state", "quote_mode", "buying_mode", "bid_fail_tender"],
+
+    data() {
+        return {
+            // 遮罩层
+            loading: true,
+            // 总条数
+            total: 0,
+            // 招标项目表格数据
+            tenderList: [],
+            // 查询参数
+            query: {
+                pageNum: 1,
+                pageSize: 10,
+                sCode: null,
+                sName: null,
+                failStatus: 0
+            },
+
+            activeName: 0
+        }
+    },
+
+    created () {
+        this.getList()
+    },
+
+    methods: {
+        /*查看采购计划*/
+        handleClick(activeName) {
+            this.query.failStatus = activeName.name
+            this.handleQuery()
+        },
+
+        /** 查询招标项目列表 */
+        getList () {
+            this.loading = true;
+            this.tenderList = [];
+            reloadFailList(this.query).then(response => {
+                response.rows.forEach((e, i) => {
+                    e.orderNum = i + 1;
+                    this.tenderList.push(e);
+                })
+                this.total = response.total;
+                this.loading = false;
+            });
+        },
+
+        /** 搜索按钮操作 */
+        handleQuery () {
+            this.query.pageNum = 1;
+            this.getList();
+        },
+        /** 重置按钮操作 */
+        resetQuery () {
+            this.query.sCode = null
+            this.query.sName = null
+            this.handleQuery()
+        },
+    }
+}
+</script>