提交代码
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using SqlSugar;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
@ -7,65 +8,77 @@ using WCS.BLL.HardWare;
|
||||
|
||||
namespace WCS.DAL.DbModels
|
||||
{
|
||||
///<summary>
|
||||
///模组信息表
|
||||
///</summary>
|
||||
[SugarTable("module_info")]
|
||||
public partial class ModuleInfo
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// 模组Id
|
||||
/// 主键 Id 自增
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "id", IsPrimaryKey = true, IsNullable = false, IsIdentity = true)]
|
||||
public int Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 模组编码
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "module_code", Length = 50, IsNullable = false, ColumnDescription = "模组编码")]
|
||||
public string ModuleCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 货架Id
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "shelf_id", IsNullable = false, ColumnDescription = "货架Id")]
|
||||
public int ShelfId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 货架编码
|
||||
/// 货架号
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "shelf_code", Length = 50, IsNullable = false, ColumnDescription = "货架编码;货架一般按照报警灯来区分 一个报警灯指示的是一个货架")]
|
||||
public string ShelfCode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 板子的Id
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "board_id", IsNullable = false, ColumnDescription = "模组pcb板id")]
|
||||
public int BoardId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 板子上有几个灯
|
||||
/// 板子上第几个灯
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "light_count", IsNullable = false, ColumnDescription = "板子上灯的数量")]
|
||||
public int LightCount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 板子所连接模块的Ip
|
||||
/// 对应Can模块的Ip
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "client_ip", Length = 50, IsNullable = false, ColumnDescription = "货架对应Can模块的Ip")]
|
||||
public string CleintIp { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第几行
|
||||
/// R 行
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "R", Length = 50, IsNullable = false, ColumnDescription = "R 行")]
|
||||
public string R { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 第几列
|
||||
/// C 列
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "C", Length = 50, IsNullable = false, ColumnDescription = " C 列")]
|
||||
public string C { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 串联后大货架编码;大货架编码:未串联时是与货架编码是一对一的关系;串联后与货架编码是一对多
|
||||
/// 串联后大货架编码;大货架编码:未串联时是与货架编码是一对一的关系;串联后与货架编码是一对多的关系
|
||||
/// </summary>
|
||||
public string Bigshelfcode { get; set; }
|
||||
[SugarColumn(ColumnName = "big_shelf_code", Length = 50, IsNullable = true, ColumnDescription = "串联后大货架编码;大货架编码:未串联时是与货架编码是一对一的关系;串联后与货架编码是一对多的关系")]
|
||||
public string? Bigshelfcode { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否被禁用
|
||||
/// </summary>
|
||||
public bool IsEnable { get; set; }
|
||||
[SugarColumn(ColumnName = "is_enable", IsNullable = false, ColumnDescription = "串联后大货架编码;大货架编码:未串联时是与货架编码是一对一的关系;串联后与货架编码是一对多的关系")]
|
||||
public bool IsEnable { get; set; } = true;
|
||||
|
||||
|
||||
public Mode CurentMode { get; set; } = Mode.待机模式;
|
||||
[SugarColumn(ColumnName = "current_mode", IsNullable = true, ColumnDescription = "串联后大货架编码;大货架编码:未串联时是与货架编码是一对一的关系;串联后与货架编码是一对多的关系")]
|
||||
public Mode CurrentMode { get; set; } = Mode.待机模式;
|
||||
}
|
||||
}
|
||||
|
@ -49,7 +49,7 @@ namespace WCS.DAL.DbModels
|
||||
/// <summary>
|
||||
/// 板子的Id
|
||||
/// </summary>
|
||||
[SugarColumn(ColumnName = "board_id", IsNullable = false, ColumnDescription = "货架Id")]
|
||||
[SugarColumn(ColumnName = "board_id", IsNullable = false, ColumnDescription = "模组pcb板id")]
|
||||
public int BoardId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -33,7 +33,7 @@ namespace WCS.BLL.HardWare
|
||||
|
||||
public void GoInInstore(string IPAdress)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
//找到对应的灯 亮灯
|
||||
}
|
||||
|
||||
public void GoInOutstore(List<OutOrderMatDetail> MatDetails, OutOrder outOrder)
|
||||
@ -53,6 +53,7 @@ namespace WCS.BLL.HardWare
|
||||
|
||||
public void GoOutInstore()
|
||||
{
|
||||
//找到已亮灯的 灭灯
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
|
@ -38,7 +38,7 @@ namespace WCS.BLL.HardWare
|
||||
ModuleCode = module.ModuleCode,
|
||||
BoardId = module.BoardId,
|
||||
IsEnable = module.IsEnable,
|
||||
CurrentMode = module.CurentMode
|
||||
CurrentMode = module.CurrentMode
|
||||
});
|
||||
}
|
||||
ModulesStr = string.Join(";", Modules.Select(t => t.ModuleCode));
|
||||
|
@ -153,7 +153,7 @@ namespace WCS.BLL.HardWare
|
||||
{
|
||||
if (CurrentMode != Mode.待机模式)
|
||||
{
|
||||
//TO DO 退出对应的模式 然后再发送进入入库模式
|
||||
return;
|
||||
}
|
||||
var storeInfos = DbHelp.db.Queryable<StoreInfo>()
|
||||
.Where(t => t.BoardId == BoardId)
|
||||
|
@ -38,6 +38,13 @@ namespace WCS.BLL.Manager
|
||||
ShelfCode = shelfInDb.ShelfCode,
|
||||
GroupName = shelfInDb.GroupName,
|
||||
};
|
||||
case 2:
|
||||
return new SmartShelf(shelfInDb)
|
||||
{
|
||||
ShelfId = shelfInDb.Id,
|
||||
ShelfCode = shelfInDb.ShelfCode,
|
||||
GroupName = shelfInDb.GroupName,
|
||||
};
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
@ -34,6 +34,7 @@ namespace WCS.BLL.Services.Service
|
||||
.WhereIF(!string.IsNullOrEmpty(request.MatSpec), (id, si) => id.MatSpec.Contains(request.MatSpec))
|
||||
.WhereIF(!string.IsNullOrEmpty(request.MatSupplier), (id, si) => id.MatSpec.Contains(request.MatSupplier))
|
||||
.WhereIF(!string.IsNullOrEmpty(request.MatCustomer), (id, si) => id.MatSpec.Contains(request.MatCustomer))
|
||||
.WhereIF(request.Direction != null, (id, si) => id.Direction == request.Direction)
|
||||
|
||||
|
||||
.WhereIF(request.StoreId != 0, (id, si) => id.StoreId == request.StoreId)
|
||||
@ -94,7 +95,6 @@ namespace WCS.BLL.Services.Service
|
||||
.WhereIF(!string.IsNullOrEmpty(request.StoreCode), (id, si) => id.StoreCode.Contains(request.StoreCode))
|
||||
;
|
||||
var records = await recordsQueryable
|
||||
.Skip((request.PageNumber - 1) * request.PageSize).Take(request.PageSize)
|
||||
.Select<InOutRecord>()
|
||||
.ToListAsync();
|
||||
//生成序号
|
||||
|
@ -909,7 +909,6 @@ namespace WCS.BLL.Services.Service
|
||||
};
|
||||
DbHelp.db.Updateable(inventoryDetail).ExecuteCommand();
|
||||
DbHelp.db.Insertable(inOutRecord).ExecuteCommand();
|
||||
|
||||
}
|
||||
//数量相等的情况 暂时不用管 不动库存数据也不生成记录
|
||||
else
|
||||
|
@ -236,15 +236,6 @@ namespace WCS.BLL.Services.Service
|
||||
}
|
||||
}
|
||||
|
||||
Task<PageQueryResponse<ShelfInfo>> IStoreInfoService.GetShelves(GetShelvesRequest request)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
Task<ResponseCommon<object>> IStoreInfoService.addOrUpdateShelfInfo(AddShelfInfoRequest<ShelfInfo> request)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
async Task<ResponseCommon<object>> IStoreInfoService.GenerateStoreInfo()
|
||||
{
|
||||
|
@ -20,6 +20,8 @@ namespace WCS.Model.ApiModel.InOutRecord
|
||||
public string MatSupplier { get; set; }
|
||||
|
||||
public string MatCustomer { get; set; }
|
||||
|
||||
public DirectionEnum? Direction { get; set; }
|
||||
#endregion
|
||||
|
||||
#region 库位属性
|
||||
|
@ -25,7 +25,7 @@ namespace WCS.Model.ApiModel.InOutRecord
|
||||
#endregion
|
||||
|
||||
public string? OrderNumber { get; set; }
|
||||
public DirectionEnum Direction { get; set; }
|
||||
public DirectionEnum? Direction { get; set; }
|
||||
public bool IsUpload { get; set; } = false;
|
||||
public DateTime OperateTime { get; set; }
|
||||
public string OperateUser { get; set; }
|
||||
|
@ -45,13 +45,19 @@ namespace WCS.WebApi.Controllers
|
||||
var columns = new[]
|
||||
{
|
||||
new ExportableColumn("序号","RowNumber"),
|
||||
new ExportableColumn("库位","StoreCode"),
|
||||
new ExportableColumn("物料编码","MatCode"),
|
||||
new ExportableColumn("物料名称","MatName"),
|
||||
new ExportableColumn("规格","MatSpec"),
|
||||
new ExportableColumn("批次","MatBatch"),
|
||||
new ExportableColumn("供应商","MatSupplier"),
|
||||
new ExportableColumn("客户","MatCustomer"),
|
||||
new ExportableColumn("数量","MatQty"),
|
||||
new ExportableColumn("库位","StoreCode"),
|
||||
new ExportableColumn("入库时间","InstoreTime"),
|
||||
new ExportableColumn("类型","Direction"),
|
||||
|
||||
new ExportableColumn("操作人","OperateUser"),
|
||||
new ExportableColumn("操作时间","OperateTime"),
|
||||
|
||||
new ExportableColumn("物料SN", "MatSN"),
|
||||
};
|
||||
if (data == null)
|
||||
|
@ -114,5 +114,33 @@ namespace WebApi.Controllers
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <20><><EFBFBD>ƻ<EFBFBD><C6BB><EFBFBD><EFBFBD>ύ<EFBFBD><E1BDBB><EFBFBD><EFBFBD>
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[Route("singleLightCommitInstore")]
|
||||
[HttpPost(Name = "queryInstoreStatus")]
|
||||
public async Task<ResponseBase> singleLightCommitInstore(QueryByMatSnRequest request)
|
||||
{
|
||||
//TODO:<3A><><EFBFBD><EFBFBD> <20><><EFBFBD>ƻ<EFBFBD><C6BB><EFBFBD><EFBFBD>ύ<EFBFBD><E1BDBB><EFBFBD><EFBFBD>
|
||||
try
|
||||
{
|
||||
return await _instoreService.queryInstoreStatus(request);
|
||||
//ShelfManager.
|
||||
//
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseCommon()
|
||||
{
|
||||
Code = 300,
|
||||
Message = $"<22><><EFBFBD><EFBFBD>ʧ<EFBFBD><CAA7>:{ex.Message}",
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -215,5 +215,79 @@ namespace WebApi.Controllers
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// <20><><EFBFBD>ƿ<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD>
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[Route("singleLightGoInOutstore")]
|
||||
[HttpPost(Name = "singleLightGoInOutstore")]
|
||||
public async Task<ResponseBase> singleLightGoInOutstore(GetOutOrderDetailRequest request)
|
||||
{
|
||||
//TODO<44><4F><EFBFBD><EFBFBD>
|
||||
try
|
||||
{
|
||||
return await _outstoreService.GoInOutstore(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ģʽʧ<CABD>ܣ<EFBFBD>" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <20><><EFBFBD>ƽ<EFBFBD><C6BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[Route("singleLightGoOutOutstore")]
|
||||
[HttpPost(Name = "singleLightGoOutOutstore")]
|
||||
public async Task<ResponseBase> singleLightGoOutOutstore(GetOutOrderDetailRequest request)
|
||||
{
|
||||
//TODO<44><4F><EFBFBD><EFBFBD>
|
||||
try
|
||||
{
|
||||
return await _outstoreService.GoOutOutstore(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "<22><>ѯʧ<D1AF>ܣ<EFBFBD>" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <20><><EFBFBD><EFBFBD>ȷ<EFBFBD>ϳ<EFBFBD><CFB3><EFBFBD>
|
||||
/// </summary>
|
||||
/// <param name="request"></param>
|
||||
/// <returns></returns>
|
||||
[Route("singleLightConfirmOutstore")]
|
||||
[HttpPost(Name = "singleLightConfirmOutstore")]
|
||||
public async Task<ResponseBase> singleLightConfirmOutstore(GetOutOrderDetailRequest request)
|
||||
{
|
||||
//TODO<44><4F><EFBFBD><EFBFBD>
|
||||
try
|
||||
{
|
||||
return await _outstoreService.GoOutOutstore(request);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
return new ResponseBase()
|
||||
{
|
||||
Code = 300,
|
||||
Message = "<22><>ѯʧ<D1AF>ܣ<EFBFBD>" + ex.Message,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -27,6 +27,8 @@ using WCS.Model.ApiModel.MatInventoryDetail;
|
||||
using HandyControl.Tools.Extension;
|
||||
using WCS.Model.ApiModel.Stocktaking;
|
||||
using WCS.Model.ApiModel.InOutRecord;
|
||||
using System.Collections.ObjectModel;
|
||||
using static 货架标准上位机.ViewModel.InOutRecordViewModel;
|
||||
|
||||
namespace 货架标准上位机.ViewModel
|
||||
{
|
||||
@ -162,6 +164,44 @@ namespace 货架标准上位机.ViewModel
|
||||
SetProperty(ref matSN, value);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private DirectionEnum? selectedDirection;
|
||||
public DirectionEnum? SelectedDirection
|
||||
{
|
||||
get { return selectedDirection; }
|
||||
set
|
||||
{
|
||||
SetProperty(ref selectedDirection, value);
|
||||
}
|
||||
}
|
||||
|
||||
public ObservableCollection<DirectionItem> Directions => GetEnumValues();
|
||||
private ObservableCollection<DirectionItem> GetEnumValues()
|
||||
{
|
||||
// 初始化ObservableCollection
|
||||
var directions = new ObservableCollection<DirectionItem>();
|
||||
// 添加“全部”选项
|
||||
directions.Add(new DirectionItem { Text = "全部", Value = null }); // Value设置为null或某个表示“全部”的值
|
||||
|
||||
// 遍历DirectionEnum枚举并添加项
|
||||
foreach (DirectionEnum direction in Enum.GetValues(typeof(DirectionEnum)))
|
||||
{
|
||||
directions.Add(new DirectionItem { Text = direction.ToString(), Value = direction });
|
||||
}
|
||||
return directions;
|
||||
}
|
||||
|
||||
public class DirectionItem
|
||||
{
|
||||
public string Text { get; set; }
|
||||
public object Value { get; set; }
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
return Text;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Command
|
||||
@ -192,11 +232,13 @@ namespace 货架标准上位机.ViewModel
|
||||
{
|
||||
var body = new GetInOutRecordRequest()
|
||||
{
|
||||
MatName = MatName,
|
||||
|
||||
MatSN = MatSN,
|
||||
MatName = MatName,
|
||||
MatBatch = MatBatch,
|
||||
MatCode = MatCode,
|
||||
StoreCode = StoreCode,
|
||||
Direction = SelectedDirection,
|
||||
|
||||
UserName = LocalStatic.CurrentUser,
|
||||
DeviceType = LocalFile.Config.DeviceType,
|
||||
|
@ -90,7 +90,7 @@ namespace 货架标准上位机.ViewModels
|
||||
return;
|
||||
}
|
||||
|
||||
#region 调用接口获取数据
|
||||
#region 调用接口获取单据
|
||||
try
|
||||
{
|
||||
var body = new GetStockTakingOrdersRequest()
|
||||
@ -113,7 +113,7 @@ namespace 货架标准上位机.ViewModels
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Growl.Error("加载数据失败:" + ex.Message);
|
||||
Growl.Error("加载单据失败:" + ex.Message);
|
||||
}
|
||||
finally
|
||||
{
|
||||
@ -138,20 +138,20 @@ namespace 货架标准上位机.ViewModels
|
||||
{
|
||||
if (DataGridItemSource == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
//判断是否勾选数据
|
||||
//判断是否勾选单据
|
||||
var selectetOrder = DataGridItemSource.Where(t => t.IsSelected)
|
||||
.FirstOrDefault();
|
||||
if (selectetOrder == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
#region 调用接口获取数据
|
||||
#region 调用接口获取单据
|
||||
|
||||
var body = new GetStockTakingOrderMatDetailRequest()
|
||||
{
|
||||
@ -203,19 +203,19 @@ namespace 货架标准上位机.ViewModels
|
||||
{
|
||||
if (DataGridItemSource == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
//判断是否勾选数据
|
||||
//判断是否勾选单据
|
||||
var selectedOutOrder = DataGridItemSource.Where(t => t.IsSelected)
|
||||
.FirstOrDefault();
|
||||
if (selectedOutOrder == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
#region 调用接口获取数据
|
||||
#region 调用接口获取单据
|
||||
var body = new GetOutOrderDetailRequest()
|
||||
{
|
||||
OrderId = selectedOutOrder.Id,
|
||||
@ -267,15 +267,15 @@ namespace 货架标准上位机.ViewModels
|
||||
//是否已搜索
|
||||
if (DataGridItemSource == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
//判断是否已勾选数据
|
||||
//判断是否已勾选单据
|
||||
var selectetOrder = DataGridItemSource.Where(t => t.IsSelected)
|
||||
.FirstOrDefault();
|
||||
if (selectetOrder == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
@ -321,15 +321,15 @@ namespace 货架标准上位机.ViewModels
|
||||
//是否已搜索
|
||||
if (DataGridItemSource == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
//判断是否已勾选数据
|
||||
//判断是否已勾选单据
|
||||
var selectetOrder = DataGridItemSource.Where(t => t.IsSelected)
|
||||
.FirstOrDefault();
|
||||
if (selectetOrder == null)
|
||||
{
|
||||
Growl.Warning("未勾选数据!");
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
@ -364,6 +364,59 @@ namespace 货架标准上位机.ViewModels
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
public ICommand BtnCommitCommand { get => new DelegateCommand(BtnCommit); }
|
||||
public void BtnCommit()
|
||||
{
|
||||
try
|
||||
{
|
||||
//是否已搜索
|
||||
if (DataGridItemSource == null)
|
||||
{
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
//判断是否已勾选单据
|
||||
var selectetOrder = DataGridItemSource.Where(t => t.IsSelected)
|
||||
.FirstOrDefault();
|
||||
if (selectetOrder == null)
|
||||
{
|
||||
Growl.Warning("未勾选单据!");
|
||||
return;
|
||||
}
|
||||
|
||||
#region 调用接口提交盘点
|
||||
var body = new GetStockTakingOrderMatDetailRequest()
|
||||
{
|
||||
StockTakingOrderId = selectetOrder.Id,
|
||||
StockTakingOrderNumber = selectetOrder.StocktakingOrderNumber,
|
||||
UserName = LocalStatic.CurrentUser,
|
||||
DeviceType = LocalFile.Config.DeviceType,
|
||||
};
|
||||
var Result = ApiHelp.GetDataFromHttp<ResponseCommon>(LocalFile.Config.ApiIpHost + "stockTaking/commitStockTakingOrder", body, "POST");
|
||||
if (Result != null && Result.Code == 200)
|
||||
{
|
||||
Growl.Warning("单据已提交,库存数据已修改!");
|
||||
BtnSearch();
|
||||
}
|
||||
else if (Result != null)
|
||||
{
|
||||
Growl.Warning(Result.Message);
|
||||
}
|
||||
else
|
||||
{
|
||||
Growl.Warning("调用接口失败!");
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Growl.Error("出现异常:" + ex.Message);
|
||||
}
|
||||
finally
|
||||
{
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region PageOperation 分页操作
|
||||
|
@ -62,6 +62,14 @@
|
||||
VerticalAlignment="Center" HorizontalAlignment="Left"
|
||||
FontSize="18" MinWidth="120" ></TextBox>
|
||||
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="2" Margin="5"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Right"
|
||||
Text=" 库 位 :" FontSize="18" ></TextBlock>
|
||||
<TextBox Grid.Row="2" Grid.Column="3" Text="{Binding StoreCode}"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Left"
|
||||
FontSize="18" MinWidth="120" ></TextBox>
|
||||
|
||||
<TextBlock Grid.Row="1" Grid.Column="4" Margin="5"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Right"
|
||||
Text="物料批次:" FontSize="18" ></TextBlock>
|
||||
@ -69,19 +77,24 @@
|
||||
VerticalAlignment="Center" HorizontalAlignment="Left"
|
||||
FontSize="18" MinWidth="120" ></TextBox>
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="2" Margin="5"
|
||||
<TextBlock Grid.Row="2" Grid.Column="4" Margin="5"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Right"
|
||||
Text="物料条码:" FontSize="18" ></TextBlock>
|
||||
<TextBox Grid.Row="2" Grid.Column="3" Text="{Binding MatSN}"
|
||||
<TextBox Grid.Row="2" Grid.Column="5" Text="{Binding MatSN}"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Left"
|
||||
FontSize="18" MinWidth="120" ></TextBox>
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" Margin="5"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Right"
|
||||
Text=" 库 位 :" FontSize="18" ></TextBlock>
|
||||
<TextBox Grid.Row="2" Grid.Column="1" Text="{Binding StoreCode}"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Left"
|
||||
FontSize="18" MinWidth="160" ></TextBox>
|
||||
Text=" 类 型 :" FontSize="18" ></TextBlock>
|
||||
<ComboBox Grid.Row="2" Grid.Column="1"
|
||||
ItemsSource="{Binding Directions}"
|
||||
DisplayMemberPath="Text"
|
||||
SelectedValuePath="Value"
|
||||
SelectedValue="{Binding SelectedDirection, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||
FontSize="18"
|
||||
Height="20"
|
||||
IsEditable="False"/>
|
||||
|
||||
<Button Style="{StaticResource ButtonSuccess}"
|
||||
Margin="2"
|
||||
@ -121,14 +134,17 @@
|
||||
AutoGenerateColumns="False" FontSize="13">
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn IsReadOnly="True" Header="序号" Binding="{Binding RowNumber}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="库位" Binding="{Binding StoreCode}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="150" Header="物料编码" Binding="{Binding MatCode}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="150" Header="物料名称" Binding="{Binding MatName}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="150" Header="规格" Binding="{Binding MatSpec}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="100" Header="批次" Binding="{Binding MatBatch}"></DataGridTextColumn>
|
||||
<DataGridTextColumn IsReadOnly="True" Header="数量" Binding="{Binding MatQty}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="库位" Binding="{Binding StoreCode}"></DataGridTextColumn>
|
||||
<DataGridTextColumn IsReadOnly="True" Header="已锁定" Binding="{Binding IsLockedStr}"></DataGridTextColumn>
|
||||
<DataGridTextColumn IsReadOnly="True" Header="入库时间" Binding="{Binding InstoreTime,StringFormat='yyyy-MM-dd HH:mm:ss'}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="100" Header="供应商" Binding="{Binding MatSupplier}"></DataGridTextColumn>
|
||||
<DataGridTextColumn MaxWidth="100" Header="客户" Binding="{Binding MatCustomer}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="数量" Binding="{Binding MatQty}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="类型" Binding="{Binding Direction}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="操作人" Binding="{Binding OperateUser}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="操作时间" Binding="{Binding OperateTime,StringFormat='yyyy-MM-dd HH:mm:ss'}"></DataGridTextColumn>
|
||||
<DataGridTextColumn Header="物料SN" Binding="{Binding MatSN}"></DataGridTextColumn>
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
|
@ -121,7 +121,7 @@
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" Margin="5">
|
||||
<TextBlock Text="绑定后货架编码:" FontSize="15" VerticalAlignment="Center" HorizontalAlignment="Right"></TextBlock>
|
||||
<TextBox Name="txtBindShelfCode" MinWidth="200" Grid.Row="0" Grid.Column="1" FontSize="15"
|
||||
<TextBox Name="txtBindShelfCode" MinWidth="150" MaxWidth="150" Grid.Row="0" Grid.Column="1" FontSize="15"
|
||||
VerticalAlignment="Center" HorizontalAlignment="Stretch"
|
||||
Text="{Binding BindShelfCode}"
|
||||
Style="{StaticResource TextBoxExtend}">
|
||||
|
@ -91,6 +91,10 @@
|
||||
<Button MinHeight="40" FontSize="18" Margin="5" Command="{Binding BtnPauseCommand}"
|
||||
Content="暂停盘点" FontFamily="{StaticResource IconFont}" Background="CadetBlue" Foreground="White">
|
||||
</Button>
|
||||
|
||||
<Button MinHeight="40" FontSize="18" Margin="5" Command="{Binding BtnCommitCommand}"
|
||||
Content="提交盘点" FontFamily="{StaticResource IconFont}" Background="SaddleBrown" Foreground="White">
|
||||
</Button>
|
||||
</StackPanel>
|
||||
<DataGrid Grid.Row="1" SelectedCellsChanged="DataGrid_SelectedCellsChanged"
|
||||
SelectedItem="{Binding SelectedataGridItem}"
|
||||
|
Reference in New Issue
Block a user