| | |
| | | [ExporterHeader("错误信息", ColumnIndex = 9999, IsBold = true, IsAutoFit = true)] |
| | | public virtual string Error { get; set; } |
| | | } |
| | | public class BaseImportInputGuid |
| | | { |
| | | /// <summary> |
| | | /// 记录Id |
| | | /// </summary> |
| | | [ImporterHeader(IsIgnore = true)] |
| | | [ExporterHeader(IsIgnore = true)] |
| | | public virtual Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 错误信息 |
| | | /// </summary> |
| | | [ImporterHeader(IsIgnore = true)] |
| | | [ExporterHeader("错误信息", ColumnIndex = 9999, IsBold = true, IsAutoFit = true)] |
| | | public virtual string Error { get; set; } |
| | | } |
| | | |
New file |
| | |
| | | using Admin.NET.Core; |
| | | using SqlSugar; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | |
| | | namespace FZCZTB.NET.MD |
| | | { |
| | | /// <summary> |
| | | /// 投诉质疑结果 |
| | | /// </summary> |
| | | [SugarTable("FB_ProcurementComplaints")] |
| | | public partial class ProcurementComplaint: EntityBase |
| | | { |
| | | /// <summary> |
| | | /// 投诉ID,主键 |
| | | /// </summary> |
| | | [SugarColumn(IsPrimaryKey = true)] |
| | | public Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | [SugarColumn(Length = 50, IsNullable = false, ColumnDescription = "项目编号")] |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | [SugarColumn(Length = 200, IsNullable = false, ColumnDescription = "项目名称")] |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | [SugarColumn(IsNullable = false, ColumnDescription = "决定日期")] |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | [SugarColumn(Length = 100, IsNullable = false, ColumnDescription = "采购人")] |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | [SugarColumn(Length = 100, IsNullable = false, ColumnDescription = "采购代理机构")] |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | [SugarColumn(Length = 100, IsNullable = false, ColumnDescription = "投诉人")] |
| | | public string? Complainant { get; set; } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | [SugarColumn(Length = 100, IsNullable = true, ColumnDescription = "采购监督部门")] |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | [SugarColumn(Length = 255, IsNullable = true, ColumnDescription = "线上地址")] |
| | | public string Url { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉事项 |
| | | /// </summary> |
| | | [Navigate(NavigateType.OneToMany,nameof(ProcurementComplaintItems.ComplaintId))] |
| | | public List<ProcurementComplaintItems>? Complaints { get; set; } |
| | | } |
| | | |
| | | |
| | | /// <summary> |
| | | /// 投诉事项子表模型 |
| | | /// </summary> |
| | | [SugarTable("FB_ProcurementComplaintItems")] |
| | | public partial class ProcurementComplaintItems |
| | | { |
| | | /// <summary> |
| | | /// 投诉事项ID,主键 |
| | | /// </summary> |
| | | [SugarColumn(IsPrimaryKey = true)] |
| | | public Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 关联的主投诉ID |
| | | /// </summary> |
| | | [SugarColumn(IsNullable = false, ColumnDescription = "关联的主投诉ID")] |
| | | public Guid ComplaintId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 具体投诉事项 |
| | | /// </summary> |
| | | [SugarColumn(Length = 1000, IsNullable = false, ColumnDescription = "具体投诉事项")] |
| | | public string ItemDescription { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 处理结果 |
| | | /// </summary> |
| | | [SugarColumn(IsNullable = true, ColumnDescription = "处理结果")] |
| | | public PComplaintStatus HandlingStatus { get; set; } |
| | | /// <summary> |
| | | /// 处理描述 |
| | | /// </summary> |
| | | [SugarColumn(Length = 1000,IsNullable = true, ColumnDescription = "处理结果")] |
| | | public string? HandlingResult { get; set; } |
| | | } |
| | | |
| | | public enum PComplaintStatus |
| | | { |
| | | /// <summary> |
| | | /// 其他 |
| | | /// </summary> |
| | | Other = 0, |
| | | /// <summary> |
| | | /// 成立 |
| | | /// </summary> |
| | | Valid = 1, |
| | | |
| | | /// <summary> |
| | | /// 驳回 |
| | | /// </summary> |
| | | Rejected = 2, |
| | | |
| | | /// <summary> |
| | | /// 部分成立 |
| | | /// </summary> |
| | | PartiallyValid = 3 |
| | | |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | | |
New file |
| | |
| | | // Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。 |
| | | // |
| | | // 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。 |
| | | // |
| | | // 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任! |
| | | |
| | | namespace FZCZTB.TSCL.Application; |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理输出参数 |
| | | /// </summary> |
| | | public class ProcurementComplaintDto |
| | | { |
| | | /// <summary> |
| | | /// 主键Id |
| | | /// </summary> |
| | | public Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | public string? Url { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建时间 |
| | | /// </summary> |
| | | public DateTime? CreateTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 更新时间 |
| | | /// </summary> |
| | | public DateTime? UpdateTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建者Id |
| | | /// </summary> |
| | | public long? CreateUserId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建者姓名 |
| | | /// </summary> |
| | | public string? CreateUserName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 修改者Id |
| | | /// </summary> |
| | | public long? UpdateUserId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 修改者姓名 |
| | | /// </summary> |
| | | public string? UpdateUserName { get; set; } |
| | | |
| | | } |
New file |
| | |
| | | // Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。 |
| | | // |
| | | // 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。 |
| | | // |
| | | // 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任! |
| | | |
| | | using Admin.NET.Core; |
| | | using System.ComponentModel.DataAnnotations; |
| | | using Magicodes.ExporterAndImporter.Core; |
| | | using Magicodes.ExporterAndImporter.Excel; |
| | | using FZCZTB.NET.MD; |
| | | |
| | | namespace FZCZTB.TSCL.Application; |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理基础输入参数 |
| | | /// </summary> |
| | | public class ProcurementComplaintBaseInput |
| | | { |
| | | /// <summary> |
| | | /// 主键Id |
| | | /// </summary> |
| | | public virtual Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目编号不能为空")] |
| | | public virtual string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目名称不能为空")] |
| | | public virtual string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "决定日期不能为空")] |
| | | public virtual DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购人不能为空")] |
| | | public virtual string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购代理机构不能为空")] |
| | | public virtual string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | public virtual string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | public virtual string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | public virtual string? Url { get; set; } |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理分页查询输入参数 |
| | | /// </summary> |
| | | public class PageProcurementComplaintInput : BasePageInput |
| | | { |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期范围 |
| | | /// </summary> |
| | | public DateTime?[] DecisionDateRange { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | public string? Url { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 选中主键列表 |
| | | /// </summary> |
| | | public List<Guid> SelectKeyList { get; set; } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理增加输入参数 |
| | | /// </summary> |
| | | public class AddProcurementComplaintInput |
| | | { |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目编号不能为空")] |
| | | [MaxLength(50, ErrorMessage = "项目编号字符长度不能超过50")] |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目名称不能为空")] |
| | | [MaxLength(200, ErrorMessage = "项目名称字符长度不能超过200")] |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "决定日期不能为空")] |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购人不能为空")] |
| | | [MaxLength(100, ErrorMessage = "采购人字符长度不能超过100")] |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购代理机构不能为空")] |
| | | [MaxLength(100, ErrorMessage = "采购代理机构字符长度不能超过100")] |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | [MaxLength(100, ErrorMessage = "投诉人字符长度不能超过100")] |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | [MaxLength(100, ErrorMessage = "采购监督部门字符长度不能超过100")] |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | [MaxLength(255, ErrorMessage = "线上地址字符长度不能超过255")] |
| | | public string? Url { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉事项 |
| | | /// </summary> |
| | | public List<ProcurementComplaintItems>? Complaints { get; set; } |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理删除输入参数 |
| | | /// </summary> |
| | | public class DeleteProcurementComplaintInput |
| | | { |
| | | /// <summary> |
| | | /// 主键Id |
| | | /// </summary> |
| | | [Required(ErrorMessage = "主键Id不能为空")] |
| | | public Guid Id { get; set; } |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理更新输入参数 |
| | | /// </summary> |
| | | public class UpdateProcurementComplaintInput |
| | | { |
| | | /// <summary> |
| | | /// 主键Id |
| | | /// </summary> |
| | | [Required(ErrorMessage = "主键Id不能为空")] |
| | | public Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目编号不能为空")] |
| | | [MaxLength(50, ErrorMessage = "项目编号字符长度不能超过50")] |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "项目名称不能为空")] |
| | | [MaxLength(200, ErrorMessage = "项目名称字符长度不能超过200")] |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "决定日期不能为空")] |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购人不能为空")] |
| | | [MaxLength(100, ErrorMessage = "采购人字符长度不能超过100")] |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | [Required(ErrorMessage = "采购代理机构不能为空")] |
| | | [MaxLength(100, ErrorMessage = "采购代理机构字符长度不能超过100")] |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | [MaxLength(100, ErrorMessage = "投诉人字符长度不能超过100")] |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | [MaxLength(100, ErrorMessage = "采购监督部门字符长度不能超过100")] |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | [MaxLength(255, ErrorMessage = "线上地址字符长度不能超过255")] |
| | | public string? Url { get; set; } |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理主键查询输入参数 |
| | | /// </summary> |
| | | public class QueryByIdProcurementComplaintInput : DeleteProcurementComplaintInput |
| | | { |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理数据导入实体 |
| | | /// </summary> |
| | | [ExcelImporter(SheetIndex = 1, IsOnlyErrorRows = true)] |
| | | public class ImportProcurementComplaintInput : BaseImportInput |
| | | { |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "*项目编号")] |
| | | [ExporterHeader("*项目编号", Format = "", Width = 25, IsBold = true)] |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "*项目名称")] |
| | | [ExporterHeader("*项目名称", Format = "", Width = 25, IsBold = true)] |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "*决定日期")] |
| | | [ExporterHeader("*决定日期", Format = "", Width = 25, IsBold = true)] |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "*采购人")] |
| | | [ExporterHeader("*采购人", Format = "", Width = 25, IsBold = true)] |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "*采购代理机构")] |
| | | [ExporterHeader("*采购代理机构", Format = "", Width = 25, IsBold = true)] |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "投诉人")] |
| | | [ExporterHeader("投诉人", Format = "", Width = 25, IsBold = true)] |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "采购监督部门")] |
| | | [ExporterHeader("采购监督部门", Format = "", Width = 25, IsBold = true)] |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | [ImporterHeader(Name = "线上地址")] |
| | | [ExporterHeader("线上地址", Format = "", Width = 25, IsBold = true)] |
| | | public string? Url { get; set; } |
| | | |
| | | } |
New file |
| | |
| | | // Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。 |
| | | // |
| | | // 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。 |
| | | // |
| | | // 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任! |
| | | using Magicodes.ExporterAndImporter.Core; |
| | | namespace FZCZTB.TSCL.Application; |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理输出参数 |
| | | /// </summary> |
| | | public class ProcurementComplaintOutput |
| | | { |
| | | /// <summary> |
| | | /// 主键Id |
| | | /// </summary> |
| | | public Guid Id { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目编号 |
| | | /// </summary> |
| | | public string ProjectCode { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 项目名称 |
| | | /// </summary> |
| | | public string ProjectName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 决定日期 |
| | | /// </summary> |
| | | public DateTime DecisionDate { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购人 |
| | | /// </summary> |
| | | public string Purchaser { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购代理机构 |
| | | /// </summary> |
| | | public string ProcurementAgency { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 投诉人 |
| | | /// </summary> |
| | | public string? Complainant { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 采购监督部门 |
| | | /// </summary> |
| | | public string? ProcurementSupervisionDepartment { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 线上地址 |
| | | /// </summary> |
| | | public string? Url { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建时间 |
| | | /// </summary> |
| | | public DateTime? CreateTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 更新时间 |
| | | /// </summary> |
| | | public DateTime? UpdateTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建者Id |
| | | /// </summary> |
| | | public long? CreateUserId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 创建者姓名 |
| | | /// </summary> |
| | | public string? CreateUserName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 修改者Id |
| | | /// </summary> |
| | | public long? UpdateUserId { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 修改者姓名 |
| | | /// </summary> |
| | | public string? UpdateUserName { get; set; } |
| | | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理数据导入模板实体 |
| | | /// </summary> |
| | | public class ExportProcurementComplaintOutput : ImportProcurementComplaintInput |
| | | { |
| | | [ImporterHeader(IsIgnore = true)] |
| | | [ExporterHeader(IsIgnore = true)] |
| | | public override string Error { get; set; } |
| | | |
| | | |
| | | } |
New file |
| | |
| | | // Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。 |
| | | // |
| | | // 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。 |
| | | // |
| | | // 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任! |
| | | |
| | | using Admin.NET.Core.Service; |
| | | using Microsoft.AspNetCore.Http; |
| | | |
| | | using Furion.DatabaseAccessor; |
| | | using Furion.FriendlyException; |
| | | using Mapster; |
| | | using SqlSugar; |
| | | using System.ComponentModel; |
| | | using System.ComponentModel.DataAnnotations; |
| | | using Microsoft.AspNetCore.Mvc; |
| | | using Admin.NET.Application; |
| | | using Admin.NET.Core; |
| | | using FZCZTB.NET.MD; |
| | | using Furion.DynamicApiController; |
| | | using Furion.DependencyInjection; |
| | | using System.Collections.Generic; |
| | | using System.Linq; |
| | | using NewLife.Xml; |
| | | using AngleSharp.Dom; |
| | | namespace FZCZTB.TSCL.Application; |
| | | |
| | | /// <summary> |
| | | /// 政府采购投诉数据处理服务 🧩 |
| | | /// </summary> |
| | | [ApiDescriptionSettings(ApplicationConst.GroupName, Order = 100)] |
| | | public class ProcurementComplaintService : IDynamicApiController, ITransient |
| | | { |
| | | private readonly SqlSugarRepository<ProcurementComplaint> _procurementComplaintRep; |
| | | private readonly ISqlSugarClient _sqlSugarClient; |
| | | |
| | | public ProcurementComplaintService(SqlSugarRepository<ProcurementComplaint> procurementComplaintRep, ISqlSugarClient sqlSugarClient) |
| | | { |
| | | _procurementComplaintRep = procurementComplaintRep; |
| | | _sqlSugarClient = sqlSugarClient; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 分页查询政府采购投诉数据处理 🔖 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("分页查询政府采购投诉数据处理")] |
| | | [ApiDescriptionSettings(Name = "Page"), HttpPost] |
| | | public async Task<SqlSugarPagedList<ProcurementComplaintOutput>> Page(PageProcurementComplaintInput input) |
| | | { |
| | | input.Keyword = input.Keyword?.Trim(); |
| | | var query = _procurementComplaintRep.AsQueryable() |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.Keyword), u => u.ProjectCode.Contains(input.Keyword) || u.ProjectName.Contains(input.Keyword) || u.Purchaser.Contains(input.Keyword) || u.ProcurementAgency.Contains(input.Keyword) || u.Complainant.Contains(input.Keyword) || u.ProcurementSupervisionDepartment.Contains(input.Keyword) || u.Url.Contains(input.Keyword)) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.ProjectCode), u => u.ProjectCode.Contains(input.ProjectCode.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.ProjectName), u => u.ProjectName.Contains(input.ProjectName.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.Purchaser), u => u.Purchaser.Contains(input.Purchaser.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.ProcurementAgency), u => u.ProcurementAgency.Contains(input.ProcurementAgency.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.Complainant), u => u.Complainant.Contains(input.Complainant.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.ProcurementSupervisionDepartment), u => u.ProcurementSupervisionDepartment.Contains(input.ProcurementSupervisionDepartment.Trim())) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(input.Url), u => u.Url.Contains(input.Url.Trim())) |
| | | .WhereIF(input.DecisionDateRange?.Length == 2, u => u.DecisionDate >= input.DecisionDateRange[0] && u.DecisionDate <= input.DecisionDateRange[1]) |
| | | .Select<ProcurementComplaintOutput>(); |
| | | return await query.OrderBuilder(input).ToPagedListAsync(input.Page, input.PageSize); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 获取政府采购投诉数据处理详情 ℹ️ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("获取政府采购投诉数据处理详情")] |
| | | [ApiDescriptionSettings(Name = "Detail"), HttpGet] |
| | | public async Task<ProcurementComplaint> Detail([FromQuery] QueryByIdProcurementComplaintInput input) |
| | | { |
| | | return await _procurementComplaintRep.GetFirstAsync(u => u.Id == input.Id); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 增加政府采购投诉数据处理 ➕ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("增加政府采购投诉数据处理")] |
| | | [ApiDescriptionSettings(Name = "Add"), HttpPost] |
| | | public async Task<bool> Add(AddProcurementComplaintInput input) |
| | | { |
| | | var entity = input.Adapt<ProcurementComplaint>(); |
| | | entity.Id = Guid.NewGuid(); |
| | | |
| | | return await _sqlSugarClient.InsertNav(entity).Include(x=>x.Complaints).ExecuteCommandAsync(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 更新政府采购投诉数据处理 ✏️ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("更新政府采购投诉数据处理")] |
| | | [ApiDescriptionSettings(Name = "Update"), HttpPost] |
| | | public async Task Update(UpdateProcurementComplaintInput input) |
| | | { |
| | | var entity = input.Adapt<ProcurementComplaint>(); |
| | | await _procurementComplaintRep.AsUpdateable(entity) |
| | | .ExecuteCommandAsync(); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 删除政府采购投诉数据处理 ❌ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("删除政府采购投诉数据处理")] |
| | | [ApiDescriptionSettings(Name = "Delete"), HttpPost] |
| | | public async Task Delete(DeleteProcurementComplaintInput input) |
| | | { |
| | | //var entity = await _procurementComplaintRep.GetFirstAsync(u => u.Id == input.Id) ?? throw Oops.Oh(ErrorCodeEnum.D1002); |
| | | var entity = await _sqlSugarClient.Queryable<ProcurementComplaint>().Includes(x=>x.Complaints).Where(x=>x.Id== input.Id).FirstAsync() ?? throw Oops.Oh(ErrorCodeEnum.D1002); |
| | | //await _procurementComplaintRep.FakeDeleteAsync(entity); //假删除 |
| | | await _sqlSugarClient.DeleteNav(entity).Include(x => x.Complaints).ExecuteCommandAsync(); //真删除 |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 批量删除政府采购投诉数据处理 ❌ |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("批量删除政府采购投诉数据处理")] |
| | | [ApiDescriptionSettings(Name = "BatchDelete"), HttpPost] |
| | | public async Task<bool > BatchDelete([Required(ErrorMessage = "主键列表不能为空")]List<DeleteProcurementComplaintInput> input) |
| | | { |
| | | var exp = Expressionable.Create<ProcurementComplaint>(); |
| | | foreach (var row in input) exp = exp.Or(it => it.Id == row.Id); |
| | | var list = await _procurementComplaintRep.AsQueryable().Where(exp.ToExpression()).ToListAsync(); |
| | | |
| | | // return await _procurementComplaintRep.FakeDeleteAsync(list); //假删除 |
| | | return await _sqlSugarClient.DeleteNav(list).Include(x => x.Complaints).ExecuteCommandAsync(); ; //真删除 |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 导出政府采购投诉数据处理记录 🔖 |
| | | /// </summary> |
| | | /// <param name="input"></param> |
| | | /// <returns></returns> |
| | | [DisplayName("导出政府采购投诉数据处理记录")] |
| | | [ApiDescriptionSettings(Name = "Export"), HttpPost, NonUnify] |
| | | public async Task<IActionResult> Export(PageProcurementComplaintInput input) |
| | | { |
| | | var list = (await Page(input)).Items?.Adapt<List<ExportProcurementComplaintOutput>>() ?? new(); |
| | | //if (input.SelectKeyList?.Count > 0) list = list.Where(x => input.SelectKeyList.Contains(x.Id)).ToList(); |
| | | return ExcelHelper.ExportTemplate(list, "政府采购投诉数据处理导出记录"); |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 下载政府采购投诉数据处理数据导入模板 ⬇️ |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [DisplayName("下载政府采购投诉数据处理数据导入模板")] |
| | | [ApiDescriptionSettings(Name = "Import"), HttpGet, NonUnify] |
| | | public IActionResult DownloadTemplate() |
| | | { |
| | | return ExcelHelper.ExportTemplate(new List<ExportProcurementComplaintOutput>(), "政府采购投诉数据处理导入模板"); |
| | | } |
| | | |
| | | private static readonly object _procurementComplaintImportLock = new object(); |
| | | /// <summary> |
| | | /// 导入政府采购投诉数据处理记录 💾 |
| | | /// </summary> |
| | | /// <returns></returns> |
| | | [DisplayName("导入政府采购投诉数据处理记录")] |
| | | [ApiDescriptionSettings(Name = "Import"), HttpPost, NonUnify, UnitOfWork] |
| | | public IActionResult ImportData([Required] IFormFile file) |
| | | { |
| | | lock (_procurementComplaintImportLock) |
| | | { |
| | | var stream = ExcelHelper.ImportData<ImportProcurementComplaintInput, ProcurementComplaint>(file, (list, markerErrorAction) => |
| | | { |
| | | _sqlSugarClient.Utilities.PageEach(list, 2048, pageItems => |
| | | { |
| | | |
| | | // 校验并过滤必填基本类型为null的字段 |
| | | var rows = pageItems.Where(x => { |
| | | return true; |
| | | }).Adapt<List<ProcurementComplaint>>(); |
| | | |
| | | var storageable = _procurementComplaintRep.Context.Storageable(rows) |
| | | .SplitError(it => string.IsNullOrWhiteSpace(it.Item.ProjectCode), "项目编号不能为空") |
| | | .SplitError(it => it.Item.ProjectCode?.Length > 50, "项目编号长度不能超过50个字符") |
| | | .SplitError(it => string.IsNullOrWhiteSpace(it.Item.ProjectName), "项目名称不能为空") |
| | | .SplitError(it => it.Item.ProjectName?.Length > 200, "项目名称长度不能超过200个字符") |
| | | .SplitError(it => string.IsNullOrWhiteSpace(it.Item.Purchaser), "采购人不能为空") |
| | | .SplitError(it => it.Item.Purchaser?.Length > 100, "采购人长度不能超过100个字符") |
| | | .SplitError(it => string.IsNullOrWhiteSpace(it.Item.ProcurementAgency), "采购代理机构不能为空") |
| | | .SplitError(it => it.Item.ProcurementAgency?.Length > 100, "采购代理机构长度不能超过100个字符") |
| | | .SplitError(it => it.Item.Complainant?.Length > 100, "投诉人长度不能超过100个字符") |
| | | .SplitError(it => it.Item.ProcurementSupervisionDepartment?.Length > 100, "采购监督部门长度不能超过100个字符") |
| | | .SplitError(it => it.Item.Url?.Length > 255, "线上地址长度不能超过255个字符") |
| | | .SplitInsert(_ => true) |
| | | .ToStorage(); |
| | | |
| | | storageable.AsInsertable.ExecuteCommand();// 不存在插入 |
| | | storageable.AsUpdateable.ExecuteCommand();// 存在更新 |
| | | |
| | | // 标记错误信息 |
| | | markerErrorAction.Invoke(storageable, pageItems, rows); |
| | | }); |
| | | }); |
| | | |
| | | return stream; |
| | | } |
| | | } |
| | | } |
New file |
| | |
| | | import {useBaseApi} from '/@/api/base'; |
| | | |
| | | // 政府采购投诉数据处理接口服务 |
| | | export const useProcurementComplaintApi = () => { |
| | | const baseApi = useBaseApi("procurementComplaint"); |
| | | return { |
| | | // 分页查询政府采购投诉数据处理 |
| | | page: baseApi.page, |
| | | // 查看政府采购投诉数据处理详细 |
| | | detail: baseApi.detail, |
| | | // 新增政府采购投诉数据处理 |
| | | add: baseApi.add, |
| | | // 更新政府采购投诉数据处理 |
| | | update: baseApi.update, |
| | | // 删除政府采购投诉数据处理 |
| | | delete: baseApi.delete, |
| | | // 批量删除政府采购投诉数据处理 |
| | | batchDelete: baseApi.batchDelete, |
| | | // 导出政府采购投诉数据处理数据 |
| | | exportData: baseApi.exportData, |
| | | // 导入政府采购投诉数据处理数据 |
| | | importData: baseApi.importData, |
| | | // 下载政府采购投诉数据处理数据导入模板 |
| | | downloadTemplate: baseApi.downloadTemplate, |
| | | } |
| | | } |
| | | |
| | | // 政府采购投诉数据处理实体 |
| | | export interface ProcurementComplaint { |
| | | // 主键Id |
| | | id: string; |
| | | // 项目编号 |
| | | projectCode?: string; |
| | | // 项目名称 |
| | | projectName?: string; |
| | | // 决定日期 |
| | | decisionDate?: string; |
| | | // 采购人 |
| | | purchaser?: string; |
| | | // 采购代理机构 |
| | | procurementAgency?: string; |
| | | // 投诉人 |
| | | complainant: string; |
| | | // 采购监督部门 |
| | | procurementSupervisionDepartment: string; |
| | | // 线上地址 |
| | | url: string; |
| | | // 创建时间 |
| | | createTime: string; |
| | | // 更新时间 |
| | | updateTime: string; |
| | | // 创建者Id |
| | | createUserId: number; |
| | | // 创建者姓名 |
| | | createUserName: string; |
| | | // 修改者Id |
| | | updateUserId: number; |
| | | // 修改者姓名 |
| | | updateUserName: string; |
| | | } |
New file |
| | |
| | | <script lang="ts" name="procurementComplaint" setup> |
| | | import { ref, reactive, onMounted } from "vue"; |
| | | import { ElMessage } from "element-plus"; |
| | | import type { FormRules } from "element-plus"; |
| | | import { formatDate } from '/@/utils/formatTime'; |
| | | import { useProcurementComplaintApi } from '/@/api/fb_p_complaints/procurementComplaint'; |
| | | |
| | | //父级传递来的函数,用于回调 |
| | | const emit = defineEmits(["reloadTable"]); |
| | | const procurementComplaintApi = useProcurementComplaintApi(); |
| | | const ruleFormRef = ref(); |
| | | |
| | | const state = reactive({ |
| | | title: '', |
| | | loading: false, |
| | | showDialog: false, |
| | | ruleForm: {} as any, |
| | | stores: {}, |
| | | dropdownData: {} as any, |
| | | }); |
| | | |
| | | // 自行添加其他规则 |
| | | const rules = ref<FormRules>({ |
| | | projectCode: [{required: true, message: '请选择项目编号!', trigger: 'blur',},], |
| | | projectName: [{required: true, message: '请选择项目名称!', trigger: 'blur',},], |
| | | decisionDate: [{required: true, message: '请选择决定日期!', trigger: 'change',},], |
| | | purchaser: [{required: true, message: '请选择采购人!', trigger: 'blur',},], |
| | | procurementAgency: [{required: true, message: '请选择采购代理机构!', trigger: 'blur',},], |
| | | }); |
| | | |
| | | // 页面加载时 |
| | | onMounted(async () => { |
| | | }); |
| | | |
| | | // 打开弹窗 |
| | | const openDialog = async (row: any, title: string) => { |
| | | state.title = title; |
| | | row = row ?? { }; |
| | | state.ruleForm = row.id ? await procurementComplaintApi.detail(row.id).then(res => res.data.result) : JSON.parse(JSON.stringify(row)); |
| | | state.showDialog = true; |
| | | }; |
| | | |
| | | // 关闭弹窗 |
| | | const closeDialog = () => { |
| | | emit("reloadTable"); |
| | | state.showDialog = false; |
| | | }; |
| | | |
| | | // 提交 |
| | | const submit = async () => { |
| | | ruleFormRef.value.validate(async (isValid: boolean, fields?: any) => { |
| | | if (isValid) { |
| | | let values = state.ruleForm; |
| | | await procurementComplaintApi[state.ruleForm.id ? 'update' : 'add'](values); |
| | | closeDialog(); |
| | | } else { |
| | | ElMessage({ |
| | | message: `表单有${Object.keys(fields).length}处验证失败,请修改后再提交`, |
| | | type: "error", |
| | | }); |
| | | } |
| | | }); |
| | | }; |
| | | |
| | | //将属性或者函数暴露给父组件 |
| | | defineExpose({ openDialog }); |
| | | </script> |
| | | <template> |
| | | <div class="procurementComplaint-container"> |
| | | <el-dialog v-model="state.showDialog" :width="800" draggable :close-on-click-modal="false"> |
| | | <template #header> |
| | | <div style="color: #fff"> |
| | | <span>{{ state.title }}</span> |
| | | </div> |
| | | </template> |
| | | <el-form :model="state.ruleForm" ref="ruleFormRef" label-width="auto" :rules="rules"> |
| | | <el-row :gutter="35"> |
| | | <el-form-item v-show="false"> |
| | | <el-input v-model="state.ruleForm.id" /> |
| | | </el-form-item> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="项目编号" prop="projectCode"> |
| | | <el-input v-model="state.ruleForm.projectCode" placeholder="请输入项目编号" maxlength="50" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="项目名称" prop="projectName"> |
| | | <el-input v-model="state.ruleForm.projectName" placeholder="请输入项目名称" maxlength="200" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="决定日期" prop="decisionDate"> |
| | | <el-date-picker v-model="state.ruleForm.decisionDate" type="date" placeholder="决定日期" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="采购人" prop="purchaser"> |
| | | <el-input v-model="state.ruleForm.purchaser" placeholder="请输入采购人" maxlength="100" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="采购代理机构" prop="procurementAgency"> |
| | | <el-input v-model="state.ruleForm.procurementAgency" placeholder="请输入采购代理机构" maxlength="100" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="投诉人" prop="complainant"> |
| | | <el-input v-model="state.ruleForm.complainant" placeholder="请输入投诉人" maxlength="100" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="采购监督部门" prop="procurementSupervisionDepartment"> |
| | | <el-input v-model="state.ruleForm.procurementSupervisionDepartment" placeholder="请输入采购监督部门" maxlength="100" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20" > |
| | | <el-form-item label="线上地址" prop="url"> |
| | | <el-input v-model="state.ruleForm.url" placeholder="请输入线上地址" maxlength="255" show-word-limit clearable /> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <template #footer> |
| | | <span class="dialog-footer"> |
| | | <el-button @click="() => state.showDialog = false">取 消</el-button> |
| | | <el-button @click="submit" type="primary" v-reclick="1000">确 定</el-button> |
| | | </span> |
| | | </template> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | <style lang="scss" scoped> |
| | | :deep(.el-select), :deep(.el-input-number) { |
| | | width: 100%; |
| | | } |
| | | </style> |
New file |
| | |
| | | <script lang="ts" setup name="procurementComplaint"> |
| | | import { ref, reactive, onMounted } from "vue"; |
| | | import { auth } from '/@/utils/authFunction'; |
| | | import { ElMessageBox, ElMessage } from "element-plus"; |
| | | import { downloadStreamFile } from "/@/utils/download"; |
| | | import { useProcurementComplaintApi } from '/@/api/fb_p_complaints/procurementComplaint'; |
| | | import editDialog from '/@/views/fb_p_complaints/procurementComplaint/component/editDialog.vue' |
| | | import printDialog from '/@/views/system/print/component/hiprint/preview.vue' |
| | | import ModifyRecord from '/@/components/table/modifyRecord.vue'; |
| | | import ImportData from "/@/components/table/importData.vue"; |
| | | |
| | | const procurementComplaintApi = useProcurementComplaintApi(); |
| | | const printDialogRef = ref(); |
| | | const editDialogRef = ref(); |
| | | const importDataRef = ref(); |
| | | const state = reactive({ |
| | | exportLoading: false, |
| | | tableLoading: false, |
| | | stores: {}, |
| | | showAdvanceQueryUI: false, |
| | | dropdownData: {} as any, |
| | | selectData: [] as any[], |
| | | tableQueryParams: {} as any, |
| | | tableParams: { |
| | | page: 1, |
| | | pageSize: 20, |
| | | total: 0, |
| | | field: 'createTime', // 默认的排序字段 |
| | | order: 'descending', // 排序方向 |
| | | descStr: 'descending', // 降序排序的关键字符 |
| | | }, |
| | | tableData: [], |
| | | }); |
| | | |
| | | // 页面加载时 |
| | | onMounted(async () => { |
| | | }); |
| | | |
| | | // 查询操作 |
| | | const handleQuery = async (params: any = {}) => { |
| | | state.tableLoading = true; |
| | | state.tableParams = Object.assign(state.tableParams, params); |
| | | const result = await procurementComplaintApi.page(Object.assign(state.tableQueryParams, state.tableParams)).then(res => res.data.result); |
| | | state.tableParams.total = result?.total; |
| | | state.tableData = result?.items ?? []; |
| | | state.tableLoading = false; |
| | | }; |
| | | |
| | | // 列排序 |
| | | const sortChange = async (column: any) => { |
| | | state.tableParams.field = column.prop; |
| | | state.tableParams.order = column.order; |
| | | await handleQuery(); |
| | | }; |
| | | |
| | | // 删除 |
| | | const delProcurementComplaint = (row: any) => { |
| | | ElMessageBox.confirm(`确定要删除吗?`, "提示", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(async () => { |
| | | await procurementComplaintApi.delete({ id: row.id }); |
| | | handleQuery(); |
| | | ElMessage.success("删除成功"); |
| | | }).catch(() => {}); |
| | | }; |
| | | |
| | | // 批量删除 |
| | | const batchDelProcurementComplaint = () => { |
| | | ElMessageBox.confirm(`确定要删除${state.selectData.length}条记录吗?`, "提示", { |
| | | confirmButtonText: "确定", |
| | | cancelButtonText: "取消", |
| | | type: "warning", |
| | | }).then(async () => { |
| | | await procurementComplaintApi.batchDelete(state.selectData.map(u => ({ id: u.id }) )).then(res => { |
| | | ElMessage.success(`成功批量删除${res.data.result}条记录`); |
| | | handleQuery(); |
| | | }); |
| | | }).catch(() => {}); |
| | | }; |
| | | |
| | | // 导出数据 |
| | | const exportProcurementComplaintCommand = async (command: string) => { |
| | | try { |
| | | state.exportLoading = true; |
| | | if (command === 'select') { |
| | | const params = Object.assign({}, state.tableQueryParams, state.tableParams, { selectKeyList: state.selectData.map(u => u.id) }); |
| | | await procurementComplaintApi.exportData(params).then(res => downloadStreamFile(res)); |
| | | } else if (command === 'current') { |
| | | const params = Object.assign({}, state.tableQueryParams, state.tableParams); |
| | | await procurementComplaintApi.exportData(params).then(res => downloadStreamFile(res)); |
| | | } else if (command === 'all') { |
| | | const params = Object.assign({}, state.tableQueryParams, state.tableParams, { page: 1, pageSize: 99999999 }); |
| | | await procurementComplaintApi.exportData(params).then(res => downloadStreamFile(res)); |
| | | } |
| | | } finally { |
| | | state.exportLoading = false; |
| | | } |
| | | } |
| | | |
| | | handleQuery(); |
| | | </script> |
| | | <template> |
| | | <div class="procurementComplaint-container" v-loading="state.exportLoading"> |
| | | <el-card shadow="hover" :body-style="{ paddingBottom: '0' }"> |
| | | <el-form :model="state.tableQueryParams" ref="queryForm" labelWidth="90"> |
| | | <el-row> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10"> |
| | | <el-form-item label="关键字"> |
| | | <el-input v-model="state.tableQueryParams.keyword" clearable placeholder="请输入模糊查询关键字"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="项目编号"> |
| | | <el-input v-model="state.tableQueryParams.projectCode" clearable placeholder="请输入项目编号"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="项目名称"> |
| | | <el-input v-model="state.tableQueryParams.projectName" clearable placeholder="请输入项目名称"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="决定日期"> |
| | | <el-date-picker type="daterange" v-model="state.tableQueryParams.decisionDateRange" value-format="YYYY-MM-DD HH:mm:ss" start-placeholder="开始日期" end-placeholder="结束日期" :default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]" /> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="采购人"> |
| | | <el-input v-model="state.tableQueryParams.purchaser" clearable placeholder="请输入采购人"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="采购代理机构"> |
| | | <el-input v-model="state.tableQueryParams.procurementAgency" clearable placeholder="请输入采购代理机构"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="投诉人"> |
| | | <el-input v-model="state.tableQueryParams.complainant" clearable placeholder="请输入投诉人"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="采购监督部门"> |
| | | <el-input v-model="state.tableQueryParams.procurementSupervisionDepartment" clearable placeholder="请输入采购监督部门"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10" v-if="state.showAdvanceQueryUI"> |
| | | <el-form-item label="线上地址"> |
| | | <el-input v-model="state.tableQueryParams.url" clearable placeholder="请输入线上地址"/> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :xs="24" :sm="12" :md="12" :lg="8" :xl="4" class="mb10"> |
| | | <el-form-item > |
| | | <el-button-group style="display: flex; align-items: center;"> |
| | | <el-button type="primary" icon="ele-Search" @click="handleQuery" v-auth="'procurementComplaint:page'" v-reclick="1000"> 查询 </el-button> |
| | | <el-button icon="ele-Refresh" @click="() => state.tableQueryParams = {}"> 重置 </el-button> |
| | | <el-button icon="ele-ZoomIn" @click="() => state.showAdvanceQueryUI = true" v-if="!state.showAdvanceQueryUI" style="margin-left:5px;"> 高级查询 </el-button> |
| | | <el-button icon="ele-ZoomOut" @click="() => state.showAdvanceQueryUI = false" v-if="state.showAdvanceQueryUI" style="margin-left:5px;"> 隐藏 </el-button> |
| | | <el-button type="danger" style="margin-left:5px;" icon="ele-Delete" @click="batchDelProcurementComplaint" :disabled="state.selectData.length == 0" v-auth="'procurementComplaint:batchDelete'"> 删除 </el-button> |
| | | <el-button type="primary" style="margin-left:5px;" icon="ele-Plus" @click="editDialogRef.openDialog(null, '新增政府采购投诉数据处理')" v-auth="'procurementComplaint:add'"> 新增 </el-button> |
| | | <el-dropdown :show-timeout="70" :hide-timeout="50" @command="exportProcurementComplaintCommand"> |
| | | <el-button type="primary" style="margin-left:5px;" icon="ele-FolderOpened" v-reclick="20000" v-auth="'procurementComplaint:export'"> 导出 </el-button> |
| | | <template #dropdown> |
| | | <el-dropdown-menu> |
| | | <el-dropdown-item command="select" :disabled="state.selectData.length == 0">导出选中</el-dropdown-item> |
| | | <el-dropdown-item command="current">导出本页</el-dropdown-item> |
| | | <el-dropdown-item command="all">导出全部</el-dropdown-item> |
| | | </el-dropdown-menu> |
| | | </template> |
| | | </el-dropdown> |
| | | <el-button type="warning" style="margin-left:5px;" icon="ele-MostlyCloudy" @click="importDataRef.openDialog()" v-auth="'procurementComplaint:import'"> 导入 </el-button> |
| | | </el-button-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | </el-card> |
| | | <el-card class="full-table" shadow="hover" style="margin-top: 5px"> |
| | | <el-table :data="state.tableData" @selection-change="(val: any[]) => { state.selectData = val; }" style="width: 100%" v-loading="state.tableLoading" tooltip-effect="light" row-key="id" @sort-change="sortChange" border> |
| | | <el-table-column type="selection" width="40" align="center" v-if="auth('procurementComplaint:batchDelete') || auth('procurementComplaint:export')" /> |
| | | <el-table-column type="index" label="序号" width="55" align="center"/> |
| | | <el-table-column prop='projectCode' label='项目编号' show-overflow-tooltip /> |
| | | <el-table-column prop='projectName' label='项目名称' show-overflow-tooltip /> |
| | | <el-table-column prop='decisionDate' label='决定日期' show-overflow-tooltip /> |
| | | <el-table-column prop='purchaser' label='采购人' show-overflow-tooltip /> |
| | | <el-table-column prop='procurementAgency' label='采购代理机构' show-overflow-tooltip /> |
| | | <el-table-column prop='complainant' label='投诉人' show-overflow-tooltip /> |
| | | <el-table-column prop='procurementSupervisionDepartment' label='采购监督部门' show-overflow-tooltip /> |
| | | <el-table-column prop='url' label='线上地址' show-overflow-tooltip /> |
| | | <el-table-column label="修改记录" width="100" align="center" show-overflow-tooltip> |
| | | <template #default="scope"> |
| | | <ModifyRecord :data="scope.row" /> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="操作" width="140" align="center" fixed="right" show-overflow-tooltip v-if="auth('procurementComplaint:update') || auth('procurementComplaint:delete')"> |
| | | <template #default="scope"> |
| | | <el-button icon="ele-Edit" size="small" text type="primary" @click="editDialogRef.openDialog(scope.row, '编辑政府采购投诉数据处理')" v-auth="'procurementComplaint:update'"> 编辑 </el-button> |
| | | <el-button icon="ele-Delete" size="small" text type="primary" @click="delProcurementComplaint(scope.row)" v-auth="'procurementComplaint:delete'"> 删除 </el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination |
| | | v-model:currentPage="state.tableParams.page" |
| | | v-model:page-size="state.tableParams.pageSize" |
| | | @size-change="(val: any) => handleQuery({ pageSize: val })" |
| | | @current-change="(val: any) => handleQuery({ page: val })" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | :page-sizes="[10, 20, 50, 100, 200, 500]" |
| | | :total="state.tableParams.total" |
| | | size="small" |
| | | background /> |
| | | <ImportData ref="importDataRef" :import="procurementComplaintApi.importData" :download="procurementComplaintApi.downloadTemplate" v-auth="'procurementComplaint:import'" @refresh="handleQuery"/> |
| | | <printDialog ref="printDialogRef" :title="'打印政府采购投诉数据处理'" @reloadTable="handleQuery" /> |
| | | <editDialog ref="editDialogRef" @reloadTable="handleQuery" /> |
| | | </el-card> |
| | | </div> |
| | | </template> |
| | | <style scoped> |
| | | :deep(.el-input), :deep(.el-select), :deep(.el-input-number) { |
| | | width: 100%; |
| | | } |
| | | </style> |