/** * Creates a string from tag parameters which will be used * to rewrite the data-devise html * * @param DeviseTag $tag * @return string */ protected function getNewDeviseTagString(DeviseTag $tag) { list($id, $bindingType, $collection, $key, $type, $humanName, $collectionName, $group, $category, $alternateTarget, $defaults, $chain) = $tag->toArray('"'); if ($bindingType === '"variable"') { $key = $chain; } return " data-devise-<?php echo devise_tag_cid('{$id}', {$bindingType}, {$collection}, {$key}, {$type}, {$humanName}, {$collectionName}, {$group}, {$category}, {$alternateTarget}, {$defaults}) ?>=\"{$id}\""; }