步步为盈
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
3.4 KiB

using BBWY.Client.Models;
using BBWY.Client.Models.APIModel;
using BBWY.Client.Models.PackTask;
using BBWY.Common.Http;
using BBWY.Common.Models;
using System;
using System.Collections.Generic;
using System.Net.Http;
using System.Text;
namespace BBWY.Client.APIServices.QiKu
{
public class PackUserService : BaseApiService, IDenpendency
{
public PackUserService(RestApiService restApiService, GlobalContext globalContext) : base(restApiService, globalContext)
{
// globalContext.User.Id = 1668426942564536320;
}
public ApiResponse<SearchPackerTaskResponse> SearchPackerTaskV2(PackTaskState? PackTaskState, string WayBillNo = null, string SourceExpressName = null, string departmentName = null, string skuId = null, string taskId = null,
string spuId = null, string orderSn = null,
string ShopName = null,
int pageIndex = 1,
int pageSize = 10,
string SkuTitle = null,
string SpuTitle = null,
PackagingTaskExceptionState? PackagingTaskExceptionState =null
)
{
return SendRequest<SearchPackerTaskResponse>(globalContext.QKApiHost, $"api/PackUser/SearchPackerTaskV2",
new
{
PackTaskState,
WayBillNo,
SourceExpressName,
departmentName,
skuId,
taskId,
spuId,
orderSn,
ShopName,
pageIndex,
pageSize,
SkuTitle,
SpuTitle,
UserId = globalContext.User.Id.ToString(),
PackagingTaskExceptionState
}
, null, HttpMethod.Post);
}
public ApiResponse<object> CompletedPackTask(long TaskId, decimal OneSkuWeight)
{
return SendRequest<object>(globalContext.QKApiHost, $"api/PackUser/CompletedPackTask",
new
{
TaskId,
OneSkuWeight
}
, null, HttpMethod.Post);
}
public ApiResponse<SearchPackerSalaryResponse> SearchPackerSalaryV2(DateTime? StartTime, DateTime? EndTime, int pageIndex = 1,
int pageSize = 10)
{
return SendRequest<SearchPackerSalaryResponse>(globalContext.QKApiHost, $"api/PackUser/SearchPackerSalaryV2",
new
{
UserId = globalContext.User.Id.ToString(),
StartTime,
EndTime,
pageIndex,
pageSize
}
, null, HttpMethod.Post);
}
/// <summary>
/// 获取打包人员列表
/// </summary>
/// <returns></returns>
public ApiResponse<PackUser[]> GetPackMembers()
{
return SendRequest<PackUser[]>(globalContext.QKApiHost, "api/PackUser/GetPackerList", null
, null, HttpMethod.Get);
}
}
}