Module: DBDiagram::Diagram::Graphviz::Simple
Instance Method Summary collapse
Instance Method Details
#entity_style(entity, attributes) ⇒ Object
98 99 100 101 102 |
# File 'lib/db_diagram/diagram/graphviz.rb', line 98 def entity_style(entity, attributes) {}.tap do || [:fontcolor] = [:color] = :grey60 if entity.abstract? end end |
#relationship_style(relationship) ⇒ Object
104 105 106 107 108 109 110 111 112 |
# File 'lib/db_diagram/diagram/graphviz.rb', line 104 def relationship_style(relationship) {}.tap do || # options[:style] = :dotted #虚线 # Closed arrows for to/from many. [:arrowhead] = relationship.to_many? ? "normal" : "none" [:arrowtail] = relationship.many_to? ? "normal" : "none" end end |