18513069273 4 år sedan
förälder
incheckning
613daa6e35

BIN
public/img/bianji.png


BIN
public/img/chakan.png


BIN
public/img/edit.png


BIN
public/img/fujian.png


BIN
public/img/header-add.png


BIN
public/img/shanchu.png


BIN
public/img/sousuo.png


+ 94 - 15
src/views/contractManagement/purchaseContract.vue

@@ -10,7 +10,18 @@
           v-hasPermission="
             `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
           "
-          >添加</ws-button
+          ><img
+            width="13"
+            height="13"
+            style="
+              vertical-align: text-top;
+              position: relative;
+              top: 2px;
+              left: -4px;
+            "
+            src="../../../public/img/header-add.png"
+            alt=""
+          />添加</ws-button
         >
         <ws-button
           @click="exportlist()"
@@ -64,13 +75,24 @@
         ></ws-input>
         <!-- v-hasPermission="'procurement.sparepart.directShip'" -->
         <ws-button
+          class="find"
           type="primary"
           @click="find()"
           v-hasPermission="
             `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
           "
-          >查找</ws-button
-        >
+          ><img
+            width="16"
+            height="16"
+            style="
+              vertical-align: text-top;
+              position: relative;
+              top: 0px;
+              left: -8px;
+            "
+            src="../../../public/img/sousuo.png"
+            alt=""
+        /></ws-button>
       </template>
     </BaseHeaderLayout>
     <el-table
@@ -99,6 +121,9 @@
           <span v-if="scope.row.grade == '三等品'" class="third-class">{{
             scope.row.grade
           }}</span>
+          <span v-if="scope.row.grade == '等外'" class="substandard">{{
+            scope.row.grade
+          }}</span>
         </template>
       </el-table-column>
       <el-table-column prop="weight" label="重量(吨)"> </el-table-column>
@@ -108,6 +133,11 @@
       <el-table-column prop="buyer" label="买方"> </el-table-column>
       <el-table-column prop="seller" label="卖方"> </el-table-column>
       <el-table-column prop="imperfectGrain" label="已完成(吨)">
+        <template slot-scope="scope">
+          <span style="color: #5473e8; font-weight: 600">{{
+            scope.row.imperfectGrain
+          }}</span>
+        </template>
       </el-table-column>
       <el-table-column prop="status" label="状态">
         <template slot-scope="scope">
@@ -175,20 +205,37 @@
           <!-- <i @click="fujian(scope.row)" class="el-icon-paperclip iconCss"></i> -->
         </template>
       </el-table-column>
-      <el-table-column prop="address" label="操作" width="300">
+      <el-table-column prop="address" label="操作" width="200">
         <template slot-scope="scope">
-          <el-button
-            type="success"
-            size="small"
+          <img
+            width="16"
+            height="16"
+            style="vertical-align: text-top; margin: 0 6px"
+            src="../../../public/img/chakan.png"
             @click="handleExamine(scope.row)"
-            >查看</el-button
-          >
-          <el-button type="primary" size="small" @click="handleEdit(scope.row)"
-            >编辑</el-button
-          >
-          <el-button type="danger" size="small" @click="handleDelete(scope.row)"
-            >删除</el-button
-          >
+            alt=""
+          />
+          <img
+            width="17"
+            height="16"
+            style="vertical-align: text-top; margin: 0 6px"
+            src="../../../public/img/bianji.png"
+            @click="handleEdit(scope.row)"
+            alt=""
+          />
+          <img
+            width="16"
+            height="17"
+            style="
+              vertical-align: text-top;
+              position: relative;
+              top: -1px;
+              margin: 0 6px;
+            "
+            src="../../../public/img/shanchu.png"
+            @click="handleDelete(scope.row)"
+            alt=""
+          />
         </template>
       </el-table-column>
     </el-table>
@@ -309,9 +356,11 @@ export default {
     },
     handleSizeChange(val) {
       console.log(`每页 ${val} 条`)
+      this.pageSize = val
       this.getList()
     },
     handleCurrentChange(val) {
+      this.currentPage = val
       console.log(`当前页: ${val}`)
       this.getList()
     },
@@ -426,6 +475,7 @@ export default {
         })
     },
     find() {
+      this.currentPage = 1
       this.getList()
     },
     async exportlist() {
@@ -487,6 +537,25 @@ export default {
 }
 </script>
 <style lang="scss" scoped>
+/deep/.base_header_layout .grid-content.right .find.el-button--primary {
+  width: 30px;
+  margin-left: -10px;
+  border-top-left-radius: 0px;
+  border-bottom-left-radius: 0px;
+}
+.el-button--primary {
+  background-color: #5878e8;
+  border-color: #5878e8;
+}
+.el-button--default {
+  border: 1px solid #5473e8;
+  color: #5473e8;
+}
+.warning {
+  width: 100%;
+  height: 2px;
+  background: red;
+}
 .executory,
 .inExecution,
 .done {
@@ -524,6 +593,12 @@ export default {
   padding: 3px;
   border-radius: 2px;
 }
+.substandard {
+  background: linear-gradient(90deg, #b2b4bb, #ced0d5);
+  color: #fff;
+  padding: 3px;
+  border-radius: 2px;
+}
 .wrap {
   width: 400px;
   position: absolute;
@@ -614,6 +689,10 @@ export default {
 .findValue {
   margin: 0 10px;
 }
+/deep/.findValue .el-input__inner {
+  border-top-right-radius: 0px;
+  border-bottom-right-radius: 0px;
+}
 .button-container {
   display: flex;
   flex-wrap: nowrap;

+ 32 - 2
src/views/contractManagement/salesContract.vue

@@ -91,6 +91,16 @@
       <el-table-column prop="buyer" label="买方"> </el-table-column>
       <el-table-column prop="seller" label="卖方"> </el-table-column>
       <el-table-column prop="imperfectGrain" label="已完成(吨)">
+        <template slot-scope="scope">
+          <span v-if="scope.row.proportion >= 90" style="color: red">{{
+            scope.row.imperfectGrain
+          }}</span>
+          <span
+            v-if="scope.row.proportion < 90"
+            style="color: #5473e8; font-weight: 600"
+            >{{ scope.row.imperfectGrain }}</span
+          >
+        </template>
       </el-table-column>
       <el-table-column prop="status" label="状态">
         <template slot-scope="scope">
@@ -300,15 +310,16 @@ export default {
     },
     handleSizeChange(val) {
       console.log(`每页 ${val} 条`)
+      this.pageSize = val
       this.getList()
     },
     handleCurrentChange(val) {
+      this.currentPage = val
       console.log(`当前页: ${val}`)
       this.getList()
     },
     uploadSuccess(data, files, url) {
       console.log(data, files, url)
-
       // this.deptBudgetList.
       // this.formData.append('files', files)
       // this.feedbackObj.uploadNameAttachment = data.appendixName
@@ -338,6 +349,21 @@ export default {
       })
         .toPromise()
         .then((response) => {
+          for (var i = 0; i < response.records.length; i++) {
+            if (
+              response.records[i].imperfectGrain != '' &&
+              response.records[i].weight != ''
+            ) {
+              response.records[i].proportion =
+                Math.floor(
+                  (response.records[i].imperfectGrain /
+                    response.records[i].weight) *
+                    10000
+                ) / 100
+            } else {
+              response.records[i].proportion = 0
+            }
+          }
           this.tableData = response
           this.deptCircularPage.currentPage = response.current
           this.deptCircularPage.pageSize = response.size
@@ -364,7 +390,7 @@ export default {
       }
     },
     find() {
-      console.log(this)
+      this.currentPage = 1
       this.getList()
     },
     editClick(row) {
@@ -665,4 +691,8 @@ export default {
     padding: 0 !important;
   }
 }
+/deep/.el-table .el-table__header .cell,
+/deep/.el-table .el-table__body .cell {
+  text-align: center;
+}
 </style>

+ 1 - 1
src/views/contractManagement/salesContractExamine.vue

@@ -230,7 +230,7 @@ export default {
     }
   },
 
-  created() {
+  activated() {
     this.status = this.$route.query.status
     this.loaddata()
     this.showType = this.isShow