Custom attribute displayed value
Permalink
Anyone know what method is called to show an attributes stored value on a file object? I have an attribute working as I want it to, but it shows only the "value" of the select and id rather it display something a little more readable. Any thoughts?
Have you tried getAttributeValue($avID)
That is what I WOULD try, but I don't even know where that would go. I don't know what function is being called after the attribute value is saved with AJAX via the properties pane.
Loader::model('file_list'); Loader::model('attribute/categories/file'); $ak = FileAttributeKey::getByHandle('my_attribute_key_handle'); $fl = new FileList(); $fl->filterByWhateverStuff('this stuff'); $arrayOutput = new array(); foreach($fl->get() as $f) { $fv = $f->getVersion(); $arrayOutput[] = $fv->getAttributeValue($ak, 'nice'); }
Off the top of my head. No testing or even sure it works really.