@@ -17,17 +17,20 @@
-
+
{{ contract.customerName }}
-
- {{ contract.contactName }}
+
+ {{ floatToFixed2(contract.price) }}
-
- {{ contract.productPrice }}
+
+ {{ contract.orderDate ? formatDate(contract.orderDate) : '空' }}
-
- {{ contract.createTime ? formatDate(contract.createTime) : '空' }}
+
+ {{ floatToFixed2(contract.price) }}
+
+
+ {{ contract.ownerUserName }}
@@ -35,6 +38,7 @@
diff --git a/src/views/crm/contract/detail/index.vue b/src/views/crm/contract/detail/index.vue
index b0f9b355..fab71ade 100644
--- a/src/views/crm/contract/detail/index.vue
+++ b/src/views/crm/contract/detail/index.vue
@@ -1,10 +1,10 @@
-
+
编辑
-
+
转移
@@ -13,6 +13,9 @@
+
+
+
@@ -25,18 +28,11 @@
@quit-team="close"
/>
-
-
-
-
+
diff --git a/src/views/crm/contract/components/ProductList.vue b/src/views/crm/contract/components/ProductList.vue
index d0c32bf4..ed4ce6f1 100644
--- a/src/views/crm/contract/components/ProductList.vue
+++ b/src/views/crm/contract/components/ProductList.vue
@@ -4,37 +4,56 @@
添加产品
-
-
+
+
+
+
+
+
+
+
-
+ fixed="right"
+ label="折扣(%)"
+ prop="discountPercent"
+ width="120"
+ >
-
+
-
+
-
+ {{ fenToYuan(getTotalPrice(row)) }}
-
-
- {{ getTotalPrice(row) }}
-
-
-
+
移除
@@ -66,7 +85,7 @@ import * as ProductApi from '@/api/crm/product'
import { DICT_TYPE } from '@/utils/dict'
import { fenToYuanFormat } from '@/utils/formatter'
import { TableSelectForm } from '@/components/Table/index'
-import { floatToFixed2, yuanToFen } from '@/utils'
+import { fenToYuan, floatToFixed2, yuanToFen } from '@/utils'
defineOptions({ name: 'ProductList' })
const props = withDefaults(defineProps<{ modelValue: ProductApi.ProductExpandVO[] }>(), {
diff --git a/src/views/crm/contract/detail/index.vue b/src/views/crm/contract/detail/index.vue
index 5973a68a..8ea43fb1 100644
--- a/src/views/crm/contract/detail/index.vue
+++ b/src/views/crm/contract/detail/index.vue
@@ -10,15 +10,16 @@
-
+
+
+
-
-
-
+
+
+
+
+
+
diff --git a/src/views/crm/contract/index.vue b/src/views/crm/contract/index.vue
index 7fc6b9c9..417392d3 100644
--- a/src/views/crm/contract/index.vue
+++ b/src/views/crm/contract/index.vue
@@ -54,7 +54,6 @@
-
@@ -145,12 +144,12 @@
>
编辑
-
+
提交审核
@@ -274,9 +273,9 @@ const handleExport = async () => {
}
/** 提交审核 **/
-const handleApprove = async (row: ContractApi.ContractVO) => {
+const handleSubmit = async (row: ContractApi.ContractVO) => {
await message.confirm(`您确定提交【${row.name}】审核吗?`)
- await ContractApi.handleApprove(row.id)
+ await ContractApi.submitContract(row.id)
message.success('提交审核成功!')
await getList()
}
diff --git a/src/views/crm/contract/oa/ContractDetail/index.vue b/src/views/crm/contract/oa/ContractDetail/index.vue
index eda87394..118ff182 100644
--- a/src/views/crm/contract/oa/ContractDetail/index.vue
+++ b/src/views/crm/contract/oa/ContractDetail/index.vue
@@ -1,4 +1,4 @@
-
+
From ce9317e3d0d5eeee963accf538efa9f96c8671ca Mon Sep 17 00:00:00 2001
From: YunaiV
Date: Sun, 4 Feb 2024 19:57:56 +0800
Subject: [PATCH 9/9] =?UTF-8?q?=E2=9C=A8=20ERP=EF=BC=9A=E5=88=9D=E5=A7=8B?=
=?UTF-8?q?=E5=8C=96=20product=20=E4=BF=A1=E6=81=AF=E3=80=81=E5=88=86?=
=?UTF-8?q?=E7=B1=BB=E3=80=81=E5=8D=95=E4=BD=8D=E7=9A=84=E5=AE=9E=E7=8E=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/api/erp/product/category/index.ts | 50 ++++
src/api/erp/product/index.ts | 64 +++++
src/api/erp/product/unit/index.ts | 44 ++++
src/views/erp/product/ProductForm.vue | 154 ++++++++++++
.../product/category/ProductCategoryForm.vue | 145 ++++++++++++
src/views/erp/product/category/index.vue | 220 ++++++++++++++++++
src/views/erp/product/index.vue | 208 +++++++++++++++++
.../erp/product/unit/ProductUnitForm.vue | 100 ++++++++
src/views/erp/product/unit/index.vue | 200 ++++++++++++++++
9 files changed, 1185 insertions(+)
create mode 100644 src/api/erp/product/category/index.ts
create mode 100644 src/api/erp/product/index.ts
create mode 100644 src/api/erp/product/unit/index.ts
create mode 100644 src/views/erp/product/ProductForm.vue
create mode 100644 src/views/erp/product/category/ProductCategoryForm.vue
create mode 100644 src/views/erp/product/category/index.vue
create mode 100644 src/views/erp/product/index.vue
create mode 100644 src/views/erp/product/unit/ProductUnitForm.vue
create mode 100644 src/views/erp/product/unit/index.vue
diff --git a/src/api/erp/product/category/index.ts b/src/api/erp/product/category/index.ts
new file mode 100644
index 00000000..945be207
--- /dev/null
+++ b/src/api/erp/product/category/index.ts
@@ -0,0 +1,50 @@
+import request from '@/config/axios'
+
+// ERP 商品分类 VO
+export interface ProductCategoryVO {
+ // 分类编号
+ id: number
+ // 父分类编号
+ parentId: number
+ // 分类名称
+ name: string
+ // 分类编码
+ code: string
+ // 分类排序
+ sort: number
+ // 开启状态
+ status: number
+}
+
+// ERP 商品分类 API
+export const ProductCategoryApi = {
+ // 查询ERP 商品分类列表
+ getProductCategoryList: async (params) => {
+ return await request.get({ url: `/erp/product-category/list`, params })
+ },
+
+ // 查询ERP 商品分类详情
+ getProductCategory: async (id: number) => {
+ return await request.get({ url: `/erp/product-category/get?id=` + id })
+ },
+
+ // 新增ERP 商品分类
+ createProductCategory: async (data: ProductCategoryVO) => {
+ return await request.post({ url: `/erp/product-category/create`, data })
+ },
+
+ // 修改ERP 商品分类
+ updateProductCategory: async (data: ProductCategoryVO) => {
+ return await request.put({ url: `/erp/product-category/update`, data })
+ },
+
+ // 删除ERP 商品分类
+ deleteProductCategory: async (id: number) => {
+ return await request.delete({ url: `/erp/product-category/delete?id=` + id })
+ },
+
+ // 导出ERP 商品分类 Excel
+ exportProductCategory: async (params) => {
+ return await request.download({ url: `/erp/product-category/export-excel`, params })
+ }
+}
\ No newline at end of file
diff --git a/src/api/erp/product/index.ts b/src/api/erp/product/index.ts
new file mode 100644
index 00000000..3729064c
--- /dev/null
+++ b/src/api/erp/product/index.ts
@@ -0,0 +1,64 @@
+import request from '@/config/axios'
+
+// ERP 产品 VO
+export interface ProductVO {
+ // 产品编号
+ id: number
+ // 产品名称
+ name: string
+ // 产品条码
+ barCode: string
+ // 产品类型编号
+ categoryId: number
+ // 单位编号
+ unitId: number
+ // 产品状态
+ status: number
+ // 产品规格
+ standard: string
+ // 产品备注
+ remark: string
+ // 保质期天数
+ expiryDay: number
+ // 基础重量(kg)
+ weight: number
+ // 采购价格,单位:元
+ purchasePrice: number
+ // 销售价格,单位:元
+ salePrice: number
+ // 最低价格,单位:元
+ minPrice: number
+}
+
+// ERP 产品 API
+export const ProductApi = {
+ // 查询ERP 产品分页
+ getProductPage: async (params: any) => {
+ return await request.get({ url: `/erp/product/page`, params })
+ },
+
+ // 查询ERP 产品详情
+ getProduct: async (id: number) => {
+ return await request.get({ url: `/erp/product/get?id=` + id })
+ },
+
+ // 新增ERP 产品
+ createProduct: async (data: ProductVO) => {
+ return await request.post({ url: `/erp/product/create`, data })
+ },
+
+ // 修改ERP 产品
+ updateProduct: async (data: ProductVO) => {
+ return await request.put({ url: `/erp/product/update`, data })
+ },
+
+ // 删除ERP 产品
+ deleteProduct: async (id: number) => {
+ return await request.delete({ url: `/erp/product/delete?id=` + id })
+ },
+
+ // 导出ERP 产品 Excel
+ exportProduct: async (params) => {
+ return await request.download({ url: `/erp/product/export-excel`, params })
+ }
+}
\ No newline at end of file
diff --git a/src/api/erp/product/unit/index.ts b/src/api/erp/product/unit/index.ts
new file mode 100644
index 00000000..6a6682e4
--- /dev/null
+++ b/src/api/erp/product/unit/index.ts
@@ -0,0 +1,44 @@
+import request from '@/config/axios'
+
+// ERP 产品单位 VO
+export interface ProductUnitVO {
+ // 单位编号
+ id: number
+ // 单位名字
+ name: string
+ // 单位状态
+ status: number
+}
+
+// ERP 产品单位 API
+export const ProductUnitApi = {
+ // 查询ERP 产品单位分页
+ getProductUnitPage: async (params: any) => {
+ return await request.get({ url: `/erp/product-unit/page`, params })
+ },
+
+ // 查询ERP 产品单位详情
+ getProductUnit: async (id: number) => {
+ return await request.get({ url: `/erp/product-unit/get?id=` + id })
+ },
+
+ // 新增ERP 产品单位
+ createProductUnit: async (data: ProductUnitVO) => {
+ return await request.post({ url: `/erp/product-unit/create`, data })
+ },
+
+ // 修改ERP 产品单位
+ updateProductUnit: async (data: ProductUnitVO) => {
+ return await request.put({ url: `/erp/product-unit/update`, data })
+ },
+
+ // 删除ERP 产品单位
+ deleteProductUnit: async (id: number) => {
+ return await request.delete({ url: `/erp/product-unit/delete?id=` + id })
+ },
+
+ // 导出ERP 产品单位 Excel
+ exportProductUnit: async (params) => {
+ return await request.download({ url: `/erp/product-unit/export-excel`, params })
+ }
+}
\ No newline at end of file
diff --git a/src/views/erp/product/ProductForm.vue b/src/views/erp/product/ProductForm.vue
new file mode 100644
index 00000000..08ff5cd9
--- /dev/null
+++ b/src/views/erp/product/ProductForm.vue
@@ -0,0 +1,154 @@
+
+
+
+
+
diff --git a/src/views/erp/product/category/ProductCategoryForm.vue b/src/views/erp/product/category/ProductCategoryForm.vue
new file mode 100644
index 00000000..ef4a003e
--- /dev/null
+++ b/src/views/erp/product/category/ProductCategoryForm.vue
@@ -0,0 +1,145 @@
+
+
+
+
diff --git a/src/views/erp/product/category/index.vue b/src/views/erp/product/category/index.vue
new file mode 100644
index 00000000..e3659ff6
--- /dev/null
+++ b/src/views/erp/product/category/index.vue
@@ -0,0 +1,220 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 搜索
+ 重置
+
+ 新增
+
+
+ 导出
+
+
+ 展开/折叠
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 编辑
+
+
+ 删除
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/erp/product/index.vue b/src/views/erp/product/index.vue
new file mode 100644
index 00000000..ef7c7cae
--- /dev/null
+++ b/src/views/erp/product/index.vue
@@ -0,0 +1,208 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 搜索
+ 重置
+
+ 新增
+
+
+ 导出
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 编辑
+
+
+ 删除
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/erp/product/unit/ProductUnitForm.vue b/src/views/erp/product/unit/ProductUnitForm.vue
new file mode 100644
index 00000000..65fe5701
--- /dev/null
+++ b/src/views/erp/product/unit/ProductUnitForm.vue
@@ -0,0 +1,100 @@
+
+
+
+
diff --git a/src/views/erp/product/unit/index.vue b/src/views/erp/product/unit/index.vue
new file mode 100644
index 00000000..c574df7c
--- /dev/null
+++ b/src/views/erp/product/unit/index.vue
@@ -0,0 +1,200 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 搜索
+ 重置
+
+ 新增
+
+
+ 导出
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 编辑
+
+
+ 删除
+
+
+
+
+
+
+
+
+
+
+
+
+