新增工资/仓储/生产日报等模块,移除旧考勤模块
- 新增 PayRoll(工资)、Wms(仓储)、Prod(车速/缫丝/考勤/丝片检测/丝片台账/纤检日报/质量日报) 模块 - 新增对应 Domain 实体、Application DTO/Service、Api Controller 与前端页面 - 移除旧 Attendance 考勤模块(Controller/Service/Entity/DTO 及 5 个前端页面),由 Prod/Kaoqin 取代 - 调整路由、仪表盘、Lsjl 流丝记录实体与服务 - 更新业务种子数据与 DbSeeder - 补充工作进度文档 14-27
This commit is contained in:
@@ -1,18 +0,0 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Attendance;
|
||||
|
||||
/// <summary>考勤打卡记录</summary>
|
||||
[Table(Name = "AttendanceRecords")]
|
||||
[Index("IX_AttendanceRecords_EmployeeId_WorkDate", "EmployeeId, WorkDate", IsUnique = true)]
|
||||
public class AttendanceRecord : BaseEntity
|
||||
{
|
||||
public long EmployeeId { get; set; }
|
||||
public DateTime WorkDate { get; set; } // 考勤日期
|
||||
public DateTime? SignInTime { get; set; } // 签到时间
|
||||
public DateTime? SignOutTime { get; set; } // 签退时间
|
||||
public string SignInStatus { get; set; } = ""; // 正常/迟到/缺卡
|
||||
public string SignOutStatus { get; set; } = ""; // 正常/早退/缺卡
|
||||
public string Remark { get; set; } = "";
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Attendance;
|
||||
|
||||
/// <summary>请假审批节点(多级审批流程,OrderNo 表示审批顺序)</summary>
|
||||
[Table(Name = "LeaveApprovers")]
|
||||
[Index("IX_LeaveApprovers_LeaveId_OrderNo", "LeaveId, OrderNo", IsUnique = true)]
|
||||
public class LeaveApprover : BaseEntity
|
||||
{
|
||||
public long LeaveId { get; set; }
|
||||
public long ApproverId { get; set; } // 审批人ID
|
||||
public string ApproverName { get; set; } = ""; // 审批人姓名(冗余)
|
||||
public int OrderNo { get; set; } // 序号(从1开始,表示审批顺序)
|
||||
public string Status { get; set; } = "待审批"; // 待审批/已批准/已驳回
|
||||
public string ApproveRemark { get; set; } = "";
|
||||
public DateTime? ApprovedAt { get; set; }
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Attendance;
|
||||
|
||||
/// <summary>请假申请</summary>
|
||||
[Table(Name = "LeaveRequests")]
|
||||
public class LeaveRequest : BaseEntity
|
||||
{
|
||||
public long EmployeeId { get; set; }
|
||||
public string Type { get; set; } = "事假"; // 事假/病假/年假/调休/婚假/产假
|
||||
public DateTime StartTime { get; set; }
|
||||
public DateTime EndTime { get; set; }
|
||||
public string Reason { get; set; } = "";
|
||||
public string Status { get; set; } = "待审批"; // 待审批/已批准/已驳回
|
||||
public int CurrentOrderNo { get; set; } = 1; // 当前审批到第几步(多级审批)
|
||||
public long? ApproverId { get; set; }
|
||||
public string ApproverName { get; set; } = "";
|
||||
public string ApproveRemark { get; set; } = "";
|
||||
public DateTime? ApprovedAt { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.PayRoll;
|
||||
|
||||
/// <summary>
|
||||
/// 薪资计算-立缫挡车车头(挡车工 / 车头工 产量计算明细)
|
||||
/// 唯一键:日期 + 部门 + 班次 + 机组 + 职工 + 工种 + 工艺庄口 + 规格 + 车台
|
||||
/// </summary>
|
||||
[Table(Name = "CalcLdccts")]
|
||||
[Index("IX_CalcLdccts_Biz", "Date, DepId, Banci, Jizu, EmployeeId, WorktypeId, GyzkId, Guige, Chetai", IsUnique = true)]
|
||||
public class CalcLdcct : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 日期
|
||||
public long EmployeeId { get; set; } // 职工
|
||||
public long DepId { get; set; } // 部门
|
||||
public long WorktypeId { get; set; } // 工种
|
||||
public int Jizu { get; set; } // 机组
|
||||
public int Banci { get; set; } // 班次(0=甲 1=乙,对应 Prod_Banci_Enum)
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
public string Chetai { get; set; } = ""; // 车台(车头工为空)
|
||||
|
||||
public decimal HoursKantai { get; set; } // 看台时长
|
||||
public decimal Dangcheshu { get; set; } // 挡车数
|
||||
public string Dengji { get; set; } = ""; // 等级
|
||||
public decimal Dengjifen { get; set; } // 等级分
|
||||
|
||||
// ---- 产量 ----
|
||||
public decimal ClDanjiaBase { get; set; } // 基础单价
|
||||
public decimal ClDanjiaDengji { get; set; } // 等级单价增减
|
||||
public decimal ClDanjiaActual { get; set; } // 实际单价
|
||||
public decimal ClSiliang { get; set; } // 丝量(g)
|
||||
|
||||
// ---- 质量 ----
|
||||
public decimal ZlSaozhe { get; set; } // 缫折
|
||||
public decimal ZlCenterxd { get; set; } // 中心纤度数
|
||||
public decimal ZlYexiannum { get; set; } // 野纤数
|
||||
public decimal ZlQingjie { get; set; } // 清洁扣款片数
|
||||
public decimal ZlJiejing { get; set; } // 洁净扣款片数
|
||||
public decimal ZlErdu { get; set; } // 二度
|
||||
public decimal ZlSandu { get; set; } // 三度
|
||||
|
||||
// ---- 金额 ----
|
||||
public decimal JineCl_Original { get; set; } // 金额-产量-初始值
|
||||
public decimal Xishu_JineCl { get; set; } // 产量金额系数
|
||||
public decimal JineCl { get; set; } // 金额-产量
|
||||
public decimal JineZlSaozhe { get; set; } // 缫折考核
|
||||
public decimal JineZlCenterxd { get; set; } // 中心纤度奖
|
||||
public decimal JineZlYexian { get; set; } // 野纤扣
|
||||
public decimal JineZlQingjie { get; set; } // 清洁扣
|
||||
public decimal JineZlJiejing { get; set; } // 洁净扣
|
||||
public decimal JineZlErdu { get; set; } // 二度扣
|
||||
public decimal JineZlSandu { get; set; } // 三度扣
|
||||
}
|
||||
@@ -0,0 +1,118 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.PayRoll;
|
||||
|
||||
// 薪资配置(对应 F9 WinClient\F9.Business.PayRoll\PAYROLL 下的 CONFGYZK / CONFGZ / CONFDCG / DCXDJK / XinZiJiaGePeiZhi)
|
||||
|
||||
/// <summary>薪资配置-工艺庄口(按 年度 + 月份 + 工艺庄口 唯一)</summary>
|
||||
[Table(Name = "ConfGyzks")]
|
||||
[Index("IX_ConfGyzks_Year_Month_GyzkId", "Year, Month, GyzkId", IsUnique = true)]
|
||||
public class ConfGyzk : BaseEntity
|
||||
{
|
||||
public int Year { get; set; } // 年度
|
||||
public int Month { get; set; } // 月份
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
|
||||
public decimal QsTaichan { get; set; } // 台产(工艺台时产量,单价分母)
|
||||
public string QsDengji { get; set; } = ""; // 等级
|
||||
public decimal QsDengjifen { get; set; } // 等级分
|
||||
public decimal SaoZhe { get; set; } // 工艺指标缫折
|
||||
public int MeiTongJianLiang { get; set; } // 每桶茧量
|
||||
public int LuoSiTongShu { get; set; } // 落丝桶数
|
||||
public decimal MeiCheSiLiang { get; set; } // 每车丝量(kg)
|
||||
public decimal DcgJijianXishu { get; set; } // 挡车工计件系数
|
||||
public decimal CtgJijianXishu { get; set; } // 车头工计件系数
|
||||
public decimal GyzkLtwxKs { get; set; } // 工艺-联统误选颗数
|
||||
public decimal GyzkLtwxl { get; set; } // 工艺-联统误选率
|
||||
public decimal XjChanliangPrice { get; set; } // 选茧产量单价
|
||||
}
|
||||
|
||||
/// <summary>薪资配置-工种/岗位(按 工种 唯一)</summary>
|
||||
[Table(Name = "ConfGzs")]
|
||||
[Index("IX_ConfGzs_WorkTypeId", "WorkTypeId", IsUnique = true)]
|
||||
public class ConfGz : BaseEntity
|
||||
{
|
||||
public long WorkTypeId { get; set; } // 工种/岗位
|
||||
|
||||
public decimal HoursPerday { get; set; } // 标准日工作时长
|
||||
public decimal QqDaysStandard { get; set; } // 全勤-标准出勤天数
|
||||
public decimal QqHoursMaxQj { get; set; } // 全勤-最大请假时长
|
||||
public decimal QqHoursDkMinjiaban { get; set; } // 全勤-满勤时请假免扣全勤最小加班时长
|
||||
public decimal QqHoursDkQingjia { get; set; } // 全勤-超过加班天数后免扣全勤请假时长
|
||||
|
||||
public decimal XgJineQuanqin { get; set; } // 学工-全勤奖金额
|
||||
public decimal XgJineGangwei { get; set; } // 学工-岗位薪资
|
||||
|
||||
public decimal JineNiangong { get; set; } // 年功工资
|
||||
public decimal JineQuanqin { get; set; } // 全勤奖金额
|
||||
public decimal JineGangwei { get; set; } // 岗位薪资
|
||||
public decimal JineYuekhJixiao { get; set; } // 月度绩效考核金额
|
||||
public decimal JineGwkh { get; set; } // 岗位考核
|
||||
public decimal JineYueticheng { get; set; } // 月度提成
|
||||
public decimal JineJtkhYear { get; set; } // 年度考核计提
|
||||
public decimal JineJisuanjishu { get; set; } // 计算基数工资
|
||||
public decimal JineYeban { get; set; } // 夜班补助金额/次
|
||||
public decimal JineJiaotongButie { get; set; } // 交通补贴/天
|
||||
public decimal LiudongJineGuding { get; set; } // 固定流动工资/小时
|
||||
|
||||
public decimal JiaqiJineKuangongKk { get; set; } // 旷工扣除/小时
|
||||
public decimal JiaqiJineFadingGz { get; set; } // 法定假工资/小时
|
||||
public decimal JiaqiJineFadingBz { get; set; } // 法定假补助/小时
|
||||
public decimal JiaqiJineHunjiaBz { get; set; } // 婚假补助/小时
|
||||
public decimal JiaqiJineSangjiaBz { get; set; } // 丧假补助/小时
|
||||
public decimal JiaqiJineBingjiaBz { get; set; } // 病假补助/小时
|
||||
public decimal JiaqiJineLunxiuBz { get; set; } // 轮休补助/小时
|
||||
public decimal JiabanJineBz { get; set; } // 加班补助/小时
|
||||
public decimal Jiaqi_Jine_TiaoxiuBz { get; set; } // 调休补助
|
||||
public decimal Jiaqi_Jine_NianjiaBz { get; set; } // 年假补助
|
||||
|
||||
public decimal GwsrkhJineQianhege { get; set; } // 岗位胜任考核-欠合格
|
||||
public decimal GwsrkhJineQiwang { get; set; } // 岗位胜任考核-期望
|
||||
public decimal GwsrkhJineHege { get; set; } // 岗位胜任考核-合格
|
||||
public decimal GwsrkhJineShengren { get; set; } // 岗位胜任考核-胜任
|
||||
public decimal GwsrkhJineChaoshengren { get; set; } // 岗位胜任考核-超胜任
|
||||
|
||||
public decimal Jiaban_GwsrkhJineQianhege { get; set; } // 加班工资-欠合格
|
||||
public decimal Jiaban_GwsrkhJineQiwang { get; set; } // 加班工资-期望
|
||||
public decimal Jiaban_GwsrkhJineHege { get; set; } // 加班工资-合格
|
||||
public decimal Jiaban_GwsrkhJineShengren { get; set; } // 加班工资-胜任
|
||||
public decimal Jiaban_GwsrkhJineChaoshengren { get; set; } // 加班工资-超胜任
|
||||
}
|
||||
|
||||
/// <summary>薪资配置-挡车/车头岗位(按 部门 唯一)</summary>
|
||||
[Table(Name = "ConfDcgs")]
|
||||
[Index("IX_ConfDcgs_DepId", "DepId", IsUnique = true)]
|
||||
public class ConfDcg : BaseEntity
|
||||
{
|
||||
public long DepId { get; set; } // 部门
|
||||
public decimal JineJisuanjishu50 { get; set; } // 50绪计算基数工资
|
||||
public decimal JineJisuanjishu60 { get; set; } // 60绪计算基数工资
|
||||
public decimal JineJisuanjishu70 { get; set; } // 70绪计算基数工资
|
||||
public decimal JineJisuanjishu100 { get; set; } // 100绪计算基数工资
|
||||
public decimal JineCtg { get; set; } // 车头工金额
|
||||
}
|
||||
|
||||
/// <summary>挡车纤度奖扣(按 规格 + 纤度 唯一)</summary>
|
||||
[Table(Name = "DangCheXianDuJiangKous")]
|
||||
[Index("IX_Dcxdjk_Guige_Xiandu", "GuiGe, XianDu", IsUnique = true)]
|
||||
public class DangCheXianDuJiangKou : BaseEntity
|
||||
{
|
||||
public string GuiGe { get; set; } = ""; // 规格
|
||||
public decimal XianDu { get; set; } // 纤度
|
||||
public decimal JiangLi { get; set; } // 奖励
|
||||
public decimal KouKuan { get; set; } // 扣款
|
||||
}
|
||||
|
||||
/// <summary>薪资价格配置(按 分组 + 项目 唯一)</summary>
|
||||
[Table(Name = "XinZiJiaGePeiZhis")]
|
||||
[Index("IX_Xzjg_Group_Key", "Group, Key", IsUnique = true)]
|
||||
public class XinZiJiaGePeiZhi : BaseEntity
|
||||
{
|
||||
public string Group { get; set; } = ""; // 分组(如「薪资.前缫」)
|
||||
public string Key { get; set; } = ""; // 项目(如「挡车工计件等级奖扣单价」)
|
||||
public string Unit { get; set; } = ""; // 单位
|
||||
public decimal Price { get; set; } // 价格
|
||||
public string Memo { get; set; } = ""; // 备注
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.PayRoll;
|
||||
|
||||
// 考勤统计(CQTJ)依赖的三套配置:
|
||||
// CONFZQ 薪资配置-账期、CONFEMPLOYEE 薪资配置-职工、GWsrkh 岗位胜任考核
|
||||
// 对应 F9 WinClient\F9.Business.PayRoll\PAYROLL\CONFZQ / CONFEMPLOYEE 与 CalXzMain 的岗位胜任考核。
|
||||
|
||||
/// <summary>薪资配置-账期(按 年度 + 月份 唯一):考勤统计用「前缫出勤天数 QsQuanqinDays」判断满勤</summary>
|
||||
[Table(Name = "ConfZqs")]
|
||||
[Index("IX_ConfZqs_Year_Month", "Year, Month", IsUnique = true)]
|
||||
public class ConfZq : BaseEntity
|
||||
{
|
||||
public int Year { get; set; }
|
||||
public int Month { get; set; }
|
||||
public decimal QsQuanqinDays { get; set; } // 前缫出勤天数(必填,考勤统计满勤/加班免扣口径)
|
||||
public string Memo { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>薪资配置-职工(按 职工 + 工种 唯一):法定假补助/工资小时数、是否学工</summary>
|
||||
[Table(Name = "ConfEmployees")]
|
||||
[Index("IX_ConfEmployees_Emp_WorkType", "EmployeeId, WorktypeId", IsUnique = true)]
|
||||
public class ConfEmployee : BaseEntity
|
||||
{
|
||||
public long EmployeeId { get; set; }
|
||||
public long WorktypeId { get; set; }
|
||||
public decimal HoursFadingBz { get; set; } // 法定假-补助小时
|
||||
public decimal HoursFadingGz { get; set; } // 法定假-工资小时
|
||||
public bool IsXuegong { get; set; } // 是否学工(全勤奖取学工标准)
|
||||
public string Memo { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>岗位胜任考核(按 年度+月份+职工 唯一):考核结果决定加班费单价档位</summary>
|
||||
[Table(Name = "Gwsrkhs")]
|
||||
[Index("IX_Gwsrkhs_Year_Month_Emp", "Year, Month, EmployeeId", IsUnique = true)]
|
||||
public class Gwsrkh : BaseEntity
|
||||
{
|
||||
public int Year { get; set; }
|
||||
public int Month { get; set; }
|
||||
public long DepId { get; set; }
|
||||
public long EmployeeId { get; set; }
|
||||
public string KhJieguo { get; set; } = ""; // 欠合格 / 期望 / 合格 / 胜任 / 超胜任
|
||||
public string Memo { get; set; } = "";
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>秤大丝-落丝汇总(每个落丝记录一条)</summary>
|
||||
[Table(Name = "CdsLsjls")]
|
||||
[Index("IX_CdsLsjls_LsjlId", "LsjlId", IsUnique = true)]
|
||||
public class CdsLsjl : BaseEntity
|
||||
{
|
||||
public long LsjlId { get; set; } // 落丝记录
|
||||
public int Num { get; set; } // 已秤数(把数)
|
||||
public int Siliang { get; set; } // 已秤丝量(g)
|
||||
public int Jianliang { get; set; } // 茧量(g)= 落丝桶数 × 每桶茧量
|
||||
public decimal Saozhe { get; set; } // 缫折 = 茧量 / 丝量 × 100
|
||||
public decimal Taichan { get; set; } // 实绩台产 = 丝量 / 落丝时长 / 车台数
|
||||
}
|
||||
|
||||
/// <summary>秤大丝-车台明细(每车台一行,4 个丝量值,单位 g)</summary>
|
||||
[Table(Name = "CdsChetais")]
|
||||
[Index("IX_CdsChetais_LsjlId_Chetaihao", "LsjlId, Chetaihao", IsUnique = true)]
|
||||
public class CdsChetai : BaseEntity
|
||||
{
|
||||
public long LsjlId { get; set; } // 落丝记录
|
||||
public int Chetaihao { get; set; } // 车台号
|
||||
public int Sl1 { get; set; } // 丝量1
|
||||
public int Sl2 { get; set; } // 丝量2
|
||||
public int Sl3 { get; set; } // 丝量3
|
||||
public int Sl4 { get; set; } // 丝量4
|
||||
public int Num { get; set; } // 个数 = 丝量 > 0 的个数
|
||||
public int Siliang { get; set; } // 小计丝量
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>
|
||||
/// 考勤登记主表:一人一天一条(唯一:日期 + 职工)。
|
||||
/// 对应 F9 WinClient\F9.Business.Prod\KQ\CQDJ 的 Cqdj 实体。
|
||||
/// </summary>
|
||||
[Table(Name = "biz_prod_kq_cqdj")]
|
||||
public class Cqdj : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 考勤日期
|
||||
public long DepId { get; set; } // 部门(车间)
|
||||
public long WorktypeId { get; set; } // 工种
|
||||
public long EmployeeId { get; set; } // 职工
|
||||
public int Banci { get; set; } // 班次(Prod_Banci_Enum:甲=1 乙=2)
|
||||
public bool IsXuegong { get; set; } // 是否学工(未转正)
|
||||
|
||||
public decimal HoursStandard { get; set; } // 标准时长
|
||||
public decimal HoursCq { get; set; } // 出勤时长(含正常/流动/代班/外派/工伤,不含加班)
|
||||
public decimal HoursQj { get; set; } // 请假时长
|
||||
public decimal HoursLd { get; set; } // 流动时长
|
||||
public decimal HoursJb { get; set; } // 加班时长
|
||||
public decimal HoursDb { get; set; } // 代班时长
|
||||
public decimal HoursWp { get; set; } // 外派时长
|
||||
public decimal HoursKg { get; set; } // 旷工时长
|
||||
public decimal HoursGs { get; set; } // 工伤时长
|
||||
|
||||
public int CsYeban { get; set; } // 夜班次数
|
||||
public string Memo { get; set; } = ""; // 备注
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 考勤登记明细:一人一天多行,按出勤类型拆分。
|
||||
/// 对应 F9 WinClient\F9.Business.Prod\KQ\CQDJ 的 Cqdj_Item 实体。
|
||||
/// </summary>
|
||||
[Table(Name = "biz_prod_kq_cqdj_item")]
|
||||
public class CqdjItem : BaseEntity
|
||||
{
|
||||
public long CqdjId { get; set; } // 主表 Id
|
||||
public DateTime Date { get; set; } // 考勤日期
|
||||
public long DepId { get; set; } // 出勤部门(流动/代班时可能是别的部门)
|
||||
public long WorktypeId { get; set; } // 出勤工种
|
||||
public long EmployeeId { get; set; } // 职工
|
||||
public int Banci { get; set; } // 班次
|
||||
public int TypeCq { get; set; } // 出勤类型(Cqdj_CqType_Enum)
|
||||
public int TypeQj { get; set; } // 请假类型(Cqdj_QjType_Enum,非请假为 0)
|
||||
public decimal Hours { get; set; } // 时长
|
||||
public string Jizu { get; set; } = ""; // 机组
|
||||
public string CtStart { get; set; } = ""; // 开始车台
|
||||
public string CtEnd { get; set; } = ""; // 结束车台
|
||||
public int DangcheNum { get; set; } // 挡车数
|
||||
public string Memo { get; set; } = ""; // 备注
|
||||
}
|
||||
@@ -0,0 +1,74 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>
|
||||
/// 考勤统计(月快照,一人一行)。
|
||||
/// 对应 F9 WinClient\F9.Business.Prod\KQ\CQTJ 的 Cqtj 实体。
|
||||
/// 数据由「录入 / 一键生成」按账期从考勤登记(Cqdj + CqdjItem)汇总后落库,
|
||||
/// 落库后可在统计页手工调整(年假 / 公假 / 调休 / 法定假 / 全勤相关时长与金额等)。
|
||||
/// </summary>
|
||||
[Table(Name = "biz_prod_kq_cqtj")]
|
||||
[Index("IX_Cqtj_Year_Month_DepId", "Year, Month, DepId", false)]
|
||||
public class Cqtj : BaseEntity
|
||||
{
|
||||
public int Year { get; set; }
|
||||
public int Month { get; set; }
|
||||
public long DepId { get; set; }
|
||||
public long WorktypeId { get; set; }
|
||||
public long EmployeeId { get; set; }
|
||||
|
||||
// ===== 出勤天数 =====
|
||||
public decimal DaysCqStandard { get; set; } // 标准出勤天数(工种配置 QqDaysStandard)
|
||||
public decimal DaysCqActual { get; set; } // 实际出勤天数 = 本部门出勤时长 / HoursPerday
|
||||
public decimal CqTianci { get; set; } // 出勤天次:(出勤 + 加班) > 0 的天数
|
||||
|
||||
// ===== 时长 =====
|
||||
public decimal HoursCq { get; set; } // 出勤
|
||||
public decimal HoursQj { get; set; } // 请假(合计)
|
||||
public decimal HoursLd { get; set; } // 流动
|
||||
public decimal HoursJb { get; set; } // 加班
|
||||
public decimal HoursDb { get; set; } // 代班
|
||||
public decimal HoursWp { get; set; } // 外派
|
||||
public decimal HoursKg { get; set; } // 旷工
|
||||
public int CsYeban { get; set; } // 夜班次数
|
||||
|
||||
// ===== 请假分项时长 =====
|
||||
public decimal HoursQjShijia { get; set; } // 事假
|
||||
public decimal HoursQjBj { get; set; } // 病假
|
||||
public decimal HoursQjHj { get; set; } // 婚假
|
||||
public decimal HoursQjCj { get; set; } // 产假
|
||||
public decimal HoursQjLx { get; set; } // 轮休
|
||||
public decimal HoursQjSangjia { get; set; } // 丧假
|
||||
public decimal HoursQjGj { get; set; } // 公假
|
||||
public decimal HoursQjNj { get; set; } // 年假
|
||||
public decimal HoursQjTx { get; set; } // 调休
|
||||
|
||||
// ===== 学工时长 =====
|
||||
public decimal HoursXgCq { get; set; } // 学工出勤
|
||||
public decimal HoursXgJiaban { get; set; } // 学工加班
|
||||
|
||||
// ===== 法定假 / 全勤相关时长 =====
|
||||
public decimal HoursFadingjiaqi { get; set; } // 法定假期时长 = 职工配置 法定补助 + 法定工资
|
||||
public decimal HoursQjQqmc { get; set; } // 全勤免扣请假(加班免扣)
|
||||
public decimal HoursQjQqcal { get; set; } // 全勤计算请假(本部门)
|
||||
|
||||
// ===== 金额 =====
|
||||
public decimal JineQuanqin { get; set; } // 全勤奖
|
||||
public decimal JineJb { get; set; } // 加班费
|
||||
public decimal JineLiudong { get; set; } // 流动工资
|
||||
public decimal JineDaiban { get; set; } // 代班工资
|
||||
public decimal JineYb { get; set; } // 夜班补助
|
||||
public decimal JineKgKk { get; set; } // 旷工考核
|
||||
|
||||
public decimal JineJqBzHj { get; set; } // 婚假补助
|
||||
public decimal JineJqBzBj { get; set; } // 病假补助
|
||||
public decimal JineJqBzLx { get; set; } // 轮休补助
|
||||
public decimal JineJqBzSangjia { get; set; } // 丧假补助
|
||||
public decimal JineJqBzFading { get; set; } // 法定假补助
|
||||
public decimal JineJqBzTxnj { get; set; } // 调休 + 年假补助
|
||||
public decimal JineJqBz { get; set; } // 假期补助合计
|
||||
|
||||
public string Memo { get; set; } = "";
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>公量纤度(每个落丝记录一条,由质检录入)</summary>
|
||||
[Table(Name = "Glxds")]
|
||||
[Index("IX_Glxds_LsjlId", "LsjlId", IsUnique = true)]
|
||||
public class Glxd : BaseEntity
|
||||
{
|
||||
public long LsjlId { get; set; } // 落丝记录
|
||||
public decimal Gongliangxiandu { get; set; } // 公量纤度
|
||||
}
|
||||
@@ -20,6 +20,8 @@ public class LsjlRecord : BaseEntity
|
||||
public int Chetaishu { get; set; } // 车台数
|
||||
public bool Isbanche { get; set; } // 是否半车
|
||||
public double Hours { get; set; } // 缫丝时长
|
||||
public int Tongshu { get; set; } // 落丝桶数(秤大丝「茧量」口径需要)
|
||||
public int Meitongjianliang { get; set; } // 每桶茧量(g,秤大丝「茧量」口径需要)
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
public double Chesu { get; set; } // 车速
|
||||
}
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>丝片检查(按「日期 + 车间 + 工艺庄口 + 规格」唯一)</summary>
|
||||
[Table(Name = "Spjcs")]
|
||||
[Index("IX_Spjcs_Date_DepId_GyzkId_Guige", "Date, DeptId, GyzkId, Guige", IsUnique = true)]
|
||||
public class Spjc : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 日期
|
||||
public long DeptId { get; set; } // 车间
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
|
||||
public int Pianshu { get; set; } // 总片数
|
||||
public int PianshuXuegong { get; set; } // 学工片数
|
||||
|
||||
// ---- 前缫 ----
|
||||
public int QsJiahua { get; set; } // 夹花
|
||||
public int QsYouwu { get; set; } // 油污
|
||||
public int QsHeidian { get; set; } // 黑点
|
||||
public int QsShangsi { get; set; } // 伤丝
|
||||
public int QsYetiao { get; set; } // 野条
|
||||
public int QsXiaosipian { get; set; } // 小丝片
|
||||
public int QsQita { get; set; } // 其他
|
||||
public int QsHeji { get; set; } // 合计
|
||||
|
||||
// ---- 后缫 ----
|
||||
public int HsYouwu { get; set; } // 油污
|
||||
public int HsShangsi { get; set; } // 伤丝
|
||||
public int HsShuangsi { get; set; } // 双丝
|
||||
public int HsZhisi { get; set; } // 直丝
|
||||
public int HsZhantiao { get; set; } // 粘条
|
||||
public int HsYingjiao { get; set; } // 硬胶
|
||||
public int HsGuojiao { get; set; } // 过胶
|
||||
public int HsShouchu { get; set; } // 手触
|
||||
public int HsWuran { get; set; } // 污染
|
||||
public int HsLiansi { get; set; } // 连丝
|
||||
public int HsWdmt { get; set; } // 无底面头
|
||||
public int HsMaoluan { get; set; } // 毛乱
|
||||
public int HsQita { get; set; } // 其他
|
||||
public int HsHeji { get; set; } // 合计
|
||||
|
||||
public string Memo { get; set; } = ""; // 备注
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
/// <summary>丝片台帐(每日一条):浸丝 / 返丝 / 编丝 / 整理</summary>
|
||||
[Table(Name = "Sptzs")]
|
||||
[Index("IX_Sptzs_Date", "Date", IsUnique = true)]
|
||||
public class Sptz : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 日期
|
||||
public DateTime DateLast { get; set; } // 上一日(上一本台账日期)
|
||||
|
||||
// ---- 浸丝 ----
|
||||
public int JsShangcun { get; set; } // 上存 = 上一日今存
|
||||
public int JsXiasi { get; set; } // 下丝
|
||||
public int JsJinsi { get; set; } // 浸丝
|
||||
public int JsSrylJrxz { get; set; } // 上日遗留/今日新增 = 上存 − 浸丝
|
||||
public int JsJincun { get; set; } // 今存 = 下丝 + 上日遗留/今日新增
|
||||
|
||||
public int FsFsps { get; set; } // 返丝片数
|
||||
public int BsBsps { get; set; } // 编丝片数
|
||||
|
||||
// ---- 整理 ----
|
||||
public int ZlZhengpin { get; set; } // 正品片数
|
||||
public int ZlTichu { get; set; } // 剔除片数
|
||||
|
||||
public string Memo { get; set; } = ""; // 备注
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
// 选茧班组(对应 F9 生产-选剥茧 XBJ\XJBZ 两张表:班组 / 班组职工)
|
||||
// 数据口径:
|
||||
// 1) XjpbBanzu 班组:【班次(甲/乙)+ 选茧组】一条,来自职工分配时勾选的组别。
|
||||
// 2) XjpbBanzuZhigong 班组职工:某班组下的职工及顺序,来源是「选剥茧车间」下工种为「选茧工」的在职职工。
|
||||
// 注意:老系统班组由「编辑录入」时勾选职工+组别后保存生成(XjpbBanzuZhigong_SaveCommand),
|
||||
// 班组列表本身没有独立的新增入口,移植后同样以「编辑录入」批量保存为准。
|
||||
|
||||
/// <summary>选茧班组(F9 biz_prod_xbj_xjpb_banzu)</summary>
|
||||
[Table(Name = "XjpbBanzus")]
|
||||
public class XjpbBanzu : BaseEntity
|
||||
{
|
||||
public string Banci { get; set; } = ""; // 班次(甲 / 乙)
|
||||
public int Zu { get; set; } // 选茧组
|
||||
}
|
||||
|
||||
/// <summary>选茧班组职工(F9 biz_prod_xbj_xjpb_banzu_zhigong)</summary>
|
||||
[Table(Name = "XjpbBanzuZhigongs")]
|
||||
public class XjpbBanzuZhigong : BaseEntity
|
||||
{
|
||||
public long BanzuId { get; set; } // 选茧班组ID
|
||||
public string Banci { get; set; } = ""; // 班次(甲 / 乙)
|
||||
public int Zu { get; set; } // 选茧组
|
||||
public long YgId { get; set; } // 职工ID
|
||||
public string YgName { get; set; } = ""; // 职工姓名
|
||||
public string YgPhone { get; set; } = ""; // 职工电话
|
||||
public int Sort { get; set; } // 顺序
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
// 选茧日报(对应 F9 生产-选剥茧 XBJ\XJRB 三张表:日报主表 / 计划 / 计划明细)
|
||||
// 数据口径:
|
||||
// 1) XjrbRecord 日报:某日某工艺庄口一条,记录干茧领入与 8 类茧(联统/好五级/六级/绵/双宫/下脚/茧衣/茧花)的
|
||||
// 包数与重量,另含「退回」、合计重量、联统率、盈亏。
|
||||
// 2) XjrbPlan 计划:按领料单(原料出库单)下达的选茧计划,含计划的 8 类茧与选茧盈亏、是否完成。
|
||||
// 3) XjrbItem 计划明细:挂在计划下的每日选茧进度行(外键 XjrbPlanId),完成勾选后回写计划盈亏。
|
||||
//
|
||||
// 盈亏 / 联统率口径(对齐 F9 GetXjrbCountYingkuiQuery):
|
||||
// 累计区间 = 同庄口下 Date < 当前日期 的历史日报(含当前录入值)
|
||||
// yllr = Σ 干茧领入重量(含当前)
|
||||
// ltj = Σ 联统茧重量(含当前)
|
||||
// all = Σ (联统+好五级+六级+绵+双宫+下脚+茧衣+茧花) 重量(含当前,不含退回)
|
||||
// 联统率 = yllr != 0 ? (ltj / yllr) * 100 : 0
|
||||
// 盈亏 = all - yllr
|
||||
|
||||
/// <summary>选茧日报主表(F9 biz_prod_xbj_xjrb)</summary>
|
||||
[Table(Name = "XjrbRecords")]
|
||||
public class XjrbRecord : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 选茧日期
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
|
||||
public int YlLrBaoshu { get; set; } // 干茧领入包数
|
||||
public decimal YlLrZhongliang { get; set; } // 干茧领入重量
|
||||
|
||||
public int LtjBaoshu { get; set; } // 联统茧包数
|
||||
public decimal LtjZhongliang { get; set; } // 联统茧重量
|
||||
public int HwjjBaoshu { get; set; } // 好五级茧包数
|
||||
public decimal HwjjZhongliang { get; set; } // 好五级茧重量
|
||||
public int LjjBaoshu { get; set; } // 六级茧包数
|
||||
public decimal LjjZhongliang { get; set; } // 六级茧重量
|
||||
public int MjBaoshu { get; set; } // 绵茧包数
|
||||
public decimal MjZhongliang { get; set; } // 绵茧重量
|
||||
public int SgjBaoshu { get; set; } // 双宫茧包数
|
||||
public decimal SgjZhongliang { get; set; } // 双宫茧重量
|
||||
public int XjjBaoshu { get; set; } // 下脚茧包数
|
||||
public decimal XjjZhongliang { get; set; } // 下脚茧重量
|
||||
public int JyBaoshu { get; set; } // 茧衣包数
|
||||
public decimal JyZhongliang { get; set; } // 茧衣重量
|
||||
public int JhBaoshu { get; set; } // 茧花包数
|
||||
public decimal JhZhongliang { get; set; } // 茧花重量
|
||||
|
||||
public decimal TotalZhongliang { get; set; } // 合计重量(上述 8 项重量之和)
|
||||
|
||||
public int ThBaoshu { get; set; } // 退回包数
|
||||
public decimal ThZhongliang { get; set; } // 退回重量
|
||||
|
||||
public decimal LiantongRate { get; set; } // 联统率(%)
|
||||
public decimal Yingkui { get; set; } // 盈亏
|
||||
}
|
||||
|
||||
/// <summary>选茧计划(F9 biz_prod_xbj_xjrb_plan):按领料单下达,含计划盈亏与完成标记</summary>
|
||||
[Table(Name = "XjrbPlans")]
|
||||
public class XjrbPlan : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 日期
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public long YllingliaodanId { get; set; } // 领料单(原料出库单)ID
|
||||
|
||||
public int YlBaoshu { get; set; } // 原料领入包数
|
||||
public decimal YlZhongliang { get; set; } // 原料领入重量
|
||||
|
||||
public int LtjBaoshu { get; set; } // 联统茧包数
|
||||
public decimal LtjZhongliang { get; set; } // 联统茧重量
|
||||
public int HwjjBaoshu { get; set; } // 好五级茧包数
|
||||
public decimal HwjjZhongliang { get; set; } // 好五级茧重量
|
||||
public int WjjBaoshu { get; set; } // 五级茧包数
|
||||
public decimal WjjZhongliang { get; set; } // 五级茧重量
|
||||
public int SgjBaoshu { get; set; } // 双宫茧包数
|
||||
public decimal SgjZhongliang { get; set; } // 双宫茧重量
|
||||
public int XjjBaoshu { get; set; } // 下脚茧包数
|
||||
public decimal XjjZhongliang { get; set; } // 下脚茧重量
|
||||
public int JyBaoshu { get; set; } // 茧衣包数
|
||||
public decimal JyZhongliang { get; set; } // 茧衣重量
|
||||
public int JhBaoshu { get; set; } // 茧花包数
|
||||
public decimal JhZhongliang { get; set; } // 茧花重量
|
||||
|
||||
public decimal TotalZhongliang { get; set; } // 合计重量
|
||||
public decimal LiantongRate { get; set; } // 联统率(%)
|
||||
public decimal Yingkui { get; set; } // 选茧盈亏
|
||||
public bool IsFinish { get; set; } // 是否选茧完成(完成后禁止改动明细)
|
||||
}
|
||||
|
||||
/// <summary>选茧计划明细(F9 biz_prod_xbj_xjrb_item):挂在计划下的每日选茧进度行</summary>
|
||||
[Table(Name = "XjrbItems")]
|
||||
public class XjrbItem : BaseEntity
|
||||
{
|
||||
public long XjrbPlanId { get; set; } // 选茧计划ID
|
||||
public DateTime Date { get; set; } // 选茧日期
|
||||
|
||||
public int LtjBaoshu { get; set; } // 联统茧包数
|
||||
public decimal LtjZhongliang { get; set; } // 联统茧重量
|
||||
public int HwjjBaoshu { get; set; } // 好五级茧包数
|
||||
public decimal HwjjZhongliang { get; set; } // 好五级茧重量
|
||||
public int WjjBaoshu { get; set; } // 五级茧包数
|
||||
public decimal WjjZhongliang { get; set; } // 五级茧重量
|
||||
public int SgjBaoshu { get; set; } // 双宫茧包数
|
||||
public decimal SgjZhongliang { get; set; } // 双宫茧重量
|
||||
public int XjjBaoshu { get; set; } // 下脚茧包数
|
||||
public decimal XjjZhongliang { get; set; } // 下脚茧重量
|
||||
public int JyBaoshu { get; set; } // 茧衣包数
|
||||
public decimal JyZhongliang { get; set; } // 茧衣重量
|
||||
public int JhBaoshu { get; set; } // 茧花包数
|
||||
public decimal JhZhongliang { get; set; } // 茧花重量
|
||||
|
||||
public decimal TotalZhongliang { get; set; } // 合计重量
|
||||
public bool IsFinish { get; set; } // 是否选茧完成(勾选后回写计划盈亏)
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
using F9WebAiTest.Domain.Enums.SYS.Employees;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Prod;
|
||||
|
||||
// 煮茧日报(对应 F9 生产-前缫 的 ZJRB 四张表:日报主表 / 机组 / 班次 / 机组班次)
|
||||
// 数据口径:某日某车间某庄口某规格一条日报,主表存「班次合计」,机组存桶数,机组班次存甲乙班今缫桶数。
|
||||
|
||||
/// <summary>煮茧日报主表(biz_prod_qs_zjrb)</summary>
|
||||
[Table(Name = "ZjrbRecords")]
|
||||
public class ZjrbRecord : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 日期
|
||||
public long DeptId { get; set; } // 车间(前缫)
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
public DateTime? LastDate { get; set; } // 上一日(写入时标记,取上一日一律按 Date < 当前日期)
|
||||
public int StandardLuositongshu { get; set; } // 工艺落丝桶数(标准落丝桶数)
|
||||
public int MeitongJianliang { get; set; } // 每桶茧量(g)
|
||||
|
||||
// 包数(今日 = 甲班 + 乙班)
|
||||
public int BaoshuShangcun { get; set; } // 上存包数
|
||||
public int BaoshuLingru { get; set; } // 领入包数
|
||||
public int BaoshuSaosi { get; set; } // 今缫包数
|
||||
public int BaoshuTuihui { get; set; } // 退回包数
|
||||
public int BaoshuJincun { get; set; } // 今存包数
|
||||
|
||||
// 重量(kg,今日 = 甲班 + 乙班)
|
||||
public decimal JianliangShangcun { get; set; } // 上存重量
|
||||
public decimal JianliangLingru { get; set; } // 领入重量
|
||||
public decimal JianliangSaosi { get; set; } // 今缫重量
|
||||
public decimal JianliangTuihui { get; set; } // 退回重量
|
||||
public decimal JianliangJincun { get; set; } // 今存重量
|
||||
}
|
||||
|
||||
/// <summary>煮茧日报-机组(biz_prod_qs_zjrb_jizu):今存桶数 = 上存 + 今缫 - 今落</summary>
|
||||
[Table(Name = "ZjrbJizus")]
|
||||
public class ZjrbJizu : BaseEntity
|
||||
{
|
||||
public long ZjrbId { get; set; } // 煮茧日报ID
|
||||
public int Jizu { get; set; } // 机组
|
||||
public decimal JizuSaosiHours { get; set; } // 缫丝时长(小时,上限 20)
|
||||
public int TongshuShangcun { get; set; } // 上存桶数
|
||||
public int TongshuJinsao { get; set; } // 今缫桶数(= 甲班 + 乙班)
|
||||
public int TongshuJinluo { get; set; } // 今落桶数
|
||||
public int TongshuJincun { get; set; } // 今存桶数
|
||||
}
|
||||
|
||||
/// <summary>煮茧日报-班次(biz_prod_qs_zjrb_banci):车间级甲乙班的包数/重量</summary>
|
||||
[Table(Name = "ZjrbBancis")]
|
||||
public class ZjrbBanci : BaseEntity
|
||||
{
|
||||
public long ZjrbId { get; set; } // 煮茧日报ID
|
||||
public Prod_Banci_Enum Banci { get; set; } // 班次(甲/乙)
|
||||
|
||||
public int BaoshuShangcun { get; set; } // 上存包数
|
||||
public int BaoshuLingru { get; set; } // 领入包数
|
||||
public int BaoshuSaosi { get; set; } // 今缫包数
|
||||
public int BaoshuTuihui { get; set; } // 退回包数
|
||||
public int BaoshuJincun { get; set; } // 今存包数
|
||||
|
||||
public decimal JianliangShangcun { get; set; } // 上存重量
|
||||
public decimal JianliangLingru { get; set; } // 领入重量
|
||||
public decimal JianliangSaosi { get; set; } // 今缫重量
|
||||
public decimal JianliangTuihui { get; set; } // 退回重量
|
||||
public decimal JianliangJincun { get; set; } // 今存重量
|
||||
}
|
||||
|
||||
/// <summary>煮茧日报-机组班次(biz_prod_qs_zjrb_jizu_banci):只存每机组每班次的今缫桶数</summary>
|
||||
[Table(Name = "ZjrbJizuBancis")]
|
||||
public class ZjrbJizuBanci : BaseEntity
|
||||
{
|
||||
public long ZjrbId { get; set; } // 煮茧日报ID
|
||||
public long ZjrbJizuId { get; set; } // 煮茧日报机组ID
|
||||
public int Jizu { get; set; } // 机组
|
||||
public Prod_Banci_Enum Banci { get; set; } // 班次(甲/乙)
|
||||
public int TongshuJinsao { get; set; } // 今缫桶数
|
||||
}
|
||||
@@ -0,0 +1,378 @@
|
||||
using FreeSql.DataAnnotations;
|
||||
using F9WebAiTest.Domain.Common;
|
||||
|
||||
namespace F9WebAiTest.Domain.Entities.Wms;
|
||||
|
||||
// 仓储(对应 F9 WinClient\F9.Business.WMS 的五个模块:原料 / 副产品 / 中间品 / 生丝 / 物资)
|
||||
// 五个模块的「入库 / 出库 / 库存台账」结构完全一致,仅「台账项目」口径不同:
|
||||
// 原料 = 原料庄口,副产品/中间品/生丝/物资 = 物资目录(中间品另有一套按工艺庄口的「笼筒架台账」)
|
||||
// 因此统一为一套表 + Module 维度(F9 里是五套同名表),字段为五个模块字段的并集。
|
||||
|
||||
/// <summary>仓储模块</summary>
|
||||
public enum Wms_Module_Enum
|
||||
{
|
||||
原料 = 1,
|
||||
副产品 = 2,
|
||||
中间品 = 3,
|
||||
生丝 = 4,
|
||||
物资 = 5
|
||||
}
|
||||
|
||||
/// <summary>入库单(五模块共用)</summary>
|
||||
[Table(Name = "WmsRukus")]
|
||||
[Index("IX_WmsRukus_Module_Date_Code", "Module, Date, Code", IsUnique = true)]
|
||||
public class WmsRuku : BaseEntity
|
||||
{
|
||||
public Wms_Module_Enum Module { get; set; } // 模块
|
||||
public DateTime Date { get; set; } // 入库日期
|
||||
public int Type { get; set; } // 入库类型(各模块枚举值,见 WmsTypes)
|
||||
public string Code { get; set; } = ""; // 单据编号
|
||||
public long GysId { get; set; } // 供应商(原料/物资)
|
||||
public long KhId { get; set; } // 客户(副产品)
|
||||
public long GyzkId { get; set; } // 工艺庄口(副产品入库)
|
||||
public long DepId { get; set; } // 部门(副产品/在制品)
|
||||
public string Lianxiren { get; set; } = ""; // 联系人(原料)
|
||||
public string Phone { get; set; } = ""; // 联系电话(原料)
|
||||
public string Carno { get; set; } = ""; // 车牌号(原料)
|
||||
public string Kuguan { get; set; } = ""; // 库管员
|
||||
public string Caigouyuan { get; set; } = ""; // 采购员(物资)
|
||||
public string PayStatus { get; set; } = ""; // 支付类型(物资)
|
||||
public int RkStatus { get; set; } // 入库状态(物资:0未入库 1已入库)
|
||||
public int BxStatus { get; set; } // 报销状态(物资:0无 1待报销 2已报销)
|
||||
public string Description { get; set; } = ""; // 备注
|
||||
}
|
||||
|
||||
/// <summary>入库明细(五模块共用)</summary>
|
||||
[Table(Name = "WmsRukuDetails")]
|
||||
public class WmsRukuDetail : BaseEntity
|
||||
{
|
||||
public long RukuId { get; set; }
|
||||
public long WzmlId { get; set; } // 物资目录
|
||||
public long YlzkId { get; set; } // 原料庄口(原料)
|
||||
public long GyzkId { get; set; } // 工艺庄口(在制品)
|
||||
public long DepId { get; set; } // 部门(在制品)
|
||||
public int Jianshu { get; set; } // 件数
|
||||
public decimal Maozhong { get; set; } // 毛重
|
||||
public decimal Pizhong { get; set; } // 皮重
|
||||
public decimal Jingzhong { get; set; } // 净重
|
||||
public decimal BiaobaoZhongliang { get; set; } // 标包重量(在制品)
|
||||
public decimal BaozhuangZhongliang { get; set; } // 包装重量(在制品)
|
||||
public decimal Shuliang { get; set; } // 数量(物资)
|
||||
public decimal Danjia { get; set; } // 单价
|
||||
public decimal Jine { get; set; } // 金额
|
||||
public decimal Sunhao { get; set; } // 运损(原料)
|
||||
public string PiciCodes { get; set; } = ""; // 批次号(生丝)
|
||||
public int PiciNum { get; set; } // 批数(生丝)
|
||||
public int BaojianNum { get; set; } // 包件数(生丝)
|
||||
public string PiciIds { get; set; } = ""; // 批次ID(生丝,逗号分隔,入库按批次关联)
|
||||
public string Banci { get; set; } = ""; // 班次(在制品出库)
|
||||
public string JidiWaigou { get; set; } = ""; // 基地 / 外购(生丝)
|
||||
}
|
||||
|
||||
/// <summary>磅码单(原料入库/出库过磅明细)</summary>
|
||||
[Table(Name = "WmsBangmadans")]
|
||||
public class WmsBangmadan : BaseEntity
|
||||
{
|
||||
public long DetailId { get; set; } // 出/入库明细 Id
|
||||
public bool IsChuku { get; set; } // false=入库 true=出库
|
||||
public int Jianshu { get; set; } // 件数
|
||||
public decimal Maozhong { get; set; } // 毛重
|
||||
public decimal Pizhong { get; set; } // 皮重
|
||||
public decimal Jingzhong { get; set; } // 净重 = 毛重 − 皮重
|
||||
public DateTime? GuobangShijian { get; set; } // 过磅时间
|
||||
}
|
||||
|
||||
/// <summary>出库单(五模块共用)</summary>
|
||||
[Table(Name = "WmsChukus")]
|
||||
[Index("IX_WmsChukus_Module_Date_Code", "Module, Date, Code", IsUnique = true)]
|
||||
public class WmsChuku : BaseEntity
|
||||
{
|
||||
public Wms_Module_Enum Module { get; set; }
|
||||
public DateTime Date { get; set; } // 出库日期
|
||||
public int Type { get; set; } // 出库类型
|
||||
public string Code { get; set; } = ""; // 单据编号
|
||||
public long WldwId { get; set; } // 往来单位/客户(生丝/原料销售)
|
||||
public long KhId { get; set; } // 客户(副产品)
|
||||
public long GyzkId { get; set; } // 工艺庄口(原料领料)
|
||||
public long LingliaoDepId { get; set; } // 领料部门(物资)
|
||||
public long UseDepId { get; set; } // 使用部门(物资)
|
||||
public long DbdepId { get; set; } // 调拨部门(物资/副产品)
|
||||
public string Lingliaoren { get; set; } = ""; // 领料人
|
||||
public string Kuguan { get; set; } = ""; // 库管员
|
||||
public string UseLocation { get; set; } = ""; // 使用位置(物资)
|
||||
public int CkStatus { get; set; } // 出库状态(物资:0未出库 1已出库)
|
||||
public DateTime? CkTime { get; set; } // 出库时间(物资)
|
||||
public bool IsHongchong { get; set; } // 是否红冲(物资)
|
||||
public long HongchongId { get; set; } // 红冲单据(物资)
|
||||
public string Description { get; set; } = ""; // 备注
|
||||
}
|
||||
|
||||
/// <summary>出库明细(五模块共用)</summary>
|
||||
[Table(Name = "WmsChukuDetails")]
|
||||
public class WmsChukuDetail : BaseEntity
|
||||
{
|
||||
public long ChukuId { get; set; }
|
||||
public long WzmlId { get; set; } // 物资目录
|
||||
public long YlzkId { get; set; } // 原料庄口(原料)
|
||||
public long GyzkId { get; set; } // 工艺庄口(在制品)
|
||||
public long DepId { get; set; } // 部门(在制品)
|
||||
public int Jianshu { get; set; }
|
||||
public decimal Maozhong { get; set; }
|
||||
public decimal Pizhong { get; set; }
|
||||
public decimal Jingzhong { get; set; }
|
||||
public decimal BiaobaoZhongliang { get; set; }
|
||||
public decimal BaozhuangZhongliang { get; set; }
|
||||
public decimal Shuliang { get; set; } // 数量(物资)
|
||||
public decimal Danjia { get; set; }
|
||||
public decimal Jine { get; set; }
|
||||
public decimal KucunNum { get; set; } // 库存数量(物资,用于金额分摊)
|
||||
public string PiciCodes { get; set; } = ""; // 批次号(生丝)
|
||||
public int PiciNum { get; set; }
|
||||
public string PcAndBjIds { get; set; } = ""; // 批次+包件ID(生丝,JSON:[{piciId,piciBaojianIds}...])
|
||||
public string Lingyongren { get; set; } = ""; // 领用人(物资)
|
||||
public string Banci { get; set; } = ""; // 班次(在制品)
|
||||
public string JidiWaigou { get; set; } = ""; // 基地 / 外购(生丝)
|
||||
}
|
||||
|
||||
/// <summary>库存台账-日期(一天一条;在制品的「笼筒架台账」用 Kind=1 区分)</summary>
|
||||
[Table(Name = "WmsKcTzDates")]
|
||||
[Index("IX_WmsKcTzDates_Module_Kind_Date", "Module, Kind, Date", IsUnique = true)]
|
||||
public class WmsKcTzDate : BaseEntity
|
||||
{
|
||||
public Wms_Module_Enum Module { get; set; }
|
||||
public int Kind { get; set; } // 0=库存台账 1=笼筒架台账(在制品)
|
||||
public DateTime Date { get; set; } // 台账日期
|
||||
public DateTime LastDate { get; set; } // 上一台账日期
|
||||
}
|
||||
|
||||
/// <summary>库存台账-明细(按台账项目一行)</summary>
|
||||
[Table(Name = "WmsKcTzItems")]
|
||||
[Index("IX_WmsKcTzItems_TzDateId_ItemId", "TzDateId, ItemId, SubKey", IsUnique = true)]
|
||||
public class WmsKcTzItem : BaseEntity
|
||||
{
|
||||
public long TzDateId { get; set; }
|
||||
public Wms_Module_Enum Module { get; set; }
|
||||
public int Kind { get; set; }
|
||||
public DateTime Date { get; set; } // 台账日期
|
||||
public long ItemId { get; set; } // 台账项目(原料=原料庄口,其余=物资目录,笼筒架=工艺庄口)
|
||||
public string SubKey { get; set; } = ""; // 项目辅助维度(生丝=基地/外购)
|
||||
public string ItemName { get; set; } = ""; // 项目名称快照
|
||||
public string ItemCode { get; set; } = ""; // 项目编号快照(物资台账)
|
||||
public decimal Ydayjianshu { get; set; } // 上日结存件数(物资台账=数量)
|
||||
public decimal Ydayjingzhong { get; set; } // 上日结存净重(物资台账=金额)
|
||||
public decimal Tdayrukujianshu { get; set; } // 今日入库件数
|
||||
public decimal Tdayrukujingzhong { get; set; } // 今日入库净重
|
||||
public decimal Tdaychukujianshu { get; set; } // 今日出库件数
|
||||
public decimal Tdaychukujingzhong { get; set; } // 今日出库净重
|
||||
public decimal Yingkui { get; set; } // 盈亏
|
||||
public decimal Tdayjianshu { get; set; } // 今日结存件数
|
||||
public decimal Tdayjingzhong { get; set; } // 今日结存净重
|
||||
public decimal Yangjianjianshu { get; set; } // 样茧件数(原料)
|
||||
public bool AllChuku { get; set; } // 全部出库
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>生丝批次(对应 F9 SS_Pici)</summary>
|
||||
[Table(Name = "WmsPicis")]
|
||||
[Index("IX_WmsPicis_Code", "Code", IsUnique = true)]
|
||||
public class WmsPici : BaseEntity
|
||||
{
|
||||
public string Code { get; set; } = ""; // 批号
|
||||
public int CodeType { get; set; } // 批号类型
|
||||
public int Year { get; set; }
|
||||
public DateTime Date { get; set; } // 织批日期
|
||||
public DateTime? ScDate { get; set; } // 生产日期
|
||||
public long GyzkId { get; set; } // 工艺庄口
|
||||
public long WzmlId { get; set; } // 物资目录(生丝规格)
|
||||
public long DepId { get; set; } // 部门
|
||||
public string Guige { get; set; } = ""; // 规格
|
||||
public string JidiWaigou { get; set; } = ""; // 基地 / 外购
|
||||
public string YoujiPutong { get; set; } = ""; // 优质 / 普通
|
||||
public int Baoshu { get; set; } // 包数
|
||||
public int StartBaojianNum { get; set; } // 起始包件号
|
||||
public decimal Maozhong { get; set; }
|
||||
public decimal Pizhong { get; set; }
|
||||
public decimal Jingzhong { get; set; }
|
||||
public decimal Gongliang { get; set; } // 公量
|
||||
public int KcStatus { get; set; } // 0全部 1待入库 2已入库 3部分出库 4已出库
|
||||
public long RkItemId { get; set; } // 关联入库明细
|
||||
public DateTime? RkDate { get; set; } // 入库日期
|
||||
public long CkItemId { get; set; } // 关联出库明细(最后一笔)
|
||||
public DateTime CkLastDate { get; set; } // 最后出库日期
|
||||
public int CkBaoshu { get; set; } // 已出库包数
|
||||
public decimal CkJingzhong { get; set; } // 已出库净重
|
||||
public int KcBaoshu { get; set; } // 库存包数
|
||||
public string Dengji { get; set; } = ""; // 等级
|
||||
public decimal Qingjie { get; set; } // 清洁
|
||||
public decimal Jiejing { get; set; } // 洁净
|
||||
public decimal Piancha { get; set; } // 偏差
|
||||
public decimal Zongcha { get; set; } // 总差
|
||||
public decimal Qieduan { get; set; } // 切断
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>生丝批次-包件(对应 F9 SS_Pici_Baojian)</summary>
|
||||
[Table(Name = "WmsPiciBaojians")]
|
||||
public class WmsPiciBaojian : BaseEntity
|
||||
{
|
||||
public long PiciId { get; set; }
|
||||
public int Baojianhao { get; set; } // 包件号
|
||||
public decimal Maozhong { get; set; }
|
||||
public decimal Pizhong { get; set; }
|
||||
public decimal Jingzhong { get; set; }
|
||||
public decimal Gongliang { get; set; } // 公量
|
||||
public decimal Huichaolv { get; set; } // 实测回潮率(%)
|
||||
public bool CkIsck { get; set; } // 是否已出库
|
||||
public long CkItemId { get; set; } // 出库明细ID
|
||||
public DateTime? CkDate { get; set; } // 出库日期
|
||||
public decimal CkJingzhong { get; set; } // 出库净重
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>生丝批次-出库记录(对应 F9 SS_Pici_Chuku)</summary>
|
||||
[Table(Name = "WmsPiciChukus")]
|
||||
public class WmsPiciChuku : BaseEntity
|
||||
{
|
||||
public long PiciId { get; set; }
|
||||
public long CkItemId { get; set; } // 出库明细ID
|
||||
public int CkBaoshu { get; set; } // 出库包数
|
||||
public DateTime? CkDate { get; set; }
|
||||
public decimal CkJingzhong { get; set; } // 出库净重
|
||||
}
|
||||
|
||||
/// <summary>生丝批次-质检(对应 F9 SS_Pici_Qc)</summary>
|
||||
[Table(Name = "WmsPiciQcs")]
|
||||
[Index("IX_WmsPiciQcs_PiciId", "PiciId", IsUnique = true)]
|
||||
public class WmsPiciQc : BaseEntity
|
||||
{
|
||||
public long PiciId { get; set; } // 生丝批次ID
|
||||
public string Pingwei { get; set; } = ""; // 品味
|
||||
public string Seze { get; set; } = ""; // 检验-色泽
|
||||
public decimal AvgHuichaolv { get; set; } // 平均回潮率
|
||||
public decimal AvgGongliangXiandu { get; set; } // 平均公量纤度
|
||||
public decimal XianduPiancha { get; set; } // 纤度偏差
|
||||
public decimal XianduZdpiancha { get; set; } // 纤度最大偏差
|
||||
public decimal Qingjie { get; set; } // 清洁
|
||||
public decimal Jiejing { get; set; } // 洁净
|
||||
public int JunyunYd { get; set; } // 均匀一度变化
|
||||
public int JunyunEd { get; set; } // 均匀二度变化
|
||||
public int JunyunSd { get; set; } // 均匀三度变化
|
||||
public int Qieduan { get; set; } // 切断次数
|
||||
public string DuanlieQiangdu { get; set; } = ""; // 断裂强度
|
||||
public string DuanlieShenchanglv { get; set; } = ""; // 断裂伸长率
|
||||
public int Baohe { get; set; } // 抱合
|
||||
public string WgWg { get; set; } = ""; // 外观-外观检验
|
||||
public string WgYanse { get; set; } = ""; // 外观-颜色
|
||||
public string WgGuangze { get; set; } = ""; // 外观-光泽
|
||||
public string WgShougan { get; set; } = ""; // 外观-手感
|
||||
public int? QjZhuyao { get; set; } // 清洁-主要疵点
|
||||
public int? QjCiyaoFeisi { get; set; } // 清洁-次要疵点-废丝
|
||||
public int? QjCiyaoDacao { get; set; } // 清洁-次要疵点-大糙
|
||||
public int? QjCiyaoNianfucao { get; set; } // 清洁-次要疵点-粘附糙
|
||||
public int? QjCiyaoDachangjie { get; set; } // 清洁-次要疵点-大长结
|
||||
public int? QjCiyaoZhongluoxuan { get; set; } // 清洁-次要疵点-重螺旋
|
||||
public int? QjPutongXiaocao { get; set; } // 清洁-普通疵点-小糙
|
||||
public int? QjPutongChangjie { get; set; } // 清洁-普通疵点-长结
|
||||
public int? QjPutongLuoxuan { get; set; } // 清洁-普通疵点-螺旋
|
||||
public int? QjPutongHuanjie { get; set; } // 清洁-普通疵点-环结及裂丝
|
||||
public int? Jj100 { get; set; } // 洁净100
|
||||
public int? Jj95 { get; set; }
|
||||
public int? Jj90 { get; set; }
|
||||
public int? Jj85 { get; set; }
|
||||
public int? Jj80 { get; set; }
|
||||
public int? Jj75 { get; set; }
|
||||
public int? Jj70 { get; set; }
|
||||
public int? Jj65 { get; set; }
|
||||
public int? Jj60 { get; set; }
|
||||
public int? Jj55 { get; set; }
|
||||
public int? Jj50 { get; set; }
|
||||
public int? Jj45 { get; set; }
|
||||
public string JjYuanyin { get; set; } = ""; // 降级原因
|
||||
public string Description { get; set; } = ""; // 备注
|
||||
}
|
||||
|
||||
/// <summary>生丝批次-纤度检验(对应 F9 SS_Pici_Qc_Xdjy)</summary>
|
||||
[Table(Name = "WmsPiciQcXdjys")]
|
||||
public class WmsPiciQcXdjy : BaseEntity
|
||||
{
|
||||
public long PiciId { get; set; }
|
||||
public decimal Xiandu { get; set; }
|
||||
public int Num { get; set; }
|
||||
}
|
||||
|
||||
/// <summary>物资库存(对应 F9 WJ_Kucun,按物资目录一行)</summary>
|
||||
[Table(Name = "WmsKucuns")]
|
||||
[Index("IX_WmsKucuns_WzmlId", "WzmlId", IsUnique = true)]
|
||||
public class WmsKucun : BaseEntity
|
||||
{
|
||||
public long WzmlId { get; set; }
|
||||
public decimal Shuliang { get; set; } // 库存数量
|
||||
public decimal Danjia { get; set; } // 库存单价(加权平均)
|
||||
public decimal Jine { get; set; } // 库存金额
|
||||
}
|
||||
|
||||
/// <summary>原料采购(对应 F9 Yuanliao_Caigou)</summary>
|
||||
[Table(Name = "WmsCaigous")]
|
||||
public class WmsCaigou : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; }
|
||||
public string Code { get; set; } = ""; // 采购单号
|
||||
public long GysId { get; set; } // 供应商(往来单位)
|
||||
public long YlzkId { get; set; } // 原料庄口
|
||||
public int Jianshu { get; set; }
|
||||
public decimal Maozhong { get; set; }
|
||||
public decimal Pizhong { get; set; }
|
||||
public decimal Jingzhong { get; set; }
|
||||
public decimal Danjia { get; set; }
|
||||
public decimal Jine { get; set; }
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>原料翻包计划(对应 F9 Fbplan)</summary>
|
||||
[Table(Name = "WmsFbplans")]
|
||||
public class WmsFbplan : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; } // 翻包日期
|
||||
public string Code { get; set; } = ""; // 计划号
|
||||
public long YlzkId { get; set; } // 原料庄口
|
||||
public long WzmlId { get; set; } // 物资目录
|
||||
public int Jianshu { get; set; } // 计划件数
|
||||
public decimal Jingzhong { get; set; } // 计划净重
|
||||
public int FbType { get; set; } // 1翻包中 2完成 3暂停
|
||||
public int RukuStatus { get; set; } // 1有效 2作废 3无
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>原料翻包记录(对应 F9 Fbjl)</summary>
|
||||
[Table(Name = "WmsFbjls")]
|
||||
public class WmsFbjl : BaseEntity
|
||||
{
|
||||
public long FbplanId { get; set; }
|
||||
public DateTime Date { get; set; }
|
||||
public int Jianshu { get; set; }
|
||||
public decimal Jingzhong { get; set; }
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>物资采购计划(对应 F9 WJ_Cgplan)</summary>
|
||||
[Table(Name = "WmsCgplans")]
|
||||
public class WmsCgplan : BaseEntity
|
||||
{
|
||||
public DateTime Date { get; set; }
|
||||
public string Code { get; set; } = ""; // 计划号
|
||||
public long DepId { get; set; } // 申请部门
|
||||
public int Status { get; set; } // 0草稿 1已确认 2已完成
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
|
||||
/// <summary>物资采购计划明细(对应 F9 WJ_Cgplan_Item)</summary>
|
||||
[Table(Name = "WmsCgplanItems")]
|
||||
public class WmsCgplanItem : BaseEntity
|
||||
{
|
||||
public long CgplanId { get; set; }
|
||||
public long WzmlId { get; set; }
|
||||
public decimal Shuliang { get; set; }
|
||||
public decimal Danjia { get; set; }
|
||||
public decimal Jine { get; set; }
|
||||
public string Description { get; set; } = "";
|
||||
}
|
||||
Reference in New Issue
Block a user