diff --git a/Excel导入格式说明.md b/Excel导入格式说明.md
new file mode 100644
index 0000000..523ef84
--- /dev/null
+++ b/Excel导入格式说明.md
@@ -0,0 +1,146 @@
+# Excel导入格式说明
+
+## 📋 合作成本表导入格式
+
+### 文件要求
+- 文件格式:`.xlsx` 或 `.xls`
+- 第一行为标题行(必须)
+- 从第二行开始为数据行
+
+### Excel列格式
+
+| 列序号 | 列名 | 是否必填 | 数据类型 | 说明 | 示例 |
+|--------|------|---------|---------|------|------|
+| A | 门店ID | ✅ 必填 | 文本 | 门店ID(关联lq_mdxx.F_Id) | `1649328471923847168` |
+| B | 门店名称 | ⚪ 可选 | 文本 | 门店名称(如果为空,系统会根据门店ID自动查询) | `川师店` |
+| C | 年份 | ✅ 必填 | 数字 | 年份(4位数字) | `2025` |
+| D | 月份 | ✅ 必填 | 文本 | 月份(YYYYMM格式,6位) | `202501` |
+| E | 合计金额 | ✅ 必填 | 数字 | 合计金额(支持小数) | `5000.00` |
+| F | 备注说明 | ⚪ 可选 | 文本 | 备注说明 | `1月合作项目成本` |
+
+### Excel示例
+
+```
+门店ID | 门店名称 | 年份 | 月份 | 合计金额 | 备注说明
+---------------------------|---------|------|--------|----------|------------------
+1649328471923847168 | 川师店 | 2025 | 202501 | 5000.00 | 1月合作项目成本
+1649328471923847169 | 春熙店 | 2025 | 202501 | 3000.00 | 1月合作项目成本
+```
+
+### 注意事项
+1. **门店ID**:必须存在系统中,否则导入会失败
+2. **年份**:必须是4位数字,如:2025
+3. **月份**:必须是YYYYMM格式的6位字符串,如:202501(表示2025年1月)
+4. **合计金额**:必须是数字,支持小数,如:5000.00
+5. **重复检查**:系统会检查相同门店、年份、月份是否已存在记录,如果存在会跳过并提示
+6. **空行处理**:如果门店ID和门店名称都为空,该行会被跳过
+
+---
+
+## 📋 店内支出表导入格式
+
+### 文件要求
+- 文件格式:`.xlsx` 或 `.xls`
+- 第一行为标题行(必须)
+- 从第二行开始为数据行
+
+### Excel列格式
+
+| 列序号 | 列名 | 是否必填 | 数据类型 | 说明 | 示例 |
+|--------|------|---------|---------|------|------|
+| A | 门店ID | ✅ 必填 | 文本 | 门店ID(关联lq_mdxx.F_Id) | `1649328471923847168` |
+| B | 门店名称 | ⚪ 可选 | 文本 | 门店名称(如果为空,系统会根据门店ID自动查询) | `川师店` |
+| C | 支出分类ID | ⚪ 可选 | 文本 | 支出分类ID(关联lq_reimbursement_category.F_Id) | `xxx` |
+| D | 支出分类名称 | ⚪ 可选 | 文本 | 支出分类名称 | `办公用品` |
+| E | 支出日期 | ✅ 必填 | 日期 | 支出日期(格式:YYYY-MM-DD) | `2025-01-15` |
+| F | 单价 | ⚪ 可选 | 数字 | 单价(支持小数) | `10.50` |
+| G | 数量 | ⚪ 可选 | 数字 | 数量(整数) | `5` |
+| H | 金额 | ✅ 必填 | 数字 | 金额(支持小数) | `52.50` |
+| I | 备注说明 | ⚪ 可选 | 文本 | 备注说明 | `购买办公用品` |
+| J | 关联报销申请ID | ⚪ 可选 | 文本 | 关联的报销申请ID | `xxx` |
+| K | 关联购买记录ID | ⚪ 可选 | 文本 | 关联的购买记录ID | `xxx` |
+
+### Excel示例
+
+```
+门店ID | 门店名称 | 支出分类ID | 支出分类名称 | 支出日期 | 单价 | 数量 | 金额 | 备注说明 | 关联报销申请ID | 关联购买记录ID
+---------------------------|---------|-----------|------------|-----------|-------|------|--------|-------------|--------------|---------------
+1649328471923847168 | 川师店 | xxx | 办公用品 | 2025-01-15 | 10.50 | 5 | 52.50 | 购买办公用品 | xxx | xxx
+1649328471923847168 | 川师店 | xxx | 水电费 | 2025-01-20 | 0.00 | 0 | 500.00 | 1月水电费 | |
+```
+
+### 注意事项
+1. **门店ID**:必须存在系统中,否则导入会失败
+2. **支出日期**:必须是日期格式,推荐格式:`YYYY-MM-DD`,如:`2025-01-15`
+3. **金额**:必须是数字,支持小数,如:52.50
+4. **单价和数量**:如果为空,默认为0
+5. **空行处理**:如果门店ID和门店名称都为空,该行会被跳过
+
+---
+
+## 🔗 导入接口说明
+
+### 合作成本表导入接口
+```
+POST /api/Extend/LqCooperationCost/Actions/Import
+Content-Type: multipart/form-data
+
+参数:
+- file: Excel文件(必填)
+```
+
+### 店内支出表导入接口
+```
+POST /api/Extend/LqStoreExpense/Actions/Import
+Content-Type: multipart/form-data
+
+参数:
+- file: Excel文件(必填)
+```
+
+### 返回结果
+```json
+{
+ "success": true,
+ "message": "导入完成:成功2条,失败0条",
+ "successCount": 2,
+ "failCount": 0,
+ "failMessages": []
+}
+```
+
+---
+
+## 📝 测试数据准备
+
+### 合作成本表测试数据(示例)
+
+请创建一个Excel文件,包含以下测试数据:
+
+| 门店ID | 门店名称 | 年份 | 月份 | 合计金额 | 备注说明 |
+|--------|---------|------|------|----------|----------|
+| (请填写实际门店ID) | 测试门店1 | 2025 | 202501 | 5000.00 | 测试数据1 |
+| (请填写实际门店ID) | 测试门店2 | 2025 | 202501 | 3000.00 | 测试数据2 |
+| (请填写实际门店ID) | 测试门店1 | 2025 | 202502 | 6000.00 | 测试数据3 |
+
+### 店内支出表测试数据(示例)
+
+请创建一个Excel文件,包含以下测试数据:
+
+| 门店ID | 门店名称 | 支出分类ID | 支出分类名称 | 支出日期 | 单价 | 数量 | 金额 | 备注说明 | 关联报销申请ID | 关联购买记录ID |
+|--------|---------|-----------|------------|---------|------|------|------|----------|--------------|--------------|
+| (请填写实际门店ID) | 测试门店1 | | 办公用品 | 2025-01-15 | 10.50 | 5 | 52.50 | 测试支出1 | | |
+| (请填写实际门店ID) | 测试门店1 | | 水电费 | 2025-01-20 | 0 | 0 | 500.00 | 测试支出2 | | |
+| (请填写实际门店ID) | 测试门店2 | | 交通费 | 2025-01-25 | 50.00 | 2 | 100.00 | 测试支出3 | | |
+
+---
+
+## ⚠️ 重要提示
+
+1. **门店ID获取**:可以通过门店列表接口获取实际的门店ID
+2. **日期格式**:支出日期必须使用标准日期格式,推荐使用 `YYYY-MM-DD`
+3. **月份格式**:合作成本表的月份必须是YYYYMM格式(6位字符串),如:202501
+4. **金额精度**:所有金额字段支持2位小数
+5. **重复数据**:合作成本表会检查相同门店、年份、月份是否已存在,如果存在会跳过
+6. **错误处理**:导入过程中如果有错误,会在返回结果中列出所有错误信息
+
diff --git a/antis-ncc-admin/.env.development b/antis-ncc-admin/.env.development
index c236b7d..f6590fa 100644
--- a/antis-ncc-admin/.env.development
+++ b/antis-ncc-admin/.env.development
@@ -2,7 +2,7 @@
VUE_CLI_BABEL_TRANSPILE_MODULES = true
# VUE_APP_BASE_API = 'https://erp.lvqianmeiye.com'
-VUE_APP_BASE_API = 'http://erp_test.lvqianmeiye.com'
-# VUE_APP_BASE_API = 'http://localhost:2011'
+# VUE_APP_BASE_API = 'http://erp_test.lvqianmeiye.com'
+VUE_APP_BASE_API = 'http://localhost:2011'
# VUE_APP_BASE_API = 'http://localhost:2011'
VUE_APP_BASE_WSS = 'ws://192.168.110.45:2011/websocket'
diff --git a/excel/合作成本表.xlsx b/excel/合作成本表.xlsx
new file mode 100644
index 0000000..862d084
--- /dev/null
+++ b/excel/合作成本表.xlsx
diff --git a/excel/店内支出表.xlsx b/excel/店内支出表.xlsx
new file mode 100644
index 0000000..77bb348
--- /dev/null
+++ b/excel/店内支出表.xlsx
diff --git a/excel/考勤统计导入模板_11月.xlsx b/excel/考勤统计导入模板_11月.xlsx
new file mode 100644
index 0000000..0ab8932
--- /dev/null
+++ b/excel/考勤统计导入模板_11月.xlsx
diff --git a/netcore/src/Application/NCC.API/Files/TemporaryFile/合作成本表.xls b/netcore/src/Application/NCC.API/Files/TemporaryFile/合作成本表.xls
new file mode 100644
index 0000000..1dcef9f
--- /dev/null
+++ b/netcore/src/Application/NCC.API/Files/TemporaryFile/合作成本表.xls
diff --git a/netcore/src/Application/NCC.API/Files/TemporaryFile/店内支出表.xls b/netcore/src/Application/NCC.API/Files/TemporaryFile/店内支出表.xls
new file mode 100644
index 0000000..296dc9a
--- /dev/null
+++ b/netcore/src/Application/NCC.API/Files/TemporaryFile/店内支出表.xls
diff --git a/netcore/src/Application/NCC.API/Files/TemporaryFile/报销表明细_2025年01月.xls b/netcore/src/Application/NCC.API/Files/TemporaryFile/报销表明细_2025年01月.xls
new file mode 100644
index 0000000..6202775
--- /dev/null
+++ b/netcore/src/Application/NCC.API/Files/TemporaryFile/报销表明细_2025年01月.xls
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostCrInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostCrInput.cs
new file mode 100644
index 0000000..ff835a3
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostCrInput.cs
@@ -0,0 +1,41 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqCooperationCost
+{
+ ///
+ /// 合作成本表创建输入参数
+ ///
+ public class LqCooperationCostCrInput
+ {
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ public int year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ public string month { get; set; }
+
+ ///
+ /// 合计金额
+ ///
+ public decimal totalAmount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string remarks { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostInfoOutput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostInfoOutput.cs
new file mode 100644
index 0000000..c2a3238
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostInfoOutput.cs
@@ -0,0 +1,66 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqCooperationCost
+{
+ ///
+ /// 合作成本表详情输出参数
+ ///
+ public class LqCooperationCostInfoOutput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ public int year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ public string month { get; set; }
+
+ ///
+ /// 合计金额
+ ///
+ public decimal totalAmount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string remarks { get; set; }
+
+ ///
+ /// 创建人ID
+ ///
+ public string createUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? createTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ public string updateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ public DateTime? updateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListOutput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListOutput.cs
new file mode 100644
index 0000000..75f2c85
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListOutput.cs
@@ -0,0 +1,66 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqCooperationCost
+{
+ ///
+ /// 合作成本表列表输出参数
+ ///
+ public class LqCooperationCostListOutput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ public int year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ public string month { get; set; }
+
+ ///
+ /// 合计金额
+ ///
+ public decimal totalAmount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string remarks { get; set; }
+
+ ///
+ /// 创建人ID
+ ///
+ public string createUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? createTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ public string updateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ public DateTime? updateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListQueryInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListQueryInput.cs
new file mode 100644
index 0000000..8251256
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostListQueryInput.cs
@@ -0,0 +1,41 @@
+using NCC.Common.Filter;
+
+namespace NCC.Extend.Entitys.Dto.LqCooperationCost
+{
+ ///
+ /// 合作成本表列表查询输入参数
+ ///
+ public class LqCooperationCostListQueryInput : PageInputBase
+ {
+ ///
+ /// 选择导出数据key
+ ///
+ public string selectKey { get; set; }
+
+ ///
+ /// 数据类型(0:分页 1:全部)
+ ///
+ public int dataType { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ public int? year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ public string month { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostUpInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostUpInput.cs
new file mode 100644
index 0000000..e71c08f
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqCooperationCost/LqCooperationCostUpInput.cs
@@ -0,0 +1,46 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqCooperationCost
+{
+ ///
+ /// 合作成本表更新输入参数
+ ///
+ public class LqCooperationCostUpInput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ public int year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ public string month { get; set; }
+
+ ///
+ /// 合计金额
+ ///
+ public decimal totalAmount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string remarks { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseCrInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseCrInput.cs
new file mode 100644
index 0000000..4800fe9
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseCrInput.cs
@@ -0,0 +1,73 @@
+using System;
+using System.Collections.Generic;
+using NCC.Common.Model;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreExpense
+{
+ ///
+ /// 店内支出表创建输入参数
+ ///
+ public class LqStoreExpenseCrInput
+ {
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 支出分类ID(关联lq_reimbursement_category.F_Id)
+ ///
+ public string expenseCategoryId { get; set; }
+
+ ///
+ /// 支出分类名称
+ ///
+ public string expenseCategoryName { get; set; }
+
+ ///
+ /// 支出日期
+ ///
+ public DateTime expenseDate { get; set; }
+
+ ///
+ /// 单价
+ ///
+ public decimal unitPrice { get; set; }
+
+ ///
+ /// 数量
+ ///
+ public int quantity { get; set; }
+
+ ///
+ /// 金额
+ ///
+ public decimal amount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string memo { get; set; }
+
+ ///
+ /// 附件
+ ///
+ public List attachment { get; set; }
+
+ ///
+ /// 关联报销申请ID(可选)
+ ///
+ public string relatedReimbursementId { get; set; }
+
+ ///
+ /// 关联购买记录ID(可选)
+ ///
+ public string relatedPurchaseRecordId { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseInfoOutput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseInfoOutput.cs
new file mode 100644
index 0000000..09251b2
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseInfoOutput.cs
@@ -0,0 +1,98 @@
+using System;
+using System.Collections.Generic;
+using NCC.Common.Model;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreExpense
+{
+ ///
+ /// 店内支出表详情输出参数
+ ///
+ public class LqStoreExpenseInfoOutput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 支出分类ID
+ ///
+ public string expenseCategoryId { get; set; }
+
+ ///
+ /// 支出分类名称
+ ///
+ public string expenseCategoryName { get; set; }
+
+ ///
+ /// 支出日期
+ ///
+ public DateTime expenseDate { get; set; }
+
+ ///
+ /// 单价
+ ///
+ public decimal unitPrice { get; set; }
+
+ ///
+ /// 数量
+ ///
+ public int quantity { get; set; }
+
+ ///
+ /// 金额
+ ///
+ public decimal amount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string memo { get; set; }
+
+ ///
+ /// 附件
+ ///
+ public List attachment { get; set; }
+
+ ///
+ /// 关联报销申请ID
+ ///
+ public string relatedReimbursementId { get; set; }
+
+ ///
+ /// 关联购买记录ID
+ ///
+ public string relatedPurchaseRecordId { get; set; }
+
+ ///
+ /// 创建人ID
+ ///
+ public string createUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? createTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ public string updateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ public DateTime? updateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListOutput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListOutput.cs
new file mode 100644
index 0000000..5bf9201
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListOutput.cs
@@ -0,0 +1,91 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreExpense
+{
+ ///
+ /// 店内支出表列表输出参数
+ ///
+ public class LqStoreExpenseListOutput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 支出分类ID
+ ///
+ public string expenseCategoryId { get; set; }
+
+ ///
+ /// 支出分类名称
+ ///
+ public string expenseCategoryName { get; set; }
+
+ ///
+ /// 支出日期
+ ///
+ public DateTime expenseDate { get; set; }
+
+ ///
+ /// 单价
+ ///
+ public decimal unitPrice { get; set; }
+
+ ///
+ /// 数量
+ ///
+ public int quantity { get; set; }
+
+ ///
+ /// 金额
+ ///
+ public decimal amount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string memo { get; set; }
+
+ ///
+ /// 关联报销申请ID
+ ///
+ public string relatedReimbursementId { get; set; }
+
+ ///
+ /// 关联购买记录ID
+ ///
+ public string relatedPurchaseRecordId { get; set; }
+
+ ///
+ /// 创建人ID
+ ///
+ public string createUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ public DateTime? createTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ public string updateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ public DateTime? updateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListQueryInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListQueryInput.cs
new file mode 100644
index 0000000..e637356
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseListQueryInput.cs
@@ -0,0 +1,46 @@
+using NCC.Common.Filter;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreExpense
+{
+ ///
+ /// 店内支出表列表查询输入参数
+ ///
+ public class LqStoreExpenseListQueryInput : PageInputBase
+ {
+ ///
+ /// 选择导出数据key
+ ///
+ public string selectKey { get; set; }
+
+ ///
+ /// 数据类型(0:分页 1:全部)
+ ///
+ public int dataType { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 支出分类ID
+ ///
+ public string expenseCategoryId { get; set; }
+
+ ///
+ /// 支出日期(开始)
+ ///
+ public string expenseDateStart { get; set; }
+
+ ///
+ /// 支出日期(结束)
+ ///
+ public string expenseDateEnd { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseUpInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseUpInput.cs
new file mode 100644
index 0000000..15a3776
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreExpense/LqStoreExpenseUpInput.cs
@@ -0,0 +1,78 @@
+using System;
+using System.Collections.Generic;
+using NCC.Common.Model;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreExpense
+{
+ ///
+ /// 店内支出表更新输入参数
+ ///
+ public class LqStoreExpenseUpInput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string id { get; set; }
+
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ public string storeId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string storeName { get; set; }
+
+ ///
+ /// 支出分类ID(关联lq_reimbursement_category.F_Id)
+ ///
+ public string expenseCategoryId { get; set; }
+
+ ///
+ /// 支出分类名称
+ ///
+ public string expenseCategoryName { get; set; }
+
+ ///
+ /// 支出日期
+ ///
+ public DateTime expenseDate { get; set; }
+
+ ///
+ /// 单价
+ ///
+ public decimal unitPrice { get; set; }
+
+ ///
+ /// 数量
+ ///
+ public int quantity { get; set; }
+
+ ///
+ /// 金额
+ ///
+ public decimal amount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ public string memo { get; set; }
+
+ ///
+ /// 附件
+ ///
+ public List attachment { get; set; }
+
+ ///
+ /// 关联报销申请ID(可选)
+ ///
+ public string relatedReimbursementId { get; set; }
+
+ ///
+ /// 关联购买记录ID(可选)
+ ///
+ public string relatedPurchaseRecordId { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryInput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryInput.cs
new file mode 100644
index 0000000..97894e2
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryInput.cs
@@ -0,0 +1,32 @@
+using NCC.Common.Filter;
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreManagerSalary
+{
+ ///
+ /// 店长工资查询参数
+ ///
+ public class StoreManagerSalaryInput : PageInputBase
+ {
+ ///
+ /// 年份
+ ///
+ public int Year { get; set; }
+
+ ///
+ /// 月份
+ ///
+ public int Month { get; set; }
+
+ ///
+ /// 门店ID(可选,用于筛选特定门店)
+ ///
+ public string StoreId { get; set; }
+
+ ///
+ /// 员工姓名/账号(可选,用于模糊搜索)
+ ///
+ public string Keyword { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryOutput.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryOutput.cs
new file mode 100644
index 0000000..5d77b43
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStoreManagerSalary/StoreManagerSalaryOutput.cs
@@ -0,0 +1,236 @@
+using System;
+
+namespace NCC.Extend.Entitys.Dto.LqStoreManagerSalary
+{
+ ///
+ /// 店长工资输出
+ ///
+ public class StoreManagerSalaryOutput
+ {
+ ///
+ /// 主键ID
+ ///
+ public string Id { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ public string StoreName { get; set; }
+
+ ///
+ /// 员工姓名
+ ///
+ public string EmployeeName { get; set; }
+
+ ///
+ /// 岗位
+ ///
+ public string Position { get; set; }
+
+ ///
+ /// 门店总业绩
+ ///
+ public decimal StoreTotalPerformance { get; set; }
+
+ ///
+ /// 门店开单业绩
+ ///
+ public decimal StoreBillingPerformance { get; set; }
+
+ ///
+ /// 门店退卡业绩
+ ///
+ public decimal StoreRefundPerformance { get; set; }
+
+ ///
+ /// 门店生命线
+ ///
+ public decimal StoreLifeline { get; set; }
+
+ ///
+ /// 业绩完成率
+ ///
+ public decimal PerformanceCompletionRate { get; set; }
+
+ ///
+ /// 业绩是否达标
+ ///
+ public string PerformanceReached { get; set; }
+
+ ///
+ /// 人头是否达标
+ ///
+ public string HeadCountReached { get; set; }
+
+ ///
+ /// 消耗是否达标
+ ///
+ public string ConsumeReached { get; set; }
+
+ ///
+ /// 考核扣款金额
+ ///
+ public decimal AssessmentDeduction { get; set; }
+
+ ///
+ /// 未达标指标数量
+ ///
+ public int UnreachedIndicatorCount { get; set; }
+
+ ///
+ /// 进店消耗人数
+ ///
+ public int HeadCount { get; set; }
+
+ ///
+ /// 目标人头数
+ ///
+ public decimal TargetHeadCount { get; set; }
+
+ ///
+ /// 门店消耗金额
+ ///
+ public decimal StoreConsume { get; set; }
+
+ ///
+ /// 目标消耗金额
+ ///
+ public decimal TargetConsume { get; set; }
+
+ ///
+ /// 销售业绩(开单业绩-退款业绩)
+ ///
+ public decimal SalesPerformance { get; set; }
+
+ ///
+ /// 产品物料(仓库领用金额)
+ ///
+ public decimal ProductMaterial { get; set; }
+
+ ///
+ /// 合作项目成本
+ ///
+ public decimal CooperationCost { get; set; }
+
+ ///
+ /// 店内支出
+ ///
+ public decimal StoreExpense { get; set; }
+
+ ///
+ /// 洗毛巾费用
+ ///
+ public decimal LaundryCost { get; set; }
+
+ ///
+ /// 毛利(销售业绩-产品物料-合作项目成本-店内支出-洗毛巾)
+ ///
+ public decimal GrossProfit { get; set; }
+
+ ///
+ /// 提成比例
+ ///
+ public decimal CommissionRate { get; set; }
+
+ ///
+ /// 提成金额(基于毛利)
+ ///
+ public decimal CommissionAmount { get; set; }
+
+ ///
+ /// 底薪金额(固定4000元)
+ ///
+ public decimal BaseSalary { get; set; }
+
+ ///
+ /// 旗舰店负奖励(800元)
+ ///
+ public decimal FlagshipStoreDeduction { get; set; }
+
+ ///
+ /// 实际底薪(底薪-考核扣款-旗舰店负奖励)
+ ///
+ public decimal ActualBaseSalary { get; set; }
+
+ ///
+ /// 在店天数
+ ///
+ public int WorkingDays { get; set; }
+
+ ///
+ /// 请假天数
+ ///
+ public int LeaveDays { get; set; }
+
+ ///
+ /// 应发工资(实际底薪+提成)
+ ///
+ public decimal GrossSalary { get; set; }
+
+ ///
+ /// 实发工资(应发工资-扣款合计+补贴合计+奖金)
+ ///
+ public decimal ActualSalary { get; set; }
+
+ ///
+ /// 扣款合计
+ ///
+ public decimal TotalDeduction { get; set; }
+
+ ///
+ /// 补贴合计
+ ///
+ public decimal TotalSubsidy { get; set; }
+
+ ///
+ /// 发奖金
+ ///
+ public decimal Bonus { get; set; }
+
+ ///
+ /// 当月是否发放
+ ///
+ public string MonthlyPaymentStatus { get; set; }
+
+ ///
+ /// 支付金额
+ ///
+ public decimal PaidAmount { get; set; }
+
+ ///
+ /// 待支付金额
+ ///
+ public decimal PendingAmount { get; set; }
+
+ ///
+ /// 是否锁定(0未锁定,1已锁定)
+ ///
+ public int IsLocked { get; set; }
+
+ ///
+ /// 门店类型
+ ///
+ public int? StoreType { get; set; }
+
+ ///
+ /// 门店类别
+ ///
+ public int? StoreCategory { get; set; }
+
+ ///
+ /// 是否新店
+ ///
+ public string IsNewStore { get; set; }
+
+ ///
+ /// 新店保护阶段
+ ///
+ public int NewStoreProtectionStage { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ public DateTime UpdateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_cooperation_cost/LqCooperationCostEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_cooperation_cost/LqCooperationCostEntity.cs
new file mode 100644
index 0000000..53efc8d
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_cooperation_cost/LqCooperationCostEntity.cs
@@ -0,0 +1,87 @@
+using System;
+using NCC.Common.Const;
+using SqlSugar;
+
+namespace NCC.Extend.Entitys.lq_cooperation_cost
+{
+ ///
+ /// 合作成本表
+ ///
+ [SugarTable("lq_cooperation_cost")]
+ [Tenant(ClaimConst.TENANT_ID)]
+ public class LqCooperationCostEntity
+ {
+ ///
+ /// 主键ID
+ ///
+ [SugarColumn(ColumnName = "F_Id", IsPrimaryKey = true)]
+ public string Id { get; set; }
+
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ [SugarColumn(ColumnName = "F_StoreId")]
+ public string StoreId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ [SugarColumn(ColumnName = "F_StoreName")]
+ public string StoreName { get; set; }
+
+ ///
+ /// 年份
+ ///
+ [SugarColumn(ColumnName = "F_Year")]
+ public int Year { get; set; }
+
+ ///
+ /// 月份(YYYYMM格式)
+ ///
+ [SugarColumn(ColumnName = "F_Month")]
+ public string Month { get; set; }
+
+ ///
+ /// 合计金额
+ ///
+ [SugarColumn(ColumnName = "F_TotalAmount", DecimalDigits = 2)]
+ public decimal TotalAmount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ [SugarColumn(ColumnName = "F_Remarks")]
+ public string Remarks { get; set; }
+
+ ///
+ /// 是否有效(1:有效 0:无效)
+ ///
+ [SugarColumn(ColumnName = "F_IsEffective")]
+ public int IsEffective { get; set; } = 1;
+
+ ///
+ /// 创建人ID
+ ///
+ [SugarColumn(ColumnName = "F_CreateUser")]
+ public string CreateUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ [SugarColumn(ColumnName = "F_CreateTime")]
+ public DateTime? CreateTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ [SugarColumn(ColumnName = "F_UpdateUser")]
+ public string UpdateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ [SugarColumn(ColumnName = "F_UpdateTime")]
+ public DateTime? UpdateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application/LqInventoryUsageApplicationEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application/LqInventoryUsageApplicationEntity.cs
index b4fa096..556f6ad 100644
--- a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application/LqInventoryUsageApplicationEntity.cs
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application/LqInventoryUsageApplicationEntity.cs
@@ -128,3 +128,5 @@ namespace NCC.Extend.Entitys.lq_inventory_usage_application
}
+
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application_node/LqInventoryUsageApplicationNodeEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application_node/LqInventoryUsageApplicationNodeEntity.cs
index 2de8618..8aafa4a 100644
--- a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application_node/LqInventoryUsageApplicationNodeEntity.cs
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_application_node/LqInventoryUsageApplicationNodeEntity.cs
@@ -56,3 +56,5 @@ namespace NCC.Extend.Entitys.lq_inventory_usage_application_node
}
+
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_approval_record/LqInventoryUsageApprovalRecordEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_approval_record/LqInventoryUsageApprovalRecordEntity.cs
index 5826882..15613a3 100644
--- a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_approval_record/LqInventoryUsageApprovalRecordEntity.cs
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_inventory_usage_approval_record/LqInventoryUsageApprovalRecordEntity.cs
@@ -74,3 +74,5 @@ namespace NCC.Extend.Entitys.lq_inventory_usage_approval_record
}
+
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_expense/LqStoreExpenseEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_expense/LqStoreExpenseEntity.cs
new file mode 100644
index 0000000..3d172be
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_expense/LqStoreExpenseEntity.cs
@@ -0,0 +1,123 @@
+using System;
+using NCC.Common.Const;
+using SqlSugar;
+
+namespace NCC.Extend.Entitys.lq_store_expense
+{
+ ///
+ /// 店内支出表
+ ///
+ [SugarTable("lq_store_expense")]
+ [Tenant(ClaimConst.TENANT_ID)]
+ public class LqStoreExpenseEntity
+ {
+ ///
+ /// 主键ID
+ ///
+ [SugarColumn(ColumnName = "F_Id", IsPrimaryKey = true)]
+ public string Id { get; set; }
+
+ ///
+ /// 门店ID(关联lq_mdxx.F_Id)
+ ///
+ [SugarColumn(ColumnName = "F_StoreId")]
+ public string StoreId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ [SugarColumn(ColumnName = "F_StoreName")]
+ public string StoreName { get; set; }
+
+ ///
+ /// 支出分类ID(关联lq_reimbursement_category.F_Id)
+ ///
+ [SugarColumn(ColumnName = "F_ExpenseCategoryId")]
+ public string ExpenseCategoryId { get; set; }
+
+ ///
+ /// 支出分类名称
+ ///
+ [SugarColumn(ColumnName = "F_ExpenseCategoryName")]
+ public string ExpenseCategoryName { get; set; }
+
+ ///
+ /// 支出日期
+ ///
+ [SugarColumn(ColumnName = "F_ExpenseDate")]
+ public DateTime ExpenseDate { get; set; }
+
+ ///
+ /// 单价
+ ///
+ [SugarColumn(ColumnName = "F_UnitPrice", DecimalDigits = 2)]
+ public decimal UnitPrice { get; set; }
+
+ ///
+ /// 数量
+ ///
+ [SugarColumn(ColumnName = "F_Quantity")]
+ public int Quantity { get; set; }
+
+ ///
+ /// 金额
+ ///
+ [SugarColumn(ColumnName = "F_Amount", DecimalDigits = 2)]
+ public decimal Amount { get; set; }
+
+ ///
+ /// 备注说明
+ ///
+ [SugarColumn(ColumnName = "F_Memo")]
+ public string Memo { get; set; }
+
+ ///
+ /// 附件(JSON格式)
+ ///
+ [SugarColumn(ColumnName = "F_Attachment", ColumnDataType = "TEXT")]
+ public string Attachment { get; set; }
+
+ ///
+ /// 关联报销申请ID(可选)
+ ///
+ [SugarColumn(ColumnName = "F_RelatedReimbursementId")]
+ public string RelatedReimbursementId { get; set; }
+
+ ///
+ /// 关联购买记录ID(可选)
+ ///
+ [SugarColumn(ColumnName = "F_RelatedPurchaseRecordId")]
+ public string RelatedPurchaseRecordId { get; set; }
+
+ ///
+ /// 是否有效(1:有效 0:无效)
+ ///
+ [SugarColumn(ColumnName = "F_IsEffective")]
+ public int IsEffective { get; set; } = 1;
+
+ ///
+ /// 创建人ID
+ ///
+ [SugarColumn(ColumnName = "F_CreateUser")]
+ public string CreateUser { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ [SugarColumn(ColumnName = "F_CreateTime")]
+ public DateTime? CreateTime { get; set; }
+
+ ///
+ /// 更新人ID
+ ///
+ [SugarColumn(ColumnName = "F_UpdateUser")]
+ public string UpdateUser { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ [SugarColumn(ColumnName = "F_UpdateTime")]
+ public DateTime? UpdateTime { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_manager_salary_statistics/LqStoreManagerSalaryStatisticsEntity.cs b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_manager_salary_statistics/LqStoreManagerSalaryStatisticsEntity.cs
new file mode 100644
index 0000000..1ec9afc
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_store_manager_salary_statistics/LqStoreManagerSalaryStatisticsEntity.cs
@@ -0,0 +1,417 @@
+using System;
+using NCC.Common.Const;
+using SqlSugar;
+
+namespace NCC.Extend.Entitys.lq_store_manager_salary_statistics
+{
+ ///
+ /// 店长工资统计表
+ ///
+ [SugarTable("lq_store_manager_salary_statistics")]
+ [Tenant(ClaimConst.TENANT_ID)]
+ public class LqStoreManagerSalaryStatisticsEntity
+ {
+ ///
+ /// 主键ID
+ ///
+ [SugarColumn(ColumnName = "F_Id", IsPrimaryKey = true)]
+ public string Id { get; set; }
+
+ ///
+ /// 门店ID
+ ///
+ [SugarColumn(ColumnName = "F_StoreId")]
+ public string StoreId { get; set; }
+
+ ///
+ /// 门店名称
+ ///
+ [SugarColumn(ColumnName = "F_StoreName")]
+ public string StoreName { get; set; }
+
+ ///
+ /// 核算岗位
+ ///
+ [SugarColumn(ColumnName = "F_Position")]
+ public string Position { get; set; }
+
+ ///
+ /// 员工ID
+ ///
+ [SugarColumn(ColumnName = "F_EmployeeId")]
+ public string EmployeeId { get; set; }
+
+ ///
+ /// 员工姓名
+ ///
+ [SugarColumn(ColumnName = "F_EmployeeName")]
+ public string EmployeeName { get; set; }
+
+ ///
+ /// 统计月份(YYYYMM)
+ ///
+ [SugarColumn(ColumnName = "F_StatisticsMonth")]
+ public string StatisticsMonth { get; set; }
+
+ ///
+ /// 门店类型
+ ///
+ [SugarColumn(ColumnName = "F_StoreType")]
+ public int? StoreType { get; set; }
+
+ ///
+ /// 门店类别
+ ///
+ [SugarColumn(ColumnName = "F_StoreCategory")]
+ public int? StoreCategory { get; set; }
+
+ ///
+ /// 是否新店
+ ///
+ [SugarColumn(ColumnName = "F_IsNewStore")]
+ public string IsNewStore { get; set; }
+
+ ///
+ /// 新店保护阶段
+ ///
+ [SugarColumn(ColumnName = "F_NewStoreProtectionStage")]
+ public int NewStoreProtectionStage { get; set; }
+
+ ///
+ /// 门店总业绩
+ ///
+ [SugarColumn(ColumnName = "F_StoreTotalPerformance")]
+ public decimal StoreTotalPerformance { get; set; }
+
+ ///
+ /// 门店开单业绩
+ ///
+ [SugarColumn(ColumnName = "F_StoreBillingPerformance")]
+ public decimal StoreBillingPerformance { get; set; }
+
+ ///
+ /// 门店退卡业绩
+ ///
+ [SugarColumn(ColumnName = "F_StoreRefundPerformance")]
+ public decimal StoreRefundPerformance { get; set; }
+
+ ///
+ /// 门店生命线
+ ///
+ [SugarColumn(ColumnName = "F_StoreLifeline")]
+ public decimal StoreLifeline { get; set; }
+
+ ///
+ /// 业绩完成率
+ ///
+ [SugarColumn(ColumnName = "F_PerformanceCompletionRate")]
+ public decimal PerformanceCompletionRate { get; set; }
+
+ ///
+ /// 业绩是否达标
+ ///
+ [SugarColumn(ColumnName = "F_PerformanceReached")]
+ public string PerformanceReached { get; set; }
+
+ ///
+ /// 进店消耗人数
+ ///
+ [SugarColumn(ColumnName = "F_HeadCount")]
+ public int HeadCount { get; set; }
+
+ ///
+ /// 目标人头数
+ ///
+ [SugarColumn(ColumnName = "F_TargetHeadCount")]
+ public decimal TargetHeadCount { get; set; }
+
+ ///
+ /// 人头是否达标
+ ///
+ [SugarColumn(ColumnName = "F_HeadCountReached")]
+ public string HeadCountReached { get; set; }
+
+ ///
+ /// 门店消耗金额
+ ///
+ [SugarColumn(ColumnName = "F_StoreConsume")]
+ public decimal StoreConsume { get; set; }
+
+ ///
+ /// 目标消耗金额
+ ///
+ [SugarColumn(ColumnName = "F_TargetConsume")]
+ public decimal TargetConsume { get; set; }
+
+ ///
+ /// 消耗是否达标
+ ///
+ [SugarColumn(ColumnName = "F_ConsumeReached")]
+ public string ConsumeReached { get; set; }
+
+ ///
+ /// 未达标指标数量
+ ///
+ [SugarColumn(ColumnName = "F_UnreachedIndicatorCount")]
+ public int UnreachedIndicatorCount { get; set; }
+
+ ///
+ /// 考核扣款金额
+ ///
+ [SugarColumn(ColumnName = "F_AssessmentDeduction")]
+ public decimal AssessmentDeduction { get; set; }
+
+ ///
+ /// 销售业绩(开单业绩-退款业绩)
+ ///
+ [SugarColumn(ColumnName = "F_SalesPerformance")]
+ public decimal SalesPerformance { get; set; }
+
+ ///
+ /// 产品物料(仓库领用金额)
+ ///
+ [SugarColumn(ColumnName = "F_ProductMaterial")]
+ public decimal ProductMaterial { get; set; }
+
+ ///
+ /// 合作项目成本
+ ///
+ [SugarColumn(ColumnName = "F_CooperationCost")]
+ public decimal CooperationCost { get; set; }
+
+ ///
+ /// 店内支出
+ ///
+ [SugarColumn(ColumnName = "F_StoreExpense")]
+ public decimal StoreExpense { get; set; }
+
+ ///
+ /// 洗毛巾费用
+ ///
+ [SugarColumn(ColumnName = "F_LaundryCost")]
+ public decimal LaundryCost { get; set; }
+
+ ///
+ /// 毛利(销售业绩-产品物料-合作项目成本-店内支出-洗毛巾)
+ ///
+ [SugarColumn(ColumnName = "F_GrossProfit")]
+ public decimal GrossProfit { get; set; }
+
+ ///
+ /// 提成比例
+ ///
+ [SugarColumn(ColumnName = "F_CommissionRate")]
+ public decimal CommissionRate { get; set; }
+
+ ///
+ /// 提成金额(基于毛利)
+ ///
+ [SugarColumn(ColumnName = "F_CommissionAmount")]
+ public decimal CommissionAmount { get; set; }
+
+ ///
+ /// 底薪金额(固定4000元)
+ ///
+ [SugarColumn(ColumnName = "F_BaseSalary")]
+ public decimal BaseSalary { get; set; }
+
+ ///
+ /// 旗舰店负奖励(800元)
+ ///
+ [SugarColumn(ColumnName = "F_FlagshipStoreDeduction")]
+ public decimal FlagshipStoreDeduction { get; set; }
+
+ ///
+ /// 实际底薪(底薪-考核扣款-旗舰店负奖励)
+ ///
+ [SugarColumn(ColumnName = "F_ActualBaseSalary")]
+ public decimal ActualBaseSalary { get; set; }
+
+ ///
+ /// 在店天数
+ ///
+ [SugarColumn(ColumnName = "F_WorkingDays")]
+ public int WorkingDays { get; set; }
+
+ ///
+ /// 请假天数
+ ///
+ [SugarColumn(ColumnName = "F_LeaveDays")]
+ public int LeaveDays { get; set; }
+
+ ///
+ /// 应发工资(实际底薪+提成)
+ ///
+ [SugarColumn(ColumnName = "F_GrossSalary")]
+ public decimal GrossSalary { get; set; }
+
+ ///
+ /// 实发工资(应发工资-扣款合计+补贴合计+奖金)
+ ///
+ [SugarColumn(ColumnName = "F_ActualSalary")]
+ public decimal ActualSalary { get; set; }
+
+ ///
+ /// 缺卡扣款
+ ///
+ [SugarColumn(ColumnName = "F_MissingCard")]
+ public decimal MissingCard { get; set; }
+
+ ///
+ /// 迟到扣款
+ ///
+ [SugarColumn(ColumnName = "F_LateArrival")]
+ public decimal LateArrival { get; set; }
+
+ ///
+ /// 请假扣款
+ ///
+ [SugarColumn(ColumnName = "F_LeaveDeduction")]
+ public decimal LeaveDeduction { get; set; }
+
+ ///
+ /// 扣社保
+ ///
+ [SugarColumn(ColumnName = "F_SocialInsuranceDeduction")]
+ public decimal SocialInsuranceDeduction { get; set; }
+
+ ///
+ /// 扣除奖励
+ ///
+ [SugarColumn(ColumnName = "F_RewardDeduction")]
+ public decimal RewardDeduction { get; set; }
+
+ ///
+ /// 扣住宿费
+ ///
+ [SugarColumn(ColumnName = "F_AccommodationDeduction")]
+ public decimal AccommodationDeduction { get; set; }
+
+ ///
+ /// 扣学习期费用
+ ///
+ [SugarColumn(ColumnName = "F_StudyPeriodDeduction")]
+ public decimal StudyPeriodDeduction { get; set; }
+
+ ///
+ /// 扣工作服费用
+ ///
+ [SugarColumn(ColumnName = "F_WorkClothesDeduction")]
+ public decimal WorkClothesDeduction { get; set; }
+
+ ///
+ /// 扣款合计
+ ///
+ [SugarColumn(ColumnName = "F_TotalDeduction")]
+ public decimal TotalDeduction { get; set; }
+
+ ///
+ /// 当月培训补贴
+ ///
+ [SugarColumn(ColumnName = "F_MonthlyTrainingSubsidy")]
+ public decimal MonthlyTrainingSubsidy { get; set; }
+
+ ///
+ /// 当月交通补贴
+ ///
+ [SugarColumn(ColumnName = "F_MonthlyTransportSubsidy")]
+ public decimal MonthlyTransportSubsidy { get; set; }
+
+ ///
+ /// 上月培训补贴
+ ///
+ [SugarColumn(ColumnName = "F_LastMonthTrainingSubsidy")]
+ public decimal LastMonthTrainingSubsidy { get; set; }
+
+ ///
+ /// 上月交通补贴
+ ///
+ [SugarColumn(ColumnName = "F_LastMonthTransportSubsidy")]
+ public decimal LastMonthTransportSubsidy { get; set; }
+
+ ///
+ /// 补贴合计
+ ///
+ [SugarColumn(ColumnName = "F_TotalSubsidy")]
+ public decimal TotalSubsidy { get; set; }
+
+ ///
+ /// 发奖金
+ ///
+ [SugarColumn(ColumnName = "F_Bonus")]
+ public decimal Bonus { get; set; }
+
+ ///
+ /// 退手机押金
+ ///
+ [SugarColumn(ColumnName = "F_ReturnPhoneDeposit")]
+ public decimal ReturnPhoneDeposit { get; set; }
+
+ ///
+ /// 退住宿押金
+ ///
+ [SugarColumn(ColumnName = "F_ReturnAccommodationDeposit")]
+ public decimal ReturnAccommodationDeposit { get; set; }
+
+ ///
+ /// 当月是否发放
+ ///
+ [SugarColumn(ColumnName = "F_MonthlyPaymentStatus")]
+ public string MonthlyPaymentStatus { get; set; }
+
+ ///
+ /// 支付金额
+ ///
+ [SugarColumn(ColumnName = "F_PaidAmount")]
+ public decimal PaidAmount { get; set; }
+
+ ///
+ /// 待支付金额
+ ///
+ [SugarColumn(ColumnName = "F_PendingAmount")]
+ public decimal PendingAmount { get; set; }
+
+ ///
+ /// 补发上月
+ ///
+ [SugarColumn(ColumnName = "F_LastMonthSupplement")]
+ public decimal LastMonthSupplement { get; set; }
+
+ ///
+ /// 当月支付总额
+ ///
+ [SugarColumn(ColumnName = "F_MonthlyTotalPayment")]
+ public decimal MonthlyTotalPayment { get; set; }
+
+ ///
+ /// 是否锁定(0未锁定,1已锁定)
+ ///
+ [SugarColumn(ColumnName = "F_IsLocked")]
+ public int IsLocked { get; set; }
+
+ ///
+ /// 创建时间
+ ///
+ [SugarColumn(ColumnName = "F_CreateTime")]
+ public DateTime CreateTime { get; set; }
+
+ ///
+ /// 更新时间
+ ///
+ [SugarColumn(ColumnName = "F_UpdateTime")]
+ public DateTime UpdateTime { get; set; }
+
+ ///
+ /// 创建人
+ ///
+ [SugarColumn(ColumnName = "F_CreateUser")]
+ public string CreateUser { get; set; }
+
+ ///
+ /// 更新人
+ ///
+ [SugarColumn(ColumnName = "F_UpdateUser")]
+ public string UpdateUser { get; set; }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqCooperationCostService.cs b/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqCooperationCostService.cs
new file mode 100644
index 0000000..0d35793
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqCooperationCostService.cs
@@ -0,0 +1,7 @@
+namespace NCC.Extend.Interfaces.LqCooperationCost
+{
+ public interface ILqCooperationCostService
+ {
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqStoreExpenseService.cs b/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqStoreExpenseService.cs
new file mode 100644
index 0000000..e563d30
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend.Interfaces/ILqStoreExpenseService.cs
@@ -0,0 +1,7 @@
+namespace NCC.Extend.Interfaces.LqStoreExpense
+{
+ public interface ILqStoreExpenseService
+ {
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend/LqCooperationCostService.cs b/netcore/src/Modularity/Extend/NCC.Extend/LqCooperationCostService.cs
new file mode 100644
index 0000000..ea062f6
--- /dev/null
+++ b/netcore/src/Modularity/Extend/NCC.Extend/LqCooperationCostService.cs
@@ -0,0 +1,516 @@
+using NCC.Common.Core.Manager;
+using NCC.Common.Enum;
+using NCC.Common.Extension;
+using NCC.Common.Filter;
+using NCC.Dependency;
+using NCC.DynamicApiController;
+using NCC.FriendlyException;
+using NCC.Extend.Interfaces.LqCooperationCost;
+using Mapster;
+using Microsoft.AspNetCore.Mvc;
+using SqlSugar;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Threading.Tasks;
+using NCC.Extend.Entitys.lq_cooperation_cost;
+using NCC.Extend.Entitys.Dto.LqCooperationCost;
+using NCC.Extend.Entitys.lq_mdxx;
+using Yitter.IdGenerator;
+using NCC.Common.Helper;
+using NCC.Common.Model.NPOI;
+using NCC.Common.Configuration;
+using NCC.DataEncryption;
+using NCC.ClayObject;
+using NCC.Common.Const;
+using NCC.Extend.Entitys.Enum;
+using Microsoft.AspNetCore.Http;
+using System.IO;
+using System.Data;
+
+namespace NCC.Extend.LqCooperationCost
+{
+ ///
+ /// 合作成本表服务
+ ///
+ [ApiDescriptionSettings(Tag = "Extend", Name = "LqCooperationCost", Order = 200)]
+ [Route("api/Extend/[controller]")]
+ public class LqCooperationCostService : ILqCooperationCostService, IDynamicApiController, ITransient
+ {
+ private readonly ISqlSugarRepository _repository;
+ private readonly SqlSugarScope _db;
+ private readonly IUserManager _userManager;
+
+ ///
+ /// 初始化一个类型的新实例
+ ///
+ public LqCooperationCostService(
+ ISqlSugarRepository repository,
+ IUserManager userManager)
+ {
+ _repository = repository;
+ _db = _repository.Context;
+ _userManager = userManager;
+ }
+
+ ///
+ /// 获取合作成本表详情
+ ///
+ /// 主键ID
+ ///
+ [HttpGet("{id}")]
+ public async Task GetInfo(string id)
+ {
+ var entity = await _db.Queryable()
+ .Where(x => x.Id == id && x.IsEffective == StatusEnum.有效.GetHashCode())
+ .FirstAsync();
+ _ = entity ?? throw NCCException.Oh(ErrorCode.COM1005);
+ var output = entity.Adapt();
+ return output;
+ }
+
+ ///
+ /// 获取合作成本表列表
+ ///
+ /// 请求参数
+ ///
+ [HttpGet("")]
+ public async Task GetList([FromQuery] LqCooperationCostListQueryInput input)
+ {
+ var sidx = input.sidx ?? "CreateTime";
+ var sortType = input.sort?.ToLower() == "asc" ? OrderByType.Asc : OrderByType.Desc;
+ var query = _db.Queryable()
+ .Where(x => x.IsEffective == StatusEnum.有效.GetHashCode())
+ .WhereIF(!string.IsNullOrEmpty(input.storeId), x => x.StoreId == input.storeId)
+ .WhereIF(!string.IsNullOrEmpty(input.storeName), x => x.StoreName.Contains(input.storeName))
+ .WhereIF(input.year.HasValue, x => x.Year == input.year.Value)
+ .WhereIF(!string.IsNullOrEmpty(input.month), x => x.Month == input.month);
+
+ // 处理排序
+ switch (sidx.ToLower())
+ {
+ case "id":
+ query = query.OrderBy(x => x.Id, sortType);
+ break;
+ case "createtime":
+ query = query.OrderBy(x => x.CreateTime, sortType);
+ break;
+ case "storename":
+ query = query.OrderBy(x => x.StoreName, sortType);
+ break;
+ case "year":
+ query = query.OrderBy(x => x.Year, sortType);
+ break;
+ case "month":
+ query = query.OrderBy(x => x.Month, sortType);
+ break;
+ default:
+ query = query.OrderBy(x => x.CreateTime, OrderByType.Desc);
+ break;
+ }
+
+ var total = await query.CountAsync();
+ var list = await query.ToPageListAsync(input.currentPage, input.pageSize);
+
+ var result = list.Select(x => new LqCooperationCostListOutput
+ {
+ id = x.Id,
+ storeId = x.StoreId,
+ storeName = x.StoreName,
+ year = x.Year,
+ month = x.Month,
+ totalAmount = x.TotalAmount,
+ remarks = x.Remarks,
+ createUser = x.CreateUser,
+ createTime = x.CreateTime,
+ updateUser = x.UpdateUser,
+ updateTime = x.UpdateTime
+ }).ToList();
+
+ return PageResult.SqlSugarPageResult(
+ new SqlSugarPagedList
+ {
+ list = result,
+ pagination = new PagedModel { PageIndex = input.currentPage, PageSize = input.pageSize, Total = total }
+ });
+ }
+
+ ///
+ /// 获取合作成本表无分页列表
+ ///
+ /// 请求参数
+ ///
+ [HttpGet("Actions/GetNoPagingList")]
+ public async Task> GetNoPagingList([FromQuery] LqCooperationCostListQueryInput input)
+ {
+ var sidx = input.sidx ?? "CreateTime";
+ var sortType = input.sort?.ToLower() == "asc" ? OrderByType.Asc : OrderByType.Desc;
+ var query = _db.Queryable()
+ .Where(x => x.IsEffective == StatusEnum.有效.GetHashCode())
+ .WhereIF(!string.IsNullOrEmpty(input.storeId), x => x.StoreId == input.storeId)
+ .WhereIF(!string.IsNullOrEmpty(input.storeName), x => x.StoreName.Contains(input.storeName))
+ .WhereIF(input.year.HasValue, x => x.Year == input.year.Value)
+ .WhereIF(!string.IsNullOrEmpty(input.month), x => x.Month == input.month);
+
+ // 处理排序
+ switch (sidx.ToLower())
+ {
+ case "id":
+ query = query.OrderBy(x => x.Id, sortType);
+ break;
+ case "createtime":
+ query = query.OrderBy(x => x.CreateTime, sortType);
+ break;
+ case "storename":
+ query = query.OrderBy(x => x.StoreName, sortType);
+ break;
+ case "year":
+ query = query.OrderBy(x => x.Year, sortType);
+ break;
+ case "month":
+ query = query.OrderBy(x => x.Month, sortType);
+ break;
+ default:
+ query = query.OrderBy(x => x.CreateTime, OrderByType.Desc);
+ break;
+ }
+
+ var list = await query
+ .Select(x => new LqCooperationCostListOutput
+ {
+ id = x.Id,
+ storeId = x.StoreId,
+ storeName = x.StoreName,
+ year = x.Year,
+ month = x.Month,
+ totalAmount = x.TotalAmount,
+ remarks = x.Remarks,
+ createUser = x.CreateUser,
+ createTime = x.CreateTime,
+ updateUser = x.UpdateUser,
+ updateTime = x.UpdateTime
+ })
+ .ToListAsync();
+ return list;
+ }
+
+ ///
+ /// 创建合作成本表
+ ///
+ /// 参数
+ ///
+ [HttpPost("")]
+ public async Task Create([FromBody] LqCooperationCostCrInput input)
+ {
+ var userInfo = await _userManager.GetUserInfo();
+ var entity = input.Adapt();
+ entity.Id = YitIdHelper.NextId().ToString();
+ entity.IsEffective = StatusEnum.有效.GetHashCode();
+ entity.CreateUser = _userManager.UserId;
+ entity.CreateTime = DateTime.Now;
+
+ // 如果未提供门店名称,根据门店ID查询
+ if (string.IsNullOrEmpty(entity.StoreName) && !string.IsNullOrEmpty(entity.StoreId))
+ {
+ var store = await _db.Queryable()
+ .Where(x => x.Id == entity.StoreId)
+ .Select(x => x.Dm)
+ .FirstAsync();
+ entity.StoreName = store;
+ }
+
+ var isOk = await _db.Insertable(entity).ExecuteCommandAsync();
+ if (!(isOk > 0)) throw NCCException.Oh(ErrorCode.COM1000);
+ }
+
+ ///
+ /// 更新合作成本表
+ ///
+ /// 主键
+ /// 参数
+ ///
+ [HttpPut("{id}")]
+ public async Task Update(string id, [FromBody] LqCooperationCostUpInput input)
+ {
+ var entity = await _db.Queryable()
+ .Where(x => x.Id == id && x.IsEffective == StatusEnum.有效.GetHashCode())
+ .FirstAsync();
+ _ = entity ?? throw NCCException.Oh(ErrorCode.COM1005);
+
+ entity.StoreId = input.storeId;
+ entity.StoreName = input.storeName;
+ entity.Year = input.year;
+ entity.Month = input.month;
+ entity.TotalAmount = input.totalAmount;
+ entity.Remarks = input.remarks;
+ entity.UpdateUser = _userManager.UserId;
+ entity.UpdateTime = DateTime.Now;
+
+ // 如果未提供门店名称,根据门店ID查询
+ if (string.IsNullOrEmpty(entity.StoreName) && !string.IsNullOrEmpty(entity.StoreId))
+ {
+ var store = await _db.Queryable()
+ .Where(x => x.Id == entity.StoreId)
+ .Select(x => x.Dm)
+ .FirstAsync();
+ entity.StoreName = store;
+ }
+
+ var isOk = await _db.Updateable(entity).ExecuteCommandAsync();
+ if (!(isOk > 0)) throw NCCException.Oh(ErrorCode.COM1001);
+ }
+
+ ///
+ /// 删除合作成本表
+ ///
+ /// 主键
+ ///
+ [HttpDelete("{id}")]
+ public async Task Delete(string id)
+ {
+ var entity = await _db.Queryable()
+ .Where(x => x.Id == id && x.IsEffective == StatusEnum.有效.GetHashCode())
+ .FirstAsync();
+ _ = entity ?? throw NCCException.Oh(ErrorCode.COM1005);
+
+ // 逻辑删除
+ entity.IsEffective = StatusEnum.无效.GetHashCode();
+ entity.UpdateUser = _userManager.UserId;
+ entity.UpdateTime = DateTime.Now;
+
+ var isOk = await _db.Updateable(entity).ExecuteCommandAsync();
+ if (!(isOk > 0)) throw NCCException.Oh(ErrorCode.COM1002);
+ }
+
+ ///
+ /// 导出合作成本表
+ ///
+ /// 请求参数
+ ///
+ [HttpGet("Actions/Export")]
+ public async Task Export([FromQuery] LqCooperationCostListQueryInput input)
+ {
+ var userInfo = await _userManager.GetUserInfo();
+ var exportData = new List();
+ if (input.dataType == 0)
+ {
+ var data = Clay.Object(await this.GetList(input));
+ exportData = data.Solidify>().list;
+ }
+ else
+ {
+ exportData = await this.GetNoPagingList(input);
+ }
+ List paramList = "[{\"value\":\"门店ID\",\"field\":\"storeId\"},{\"value\":\"门店名称\",\"field\":\"storeName\"},{\"value\":\"年份\",\"field\":\"year\"},{\"value\":\"月份\",\"field\":\"month\"},{\"value\":\"合计金额\",\"field\":\"totalAmount\"},{\"value\":\"备注说明\",\"field\":\"remarks\"},{\"value\":\"创建人\",\"field\":\"createUser\"},{\"value\":\"创建时间\",\"field\":\"createTime\"},]".ToList();
+ ExcelConfig excelconfig = new ExcelConfig();
+ excelconfig.FileName = "合作成本表.xls";
+ excelconfig.HeadFont = "微软雅黑";
+ excelconfig.HeadPoint = 10;
+ excelconfig.IsAllSizeColumn = true;
+ excelconfig.ColumnModel = new List();
+ List selectKeyList = !string.IsNullOrEmpty(input.selectKey) ? input.selectKey.Split(',').ToList() : paramList.Select(p => p.field).ToList();
+ foreach (var item in selectKeyList)
+ {
+ var isExist = paramList.Find(p => p.field == item);
+ if (isExist != null)
+ {
+ excelconfig.ColumnModel.Add(new ExcelColumnModel() { Column = isExist.field, ExcelColumn = isExist.value });
+ }
+ }
+ var addPath = FileVariable.TemporaryFilePath + excelconfig.FileName;
+ ExcelExportHelper.Export(exportData, excelconfig, addPath);
+ var fileName = _userManager.UserId + "|" + addPath + "|xls";
+ var output = new
+ {
+ name = excelconfig.FileName,
+ url = "/api/File/Download?encryption=" + DESCEncryption.Encrypt(fileName, "NCC")
+ };
+ return output;
+ }
+
+ ///
+ /// 导入合作成本数据
+ ///
+ ///
+ /// 从Excel文件导入合作成本数据
+ ///
+ /// Excel格式要求:
+ /// 第一行为标题行:门店ID、门店名称、年份、月份、合计金额、备注说明
+ /// 从第二行开始为数据行
+ ///
+ /// 示例请求:
+ /// POST /api/Extend/LqCooperationCost/Actions/Import
+ /// Content-Type: multipart/form-data
+ ///
+ /// Excel文件
+ /// 导入结果
+ /// 导入成功
+ /// 文件格式错误或数据验证失败
+ [HttpPost("Actions/Import")]
+ public async Task Import(IFormFile file)
+ {
+ try
+ {
+ if (file == null || file.Length == 0)
+ {
+ throw NCCException.Oh("请选择要上传的Excel文件");
+ }
+
+ // 检查文件格式
+ var allowedExtensions = new[] { ".xlsx", ".xls" };
+ var fileExtension = Path.GetExtension(file.FileName).ToLowerInvariant();
+ if (!allowedExtensions.Contains(fileExtension))
+ {
+ throw NCCException.Oh("只支持.xlsx和.xls格式的Excel文件");
+ }
+
+ var successCount = 0;
+ var failCount = 0;
+ var failMessages = new List();
+
+ // 保存临时文件
+ var tempFilePath = Path.Combine(Path.GetTempPath(), Guid.NewGuid().ToString() + Path.GetExtension(file.FileName));
+ try
+ {
+ using (var stream = new FileStream(tempFilePath, FileMode.Create))
+ {
+ await file.CopyToAsync(stream);
+ }
+
+ // 使用ExcelImportHelper读取Excel文件(第一行为标题行)
+ var dataTable = ExcelImportHelper.ToDataTable(tempFilePath, 0, 0);
+
+ if (dataTable.Rows.Count <= 1)
+ {
+ throw NCCException.Oh("Excel文件中没有数据行(至少需要标题行和一行数据)");
+ }
+
+ // 从第1行开始读取数据(跳过标题行)
+ for (int i = 1; i < dataTable.Rows.Count; i++)
+ {
+ try
+ {
+ var row = dataTable.Rows[i];
+ var storeId = row[0]?.ToString()?.Trim();
+ var storeName = row[1]?.ToString()?.Trim();
+ var yearText = row[2]?.ToString()?.Trim();
+ var monthText = row[3]?.ToString()?.Trim();
+ var totalAmountText = row[4]?.ToString()?.Trim();
+ var remarks = row[5]?.ToString()?.Trim();
+
+ // 跳过空行
+ if (string.IsNullOrEmpty(storeId) && string.IsNullOrEmpty(storeName))
+ {
+ continue;
+ }
+
+ // 验证必填字段
+ if (string.IsNullOrEmpty(storeId))
+ {
+ failMessages.Add($"第{i + 1}行:门店ID不能为空");
+ failCount++;
+ continue;
+ }
+
+ if (string.IsNullOrEmpty(yearText) || !int.TryParse(yearText, out int year))
+ {
+ failMessages.Add($"第{i + 1}行:年份格式错误(应为数字)");
+ failCount++;
+ continue;
+ }
+
+ if (string.IsNullOrEmpty(monthText) || monthText.Length != 6)
+ {
+ failMessages.Add($"第{i + 1}行:月份格式错误(应为YYYYMM格式,如:202501)");
+ failCount++;
+ continue;
+ }
+
+ if (string.IsNullOrEmpty(totalAmountText) || !decimal.TryParse(totalAmountText, out decimal totalAmount))
+ {
+ failMessages.Add($"第{i + 1}行:合计金额格式错误(应为数字)");
+ failCount++;
+ continue;
+ }
+
+ // 如果未提供门店名称,根据门店ID查询
+ if (string.IsNullOrEmpty(storeName))
+ {
+ var store = await _db.Queryable()
+ .Where(x => x.Id == storeId)
+ .Select(x => x.Dm)
+ .FirstAsync();
+ storeName = store ?? "";
+ }
+
+ // 检查是否已存在相同门店、年份、月份的记录
+ var exists = await _db.Queryable()
+ .Where(x => x.StoreId == storeId && x.Year == year && x.Month == monthText && x.IsEffective == StatusEnum.有效.GetHashCode())
+ .AnyAsync();
+
+ if (exists)
+ {
+ failMessages.Add($"第{i + 1}行:该门店{year}年{monthText}月的记录已存在");
+ failCount++;
+ continue;
+ }
+
+ // 创建记录
+ var entity = new LqCooperationCostEntity
+ {
+ Id = YitIdHelper.NextId().ToString(),
+ StoreId = storeId,
+ StoreName = storeName,
+ Year = year,
+ Month = monthText,
+ TotalAmount = totalAmount,
+ Remarks = remarks,
+ IsEffective = StatusEnum.有效.GetHashCode(),
+ CreateUser = _userManager.UserId,
+ CreateTime = DateTime.Now
+ };
+
+ var isOk = await _db.Insertable(entity).ExecuteCommandAsync();
+ if (isOk > 0)
+ {
+ successCount++;
+ }
+ else
+ {
+ failMessages.Add($"第{i + 1}行:保存失败");
+ failCount++;
+ }
+ }
+ catch (Exception ex)
+ {
+ failMessages.Add($"第{i + 1}行:{ex.Message}");
+ failCount++;
+ }
+ }
+ }
+ finally
+ {
+ // 清理临时文件
+ if (File.Exists(tempFilePath))
+ {
+ File.Delete(tempFilePath);
+ }
+ }
+
+ return new
+ {
+ success = true,
+ message = $"导入完成:成功{successCount}条,失败{failCount}条",
+ successCount = successCount,
+ failCount = failCount,
+ failMessages = failMessages
+ };
+ }
+ catch (Exception ex)
+ {
+ throw NCCException.Oh($"导入失败:{ex.Message}");
+ }
+ }
+ }
+}
+
diff --git a/netcore/src/Modularity/Extend/NCC.Extend/LqReimbursementApplicationService.cs b/netcore/src/Modularity/Extend/NCC.Extend/LqReimbursementApplicationService.cs
index 3de354f..5ce9e32 100644
--- a/netcore/src/Modularity/Extend/NCC.Extend/LqReimbursementApplicationService.cs
+++ b/netcore/src/Modularity/Extend/NCC.Extend/LqReimbursementApplicationService.cs
@@ -1470,5 +1470,233 @@ namespace NCC.Extend.LqReimbursementApplication
return new List