개정판 c47493ca
pemss 바로가기 기능 추가
Change-Id: I82069f63cb9c8e17ff90a024e633eac0c103bd72
KCOM/ViewModel/RequirementViewModel.cs | ||
---|---|---|
208 | 208 |
|
209 | 209 |
var selectComments = Common.ViewerDataModel.Instance.MarkupControls_USER.Where(x=>iditems.Count(y=> y == x.CommentID) > 0).ToList(); |
210 | 210 |
|
211 |
foreach (var item in selectComments)
|
|
211 |
if (selectComments.Count() > 0)
|
|
212 | 212 |
{ |
213 |
var infoList = Common.ViewerDataModel.Instance.MyMarkupList.Where(f => f.MarkupInfoID == selectComments.First().MarkupInfoID); |
|
213 | 214 |
|
215 |
if (infoList.Count() > 0) |
|
216 |
{ |
|
217 |
Common.ViewerDataModel.Instance.PageBalanceNumber = infoList.First().PageNumber; |
|
218 |
selectComments.First().IsSelected = true; |
|
219 |
GotoMarkup(selectComments); |
|
220 |
|
|
221 |
} |
|
214 | 222 |
} |
215 | 223 |
|
216 | 224 |
//selectedComment |
... | ... | |
227 | 235 |
} |
228 | 236 |
} |
229 | 237 |
|
238 |
private void GotoMarkup(IEnumerable<MarkupToPDF.Common.CommentUserInfo> commentUserInfo) |
|
239 |
{ |
|
240 |
if (commentUserInfo?.Count() > 0) |
|
241 |
{ |
|
242 |
var main = Common.ViewerDataModel.Instance.SystemMain.dzMainMenu; |
|
243 |
|
|
244 |
try |
|
245 |
{ |
|
246 |
foreach (var instance in commentUserInfo) |
|
247 |
{ |
|
248 |
SelectionSet.Instance.SelectItemByRect(instance.ItemRect, main); |
|
249 |
main.zoomAndPanControl.ZoomTo(instance.ItemRect); |
|
250 |
} |
|
251 |
} |
|
252 |
catch (Exception ex) |
|
253 |
{ |
|
254 |
main.DialogMessage_Alert(ex.Message, "Error"); |
|
255 |
} |
|
256 |
} |
|
257 |
} |
|
258 |
|
|
230 | 259 |
private void OnVpCommentSelectCommand(object x) |
231 | 260 |
{ |
232 | 261 |
throw new NotImplementedException(); |
... | ... | |
255 | 284 |
} |
256 | 285 |
catch (Exception) |
257 | 286 |
{ |
258 |
MessageBox.Show("삭제 오류"); |
|
287 |
//MessageBox.Show("삭제 오류");
|
|
259 | 288 |
} |
260 | 289 |
|
261 | 290 |
await OnGetRequirementDataAsync(); |
PemssAPI/PemssApi.cs | ||
---|---|---|
6 | 6 |
using PemssAPI.DataModel; |
7 | 7 |
using System.Collections.Specialized; |
8 | 8 |
using System.Net.Http; |
9 |
using System.Net.Http.Headers; |
|
9 | 10 |
|
10 | 11 |
namespace KCOM_API |
11 | 12 |
{ |
... | ... | |
160 | 161 |
{ "uId", uId} |
161 | 162 |
}; |
162 | 163 |
|
163 |
var jsonObj = DeleteWebClientString($"{gPemssUri}/rest/ext/comment/requirement"
|
|
164 |
+ $"dId={dId}&mdId={mdId}&commentId={commentId}&uId={uId}"); |
|
164 |
var jsonObj = DeleteWebClientString($"{gPemssUri}","/rest/ext/comment/requirement", values);
|
|
165 |
//+ $"dId={dId}&mdId={mdId}&commentId={commentId}&uId={uId}");
|
|
165 | 166 |
|
166 | 167 |
// var jsonObj = DeleteWebClientString($"{gPemssUri}/rest/ext/comment/requirement", values); |
167 | 168 |
|
... | ... | |
310 | 311 |
} |
311 | 312 |
} |
312 | 313 |
|
313 |
private string DeleteWebClientString(string uri)
|
|
314 |
private string DeleteWebClientString(string baseUri, string RestApi, NameValueCollection data)
|
|
314 | 315 |
{ |
315 | 316 |
try |
316 | 317 |
{ |
317 | 318 |
using (var client = new HttpClient()) |
318 | 319 |
{ |
319 |
var response = client.DeleteAsync(uri); |
|
320 |
client.BaseAddress = new Uri(baseUri); |
|
321 |
client.DefaultRequestHeaders.Accept.Clear(); |
|
322 |
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json")); |
|
323 |
|
|
324 |
var response = client.SendAsync(new HttpRequestMessage(HttpMethod.Delete, RestApi) |
|
325 |
{ |
|
326 |
Content = new StringContent(Newtonsoft.Json.JsonConvert.SerializeObject(data), System.Text.Encoding.UTF8, "application/json") |
|
327 |
}); |
|
320 | 328 |
|
321 | 329 |
var result = response.Result; |
322 | 330 |
|
내보내기 Unified diff