From 0f8ceb083f23793ffc15189e7ce28292da22c8b6 Mon Sep 17 00:00:00 2001
From: xiao-fajia <1665375861@qq.com>
Date: Fri, 13 Sep 2024 18:31:13 +0800
Subject: [PATCH] =?UTF-8?q?=E7=BB=B4=E4=BF=AE=E4=B8=9A=E5=8A=A1=E5=BA=93in?=
=?UTF-8?q?it?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/base/customer/index.js | 8 +++
src/api/repair/stockOperate/stockOperate.js | 1 +
.../repair/stockOperate/stockOperateItem.js | 1 +
src/api/repair/stockTransfer/stockTransfer.js | 1 +
.../repair/stockTransfer/stockTransferItem.js | 1 +
src/api/repair/supplier/index.js | 8 +++
src/api/repair/tickets/Tickets.js | 1 +
src/api/repair/tickets/TicketsItem.js | 1 +
src/views/repair/Components/CorpChoose.vue | 21 +++++-
src/views/repair/Components/PartChoose.vue | 40 ++++++++++--
.../repair/Components/RepairTypeChoose.vue | 41 ++++++++++++
.../repair/Components/SupplierChoose.vue | 23 ++++++-
src/views/repair/Components/UserChoose.vue | 25 ++++++--
.../repair/Components/WarehouseChoose.vue | 64 +++++++++++++++++++
.../stockOperate/Components/SoIndex.vue | 19 +++++-
.../repair/stockOperate/Components/SoInfo.vue | 38 ++++++++---
.../stockOperate/Components/SoTable.vue | 16 +++--
.../stockOperate/Components/SoiTable.vue | 11 +++-
.../stockTransfer/Components/StIndex.vue | 9 ++-
.../stockTransfer/Components/StInfo.vue | 23 ++++++-
.../stockTransfer/Components/StTable.vue | 20 ++++--
.../tickets/Components/TicketSearch.vue | 20 ++++--
.../repair/tickets/Components/UserInfo.vue | 27 ++++++--
23 files changed, 368 insertions(+), 51 deletions(-)
create mode 100644 src/api/repair/stockOperate/stockOperate.js
create mode 100644 src/api/repair/stockOperate/stockOperateItem.js
create mode 100644 src/api/repair/stockTransfer/stockTransfer.js
create mode 100644 src/api/repair/stockTransfer/stockTransferItem.js
create mode 100644 src/api/repair/tickets/Tickets.js
create mode 100644 src/api/repair/tickets/TicketsItem.js
create mode 100644 src/views/repair/Components/RepairTypeChoose.vue
create mode 100644 src/views/repair/Components/WarehouseChoose.vue
diff --git a/src/api/base/customer/index.js b/src/api/base/customer/index.js
index 711b32a..b666448 100644
--- a/src/api/base/customer/index.js
+++ b/src/api/base/customer/index.js
@@ -67,3 +67,11 @@ export function exportCustomerMainExcel(params) {
responseType: 'blob'
})
}
+
+// 用户列表
+export function getCustomerList(){
+ return request({
+ url: "/base/custom/list",
+ method: "get"
+ })
+}
diff --git a/src/api/repair/stockOperate/stockOperate.js b/src/api/repair/stockOperate/stockOperate.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/stockOperate/stockOperate.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/api/repair/stockOperate/stockOperateItem.js b/src/api/repair/stockOperate/stockOperateItem.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/stockOperate/stockOperateItem.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/api/repair/stockTransfer/stockTransfer.js b/src/api/repair/stockTransfer/stockTransfer.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/stockTransfer/stockTransfer.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/api/repair/stockTransfer/stockTransferItem.js b/src/api/repair/stockTransfer/stockTransferItem.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/stockTransfer/stockTransferItem.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/api/repair/supplier/index.js b/src/api/repair/supplier/index.js
index d2f00ef..9b24844 100644
--- a/src/api/repair/supplier/index.js
+++ b/src/api/repair/supplier/index.js
@@ -51,3 +51,11 @@ export function exportBaseSupplierExcel(params) {
responseType: 'blob'
})
}
+
+// 获得所有供应商
+export function getBaseSupplierList(){
+ return request({
+ url: '/supplier/baseSupplier/list',
+ method: 'get'
+ })
+}
diff --git a/src/api/repair/tickets/Tickets.js b/src/api/repair/tickets/Tickets.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/tickets/Tickets.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/api/repair/tickets/TicketsItem.js b/src/api/repair/tickets/TicketsItem.js
new file mode 100644
index 0000000..543ea86
--- /dev/null
+++ b/src/api/repair/tickets/TicketsItem.js
@@ -0,0 +1 @@
+import request from '@/utils/request'
diff --git a/src/views/repair/Components/CorpChoose.vue b/src/views/repair/Components/CorpChoose.vue
index 4d81a84..9b6f556 100644
--- a/src/views/repair/Components/CorpChoose.vue
+++ b/src/views/repair/Components/CorpChoose.vue
@@ -1,10 +1,13 @@
-
+
diff --git a/src/views/repair/Components/PartChoose.vue b/src/views/repair/Components/PartChoose.vue
index 46b4c01..8565f20 100644
--- a/src/views/repair/Components/PartChoose.vue
+++ b/src/views/repair/Components/PartChoose.vue
@@ -1,6 +1,21 @@
-
-
+
+
+
+
+
+ {{ scope.$index + 1 }}
+
+
+
+
+
+
+
+
+
+
@@ -9,8 +24,16 @@ export default {
name: "PartChoose",
data(){
return{
- partSelected: undefined,
- partList: null,
+ partSelected: null,
+ partList: [
+ {id: 1, name: '张胜男', age:20, gender: 1},
+ {id: 2, name: '张胜妇', age:20, gender: 1}
+ ],
+ queryParams:{
+ pageNo: 1,
+ pageSize: 10
+ },
+ total: 2
}
},
mounted() {
@@ -20,11 +43,18 @@ export default {
// TODO 获取商品信息
async listPart(){
+ },
+ handleSelectionChange(data){
+ this.$emit("selected", data)
+ this.$refs.selectTable.blur()
}
}
}
diff --git a/src/views/repair/Components/RepairTypeChoose.vue b/src/views/repair/Components/RepairTypeChoose.vue
new file mode 100644
index 0000000..c2185fc
--- /dev/null
+++ b/src/views/repair/Components/RepairTypeChoose.vue
@@ -0,0 +1,41 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/repair/Components/SupplierChoose.vue b/src/views/repair/Components/SupplierChoose.vue
index 06ddd58..85ff8b9 100644
--- a/src/views/repair/Components/SupplierChoose.vue
+++ b/src/views/repair/Components/SupplierChoose.vue
@@ -1,20 +1,37 @@
-
+
diff --git a/src/views/repair/Components/UserChoose.vue b/src/views/repair/Components/UserChoose.vue
index 8667b8f..31457f0 100644
--- a/src/views/repair/Components/UserChoose.vue
+++ b/src/views/repair/Components/UserChoose.vue
@@ -1,19 +1,36 @@
-
-
+
+
diff --git a/src/views/repair/Components/WarehouseChoose.vue b/src/views/repair/Components/WarehouseChoose.vue
new file mode 100644
index 0000000..7dad376
--- /dev/null
+++ b/src/views/repair/Components/WarehouseChoose.vue
@@ -0,0 +1,64 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/repair/stockOperate/Components/SoIndex.vue b/src/views/repair/stockOperate/Components/SoIndex.vue
index 41838e3..ad3f7d9 100644
--- a/src/views/repair/stockOperate/Components/SoIndex.vue
+++ b/src/views/repair/stockOperate/Components/SoIndex.vue
@@ -21,14 +21,18 @@
-
+
+
-
+
搜索
@@ -112,9 +116,16 @@
import SupplierChoose from "@/views/repair/Components/SupplierChoose.vue";
import CorpChoose from "@/views/repair/Components/CorpChoose.vue";
import StaffChoose from "@/views/repair/Components/StaffChoose.vue";
+import {DICT_TYPE} from "@/utils/dict";
export default {
name: "SoIndex",
+ computed: {
+ getStatus(){
+ const data = this.getDictDatas(DICT_TYPE.REPAIR_SO_STATUS)
+ return data.filter(item => item.label.toString().indexOf("领料") === -1)
+ }
+ },
components:{
StaffChoose,
SupplierChoose,
@@ -164,6 +175,10 @@ export default {
getStaff(data){
this.queryParams.userId = data.id
this.queryParams.userName = data.name
+ },
+ // 门店选择
+ getCompany(data){
+ console.log(data)
}
}
}
diff --git a/src/views/repair/stockOperate/Components/SoInfo.vue b/src/views/repair/stockOperate/Components/SoInfo.vue
index e3de8c9..7b00eb6 100644
--- a/src/views/repair/stockOperate/Components/SoInfo.vue
+++ b/src/views/repair/stockOperate/Components/SoInfo.vue
@@ -5,7 +5,7 @@
-
+
@@ -29,21 +29,21 @@
-
+
-
+
-
+
@@ -72,8 +72,8 @@ export default {
SoTable,
SupplierChoose
},
- props:{
- soByType:{
+ props: {
+ soByType: {
type: Boolean,
defaultValue: true,
required: true
@@ -90,7 +90,8 @@ export default {
userName: null,
partList: []
},
- staffRole: "采购员"
+ staffRole: "采购员",
+ partList: [],
}
},
mounted() {
@@ -98,10 +99,31 @@ export default {
this.staffRole = this.soByType ? this.staffRole : "领料人"
},
methods: {
- // 得到员工选择组件回传的值
+ // 得到选择的员工
getStaff(data) {
this.formData.userId = data.id
this.formData.userName = data.name
+ },
+ // 得到选择的供应商
+ getSupplier(data) {
+ console.log(data)
+ },
+ // 得到选择的商品
+ async getPart(data) {
+ const flag = this.partList.find(item => item.id === data.id)
+ if (flag) {
+ try {
+ await this.$modal.confirm(`${data.name}已存在,确定要重复添加?`)
+ this.partList.push(data)
+ } catch {
+ }
+ } else {
+ this.partList.push(data)
+ }
+ },
+ // 删除数据
+ deleteItem(index) {
+ this.partList.splice(index, 1)
}
}
}
diff --git a/src/views/repair/stockOperate/Components/SoTable.vue b/src/views/repair/stockOperate/Components/SoTable.vue
index c863350..0a73902 100644
--- a/src/views/repair/stockOperate/Components/SoTable.vue
+++ b/src/views/repair/stockOperate/Components/SoTable.vue
@@ -1,11 +1,11 @@
-
+
{{ scope.$index + 1 }}
-
+
@@ -18,7 +18,7 @@
- 删除
@@ -34,6 +34,11 @@ export default {
type: Boolean,
defaultValue: true,
required: true
+ },
+ partList:{
+ type: Array,
+ defaultValue: false,
+ required: true
}
},
data() {
@@ -43,7 +48,10 @@ export default {
}
},
methods: {
-
+ // 通知父组件,删除数据
+ deleteItem(index){
+ this.$emit("deleteItem", index)
+ }
}
}
diff --git a/src/views/repair/stockOperate/Components/SoiTable.vue b/src/views/repair/stockOperate/Components/SoiTable.vue
index a5160a9..d015173 100644
--- a/src/views/repair/stockOperate/Components/SoiTable.vue
+++ b/src/views/repair/stockOperate/Components/SoiTable.vue
@@ -21,7 +21,7 @@
-
+
搜索
@@ -67,10 +67,11 @@
diff --git a/src/views/repair/stockTransfer/Components/StIndex.vue b/src/views/repair/stockTransfer/Components/StIndex.vue
index f3b0a01..de113f2 100644
--- a/src/views/repair/stockTransfer/Components/StIndex.vue
+++ b/src/views/repair/stockTransfer/Components/StIndex.vue
@@ -19,8 +19,9 @@
-
-
+
+
+
@@ -92,7 +93,9 @@ export default {
},
data() {
return {
- queryParams:{},
+ queryParams:{
+ stStatus: null
+ },
showSearch: true,
loading: false,
list: [],
diff --git a/src/views/repair/stockTransfer/Components/StInfo.vue b/src/views/repair/stockTransfer/Components/StInfo.vue
index 87cc78f..98c147a 100644
--- a/src/views/repair/stockTransfer/Components/StInfo.vue
+++ b/src/views/repair/stockTransfer/Components/StInfo.vue
@@ -23,13 +23,13 @@
-
+
-
+
@@ -82,14 +82,33 @@ export default {
formData: {
stNo: null,
},
+ partList: []
}
},
mounted() {
this.formData.stNo = createUniqueCodeByHead("DB")
},
methods: {
+ // 选择员工
getStaff(data) {
+ },
+ // 选择商品
+ async getPart(data){
+ const flag = this.partList.find(item => item.id === data.id)
+ if (flag) {
+ try {
+ await this.$modal.confirm(`${data.name}已存在,确定要重复添加?`)
+ this.partList.push(data)
+ } catch {
+ }
+ } else {
+ this.partList.push(data)
+ }
+ },
+ // 删除商品
+ deleteItem(index){
+ this.partList.splice(index, 1)
}
}
}
diff --git a/src/views/repair/stockTransfer/Components/StTable.vue b/src/views/repair/stockTransfer/Components/StTable.vue
index abc6ac8..8bdd154 100644
--- a/src/views/repair/stockTransfer/Components/StTable.vue
+++ b/src/views/repair/stockTransfer/Components/StTable.vue
@@ -1,11 +1,11 @@
-
+
{{ scope.$index + 1 }}
-
+
@@ -17,7 +17,7 @@
- 删除
@@ -28,13 +28,25 @@
diff --git a/src/views/repair/tickets/Components/TicketSearch.vue b/src/views/repair/tickets/Components/TicketSearch.vue
index e2a4efe..6956f2b 100644
--- a/src/views/repair/tickets/Components/TicketSearch.vue
+++ b/src/views/repair/tickets/Components/TicketSearch.vue
@@ -16,8 +16,13 @@
-
-
+
+
+
+
+
+
+
@@ -45,13 +50,15 @@
import StaffChoose from "@/views/repair/Components/StaffChoose.vue";
import SupplierChoose from "@/views/repair/Components/SupplierChoose.vue";
import TicketTable from "@/views/repair/tickets/Components/TicketTable.vue";
+import RepairTypeChoose from "@/views/repair/Components/RepairTypeChoose.vue";
export default {
name: "TicketSearch",
components: {
TicketTable,
StaffChoose,
- SupplierChoose
+ SupplierChoose,
+ RepairTypeChoose
},
props:{
TicketType:{
@@ -67,7 +74,12 @@ export default {
total: 0,
}
},
- methods: {}
+ methods: {
+ // 类型选择
+ getRepairType(data){
+ console.log(data)
+ }
+ }
}
diff --git a/src/views/repair/tickets/Components/UserInfo.vue b/src/views/repair/tickets/Components/UserInfo.vue
index 5ba31d0..6875b87 100644
--- a/src/views/repair/tickets/Components/UserInfo.vue
+++ b/src/views/repair/tickets/Components/UserInfo.vue
@@ -10,7 +10,7 @@
用户选择
-
+
@@ -99,14 +99,17 @@
质保说明
- 终检
+ 终检
+ 不终检
-
+
+
-
+
+
@@ -190,12 +193,22 @@ export default {
}
},
data() {
- return {}
+ return {
+ formData:{
+ endCheck: 1,
+ partDisposal:'01',
+ repairType: '01',
+ }
+ }
},
- methods: {}
+ methods: {
+ // 选择用户
+ getUser(data){
+ console.log(data)
+ }
+ }
}