浏览代码

园区重点项目添加审核页面

Sanmu8 1 年之前
父节点
当前提交
53a45be73b
共有 4 个文件被更改,包括 217 次插入49 次删除
  1. 1 2
      src/views/ARTICLE/edit.vue
  2. 132 45
      src/views/ARTICLE/index.vue
  3. 80 0
      src/views/ARTICLE/task/index.vue
  4. 4 2
      src/views/task/index.vue

+ 1 - 2
src/views/ARTICLE/edit.vue

@@ -40,7 +40,6 @@
       </el-form-item>
       <el-form-item label="形象进度" prop="schedule">
         <el-input
-          type="number"
           v-model="form.schedule"
           placeholder="请输入形象进度"
           style="width: 50%"
@@ -120,7 +119,7 @@ export default {
   },
   mounted() {
     if (this.param.id) {
-      getNEWS(this.param.id).then((response) => {
+      getARTICLE(this.param.id).then((response) => {
         this.form = response.data;
         this.form.content = response.data.content.replace(
           new RegExp("/profile/upload/", "g"),

+ 132 - 45
src/views/ARTICLE/index.vue

@@ -1,12 +1,30 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+    <el-form
+      :model="queryParams"
+      ref="queryForm"
+      size="small"
+      :inline="true"
+      v-show="showSearch"
+      label-width="68px"
+    >
       <el-form-item label="项目名称" prop="atvName">
-        <el-input v-model="queryParams.atvName" placeholder="请输入项目名称"></el-input>
+        <el-input
+          v-model="queryParams.atvName"
+          placeholder="请输入项目名称"
+        ></el-input>
       </el-form-item>
       <el-form-item>
-        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
-        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+        <el-button
+          type="primary"
+          icon="el-icon-search"
+          size="mini"
+          @click="handleQuery"
+          >搜索</el-button
+        >
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery"
+          >重置</el-button
+        >
       </el-form-item>
     </el-form>
 
@@ -19,24 +37,36 @@
           size="mini"
           @click="handleAdd"
           v-hasPermi="['business:ARTICLE:add']"
-        >新增</el-button>
+          >新增</el-button
+        >
       </el-col>
       <el-col :span="1.5">
-        <el-button type="danger"  size="mini" icon="el-icon-delete" :disabled="multiple" @click="handleDelete" v-hasPermi="['business:ARTICLE:remove']">删除</el-button>
+        <el-button
+          type="danger"
+          size="mini"
+          icon="el-icon-delete"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['business:ARTICLE:remove']"
+          >删除</el-button
+        >
       </el-col>
-      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+      <right-toolbar
+        :showSearch.sync="showSearch"
+        @queryTable="getList"
+      ></right-toolbar>
     </el-row>
 
     <el-table :data="ARTICLEList" @selection-change="handleSelectionChange">
       <el-table-column type="selection"></el-table-column>
       <el-table-column label="保税区名称" align="center" prop="deptName">
         <template slot-scope="scope">
-          {{scope.row.deptName}}
+          {{ scope.row.deptName }}
         </template>
       </el-table-column>
       <el-table-column label="项目名称" align="center" prop="atvName">
         <template slot-scope="scope">
-          {{scope.row.atvName}}
+          {{ scope.row.atvName }}
         </template>
       </el-table-column>
       <el-table-column label="建设规模" align="center" prop="scale">
@@ -48,34 +78,47 @@
       </el-table-column>
       <el-table-column label="年度投资计划" align="center" prop="plan">
         <template slot-scope="scope">
-          {{scope.row.plan}}
+          {{ scope.row.plan }}
         </template>
       </el-table-column>
-      <el-table-column label="实际完成投资额" align="center" prop="reality" width="130px">
+      <el-table-column
+        label="实际完成投资额"
+        align="center"
+        prop="reality"
+        width="130px"
+      >
         <template slot-scope="scope">
-          {{scope.row.reality}}
+          {{ scope.row.reality }}
         </template>
       </el-table-column>
       <el-table-column label="年度投资完成百分比" align="center" prop="retio">
         <template slot-scope="scope">
-          {{scope.row.retio}}
+          {{ scope.row.retio }}
         </template>
       </el-table-column>
       <el-table-column label="形象进度" align="center" prop="schedule">
         <template slot-scope="scope">
-          {{scope.row.schedule}}
+          {{ scope.row.schedule }}
         </template>
       </el-table-column>
       <el-table-column label="项目审核状态" align="center" prop="status">
         <template slot-scope="scope">
           <el-tag v-if="scope.row.status == 0">草稿</el-tag>
           <el-tag v-else-if="scope.row.status == 1" type="info">审核中</el-tag>
-          <el-tag v-else-if="scope.row.status == 2" type="danger">审核拒绝</el-tag>
-          <el-tag v-else-if="scope.row.status == 3" type="success">已审核</el-tag>
+          <el-tag v-else-if="scope.row.status == 2" type="danger"
+            >审核拒绝</el-tag
+          >
+          <el-tag v-else-if="scope.row.status == 3" type="success"
+            >已审核</el-tag
+          >
         </template>
       </el-table-column>
 
-      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+      <el-table-column
+        label="操作"
+        align="center"
+        class-name="small-padding fixed-width"
+      >
         <template slot-scope="scope">
           <el-button
             size="mini"
@@ -83,41 +126,56 @@
             @click="handleUpdate(scope.row)"
             v-hasPermi="['business:ARTICLE:edit']"
             v-if="scope.row.status == 0 || scope.row.status == 2"
-          >修改</el-button>
+            >修改</el-button
+          >
+          <el-button
+            size="mini"
+            type="text"
+            @click="handleTask(scope.row)"
+            v-hasPermi="['business:ARTICLE:edit']"
+            v-if="scope.row.status == 0 || scope.row.status == 2"
+            >提交审核</el-button
+          >
           <el-button
             size="mini"
             type="text"
             @click="showEnterData(scope.row)"
             v-hasPermi="['business:ARTICLE:edit']"
-          >数据填报</el-button>
+            >数据填报</el-button
+          >
         </template>
       </el-table-column>
     </el-table>
 
     <pagination
-      v-show="total>0"
+      v-show="total > 0"
       :total="total"
       :page.sync="queryParams.pageNum"
       :limit.sync="queryParams.pageSize"
       @pagination="getList"
     />
-
   </div>
 </template>
 
 <script>
-import { listARTICLE, getARTICLE, delARTICLE, addARTICLE, updateARTICLE } from "@/api/portal/ARTICLE/ARTICLE.js";
-import edit from './edit.vue'
+import {
+  listARTICLE,
+  getARTICLE,
+  delARTICLE,
+  addARTICLE,
+  updateARTICLE,
+} from "@/api/portal/ARTICLE/ARTICLE.js";
+import edit from "./edit.vue";
 import enterData from "./enterData.vue";
 export default {
   name: "ARTICLE",
   data() {
     return {
-      statusList:[
-        { label:'已保存' , value:0 },
-        { label:'审核中' , value:1 },
-        { label:'审核驳回' , value:2 },
-        { label:'已审核' , value:3 },
+      statusList: [
+        { label: "已保存", value: 0 },
+        { label: "审核中", value: 1 },
+        { label: "审核驳回", value: 2 },
+        { label: "已审核", value: 3 },
       ],
       // 根路径
       baseURL: process.env.VUE_APP_BASE_API,
@@ -158,29 +216,34 @@ export default {
         plan: null,
         reality: null,
         retio: null,
-        schedule: null
+        schedule: null,
       },
-      
     };
   },
   created() {
     this.getList();
   },
   methods: {
-    showEnterData(row){
+    showEnterData(row) {
       const id = row.id || this.ids;
-      this.iframe({ obj: enterData, param: { id: id }, title: '数据填报', width: '1050px', height: '80%' });
+      this.iframe({
+        obj: enterData,
+        param: { id: id },
+        title: "数据填报",
+        width: "1050px",
+        height: "80%",
+      });
     },
     // 多选框选中数据
     handleSelectionChange(selection) {
-      this.ids = selection.map(item => item.id);
+      this.ids = selection.map((item) => item.id);
       this.single = selection.length !== 1;
       this.multiple = !selection.length;
     },
     /** 查询重点项目管理列表 */
     getList() {
       this.loading = true;
-      listARTICLE(this.queryParams).then(response => {
+      listARTICLE(this.queryParams).then((response) => {
         this.ARTICLEList = response.rows;
         this.total = response.total;
         this.loading = false;
@@ -201,25 +264,49 @@ export default {
       this.resetForm("queryForm");
       this.handleQuery();
     },
-     /** 新增按钮操作 */
-     handleAdd() {
-      this.iframe({ obj: edit, param: {}, title: '添加重点项目', width: '1050px', height: '80%' });
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.iframe({
+        obj: edit,
+        param: {},
+        title: "添加重点项目",
+        width: "1050px",
+        height: "80%",
+      });
     },
     /** 修改按钮操作 */
     handleUpdate(row) {
       const id = row.id || this.ids;
-      this.iframe({ obj: edit, param: { id: id }, title: '修改重点项目', width: '1050px', height: '80%' });
+      this.iframe({
+        obj: edit,
+        param: { id: id },
+        title: "修改重点项目",
+        width: "1050px",
+        height: "80%",
+      });
+    },
+    handleTask(row) {
+      row.status = 1;
+      console.log(row);
+      addARTICLE(this.form).then((response) => {
+        this.$modal.msgSuccess("提交审核成功");
+        this.getList();
+      });
     },
     /** 删除按钮操作 */
     handleDelete(row) {
       const ids = row.id || this.ids;
-      this.$modal.confirm('是否确认删除?').then(function() {
-        return delARTICLE(ids);
-      }).then(() => {
-        this.getList();
-        this.$modal.msgSuccess("删除成功");
-      }).catch(() => {});
+      this.$modal
+        .confirm("是否确认删除?")
+        .then(function () {
+          return delARTICLE(ids);
+        })
+        .then(() => {
+          this.getList();
+          this.$modal.msgSuccess("删除成功");
+        })
+        .catch(() => {});
     },
-  }
+  },
 };
 </script>

+ 80 - 0
src/views/ARTICLE/task/index.vue

@@ -0,0 +1,80 @@
+<template>
+  <div>
+    <el-tabs v-model="activeName">
+      <el-tab-pane label="详细信息" name="详细信息">
+        <el-descriptions border>
+          <el-descriptions-item label="项目名称">{{
+            taskList.atvName
+          }}</el-descriptions-item>
+          <el-descriptions-item label="建设规模">
+            <el-tag v-if="taskList.scale == 1" type="success">小型</el-tag>
+            <el-tag v-else-if="taskList.scale == 2" type="success">中型</el-tag>
+            <el-tag v-else-if="taskList.scale == 3" type="success">大型</el-tag>
+          </el-descriptions-item>
+          <el-descriptions-item label="建设内容">{{
+            taskList.content
+          }}</el-descriptions-item>
+          <el-descriptions-item label="年度投资计划">{{
+            taskList.plan
+          }}</el-descriptions-item>
+          <el-descriptions-item label="审核状态">
+            <el-tag v-if="taskList.status == 1" type="success">同意</el-tag>
+            <el-tag v-else-if="taskList.status == 2" type="danger">驳回</el-tag>
+            <el-tag v-else-if="taskList.status == 3" type="info">退回</el-tag>
+            <el-tag v-else-if="taskList.status == 0">待审核</el-tag>
+          </el-descriptions-item>
+          <el-descriptions-item label="实际投资金额">{{
+            taskList.comments ? taskList.comments : "无"
+          }}</el-descriptions-item>
+        </el-descriptions>
+
+      </el-tab-pane>
+      <el-tab-pane label="审批记录" name="审批记录">
+        <el-timeline>
+          <el-timeline-item
+            v-for="(item, index) in taskList.taskHisAction"
+            :timestamp="item.createTime"
+            placement="top"
+            :key="index + 'taskHisAction'"
+          >
+            <el-card>
+              <p>
+                {{ item.execId }} {{ item.acname }} 于 {{ item.createTime }}
+              </p>
+            </el-card>
+          </el-timeline-item>
+        </el-timeline>
+      </el-tab-pane>
+    </el-tabs>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      activeName: "详细信息",
+      // 根路径
+      baseURL: process.env.VUE_APP_BASE_API,
+      typeList: [
+        { label: "要闻咨询", value: "1" },
+        { label: "政策法规", value: "2" },
+        { label: "通知公告", value: "3" },
+        { label: "政策解读", value: "4" },
+      ],
+      fileList: [],
+      BigImgVisible: false,
+    };
+  },
+  props: ["taskList"],
+  created(){
+    console.log(this.taskList);
+  },
+  methods: {
+
+  },
+};
+</script>
+
+<style>
+</style>

+ 4 - 2
src/views/task/index.vue

@@ -62,7 +62,7 @@
       <component :is="componentUrl" :taskList="taskList" ref="componentSH"></component>
       <el-dialog width="60%" :title="subTitle + '审核'" :visible.sync="innerVisible" append-to-body center @close="qx()">
         <el-form :model="subForm" :rules="subFormRules" label-width="100px" ref="extaskform">
-          <el-form-item label="审核意见" prop="comments">
+          <el-form-item label="审核意见">
             <el-input type="textarea" v-model="subForm.comments" placeholder="请输入审核意见"></el-input>
           </el-form-item>
         </el-form>
@@ -91,6 +91,7 @@
 import newsTask from '@/views/news/task/index.vue';
 import couTask from '@/views/COUNSELINGMESSAGE/task/index.vue';
 import questionService from '@/views/QUESTION/questionService.vue';
+import articleTask from '@/views/ARTICLE/task/index.vue'
 
 import {
   listINSTACTIONTASK,
@@ -109,7 +110,8 @@ export default {
   components: {
     newsTask,
     couTask,
-    questionService
+    questionService,
+    articleTask
   },
   data() {
     return {