Browse Source

技术人员年度月平均工资也修改数据增加蓝色标识

ljb 11 months ago
parent
commit
640b91c173

+ 21 - 0
src/components/updated-text/index.vue

@@ -0,0 +1,21 @@
+<template>
+  <div class="updated-text">{{ text }}</div>
+</template>
+
+<script>
+export default {
+  name: "UpdatedText",
+  props: {
+    text: {
+      type: String,
+      default: ''
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+.updated-text {
+  color: blue;
+}
+</style>

+ 10 - 9
src/views/high-tech-person-sum-list/index.vue

@@ -10,6 +10,15 @@
     >
       <template slot="menuLeft">
         <el-button
+          type="danger"
+          size="small"
+          icon="el-icon-delete"
+          plain
+          @click="handleDelete"
+        >
+          删 除
+        </el-button>
+        <el-button
           type="success"
           size="small"
           plain
@@ -27,18 +36,10 @@
         >
           导出
         </el-button>
-        <el-button
-          type="danger"
-          size="small"
-          icon="el-icon-delete"
-          plain
-          @click="handleDelete"
-        >
-          删 除
-        </el-button>
         <div>
           <year-month-select v-model="params.yearAndMonth" :showMonth="false"></year-month-select>
         </div>
+        
       </template>
       
     </avue-crud>

+ 7 - 0
src/views/technician-month-avg-sales/index.vue

@@ -48,6 +48,11 @@
           <year-month-select v-model="params.yearAndMonth" :showMonth="false"></year-month-select>
         </div>
       </template>
+
+      <div v-for="key of watchUpdateKey" :slot="key" slot-scope="scope" :key="key">
+        <updated-text v-if="scope.row[key+'Edit'] === 1" :text="scope.row[key]"></updated-text>
+        <span v-else>{{ scope.row[key] }}</span>
+      </div>
       
     </avue-crud>
 
@@ -71,6 +76,7 @@
 import { getLastMonthData } from "@/api/technicianMonthAvgSales";
 import {exportBloByPost} from "@/api/common";
 import YearMonthSelect from "@/components/year-month-select";
+import UpdatedText from "@/components/updated-text";
 import moment from "moment";
 import NProgress from 'nprogress';
 import 'nprogress/nprogress.css';
@@ -82,6 +88,7 @@ import Decimal from "decimal.js";
 export default window.$crudCommon({
   components: {
     YearMonthSelect,
+    UpdatedText,
   },
   data() {
     return {