separate (Tracker.Milestone_Pkg)

procedure Ms_Add is
    -----------------------------------------------------------------------------
    --|
    --|  NAME:  MS_ADD
    --|
    --|  OVERVIEW:
    --|    This procedure sets up the record to be added to the list by
    --|    user prompt/response.  The function calls to Prompt_Pkg return
    --|    only valid existing data.  The complete record is
    --|    then added to the linked list by calling the generic list procedure
    --|    ADD.
    --|
    --|  EXCEPTIONS HANDLED:
    --|    none
    --|
    --|  HISTORY:
    --|    written by   May Lee   March 1985
    --|
    --|  NOTES:
    --|    The number of milestones is incremented in this procedure.
    -----------------------------------------------------------------------------
    Ms_Record : Milestone_Pointer;  -- pointer to ms data

begin
    -- create a null milestone record
    Ms_Record := new Milestone_Type;

    New_Line;
    Put_Line (" If you would like more information on the type of data ");
    Put_Line (" to enter for any of the following questions, enter a '?'");
    Put_Line (" Otherwise, enter the data requested.      ");
    New_Line (2);

    -- get the record fields
    Ms_Record.Number := Prompt_Pkg.New_Milstone_Number;
    Ms_Record.Completion_Number :=
       Prompt_Pkg.Milestone_Completion_Number (Default => Ms_Record.Number);
    Put_Line (" What is the due date? ");
    Ms_Record.Due_Date := Prompt_Pkg.Date;
    Ms_Record.Description := Prompt_Pkg.Ms_Description;

    -- add the record to the linked list by calling the generic add
    Add (Ms_List, Ms_Record.Number, Ms_Record);

    -- increment milestone counter
    Num_Of_Milestones := Num_Of_Milestones + 1;

    New_Line;
    Put (" The number of milestones = ");
    Put (Num_Of_Milestones, 1);
    New_Line (2);
    delay 1.0;
end Ms_Add;

