2
3
Переглянути джерело

前端: 日常评价列表字段样式

baichengfei 4 роки тому
батько
коміт
cd3d26fbc3

+ 9 - 3
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-basis/index.vue

@@ -54,9 +54,9 @@
         <el-table-column v-if="selectAllButtonBoolean" :selectable="selectableFun" type="selection"
                          width="55"></el-table-column>
 
-        <el-table-column label="操作" min-width="210" align="center" fixed>
+        <el-table-column label="操作" min-width="140" align="center" fixed>
           <template slot-scope="scope">
-            <el-button v-if="editeBoolean" type="text" title="编辑" size="small" icon="el-icon-edit"
+            <el-button v-if="editeBoolean && scope.row.Status <= 0" type="text" title="编辑" size="small" icon="el-icon-edit"
                        @click="onNavigateEvaluate(scope.row)">编辑
             </el-button>
             <el-button v-else type="text" title="编辑" size="small" icon="el-icon-edit"
@@ -84,7 +84,13 @@
                          v-if="column.prop != 'CreateOn'" :prop="column.prop" sortable min-width="140"
                          :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
-            <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop !== 'Status'">{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop === 'Status'">
+              <span v-if="scope.row[column.prop] == 0" style="color: #409EFF">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] == 8" style="color: #67C23A">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] < 0" style="color: #F56C6C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else style="color: #E6A23C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+            </div>
           </template>
         </el-table-column>
 

+ 9 - 3
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-goods/index.vue

@@ -54,9 +54,9 @@
         <el-table-column v-if="selectAllButtonBoolean" :selectable="selectableFun" type="selection"
                          width="55"></el-table-column>
 
-        <el-table-column label="操作" min-width="210" align="center" fixed>
+        <el-table-column label="操作" min-width="140" align="center" fixed>
           <template slot-scope="scope">
-            <el-button type="text" v-if="editeBoolean" title="编辑" size="small" icon="el-icon-edit"
+            <el-button type="text" v-if="editeBoolean && scope.row.Status <= 0" title="编辑" size="small" icon="el-icon-edit"
                        @click="onNavigateEvaluate(scope.row)">编辑
             </el-button>
             <el-button type="text" v-else size="small" icon="el-icon-edit" @click="onNavigateEvaluate(scope.row)">查看
@@ -83,7 +83,13 @@
                          v-if="column.prop != 'CreateOn'" :prop="column.prop" sortable min-width="140"
                          :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
-            <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop !== 'Status'">{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop === 'Status'">
+              <span v-if="scope.row[column.prop] == 0" style="color: #409EFF">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] == 8" style="color: #67C23A">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] < 0" style="color: #F56C6C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else style="color: #E6A23C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+            </div>
           </template>
         </el-table-column>
 

+ 9 - 3
src/dashoo.cn/frontend_web/src/pages/oilcontract/contract-service/index.vue

@@ -53,9 +53,9 @@
                 height="calc(100vh - 243px)" style="width: 100%" @sort-change="orderby" @selection-change="onSelectAll" v-loading="tableLoading">
         <el-table-column v-if="selectAllButtonBoolean" :selectable="selectableFun" type="selection"
                          width="55"></el-table-column>
-        <el-table-column label="操作" min-width="210" align="center" fixed>
+        <el-table-column label="操作" min-width="140" align="center" fixed>
           <template slot-scope="scope">
-            <el-button v-if="editeBoolean" type="text" title="编辑" size="small" icon="el-icon-edit"
+            <el-button v-if="editeBoolean && scope.row.Status <= 0" type="text" title="编辑" size="small" icon="el-icon-edit"
                        @click="onNavigateEvaluate(scope.row)">编辑
             </el-button>
             <el-button v-else type="text" title="编辑" size="small" icon="el-icon-edit"
@@ -83,7 +83,13 @@
                          v-if="column.prop != 'CreateOn'" :prop="column.prop" sortable min-width="140"
                          :label="column.label" align="center" show-overflow-tooltip>
           <template slot-scope="scope">
-            <div>{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop !== 'Status'">{{ columnFun(scope.row[column.prop], column.prop) }}</div>
+            <div v-if="column.prop === 'Status'">
+              <span v-if="scope.row[column.prop] == 0" style="color: #409EFF">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] == 8" style="color: #67C23A">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else-if="scope.row[column.prop] < 0" style="color: #F56C6C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+              <span v-else style="color: #E6A23C">{{ columnFun(scope.row[column.prop], column.prop) }}</span>
+            </div>
           </template>
         </el-table-column>