11
This commit is contained in:
parent
995a8f115a
commit
97d3da3116
@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MyCode.Project.Domain.Message.Request.KingDee
|
||||
{
|
||||
public class BillDelete
|
||||
{ /// <summary>
|
||||
/// 单据内码
|
||||
/// </summary>
|
||||
public string Ids { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 组织ID
|
||||
/// </summary>
|
||||
public long CreateOrgId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 单据编码
|
||||
/// </summary>
|
||||
public string Numbers { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否启用网控
|
||||
/// </summary>
|
||||
public bool NetworkCtrl { get; set; }
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MyCode.Project.Domain.Message.Request.KingDee
|
||||
{
|
||||
public class BillSave
|
||||
{
|
||||
/// <summary>
|
||||
/// 更新字段
|
||||
/// </summary>
|
||||
public List<string> NeedUpDateFields { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 返回字段
|
||||
/// </summary>
|
||||
public List<string> NeedReturnFields { get; set; }
|
||||
|
||||
public bool IsDeleteEntry { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 表单数据包,JSON类型(必录)
|
||||
/// </summary>
|
||||
public object Model { get; set; }
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,133 @@
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MyCode.Project.Domain.Message.Response.JackYun
|
||||
{
|
||||
public class PushOrderListResp
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Desc:店铺编码
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "shopCode")]
|
||||
public string ShopCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "shopName")]
|
||||
public string ShopName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "warehouseName")]
|
||||
public string WarehouseName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "warehouseCode")]
|
||||
public string WarehouseCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "warehouseId")]
|
||||
public string WarehouseId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:店铺id
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "shopId")]
|
||||
public long? ShopId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:0=未处理 1=已合并 2=已推送
|
||||
/// Default:0
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "status")]
|
||||
public int? Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:发货时间
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "consignTime")]
|
||||
public string ConsignTime { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "goodsId")]
|
||||
public string GoodsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:销售总金额(数量×单价)
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "sellTotal")]
|
||||
public decimal SellTotal { get; set; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Desc:数量
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "sellCount")]
|
||||
public int SellCount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:实付金额
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "divideSellTotal")]
|
||||
public decimal DivideSellTotal { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:条码,用这个匹配金蝶物料编码
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "barcode")]
|
||||
public string Barcode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:订单类型 销售单类型(1:零售业务;2:代发货(来自分销商);3:预售订单;4:周期性订购;5:代销售(供货商发货);6:现款现货;7:售后发货;8:售后退货;9:批发业务(B2B);10:试销业务;11:错漏调整;12:仅退款;13:销售返利;14:大B2B业务;15物流买赔;16销售对账差异 91:自定义1;92:自定义2;93:自定义3...100:自定义10)
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public int? TradeType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "goodsNo")]
|
||||
public string GoodsNo { get; set; }
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,98 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace MyCode.Project.Domain.Message.Response.KingDee
|
||||
{
|
||||
public class ErrorResponse
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public Result Result { get; set; }
|
||||
}
|
||||
|
||||
|
||||
public class ErrorsItem
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string FieldName { get; set; }
|
||||
/// <summary>
|
||||
/// 报错内容
|
||||
/// </summary>
|
||||
public string Message { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int DIndex { get; set; }
|
||||
}
|
||||
|
||||
public class ResponseStatus
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int ErrorCode { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string IsSuccess { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<ErrorsItem> Errors { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<string> SuccessEntitys { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<string> SuccessMessages { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int MsgCode { get; set; }
|
||||
}
|
||||
|
||||
public class ConvertResponseStatus
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public string IsSuccess { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<string> Errors { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<string> SuccessEntitys { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public List<string> SuccessMessages { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int MsgCode { get; set; }
|
||||
}
|
||||
|
||||
public class Result
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public ResponseStatus ResponseStatus { get; set; }
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public ConvertResponseStatus ConvertResponseStatus { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
114
Reportapi/MyCode.Project.Domain/Model/PushKingDeeOrder.cs
Normal file
114
Reportapi/MyCode.Project.Domain/Model/PushKingDeeOrder.cs
Normal file
@ -0,0 +1,114 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using SqlSugar;
|
||||
|
||||
namespace MyCode.Project.Domain.Model
|
||||
{
|
||||
///<summary>
|
||||
///
|
||||
///</summary>
|
||||
[SugarTable("PushKingDeeOrder")]
|
||||
public partial class PushKingDeeOrder
|
||||
{
|
||||
public PushKingDeeOrder(){
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey=true,ColumnName="id")]
|
||||
public Guid Id {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:店铺编码
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="shopCode")]
|
||||
public string ShopCode {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="shopName")]
|
||||
public string ShopName {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:店铺id
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="shopId")]
|
||||
public long? ShopId {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="warehouseName")]
|
||||
public string WarehouseName {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="warehouseCode")]
|
||||
public string WarehouseCode {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:DateTime.Now
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="createTime")]
|
||||
public DateTime? CreateTime {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:DateTime.Now
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="updateTime")]
|
||||
public DateTime? UpdateTime {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:0=未处理 1=已合并 2=已推送
|
||||
/// Default:0
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="status")]
|
||||
public int? Status {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:发货时间
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="consignTime")]
|
||||
public DateTime? ConsignTime {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="warehouseId")]
|
||||
public string WarehouseId {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:订单类型 销售单类型(1:零售业务;2:代发货(来自分销商);3:预售订单;4:周期性订购;5:代销售(供货商发货);6:现款现货;7:售后发货;8:售后退货;9:批发业务(B2B);10:试销业务;11:错漏调整;12:仅退款;13:销售返利;14:大B2B业务;15物流买赔;16销售对账差异 91:自定义1;92:自定义2;93:自定义3...100:自定义10)
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public int? TradeType {get;set;}
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,82 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using SqlSugar;
|
||||
|
||||
namespace MyCode.Project.Domain.Model
|
||||
{
|
||||
///<summary>
|
||||
///
|
||||
///</summary>
|
||||
[SugarTable("PushKingDeeOrderItem")]
|
||||
public partial class PushKingDeeOrderItem
|
||||
{
|
||||
public PushKingDeeOrderItem(){
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:newid()
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey=true)]
|
||||
public Guid Id {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="goodsNo")]
|
||||
public string GoodsNo {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="goodsId")]
|
||||
public string GoodsId {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:销售总金额(数量×单价)
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="sellTotal")]
|
||||
public decimal SellTotal {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:数量
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="sellCount")]
|
||||
public int SellCount {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:实付金额
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="divideSellTotal")]
|
||||
public decimal DivideSellTotal {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:条码,用这个匹配金蝶物料编码
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="barcode")]
|
||||
public string Barcode {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public Guid? PushKingDeeOrderId {get;set;}
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,147 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using SqlSugar;
|
||||
|
||||
namespace MyCode.Project.Domain.Model
|
||||
{
|
||||
///<summary>
|
||||
///
|
||||
///</summary>
|
||||
[SugarTable("WMStoJackyun_InventoryMovement_View1")]
|
||||
public partial class WMStoJackyunInventoryMovementView1
|
||||
{
|
||||
public WMStoJackyunInventoryMovementView1(){
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)]
|
||||
public int Id {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string WMS单号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public long? 单据行号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据类型 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据类型名称 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 变动方向 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string ITEMID {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string SKU {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string BARCODE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 尺码 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单位 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 商品名称 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public int? 数量 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 仓库 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public DateTime? 过账日期 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 备注 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:0=未处理 1=已合并 2=已推送
|
||||
/// Default:0
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="status")]
|
||||
public int? Status {get;set;}
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,154 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using SqlSugar;
|
||||
|
||||
namespace MyCode.Project.Domain.Model
|
||||
{
|
||||
///<summary>
|
||||
///
|
||||
///</summary>
|
||||
[SugarTable("WMStoJackyun_InventoryMovement_View3")]
|
||||
public partial class WMStoJackyunInventoryMovementView3
|
||||
{
|
||||
public WMStoJackyunInventoryMovementView3(){
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey=true,IsIdentity=true)]
|
||||
public int Id {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string WMS单号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public int? 单据行号 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据类型 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单据类型名称 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 变动方向 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string ITEMID {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string SKU {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string BARCODE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 尺码 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 单位 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 商品名称 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 数量 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public double? 数量2 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 仓库 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 过账日期 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
public string 备注 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:0=未处理 1=已合并 2=已推送
|
||||
/// Default:0
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="status")]
|
||||
public int? Status {get;set;}
|
||||
|
||||
}
|
||||
}
|
||||
@ -31,14 +31,14 @@ namespace MyCode.Project.Domain.Model
|
||||
public string FBILLNO {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:审核状态 C=已审核
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
public string FDOCUMENTSTATUS {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:门店编码
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
@ -46,7 +46,7 @@ namespace MyCode.Project.Domain.Model
|
||||
public string FSHOPCODE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:门店名称
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
@ -56,55 +56,55 @@ namespace MyCode.Project.Domain.Model
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_YTKJ_TEXT2")]
|
||||
public string FYTKJTEXT2 {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:是否同步金蝶
|
||||
/// Default:1
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_SYNCHRONIZEKINGDEE")]
|
||||
public string FSYNCHRONIZEKINGDEE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:是否同步WM
|
||||
/// Default:1
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_SYNCHRONIZEWMS")]
|
||||
public string FSYNCHRONIZEWMS {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:销售客户
|
||||
/// Default:0
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_SALESCUSTOMERS")]
|
||||
public int FSALESCUSTOMERS {get;set;}
|
||||
public int? FSALESCUSTOMERS {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:发货仓库
|
||||
/// Default:0
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_WAREHOUSE")]
|
||||
public int FWAREHOUSE {get;set;}
|
||||
public int? FWAREHOUSE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:仓库货主
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_CANGKUHUOZHU")]
|
||||
public string FCANGKUHUOZHU {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:公司ID
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_COMPANYID")]
|
||||
public string FCOMPANYID {get;set;}
|
||||
@ -112,18 +112,66 @@ namespace MyCode.Project.Domain.Model
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
/// Nullable:False
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_DACANG")]
|
||||
public string FDACANG {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Desc:税率
|
||||
/// Default:0
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_TAXRATE")]
|
||||
public decimal? FTAXRATE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:创建日期
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_YTKJ_CREATEDATE")]
|
||||
public DateTime? FYTKJCREATEDATE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:修改日期
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_YTKJ_MODIFYDATE")]
|
||||
public DateTime? FYTKJMODIFYDATE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:审核日期
|
||||
/// Default:
|
||||
/// Nullable:True
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_AUDITDATE")]
|
||||
public DateTime? FAUDITDATE {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:创建人
|
||||
/// Default:0
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_TAXRATE")]
|
||||
public decimal FTAXRATE {get;set;}
|
||||
[SugarColumn(ColumnName="F_YTKJ_CREATORID")]
|
||||
public int FYTKJCREATORID {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:修改人
|
||||
/// Default:0
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_YTKJ_MODIFIERID")]
|
||||
public int FYTKJMODIFIERID {get;set;}
|
||||
|
||||
/// <summary>
|
||||
/// Desc:审核人
|
||||
/// Default:0
|
||||
/// Nullable:False
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName="F_AUDITOR")]
|
||||
public int FAUDITOR {get;set;}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -63,28 +63,36 @@
|
||||
<Compile Include="Message\Act\Common\ExcelData.cs" />
|
||||
<Compile Include="Message\Act\Common\RequestModel.cs" />
|
||||
<Compile Include="Message\Request\JackYun\OrderTradeFullInfoGetRequestBizData.cs" />
|
||||
<Compile Include="Message\Request\KingDee\BillDelete.cs" />
|
||||
<Compile Include="Message\Request\KingDee\BillSave.cs" />
|
||||
<Compile Include="Message\Request\KingDee\FSaleOrderEntry.cs" />
|
||||
<Compile Include="Message\Request\TimeRange.cs" />
|
||||
<Compile Include="Message\Response\Common\HeadFieldItem.cs" />
|
||||
<Compile Include="Message\Response\Common\IdName.cs" />
|
||||
<Compile Include="Message\Response\Common\ItemResult.cs" />
|
||||
<Compile Include="Message\Response\Common\ListHeadFieldData.cs" />
|
||||
<Compile Include="Message\Response\JackYun\PushOrderListResp.cs" />
|
||||
<Compile Include="Message\Response\KingDee\ErrorResponse.cs" />
|
||||
<Compile Include="Message\Response\LxmZHMDReport\ReportCalRateResp.cs" />
|
||||
<Compile Include="Message\Response\Queue\QueueProcess.cs" />
|
||||
<Compile Include="Message\Response\User\AdminLoginInfo.cs" />
|
||||
<Compile Include="Message\Response\User\LoginInfo.cs" />
|
||||
<Compile Include="Message\Response\User\MemberLoginInfo.cs" />
|
||||
<Compile Include="Message\Response\WebSocket\ConnUser.cs" />
|
||||
<Compile Include="Message\Response\WebSocket\ConnUser`.cs" />
|
||||
<Compile Include="Message\Response\WorkProcess\WorkProcessResp.cs" />
|
||||
<Compile Include="Model\ApiLog.cs" />
|
||||
<Compile Include="Model\JackOrders.cs" />
|
||||
<Compile Include="Model\JackOrdersItem.cs" />
|
||||
<Compile Include="Model\PushKingDeeOrder.cs" />
|
||||
<Compile Include="Model\PushKingDeeOrderItem.cs" />
|
||||
<Compile Include="Model\SysWorkprocess.cs" />
|
||||
<Compile Include="Model\YTKJTShopParameter.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Repositories\IApiLogRepository.cs" />
|
||||
<Compile Include="Repositories\IJackOrdersItemRepository.cs" />
|
||||
<Compile Include="Repositories\IJackOrdersRepository.cs" />
|
||||
<Compile Include="Repositories\IPushKingDeeOrderItemRepository.cs" />
|
||||
<Compile Include="Repositories\IPushKingDeeOrderRepository.cs" />
|
||||
<Compile Include="Repositories\IRepository.cs" />
|
||||
<Compile Include="Repositories\IRepository`.cs" />
|
||||
<Compile Include="Repositories\ISysWorkprocessRepository.cs" />
|
||||
|
||||
@ -8,11 +8,17 @@ using MyCode.Project.Domain;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Domain.Message;
|
||||
using MyCode.Project.Domain.Message.Response.JackYun;
|
||||
|
||||
namespace MyCode.Project.Domain.Repositories
|
||||
{
|
||||
public interface IJackOrdersItemRepository : IRepository<JackOrdersItem>
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取合并后的吉客云订单
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
List<PushOrderListResp> GetPushOrder();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Infrastructure;
|
||||
using MyCode.Project.Domain;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Domain.Message;
|
||||
|
||||
namespace MyCode.Project.Domain.Repositories
|
||||
{
|
||||
public interface IPushKingDeeOrderItemRepository : IRepository<PushKingDeeOrderItem>
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Infrastructure;
|
||||
using MyCode.Project.Domain;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Domain.Message;
|
||||
|
||||
namespace MyCode.Project.Domain.Repositories
|
||||
{
|
||||
public interface IPushKingDeeOrderRepository : IRepository<PushKingDeeOrder>
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Infrastructure;
|
||||
using MyCode.Project.Domain;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Domain.Message;
|
||||
|
||||
namespace MyCode.Project.Domain.Repositories
|
||||
{
|
||||
public interface IWMStoJackyunInventoryMovementView1Repository : IRepository<WMStoJackyunInventoryMovementView1>
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Infrastructure;
|
||||
using MyCode.Project.Domain;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Domain.Message;
|
||||
|
||||
namespace MyCode.Project.Domain.Repositories
|
||||
{
|
||||
public interface IWMStoJackyunInventoryMovementView3Repository : IRepository<WMStoJackyunInventoryMovementView3>
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,166 @@
|
||||
using Kingdee.CDP.WebApi.SDK;
|
||||
using MyCode.Project.Domain.Message.Request.KingDee;
|
||||
using MyCode.Project.Domain.Message.Response.KingDee;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Configuration;
|
||||
using System.Linq;
|
||||
|
||||
namespace MyCode.Project.OutSideService.Implementation
|
||||
{
|
||||
public class KingDeeService //: IKingDeeService
|
||||
{
|
||||
public KingDeeService()
|
||||
{
|
||||
}
|
||||
public static K3CloudApi staClient = null;
|
||||
public static DateTime timeOut = DateTime.Now;
|
||||
|
||||
|
||||
#region
|
||||
/// <summary>
|
||||
/// 获取一个K3客户端
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public K3CloudApi GetK3CloudClient(string yuYan = "")
|
||||
{
|
||||
|
||||
/***
|
||||
* "Kingdee": {
|
||||
"Default": {
|
||||
//第三方系统登录授权的账套ID
|
||||
"AcctID": "65edc24ab975db",
|
||||
//第三方系统登录授权的应用ID
|
||||
"AppID": "302967_20fp7YsL2kpWR9VG5Y3LSbUHzv3/SDmv",
|
||||
//第三方系统登录授权的应用密钥
|
||||
"AppSec": "5e38f16711514126ae1511ca4ead3232",
|
||||
//第三方系统登录授权的用户
|
||||
"UserName": "ERP1",
|
||||
//账套语系,默认2052
|
||||
"LCID": 2052,
|
||||
//服务Url地址 (只有私有云用户需要配置Serverurl,公有云用户走网关不需要配置)
|
||||
"ServerUrl": "http://8.138.110.197/K3Cloud",
|
||||
// 时间
|
||||
"Timestamp": 30
|
||||
}
|
||||
}
|
||||
语言ID,中文2052(默认),英文1033,繁体3076;
|
||||
*
|
||||
*
|
||||
* */
|
||||
|
||||
if (staClient == null || DateTime.Now > timeOut || 1 == 1)
|
||||
{
|
||||
|
||||
string AppID = ConfigurationManager.AppSettings.Get("X-KDApi-AppID");
|
||||
string UserName = ConfigurationManager.AppSettings.Get("X-KDApi-UserName");
|
||||
string AcctID = ConfigurationManager.AppSettings.Get("X-KDApi-AcctID");
|
||||
string AppSec = ConfigurationManager.AppSettings.Get("X-KDApi-AppSec");
|
||||
string LCID = ConfigurationManager.AppSettings.Get("X-KDApi-LCID");
|
||||
if (yuYan != "")
|
||||
LCID = yuYan;
|
||||
string ServerUrl = ConfigurationManager.AppSettings.Get("X-KDApi-ServerUrl");
|
||||
//staClient = new K3CloudApi(ServerUrl);
|
||||
timeOut = DateTime.Now.AddMinutes(5);
|
||||
staClient = new K3CloudApi();
|
||||
staClient.InitClient(AcctID, AppID, AppSec, UserName, int.Parse(LCID), "100", ServerUrl);
|
||||
//staClient.InitClient("65edc24ab975db", "302967_20fp7YsL2kpWR9VG5Y3LSbUHzv3/SDmv", "5e38f16711514126ae1511ca4ead3232", "ERP1", 2052, "100", "http://8.138.110.197/k3cloud/");
|
||||
}
|
||||
return staClient;
|
||||
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#region 保存一个订单对象
|
||||
/// <summary>
|
||||
/// 保存一个订单对象
|
||||
/// </summary>
|
||||
/// <param name="formId"></param>
|
||||
/// <param name="billSave"></param>
|
||||
/// <returns></returns>
|
||||
public string Save(string formId, BillSave billSave)
|
||||
{
|
||||
staClient = GetK3CloudClient();
|
||||
var datastr = JsonHelper.ToJson(billSave);
|
||||
//LogHelper.Info(datastr);
|
||||
var resultString = staClient.Save(formId, datastr);
|
||||
if (resultString.Contains("ErrorCode"))
|
||||
{
|
||||
LogHelper.Error("金蝶云接口调用失败,请检查");
|
||||
LogHelper.Error(resultString);
|
||||
//throw new Exception("单据在云星空已锁定,请联系采购员");
|
||||
string Message = "";
|
||||
try
|
||||
{
|
||||
ErrorResponse errorResponse = JsonHelper.ToObject<ErrorResponse>(resultString);
|
||||
Message = string.Join(",", errorResponse.Result.ResponseStatus.Errors.Select(t => t.Message).ToList());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
string ds = ex.Message;
|
||||
throw new Exception("2云星空接口调用失败,请联系管理员,错误信息:" + resultString);
|
||||
|
||||
}
|
||||
throw new Exception("1云星空接口调用失败,请联系管理员,错误信息:" + Message);
|
||||
}
|
||||
var result = JsonHelper.ToObject<Dictionary<string, Dictionary<string, dynamic>>>(resultString);
|
||||
var data = result["Result"]["ResponseStatus"];
|
||||
return resultString;
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
|
||||
#region Delete(删除某个订单)
|
||||
/// <summary>
|
||||
/// 删除某个订单
|
||||
/// </summary>
|
||||
/// <param name="formId"></param>
|
||||
/// <param name="billdelete"></param>
|
||||
/// <returns></returns>
|
||||
/// <exception cref="Exception"></exception>
|
||||
|
||||
public dynamic Delete(string formId, BillDelete billdelete)
|
||||
{
|
||||
staClient = GetK3CloudClient();
|
||||
var datastr = JsonHelper.ToJson(billdelete);
|
||||
LogHelper.Info(datastr);
|
||||
var resultString = staClient.Delete(formId, datastr);
|
||||
if (resultString.Contains("ErrorCode"))
|
||||
{
|
||||
LogHelper.Error("金蝶云接口调用失败,请检查");
|
||||
LogHelper.Error(resultString);
|
||||
string Message = "";
|
||||
try
|
||||
{
|
||||
ErrorResponse errorResponse = JsonHelper.ToObject<ErrorResponse>(resultString);
|
||||
Message = string.Join(",", errorResponse.Result.ResponseStatus.Errors.Select(t => t.Message).ToList());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
string ds = ex.Message;
|
||||
throw new Exception("2云星空接口调用失败,请联系管理员,错误信息:" + resultString);
|
||||
|
||||
}
|
||||
throw new Exception("1云星空接口调用失败,请联系管理员,错误信息:" + Message);
|
||||
}
|
||||
var result = JsonHelper.ToObject<dynamic>(resultString);
|
||||
var data = result["Result"]["ResponseStatus"]["SuccessEntitys"];
|
||||
return JsonHelper.ToJson(data);
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
||||
@ -31,6 +31,9 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="Kingdee.CDP.WebApi.SDK">
|
||||
<HintPath>..\kingdeeDll\Kingdee.CDP.WebApi.SDK.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Microsoft.Practices.Unity, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\Lib\Microsoft.Practices.Unity.dll</HintPath>
|
||||
@ -108,6 +111,7 @@
|
||||
<ItemGroup>
|
||||
<Compile Include="IBfyService.cs" />
|
||||
<Compile Include="Implementation\BfyService.cs" />
|
||||
<Compile Include="Implementation\KingDeeService.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
||||
@ -9,6 +9,7 @@ using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.Search;
|
||||
using MyCode.Project.Domain.Message.Response.JackYun;
|
||||
|
||||
namespace MyCode.Project.Repositories
|
||||
{
|
||||
@ -18,8 +19,28 @@ namespace MyCode.Project.Repositories
|
||||
{ }
|
||||
|
||||
|
||||
|
||||
|
||||
#region GetPushOrder(获取合并后的吉客云订单)
|
||||
/// <summary>
|
||||
/// 获取合并后的吉客云订单
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public List<PushOrderListResp> GetPushOrder()
|
||||
{
|
||||
string sql = $@"
|
||||
SELECT [shopCode], [shopName], [shopId], [warehouseName], [warehouseCode],
|
||||
[status], CONVERT(NVARCHAR(30),[consignTime],23) [consignTime],
|
||||
[goodsNo], [goodsId],SUM([sellTotal]) [sellTotal],
|
||||
SUM([sellCount]) [sellCount], SUM([divideSellTotal]) AS [divideSellTotal],
|
||||
[barcode], [TradeType] ,[warehouseId]
|
||||
FROM [JackOrders] a WITH (NOLOCK)
|
||||
LEFT JOIN [dbo].[JackOrdersItem] b WITH (NOLOCK)
|
||||
ON a.id = b.JackOrdersId
|
||||
WHERE a.status = 0
|
||||
GROUP BY [shopCode],[shopName], [shopId], [warehouseName], [warehouseCode], [status], CONVERT(NVARCHAR(30),[consignTime],23) ,[goodsNo], [goodsId], [barcode] ,[warehouseId], [TradeType];";
|
||||
var list = this.SelectList<PushOrderListResp>(sql);
|
||||
return list;
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -90,6 +90,8 @@
|
||||
<Compile Include="JackOrdersItemRepository.cs" />
|
||||
<Compile Include="JackOrdersRepository.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="PushKingDeeOrderItemRepository.cs" />
|
||||
<Compile Include="PushKingDeeOrderRepository.cs" />
|
||||
<Compile Include="SysWorkprocessRepository.cs" />
|
||||
<Compile Include="YTKJTShopParameterRepository.cs" />
|
||||
<Compile Include="ZHMD\WMStoJackyunInventoryMovementView1Repository.cs" />
|
||||
|
||||
@ -0,0 +1,26 @@
|
||||
using MyCode.Project.Repositories.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Domain.Message;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.Search;
|
||||
|
||||
namespace MyCode.Project.Repositories
|
||||
{
|
||||
public class PushKingDeeOrderItemRepository: Repository<PushKingDeeOrderItem>, IPushKingDeeOrderItemRepository
|
||||
{
|
||||
public PushKingDeeOrderItemRepository(MyCodeSqlSugarClient context) : base(context)
|
||||
{ }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
using MyCode.Project.Repositories.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Domain.Message;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.Search;
|
||||
|
||||
namespace MyCode.Project.Repositories
|
||||
{
|
||||
public class PushKingDeeOrderRepository: Repository<PushKingDeeOrder>, IPushKingDeeOrderRepository
|
||||
{
|
||||
public PushKingDeeOrderRepository(MyCodeSqlSugarClient context) : base(context)
|
||||
{ }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
using MyCode.Project.Repositories.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Domain.Message;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.Search;
|
||||
|
||||
namespace MyCode.Project.Repositories
|
||||
{
|
||||
public class WMStoJackyunInventoryMovementView1Repository: Repository<WMStoJackyunInventoryMovementView1>, IWMStoJackyunInventoryMovementView1Repository
|
||||
{
|
||||
public WMStoJackyunInventoryMovementView1Repository(MyCodeSqlSugarClient context) : base(context)
|
||||
{ }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
using MyCode.Project.Repositories.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using MyCode.Project.Domain.Message;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.Search;
|
||||
|
||||
namespace MyCode.Project.Repositories
|
||||
{
|
||||
public class WMStoJackyunInventoryMovementView3Repository: Repository<WMStoJackyunInventoryMovementView3>, IWMStoJackyunInventoryMovementView3Repository
|
||||
{
|
||||
public WMStoJackyunInventoryMovementView3Repository(MyCodeSqlSugarClient context) : base(context)
|
||||
{ }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@ -1,4 +1,5 @@
|
||||
using MyCode.Project.Domain.Message.Response.Common;
|
||||
using MyCode.Project.Repositories.Common;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace MyCode.Project.Services
|
||||
@ -10,5 +11,12 @@ namespace MyCode.Project.Services
|
||||
/// </summary>
|
||||
/// <param name="now"></param>
|
||||
void TaskGetJackYunOrder(string now);
|
||||
|
||||
/// <summary>
|
||||
/// 合并吉客云订单到新表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
|
||||
string GetAndMergeJackYunOrder(string now);
|
||||
}
|
||||
}
|
||||
|
||||
@ -118,9 +118,9 @@ namespace MyCode.Project.Services.Implementation
|
||||
});
|
||||
return trades;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Message.Response.JackYun;
|
||||
using MyCode.Project.Domain.Model;
|
||||
using MyCode.Project.Domain.Repositories;
|
||||
using MyCode.Project.Infrastructure.Common;
|
||||
using MyCode.Project.Infrastructure.JackYun;
|
||||
@ -17,11 +18,20 @@ namespace MyCode.Project.Services.Implementation
|
||||
private IJackYunService _jackYunService;
|
||||
private IJackOrdersRepository _jackOrdersRepository;
|
||||
private IJackOrdersItemRepository _jackOrdersItemRepository;
|
||||
private IPushKingDeeOrderRepository _pushKingDeeOrderRepository;
|
||||
private IPushKingDeeOrderItemRepository _pushKingDeeOrderItemRepository;
|
||||
private IYTKJTShopParameterRepository _yTKJTShopParameterRepository;
|
||||
|
||||
public JackYunTaskService(IJackOrdersRepository jackOrdersRepository
|
||||
, IJackOrdersItemRepository jackOrdersItemRepository
|
||||
, IPushKingDeeOrderRepository pushKingDeeOrderRepository
|
||||
, IPushKingDeeOrderItemRepository pushKingDeeOrderItemRepository
|
||||
, IYTKJTShopParameterRepository yTKJTShopParameterRepository
|
||||
, IJackYunService jackYunService)
|
||||
{
|
||||
_yTKJTShopParameterRepository = yTKJTShopParameterRepository;
|
||||
_pushKingDeeOrderRepository = pushKingDeeOrderRepository;
|
||||
_pushKingDeeOrderItemRepository = pushKingDeeOrderItemRepository;
|
||||
_jackOrdersRepository = jackOrdersRepository;
|
||||
_jackOrdersItemRepository = jackOrdersItemRepository;
|
||||
_jackYunService = jackYunService;
|
||||
@ -82,5 +92,69 @@ namespace MyCode.Project.Services.Implementation
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region GetAndMergeJackYunOrder(合并吉客云订单到新表)
|
||||
/// <summary>
|
||||
/// 合并吉客云订单到新表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[TransactionCallHandler]
|
||||
public string GetAndMergeJackYunOrder(string now)
|
||||
{
|
||||
var list = _jackOrdersItemRepository.GetPushOrder();
|
||||
List<string> mesg = new List<string>();
|
||||
|
||||
var shopParemList = _yTKJTShopParameterRepository.Queryable().Where(t => t.FDOCUMENTSTATUS == "C").ToList();
|
||||
List<PushKingDeeOrderItem> pushKingDeeOrderItems = new List<PushKingDeeOrderItem>();
|
||||
List<PushKingDeeOrder> pushKingDeeOrders = new List<PushKingDeeOrder>();
|
||||
list.ForEach(sheet =>
|
||||
{
|
||||
if (pushKingDeeOrders.Where(t => t.ShopId == sheet.ShopId && t.WarehouseId == sheet.WarehouseId).Count() > 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
PushKingDeeOrder pushKingDeeOrder = new PushKingDeeOrder();
|
||||
pushKingDeeOrder = AutoMapperHelper.AutoMappToSingle<PushKingDeeOrder, PushOrderListResp>(sheet);
|
||||
pushKingDeeOrder.Id = Guid.NewGuid();
|
||||
pushKingDeeOrders.Add(pushKingDeeOrder);
|
||||
|
||||
var tempList = list.Where(t => t.ShopId == sheet.ShopId && t.WarehouseId == sheet.WarehouseId).ToList();
|
||||
tempList.ForEach(item =>
|
||||
{
|
||||
PushKingDeeOrderItem pushKingDeeOrderItem = new PushKingDeeOrderItem();
|
||||
pushKingDeeOrderItem = AutoMapperHelper.AutoMappToSingle<PushKingDeeOrderItem, PushOrderListResp>(item);
|
||||
pushKingDeeOrderItem.PushKingDeeOrderId = pushKingDeeOrder.Id;
|
||||
pushKingDeeOrderItem.Id = Guid.NewGuid();
|
||||
pushKingDeeOrderItems.Add(pushKingDeeOrderItem);
|
||||
});
|
||||
//var shopParem = shopParemList.Where(h => h.FSHOPCODE == sheet.ShopId.Value.ToString()&& h.FWAREHOUSE.Value.ToString()==sheet.WarehouseId ).FirstOrDefault();
|
||||
//if (shopParem != null)
|
||||
//{
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// mesg.Add($@"店铺{sheet.ShopName}没有配置店铺参数或者配置的仓库不是 {sheet.WarehouseCode}");
|
||||
//}
|
||||
});
|
||||
if (pushKingDeeOrders.Count > 0)
|
||||
{
|
||||
var oldList = _jackOrdersRepository.Queryable().Where(t => t.Status == 0).ToList();
|
||||
oldList.ForEach(t =>
|
||||
{
|
||||
if (pushKingDeeOrders.Count(h => h.ShopId == t.ShopId && t.WarehouseId == h.WarehouseId) > 0)
|
||||
{
|
||||
t.Status = 1;
|
||||
t.UpdateTime = DateTime.Now;
|
||||
}
|
||||
});
|
||||
oldList = oldList.Where(t => t.Status == 1).ToList();
|
||||
_jackOrdersRepository.Update(oldList);
|
||||
_pushKingDeeOrderRepository.Add(pushKingDeeOrders);
|
||||
_pushKingDeeOrderItemRepository.Add(pushKingDeeOrderItems);
|
||||
}
|
||||
|
||||
return JsonHelper.ToJson(list);
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@ -12,6 +12,7 @@ using MyCode.Project.Repositories.Common;
|
||||
using MyCode.Project.Repositories.ZHMD;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Linq;
|
||||
using System.Threading;
|
||||
|
||||
@ -51,6 +52,8 @@ namespace MyCode.Project.Services.Implementation
|
||||
if (now < startTime)
|
||||
now = startTime;
|
||||
var list= _wMStoJackyunInventoryMovementView3Repository.GetList(now);
|
||||
LogHelper.Info("WMS订单行数:" + list.Count);
|
||||
if (list.Count>0)
|
||||
SetWMSOrder(list);
|
||||
return list;
|
||||
|
||||
@ -64,6 +67,7 @@ namespace MyCode.Project.Services.Implementation
|
||||
[TransactionCallHandler]
|
||||
public void SetWMSOrder(List<WMStoJackyunInventoryMovementView1> trades)
|
||||
{
|
||||
|
||||
var ids = trades.Select(t => t.单据号).ToList();
|
||||
var oldids = _repository.Queryable<WMStoJackyunInventoryMovementView1>().Where(t => ids.Contains(t.单据号))
|
||||
.Select(t => new { t.单据号, t.单据行号 }).ToList();
|
||||
|
||||
@ -16,13 +16,13 @@ namespace MyCode.Project.WebApi.Areas.Wechat.Controllers
|
||||
/// <summary>
|
||||
/// 取得登陆信息
|
||||
/// </summary>
|
||||
protected MemberLoginInfo CurrentLogin
|
||||
protected LoginInfo CurrentLogin
|
||||
{
|
||||
get
|
||||
{
|
||||
var obj = this.RequestContext.RouteData.Values[Const.LoginInfoKey];
|
||||
|
||||
return ((JObject)obj).ToObject<MemberLoginInfo>();
|
||||
return ((JObject)obj).ToObject<LoginInfo>();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -50,6 +50,18 @@ namespace MyCode.Project.WebApi.Controllers
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 合并吉客云订单到新表
|
||||
/// <summary>
|
||||
/// 合并吉客云订单到新表
|
||||
/// </summary>
|
||||
[HttpGet]
|
||||
[AllowAnonymous]
|
||||
public string GetAndMergeJackYunOrder(string now)
|
||||
{
|
||||
return _jackYunTaskService.GetAndMergeJackYunOrder(now);
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
//#region 订单查询
|
||||
|
||||
|
||||
BIN
Reportapi/kingdeeDll/Kingdee.CDP.WebApi.SDK.dll
Normal file
BIN
Reportapi/kingdeeDll/Kingdee.CDP.WebApi.SDK.dll
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user