Commit 43386d78 authored by liudong1993's avatar liudong1993

1

parent 224e2f15
......@@ -88,6 +88,10 @@ namespace Mall.Common.API
/// </summary>
public int ERPEmpId { get; set; }
/// <summary>
/// erp公司id
/// </summary>
public int ERPBranchId { get; set; }
/// <summary>
/// erp集团id
/// </summary>
public int ERPGroupId { get; set; }
......
......@@ -4,4 +4,11 @@
<TargetFramework>netcoreapp3.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\Mall.CacheManager\Mall.CacheManager.csproj" />
<ProjectReference Include="..\Mall.Common\Mall.Common.csproj" />
<ProjectReference Include="..\Mall.Model\Mall.Model.csproj" />
<ProjectReference Include="..\Mall.Repository\Mall.Repository.csproj" />
</ItemGroup>
</Project>
......@@ -94,6 +94,19 @@ namespace Mall.Module.Property
return list;
}
/// <summary>
/// 同步商品信息至资产物料
/// </summary>
/// <param name="wareHouseId"></param>
/// <param name="categoryIdList"></param>
/// <param name="eRPEmpId"></param>
/// <param name="eRPGroupId"></param>
/// <returns></returns>
public bool SetSyncGoodsToMaterial(int wareHouseId, List<int> categoryIdList, int eRPEmpId, int eRPGroupId)
{
throw new NotImplementedException();
}
#endregion
}
}
......@@ -60,12 +60,50 @@ namespace Mall.WebApi.Controllers.MallBase
x.SuppliesModel,
x.SuppliesNum,
x.InventoryNum,
UpdateBy = CacheManager.User.UserReidsCache.GetEmployee(x.UpdateBy)?.EmName ?? "",
//UpdateBy = CacheManager.User.UserReidsCache.GetEmployee(x.UpdateBy)?.EmName ?? "",
UpdateDate = x.UpdateDate.Value.ToString("yyyy-MM-dd")
});
return ApiResult.Success("", pagelist);
}
/// <summary>
/// 同步商品信息至资产耗材
/// </summary>
/// <returns></returns>
[HttpPost]
public ApiResult SetSyncGoodsToMaterial() {
var requestParm = RequestParm;
JObject parms = JObject.Parse(requestParm.msg.ToString());
int WareHouseId = parms.GetInt("WareHouseId", 0);//仓库id
string CategoryIds = parms.GetStringValue("CategoryIds");//同步的商品分类
if (WareHouseId <= 0) {
return ApiResult.ParamIsNull("请传递仓库id");
}
if (string.IsNullOrEmpty(CategoryIds) || CategoryIds == "[]")
{
return ApiResult.ParamIsNull("请传递分类");
}
List<int> categoryIdList = new List<int>();
try
{
categoryIdList = JsonConvert.DeserializeObject<List<int>>(CategoryIds);
}
catch (Exception)
{
return ApiResult.ParamIsNull("分类格式有误");
}
bool flag = propertyModule.SetSyncGoodsToMaterial(WareHouseId, categoryIdList, requestParm.ERPEmpId, requestParm.ERPGroupId);
if (flag)
{
return ApiResult.Success();
}
else {
return ApiResult.Failed();
}
}
#endregion
}
}
\ No newline at end of file
......@@ -22,6 +22,7 @@
<ProjectReference Include="..\Mall.Module.BaseSetUp\Mall.Module.BaseSetUp.csproj" />
<ProjectReference Include="..\Mall.Module.MarketingCenter\Mall.Module.MarketingCenter.csproj" />
<ProjectReference Include="..\Mall.Module.Product\Mall.Module.Product.csproj" />
<ProjectReference Include="..\Mall.Module.Property\Mall.Module.Property.csproj" />
<ProjectReference Include="..\Mall.Module.User\Mall.Module.User.csproj" />
<ProjectReference Include="..\Mall.ThirdCore\Mall.ThirdCore.csproj" />
</ItemGroup>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment