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

10
Controller/Properties/Settings.Designer.cs

@ -62,5 +62,15 @@ namespace CK.SCP.Controller.Properties {
return ((string)(this["CK_SCP_Controller_BomList1_JsonService"])); 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"> <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> <Value Profile="(Default)">http://10.62.144.124:8070/JsonService.asmx</Value>
</Setting> </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> </Settings>
</SettingsFile> </SettingsFile>

19
Controller/SCP_PO_CONTROLLER.cs

@ -2216,7 +2216,7 @@ namespace CK.SCP.Controller
/// <param name="db"></param> /// <param name="db"></param>
/// <param name="p_excel"></param> /// <param name="p_excel"></param>
/// <returns></returns> /// <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>(); List<string> ErrorList = new List<string>();
var _count = db.TA_Appliance.Count(p => p.PartNumber == p_excel. && p.VendID == p_excel.); 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.)); ErrorList.Add(string.Format("零件号码{0}与供应商{1}没有对应的基础信息!", p_excel., p_excel.));
} }
if (_wmsweb)
{
BomList1.JsonService bomVersionRe = new BomList1.JsonService(); BomList1.JsonService bomVersionRe = new BomList1.JsonService();
var _ReturnRelust = bomVersionRe.GetBomVersion(p_excel., p_excel.); var _ReturnRelust = bomVersionRe.GetBomVersion(p_excel., p_excel.);
if (p_excel.BOM版本 != _ReturnRelust) if (p_excel.BOM版本 != _ReturnRelust)
{ {
ErrorList.Add(string.Format("物料号码{0}的BOM版本号填写错误", p_excel.)); 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"); 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) if (price == 0)
{ {
@ -5441,7 +5454,7 @@ namespace CK.SCP.Controller
/// <param name="p_modtype"></param> /// <param name="p_modtype"></param>
/// <param name="IsAutoPublish"></param> /// <param name="IsAutoPublish"></param>
/// <returns></returns> /// <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>(); ResultObject<bool> _ret = new ResultObject<bool>();
try try
@ -5461,7 +5474,7 @@ namespace CK.SCP.Controller
lineError.Add(string.Format("导入的物料号码{0}有重复", p.)); lineError.Add(string.Format("导入的物料号码{0}有重复", p.));
ErrorList = lineError; ErrorList = lineError;
} }
var _ls = CheckExcelMode_Po1(db, p); var _ls = CheckExcelMode_Po1(db, p, _wmsweb);
if (_ls.Count > 0) if (_ls.Count > 0)
{ {
lineError.Add(number.ToString()); 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"> <setting name="CK_SCP_Controller_BomList_JsonService" serializeAs="String">
<value>http://10.62.144.124:8016/JsonService.asmx</value> <value>http://10.62.144.124:8016/JsonService.asmx</value>
</setting> </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> <value>http://192.168.0.228:7602/JsonService.asmx</value>
</setting> </setting>
<setting name="CK_SCP_Controller_BomList1_JsonService" serializeAs="String"> <setting name="CK_SCP_Controller_BomList1_JsonService" serializeAs="String">
<value>http://10.62.144.124:8070/JsonService.asmx</value> <value>http://10.62.144.124:8070/JsonService.asmx</value>
</setting> </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> </CK.SCP.Controller.Properties.Settings>
</applicationSettings> </applicationSettings>
<system.serviceModel> <system.serviceModel>

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

@ -266,7 +266,12 @@ namespace SCP.Views.富维冲压件
_dt = ExcelHelper.GetDataTableOfXlsx(_stream); _dt = ExcelHelper.GetDataTableOfXlsx(_stream);
} }
var list = ConvertHelper.ToList<SCP_PO_EXPORT_IMPORT_MODEL>(ExcelHelper.RemoveEmpty(_dt)).ToList(); 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) 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(); User _entity = new User();
_entity.Name = vendname; _entity.Name = vendname;
_entity.ChineseName = string.IsNullOrEmpty(qadData.NAME1) ? qadData.VENDORNO : qadData.NAME1;
_entity.Remark = qadData.COMMUADDRESS.ToUpper(); _entity.Remark = qadData.COMMUADDRESS.ToUpper();
_entity.Password = PasswordUtil.CreateDbPassword("555555"); _entity.Password = PasswordUtil.CreateDbPassword("555555");
_entity.Email = wmsData.VendId + "@163.com"; _entity.Email = wmsData.VendId + "@163.com";

Loading…
Cancel
Save