Explorar el Código

Merge branch 'purchaseDev' of http://172.16.100.139/new-business/drp-web into purchaseDev

002390 hace 1 año
padre
commit
3e5061dcc4

+ 8 - 0
src/api/business/ehr/pm/performance.js

@@ -58,4 +58,12 @@ export function getNextMonthId() {
     url: '/ehr/pm/performance/getNextMonthId',
     method: 'get'
   })
+}
+
+// 删除绩效
+export function delPerformance(id) {
+  return request({
+    url: '/ehr/pm/performance/' + id,
+    method: 'delete'
+  })
 }

+ 8 - 0
src/api/business/ehr/pm/stage.js

@@ -113,4 +113,12 @@ export function createPm(data) {
     method: 'post',
     data: data
   })
+}
+
+// 查询指定周期各阶段的绩效数量
+export function stageCount(id) {
+  return request({
+    url: '/ehr/pm/stage/stageCount/' + id,
+    method: 'get'
+  })
 }

+ 8 - 7
src/views/business/ehr/pm/mark/detail.vue

@@ -6,7 +6,7 @@
         <div style="float: right; padding: 3px 0" type="text">
           <el-button size="mini" plain @click="btnBack">返回</el-button>
           <el-button size="mini" plain @click="btnTurnDown(1)" v-if="flow.status == 0">驳回</el-button>
-          <el-button size="mini" type="primary" plain @click="btnverify(2)" v-if="flow.status == 0">评写完成</el-button>
+          <el-button size="mini" type="primary" plain @click="btnverify(2)" v-if="flow.status == 0">提交</el-button>
         </div>
       </div>
       <div v-loading="loading">
@@ -38,24 +38,25 @@
           <el-button size="mini" @click="btnUnfold">{{isUnfold == true ? "收起" : "展开"}}</el-button>
         </div> -->
         <el-table size="mini"  :data="form.performanceItem" show-summary :summary-method="getSummaries" border>
+          <el-table-column type="index" width="50" label="序号"/>
           <el-table-column width="100" :show-overflow-tooltip="!isUnfold" label="评估方面" align="center" prop="aspect">
             <template slot-scope="scope">
               <dict-tag :options="dict.type.ehr_pm_aspect" :value="scope.row.aspect"/>
             </template>
           </el-table-column>
           <el-table-column width="100" :show-overflow-tooltip="!isUnfold" label="评估指标" align="center" prop="target" />
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="评估说明" align="center" prop="instructions">
+          <el-table-column width="80" label="权重" align="center" prop="weight"/>
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="指标说明" align="center" prop="instructions">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.instructions}}</div>
             </template>
           </el-table-column>
-          <el-table-column width="100" label="角色" align="center" prop="role">
+          <!-- <el-table-column width="100" label="角色" align="center" prop="role">
             <template slot-scope="scope">
               <dict-tag :options="dict.type.ehr_pm_role" :value="scope.row.role"/>
             </template>
-          </el-table-column>
-          <el-table-column width="80" label="权重" align="center" prop="weight"/>
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="绩效标准" align="center" prop="standard">
+          </el-table-column> -->
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="评分标准" align="center" prop="standard">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.standard}}</div>
             </template>
@@ -163,7 +164,7 @@ export default {
       const { columns, data } = param;
       let val = data.reduce((sum, e) => sum + Number(e.weight || 0), 0);
       this.weightSum = val;
-      return ['合计','','','','',val,'','',this.form.saMark,'',this.form.ldMark];
+      return ['合计','','',val,'','','',this.form.saMark,'',this.form.ldMark];
     },
     //驳回
     btnTurnDown(){

+ 1 - 1
src/views/business/ehr/pm/performance/btnApproveLog.vue

@@ -15,7 +15,7 @@
             <dict-tag :options="dict.type.ehr_pm_flow_status" :value="scope.row.status"/>
           </template>
         </el-table-column>
-        <el-table-column label="结果" align="center" prop="result" />
+        <el-table-column label="意见" align="center" prop="result" />
       </el-table>
     </el-dialog>
   </div>

+ 40 - 76
src/views/business/ehr/pm/performance/detail.vue

@@ -53,18 +53,18 @@
             </template>
           </el-table-column>
           <el-table-column width="100" :show-overflow-tooltip="!isUnfold" label="评估指标" align="center" prop="target" />
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="评估说明" align="center" prop="instructions">
+          <el-table-column width="80" label="权重(%)" align="center" prop="weight"/>
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="指标说明" align="center" prop="instructions">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.instructions}}</div>
             </template>
           </el-table-column>
-          <el-table-column width="100" label="角色" align="center" prop="role">
+          <!-- <el-table-column width="100" label="角色" align="center" prop="role">
             <template slot-scope="scope">
               <dict-tag :options="dict.type.ehr_pm_role" :value="scope.row.role"/>
             </template>
-          </el-table-column>
-          <el-table-column width="80" label="权重(%)" align="center" prop="weight"/>
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="绩效标准" align="center" prop="standard">
+          </el-table-column> -->
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="评分标准" align="center" prop="standard">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.standard}}</div>
             </template>
@@ -113,10 +113,18 @@
         <el-form-item label="评估指标" prop="target">
           <el-input v-model="rowData.target"></el-input>
         </el-form-item>
-        <el-form-item label="评估说明" prop="instructions">
+        <el-form-item label="加/减分项" prop="asItem">
+          <el-checkbox v-model="rowData.asItem" @change="handleCheckedChange"></el-checkbox>
+        </el-form-item>
+        <el-form-item label="权重(%)" prop="weight" v-if="!rowData.asItem">
+          <el-input  v-model.number="rowData.weight" v-only-number="{max:100,min:0,precision:0}" size="mini">
+            <i slot="suffix" style="color: #000;font-style:normal;margin-right: 10px;">%</i>
+          </el-input>
+        </el-form-item>
+        <el-form-item label="指标说明" prop="instructions">
           <el-input type="textarea" v-model="rowData.instructions" :rows="5"></el-input>
         </el-form-item>
-        <el-form-item label="角色" prop="role">
+        <!-- <el-form-item label="角色" prop="role">
           <el-select v-model="rowData.role" >
             <el-option
               v-for="dict in dict.type.ehr_pm_role"
@@ -125,16 +133,8 @@
               :value="dict.value"
             ></el-option>
           </el-select>
-        </el-form-item>
-        <el-form-item label="加/减分项" prop="asItem">
-          <el-checkbox v-model="rowData.asItem" @change="handleCheckedChange"></el-checkbox>
-        </el-form-item>
-        <el-form-item label="权重(%)" prop="weight" v-if="!rowData.asItem">
-          <el-input  v-model.number="rowData.weight" v-only-number="{max:100,min:0,precision:0}" size="mini">
-            <i slot="suffix" style="color: #000;font-style:normal;margin-right: 10px;">%</i>
-          </el-input>
-        </el-form-item>
-        <el-form-item label="绩效标准" prop="standard">
+        </el-form-item> -->
+        <el-form-item label="评分标准" prop="standard">
           <el-input type="textarea" v-model="rowData.standard" :rows="5"></el-input>
         </el-form-item>
         <el-form-item label="数据来源" prop="source">
@@ -334,7 +334,7 @@ export default {
       const { columns, data } = param;
       let val = data.reduce((sum, e) => sum + Number(e.weight || 0), 0);
       this.weightSum = val;
-      return ['合计','','','','',val,'','',this.form.saMark,'',this.form.ldMark];
+      return ['合计','','',val,'','','',this.form.saMark,'',this.form.ldMark];
     },
     //提交
     btnSubmit(){
@@ -343,35 +343,17 @@ export default {
           this.$modal.msgWarning("权重不为100%无法提交!");
           return;
         }
-        this.$confirm("确认提交吗?", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "info",
-          beforeClose: async (action, instance,done) => {
-            if (action === "confirm") {
-              instance.confirmButtonLoading = true;
-              instance.confirmButtonText = "执行中...";
-              try {
-                const { msg, code } = await fillinFinish(this.form);
-                if (code === 200) {
-                  this.$modal.msgSuccess("提交成功");
-                  await this.fetchPerformance(this.id);
-                }
-              } catch (err) {
-                // catch
-                console.error(err);
-                instance.confirmButtonText = "确认";
-              } finally {
-                // finally
-                instance.confirmButtonLoading = false;
-                done();
-              }
-            }else{
-              done();
-            }
-          },
-        }).then(() => {})
-        .catch(() => {});
+        let that = this;
+        this.$modal.confirm('确认提交吗?').then(async function() {
+          that.loading = true;
+          return await fillinFinish(that.form);
+        }).then(() => {
+          that.fetchPerformance(that.id);
+          that.$modal.msgSuccess("提交成功");
+          that.loading = false;
+        }).catch(() => {
+          that.loading = false;
+        });
       }
       if(this.form.status == '3'){
         let v = false;
@@ -388,35 +370,17 @@ export default {
           this.$modal.msgWarning("请填写个人总结再提交!");
           return;
         }
-        this.$confirm("确认提交吗?", "提示", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "info",
-          beforeClose: async (action, instance,done) => {
-            if (action === "confirm") {
-              instance.confirmButtonLoading = true;
-              instance.confirmButtonText = "执行中...";
-              try {
-                const { msg, code } = await selfestimate(this.form);
-                if (code === 200) {
-                  this.$modal.msgSuccess("提交成功");
-                  await this.fetchPerformance(this.id);
-                }
-              } catch (err) {
-                // catch
-                console.error(err);
-                instance.confirmButtonText = "确认";
-              } finally {
-                // finally
-                instance.confirmButtonLoading = false;
-                done();
-              }
-            }else{
-              done();
-            }
-          },
-        }).then(() => {})
-        .catch(() => {});
+        let that = this;
+        this.$modal.confirm('确认提交吗?').then(async function() {
+          that.loading = true;
+          return await selfestimate(that.form);
+        }).then(() => {
+          that.fetchPerformance(that.id);
+          that.$modal.msgSuccess("提交成功");
+          that.loading = false;
+        }).catch(() => {
+          that.loading = false;
+        });
       }
     },
     //设置明细

+ 3 - 1
src/views/business/ehr/pm/performance/index.vue

@@ -61,7 +61,9 @@
         <el-badge :value="markCount" class="item" style="margin: 0 10px"  v-if="markCount > 0">
           <el-button type="primary" size="mini" @click="btnPmMark">待评分</el-button>
         </el-badge>
-        <el-button type="primary" size="mini" @click="btnGradeAdjust" v-if="adjustCount > 0">等级调整({{adjustCount}})</el-button>
+        <el-badge :value="adjustCount" class="item" style="margin: 0 10px"  v-if="adjustCount> 0">
+          <el-button type="primary" size="mini" @click="btnGradeAdjust">待等级调整</el-button>
+        </el-badge>
         <el-button type="primary" size="mini" @click="btnCurrentMonth">本月绩效</el-button>
         <el-button type="primary" size="mini" @click="btnNextMonth">下月绩效</el-button>
       </div>

+ 9 - 2
src/views/business/ehr/pm/stagecontrol/btnCreatePm.vue

@@ -1,6 +1,6 @@
 <template>
-  <div>
-    <el-button size="mini" @click="click">生成绩效</el-button>
+  <div class="createPm">
+    <el-button size="mini" icon="el-icon-plus" @click="click">生成绩效</el-button>
     <el-dialog title="生成绩效" :visible.sync="open" width="1000px" :close-on-click-modal="false">
       <el-form :model="queryParams" ref="queryForm" size="mini" :inline="true">
         <el-form-item label="员工" prop="staffName">
@@ -121,4 +121,11 @@ export default {
   },
 };
 </script>
+<style>
+.createPm{
+  display: flex;
+  align-items: center;
+  justify-content: end;
+}
+</style>
 

+ 109 - 203
src/views/business/ehr/pm/stagecontrol/detail.vue

@@ -13,7 +13,6 @@
           <el-button size="mini" type="primary" :loading="loading" plain @click="btnCloseGradeAdjust" v-if="form.stage == '5' && form.isAdjust == 'Y' && form.isSalary == 'N'">关闭等级调整</el-button>
           <el-button size="mini" type="primary" :loading="loading" plain @click="btnAdjustMark" v-if="form.stage == '5' && form.isSalary == 'N'">分数调整</el-button>
           <el-button size="mini" type="primary" :loading="loading" plain @click="btnCendToSalary" v-if="form.stage == '5' && form.isSalary == 'N'">过数到薪资</el-button>
-          <CreatePmDialog style="margin: 0 10px" :stageId="form.id" v-if="form.isPublish == 'Y' && form.stage != '5'"></CreatePmDialog>
           <el-button size="mini" plain @click="btnPreviou">上一个</el-button>
           <el-button size="mini" plain @click="btnNext">下一个</el-button>
         </div>
@@ -27,8 +26,8 @@
               <div>{{ dict.label }}</div>
             </div>
           </el-descriptions-item>
-          <el-descriptions-item label="预计填写结束时间">{{form.month}}</el-descriptions-item>
-          <el-descriptions-item label="预计评分结束时间">{{form.month}}</el-descriptions-item>
+          <el-descriptions-item label="预计填写结束时间">{{form.fillinEndtiem}}</el-descriptions-item>
+          <el-descriptions-item label="预计评分结束时间">{{form.markEndtiem}}</el-descriptions-item>
         </el-descriptions>
         <el-form size="mini" label-position="right" ref="form" :model="form" :rules="formRules" :inline="true" class="demo-form-inline" v-if="pageState != 'see'">
           <el-row>
@@ -45,7 +44,7 @@
             </el-col>
             <el-col span="6">
               <el-form-item label="状态" prop="stage">
-                <el-select size="mini" v-model="form.stage" placeholder="" :disabled="form.isPublish == 'Y'" >
+                <el-select size="mini" v-model="form.stage" placeholder="" disabled>
                   <el-option
                     v-for="dict in dict.type.ehr_pm_status"
                     :key="dict.value"
@@ -57,23 +56,25 @@
             </el-col>
             <el-col span="6">
               <el-form-item label="预计填写结束时间" prop="yearMonth">
-                <el-date-picker type="date" value-format="yyyy-MM" v-model="form.month">
+                <el-date-picker type="date" value-format="yyyy-MM-dd" v-model="form.fillinEndtiem">
                 </el-date-picker>
               </el-form-item>
             </el-col>
             <el-col span="6">
               <el-form-item label="预计评分结束时间" prop="yearMonth">
-                <el-date-picker type="date" value-format="yyyy-MM" v-model="form.month">
+                <el-date-picker type="date" value-format="yyyy-MM-dd" v-model="form.markEndtiem">
                 </el-date-picker>
               </el-form-item>
             </el-col>
           </el-row>
         </el-form>
-        <el-tabs v-model="activeName" v-if="form.isPublish == 'Y'" @tab-click="btnTabs">
+        <el-tabs v-model="activeName" v-if="form.isPublish == 'Y'" @tab-click="btnTabs" v-show="pageState == 'see'">
           <el-tab-pane label="绩效列表" name="first">
-            绩效列表
+            <PmList :key="pmListKey" :stage="form"/>
+          </el-tab-pane>
+          <el-tab-pane label="等级参数" name="second">
+            <GcList :key="gcListKey" :stage="form"/>
           </el-tab-pane>
-          <el-tab-pane label="等级参数" name="second">等级参数</el-tab-pane>
         </el-tabs>
         <div class="footer">
           <el-button type="primary" size="mini" @click="btnEdit" v-if="pageState == 'see'">修改</el-button>
@@ -87,7 +88,8 @@
 </template>
 
 <script>
-import CreatePmDialog from './btnCreatePm.vue'
+import PmList from './pmList.vue'
+import GcList from './gcList.vue'
 import { getStage,addStage,updateStage,publishStage,fillinFinish,startSelfEvaluation,finishSelfEvaluation,openGradeAdjust,closeGradeAdjust,cendToSalary} from "@/api/business/ehr/pm/stage";
 
 export default {
@@ -98,7 +100,7 @@ export default {
     prop: 'isList',
     event: 'jugislist'
   },
-  components: {CreatePmDialog},
+  components: {PmList,GcList},
   data() {
     return {
       //id
@@ -119,7 +121,11 @@ export default {
       //页面状态
       pageState: null,
       //当前页签
-      activeName: 'first'
+      activeName: 'first',
+      //pmListKey
+      pmListKey: 0,
+      //gcListKey
+      gcListKey: 0,
     }
   },
   async created() {
@@ -159,6 +165,8 @@ export default {
       if(i > -1){
         let id = this.ids[i];
         this.fetchStage(id);
+        this.activeName = 'first';
+        this.pmListKey++;
       }else{
         this.$modal.msgSuccess("已经是当前页第一条了!");
       }
@@ -169,189 +177,95 @@ export default {
       if(i < this.ids.length){
         let id = this.ids[i];
         this.fetchStage(id);
+        this.activeName = 'first';
+        this.pmListKey++;
       }else{
         this.$modal.msgSuccess("已经是当前页最后一条了!");
       }
     },
     //发布
     btnPublish(){
-      this.$confirm("确认要发布吗?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await publishStage(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("发布成功");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要发布吗?').then(async function() {
+        that.loading = true;
+        return await publishStage(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("发布成功");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //填写结束
     btnFillinFinish(){
-      this.$confirm("确认要结束填写吗?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await fillinFinish(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("保存成功");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要结束填写吗?').then(async function() {
+        that.loading = true;
+        return await fillinFinish(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("保存成功");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //开始自评
     btnStartSelfEvaluation(){
-      this.$confirm("确认要开启自评吗?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await startSelfEvaluation(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("开启成功");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要开启自评吗?').then(async function() {
+        that.loading = true;
+        return await startSelfEvaluation(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("开启成功");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //结束自评
     btnFinishSelfEvaluation(){
-      this.$confirm("确认要结束评分吗?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await finishSelfEvaluation(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("结束成功");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要结束评分吗?').then(async function() {
+        that.loading = true;
+        return await finishSelfEvaluation(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("结束成功");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //开启等级调整
     btnOpenGradeAdjust(){
-      this.$confirm("确认要开启等级调整?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await openGradeAdjust(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("已开始");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要开启等级调整?').then(async function() {
+        that.loading = true;
+        return await openGradeAdjust(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("已开始");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //关闭等级调整
     btnCloseGradeAdjust(){
-      this.$confirm("确认要关闭等级调整?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await closeGradeAdjust(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("已关闭");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要关闭等级调整?').then(async function() {
+        that.loading = true;
+        return await closeGradeAdjust(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("已关闭");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //分数调整
     btnAdjustMark(){
@@ -359,33 +273,17 @@ export default {
     },
     //过数到薪资
     btnCendToSalary(){
-      this.$confirm("确认要同步到薪资绩效系数吗?", "提示", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "info",
-        beforeClose: async (action, instance,done) => {
-          if (action === "confirm") {
-            instance.confirmButtonLoading = true;
-            instance.confirmButtonText = "执行中...";
-            try {
-              const { msg, code } = await cendToSalary(this.form);
-              if (code === 200) {
-                this.$modal.msgSuccess("操作成功");
-                await this.fetchStage(this.id);
-              }
-            } catch (err) {
-              console.error(err);
-              instance.confirmButtonText = "确认";
-            } finally {
-              instance.confirmButtonLoading = false;
-              done();
-            }
-          }else{
-            done();
-          }
-        },
-      }).then(() => {})
-      .catch(() => {});
+      let that = this;
+      this.$modal.confirm('确认要同步到薪资绩效系数吗?').then(async function() {
+        that.loading = true;
+        return await cendToSalary(that.form);
+      }).then(() => {
+        that.fetchStage(that.id);
+        that.$modal.msgSuccess("操作成功");
+        that.loading = false;
+      }).catch(() => {
+        that.loading = false;
+      });
     },
     //修改
     btnEdit(){
@@ -424,8 +322,16 @@ export default {
         }
       });
     },
-    btnTabs(tab, event) {
-      console.log(tab, event);
+    //页签切换
+    btnTabs(e) {
+      switch (e.name) {
+        case "first":
+          break;
+        case "second":
+          break;
+        default:
+          break;
+      }
     },
   }
 }

+ 42 - 0
src/views/business/ehr/pm/stagecontrol/gcList.vue

@@ -0,0 +1,42 @@
+<template>
+  <div>
+    <el-table size="mini" height="500px" v-loading="loading" :data="listData">
+      <el-table-column label="编号" align="center" prop="id" />
+      <el-table-column label="名称" align="center" prop="name" />
+      <el-table-column label="小值" align="center" prop="min" />
+      <el-table-column label="大值" align="center" prop="max" />
+      <el-table-column label="系数" align="center" prop="coefficient" />
+    </el-table>
+  </div>
+</template>
+
+<script>
+import { getGradeconfig} from "@/api/business/ehr/pm/gradeconfig";
+export default {
+  name: "gcList",
+  props: ["stage"],
+  data() {
+    return {
+      // 表格数据
+      listData: [],
+      // 遮罩层
+      loading: true,
+    };
+  },
+  created() {
+    this.fetchList();
+  },
+  methods: {
+    //查询等级配置列表
+    fetchList() {
+      this.loading = true;
+      getGradeconfig(this.stage.gradeconfigId).then(response => {
+        console.log(response.data);
+        this.listData = response.data.gradeconfigItem;
+        this.loading = false;
+      });
+    },
+  },
+};
+</script>
+

+ 2 - 1
src/views/business/ehr/pm/stagecontrol/index.vue

@@ -38,6 +38,7 @@
               size="mini"
               type="text"
               @click="btnDelete(scope.row)"
+              v-if="scope.row.isPublish != 'Y'"
             >删除</el-button>
           </template>
         </el-table-column>
@@ -129,7 +130,7 @@ export default {
     },
     /** 删除 */
     btnDelete(row){
-      this.$modal.confirm('是否确认删除编号为"' + row.id + '"的数据项?这将会同时删除关联绩效').then(function() {
+      this.$modal.confirm('是否确认删除编号为"' + row.id + '"的数据项?').then(function() {
         return delStage(row.id);
       }).then(() => {
         this.getList();

+ 146 - 0
src/views/business/ehr/pm/stagecontrol/pmList.vue

@@ -0,0 +1,146 @@
+<template>
+  <div>
+    <el-form :model="queryParams" ref="queryForm" size="mini" :inline="true">
+      <el-row type="flex" justify="space-between">
+        <el-col :span="12">
+          <el-form-item label="状态" prop="status">
+            <el-select
+              size="mini"
+              v-model="queryParams.status"
+              placeholder=""
+              clearable
+            >
+              <el-option
+                v-for="dict in dict.type.ehr_pm_status"
+                :key="dict.value"
+                :label="dict.label"
+                :value="dict.value"
+              ></el-option>
+            </el-select>
+            
+          </el-form-item>
+          <el-form-item>
+            <el-button type="primary" icon="el-icon-search" size="mini" @click="btnSearch">搜索</el-button>
+            <el-button icon="el-icon-refresh" size="mini" @click="btnResetQuery">重置</el-button>
+          </el-form-item>
+        </el-col>
+        <el-col :span="12" >
+          <CreatePmDialog :stageId="stage.id"></CreatePmDialog>
+        </el-col>
+      </el-row>
+    </el-form>
+    <el-table size="mini" height="500px" v-loading="loading" :data="listData">
+      <el-table-column label="编号" align="center" prop="id" />
+      <el-table-column label="员工工号" align="center" prop="staff" />
+      <el-table-column label="员工名称" align="center" prop="staffName" />
+      <el-table-column label="部门" align="center" prop="deptName" show-overflow-tooltip/>
+      <el-table-column label="状态" align="center" prop="status" >
+        <template slot-scope="scope">
+          <dict-tag :options="dict.type.ehr_pm_status" :value="scope.row.status"/>
+        </template>
+      </el-table-column>
+      <el-table-column label="操作" fixed="right" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+            <el-button
+              size="mini"
+              type="danger"
+              icon="el-icon-delete-solid"
+              plain
+              @click="btnDel(scope.row)"
+            >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    <div>
+      <el-row type="flex" justify="space-between">
+        <el-col :span="12">
+          <el-descriptions :column="6">
+              <el-descriptions-item v-for="(objValue,key,index) of pmStatusNum" :label="key" v-if="objValue > 0">{{objValue}}</el-descriptions-item>
+          </el-descriptions>
+        </el-col>
+        <el-col :span="12">
+          <pagination
+            v-show="total>0"
+            :total="total"
+            :page.sync="queryParams.pageNum"
+            :limit.sync="queryParams.pageSize"
+            @pagination="getList"
+          />
+        </el-col>
+      </el-row>
+    </div>
+  </div>
+</template>
+
+<script>
+import { listPerformance,delPerformance} from "@/api/business/ehr/pm/performance";
+import { stageCount} from "@/api/business/ehr/pm/stage";
+import CreatePmDialog from './btnCreatePm.vue'
+export default {
+  name: "PmList",
+  dicts: ['ehr_pm_status',],
+  props: ["stage"],
+  components: {CreatePmDialog},
+  data() {
+    return {
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 5,
+        status: null,
+      },
+      // 总条数
+      total: 0,
+      // 表格数据
+      listData: [],
+      // 遮罩层
+      loading: true,
+      // 是否显示弹出层
+      open: false,
+      // 绩效状态对应的数量
+      pmStatusNum:[],
+    };
+  },
+  created() {
+    this.queryParams.sourceId = this.stage.id;
+    this.getList();
+    stageCount(this.stage.id).then(response => {
+      this.pmStatusNum = response.data;
+      console.log('this.pmStatusNum',this.pmStatusNum);
+    });
+  },
+  methods: {
+    /** 查询绩效列表 */
+    getList() {
+      this.loading = true;
+      listPerformance(this.queryParams).then(response => {
+        this.listData = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    /** 搜索按钮操作 */
+    async btnSearch() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    btnResetQuery() {
+      this.resetForm("queryForm");
+      this.dateRange = [];
+      this.treeValue = [];
+      this.btnSearch();
+    },
+    //删除绩效
+    btnDel(row){
+      this.$modal.confirm('是否确认删除' + row.staffName + '[' + row.staff + ']'+ this.stage.month +'月的绩效吗?').then(function() {
+        return delPerformance(row.id);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    }
+  },
+};
+</script>
+

+ 7 - 6
src/views/business/ehr/pm/verify/detail.vue

@@ -29,24 +29,25 @@
           <el-button size="mini" @click="btnUnfold">{{isUnfold == true ? "收起" : "展开"}}</el-button>
         </div> -->
         <el-table size="mini"  :data="form.performanceItem" show-summary :summary-method="getSummaries" border>
+          <el-table-column type="index" width="50" label="序号"/>
           <el-table-column width="100" :show-overflow-tooltip="!isUnfold" label="评估方面" align="center" prop="aspect">
             <template slot-scope="scope">
               <dict-tag :options="dict.type.ehr_pm_aspect" :value="scope.row.aspect"/>
             </template>
           </el-table-column>
           <el-table-column width="100" :show-overflow-tooltip="!isUnfold" label="评估指标" align="center" prop="target" />
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="评估说明" align="center" prop="instructions">
+          <el-table-column width="80" label="权重" align="center" prop="weight"/>
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="指标说明" align="center" prop="instructions">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.instructions}}</div>
             </template>
           </el-table-column>
-          <el-table-column width="100" label="角色" align="center" prop="role">
+          <!-- <el-table-column width="100" label="角色" align="center" prop="role">
             <template slot-scope="scope">
               <dict-tag :options="dict.type.ehr_pm_role" :value="scope.row.role"/>
             </template>
-          </el-table-column>
-          <el-table-column width="80" label="权重" align="center" prop="weight"/>
-          <el-table-column :show-overflow-tooltip="!isUnfold" label="绩效标准" align="center" prop="standard">
+          </el-table-column> -->
+          <el-table-column :show-overflow-tooltip="!isUnfold" label="评分标准" align="center" prop="standard">
             <template slot-scope="scope">
               <div style="white-space: pre-wrap;text-align: left">{{scope.row.standard}}</div>
             </template>
@@ -135,7 +136,7 @@ export default {
       const { columns, data } = param;
       let val = data.reduce((sum, e) => sum + Number(e.weight || 0), 0);
       this.weightSum = val;
-      return ['合计','','','','',val,'','',this.form.saMark,'',this.form.ldMark];
+      return ['合计','','',val,'','','',this.form.saMark,'',this.form.ldMark];
     },
     //驳回
     btnTurnDown(){