Skip to content

Commit 83f4817

Browse files
committed
Add view and mat.view to puml lib
1 parent 6c4a503 commit 83f4817

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

puml-lib/db_ent.puml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,14 @@
1818
!return 'entity "**' + $name + '**"' + " as " + $name
1919
!endfunction
2020
21+
!function view($name, $materialized=false)
22+
!if ($materialized == false)
23+
!return 'entity "**' + $name + ' **<color:SkyBlue>**(V)**</color>"' + " as " + $name
24+
!else
25+
!return 'entity "**' + $name + ' **<color:DarkBlue>**(MV)**</color>"' + " as " + $name
26+
!endif
27+
!endfunction
28+
2129
!procedure enum($name, $variants)
2230
!$list = %splitstr($variants, ",")
2331
@@ -35,5 +43,7 @@
3543
|<color:#aaaaaa><&key></color>| Foreign Key |
3644
| &#8226; | Mandatory field (Not Null) |
3745
| <color:purple>**(E)**</color> | Enum |
46+
| <color:SkyBlue>**(V)**</color> | View |
47+
| <color:DarkBlue>**(MV)**</color> | Materialized View |
3848
endlegend
3949
!endprocedure

0 commit comments

Comments
 (0)