510 lines
17 KiB
C#
510 lines
17 KiB
C#
|
using System;
|
|||
|
using System.Collections.Generic;
|
|||
|
using System.Linq;
|
|||
|
using System.Runtime.Serialization;
|
|||
|
using System.ServiceModel;
|
|||
|
using System.ServiceModel.Web;
|
|||
|
using System.Text;
|
|||
|
using System.Data;
|
|||
|
using DeiNiu.Utils;
|
|||
|
|
|||
|
namespace DeiNiu.Wcf
|
|||
|
{
|
|||
|
/// <summary>
|
|||
|
/// wince 专用
|
|||
|
/// </summary>
|
|||
|
[ServiceContract]
|
|||
|
public interface IMobile
|
|||
|
{
|
|||
|
[OperationContract]
|
|||
|
[WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json,
|
|||
|
UriTemplate = "validuser?userId={userId}&passwd={passwd}")]
|
|||
|
int validUser(string userId, string passwd);
|
|||
|
[OperationContract]
|
|||
|
[WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json,
|
|||
|
UriTemplate = "login?userId={userId}&passwd={passwd}")]
|
|||
|
string login(string account, string passwd);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getDictionary();
|
|||
|
|
|||
|
/// <summary>
|
|||
|
///取移动端权限列表
|
|||
|
/// </summary>
|
|||
|
/// <param name="userId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
List<string> getPortAuths(int userId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
///取所有线路
|
|||
|
/// </summary>
|
|||
|
/// <param name="custName">可为null,取所有线路</param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
List<string> getLines(string custName);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
///取所属货区
|
|||
|
/// </summary>
|
|||
|
/// <param name="userId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
List<string> getPartions(int userId);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int validRole(string account,string passwd,string role);
|
|||
|
|
|||
|
|
|||
|
//------------------------- stock location begin ------------------------------------------------------------------------------------------
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// get stock goods info by locid
|
|||
|
/// for wince
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getStockLocation(string locId);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getStockLocationsByBarcode(string barcode);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// update stock goods info
|
|||
|
/// on wince stock check
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <param name="batch"></param>
|
|||
|
/// <param name="count"></param>
|
|||
|
/// <param name="oldCount"></param>
|
|||
|
/// <param name="reason"></param>
|
|||
|
[OperationContract]
|
|||
|
bool updateStockLocation(string locId, string goodsId, int skuId, string batch, decimal count, string reason, int type, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int initialStockIn(string goodsId,string locId, decimal batchCount, string[] skuKeys, string[] skuValues, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// clear the location
|
|||
|
/// on wince
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <param name="reason"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool clearLocation(string locId, string reason, int operId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 更新location status
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <param name="status"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool upLocationStatus(string locId, int status, int operId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 更新商品库容量
|
|||
|
/// </summary>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <param name="volType"></param>
|
|||
|
/// <param name="volume"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool updateGoodsLocationVolume(string goodsId, int volType, decimal volume, int operId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// location info
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getLocation(string locId);
|
|||
|
/// <summary>
|
|||
|
/// 扫描货位,得到货架上的商品信息,比较该商品在erp和wms库存
|
|||
|
/// </summary>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getStockCompareErp(string goodsId, string barcode);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 手持上下架
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <param name="batch"></param>
|
|||
|
/// <param name="count"></param>
|
|||
|
/// <param name="type"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
int upDownStockLocation(string locId, string goodsId, int skuId, string batch, decimal count, int type, int operId, string token, int oldRecId);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 已下架待上架商品
|
|||
|
/// </summary>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getDownStockList4Up(int operId);
|
|||
|
|
|||
|
//绑定id
|
|||
|
[OperationContract]
|
|||
|
int locationEleIdCombine(string locId, int eleId, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 补零入库
|
|||
|
/// </summary>
|
|||
|
/// <param name="locId"></param>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <param name="batch"></param>
|
|||
|
/// <param name="count"></param>
|
|||
|
/// <param name="reason"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
int repItemIn(string locId, string goodsId, int skuId, string batch, decimal count, int portId, int operId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 货位分配
|
|||
|
/// </summary>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <param name="batch"></param>
|
|||
|
/// <param name="count"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getLocations(int skuId, string skuCode, string goodsId, string batch, decimal count);
|
|||
|
/// <summary>
|
|||
|
/// 根据商品找库存货位信息
|
|||
|
/// </summary>
|
|||
|
/// <param name="goodsId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getGoodsStockLocations(string barcode);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// get erp storage by barcode
|
|||
|
/// </summary>
|
|||
|
/// <param name="barcode"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getGoodsERPStoreByBarcode(string barcode);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// get pandian orders by ownerid and status
|
|||
|
/// </summary>
|
|||
|
/// <param name="ownerId"></param>
|
|||
|
/// <param name="status"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getPandianOrders(int ownerId,int status);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getPandianItem(string orderNo, string locationId);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 盘点采集
|
|||
|
/// </summary>
|
|||
|
/// <param name="orderNo"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool newPandianItem(string orderNo, string locationId, int skuId, string barcode, string prdDate,
|
|||
|
string batch, decimal count, int operId, string token);
|
|||
|
|
|||
|
//-----------------------stock maintain begin --------------------------------------------------------------
|
|||
|
|
|||
|
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataSet getData4Maintain(string locationId = "");
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getIssueData(int skuId);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// new maintain record
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool newMaintain(int stockId,decimal mCount,decimal issueCount, string details, int operId,string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
bool fixIssueData(int skuId, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
// -------------------stock In request begin --------------------------------------------------------------------------------------------------
|
|||
|
|
|||
|
|
|||
|
// 根据预到单收货
|
|||
|
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getPreInDetail(string preInNo,int operId, string token);
|
|||
|
|
|||
|
// [OperationContract]
|
|||
|
// DataTable getPreInInfo(string preInNo, int operId, string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
bool receiveDetail(string preInNo, string goodsId, decimal arriveNumber, decimal receiveNumber, int inType, string inRemark,
|
|||
|
decimal temperature, bool isCache, int cachePartion, int operId, string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getGoodsPackByBarcode(string barcode);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getReceiveDetailByBarcode(string preInOrder, string barcode);
|
|||
|
[OperationContract]
|
|||
|
decimal getValidSeedsCnt(string goodsId, decimal batchCount);
|
|||
|
[OperationContract]
|
|||
|
bool isFlowNoValid(string preInOrder, string flowNo);
|
|||
|
[OperationContract]
|
|||
|
int validIn(string preInNo, string flowNo, string goodsId, decimal batchCount, decimal seedsCount,
|
|||
|
string[] skuKeys, string[] skuValues, bool isPass, bool isIsuLocations, int secondValidUserId, int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getPreValidResult(string preInNo, string flowNo, int operId, string token,bool showAllPartions=false);
|
|||
|
[OperationContract]
|
|||
|
DataTable getStockInPortDetail(int portId);
|
|||
|
[OperationContract]
|
|||
|
DataTable getStockInDetails(string flowNo);
|
|||
|
[OperationContract]
|
|||
|
int finishUpShelfItem(string orderNo, int id, decimal count, string locationId,string reason, int operId, string token);
|
|||
|
// -------------------stock OUT request begin --------------------------------------------------------------------------------------------------
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 取待复核订单列表
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getBatchPickOrders4Valid();
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 取待复核订单明细
|
|||
|
/// </summary>
|
|||
|
/// <param name="orderNo"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getPickOrderDetails(string orderNo);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// get batch pick detail by port record id
|
|||
|
/// </summary>
|
|||
|
/// <param name="Id"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable getPickDetail(int Id);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 手持捡完一个货位,更新状态
|
|||
|
/// 检测到出库单所有整货都已经分拣完毕后将更新订单明细及订单 batchPickStatus,status
|
|||
|
/// </summary>
|
|||
|
/// <param name="pickOrderNo"></param>
|
|||
|
/// <param name="id"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool finishPickItem(string flowNo,string waveNo, string pickOrderNo, int id, decimal pickCount, int operId, string token);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 手持复核一个货位,更新状态
|
|||
|
/// 检测到出库单所有整货都已经复核完毕后将更新订单明细及订单 batchPickStatus,status
|
|||
|
/// </summary>
|
|||
|
/// <param name="pickOrderNo"></param>
|
|||
|
/// <param name="id"></param>
|
|||
|
/// <param name="operId"></param>
|
|||
|
/// <param name="token"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
bool finishBatchValidateItem(string pickOrderNo, int id, int operId, int checkBy2, string token);
|
|||
|
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int batchPickCount4Valid(string pickOrderNo);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 当天待分拣补货明细
|
|||
|
/// </summary>
|
|||
|
/// <param name="pickOrderNo"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable repTodayDetails4Pick(int userId=0);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 待上架补货任务
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
DataTable repInDetailsByFlowNo(string flowNo,int operId,string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int regSeedsPlate(string plateId, int partion);
|
|||
|
[OperationContract]
|
|||
|
DataTable getPlatePickList(string plateId, int partion);
|
|||
|
|
|||
|
//获取出库下架任务
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTaskAssigned(int operId, int partion , int lineId , bool batchOnly ,int orderType);
|
|||
|
[OperationContract]
|
|||
|
DataTable taskAssign(int partion, int lineId, bool batchOnly, int orderType, int operId, string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int taskResign(int partion, int lineId, bool batchOnly, int orderType, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
// ------------------TMS begin --------------------------------------------------------------------------------------------------
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 有打包零货待装车的运输单
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTransRequestsWithBulks();
|
|||
|
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 待装车的运输单打包零货列表
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTransRequestsBulks(string transNo);
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
///从零库集货区取走零货打包
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
bool pickBulks(string tranNo, int stockId,int operId, string token);
|
|||
|
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 待装车的运输单打包零货列表
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTransRequestsByStatus(int status);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 运输单拣货单列表
|
|||
|
/// </summary>
|
|||
|
/// <returns></returns>
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTransRequestsDetail(string transNo,int status);
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 装车
|
|||
|
/// </summary>
|
|||
|
/// <param name="transNo"></param>
|
|||
|
/// <param name="pickOrderNo"></param>
|
|||
|
/// <param name="tranDetailId"></param>
|
|||
|
/// <returns></returns>
|
|||
|
[OperationContract]
|
|||
|
string loadTrucks(string transNo, string pickOrderNo, int tranDetailId, int operId, string token);
|
|||
|
|
|||
|
//-------------------------box reg---------------------------------
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
int regPartBox(int partion, string boxId, int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getPartionRequests(int partion, int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getLightPartions(int operId, string token);
|
|||
|
|
|||
|
|
|||
|
|
|||
|
//------------------------------------------------task centers-------------------------------------
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
DataTable getTasks(int status,int partion,int emId,int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getTaskDetails(string tastNo, int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getFlowDetails(string flowNo, int operId, string token);
|
|||
|
[OperationContract]
|
|||
|
DataTable getTaskInfo(string taskNo, int operId, string token);
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
enumFlowTaskResult startTask(string taskNo, int operId, string token);
|
|||
|
|
|||
|
|
|||
|
|
|||
|
//---亮灯
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
string getLightService();
|
|||
|
|
|||
|
|
|||
|
[OperationContract]
|
|||
|
[WebInvoke(
|
|||
|
Method = "GET",
|
|||
|
RequestFormat = WebMessageFormat.Json,
|
|||
|
ResponseFormat = WebMessageFormat.Json,
|
|||
|
UriTemplate = "getLabels"
|
|||
|
)]
|
|||
|
List<ELabel> getLabels();
|
|||
|
|
|||
|
}
|
|||
|
|
|||
|
|
|||
|
[DataContract]
|
|||
|
public class ELabel
|
|||
|
{
|
|||
|
[DataMember]
|
|||
|
public int labelId { get; set; }
|
|||
|
[DataMember]
|
|||
|
public int address { get; set; }
|
|||
|
[DataMember]
|
|||
|
public int count { get; set; }
|
|||
|
[DataMember]
|
|||
|
public int color { get; set; }
|
|||
|
[DataMember]
|
|||
|
public int port { get; set; }
|
|||
|
[DataMember]
|
|||
|
public int orderNo { get; set; }
|
|||
|
|
|||
|
}
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
|
|||
|
}
|