.___ ___. .___ ___. ___
| \/ | | \/ | / \
| \ / | | \ / | / ^ \
| |\/| | | |\/| | / /_\ \
| | | | | | | | / _____ \
|__| |__| |__| |__| /__/ \__\
MMA Cli is a complete Code Generator based on ASP.NET Core to create modern APIs by following the software development best practices and the latest technologies.
- Improved migration process and enrich with notifications
- Databse first mode has been added to
UI
mode using `Import form Database' option
- Quick Start is a single-part, quick-start tutorial to create a solution with the
mma cli
. - Interactive Mode can be used to create and run ABP based solutions with different options and details.
- Command Line Mode is a complete tutorial to develop a full stack web application with all aspects of a real-life solution.
- UI is a complete tutorial to develop a full stack web application with all aspects of a real-life solution.
Install the mma-cli
:
dotnet tool install --global mma-cli
Create a new Solution:
mma new SolutionName
you can also use short form
mma n SolutionName
--mapper
tom indecat which object mapping libirary that accept mapster
or automapper
and default value is automapper
mma n SolutionName --mapper mapster
Now, we need to navigate to the solution folder to start add components.
cd SolutionName
-
Add Entity:
mma generate entity MyEntity long # OR mma g e MyEntity long
generate entity also require
--mapper
value and the default value isautomapper
mma g e MyEntity long --mapper Mapster
generate property requires
EntityName
,PK Data type
supported data types:
- Guid
- int
- long
- string
- decimal
- float
- bool
- DateTime
Default data type is
Guid
-
--mapper
tom indecat which object mapping libirary that acceptmapster
orautomapper
and default value isautomapper
-
--no-api
to skip generaate API controller for this entity.
-
Add/Remove Property to exsiting Entity
mma generate property MyEntity MyProperty long # OR mma g p MyEntity MyProperty long true
generate property requires
EntityName
,PropertyName
,DataType
supported data types:
- Guid
- int
- long
- string
- decimal
- float
- bool
- DateTime
Default data type is
Guid
--remove
to remove the property from existing entitymma g p MyEntity MyProperty long true --remove
-
Add/Remove relation to exsiting Entities
mma generate relation MyParentEntity MyChildEntity ForeignKeyProperty # OR mma g r MyParentEntity MyChildEntity ForeignKeyProperty
generate property requires
Referece Entit Name
,Child Entity Name
,ForeignKey PropertyName
--remove
to remove the property from existing entitymma g r MyParentEntity MyChildEntity ForeignKeyProperty --remove
You can use interactive mode by enter command mma
without any arguments in solution path
Also you can use UI mode to create and manage your solutions. Select UI
from Interactive
or execute mma ui
Thanks to Radzen
mma ui