xxe hace 2 años
padre
commit
d2e3bb9b2b
Se han modificado 3 ficheros con 4 adiciones y 9 borrados
  1. +0
    -5
      HKCardOUT/Logic/Model/SaleLog.cs
  2. +2
    -2
      HKCardOUT/Logic/RemoteService.cs
  3. +2
    -2
      HKCardOUT/Logic/Service/HKCore.cs

+ 0
- 5
HKCardOUT/Logic/Model/SaleLog.cs Ver fichero

@@ -16,11 +16,6 @@ namespace HKCardOUT.Logic.Model
[SugarColumn(IsNullable = false)]
public string CardNo { get; set; }
/// <summary>
/// 消费金额
/// </summary>
[SugarColumn(IsNullable = false, ColumnDataType = "decimal(10,2)")]
public decimal Money { get; set; }
/// <summary>
/// 消费位置
/// </summary>
[SugarColumn(IsNullable = false)]


+ 2
- 2
HKCardOUT/Logic/RemoteService.cs Ver fichero

@@ -31,12 +31,12 @@ namespace HKCardOUT.Logic
/// </summary>
/// <param name="CardNo"></param>
/// <param name="Money"></param>
public static bool SyncSaleLog(string CardNo, decimal Money)
public static bool SyncSaleLog(string CardNo, string StallId)
{
var data = IHttpMultiClient.HttpMulti.AddNode(t =>
{
t.ReqType = MultiType.POST;
t.JsonParam = (new { Money, Type = -1, CardNum = CardNo }).ToJson();
t.JsonParam = (new { GateId=StallId, Type = -1, CardNum = CardNo }).ToJson();
t.NodePath = ApiRoute.SyncSaleLog;
}).Build().RunStringFirst();
return bool.Parse(data.ToModel<JObject>()["data"].ToString());


+ 2
- 2
HKCardOUT/Logic/Service/HKCore.cs Ver fichero

@@ -31,7 +31,7 @@ namespace HKCardOUT.Logic.Service
var entity = DbContext.Context.Insertable(input).CallEntityMethod(t => t.Create()).ExecuteReturnEntity();
if (entity.Id!=Guid.Empty)
{
var res = RemoteService.SyncSaleLog(input.CardNo, input.Money);
var res = RemoteService.SyncSaleLog(input.CardNo, input.Location);
Main.GetInstance.Start(input.Location.AsInt());
DbContext.Context.Updateable<SaleLog>().SetColumns(t => t.IsSync == true).Where(t => t.Id == entity.Id).ExecuteCommand();
return res;
@@ -44,7 +44,7 @@ namespace HKCardOUT.Logic.Service
var entity = DbContext.Context.Insertable(input).CallEntityMethod(t => t.Create()).ExecuteReturnEntity();
if (entity.Id!=Guid.Empty)
{
var res = RemoteService.SyncSaleLog(input.CardNo, input.Money);
var res = RemoteService.SyncSaleLog(input.CardNo, input.Location);
Main.GetInstance.Start(input.Location.AsInt());
DbContext.Context.Updateable<SaleLog>().SetColumns(t => t.IsSync == true).Where(t => t.Id == entity.Id).ExecuteCommand();
return res;


Cargando…
Cancelar
Guardar