示例#1
0
 public PeanutUpdateCommand()
 {
     PeanutDto    = new PeanutDto();
     Requirements = new Dictionary <string, RequirementDto>();
     PeanutCommentCreateCommand = new PeanutCommentCreateCommand();
     PeanutState = PeanutState.Scheduling;
 }
示例#2
0
        public PeanutUpdateCommand(Core.Domain.Peanuts.Peanut peanut)
        {
            Require.NotNull(peanut, "peanut");

            PeanutDto    = peanut.GetDto();
            Requirements = peanut.Requirements.ToDictionary(r => Guid.NewGuid().ToString(), r => r.GetDto());
            PeanutCommentCreateCommand = new PeanutCommentCreateCommand();
            PeanutState = peanut.PeanutState;
        }