Creating the opportunity details page
In this section, we'll create the opportunity details page. The opportunity details page allows the user to track and register opportunity activities.
The user can also change the opportunity step and edit the opportunity properties such as title
and expected revenue
.
Follow these steps to create the opportunity details page:
- Run the following command to generate the opportunity detail page:
yarn umi g page /OpportunityDetail/index --typeScript --less
- We'll use a pro component called
ProDescriptions
. It's similar to theProTable
component but intended for display properties instead of a batch of data. Run the following command to add theProDescriptions
component to the project:yarn add @ant-design/pro-descriptions@1.10.5
- Next, import these dependencies to the
index.tsx
file in theOpportunityDetail
folder, as follows:import { Opportunity } from '@/types/opportunity'; import ProDescriptions from &apos...