Browse Source

tiaojiao

master
学 赵 4 years ago
parent
commit
5198af2988
  1. 14
      Controller/SCP_QUALITY_CONTROLLER.cs
  2. 6
      Models/Enums/SCP_ENUM.cs.cs
  3. 13
      SCP/Admin/default.aspx.cs
  4. 2
      SCP/Global.asax.cs
  5. 2
      SCP/Properties/PublishProfiles/COM.pubxml
  6. 9
      SCP/Views/SupplierData/SCP_ASN_CREATE.aspx.cs
  7. 45
      SCP/Views/SupplierData/SCP_CLAIM.aspx
  8. 111
      SCP/Views/SupplierData/SCP_CLAIM.aspx.cs
  9. 27
      SCP/Views/SupplierData/SCP_CLAIM.aspx.designer.cs
  10. 15
      UniApiGroup/Controller/OdbcApiScpController.cs
  11. 4
      UniApiGroup/Controller/OdbcApiWmsController.cs

14
Controller/SCP_QUALITY_CONTROLLER.cs

@ -635,10 +635,10 @@ namespace CK.SCP.Controller
{
q = q.Where(p => p_entity.EndTime.Value >= p.ReviewTime);
}
if (p_entity.State != 3)
{
q = q.Where(p => p.State == p_entity.State);
}
//if (p_entity.State != 3)
//{
// q = q.Where(p => p.State == p_entity.State);
//}
if (p_entity.UserInVendIds != null && p_entity.UserInVendIds.Count > 0)
{
q = q.Where(p => p_entity.UserInVendIds.Contains(p.VendId));
@ -647,6 +647,12 @@ namespace CK.SCP.Controller
{
q = q.Where(p => p_entity.UserInAddress.Contains(p.Domain));
}
if (p_entity.BillStateList != null && p_entity.BillStateList.Count > 0)
{
q = q.Where(p => p_entity.BillStateList.Contains(p.State.Value));
}
_ret.State = ReturnStatus.Succeed;
_ret.Result = q;
p_action(_ret);

6
Models/Enums/SCP_ENUM.cs.cs

@ -18,10 +18,12 @@ namespace CK.SCP.Models.Enums
public enum REVIEW_STATE
{
[Description("打开")]
[Description("未审核")]
OPEN = 0,
[Description("关闭")]
[Description("已审核")]
CLOSE = -1,
[Description("已作废")]
DELETE= -2,
}

13
SCP/Admin/default.aspx.cs

@ -52,6 +52,19 @@ namespace SCP.admin
//同时发给自己的信息里,只能看到供应商的名称是自己名字,不能有其它供应商名字
if (CurrentUser.RoleList.Contains("供应商") && !CurrentUser.RoleList.Contains("采购人员") && !CurrentUser.RoleList.Contains("计划人员") )
{
if (CurrentUser.UsedDomain == "BJINTIER")
{
if (!string.IsNullOrEmpty(_info.SupplierCode))
{
SCP_INFO_CONTROLLER.Get_V_INFO_List(_info, (ret) =>
{
if (ret.State == ReturnStatus.Succeed)
{
p_action(ret.Result);
}
});
}
}
//string name = GetIdentityName();
//User modelUsers = DB.Users.FirstOrDefault(p => p.Name == name);

2
SCP/Global.asax.cs

@ -37,7 +37,7 @@ namespace SCP
if (context != null)
{
context.Dispose();
Alert.Show("gg");
}
}

2
SCP/Properties/PublishProfiles/COM.pubxml

@ -11,7 +11,7 @@
<SiteUrlToLaunchAfterPublish />
<LaunchSiteAfterPublish>True</LaunchSiteAfterPublish>
<ExcludeApp_Data>False</ExcludeApp_Data>
<publishUrl>http://localhost/SCP1</publishUrl>
<publishUrl>D:\SCP20201106</publishUrl>
<DeleteExistingFiles>False</DeleteExistingFiles>
<PrecompileBeforePublish>True</PrecompileBeforePublish>
<EnableUpdateable>True</EnableUpdateable>

9
SCP/Views/SupplierData/SCP_ASN_CREATE.aspx.cs

@ -99,8 +99,6 @@ namespace SCP.SupplierData
}
public void BindDetail(bool p_state=false)
{
SearchV_TB_ASK_DETAILData((ret) => {
Grid_V_TB_ASK_DETAIL.RecordCount = ret.Count();
var list = SortAndPage<V_TB_ASK_DETAIL>(ret, Grid_V_TB_ASK_DETAIL);
@ -125,9 +123,7 @@ namespace SCP.SupplierData
p.TempQty = 0;
}
}
);
Grid_V_TB_ASK_DETAIL.DataSource = _ls;
Grid_V_TB_ASK_DETAIL.DataBind();
if (_notifyList.Count > 0)
@ -139,10 +135,6 @@ namespace SCP.SupplierData
});
}
private void IsBatch(string batch)
{
try
@ -197,7 +189,6 @@ namespace SCP.SupplierData
for (int i = 0, count = Grid_V_TB_ASK_DETAIL.Rows.Count; i < count; i++)
{
V_TB_ASK_DETAIL _entity = new V_TB_ASK_DETAIL();
object[] rowDataKeys = Grid_V_TB_ASK_DETAIL.DataKeys[i];
_entity.UID = ConvertHelper.To<Int32>(rowDataKeys[0]);

45
SCP/Views/SupplierData/SCP_CLAIM.aspx

@ -31,6 +31,10 @@
<f:Button ID="btnSave" runat="server" Text="修改评审单" OnClick="btnSave_Click" Icon="BasketEdit">
</f:Button>
<f:Button ID="btnDelete" runat="server" Text="作废审批单" OnClick="btnDelete_Click" Icon="Delete" OnClientClick="if(!confirm('是否要将剩余零件,全部生成到发货单,请确认标包数量是否准确,发货数量必须与物料实际数量一致?'))return false;" >
</f:Button>
</Items>
</f:Toolbar>
@ -46,29 +50,8 @@
<f:TextBox runat = "server" Label = "项目编号" EmptyText = "" ID = "TXT_ProjectId" />
<f:TextBox runat = "server" Label = "物料编码" EmptyText = "" ID = "TXT_PartCode" />
<f:DropDownList runat="server" ID="DDL_State" Label="状态">
<f:ListItem Text="-" Value="3"/>
<f:ListItem Text="未索赔" Value="0" />
<f:ListItem Text="已索赔" Value="-1" />
<f:ListItem Text="已开票" Value="4" />
</f:DropDownList>
<%-- <f:DropDownList Hidden="true" ID="DDL_EnumReviewSite" Label="评审单位置" runat="server" >
<f:ListItem Text="第三方仓库" Value="2"/>
<f:ListItem Text="客户处" Value="1" />
<f:ListItem Text="供应商(退货)" Value="1" />
<f:ListItem Text="供应商索赔(过程&客退)" Value="1" />
</f:DropDownList>
<f:NumberBox Label="索赔金额开始" ID="NB_ClaimAmoun_Begin" runat="server" NoDecimal="false" NoNegative="True" Required="True" EmptyText="" />
<f:NumberBox Label="至" ID="NB_ClaimAmoun_End" runat="server" NoDecimal="false" NoNegative="True" Required="True" EmptyText="" />
<f:TextBox runat = "server" Label = "" EmptyText = "" ID = "TXT_BadCouse" Required = "true" ShowRedStar = "true" />
<f:TextBox runat = "server" Label = "" EmptyText = "" ID = "TXT_ReviewResult" Required = "true" ShowRedStar = "true" />
<f:TextBox runat = "server" Label = "" EmptyText = "" ID = "TXT_UltimateName" Required = "true" ShowRedStar = "true" />
<f:NumberBox Label="" ID="NB_ClaimAmount" runat="server" NoDecimal="false" NoNegative="True" Required="True" EmptyText="" ShowRedStar="True" />
<f:TextBox runat = "server" Label = "" EmptyText = "" ID = "TXT_OperName" Required = "true" ShowRedStar = "true" />
<f:DatePicker runat="server" Required ="true" DateFormatString="yyyy-MM-dd" Label="" EmptyText="请选择日期" ID="DP_BillDate" ShowRedStar = "True"/>
<f:DatePicker runat="server" Required ="true" DateFormatString="yyyy-MM-dd" Label="" EmptyText="请选择日期" ID="DP_CreateTime" ShowRedStar = "True"/>
<f:DatePicker runat="server" Required ="true" DateFormatString="yyyy-MM-dd" Label="" EmptyText="请选择日期" ID="DP_ReviewTime" ShowRedStar = "True"/> --%>
<f:DropDownList ID="ddl_Vender" runat="server" Label="供应商" EnableEdit="true"></f:DropDownList>
</Items>
</f:FormRow>
@ -77,14 +60,26 @@
<f:TextBox runat = "server" Label = "操作人" EmptyText = "" ID = "TXT_OperName" />
<f:TextBox runat = "server" Label = "条码" EmptyText = "" ID = "TXT_BarCode" />
<f:TextBox runat = "server" Label = "批次" EmptyText = "" ID = "TXT_Batch" />
<f:DropDownList ID="ddl_Vender" runat="server" Label="供应商" EnableEdit="true"></f:DropDownList>
<f:TextBox runat = "server" Label = "最终处理部门" EmptyText = "" ID = "TXT_UltimateDepart" />
</Items>
</f:FormRow>
<f:FormRow >
<Items>
<f:DatePicker runat="server" Label="索赔日期" ID="dp_BeginDate"></f:DatePicker>
<f:DatePicker runat="server" Label="至" ID="dp_EndDate"></f:DatePicker>
<f:TextBox runat = "server" Label = "最终处理部门" EmptyText = "" ID = "TXT_UltimateDepart" />
<f:CheckBoxList runat="server" ID="ckb" Label="状态">
<f:CheckItem Text="未索赔" Value="0" Selected="True" />
<f:CheckItem Text="已索赔" Value="-1" Selected="True" />
<f:CheckItem Text="已开票" Value="4" Selected="True" />
<f:CheckItem Text="已作废" Value="-2" Selected="false"/>
<%-- <f:CheckItem Text="供应商申请" Value="1" Selected="True" />
<f:CheckItem Text="采购审核退回" Value="2" Selected="True" />
<f:CheckItem Text="采购审核通过" Value="3" Selected="True" />
<f:CheckItem Text="发票寄出" Value="4" Selected="True" />
<f:CheckItem Text="财务收票" Value="5" Selected="True" />
<f:CheckItem Text="财务手工收票" Value="8" Selected="True" /> --%>
</f:CheckBoxList>
<f:Button runat="server" ID="btnQuery" Text="查询" OnClick="btnQuery_Click"></f:Button>
</Items>
</f:FormRow>

111
SCP/Views/SupplierData/SCP_CLAIM.aspx.cs

@ -46,9 +46,9 @@ namespace SCP.Views.SupplierData
public void Search(Action<IQueryable<V_TM_HYANTOLIN_REVIEW>> p_action)
{
V_TM_HYANTOLIN_REVIEW _entity = new V_TM_HYANTOLIN_REVIEW();
_entity.State = 0;
_entity.ReviewBillNum = TXT_ReviewBillNum.Text;
_entity.State = int.Parse(DDL_State.SelectedValue);
_entity.BillStateList = GetStateList();
_entity.BarCode = TXT_BarCode.Text;
_entity.PartCode = TXT_PartCode.Text;
_entity.Batch = TXT_Batch.Text;
@ -83,62 +83,19 @@ namespace SCP.Views.SupplierData
}
});
}
private List<int> GetStateList()
{
List<int> lsValue = new List<int>();
string[] values = ckb.SelectedValueArray;
foreach(var itm in values)
{
lsValue.Add(int.Parse(itm));
}
return lsValue;
}
protected void btnOutput_Click(object sender, EventArgs e)
{
//DataSet _ds = new DataSet();
//int[] _selections = Grid_TM_HYANTOLIN_REVIEW.SelectedRowIndexArray;
//List<V_TM_HYANTOLIN_REVIEW> _list = new List<V_TM_HYANTOLIN_REVIEW>();
//V_TM_HYANTOLIN_REVIEW _entity = new V_TM_HYANTOLIN_REVIEW();
//for (int i = 0, count = Grid_TM_HYANTOLIN_REVIEW.Rows.Count; i < count; i++)
//{
// if (_selections.Contains(i))
// {
// GridRow row = Grid_TM_HYANTOLIN_REVIEW.Rows[i];
// object[] rowDataKeys = Grid_TM_HYANTOLIN_REVIEW.DataKeys[i];
// V_TM_HYANTOLIN_REVIEW _review = new V_TM_HYANTOLIN_REVIEW();
// _review.ReviewBillNum = rowDataKeys[3] as string;
// _review.RelationReviewNo = rowDataKeys[4] as string;
// _review.BarCode = rowDataKeys[7] as string;
// _review.PartCode = rowDataKeys[8] as string;
// _review.Batch = rowDataKeys[9] as string;
// _review.ProjectId = rowDataKeys[10] as string;
// _review.Qty = ConvertHelper.To<decimal>(rowDataKeys[11]);
// _review.BadCouse = rowDataKeys[12] as string;
// _review.ReviewResult = rowDataKeys[13] as string;
// _review.UltimateDepart = rowDataKeys[14] as string;
// _review.UltimateName = rowDataKeys[15] as string;
// _review.ClaimAmount = ConvertHelper.To<decimal>(rowDataKeys[16]);
// //_review.OperName = rowDataKeys[17] as string;
// //_review.BillDate = ConvertHelper.To<DateTime?>(rowDataKeys[18]);
// //_review.CreateTime = ConvertHelper.To<DateTime?>(rowDataKeys[19]);
// //_review.ReviewTime = ConvertHelper.To<DateTime?>(rowDataKeys[20]);
// //_review.VendId = rowDataKeys[23] as string;
// //_review.VendName = rowDataKeys[24] as string;
// //_review.Currency = rowDataKeys[25] as string;
// //_review.Unit = rowDataKeys[26] as string;
// //_review.PartDesc = rowDataKeys[27] as string;
// _list.Add(_review);
// //UID,Guid,State,ReviewBillNum,RelationReviewNo,
// //ReviewType,ReviewSite,BarCode,PartCode,Batch,ProjectId,Qty,BadCouse,ReviewResult,
// //UltimateDepart,UltimateName,ClaimAmount,OperName,BillDate,CreateTime,ReviewTime
// }
//}
//if (_list.Count > 0)
//{
// _entity.VendName = _list[0].VendName;
//}
//var _dt = ConvertHelper.ToDataTable(_list);
//_ds.Tables.Add(_dt);
//string str = JSONReportData.FromDataSet(_ds);
//var js = string.Format("openPostWindow('{0}',{1},'winOpen')", "../../Handlers/GenerateReport.ashx?report=ClaimBill&data=101&type=pdf&filename=ClaimBill.grf&open=", str);
//PageContext.RegisterStartupScript(js);
Search((rs) =>
{
@ -147,6 +104,9 @@ namespace SCP.Views.SupplierData
switch (p.State)
{
case -2:
p.UltimateDepart = "已作废";
break;
case -1:
p.UltimateDepart = "已索赔";
break;
@ -177,16 +137,12 @@ namespace SCP.Views.SupplierData
break;
case 4:
p.Domain= "发票寄出";
break;
case 5:
p.Domain= "财务收票";
break;
case 8:
p.Domain= "财务手工收票";
break;
case 6:
p.Domain = "财务退回";
@ -252,12 +208,15 @@ namespace SCP.Views.SupplierData
}
}
if (_ls.Count > 0)
{
var ret = SCP_QUALITY_CONTROLLER.Save_TM_HYANTOLIN_REVIEW(_ls, REVIEW_STATE.CLOSE);
if (ret.State == ReturnStatus.Succeed)
{
Bind();
}
}
}
protected void btnUnAccept_Click(object sender, EventArgs e)
{
@ -366,6 +325,11 @@ namespace SCP.Views.SupplierData
}
switch (itm.State)
{
case -2:
_label1.Text = "已报废";
_label1.ForeColor = Color.Red;
break;
case -1:
_label1.Text = "已索赔";
_label1.ForeColor = Color.DarkBlue;
@ -426,5 +390,34 @@ namespace SCP.Views.SupplierData
}
protected void btnDelete_Click(object sender, EventArgs e)
{
List<int> _ls = new List<int>();
int[] _selections = Grid_TM_HYANTOLIN_REVIEW.SelectedRowIndexArray;
for (int i = 0, count = Grid_TM_HYANTOLIN_REVIEW.Rows.Count; i < count; i++)
{
if (_selections.Contains(i))
{
object[] rowDataKeys = Grid_TM_HYANTOLIN_REVIEW.DataKeys[i];
_ls.Add(int.Parse(rowDataKeys[0].ToString()));
}
}
if (_ls.Count > 0)
{
var ret = SCP_QUALITY_CONTROLLER.Save_TM_HYANTOLIN_REVIEW(_ls, REVIEW_STATE.DELETE);
if (ret.State == ReturnStatus.Succeed)
{
Bind();
}
}
else
{
Alert.Show("请选择操作数据!");
}
}
}
}

27
SCP/Views/SupplierData/SCP_CLAIM.aspx.designer.cs

@ -7,10 +7,12 @@
// </自动生成>
//------------------------------------------------------------------------------
namespace SCP.Views.SupplierData {
namespace SCP.Views.SupplierData
{
public partial class SCP_CLAIM {
public partial class SCP_CLAIM
{
/// <summary>
/// form1 控件。
@ -102,6 +104,15 @@ namespace SCP.Views.SupplierData {
/// </remarks>
protected global::FineUI.Button btnSave;
/// <summary>
/// btnDelete 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUI.Button btnDelete;
/// <summary>
/// extForm1 控件。
/// </summary>
@ -139,13 +150,13 @@ namespace SCP.Views.SupplierData {
protected global::FineUI.TextBox TXT_PartCode;
/// <summary>
/// DDL_State 控件。
/// ddl_Vender 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUI.DropDownList DDL_State;
protected global::FineUI.DropDownList ddl_Vender;
/// <summary>
/// TXT_OperName 控件。
@ -175,13 +186,13 @@ namespace SCP.Views.SupplierData {
protected global::FineUI.TextBox TXT_Batch;
/// <summary>
/// ddl_Vender 控件。
/// TXT_UltimateDepart 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUI.DropDownList ddl_Vender;
protected global::FineUI.TextBox TXT_UltimateDepart;
/// <summary>
/// dp_BeginDate 控件。
@ -202,13 +213,13 @@ namespace SCP.Views.SupplierData {
protected global::FineUI.DatePicker dp_EndDate;
/// <summary>
/// TXT_UltimateDepart 控件。
/// ckb 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUI.TextBox TXT_UltimateDepart;
protected global::FineUI.CheckBoxList ckb;
/// <summary>
/// btnQuery 控件。

15
UniApiGroup/Controller/OdbcApiScpController.cs

@ -19,6 +19,9 @@ namespace CK.SCP.GrupUniApi.Controller
}
private static void PutScpCtrl(UniApiEntities idb, string seq, string tableName, int rowCount,string p_domain,string p_site)
{
var wmsCtrl = new xxscm_ctrl
{
xxscm_seq = seq,
@ -30,7 +33,7 @@ namespace CK.SCP.GrupUniApi.Controller
xxscm_wms = ((int)UniApiState.).ToString(),
xxscm_rmks = "",
xxscm_domain =p_domain,
xxscm_site = p_site,
xxscm_site = !string.IsNullOrEmpty(p_site)?p_site:p_domain,
//xxscm_create_time = DateTime.Now,
};
idb.xxscm_ctrl.Add(wmsCtrl);
@ -71,10 +74,20 @@ namespace CK.SCP.GrupUniApi.Controller
seq = CreateSeq(string.IsNullOrEmpty(uni_api.Domain)?uni_api.Site:uni_api.Domain);
}
var tableName = ScmTableName.xxscm_tx_mstr.ToString();
var qadDataList = new List<xxscm_tx_mstr>();
foreach (var wmsData in dataList)
{
if (wmsData.Domain == "BJCIAI")
{
wmsData.Domain = "BJINTIER";
wmsData.Site = "BJCIAI";
}
var qadData = qadDataList.SingleOrDefault(p => p.xxscm_tx_nbr == wmsData.BillNum
&& p.xxscm_tx_domain == wmsData.Site
&& p.xxscm_tx_part == wmsData.PartCode && p.xxscm_tx_batch==wmsData.Batch && p.xxscm_tx_vend_batch== wmsData.VendBatch);

4
UniApiGroup/Controller/OdbcApiWmsController.cs

@ -126,10 +126,6 @@ namespace CK.SCP.GrupUniApi.Controller
}
break;
}
wmsCtrl.xxwms_scm = ((int)UniApiState.³É¹¦).ToString();
EntitiesFactory.SaveDb(wdb);

Loading…
Cancel
Save