Description
This is a simple label/value field that can be attached to any entities.
Similar projects and how they are different
Both modules provide a solution to the key-value field using combination of existing fields.
A labelvalue field is not a combination of two already existing fields.
The labelvalue module try to solve a simple problematic: "I need to use a key-value field where my key and my value will be both string" while the "field Collection & Multifields" module solves more complex use-cases combining two existing fields to mimic one and allow, for example, a key-image field.
Project page
https://drupal.org/sandbox/dimduj/2268341
git clone --branch 7.x-1.x http://git.drupal.org:/sandbox/dimduj/2268341.git labelvalue
Comments
Comment #1
dimduj commentedFix git clone link => remove username
Comment #2
dimduj commentedComment #3
dimduj commentedComment #4
dimduj commentedAdding first manual review
Comment #5
PA robot commentedWe are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #6
dimduj commentedFix typo in description
Comment #7
maijs commentedHere is my review of the module.
Warning: Invalid argument supplied for foreach() in _field_sql_storage_schema() (line 182 of /Sites/labelvalue/drupal/modules/field/modules/field_sql_storage/field_sql_storage.module).Please see the documentation of _field_sql_storage_schema() function and return table index array elements as arrays:labelvalue.infofile is "Label Value" (please note the extra space).labelvalue_field_info()defines a label for thelabelvaluefield as "Label Value" (please note the extra space).labelvalue_field_widget_info()defines a label for the widget as "Label Value Default Widget".While documentation on Writing module .info files suggests to capitalise every word of the module, that fact is that every Drupal core module, that has more than one word, has only the first word capitalised. It would be more consistent with other modules to follow the same pattern.
labelvalue_field_formatter_view()function assigns$instancevariable (field instance) to#fieldtheme variable which makes the code harder to read and debug as$fieldand$instanceeach has their own content and meaning in Field API system. You should rename theme variable tofield_instanceor similar name consistent with the content of the variable.labelvalue_field_widget_form()function includes module specific stylesheet file usingdrupal_add_css()function. Consider including stylesheet files using#attachedproperty that is part of Drupal Form API. Modifying widget styling is much more simpler viahook_field_widget_form_alter()rather than other means of CSS file extraction from the output. An example for your module:I really like the simplicity of this module. Thank you for that!
Comment #8
maijs commentedHow does this module differ from Double field module which allows to select from a plenty of widgets that have
key => valueformat, including two textfields for label and value? I installed Double field module, created a field and got exatly the same result as the output oflabelvaluemodule.Have you done a proper research before creating this module? There is, in essence, no added value that it provides.
Comment #9
PA robot commentedClosing due to lack of activity. If you are still working on this application, you should fix all known problems and then set the status to "Needs review". (See also the project application workflow).
I'm a robot and this is an automated message from Project Applications Scraper.