From 4d8049330f1378c87115a7fcb66265f815b49801 Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期三, 13 九月 2023 16:52:06 +0800
Subject: [PATCH] modified: src/assets/api/controller.js modified: src/components/view/standard-table/material.vue modified: src/components/view/standard-table/product.vue modified: src/components/view/standard-table/target.vue modified: src/components/view/standard-table/technology.vue modified: src/components/view/standard.vue
---
src/components/view/Processingproducts.vue | 572 +++++++++++++++++++++++++++++++++++++++-----------------
1 files changed, 394 insertions(+), 178 deletions(-)
diff --git a/src/components/view/Processingproducts.vue b/src/components/view/Processingproducts.vue
index 19630f9..a9dcf00 100644
--- a/src/components/view/Processingproducts.vue
+++ b/src/components/view/Processingproducts.vue
@@ -1,192 +1,408 @@
<template>
- <div>
- <div class="article-main" style="overflow: hidden;">
- <el-row>
- <el-col :span="12" style="line-height: 32px;">涓嶅悎鏍煎搧澶勭疆</el-col>
- <el-col :span="12" style="text-align: right;">
- <el-button icon="el-icon-download" size="mini" @click="()=>{}">瀵煎嚭</el-button>
- </el-col>
- </el-row>
- <div>
-
- <div style="margin-top: 10px;">
- <el-card shadow="hover" class="margin-30">
- <el-form ref="form" :model="searchform" label-width="80px">
- <el-row :gutter="25">
- <el-col :span="7" >
- <el-form-item label="浜у搧鍚嶇О:">
- <el-input v-model="searchform.name" placeholder="璇疯緭鍏�"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="7" >
- <el-form-item label="瑙勬牸鍨嬪彿:">
- <el-input v-model="searchform.stude" placeholder="璇疯緭鍏�"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-button size="default" @click="">閲嶇疆</el-button>
- <el-button type="primary" size="default" style="background:0, 78, 162 ;" @click="getDetailInfo">鏌ヨ</el-button>
-
- </el-col>
- </el-row>
- </el-form>
- </el-card>
- </div>
-
- <div style="margin-top: 30px;">
- <el-card shadow="hover" class="margin-30">
- <el-table
- ref="multipleTable"
- :data="tableData"
- tooltip-effect="dark"
- style="width: 100%"
- @selection-change="handleSelectionChange">
- <el-table-column
- type="selection"
- width="55">
- </el-table-column>
- <el-table-column
- label="鏃ユ湡"
- width="120">
- <template slot-scope="scope">{{ scope.row.date }}</template>
- </el-table-column>
- <el-table-column
- prop="name"
- label="濮撳悕"
- width="120">
- </el-table-column>
- <el-table-column
- prop="address"
- label="鍦板潃"
- show-overflow-tooltip>
- </el-table-column>
- </el-table>
- </el-card>
- <el-col style="height: 50px;display: flex;align-items: center;justify-content: right;">
- <el-pagination
- @size-change="handleSizeChange"
- @current-change="handleCurrentChange"
- :current-page="4"
- :page-sizes="[1,10, 20, 30, 50]"
- :page-size="4"
- layout="total, sizes, prev, pager, next, jumper"
- :total="countSize">
- </el-pagination>
- </el-col>
- </div>
- </div>
+ <div class="unqualifiedBox">
+ <el-row>
+ <el-col :span="12" style="line-height: 32px;">涓嶅悎鏍煎搧澶勭疆</el-col>
+ <el-col :span="12" style="text-align: right;">
+ <el-button icon="el-icon-download" size="mini" @click="() => {}"
+ >瀵煎嚭</el-button
+ >
+ </el-col>
+ </el-row>
+ <div style="margin-top: 10px;">
+ <el-card shadow="hover" class="margin-30" style="height: 80px;">
+ <div class="choose">
+ <span>浜у搧鍚嶇О锛�</span>
+ <el-input
+ size="small"
+ v-model="search.productName"
+ style="width: 224px;margin-right: 30px;"
+ placeholder="璇疯緭鍏�"
+ clearable
+ ></el-input>
+ <span>瑙勬牸鍨嬪彿锛�</span>
+ <el-input
+ size="small"
+ v-model="search.specificationModel"
+ style="width: 224px;margin-right: 30px;"
+ placeholder="璇疯緭鍏�"
+ clearable
+ ></el-input>
+ <span>浜у搧澶х被锛�</span>
+ <el-select
+ v-model="search.productCategories"
+ size="small"
+ placeholder="璇烽�夋嫨"
+ style="width: 224px;margin-right: 30px;"
+ >
+ <el-option label="鍘熸潗鏂�" :value="0"></el-option>
+ <el-option label="鎴愬搧" :value="1"></el-option>
+ <el-option label="鍗婃垚鍝�" :value="2"></el-option>
+ </el-select>
+ <span>鐘舵�侊細</span>
+ <el-select
+ v-model="search.state"
+ size="small"
+ placeholder="璇烽�夋嫨"
+ style="width: 224px;margin-right: 30px;"
+ >
+ <el-option label="杩斾慨涓�" :value="1"></el-option>
+ <el-option label="寰呭鐞�" :value="0"></el-option>
+ </el-select>
+ <el-button size="mini" @click="clean()"><span>閲� 缃�</span></el-button>
+ <el-button
+ size="mini"
+ type="primary"
+ style="background: #004EA2;"
+ @click="
+ unqualifiedTable = [];
+ getDetailInfo();
+ "
+ ><span>鏌� 璇�</span></el-button
+ >
</div>
- </div>
+ </el-card>
+ </div>
+ <div class="tableno" style="height:300px">
+ <el-card shadow="hover" class="margin-30">
+ <el-table
+ :data="unqualifiedTable"
+ border
+ ref="multipleTable"
+ tooltip-effect="dark"
+ height="calc(100vh - 340px)"
+ style="width: 100%"
+ >
+ <el-table-column type="selection" min-width="50"> </el-table-column>
+ <el-table-column type="index" label="搴忓彿" width="60">
+ <template slot-scope="scope">
+ {{ (search.pageSize - 1) * search.countSize + scope.$index + 1 }}
+ </template>
+ </el-table-column>
+ <el-table-column prop="dateArrival" label="浜у搧澶х被">
+ <template slot-scope="scope">
+ <span v-if="scope.row.type == 0">鍘熸潗鏂�</span>
+ <span v-if="scope.row.type == 1">鎴愬搧</span>
+ <span v-if="scope.row.type == 2">鍗婃垚鍝�</span>
+ </template>
+ </el-table-column>
+ <el-table-column
+ prop="productName"
+ label="浜у搧鍚嶇О"
+ min-width="90"
+ show-overflow-tooltip
+ >
+ </el-table-column>
+ <el-table-column prop="specifications" label="瑙勬牸鍨嬪彿">
+ </el-table-column>
+ <el-table-column prop="number" label="涓嶅悎鏍煎搧鏁伴噺">
+ </el-table-column>
+ <el-table-column label="鐜板儚鎻忚堪" min-width="150">
+ <template slot-scope="scope">
+ <el-input
+ size="small"
+ v-model="scope.row.description"
+ @blur="outOfFocusDescription(scope)"
+ ></el-input>
+ </template>
+ </el-table-column>
+ <el-table-column label="澶勭疆鎰忚">
+ <template slot-scope="scope">
+ <el-button type="text" @click="showDisposalOpinions(scope)"
+ >鏌ョ湅澶勭疆鎰忚</el-button
+ >
+ </template>
+ </el-table-column>
+ <el-table-column prop="user_name" label="鐢宠浜�"> </el-table-column>
+ <el-table-column prop="date" label="鏃ユ湡"> </el-table-column>
+ <el-table-column prop="deal_state" label="鐘舵��">
+ <template slot-scope="scope">
+ <span style="color:#34BD66;" v-if="scope.row.deal_state == 1"
+ >宸插鐞�</span
+ >
+ <span style="color:#E84738;" v-else-if="scope.row.deal_state == 0"
+ >寰呭鐞�</span
+ >
+ </template>
+ </el-table-column>
+ <el-table-column label="鎿嶄綔" width="130">
+ <template slot-scope="scope">
+ <div style="display: flex;">
+ <el-button type="text" siae="small" size="mini">闄勪欢</el-button>
+ <el-button
+ type="text"
+ siae="small"
+ size="mini"
+ style=" color:87, 138, 193 ;"
+ @click="clickEditorialOpinion(scope)"
+ >缂栬緫鎰忚</el-button
+ >
+ </div>
+ </template>
+ </el-table-column>
+ </el-table>
+ <el-col
+ style="height: 50px;display: flex;align-items: center;justify-content: right;"
+ >
+ <el-pagination
+ @size-change="handleSizeChange"
+ @current-change="handleCurrentChange"
+ :current-page="search.pageSize"
+ :page-sizes="[10, 15, 20, 30, 50]"
+ :page-size="search.countSize"
+ layout="total, sizes, prev, pager, next, jumper"
+ :total="total"
+ >
+ </el-pagination>
+ </el-col>
+ </el-card>
+ </div>
+ <el-dialog title="鎻愮ず" :visible.sync="dialogVisible" width="30%">
+ <el-form label-width="130px" style="height: 500px; overflow: auto ;">
+ <el-empty
+ v-if="updateEditList.length == 0"
+ :image-size="200"
+ ></el-empty>
+ <div v-for="item in updateEditList" :key="item.$index">
+ <el-form-item
+ :label="
+ item.type == 0
+ ? '鎶�鏈儴澶勭疆鎰忚锛�'
+ : item.type == 1
+ ? '鐢熶骇閮ㄥ缃剰瑙侊細'
+ : item.type == 2
+ ? '璐ㄩ噺閮ㄥ缃剰瑙侊細'
+ : '鎬荤粡鍔炲缃剰瑙侊細'
+ "
+ >
+ <el-input
+ type="textarea"
+ :rows="2"
+ placeholder="璇疯緭鍏ュ唴瀹�"
+ v-model="item.tell"
+ >
+ </el-input>
+ </el-form-item>
+ <el-row v-if="isShow == true">
+ <el-col :span="12">
+ <el-form-item label="濉啓浜猴細" v-if="isShow == true">
+ {{ item.name }}
+ </el-form-item>
+ </el-col>
+ <el-col :span="12">
+ <el-form-item label="濉啓鏃ユ湡锛�" v-if="isShow == true">
+ {{ item.fillDate }}
+ </el-form-item>
+ </el-col>
+ </el-row>
+ <el-form-item label="澶勭疆鏂瑰紡锛�">
+ <el-radio-group v-model="item.way">
+ <el-radio :label="0">杩斿伐</el-radio>
+ <el-radio :label="1">杩斾慨</el-radio>
+ <el-radio :label="2">璁╂鎺ユ敹</el-radio>
+ <el-radio :label="3">鎷掓敹</el-radio>
+ <el-radio :label="4">闄嶇骇浣跨敤</el-radio>
+ <el-radio :label="5">鎶ュ簾</el-radio>
+ </el-radio-group>
+ </el-form-item>
+ <el-divider v-if="item.type != 3"></el-divider>
+ </div>
+ </el-form>
+ <span slot="footer" class="dialog-footer">
+ <el-button @click="dialogVisible = false">鍙� 娑�</el-button>
+ <el-button type="primary" @click="updateEditDevided()">纭� 瀹�</el-button>
+ </span>
+ </el-dialog>
+ </div>
</template>
-
-
<script>
+import { watch } from "vue";
export default {
- data() {
- return {
- searchform:{
- name:'',
- stude:''
- },
- tableData: [
- {
- date: '2016-05-03',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-02',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-04',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-01',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-08',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-06',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }, {
- date: '2016-05-07',
- name: '鐜嬪皬铏�',
- address: '涓婃捣甯傛櫘闄�鍖洪噾娌欐睙璺� 1518 寮�'
- }
- ],
- pageSize:3,
- countSize:1,
- currentPage:2,
- multipleSelection:''
- }
- },
- created(){
- // this.getDetailInfo()
- },
- methods:{
- handleSelectionChange(val) {
- // console.log(val);
- // this.multipleSelection = val;
+ data() {
+ return {
+ isShow: false,
+ search: {
+ countSize: 10, // 鏉℃暟/椤�
+ pageSize: 1, // 璧峰椤�
+ productCategories: "", // 浜у搧澶х被
+ productName: "", // 浜у搧鍚嶇О
+ specificationModel: "", // 瑙勬牸鍨嬪彿
+ state: "" // 鐘舵��
},
- handleSizeChange(val) {
- console.log(val);
- // this.pageSize = 1
- // this.countSize= val
- // this.getDetailInfo()
- },
- handleCurrentChange(val) {
- // this.pageSize = val
- // this.getDetailInfo()
- },
- getDetailInfo() {
- let aa = [0,5]
- aa.map(el =>{
- console.log(el);
- })
- console.log(this.searchform.name);
- console.log(this.searchform.stude);
- // this.tableData
- // this.axios.get(this.$api.url.gettable,{
- // params:{pageNo:10,
- // pageSize:1,
- // productName:this.searchform.name,
- // specificationsModels:this.searchform.stude
- // },
- // }).then(res=>{
- // console.log(res);
- // this.tableData = res.data.row
- // })
+ unqualifiedTable: [], // 椤甸潰琛ㄦ牸鏁版嵁
+ total: 0, // 鎬绘潯鏁�
+ dialogVisible: false, // 鏄剧ず寮瑰嚭妗�
+ updateEditList: []
+ };
+ },
+ mounted() {
+ this.getDetailInfo();
+ },
+ methods: {
+ // 鍒嗛〉
+ handleSizeChange(val) {
+ this.search.countSize = val;
+ this.getDetailInfo();
+ },
+ // 鍒嗛〉
+ handleCurrentChange(val) {
+ this.search.pageSize = val;
+ this.getDetailInfo();
+ },
+ // 鍒嗛〉琛ㄦ牸鏁版嵁
+ getDetailInfo() {
+ this.axios
+ .get(this.$api.url.getTable, {
+ params: this.search
+ })
+ .then(res => {
+ this.unqualifiedTable = res.data.row;
+ this.total = res.data.total;
+ });
+ },
+ // 閲嶇疆鎸夐挳
+ clean() {
+ this.search = {
+ countSize: 10, // 鏉℃暟/椤�
+ pageSize: 1, // 璧峰椤�
+ productCategories: "", // 浜у搧澶х被
+ productName: "", // 浜у搧鍚嶇О
+ specificationModel: "", // 瑙勬牸鍨嬪彿
+ state: "" // 鐘舵��
+ };
+ this.getDetailInfo();
+ },
+ // 鐐瑰嚮鏌ョ湅澶勭疆鎰忚
+ showDisposalOpinions(scope) {
+ this.isShow = true;
+ this.dialogVisible = true;
+ this.$axios
+ .get(this.$api.url.viewEditorial, {
+ params: {
+ rawUnacceptedId: scope.row.id
+ }
+ })
+ .then(res => {
+ this.updateEditList = res.data;
+ });
+ },
+ // 鐐瑰嚮缂栬緫鎰忚
+ clickEditorialOpinion(scope) {
+ this.dialogVisible = true;
+ this.axios
+ .get(this.$api.url.clickEditing, {
+ params: { rawUnacceptedId: scope.row.id }
+ })
+ .then(res => {
+ this.updateEditList = res.data;
+ });
+ },
+ // 澶卞幓鐜板儚鎻忚堪鐒︾偣瑙﹀彂
+ outOfFocusDescription(scope) {
+ this.axios
+ .get(this.$api.url.descriptionUpdate, {
+ params: {
+ rawUnacceptedId: scope.row.id,
+ tell: scope.row.description
+ }
+ })
+ .then(res => {
+ this.$message({
+ message: res.message,
+ type: "success"
+ });
+ });
+ },
+ // 鐐瑰嚮纭畾鎸夐挳
+ updateEditDevided() {
+ this.$axios
+ .post(
+ this.$api.url.addOpinion,
+ { opinion: this.updateEditList },
+ {
+ headers: { "Content-Type": "application/json" }
+ }
+ )
+ .then(res => {
+ console.log(`output->res`, res);
+ this.dialogVisible = false;
+ });
+ }
+ },
+ watch: {
+ dialogVisible: {
+ handler(newVal, oldVal) {
+ if (newVal == false) {
+ this.isShow = false;
}
-}}
- // methods:{
- // toggleSelection(rows) {
- // if (rows) {
- // rows.forEach(row => {
- // this.$refs.multipleTable.toggleRowSelection(row);
- // });
- // } else {
- // this.$refs.multipleTable.clearSelection();
- // }
- // },
-
- // }
- // }
-
-
+ }
+ }
+ }
+};
</script>
+
<style scoped>
-.card-2{
- display: flex;
- margin-top: 30px;
+.main_div {
+ padding-top: 15px;
+}
+.el-radio__label {
+ font-size: 16px;
+}
+.el-radio {
+ margin-right: 60px;
+ margin-top: 10px;
+}
+.el-form-item {
+ margin-bottom: 6px;
+ font-size: 16px;
+}
+.unqualifiedBox {
+ width: 100%;
+ max-height: 100%;
+ display: flex;
+ flex-direction: column;
+ /* overflow-y: scroll; */
+}
+.unqualifiedBox .title .el-button {
+ height: 32px;
+ border: 1px solid rgba(190, 190, 190, 0.44);
+ box-shadow: 0px 2px 4px rgba(220, 220, 220, 0.41);
+ padding: 0 12px;
+}
+/deep/ .el-table__cell {
+ padding: 5px 0;
+}
+.unqualifiedBox .title {
+ margin-bottom: 10px;
+ padding: 0 20px;
+}
+<!-- /* 鏉′欢鏌ヨ澶撮儴鏍峰紡 */ -->
+ .choose {
+ padding: 21px 24px;
+ display: flex;
+ align-items: center;
+ background-color: #fff;
+ border-bottom: 3px solid rgb(245, 247, 251);
}
-.ssss{
- background-color: #fff;
+.choose {
+ font-size: 14px;
+}
+
+.choose .el-button {
+ height: 32px;
+ border: 1px solid rgba(190, 190, 190, 0.44);
+ box-shadow: 0px 2px 4px rgba(220, 220, 220, 0.41);
+ padding: 0 12px;
+}
+<!-- /* 涓嶅悎鏍艰〃鏍兼牱寮� */
+ .unqualifiedTable {
+ flex: 1;
+ background: #fff;
+ margin-top: 11px;
+ padding: 23px 21px;
+}
+.tableno {
+ margin-top: 10px;
}
</style>
--
Gitblit v1.9.3