|
|
@@ -273,7 +273,8 @@ namespace Dongke.IBOSS.PRD.Client.SystemModule
|
|
|
if ((this.txtGoodsCode.Text != this._thisGoodsEntity.GoodsCode && _formStatus == Constant.FormMode.Edit)
|
|
|
|| this._formStatus == Constant.FormMode.Add)
|
|
|
{
|
|
|
- if (ValidationCode(this.txtGoodsCode.Text) == false)
|
|
|
+ // 250327 产品编码的回车和空格 去除
|
|
|
+ if (ValidationCode(this.txtGoodsCode.Text.Trim().Replace(" ", "").Replace("\r", "").Replace("\n", "")) == false)
|
|
|
{
|
|
|
MessageBox.Show(string.Format(Messages.MSG_CMN_W006, "产品编码"), this.Text,
|
|
|
MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
|
|
@@ -285,7 +286,8 @@ namespace Dongke.IBOSS.PRD.Client.SystemModule
|
|
|
{
|
|
|
this._thisGoodsEntity = new GoodsEntity();
|
|
|
}
|
|
|
- this._thisGoodsEntity.GoodsCode = this.txtGoodsCode.Text;
|
|
|
+ // 250327 产品编码的回车和空格 去除
|
|
|
+ this._thisGoodsEntity.GoodsCode = this.txtGoodsCode.Text.Trim().Replace(" ", "").Replace("\r", "").Replace("\n", "");
|
|
|
this._thisGoodsEntity.GoodsModel = this.txtGoodsModel.Text;
|
|
|
this._thisGoodsEntity.GoodsName = this.txtGoodsName.Text;
|
|
|
this._thisGoodsEntity.GoodsSpecification = this.txtGoodsSpecification.Text;
|
|
|
@@ -720,7 +722,10 @@ namespace Dongke.IBOSS.PRD.Client.SystemModule
|
|
|
{
|
|
|
ErrorID = 6;
|
|
|
}
|
|
|
- if (this.txtGoodsCode.Text == string.Empty)
|
|
|
+ if (this.txtGoodsCode.Text == string.Empty
|
|
|
+ || String.IsNullOrEmpty(this.txtGoodsCode.Text.Trim())
|
|
|
+ || String.IsNullOrEmpty(this.txtGoodsCode.Text.Trim().Replace(" ","").Replace("\r","").Replace("\n", ""))
|
|
|
+ )
|
|
|
{
|
|
|
ErrorID = 1;
|
|
|
}
|