Permalink
Browse files

Adding support of custom fields

  • Loading branch information...
joki1987 committed Oct 11, 2015
1 parent 0ae6147 commit a5e933534f93b65185bbe01c3b43adbf8716dacc
@@ -7,6 +7,9 @@ class ReArtifactPropertiesController < RedmineReController
helper :watchers
helper :attachments
include AttachmentsHelper
helper :custom_fields
include CustomFieldsHelper
def new
@re_artifact_properties = ReArtifactProperties.new
@@ -104,6 +104,9 @@ class ReArtifactProperties < ActiveRecord::Base
has_many :sources, :through => :traces_as_sink, :order => "re_artifact_relationships.position"
has_one :parent, :through => :parent_relation, :source => "source"
acts_as_customizable
acts_as_watchable
acts_as_attachable({:delete_permission => :edit_requirements, :view_permission => :view_requirements})
@@ -123,10 +123,23 @@
</fieldset>
<% unless @re_artifact_properties.custom_field_values.blank? %>
<fieldset>
<legend><%= t(:re_user_defined_fields) %></legend>
<% @re_artifact_properties.custom_field_values.each do |value| %>
<p><%= custom_field_tag_with_label :re_artifact_properties, value %></p>
<% end %>
</fieldset>
<% end %>
<%= call_hook(:view_projects_form, :re_artifact_properties => @re_artifact_properties, :form => f) %>
<div id="attachments" class="artifact_edit_box">
<h3><%= t :label_attachments %></h3>
<%= render 'attachments/form', :locals => {:container => @re_artifact_properties} %>
</div>
<p>
<%= submit_tag t(:re_save) %>
View
@@ -122,6 +122,7 @@ en:
re_artifact_properties_updated: 'Artifact Properties updated'
re_artifact_properties_created: 'Artifact created'
re_no_responsible_user_defined: 'No responsible user defined'
re_user_defined_fields: 'User defined Field'
project: Project
re_my_artifacts: 'My Artifacts'
@@ -608,4 +609,7 @@ en:
re_user_profile_default_description: "<p>You can use user profiles to describe your users.</p><p>Describing the stakeholder with user profiles is are very important because all requirements come from people. Thus you should discover and document all stakeholder which are involved in your project. [Alexander 2009, S 28]</p>"
re_workarea_default_description: "<p>A workarea can be used to structure a couple of tasks. It provides an ability to keep artifacts together, which take place in the same area (e.g. a room, a company or a department).</p>"
re_description_of_plugin_usage: "<h2>Artifact Creation</h2><ul><li>Get started by creating requirements artifacts. You may select from the artifacts shown below. After saving, you will find the artifacts you created in the tree to your left.</li><li>You can also right click on any artifact on the tree to add new artifacts. Use \"create artifact in\" to create an artifact in the next level of the tree or \"create artifact below\" to create an artifact on the same level.</li></ul><h2>Structure</h2><ul><li>You can drag and drop each artifact in the tree to reorder or restructure your RE artifacts. The tree represents the structure of your requirements document.</li><li>You can create traces between artifact by<ul><li>Editing an artifact and use the \"relationships\" section. Select the trace type with the radio butting and start typing a name. The artifacts will show up and a link can be created. You find all traces in the top-right section.</li><li>You can also create traces by dragging and dropping an artifact from the tree in the traces from/traces to sections. After dropping you can choose the relation type.</li></ul></li></ul><h2>Connecting Issues</h2><ul><li>You can use the Connect Issue link to create an issue which gets automatically linked to the selected artifact</li><li>You can also edit issues and artifacts to create links manually</li></ul><h2>Visualization</h2><ul><li>Use traceability visualizations by right-clicking an artifact. The visualization will apply to the selected sub-tree</li><li>Please note, that the artifact types and trace types need to be enabled in the side bar on the right side. Slide over the bar with the mouse to open it.</li></ul><!--<h2>Diagrameditor</h2><ul><li>The diagrameditor is a early alpha version and is right now abandoned in development. It is distributed in a seperate plugin and the RE plugin works without it. However if both plugins are installed they integrate with each other.</li><li>If you want to update/extend/use the editor feel free to contact us: <a class='external' href='http://korem.de/team.16.html'>http://korem.de/team.16.html</a></li></ul>--><h2>Other things</h2><ul><li>Usability<ul><li>The bars to the left and right are slid open on mouse over. You can close/open them permanently by clicking on the dark gray area.</li><li>The bar on the right shows all watcher and comments for the requirement artifact. Please note, that you need to reload the page to update the number of watchers and comments (there is no ajax-ish implementation, yet)</li></ul></li><li> Configurability<ul><li>This demo lets you export to opendocument ony. We use an open source conversion tool to export, which supports other types, like html, latex, mediawiki, rtf, etc. and is configurable by administrators. This may or may not work superb.</li><li>We enabled all types of requirement artifacts in this demo. If you prefer use-cases or other techniques administrators can disable certain artifact types.</li><li>The same for relationships</li><li>Artifact and relationship types can be renamed for your convenience.</li><li>Artifact and relationship colors can be choosen as you like</li><li>The visualization uses 4 recursive steps as the standard and is set to a size of 800x800 pixels. This can be configured.</li><li>Issues are included in visualization. This can be disabled.</li></ul></li></ul><p>Enjoy trying the plugin. Please contact us at <a class='external' href='http://korem.de/team.16.html'>http://korem.de/team.16.html</a> if you need more information.</p>"
re_description_of_plugin_usage: "<h2>Artifact Creation</h2><ul><li>Get started by creating requirements artifacts. You may select from the artifacts shown below. After saving, you will find the artifacts you created in the tree to your left.</li><li>You can also right click on any artifact on the tree to add new artifacts. Use \"create artifact in\" to create an artifact in the next level of the tree or \"create artifact below\" to create an artifact on the same level.</li></ul><h2>Structure</h2><ul><li>You can drag and drop each artifact in the tree to reorder or restructure your RE artifacts. The tree represents the structure of your requirements document.</li><li>You can create traces between artifact by<ul><li>Editing an artifact and use the \"relationships\" section. Select the trace type with the radio butting and start typing a name. The artifacts will show up and a link can be created. You find all traces in the top-right section.</li><li>You can also create traces by dragging and dropping an artifact from the tree in the traces from/traces to sections. After dropping you can choose the relation type.</li></ul></li></ul><h2>Connecting Issues</h2><ul><li>You can use the Connect Issue link to create an issue which gets automatically linked to the selected artifact</li><li>You can also edit issues and artifacts to create links manually</li></ul><h2>Visualization</h2><ul><li>Use traceability visualizations by right-clicking an artifact. The visualization will apply to the selected sub-tree</li><li>Please note, that the artifact types and trace types need to be enabled in the side bar on the right side. Slide over the bar with the mouse to open it.</li></ul><!--<h2>Diagrameditor</h2><ul><li>The diagrameditor is a early alpha version and is right now abandoned in development. It is distributed in a seperate plugin and the RE plugin works without it. However if both plugins are installed they integrate with each other.</li><li>If you want to update/extend/use the editor feel free to contact us: <a class='external' href='http://korem.de/team.16.html'>http://korem.de/team.16.html</a></li></ul>--><h2>Other things</h2><ul><li>Usability<ul><li>The bars to the left and right are slid open on mouse over. You can close/open them permanently by clicking on the dark gray area.</li><li>The bar on the right shows all watcher and comments for the requirement artifact. Please note, that you need to reload the page to update the number of watchers and comments (there is no ajax-ish implementation, yet)</li></ul></li><li> Configurability<ul><li>This demo lets you export to opendocument ony. We use an open source conversion tool to export, which supports other types, like html, latex, mediawiki, rtf, etc. and is configurable by administrators. This may or may not work superb.</li><li>We enabled all types of requirement artifacts in this demo. If you prefer use-cases or other techniques administrators can disable certain artifact types.</li><li>The same for relationships</li><li>Artifact and relationship types can be renamed for your convenience.</li><li>Artifact and relationship colors can be choosen as you like</li><li>The visualization uses 4 recursive steps as the standard and is set to a size of 800x800 pixels. This can be configured.</li><li>Issues are included in visualization. This can be disabled.</li></ul></li></ul><p>Enjoy trying the plugin. Please contact us at <a class='external' href='http://korem.de/team.16.html'>http://korem.de/team.16.html</a> if you need more information.</p>"
label_re_artifact_properties_plural: "Artifacts"
View
@@ -4,8 +4,10 @@
require_dependency '../app/models/re_artifact_relationship'
require_dependency '../app/models/re_artifact_properties'
require_dependency '../app/models/re_artifact_properties_custom_field'
require_dependency '../app/models/re_relationtype'
require_dependency '../app/helpers/re_application_helper'
require_dependency '../app/helpers/custom_fields_helper'
# Make singular and plural for RE_Artifact_Properties the same
ActiveSupport::Inflector.inflections do |inflect|
@@ -23,6 +25,7 @@
require_dependency 'project_patch'
require_dependency 'projects_controller_patch'
require_dependency 'user_patch'
require_dependency 'custom_fileds_helper_patch'
end
require_dependency '../lib/re_wiki_macros'

0 comments on commit a5e9335

Please sign in to comment.