Browse Source

添加测试引用 以及生成用户中文赋值

master
qian 9 months ago
parent
commit
26a6ba672f
  1. 24
      Controller/CK.SCP.Controller.csproj
  2. 10
      Controller/Properties/Settings.Designer.cs
  3. 3
      Controller/Properties/Settings.settings
  4. 27
      Controller/SCP_PO_CONTROLLER.cs
  5. 6
      Controller/Web References/BomVersion2/JsonService.disco
  6. 2466
      Controller/Web References/BomVersion2/JsonService.wsdl
  7. 1973
      Controller/Web References/BomVersion2/Reference.cs
  8. 7
      Controller/Web References/BomVersion2/Reference.map
  9. 6
      Controller/app.config
  10. 7
      SCP/Views/富维冲压件/SCP_PO_EXTEND.aspx.cs
  11. 1
      UniApiGroup/Controller/OdbcApiQadController.cs

24
Controller/CK.SCP.Controller.csproj

@ -135,6 +135,11 @@
<DesignTime>True</DesignTime>
<DependentUpon>Reference.map</DependentUpon>
</Compile>
<Compile Include="Web References\BomVersion2\Reference.cs">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Reference.map</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Models\CK.SCP.Models.csproj">
@ -173,6 +178,11 @@
<Generator>MSDiscoCodeGenerator</Generator>
<LastGenOutput>Reference.cs</LastGenOutput>
</None>
<None Include="Web References\BomVersion2\JsonService.wsdl" />
<None Include="Web References\BomVersion2\Reference.map">
<Generator>MSDiscoCodeGenerator</Generator>
<LastGenOutput>Reference.cs</LastGenOutput>
</None>
</ItemGroup>
<ItemGroup>
<WCFMetadata Include="Connected Services\" />
@ -181,6 +191,17 @@
<WebReferences Include="Web References\" />
</ItemGroup>
<ItemGroup>
<WebReferenceUrl Include="http://10.62.144.124:8016/JsonService.asmx">
<UrlBehavior>Dynamic</UrlBehavior>
<RelPath>Web References\BomVersion2\</RelPath>
<UpdateFromURL>http://10.62.144.124:8016/JsonService.asmx</UpdateFromURL>
<ServiceLocationURL>
</ServiceLocationURL>
<CachedDynamicPropName>
</CachedDynamicPropName>
<CachedAppSettingsObjectName>Settings</CachedAppSettingsObjectName>
<CachedSettingsPropName>CK_SCP_Controller_WebReference_JsonService</CachedSettingsPropName>
</WebReferenceUrl>
<WebReferenceUrl Include="http://10.62.144.124:8016/JsonService.asmx%3f">
<UrlBehavior>Dynamic</UrlBehavior>
<RelPath>Web References\BomList\</RelPath>
@ -238,5 +259,8 @@
<ItemGroup>
<None Include="Web References\BomList1\JsonService.disco" />
</ItemGroup>
<ItemGroup>
<None Include="Web References\BomVersion2\JsonService.disco" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>

10
Controller/Properties/Settings.Designer.cs

@ -62,5 +62,15 @@ namespace CK.SCP.Controller.Properties {
return ((string)(this["CK_SCP_Controller_BomList1_JsonService"]));
}
}
[global::System.Configuration.ApplicationScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.SpecialSettingAttribute(global::System.Configuration.SpecialSetting.WebServiceUrl)]
[global::System.Configuration.DefaultSettingValueAttribute("http://10.62.144.124:8016/JsonService.asmx")]
public string CK_SCP_Controller_WebReference_JsonService {
get {
return ((string)(this["CK_SCP_Controller_WebReference_JsonService"]));
}
}
}
}

3
Controller/Properties/Settings.settings

@ -14,5 +14,8 @@
<Setting Name="CK_SCP_Controller_BomList1_JsonService" Type="(Web Service URL)" Scope="Application">
<Value Profile="(Default)">http://10.62.144.124:8070/JsonService.asmx</Value>
</Setting>
<Setting Name="CK_SCP_Controller_WebReference_JsonService" Type="(Web Service URL)" Scope="Application">
<Value Profile="(Default)">http://10.62.144.124:8016/JsonService.asmx</Value>
</Setting>
</Settings>
</SettingsFile>

27
Controller/SCP_PO_CONTROLLER.cs

@ -2216,7 +2216,7 @@ namespace CK.SCP.Controller
/// <param name="db"></param>
/// <param name="p_excel"></param>
/// <returns></returns>
private static List<string> CheckExcelMode_Po1(ScpEntities db, SCP_PO_EXPORT_IMPORT_MODEL p_excel)
private static List<string> CheckExcelMode_Po1(ScpEntities db, SCP_PO_EXPORT_IMPORT_MODEL p_excel , bool _wmsweb)
{
List<string> ErrorList = new List<string>();
var _count = db.TA_Appliance.Count(p => p.PartNumber == p_excel. && p.VendID == p_excel.);
@ -2224,12 +2224,25 @@ namespace CK.SCP.Controller
{
ErrorList.Add(string.Format("零件号码{0}与供应商{1}没有对应的基础信息!", p_excel., p_excel.));
}
BomList1.JsonService bomVersionRe = new BomList1.JsonService();
var _ReturnRelust = bomVersionRe.GetBomVersion(p_excel., p_excel.);
if (p_excel.BOM版本 != _ReturnRelust)
if (_wmsweb)
{
ErrorList.Add(string.Format("物料号码{0}的BOM版本号填写错误", p_excel.));
BomList1.JsonService bomVersionRe = new BomList1.JsonService();
var _ReturnRelust = bomVersionRe.GetBomVersion(p_excel., p_excel.);
if (p_excel.BOM版本 != _ReturnRelust)
{
ErrorList.Add(string.Format("物料号码{0}的BOM版本号填写错误", p_excel.));
}
}
else
{
BomList.JsonService bomVersionRe = new BomList.JsonService();
var _ReturnRelust = bomVersionRe.GetBomVersion(p_excel., p_excel.);
if (p_excel.BOM版本 != _ReturnRelust)
{
ErrorList.Add(string.Format("物料号码{0}的BOM版本号填写错误", p_excel.));
}
}
var price = db.TB_NetPrice.Count(p => p.PartCode == p_excel. && p.VendId == p_excel. && p.EndTime > DateTime.Now && p.StartTime <DateTime.Now && p.Extend3 != "D");
if (price == 0)
{
@ -5441,7 +5454,7 @@ namespace CK.SCP.Controller
/// <param name="p_modtype"></param>
/// <param name="IsAutoPublish"></param>
/// <returns></returns>
public static ResultObject<bool> EXCEL_PO_MOD1(DataTable p_order_list1, List<SCP_PO_EXPORT_IMPORT_MODEL> p_order_list, string site, string p_creator, DateTime p_time, PoState p_modtype, string SubSite, string p_chineseName, string p_buyerPhone)
public static ResultObject<bool> EXCEL_PO_MOD1(DataTable p_order_list1, List<SCP_PO_EXPORT_IMPORT_MODEL> p_order_list, string site, string p_creator, DateTime p_time, PoState p_modtype, string SubSite, string p_chineseName, string p_buyerPhone, bool _wmsweb)
{
ResultObject<bool> _ret = new ResultObject<bool>();
try
@ -5461,7 +5474,7 @@ namespace CK.SCP.Controller
lineError.Add(string.Format("导入的物料号码{0}有重复", p.));
ErrorList = lineError;
}
var _ls = CheckExcelMode_Po1(db, p);
var _ls = CheckExcelMode_Po1(db, p, _wmsweb);
if (_ls.Count > 0)
{
lineError.Add(number.ToString());

6
Controller/Web References/BomVersion2/JsonService.disco

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<discovery xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/disco/">
<contractRef ref="http://10.62.144.124:8016/JsonService.asmx?wsdl" docRef="http://10.62.144.124:8016/JsonService.asmx" xmlns="http://schemas.xmlsoap.org/disco/scl/" />
<soap address="http://10.62.144.124:8016/JsonService.asmx" xmlns:q1="http://tempuri.org/" binding="q1:JsonServiceSoap" xmlns="http://schemas.xmlsoap.org/disco/soap/" />
<soap address="http://10.62.144.124:8016/JsonService.asmx" xmlns:q2="http://tempuri.org/" binding="q2:JsonServiceSoap12" xmlns="http://schemas.xmlsoap.org/disco/soap/" />
</discovery>

2466
Controller/Web References/BomVersion2/JsonService.wsdl

File diff suppressed because it is too large

1973
Controller/Web References/BomVersion2/Reference.cs

File diff suppressed because it is too large

7
Controller/Web References/BomVersion2/Reference.map

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<DiscoveryClientResultsFile xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Results>
<DiscoveryClientResult referenceType="System.Web.Services.Discovery.ContractReference" url="http://10.62.144.124:8016/JsonService.asmx?wsdl" filename="JsonService.wsdl" />
<DiscoveryClientResult referenceType="System.Web.Services.Discovery.DiscoveryDocumentReference" url="http://10.62.144.124:8016/JsonService.asmx?disco" filename="JsonService.disco" />
</Results>
</DiscoveryClientResultsFile>

6
Controller/app.config

@ -37,12 +37,16 @@
<setting name="CK_SCP_Controller_BomList_JsonService" serializeAs="String">
<value>http://10.62.144.124:8016/JsonService.asmx</value>
</setting>
<setting name="CK_SCP_Controller_BomListcompany_JsonService" serializeAs="String">
<setting name="CK_SCP_Controller_BomListcompany_JsonService"
serializeAs="String">
<value>http://192.168.0.228:7602/JsonService.asmx</value>
</setting>
<setting name="CK_SCP_Controller_BomList1_JsonService" serializeAs="String">
<value>http://10.62.144.124:8070/JsonService.asmx</value>
</setting>
<setting name="CK_SCP_Controller_WebReference_JsonService" serializeAs="String">
<value>http://10.62.144.124:8016/JsonService.asmx</value>
</setting>
</CK.SCP.Controller.Properties.Settings>
</applicationSettings>
<system.serviceModel>

7
SCP/Views/富维冲压件/SCP_PO_EXTEND.aspx.cs

@ -266,7 +266,12 @@ namespace SCP.Views.富维冲压件
_dt = ExcelHelper.GetDataTableOfXlsx(_stream);
}
var list = ConvertHelper.ToList<SCP_PO_EXPORT_IMPORT_MODEL>(ExcelHelper.RemoveEmpty(_dt)).ToList();
var ret = SCP_PO_CONTROLLER.EXCEL_PO_MOD1(_dt, list,CurrentUser.FactoryList[0], CurrentUser.Name, DateTime.Now, PoState.Open, CurrentUser.SubSiteList[0], CurrentUser.ChineseName, CurrentUser.CellPhone);
bool _wmsweb = true;
if (CurrentUser.ConfigList.ContainsKey("调用WMS测试接口"))
{
_wmsweb = false;
}
var ret = SCP_PO_CONTROLLER.EXCEL_PO_MOD1(_dt, list,CurrentUser.FactoryList[0], CurrentUser.Name, DateTime.Now, PoState.Open, CurrentUser.SubSiteList[0], CurrentUser.ChineseName, CurrentUser.CellPhone, _wmsweb);
if (ret.State == ReturnStatus.Succeed && ret.Result == true)
{

1
UniApiGroup/Controller/OdbcApiQadController.cs

@ -1451,6 +1451,7 @@ namespace CK.SCP.GrupUniApi.Controller
{
User _entity = new User();
_entity.Name = vendname;
_entity.ChineseName = string.IsNullOrEmpty(qadData.NAME1) ? qadData.VENDORNO : qadData.NAME1;
_entity.Remark = qadData.COMMUADDRESS.ToUpper();
_entity.Password = PasswordUtil.CreateDbPassword("555555");
_entity.Email = wmsData.VendId + "@163.com";

Loading…
Cancel
Save