@@ -286,7 +286,7 @@ public void renderInputHtml(RenderContext ctx, HtmlWriter out, Object value)
286286 if (null != filename )
287287 {
288288 // Existing value, so tell the user the file name, allow the file to be removed, and a new file uploaded
289- renderThumbnailAndRemoveLink (out , ctx , formFieldName , filename , value , input );
289+ renderThumbnailAndRemoveLink (out , ctx , getBoundColumn () , filename , value , input );
290290 }
291291 else
292292 {
@@ -307,14 +307,14 @@ protected String getRemovalWarningText(String filename)
307307 return "Previous file " + filename + " will be removed." ;
308308 }
309309
310- private void renderThumbnailAndRemoveLink (HtmlWriter out , RenderContext ctx , String fieldName , String filename , Object value , InputBuilder <?> filePicker )
310+ private void renderThumbnailAndRemoveLink (HtmlWriter out , RenderContext ctx , ColumnInfo column , String filename , Object value , InputBuilder <?> filePicker )
311311 {
312312 String divId = GUID .makeGUID ();
313313 String linkId = "remove" + divId ;
314314
315315 DIV (
316316 id (divId )
317- .data ("fieldName" , fieldName )
317+ .data ("fieldName" , column . getName () )
318318 .cl ("lk-remove-file" ),
319319 (Renderable ) ret -> {
320320 renderIconAndFilename (ctx , out , value instanceof String s ? s : filename , false , false );
0 commit comments