Have you ever found yourself in a situation when you had to change field types but Drupal did not let you do this because you already had values in the DB? And than you had to write not so arbitrary code to change field settings in the database. This module helps you do this change with a simple UI or drush command.

At the moment, module can transform:

File fields from private to public and vice versa.
Date fields from/to Datestamp and Datetime (dates are of course transformed into the right form)
by keeping all the values.

For example, if you want to make your files private from public, just run

drush fut field_name private

Module makes a backup of the field values table first, so if anything goes wrong, you can revert it back manually. Backup tables are named same as the original once with an added suffix '_field_utils_bak'. Please note that backup tables are removed when CRON is executed.

https://www.drupal.org/sandbox/qstraza/2839329
git clone --branch 7.x-1.x https://git.drupal.org/sandbox/qstraza/2839329.git field_utilities

Comments

qstraza created an issue. See original summary.

PA robot’s picture

Status: Needs review » Needs work

There are some errors reported by automated review tools, did you already check them? See http://pareview.sh/pareview/httpsgitdrupalorgsandboxqstraza2839329git

We 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.

qstraza’s picture

Fixed warning and errors posted by pareview.sh.

qstraza’s picture

Status: Needs work » Needs review
kajalkiran’s picture

Hi @qstraza,

I have Reviewed your project application and found this module useful. But in the meanwhile, found an error which needs to be work upon.

Automated Review

[No automated test cases were found, did you consider writing Simpletests or PHPUnit tests? This is not a requirement but encouraged for professional software development.]

pa_error

Manual Review

Individual user account

Coding style & Drupal API usage

List of identified issues:

  1. On install of module we get following log message :
  2. Install Error
    detail_error_log_on_install.png

  3. Field name : field_date. So, on trying to convert the field_date from current field type datetime to field_type datestamp getting following error:
  4. convertion_error
    Detail conversation issue

  5. Before running the cron if module is uninstalled the backup table created with suffix ‘_field_utils_bak’ should be deleted. This should be handled or else database will have many such tables which is not of use. Thus by handling this will have efficient memory management.
  6. Typo errors : The comment should be updated for few functions such as “Implements hook hook_permission().” should be only “Implements hook_permission().”

Recommendations for Application Issue

  • Provide Similar Modules(if any)and how your module is different from others.
kajalkiran’s picture

Status: Needs review » Needs work
PA robot’s picture

Status: Needs work » Closed (won't fix)

Closing 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.