@@ -177,7 +177,7 @@ export class ArtIframeDialogComponent {
177177 }
178178
179179 processCategory ( category ) {
180- console . log ( 'category (processCategory):' , category )
180+ console . debug ( 'category (processCategory):' , category )
181181
182182 let artBody = { }
183183
@@ -202,16 +202,16 @@ export class ArtIframeDialogComponent {
202202 artBody [ category . art_api ] = true
203203 }
204204
205- console . log ( 'Art Body (processCategory):' , artBody )
205+ console . debug ( 'Art Body (processCategory):' , artBody )
206206
207207 return artBody
208208
209209 }
210210
211211 createARTBody ( ) {
212212 // Make ART JSON body in structure shown above
213- //console.log ('selected Categories:', this.selectedCategories)
214- //console.log ('selected SubCategories:', this.selectedSubcategories)
213+ //console.debug ('selected Categories:', this.selectedCategories)
214+ //console.debug ('selected SubCategories:', this.selectedSubcategories)
215215
216216 this . categories . forEach ( category => {
217217
@@ -226,8 +226,8 @@ export class ArtIframeDialogComponent {
226226
227227 onSubmit ( ) : void {
228228 // Process ART data here
229- console . log ( 'Selected Categories:' , this . selectedCategories )
230- console . log ( 'Selected Subcategories:' , this . selectedSubcategories )
229+ console . debug ( 'Selected Categories:' , this . selectedCategories )
230+ console . debug ( 'Selected Subcategories:' , this . selectedSubcategories )
231231
232232 if ( this . selectedCategories . length === 0 && this . selectedSubcategories . length === 0 ) {
233233 this . alert_display = 'inherit'
@@ -239,32 +239,34 @@ export class ArtIframeDialogComponent {
239239
240240 this . createARTBody ( )
241241
242- console . log ( 'Art Body:' , this . art_body )
242+ console . debug ( 'Art Body:' , this . art_body )
243243
244244
245245 this . artService . getArtLanguage ( this . art_body )
246246 . subscribe ( {
247247 next : data => {
248- console . log ( 'Art Language Data:' , data )
248+ console . debug ( 'Art Language Data:' , data )
249249 this . art_language = data ;
250250
251251 if ( data ) {
252252 this . display = 'inherit'
253253 this . solicitationService . postSolicitationART ( this . solicitationId , data ) . subscribe ( {
254- next : ( response ) => console . log ( 'Post Solicitation ART Response:' , response ) ,
254+ next : ( response ) => console . debug ( 'Post Solicitation ART Response:' , response ) ,
255255 error : ( error ) => console . error ( 'Post Solicitation ART Error:' , error )
256256 } )
257257
258258 }
259259
260+ this . art_body = { } ;
261+
260262 } ,
261263 error : error => {
262264 let errors : string [ ] = [ ] ;
263265
264266 const replaceFieldNames = ( error : string , fieldNames : { [ key : string ] : string } ) : string => {
265267 return error . replace ( / ' ( [ ^ ' ] + ) ' / g, ( match , p1 ) => {
266- console . log ( 'Match:' , match )
267- console . log ( 'P1:' , p1 )
268+ console . debug ( 'Match:' , match )
269+ console . debug ( 'P1:' , p1 )
268270 const parts = p1 . split ( '.' ) ;
269271 const art_api = parts [ parts . length - 1 ] ;
270272 return fieldNames [ art_api ] ? `'${ fieldNames [ art_api ] } '` : match ;
@@ -283,14 +285,15 @@ export class ArtIframeDialogComponent {
283285 }
284286 } ) ;
285287
286- console . log ( 'Art Language:' , this . art_language )
288+ console . debug ( 'Art Language:' , this . art_language )
287289 }
288290
289291 clearAll ( ) {
290292 this . selectedCategories = [ ] ;
291293 this . selectedSubcategories = [ ] ;
292294 this . display = 'none' ;
293295 this . art_language = null ;
296+ this . art_body = { } ;
294297
295298 this . categories . forEach ( category => {
296299 category . isChecked = false
@@ -319,7 +322,7 @@ export class ArtIframeDialogComponent {
319322 }
320323
321324 onCategoryChange ( selected ) {
322- console . log ( 'Selected:' , selected )
325+ console . debug ( 'Selected:' , selected )
323326
324327 this . selectedCategories = selected . selectedCategories ;
325328 let parent = selected . parent ;
@@ -332,13 +335,13 @@ export class ArtIframeDialogComponent {
332335
333336 }
334337
335- console . log ( 'Selected Subcategories:' , this . selectedSubcategories )
338+ console . debug ( 'Selected Subcategories:' , this . selectedSubcategories )
336339 }
337340
338341 copyToClipBoard ( elem ) {
339342 navigator . clipboard . writeText ( elem . innerText )
340343 . then ( ( ) => {
341- console . log ( 'Text copied to clipboard' ) ;
344+ console . debug ( 'Text copied to clipboard' ) ;
342345 // Additional code after copying to clipboard
343346 } )
344347 . catch ( ( error ) => {
@@ -371,6 +374,7 @@ export class ArtIframeDialogComponent {
371374 }
372375
373376 this . art_language = [ ] ; // Remove art language
377+ this . art_body = { } ; // Remove art body
374378 this . display = 'none' ;
375379 }
376380
0 commit comments