Compare commits
3 Commits
1e1ec2e190
...
fcd70fd027
Author | SHA1 | Date | |
---|---|---|---|
fcd70fd027 | |||
0a109b93c7 | |||
2095b88323 |
@ -0,0 +1,47 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using Admin.NET.Core;
|
||||||
|
using SqlSugar;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
namespace Vistar.Application.Entity;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarTable("FieldGroupDefault","")]
|
||||||
|
[Tenant("启威星 1.94.4.74")]
|
||||||
|
public class FieldGroupDefault
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "FieldGroupDefaultId", IsIdentity = true, ColumnDescription = "", IsPrimaryKey = true)]
|
||||||
|
public long FieldGroupDefaultId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "GroupObjid", ColumnDescription = "")]
|
||||||
|
public long GroupObjid { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "ColumnId", ColumnDescription = "")]
|
||||||
|
public long ColumnId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "DefaultValue", ColumnDescription = "", Length = -1)]
|
||||||
|
public string DefaultValue { get; set; }
|
||||||
|
|
||||||
|
}
|
@ -813,5 +813,7 @@ public class Obj109
|
|||||||
[SugarColumn(ColumnName = "fld005040", ColumnDescription = "", Length = -1)]
|
[SugarColumn(ColumnName = "fld005040", ColumnDescription = "", Length = -1)]
|
||||||
public string? fld005040 { get; set; }
|
public string? fld005040 { get; set; }
|
||||||
public string fld005281 { get; set; }
|
public string fld005281 { get; set; }
|
||||||
|
public string fld005299 { get; set; }
|
||||||
|
public string fld005300 { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,369 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using Admin.NET.Core;
|
||||||
|
using SqlSugar;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
namespace Vistar.Application.Entity;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarTable("ObjectFieldsGroups","")]
|
||||||
|
[Tenant("启威星 1.94.4.74")]
|
||||||
|
public class ObjectFieldsGroups
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "GroupName", ColumnDescription = "", Length = 200)]
|
||||||
|
public string? GroupName { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "GroupObjId", IsIdentity = true, ColumnDescription = "", IsPrimaryKey = true)]
|
||||||
|
public long GroupObjId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "ObjectId", ColumnDescription = "")]
|
||||||
|
public long ObjectId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "isTab", ColumnDescription = "")]
|
||||||
|
public bool isTab { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "ParentId", ColumnDescription = "")]
|
||||||
|
public long ParentId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "OrderIndex", ColumnDescription = "")]
|
||||||
|
public long OrderIndex { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "GroupType", ColumnDescription = "")]
|
||||||
|
public bool? GroupType { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "NBSVersionId", ColumnDescription = "")]
|
||||||
|
public long? NBSVersionId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "NBSPartVersionId", ColumnDescription = "")]
|
||||||
|
public long? NBSPartVersionId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "NBSDRWVersionId", ColumnDescription = "")]
|
||||||
|
public long? NBSDRWVersionId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "NBSASSVersionId", ColumnDescription = "")]
|
||||||
|
public long? NBSASSVersionId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "IsVisibilityNormal", ColumnDescription = "")]
|
||||||
|
public bool? IsVisibilityNormal { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "ForceRevisionChange", ColumnDescription = "")]
|
||||||
|
public bool ForceRevisionChange { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "ForceRelatedFile", ColumnDescription = "")]
|
||||||
|
public bool ForceRelatedFile { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedFieldId", ColumnDescription = "")]
|
||||||
|
public long? LinkedFieldId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedDelimiter", ColumnDescription = "", Length = 10)]
|
||||||
|
public string? LinkedDelimiter { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedEnabled", ColumnDescription = "")]
|
||||||
|
public bool? LinkedEnabled { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedBefore", ColumnDescription = "")]
|
||||||
|
public bool? LinkedBefore { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedCharLimit", ColumnDescription = "")]
|
||||||
|
public int? LinkedCharLimit { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "LinkedResetCounter", ColumnDescription = "")]
|
||||||
|
public bool? LinkedResetCounter { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "ConfigToShowId", ColumnDescription = "")]
|
||||||
|
public long? ConfigToShowId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "isFieldGroupOptionDefault", ColumnDescription = "")]
|
||||||
|
public bool? isFieldGroupOptionDefault { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "UseDashboardReference", ColumnDescription = "")]
|
||||||
|
public bool? UseDashboardReference { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "OrderIndexDashBoard", ColumnDescription = "")]
|
||||||
|
public long? OrderIndexDashBoard { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "DashboardImage", ColumnDescription = "")]
|
||||||
|
public bool? DashboardImage { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWcheckInNoteRequired", ColumnDescription = "")]
|
||||||
|
public bool? SWcheckInNoteRequired { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWcheckOutNoteRequired", ColumnDescription = "")]
|
||||||
|
public bool? SWcheckOutNoteRequired { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "ContainsAllSpecialGroups", ColumnDescription = "")]
|
||||||
|
public bool? ContainsAllSpecialGroups { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "EPDMCardId", ColumnDescription = "")]
|
||||||
|
public long? EPDMCardId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "ContainsAllSubFolders", ColumnDescription = "")]
|
||||||
|
public bool? ContainsAllSubFolders { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWPDMCardId", ColumnDescription = "")]
|
||||||
|
public long? SWPDMCardId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWPDMNBSVariableId", ColumnDescription = "")]
|
||||||
|
public long? SWPDMNBSVariableId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWPDMDescriptionVariableId", ColumnDescription = "")]
|
||||||
|
public long? SWPDMDescriptionVariableId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "SWPDMRevisionVariableId", ColumnDescription = "")]
|
||||||
|
public long? SWPDMRevisionVariableId { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "isDefault", ColumnDescription = "")]
|
||||||
|
public bool? isDefault { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "allowedFileExtensions", ColumnDescription = "", Length = -1)]
|
||||||
|
public string? allowedFileExtensions { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
[SugarColumn(ColumnName = "NewFromSameAutoNumber", ColumnDescription = "")]
|
||||||
|
public bool NewFromSameAutoNumber { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "ObjectNotesText", ColumnDescription = "", Length = 2147483647)]
|
||||||
|
public string? ObjectNotesText { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "DashboardDisplayName", ColumnDescription = "", Length = 100)]
|
||||||
|
public string? DashboardDisplayName { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_EN", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_EN { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_CS", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_CS { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_DE", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_DE { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_ES", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_ES { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_FR", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_FR { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_IT", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_IT { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_JA", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_JA { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_KO", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_KO { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_PL", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_PL { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_PTBR", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_PTBR { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_RU", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_RU { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_TR", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_TR { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_ZHCN", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_ZHCN { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_ZHTW", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_ZHTW { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "EnableCustomTable", ColumnDescription = "")]
|
||||||
|
public bool? EnableCustomTable { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "AltDisplay_SQ", ColumnDescription = "", Length = 300)]
|
||||||
|
public string? AltDisplay_SQ { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "Collapse", ColumnDescription = "")]
|
||||||
|
public bool? Collapse { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
[SugarColumn(ColumnName = "VisibleInSpObjectsTree", ColumnDescription = "")]
|
||||||
|
public bool? VisibleInSpObjectsTree { get; set; }
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,92 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Vistar.Application.Service.OaOpenInterface.Dto;
|
||||||
|
public class OaCreateProjectInput
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 对象id
|
||||||
|
/// </summary>
|
||||||
|
public int object_id { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 字段组
|
||||||
|
/// </summary>
|
||||||
|
public string field_group { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 设备名称(OA产品名称)
|
||||||
|
/// </summary>
|
||||||
|
public string fld004684 { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 项目编号
|
||||||
|
/// </summary>
|
||||||
|
public string _System_objNBS { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 项目名称
|
||||||
|
/// </summary>
|
||||||
|
public string _System_objDescription { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 项目负责人
|
||||||
|
/// </summary>
|
||||||
|
public string fld004728 { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 开始日期
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? fld004503 { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 结束日期(预计完成日期)
|
||||||
|
/// </summary>
|
||||||
|
public DateTime? fld004504 { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 项目地点
|
||||||
|
/// </summary>
|
||||||
|
public string? fld005299 { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 备注
|
||||||
|
/// </summary>
|
||||||
|
public string? fld005300 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 单位
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld005281 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 行业领域
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004521 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 物料类型
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004519 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 工厂
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004522 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 采购类型
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004928 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 是否BOM内物料
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004935 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 物料同步标识
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004510 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// BOM同步标识
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004514 { get; set; }
|
||||||
|
///// <summary>
|
||||||
|
///// 工艺同步标识
|
||||||
|
///// </summary>
|
||||||
|
//public string? fld004517 { get; set; }
|
||||||
|
}
|
@ -0,0 +1,152 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using Admin.NET.Core;
|
||||||
|
using DocumentFormat.OpenXml.Drawing.Charts;
|
||||||
|
using Furion.DependencyInjection;
|
||||||
|
using Furion.DynamicApiController;
|
||||||
|
using Microsoft.AspNetCore.Authentication.JwtBearer;
|
||||||
|
using Microsoft.AspNetCore.Authorization;
|
||||||
|
using Microsoft.AspNetCore.Mvc;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Vistar.Application.Const;
|
||||||
|
using Vistar.Application.Entity;
|
||||||
|
using Vistar.Application.Service.OaOpenInterface.Dto;
|
||||||
|
using Vistar.Application.SolidWorksManageService.Dto;
|
||||||
|
|
||||||
|
namespace Vistar.Application.Service.OaOpenInterface;
|
||||||
|
/// <summary>
|
||||||
|
/// 开放接口给OA
|
||||||
|
/// </summary>
|
||||||
|
[ApiDescriptionSettings(ApplicationConst.GroupName, Name = "OaOpenInterfaceService", Order = 100)]
|
||||||
|
public class OaOpenInterfaceService : IDynamicApiController, ITransient
|
||||||
|
{
|
||||||
|
public SqlSugarRepository<Obj109> _obj109Rep;
|
||||||
|
public SolidWorksManageService.SolidWorksManageService _solidWorksManageService;
|
||||||
|
public SqlSugarRepository<ObjectFieldsGroups> _objectFieldsGroupsRep;
|
||||||
|
public SqlSugarRepository<FieldGroupDefault> _fieldGroupDefaultRep;
|
||||||
|
|
||||||
|
public OaOpenInterfaceService(
|
||||||
|
SqlSugarRepository<Obj109> obj109Rep,
|
||||||
|
SolidWorksManageService.SolidWorksManageService solidWorksManageService,
|
||||||
|
SqlSugarRepository<ObjectFieldsGroups> objectFieldsGroupsRep,
|
||||||
|
SqlSugarRepository<FieldGroupDefault> fieldGroupDefaultRep)
|
||||||
|
{
|
||||||
|
_obj109Rep = obj109Rep;
|
||||||
|
_solidWorksManageService = solidWorksManageService;
|
||||||
|
_objectFieldsGroupsRep = objectFieldsGroupsRep;
|
||||||
|
_fieldGroupDefaultRep = fieldGroupDefaultRep;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// OA创建、修改项目
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="input"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
[Authorize(AuthenticationSchemes = JwtBearerDefaults.AuthenticationScheme + "," + SignatureAuthenticationDefaults.AuthenticationScheme)]
|
||||||
|
[ApiDescriptionSettings(Name = "OaCreateProject"), HttpPost]
|
||||||
|
[DisplayName("OA创建、修改项目")]
|
||||||
|
public async Task<ManageResponse> OaCreateProject(OaCreateProjectInput input)
|
||||||
|
{
|
||||||
|
var response = new ManageResponse();
|
||||||
|
|
||||||
|
if (string.IsNullOrWhiteSpace(input._System_objNBS) || string.IsNullOrWhiteSpace(input._System_objDescription))
|
||||||
|
{
|
||||||
|
response.Success = true;
|
||||||
|
response.Message = "请输入必填字段";
|
||||||
|
return response;
|
||||||
|
}
|
||||||
|
if (input._System_objDescription.Length > 40)
|
||||||
|
{
|
||||||
|
response.Success = true;
|
||||||
|
response.Message = "项目名称不能超过40字符";
|
||||||
|
return response;
|
||||||
|
}
|
||||||
|
//判断是否存在项目记录
|
||||||
|
var clientExists = await _obj109Rep.AsQueryable().AnyAsync(x => x._System_objNBS == input._System_objNBS && x.deleted == false);
|
||||||
|
|
||||||
|
if (clientExists == false)
|
||||||
|
{
|
||||||
|
var fieldList = new List<Field>();
|
||||||
|
if (input.fld004503 != null)
|
||||||
|
{
|
||||||
|
fieldList.Add(new Field { key = "fld004503", value = input.fld004503.ToString() });
|
||||||
|
}
|
||||||
|
if (input.fld004503 != null)
|
||||||
|
{
|
||||||
|
fieldList.Add(new Field { key = "fld004504", value = input.fld004504.ToString() });
|
||||||
|
}
|
||||||
|
|
||||||
|
fieldList.Add(new Field { key = "fld004684", value = input.fld004684 });
|
||||||
|
fieldList.Add(new Field { key = "_System_objNBS", value = input._System_objNBS });
|
||||||
|
fieldList.Add(new Field { key = "_System_objDescription", value = input._System_objDescription });
|
||||||
|
fieldList.Add(new Field { key = "fld004728", value = input.fld004728 });
|
||||||
|
fieldList.Add(new Field { key = "fld005299", value = input.fld005299 });
|
||||||
|
fieldList.Add(new Field { key = "fld005300", value = input.fld005300 });
|
||||||
|
fieldList.Add(new Field { key = "fld005281", value = "SET" });
|
||||||
|
fieldList.Add(new Field { key = "fld004521", value = "M" });
|
||||||
|
fieldList.Add(new Field { key = "fld004519", value = "FERT" });
|
||||||
|
fieldList.Add(new Field { key = "fld004522", value = "1000" });
|
||||||
|
fieldList.Add(new Field { key = "fld004928", value = "E" });
|
||||||
|
fieldList.Add(new Field { key = "fld004935", value = "X" });
|
||||||
|
fieldList.Add(new Field { key = "fld004510", value = "A" });
|
||||||
|
fieldList.Add(new Field { key = "fld004514", value = "A" });
|
||||||
|
fieldList.Add(new Field { key = "fld004517", value = "A" });
|
||||||
|
|
||||||
|
var fieldGroupValue = await _fieldGroupDefaultRep.AsQueryable().Where(x => x.GroupObjid == input.object_id).ToListAsync();
|
||||||
|
|
||||||
|
for (int i = 0; i < fieldGroupValue.Count; i++)
|
||||||
|
{
|
||||||
|
fieldList.Add(new Field { key = "fld00" + fieldGroupValue[i].ColumnId, value = fieldGroupValue[i].DefaultValue });
|
||||||
|
}
|
||||||
|
|
||||||
|
var fieldGroup = await _objectFieldsGroupsRep.AsQueryable().Where(x => x.GroupName == input.field_group).FirstAsync();
|
||||||
|
|
||||||
|
var data = new CreateProjectInput
|
||||||
|
{
|
||||||
|
object_id = input.object_id,
|
||||||
|
field_group_id = fieldGroup.GroupObjId,
|
||||||
|
fields = fieldList
|
||||||
|
};
|
||||||
|
response = await _solidWorksManageService.CreateProject(data);
|
||||||
|
var projectData = await _obj109Rep.AsQueryable().Where(x=>x._System_objNBS==input._System_objNBS).FirstAsync();
|
||||||
|
|
||||||
|
var CheckData = new CheckDataInput() {
|
||||||
|
object_id=input.object_id,
|
||||||
|
record_guid=projectData.RecordGuid,
|
||||||
|
bom_level=1
|
||||||
|
};
|
||||||
|
await _solidWorksManageService.CheckOut(CheckData);
|
||||||
|
await _solidWorksManageService.CheckIn(CheckData);
|
||||||
|
}
|
||||||
|
else if (clientExists == true)
|
||||||
|
{
|
||||||
|
var updateable = await _obj109Rep.AsUpdateable()
|
||||||
|
.SetColumns(it => new Obj109
|
||||||
|
{
|
||||||
|
fld004684 = input.fld004684,
|
||||||
|
_System_ObjDescription = input._System_objDescription,
|
||||||
|
fld004728 = input.fld004728,
|
||||||
|
fld005299 = input.fld005299,
|
||||||
|
fld005300 = input.fld005300,
|
||||||
|
fld004503 = input.fld004503,
|
||||||
|
fld004504 = input.fld004504
|
||||||
|
|
||||||
|
})
|
||||||
|
.Where(x => x._System_objNBS == input._System_objNBS && x.deleted == false)
|
||||||
|
.ExecuteCommandHasChangeAsync();
|
||||||
|
response.Success = true;
|
||||||
|
response.Message = updateable ? "修改成功" : "修改失败";
|
||||||
|
}
|
||||||
|
return response;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -79,7 +79,7 @@ public class SapOpenInterfaceService : IDynamicApiController, ITransient
|
|||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
//判断是否存在客户记录
|
//判断是否存在客户记录
|
||||||
var clientExists = await _obj132Rep.AsQueryable().AnyAsync(x => x._System_objNBS == input._System_objNBS);
|
var clientExists = await _obj132Rep.AsQueryable().AnyAsync(x => x._System_objNBS == input._System_objNBS && x.deleted == false);
|
||||||
|
|
||||||
if (clientExists == false)
|
if (clientExists == false)
|
||||||
{
|
{
|
||||||
@ -104,7 +104,7 @@ public class SapOpenInterfaceService : IDynamicApiController, ITransient
|
|||||||
field_group_id = 422,
|
field_group_id = 422,
|
||||||
fields = fieldList
|
fields = fieldList
|
||||||
};
|
};
|
||||||
response= await _solidWorksManageService.CreateRecord(data);
|
response = await _solidWorksManageService.CreateRecord(data);
|
||||||
return response;
|
return response;
|
||||||
}
|
}
|
||||||
else if (clientExists == true)
|
else if (clientExists == true)
|
||||||
@ -116,7 +116,7 @@ public class SapOpenInterfaceService : IDynamicApiController, ITransient
|
|||||||
fld004808 = input.fld004808,
|
fld004808 = input.fld004808,
|
||||||
fld004950 = input.fld004950
|
fld004950 = input.fld004950
|
||||||
})
|
})
|
||||||
.Where(x => x._System_objNBS == input._System_objNBS)
|
.Where(x => x._System_objNBS == input._System_objNBS && x.deleted == false)
|
||||||
.ExecuteCommandHasChangeAsync();
|
.ExecuteCommandHasChangeAsync();
|
||||||
|
|
||||||
response.Success = true;
|
response.Success = true;
|
||||||
|
@ -0,0 +1,31 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Vistar.Application.SolidWorksManageService.Dto;
|
||||||
|
/// <summary>
|
||||||
|
/// 检入检出输入参数
|
||||||
|
/// </summary>
|
||||||
|
public class CheckDataInput
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 对象id
|
||||||
|
/// </summary>
|
||||||
|
public long object_id { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// 记录RecordGuid
|
||||||
|
/// </summary>
|
||||||
|
public string record_guid { get; set; }
|
||||||
|
/// <summary>
|
||||||
|
/// BOM层次
|
||||||
|
/// </summary>
|
||||||
|
public int bom_level { get; set; }
|
||||||
|
}
|
@ -0,0 +1,28 @@
|
|||||||
|
// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
|
||||||
|
//
|
||||||
|
// 本项目主要遵循 MIT 许可证和 Apache 许可证(版本 2.0)进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
|
||||||
|
//
|
||||||
|
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动!任何基于本项目二次开发而产生的一切法律纠纷和责任,我们不承担任何责任!
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Vistar.Application.SolidWorksManageService.Dto;
|
||||||
|
/// <summary>
|
||||||
|
/// 创建项目输入参数
|
||||||
|
/// </summary>
|
||||||
|
public class CreateProjectInput
|
||||||
|
{
|
||||||
|
public long object_id { get; set; }
|
||||||
|
public long field_group_id { get; set; }
|
||||||
|
public List<Field> fields { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class CreateProjectField
|
||||||
|
{
|
||||||
|
public string key { get; set; }
|
||||||
|
public string value { get; set; }
|
||||||
|
}
|
@ -11,6 +11,9 @@ using System.Text;
|
|||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace Vistar.Application.SolidWorksManageService.Dto;
|
namespace Vistar.Application.SolidWorksManageService.Dto;
|
||||||
|
/// <summary>
|
||||||
|
/// 创建记录输入参数
|
||||||
|
/// </summary>
|
||||||
public class CreateRecordInput
|
public class CreateRecordInput
|
||||||
{
|
{
|
||||||
public long object_id { get; set; }
|
public long object_id { get; set; }
|
||||||
|
@ -119,4 +119,140 @@ public class SolidWorksManageService : IDynamicApiController, ITransient
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 创建项目
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="input"></param>
|
||||||
|
/// <returns></returns>Create Project(创建项目)
|
||||||
|
public async Task<ManageResponse> CreateProject(CreateProjectInput input)
|
||||||
|
{
|
||||||
|
// 获取 SolidWorksManage 地址
|
||||||
|
string apiUrl = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageApiUrl);
|
||||||
|
// 拼接接口地址
|
||||||
|
string url = $"{apiUrl}/api/PropertyCard/CreateProject";
|
||||||
|
//获取token
|
||||||
|
var token = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageAuthorization);
|
||||||
|
// 将参数对象序列化为 JSON 字符串
|
||||||
|
string jsonParameters = JsonConvert.SerializeObject(input);
|
||||||
|
// 设置请求内容
|
||||||
|
var content = new StringContent(jsonParameters, Encoding.UTF8, "application/json");
|
||||||
|
client.DefaultRequestHeaders.Remove("Authorization");
|
||||||
|
// 添加 Authorization 到请求头
|
||||||
|
client.DefaultRequestHeaders.Add("Authorization", token);
|
||||||
|
// 发送 POST 请求
|
||||||
|
HttpResponseMessage response = await client.PostAsync(url, content);
|
||||||
|
// 处理响应
|
||||||
|
if (response.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
// 解析 JSON 数据
|
||||||
|
var result = JsonConvert.DeserializeObject<ManageResponse>(responseBody);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
|
||||||
|
var errorResponse = new ManageResponse()
|
||||||
|
{
|
||||||
|
Success = false,
|
||||||
|
Message = responseBody,
|
||||||
|
Data = "",
|
||||||
|
CustomAction = "",
|
||||||
|
CustomAttributes = ""
|
||||||
|
};
|
||||||
|
return errorResponse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 检出
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="input"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public async Task<ManageResponse> CheckOut(CheckDataInput input)
|
||||||
|
{
|
||||||
|
// 获取 SolidWorksManage 地址
|
||||||
|
string apiUrl = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageApiUrl);
|
||||||
|
// 拼接接口地址
|
||||||
|
string url = $"{apiUrl}/api/PropertyCard/CheckOut";
|
||||||
|
//获取token
|
||||||
|
var token = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageAuthorization);
|
||||||
|
// 将参数对象序列化为 JSON 字符串
|
||||||
|
string jsonParameters = JsonConvert.SerializeObject(input);
|
||||||
|
// 设置请求内容
|
||||||
|
var content = new StringContent(jsonParameters, Encoding.UTF8, "application/json");
|
||||||
|
client.DefaultRequestHeaders.Remove("Authorization");
|
||||||
|
// 添加 Authorization 到请求头
|
||||||
|
client.DefaultRequestHeaders.Add("Authorization", token);
|
||||||
|
// 发送 POST 请求
|
||||||
|
HttpResponseMessage response = await client.PostAsync(url, content);
|
||||||
|
// 处理响应
|
||||||
|
if (response.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
// 解析 JSON 数据
|
||||||
|
var result = JsonConvert.DeserializeObject<ManageResponse>(responseBody);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
|
||||||
|
var errorResponse = new ManageResponse()
|
||||||
|
{
|
||||||
|
Success = false,
|
||||||
|
Message = responseBody,
|
||||||
|
Data = "",
|
||||||
|
CustomAction = "",
|
||||||
|
CustomAttributes = ""
|
||||||
|
};
|
||||||
|
return errorResponse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// 检入
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="input"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public async Task<ManageResponse> CheckIn(CheckDataInput input)
|
||||||
|
{
|
||||||
|
// 获取 SolidWorksManage 地址
|
||||||
|
string apiUrl = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageApiUrl);
|
||||||
|
// 拼接接口地址
|
||||||
|
string url = $"{apiUrl}/api/PropertyCard/CheckIn";
|
||||||
|
//获取token
|
||||||
|
var token = await _sysConfigService.GetConfigValueByCode<string>(ConfigConst.SolidWorksManageAuthorization);
|
||||||
|
// 将参数对象序列化为 JSON 字符串
|
||||||
|
string jsonParameters = JsonConvert.SerializeObject(input);
|
||||||
|
// 设置请求内容
|
||||||
|
var content = new StringContent(jsonParameters, Encoding.UTF8, "application/json");
|
||||||
|
client.DefaultRequestHeaders.Remove("Authorization");
|
||||||
|
// 添加 Authorization 到请求头
|
||||||
|
client.DefaultRequestHeaders.Add("Authorization", token);
|
||||||
|
// 发送 POST 请求
|
||||||
|
HttpResponseMessage response = await client.PostAsync(url, content);
|
||||||
|
// 处理响应
|
||||||
|
if (response.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
// 解析 JSON 数据
|
||||||
|
var result = JsonConvert.DeserializeObject<ManageResponse>(responseBody);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
string responseBody = await response.Content.ReadAsStringAsync();
|
||||||
|
|
||||||
|
var errorResponse = new ManageResponse()
|
||||||
|
{
|
||||||
|
Success = false,
|
||||||
|
Message = responseBody,
|
||||||
|
Data = "",
|
||||||
|
CustomAction = "",
|
||||||
|
CustomAttributes = ""
|
||||||
|
};
|
||||||
|
return errorResponse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user