Chore: New standard fields on Companies (#1276)
* New standard fields on Companies Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * New standard fields on Companies Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * Add requested changes Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * Make some fields hidden by default Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * Add minor refactors Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> --------- Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> Co-authored-by: v1b3m <vibenjamin6@gmail.com>
This commit is contained in:
@ -1,8 +1,10 @@
|
||||
import {
|
||||
ViewFieldBooleanMetadata,
|
||||
ViewFieldChipMetadata,
|
||||
ViewFieldDateMetadata,
|
||||
ViewFieldDefinition,
|
||||
ViewFieldMetadata,
|
||||
ViewFieldMoneyMetadata,
|
||||
ViewFieldNumberMetadata,
|
||||
ViewFieldRelationMetadata,
|
||||
ViewFieldTextMetadata,
|
||||
@ -10,10 +12,13 @@ import {
|
||||
} from '@/ui/editable-field/types/ViewField';
|
||||
import {
|
||||
IconBrandLinkedin,
|
||||
IconBrandX,
|
||||
IconBuildingSkyscraper,
|
||||
IconCalendarEvent,
|
||||
IconLink,
|
||||
IconMap,
|
||||
IconMoneybag,
|
||||
IconTarget,
|
||||
IconUserCircle,
|
||||
IconUsers,
|
||||
} from '@/ui/icon/index';
|
||||
@ -111,4 +116,40 @@ export const companyViewFields: ViewFieldDefinition<ViewFieldMetadata>[] = [
|
||||
},
|
||||
isVisible: true,
|
||||
} satisfies ViewFieldDefinition<ViewFieldTextMetadata>,
|
||||
{
|
||||
id: 'idealCustomerProfile',
|
||||
columnLabel: 'ICP',
|
||||
columnIcon: <IconTarget />,
|
||||
columnSize: 150,
|
||||
columnOrder: 8,
|
||||
metadata: {
|
||||
type: 'boolean',
|
||||
fieldName: 'idealCustomerProfile',
|
||||
},
|
||||
isVisible: false,
|
||||
} satisfies ViewFieldDefinition<ViewFieldBooleanMetadata>,
|
||||
{
|
||||
id: 'annualRecurringRevenue',
|
||||
columnLabel: 'ARR',
|
||||
columnIcon: <IconMoneybag />,
|
||||
columnSize: 150,
|
||||
columnOrder: 8,
|
||||
metadata: {
|
||||
type: 'moneyAmount',
|
||||
fieldName: 'annualRecurringRevenue',
|
||||
},
|
||||
} satisfies ViewFieldDefinition<ViewFieldMoneyMetadata>,
|
||||
{
|
||||
id: 'xUrl',
|
||||
columnLabel: 'Twitter',
|
||||
columnIcon: <IconBrandX />,
|
||||
columnSize: 150,
|
||||
columnOrder: 8,
|
||||
metadata: {
|
||||
type: 'url',
|
||||
fieldName: 'xUrl',
|
||||
placeHolder: 'X',
|
||||
},
|
||||
isVisible: false,
|
||||
} satisfies ViewFieldDefinition<ViewFieldURLMetadata>,
|
||||
];
|
||||
|
||||
@ -13,6 +13,9 @@ export const COMPANY_FIELDS_FRAGMENT = gql`
|
||||
domainName
|
||||
employees
|
||||
linkedinUrl
|
||||
xUrl
|
||||
annualRecurringRevenue
|
||||
idealCustomerProfile
|
||||
id
|
||||
name
|
||||
}
|
||||
|
||||
@ -12,6 +12,9 @@ export const GET_COMPANIES = gql`
|
||||
createdAt
|
||||
address
|
||||
linkedinUrl
|
||||
xUrl
|
||||
annualRecurringRevenue
|
||||
idealCustomerProfile
|
||||
employees
|
||||
_activityCount
|
||||
accountOwner {
|
||||
|
||||
@ -9,6 +9,9 @@ export const GET_COMPANY = gql`
|
||||
createdAt
|
||||
address
|
||||
linkedinUrl
|
||||
xUrl
|
||||
annualRecurringRevenue
|
||||
idealCustomerProfile
|
||||
employees
|
||||
_activityCount
|
||||
accountOwner {
|
||||
|
||||
@ -10,6 +10,9 @@ type MockedCompany = Pick<
|
||||
| 'address'
|
||||
| 'employees'
|
||||
| 'linkedinUrl'
|
||||
| 'xUrl'
|
||||
| 'annualRecurringRevenue'
|
||||
| 'idealCustomerProfile'
|
||||
| '_activityCount'
|
||||
> & {
|
||||
accountOwner: Pick<
|
||||
@ -30,6 +33,9 @@ export const mockedCompaniesData: Array<MockedCompany> = [
|
||||
domainName: 'airbnb.com',
|
||||
name: 'Airbnb',
|
||||
linkedinUrl: 'https://www.linkedin.com/company/airbnb/',
|
||||
xUrl: 'https://twitter.com/airbnb',
|
||||
annualRecurringRevenue: 500000,
|
||||
idealCustomerProfile: true,
|
||||
createdAt: '2023-04-26T10:08:54.724515+00:00',
|
||||
address: 'San Francisco, CA',
|
||||
employees: 5000,
|
||||
@ -50,6 +56,9 @@ export const mockedCompaniesData: Array<MockedCompany> = [
|
||||
domainName: 'qonto.com',
|
||||
name: 'Qonto',
|
||||
linkedinUrl: 'https://www.linkedin.com/company/qonto/',
|
||||
xUrl: 'https://twitter.com/qonto',
|
||||
annualRecurringRevenue: 500000,
|
||||
idealCustomerProfile: false,
|
||||
createdAt: '2023-04-26T10:12:42.33625+00:00',
|
||||
address: 'Paris, France',
|
||||
employees: 800,
|
||||
@ -62,6 +71,9 @@ export const mockedCompaniesData: Array<MockedCompany> = [
|
||||
domainName: 'stripe.com',
|
||||
name: 'Stripe',
|
||||
linkedinUrl: 'https://www.linkedin.com/company/stripe/',
|
||||
xUrl: 'https://twitter.com/stripe',
|
||||
annualRecurringRevenue: 5000000,
|
||||
idealCustomerProfile: false,
|
||||
createdAt: '2023-04-26T10:10:32.530184+00:00',
|
||||
address: 'San Francisco, CA',
|
||||
employees: 8000,
|
||||
@ -73,6 +85,9 @@ export const mockedCompaniesData: Array<MockedCompany> = [
|
||||
id: 'b1cfd51b-a831-455f-ba07-4e30671e1dc3',
|
||||
domainName: 'figma.com',
|
||||
linkedinUrl: 'https://www.linkedin.com/company/figma/',
|
||||
xUrl: 'https://twitter.com/figma',
|
||||
annualRecurringRevenue: 50000,
|
||||
idealCustomerProfile: true,
|
||||
name: 'Figma',
|
||||
createdAt: '2023-03-21T06:30:25.39474+00:00',
|
||||
address: 'San Francisco, CA',
|
||||
@ -85,6 +100,9 @@ export const mockedCompaniesData: Array<MockedCompany> = [
|
||||
id: '5c21e19e-e049-4393-8c09-3e3f8fb09ecb',
|
||||
domainName: 'notion.com',
|
||||
linkedinUrl: 'https://www.linkedin.com/company/notion/',
|
||||
xUrl: 'https://twitter.com/notion',
|
||||
annualRecurringRevenue: 500000,
|
||||
idealCustomerProfile: false,
|
||||
name: 'Notion',
|
||||
createdAt: '2023-04-26T10:13:29.712485+00:00',
|
||||
address: 'San Francisco, CA',
|
||||
|
||||
Reference in New Issue
Block a user