modal-dsl / modal

A Domain Specific Language for AL Extension Development
Apache License 2.0
16 stars 4 forks source link

Should I use all Categories (e. g. Master, Supplemental, (Posted) Document Header, (Posted) Document Line, Setup). #14

Closed spookymattress closed 3 years ago

spookymattress commented 4 years ago

Is it mandatory to use all categories when creating a new solution. It seems so!

I get an error when I try this example:


solution "Seminar Management" {
    Prefix = "SEM";

    master "Seminar" {
        ShortName = "Sem.";

        fields {
            template("Description"; Description)
            field("Duration Days"; Decimal)
            field("Minimum Participants"; Integer)
            field("Maximum Participants"; Integer)
            field("Language Code"; Code[10]) {
                TableRelation = "Language";
            }
            field("Seminar Price"; Decimal)
            field("Gen. Prod. Posting Group"; Code[20]) {
                TableRelation = "Gen. Product Posting Group";
            }
            template("Dimensions"; Dimensions)
        }

        cardPage {
            group("General") {
                field("Description")
                field("Duration Days")
                field("Minimum Participants")
                field("Maximum Participants")
                field("Language Code")
            }
            group("Posting Details") {
                field("Gen. Prod. Posting Group")
                field("Seminar Price")
                field("Dimensions")
            }
        }

        listPage {
            field("Description")
            field("Duration Days")
            field("Minimum Participants")
            field("Maximum Participants")
            field("Seminar Price")
            field("Language Code")
        }
    }
}
joneug commented 4 years ago

At the moment only supplemental definitions are optional and all of the other elements are required. However, it is planned to change this behaviour.

joneug commented 3 years ago

This issue was fixed in version 0.4.0 of the mdAL VS Code Extension. Please update your installation and the example you provided should work.