14
80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Hands-On-Lab Learning Portal

Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

  • Upload
    vokhanh

  • View
    246

  • Download
    2

Embed Size (px)

Citation preview

Page 1: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics

AX 2012 R3 CU8 Hands-On-Lab

Learning Portal

Page 2: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Table of Contents

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 ........................................... 1

Exercise 1 Create a New Model and Development Project ........................................................................................... 2

Exercise 2 Create a New EDT ......................................................................................................................................... 3

Exercise 3 Create a New Table ....................................................................................................................................... 4

Exercise 4 Create a Primary Index ................................................................................................................................. 5

Exercise 5 Create a Relation .......................................................................................................................................... 6

Exercise 6 Add an Enum ................................................................................................................................................ 8

Exercise 7 Create a Form ............................................................................................................................................... 9

Exercise 8 Create a Form from a Template ................................................................................................................. 10

Exercise 9 Create a New Security Role ........................................................................................................................ 11

Page 3: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 1 of 12

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Objectives

After completing this lab, you will be better able to:

Create a new model and development project; new EDT; new table; primary index; relation; form; form from a template; new security role

Add an enum

Scenario

As a member of the Microsoft Dynamics AX 2012 R3 CU8 project team for Adventure Works Cycles you are asked to set up various items in Dynamics AX.

Estimated Time to Complete This Lab

60 Minutes

Computers used in this Lab AX2012R3A

The password for the Administrator account on all computers in this lab is: w0rd@p@$$

Page 4: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 2 of 12

Exercise 1 Create a New Model and Development Project

Scenario The following step procedures and practices will demonstrate how to create a modification that can be used in a veterinary surgery. The surgery procedure will need to keep track of each animal that arrives, the owners of the animal, the species, the breed, and details of each visit including the date, reason and the cost.

In this practice you will create a model and a development project to keep your modifications organized. During the remainder of the course, any elements you modify or create should be added to this project.

Isaac, the Systems Developer, needs to make a number of modifications to the system. He wants to be able to group all the elements he creates and modifies together in one place, and also make it easy to move the modifications to test and production systems later.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create a model for Dynamics AX Development I training practices

a. Press Ctrl + D to open the AOT.

b. Click Tools > Model management > Create model.

c. In the Model name field, enter “Dev1”.

d. In the Model publisher field, enter your name.

e. In the Model description field, type “Dynamics AX Development I training practices”.

f. Click OK.

g. Click Close on the Infolog dialog.

Complete the following tasks on:

AX2012R3A

2. Create a project for Dev I training

a. Press Ctrl+Shift+P to open the development projects window.

b. Right-click the Shared node and click New > Project.

c. Rename the project to DevITraining.

Page 5: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 3 of 12

Exercise 2 Create a New EDT

Scenario Create a new Extended Data Type (EDT) that will be used for the breed Id. Set the label and help as appropriate. Ensure the size of the field is consistent with the standard application.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create an EDT for VetBreedId

a. Press Ctrl + D to open a new development workspace.

b. In the AOT, expand the Data Dictionary node.

c. Right-click the Extended Data Types node.

d. Click New > String. A new EDT called Type1(usr) is created.

e. Right-click Type1(usr) and select Properties.

f. In the Properties tab, click the Name property.

g. Type “VetBreedId”.

Complete the following tasks on:

AX2012R3A

2. Extend from SysGroup and change Practiceel to Breed Id

a. Click the Extends property, and select SysGroup.

b. Click the Label property, and type “Breed Id”.

c. Close the property sheet and click Save in the AOT to save your changes.

d. On the database synchronization dialog, click Yes.

Page 6: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 4 of 12

Exercise 3 Create a New Table

Scenario Create a new table that will store the breed of the pet. The table should have the fields BreedId (type VetBreedID) and Name (type Name).

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create VetBreedTable

a. Press Ctrl + D to open a new development workspace.

b. In the AOT, expand the Data Dictionary node.

c. Right-click on the Tables node, and click New Table. A new Table called Table1(usr) is created.

d. Right-click Table1(usr) and select Properties.

e. In the Name property, type “VetBreedTable”.

f. In the Label property, type “Breed”.

g. Close the property sheet.

Complete the following tasks on:

AX2012R3A

2. Add VetBreedId and Name to VetBreedTable

a. Press Ctrl + D to open another AOT. Ensure window is not maximized by clicking the restore down button to enable you to view both AOT windows.

b. In the first AOT, expand the Data Dictionary node.

c. Expand the Extended Data Types node.

d. On the second AOT, expand Data Dictionary > Tables > the VetBreedTable(usr) table.

e. On the first AOT, select VetBreedId(usr).

f. Drag the VetBreedId(usr) in the first AOT to the Fields node of the VetBreedTable(usr) table. A new field called VetBreedId(usr) is created.

g. Right-click the VetBreedId(usr) field and click Properties.

h. Note that the Extended Data Type for this field is set to VetBreedId.

i. In the Name property, type “BreedId”.

j. Close the property sheet.

k. In the first AOT, select the Name in the Extended Data Types node.

l. Drag the Name to the Fields node of the VetBreedTable(usr) table. A new field called Name(usr) is created.

Page 7: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 5 of 12

Exercise 4 Create a Primary Index

Scenario Set the index created in the last practice as a primary index for the table. Create a primary index for the Breed Table.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create Index called BreedIdx

a. Expand the VetBreedTable(usr) table in the AOT.

b. Right-click the Indexes node in the table and select New Index. A new index Index1 is created.

c. Rename the index to BreedIdx.

d. If you used the property sheet to rename the index, close the property sheet.

Complete the following tasks on:

AX2012R3A

2. Add BreedId to the Index and make it a primary index

a. Drag the field BreedId(usr) to the BreedIdx(usr) index node.

b. To set as a unique index, in the properties sheet for the BreedIdx node, click the AllowDuplicates property, and then select No.

c. Click the AlternateKey property, and then select Yes.

d. Close the property sheet.

e. Click Save in the AOT to save your changes.

f. Right-click VetBreedTable(usr) table and select Properties.

g. In the property sheet for the table, click the PrimaryIndex property, and then select BreedIdx.

h. Close the property sheet for the table.

Page 8: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 6 of 12

Exercise 5 Create a Relation

Scenario Create a new table that will store data about the pets belonging to each customer. The table will need to have the following fields: Customer Account (Type CustAccount), PetName (Name), Species (VetSpeciesId), Breed (VetBreedId). You should create two relations - one a foreign key to the species table, and one a normal relation to the breed table so that it is limited based on the species field entered.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create VetCustPetTable

a. Open a new development workspace.

b. In the AOT, expand the Data Dictionary node.

c. Right-click the Tables node and select New Table. A new Table called Table1 is created.

d. Right-click Table1(usr) and select Properties.

e. In the Name property, type “VetCustPetTable”.

f. In the Label property, type “Pets”.

g. Close the property sheet.

Complete the following tasks on:

AX2012R3A

2. Add CustAccount, VetSpeciesId, Name and VetBreedId fields to the VetCustPetTable

a. Press Ctrl + D to open another AOT.

b. Expand the Data Dictionary node.

c. Expand the Extended Data Types node.

d. Locate the CustAccount EDT.

e. In the first AOT, expand Data Dictionary > Tables > VetCustPetTable(usr).

f. Drag the CustAccount EDT in the second AOT to the Fields node of the VetCustPetTable(usr) table in the first AOT.

g. In the second AOT, locate the VetSpeciesId(usr) EDT.

h. Drag the VetSpeciesId(usr) EDT to the Fields node of the VetCustPetTable(usr) table. A new field called VetSpeciesId(usr) is created.

i. Right-click the VetSpeciesId(usr) field and click Properties.

j. In the Name property, set the name of the field to SpeciesId.

k. Close the property sheet.

l. Locate the VetBreedId(usr) EDT.

m. Drag the VetBreedId(usr) EDT to the Fields node of the VetCustPetTable(usr) table. A new field called VetBreedId(usr) is created.

n. Right-click the VetBreedId(usr) field and click Properties.

o. In the Name property, set the name of the field to BreedId.

p. Locate the Name EDT.

q. Drag the Name EDT to the Fields node of the VetCustPetTable(usr) table.

r. Close the property sheet.

Page 9: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 7 of 12

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

3. Create a relation to the VetBreedTable

a. Right-click the Relations node on the VetCustPetTable(usr) node and select New Relation.

b. Right-click the Relation1(usr) relation and select Properties.

c. In the Name property, type “VetBreedTable”.

d. In the Table property, type “VetBreedTable”.

e. Right-click the VetBreedTable(usr) relation, and then click New > Normal.

f. In the property sheet for the new normal relation, click the Field property.

g. Select BreedId in the list.

h. Click the RelatedField property, and select BreedId.

i. Save your changes.

Page 10: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 8 of 12

Exercise 6 Add an Enum

Scenario The pet table needs to store whether the animal is male or female.

Add the Gender Enum to the VetCustPetTable table.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Add an Enum

a. Locate the Gender enum in the Base Enums node in the AOT.

b. Drag the Gender enum to the Fields node in the VetCustPetTable table.

c. Save your changes to the table.

Page 11: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 9 of 12

Exercise 7 Create a Form

Scenario Create a new form to display and edit breed records.

Create a new form that can be used to view, create and edit records in the VetBreedTable table.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create a form called VetBreedTable

a. In the AOT, right-click the Forms node and select New Form.

b. Rename the form to VetBreedTable.

c. In a second AOT, expand Data Dictionary > Tables.

d. Locate the table VetBreedTable(usr).

Complete the following tasks on:

AX2012R3A

2. Add the VetBreedTable table to datasources

a. In the first AOT, expand VetBreedTable(usr) form.

b. Drag the table VetBreedTable(usr) to the DataSources(usr) node on the VetBreedTable(usr) form.

Complete the following tasks on:

AX2012R3A

3. Add the BreedId and Name to the design

a. Expand the Designs node on the VetBreedTable(usr) form.

b. Right-click the Design(usr) node and select New Control > Grid. A new grid control is created.

c. Expand the DataSources(usr) > VetBreedTable > Fields node on the VetBreedTable(usr) form.

d. Drag the fields BreedId and Name to the grid control.

e. Right-click Design(usr) node, and click Properties.

f. On the properties sheet for the Design node, in the Caption property, enter "Breed".

g. Save your changes to the form.

Page 12: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 10 of 12

Exercise 8 Create a Form from a Template

Scenario A form is needed to view which pets belong to which customers. The form will be called from the customer form.

Create a form using a SimpleListDetails template. In the grid on the left it should show the Pet Name and Gender from the VetCustPetTable table. In the details section on the right of the form, it should show the Breed name.

Additionally, create a menu item for the form, however do not add the menu item to a menu - you will use the menu item in the next section.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create a Form from SimpleListDetails template called VetCustPetTable

a. Right-click the Forms node of the AOT and select New Form from template > SimpleListDetails.

b. Rename the form VetCustPetTable.

c. In the first AOT, expand Data Dictionary > Tables.

d. Locate the table VetCustPetTable(usr).

e. Drag the table VetCustPetTable(usr) from a first AOT to the datasources node of the new form.

f. Expand Designs > Design(usr) > Group:Body(usr) on the new form.

g. Right-click on the Group:GridContainer(usr), and then click Properties.

h. In the DataSource property, select VetCustPetTable.

Complete the following tasks on:

AX2012R3A

2. Add the BreedId, Name and Gender fields to the design

a. On the new form, expand VetCustPetTable > Fields in the Data Sources(usr) node.

b. Drag the BreedId, Name and Gender fields to the [Group:GridContainer](usr) of the Design(usr) node.

c. Save your changes to the form.

Complete the following tasks on:

AX2012R3A

3. Create a menu item for the form

a. Drag the VetCustPetTable(usr) form to the Menu Items > Display node in a first AOT to create a menu item for the new form.

b. Right-click the VetCustPetTable menu item, and click Properties.

c. In the property sheet for the new menu item, in the Label property, type “Pets”.

d. Close the property sheet and save your changes to the menu item.

e. Open the form by pressing Ctrl+O.

Page 13: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 11 of 12

Exercise 9 Create a New Security Role

Scenario June Low is employed in the new role of veterinary receptionist. June will be receiving patients at the front desk and will need access to maintain customer information and pet information. She will also need to view breeds and species. Chris, the IT Engineer, needs to create a new role for the veterinary receptionist and add duties so that she can access these areas of the application. June is already created in Microsoft Dynamics AX and is assigned the system user and employee roles. Chris needs to assign her the new role.

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

1. Create a MaintainPets Privilege

a. Press Ctrl+D to open the AOT.

b. Expand Security > Privileges.

c. Right-click Privileges, and select New Privilege.

d. Right-click Privilege1(usr), and click Properties.

e. In the Name property, type “MaintainPets”.

f. In the Label property, type “Maintain pets”.

g. Right-click Privileges, and select New Privilege.

h. In the Name property, type “ViewPetTypes”.

i. In the Label property, type “View pet types”.

Complete the following tasks on:

AX2012R3A

2. Add the VetCustPetTable menu item to the entry points with delete access

a. Expand MaintainPets(usr) to display Entry Points.

b. Press Ctrl+D to open a second AOT.

c. Expand Menu Items > Display.

d. Drag and drop the VetCustPetTable(usr) menu item to the Entry Points node.

e. Right-click the VetCustPetTable entry point, and click Properties.

f. In the property sheet, click the AccessLevel property, and select Delete.

Complete the following tasks on:

AX2012R3A

3. Add the VetSpeciesTable menu item to the entry points with read access

a. Expand ViewPetTypes(usr) to display Entry Points in the first AOT.

b. Drag and drop the VetSpeciesTable(usr) menu item to the Entry Points node.

c. Right-click VetSpeciesTable, and click Properties.

d. In the AccessLevel property, select Read.

Page 14: Warehouse Management in Microsoft Dynamics AX … Development I in Microsoft Dynamics AX 2012 R3 CU8 Page 1 of 12 80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8 Objectives

80670AE: Development I in Microsoft Dynamics AX 2012 R3 CU8

Page 12 of 12

Tasks Detailed Steps

Complete the following tasks on:

AX2012R3A

4. Create MaintainPets duty

a. Expand Security > Duties.

b. Right-click Duties and select New Duty.

c. Rename the new duty to MaintainPets.

d. Click the Label property, and type “Maintain pets”.

e. Expand the MaintainPets(usr) duty.

f. Drag and drop the MaintainPets(usr) privilege to Privileges of the MaintainPets(usr) duty.

g. Drag and drop the ViewPetTypes(usr) privilege to Privileges the MaintainPets(usr) duty.

Complete the following tasks on:

AX2012R3A

5. Add MaintainPets to the TaxRevenue process cycle

a. Expand Security > Process Cycles.

b. Expand TaxRevenue.

c. Drag and drop the MaintainPets(usr) duty to Duties of the TaxRevenue cycle.

d. Save all the changes.

Complete the following tasks on:

AX2012R3A

6. Create a VetReceptionist security Role

a. In Micorsoft Dynamics AX client, click USMF > System administration > Setup > Security > Security roles.

b. Click New.

c. In the AOT name field, type “VetReceptionist”.

d. In the Description field, type “Veterinary receptionist”.

e. Click the Add… button.

f. Expand Revenue cycle.

g. Select Maintain pets.

h. Select Inquire into customer master.

i. Click Close.

Complete the following tasks on:

AX2012R3A

7. Assign June user to the VetReceptionist role

a. Click Assign users in the Action Pane.

b. Select the VetReceptionist role.

c. Click the Manually assign / exclude users button.

d. Select JUNE and click Assign to role.

e. Click Close.