개정판 989966d4
issue #0000
프로젝트 등록 유효성 추가
ID2 프로젝트 목록에서 Name 없는 프로젝트는 제외
Change-Id: I3c4a3d5fef2864a47a46d613bf6e2378d6ea9f8e
ID2.Manager/ID2.Manager.Dapper/Repository/ID2Repository.cs | ||
---|---|---|
17 | 17 |
public IEnumerable<ID2ProjectInfo> GetID2ProjectList() |
18 | 18 |
{ |
19 | 19 |
string query = $@" |
20 |
SELECT * FROM Projects ORDER BY Id"; |
|
20 |
SELECT * FROM Projects WHERE ifnull(Name, '') <> '' ORDER BY Id";
|
|
21 | 21 |
return Query<ID2ProjectInfo>(query); |
22 | 22 |
} |
23 | 23 |
} |
ID2.Manager/ID2.Manager/Forms/SetupProject.cs | ||
---|---|---|
113 | 113 |
|
114 | 114 |
private void RadButtonSave_Click(object sender, EventArgs e) |
115 | 115 |
{ |
116 |
//Error Message |
|
117 |
StringBuilder sbErrMsg = new StringBuilder(); |
|
118 |
if (string.IsNullOrEmpty(this.radTextBoxProjectCode.Text.Trim())) |
|
119 |
{ |
|
120 |
sbErrMsg.Append("Please, enter the project code."); |
|
121 |
this.radTextBoxProjectCode.Focus(); |
|
122 |
} |
|
123 |
else if (string.IsNullOrEmpty(this.radTextBoxProjectName.Text.Trim())) |
|
124 |
{ |
|
125 |
sbErrMsg.Append("Please, enter the project name."); |
|
126 |
this.radTextBoxProjectName.Focus(); |
|
127 |
} |
|
128 |
|
|
129 |
if (sbErrMsg.Length > 0) |
|
130 |
{ |
|
131 |
string errMsg = sbErrMsg.ToString(); |
|
132 |
if (errMsg.Length > 100) |
|
133 |
{ |
|
134 |
errMsg = $"{errMsg.Substring(0, 100)}..."; |
|
135 |
} |
|
136 |
|
|
137 |
RadMessageBox.Show($"{errMsg}", "Information", MessageBoxButtons.OK, RadMessageIcon.Info); |
|
138 |
return; |
|
139 |
} |
|
140 |
|
|
116 | 141 |
var id2prjs = this.radGridViewID2Project.Rows.Where(x => |
117 | 142 |
{ |
118 | 143 |
var id2 = x.DataBoundItem as ID2ProjectInfo; |
내보내기 Unified diff