jhipster / generator-jhipster

JHipster is a development platform to quickly generate, develop, & deploy modern web applications & microservice architectures.
https://www.jhipster.tech
Apache License 2.0
21.55k stars 4.02k forks source link

Webpack build error for generated entities, when fieldName=type #5081

Closed aricooperman closed 7 years ago

aricooperman commented 7 years ago
Overview of the issue

Import jh entity file, regenerate project and get the following errors:

` ERROR in [at-loader] src/main/webapp/app/entities/network-lead-contact/network-lead-contact-dialog.component.ts:48:28 Argument of type '(res: Response) => void' is not assignable to parameter of type '(value: NetworkLeadContact) => void'. Types of parameters 'res' and 'value' are incompatible. Type 'NetworkLeadContact' is not assignable to type 'Response'. Types of property 'type' are incompatible. Type 'ContactType' is not assignable to type 'ResponseType'.

ERROR in [at-loader] src/main/webapp/app/entities/network-lead-contact/network-lead-contact-dialog.component.ts:51:28 Argument of type '(res: Response) => void' is not assignable to parameter of type '(value: NetworkLeadContact) => void'. Types of parameters 'res' and 'value' are incompatible. `

Motivation for or Use Case

Can't build project with designed entities

Reproduce the error

Use config below and generate/run webpack build

Related issues

4921

Suggest a Fix

Unsure

JHipster Version(s)

4.0.0

JHipster configuration

Welcome to the JHipster Information Sub-Generator

JHipster Version(s)
bizdevmanager@0.0.0 /Users/acooperman/Development/workspaces/x/y/z
├── UNMET PEER DEPENDENCY @angular/compiler@2.4.4
├── UNMET PEER DEPENDENCY @angular/core@2.4.4
└── generator-jhipster@4.0.0 
JHipster configuration, a .yo-rc.json file generated in the root folder
{
  "generator-jhipster": {
    "jhipsterVersion": "4.0.0",
    "baseName": "bizdevmanager",
    "packageName": "xyz",
    "packageFolder": “x/y/z“,
    "serverPort": "8080",
    "authenticationType": "oauth2",
    "hibernateCache": "ehcache",
    "clusteredHttpSession": false,
    "websocket": "spring-websocket",
    "databaseType": "sql",
    "devDatabaseType": "h2Disk",
    "prodDatabaseType": "mariadb",
    "searchEngine": "elasticsearch",
    "messageBroker": false,
    "buildTool": "gradle",
    "enableSocialSignIn": true,
    "useSass": true,
    "clientPackageManager": "yarn",
    "applicationType": "monolith",
    "testFrameworks": [
      "gatling",
      "cucumber",
      "protractor"
    ],
    "jhiPrefix": "bdm",
    "otherModules": [
      {
        "name": "generator-jhipster-nav-element",
        "version": "0.0.5"
      },
      {
        "name": "generator-jhipster-angular-ui",
        "version": "0.0.2"
      },
      {
        "name": "generator-jhipster-swagger-cli",
        "version": "2.0.5"
      },
      {
        "name": "generator-jhipster-material",
        "version": "0.0.0"
      },
      {
        "name": "generator-jhipster-entity-audit",
        "version": "2.2.2"
      },
      {
        "name": "generator-jhipster-bootswatch",
        "version": "1.0.2"
      },
      {
        "name": "generator-jhipster-elasticsearch-reindexer",
        "version": "0.2.0"
      },
      {
        "name": "generator-jhipster-bootstrap-material-design",
        "version": "3.5.1"
      },
      {
        "name": "generator-jhipster-angular-datatables",
        "version": "1.3.1"
      },
      {
        "name": "generator-jhipster-basic-auth",
        "version": "1.0.1"
      },
      {
        "name": "generator-jhipster-docker",
        "version": "2.2.0"
      },
      {
        "name": "generator-jhipster-swagger2markup",
        "version": "1.1.0"
      },
      {
        "name": "generator-jhipster-ci",
        "version": "1.0.0"
      },
      {
        "name": "generator-jhipster-spring-social-connectors",
        "version": "0.0.1"
      }
    ],
    "enableTranslation": false,
    "serviceDiscoveryType": false,
    "clientFramework": "angular2"
  }
}
Entity configuration(s) entityName.json files generated in the .jhipster directory

Company.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "one-to-many",
            "relationshipName": "childCompany",
            "otherEntityName": "company",
            "otherEntityRelationshipName": "immediateParent"
        },
        {
            "relationshipType": "one-to-many",
            "relationshipName": "notes",
            "otherEntityName": "companyNote",
            "otherEntityRelationshipName": "company"
        },
        {
            "relationshipType": "many-to-one",
            "relationshipName": "immediateParent",
            "otherEntityName": "company",
            "otherEntityField": "id"
        }
    ],
    "fields": [
        {
            "fieldName": "name",
            "fieldType": "String",
            "fieldValidateRules": [
                "required",
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 1,
            "fieldValidateRulesMaxlength": 100
        },
        {
            "fieldName": "streetAddress1",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 50
        },
        {
            "fieldName": "streetAddress2",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 50
        },
        {
            "fieldName": "city",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 50
        },
        {
            "fieldName": "state",
            "fieldType": "State",
            "fieldValues": "ALABAMA,ALASKA,ARIZONA,ARKANSAS,CALIFORNIA,COLORADO,CONNECTICUT,DELAWARE,FLORIDA,GEORGIA,HAWAII,IDAHO,ILLINOIS,INDIANA,IOWA,KANSAS,KENTUCKY,LOUISIANA,MAINE,MARYLAND,MASSACHUSETTS,MICHIGAN,MINNESOTA,MISSISSIPPI,MISSOURI,MONTANA,NEBRASKA,NEVADA,NEW_HAMPSHIRE,NEW_JERSEY,NEW_MEXICO,NEW_YORK,NORTH_CAROLINA,NORTH_DAKOTA,OHIO,OKLAHOMA,OREGON,PENNSYLVANIA,RHODE_ISLAND,SOUTH_CAROLINA,SOUTH_DAKOTA,TENNESSEE,TEXAS,UTAH,VERMONT,VIRGINIA,WASHINGTON,WEST_VIRGINIA,WISCONSIN,WYOMING,DISTRICT_OF_COLUMBIA"
        },
        {
            "fieldName": "postalCode",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 10
        },
        {
            "fieldName": "tier",
            "fieldType": "Integer",
            "fieldValidateRules": [
                "min",
                "max"
            ],
            "fieldValidateRulesMin": 1,
            "fieldValidateRulesMax": 5
        },
        {
            "fieldName": "companyType",
            "fieldType": "CompanyType",
            "fieldValues": "PUBLIC,PRIVATE,SUBSIDIARY,PRIVATE_NON_PROFIT,SCHOOL,PRIVATE_COOPERATIVE,GOVERNMENT_OWNED,GOVERNMENT_AGENCY,PRIVATE_FOUNDATION,JOINT_VENTURE,HOLDING_COMPANY,PRIVATE_PARTNERSHIP"
        },
        {
            "fieldName": "isSubsidiary",
            "fieldType": "Boolean"
        },
        {
            "fieldName": "fiscalYearEndMonth",
            "fieldType": "Integer",
            "fieldValidateRules": [
                "min",
                "max"
            ],
            "fieldValidateRulesMin": 1,
            "fieldValidateRulesMax": 12
        },
        {
            "fieldName": "revenue",
            "fieldType": "Integer",
            "fieldValidateRules": [
                "min"
            ],
            "fieldValidateRulesMin": 0
        },
        {
            "fieldName": "totalEmployees",
            "fieldType": "Integer",
            "fieldValidateRules": [
                "min"
            ],
            "fieldValidateRulesMin": 1
        },
        {
            "fieldName": "employeesAtLocation",
            "fieldType": "Integer",
            "fieldValidateRules": [
                "min"
            ],
            "fieldValidateRulesMin": 1
        },
        {
            "fieldName": "industryGroup",
            "fieldType": "IndustryGroup",
            "fieldValues": "RETAIL,RESOURCES,MANUFACTURING,CHT,PROFESSIONAL_SERVICES,FINANCIAL_SERVICES,MEDIA_AND_ENTERTAINMENT,HEALTHCARE,UTILITIES,EDUCATION,NON_PROFIT,FOOD_AND_BEVERAGE,TRAVEL_AND_TOURISM,CONSUMER_PACKAGED_GOODS,REAL_ESTATE,TRAVEL_AND_TRANSPORTATION"
        },
        {
            "fieldName": "primaryIndustry",
            "fieldType": "Industry",
            "fieldValues": "MACHINERY_MANUFACTURING,OFFICE_SUPPLY_STORES,OIL_AND_GAS_EXPLORATION_AND_PRODUCTION,HOSPITALS,FABRICATED_METAL_PRODUCT_MANUFACTURING,ELECTRICAL_PRODUCTS_WHOLESALERS,FITNESS_CENTERS,WIRED_TELECOMMUNICATIONS_SERVICES,CONCRETE_AND_MASONRY_CONTRACTORS,ARTS_ENTERTAINMENT_AND_RECREATION_SECTOR,INDUSTRIAL_CONTROL_PRODUCTS_MANUFACTURING,COLLEGES_AND_UNIVERSITIES,COMMERCIAL_AND_INDUSTRIAL_EQUIPMENT_RENTAL_AND_LEASING,ENGINEERING_SERVICES,SECURITY_SYSTEM_SERVICES,PETROLEUM_AND_PETROLEUM_PRODUCTS_WHOLESALERS,REAL_ESTATE_INVESTMENT_TRUSTS,GIFT_NOVELTY_AND_SOUVENIR_STORES,CHILD_CARE_SERVICES,NEWSPAPER_PUBLISHERS,COMPUTER_SOFTWARE,BUILDING_MATERIAL_DEALERS,EDUCATION_AND_TRAINING_SERVICES,PUBLIC_SCHOOLS_K_12,HOTELS_MOTELS_AND_RESORTS,HEALTH_INSURANCE_CARRIERS,CONSULTING_SERVICES,PLASTIC_AND_RUBBER_PRODUCT_MANUFACTURING,PROPERTY_CASUALTY_INSURANCE_CARRIERS,STAFFING_SERVICES,NONPROFIT_INSTITUTIONS,BANKS_AND_CREDIT_UNIONS,GAS_STATIONS,WIRELESS_TELECOMMUNICATIONS_SERVICES,BUSINESS_SERVICES_SECTOR,SPORTING_GOODS_STORES,EDUCATION_SECTOR,SOCIAL_ASSISTANCE,MEDICAL_EQUIPMENT_AND_SUPPLIES_MANUFACTURING,MATERIAL_HANDLING_EQUIPMENT_MANUFACTURING,FREIGHT_FORWARDING_SERVICES,NATURAL_GAS_DISTRIBUTION_AND_MARKETING,POWER_LINE_AND_TELECOMMUNICATIONS_INFRASTRUCTURE_CONSTRUCTION_CONTRACTORS,ELECTRIC_UTILITIES,PHARMACEUTICAL_MANUFACTURING,PERFORMING_ARTS_COMPANIES,FARM_AND_GARDEN_EQUIPMENT_WHOLESALERS,CHEMICAL_WHOLESALERS,SCIENTIFIC_RESEARCH_AND_DEVELOPMENT_SERVICES,COMMERCIAL_AND_HEAVY_CONSTRUCTION_CONTRACTORS,AUTOMOBILE_DEALERS,SEMICONDUCTOR_AND_OTHER_ELECTRONIC_COMPONENT_MANUFACTURING,COMPUTER_AND_OFFICE_EQUIPMENT_WHOLESALERS_,WHOLESALE_SECTOR,COAL_MINING,INFORMATION_TECHNOLOGY_SERVICES,REAL_ESTATE,PHOTOGRAPHIC_SERVICES,ELECTRIC_POWER_TRANSMISSION_DISTRIBUTION_AND_MARKETING,COMMERCIAL_PRINTING,OIL_AND_GAS_FIELD_SERVICES,DAIRY_PRODUCTS_MANUFACTURING,PLUMBING_AND_HVAC_CONTRACTORS,SCIENTIFIC_AND_TECHNICAL_INSTRUMENTS_MANUFACTURING,ELECTRICAL_CONTRACTORS,INTERNET_AND_MAIL_ORDER_RETAIL,INVESTMENT_FIRMS,USED_MERCHANDISE_STORES,HOME_HEALTH_CARE_SERVICES,FINANCIAL_TRANSACTION_PROCESSING,GROCERY_STORES_AND_SUPERMARKETS,AUTOMOBILE_PARTS_MANUFACTURING,FINANCE_AND_INSURANCE_SECTOR,DIRECT_MARKETING_SERVICES,TELECOMMUNICATIONS_SERVICES,MEDICAL_EQUIPMENT_AND_SUPPLY_WHOLESALERS,DEVELOPMENT_TOOLS_OPERATING_SYSTEMS_AND_UTILITIES_SOFTWARE,BUSINESS_AND_PROFESSIONAL_ASSOCIATIONS,COMMERCIAL_REAL_ESTATE_MANAGEMENT,OFFICE_SUPPLY_AND_PAPER_WHOLESALERS,DATA_STORAGE_SYSTEMS_MANUFACTURING,OIL_AND_GAS_TRANSPORTATION_AND_STORAGE,ELECTRONIC_EQUIPMENT_REPAIR_SERVICES,SPECIALTY_TRUCKING,MANAGED_APPLICATION_AND_NETWORK_SERVICES,FAST_FOOD_AND_QUICK_SERVICE_RESTAURANTS,ALUMINUM_PRODUCTION,NONMETALLIC_MINERAL_PRODUCT_MANUFACTURING,BEER_WINE_AND_DISTILLED_SPIRITS_WHOLESALERS,BARS_AND_NIGHTCLUBS,ELECTROMEDICAL_ELECTROTHERAPEUTIC_AND_X_RAY_APPARATUS_MANUFACTURING,GRAIN_MILLING,SPECIALTY_CONTRACTORS,MEDIA,MOTOR_AND_GENERATOR_MANUFACTURING,ELECTRICAL_PRODUCTS_MANUFACTURING,MUTUAL_FUND_MANAGEMENT,BOOK_PUBLISHERS,NURSING_HOMES_AND_LONG_TERM_CARE_FACILITIES,TV_BROADCAST_AND_CABLE_NETWORKS,HOUSEHOLD_APPLIANCE_MANUFACTURING,BUS_TRANSPORTATION_SERVICES,GUIDED_MISSILE_AND_SPACE_VEHICLE_MANUFACTURING,FOOD_MANUFACTURING,WATER_AND_SEWER_UTILITIES,CLAY_PRODUCT_AND_REFRACTORY_MANUFACTURING,ARCHITECTURAL_AND_STRUCTURAL_METALS_MANUFACTURING,SEMICONDUCTOR_EQUIPMENT_MANUFACTURING,KIDNEY_DIALYSIS_CENTERS,MOVING_SERVICES,GOLD_AND_SILVER_MINING,OIL_AND_GAS_WELL_DRILLING,HIGHWAY_STREET_AND_BRIDGE_CONSTRUCTION_CONTRACTORS,FOOD_WHOLESALERS,METAL_VALVE_AND_PIPE_FITTING_MANUFACTURING,GAMBLING,SPORTING_GOODS_MANUFACTURING,MEAT_PRODUCT_MANUFACTURING,POULTRY_PRODUCT_MANUFACTURING,LIVESTOCK_AND_OTHER_ANIMAL_FOOD_MANUFACTURING,BREWERIES,WOOD_WINDOW_AND_DOOR_MANUFACTURING,ELECTRIC_POWER_GENERATION,GRANTMAKING_FOUNDATIONS,ELECTRICAL_PLUMBING_AND_HARDWARE_WHOLESALERS,TRUCKLOAD_CARRIERS,CEMENT_AND_CONCRETE_PRODUCT_MANUFACTURING,FINANCIAL_PLANNERS_AND_INVESTMENT_ADVISERS,CONTROL_ELECTROMEDICAL_MEASURING_AND_NAVIGATIONAL_INSTRUMENTS_MANUFACTURING,PHYSICIANS,VENTURE_CAPITAL,ASSET_MANAGEMENT,MENS_CLOTHING_MANUFACTURING,AMBULATORY_HEALTH_CARE_SERVICES,COMPUTER_PERIPHERAL_EQUIPMENT_MANUFACTURING,CONVENIENCE_STORES_AND_TRUCK_STOPS,COMPUTER_MANUFACTURING,INDUSTRIAL_EQUIPMENT_WHOLESALERS,RESIDENTIAL_CONSTRUCTION_CONTRACTORS,TRANSPORTATION_SERVICES_SECTOR,LODGING,RESIDENTIAL_PROPERTY_INVESTMENT,RAILROADS,WIRELESS_TELECOMMUNICATIONS_EQUIPMENT_MANUFACTURING,CHEMICAL_MANUFACTURING,METAL_ORE_MINING,MINING,CONSTRUCTION_SECTOR,BAKERY_PRODUCT_MANUFACTURING,INSURANCE_AGENCIES_AND_BROKERAGES,WAREHOUSING_AND_STORAGE,ROOFING_SIDING_AND_SHEET_METAL_CONTRACTORS,TEXTILE_MANUFACTURING,OIL_AND_GAS_FIELD_EQUIPMENT_MANUFACTURING,SPECIALTY_FOOD_STORES,NATURAL_GAS_PIPELINES,MARKET_RESEARCH_AND_POLLING_SERVICES,DIAGNOSTIC_SUBSTANCE_MANUFACTURING,SECURITY_SOFTWARE,TIRE_WHOLESALERS,FARM_SUPPORT_SERVICES,VENDING_MACHINE_OPERATORS,CASUAL_RESTAURANTS,LEGAL_SERVICES,MEMBERSHIP_ORGANIZATIONS,MENTAL_HEALTH_AND_SUBSTANCE_ABUSE_SERVICES,RELIGIOUS_ORGANIZATIONS,COLLECTION_AGENCIES,AGRICULTURAL_CHEMICAL_MANUFACTURING,HARDWARE_AND_FASTENER_MANUFACTURING,SITE_PREPARATION_CONTRACTORS,DRUG_STORES,RADIO_BROADCASTING_AND_PROGRAMMING,RESIDENTIAL_REAL_ESTATE_BROKERAGE_AND_MANAGEMENT,RETAIL_SECTOR,FURNITURE_STORES,OFFICE_FURNITURE_FIXTURES_AND_EQUIPMENT_MANUFACTURING,PROFESSIONAL_SERVICES_SECTOR,PUBLISHING,SPECIALTY_EATERIES,RESTAURANTS,LANDSCAPING_SERVICES,FURNITURE_MANUFACTURING,PLASTIC_RESIN_AND_SYNTHETIC_FIBER_MANUFACTURING,AMBULANCE_SERVICES,SECURITY_PRODUCTS_MANUFACTURING,ARCHITECTURAL_AND_ENGINEERING_SERVICES,LENDING,AUTOMOBILE_RENTAL_AND_LEASING,METALWORKING_MACHINERY_MANUFACTURING,STEEL_SERVICE_CENTERS_AND_OTHER_METAL_WHOLESALERS,TRUCK_TRAILER_MANUFACTURING,AIRLINES,NONMETALLIC_MINERAL_MINING_AND_QUARRYING,ASPHALT_PRODUCTS_MANUFACTURING,PETROLEUM_REFINING,SALES_PROMOTION_SERVICES,CHARTER_AND_OTHER_NONSCHEDULED_AIR_TRANSPORTATION_SERVICES,CONVERTED_PAPER_PRODUCTS_MANUFACTURING,TRAVEL_AGENCIES_AND_SERVICES,MORTGAGE_BANKING,DRUG_WHOLESALERS_,HAZARDOUS_WASTE_SERVICES,FOOTWEAR_MANUFACTURING,SUGAR_MANUFACTURING,RENTAL_AND_LEASING,SOLID_WASTE_SERVICES_AND_RECYCLING,INDUSTRIAL_SUPPLY_WHOLESALERS,ACCOUNTING_SERVICES,TELEPHONE_CALL_CENTERS,RESIDENTIAL_REAL_ESTATE_DEVELOPMENT,LIFE_INSURANCE_CARRIERS,SECURITIES_BROKERAGES,HOME_FURNITURE_AND_HOUSEWARES_STORES,TV_PROGRAM_PRODUCTION_AND_DISTRIBUTION,MOTION_PICTURE_PRODUCTION_AND_DISTRIBUTION,ADVERTISING_AGENCIES,MOVIE_THEATERS,ELECTRONIC_COMPONENT_WHOLESALERS,TELECOMMUNICATIONS_RESELLERS,HEALTH_CARE_MANAGEMENT_SOFTWARE,ENVIRONMENTAL_CONSULTING_SERVICES"
        },
        {
            "fieldName": "isBestPlacesToWork",
            "fieldType": "Boolean"
        },
        {
            "fieldName": "isValuesMatch",
            "fieldType": "Boolean"
        },
        {
            "fieldName": "linkedinIds",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 3,
            "fieldValidateRulesMaxlength": 100
        }
    ],
    "changelogDate": "20170203172118",
    "entityTableName": "company",
    "dto": "mapstruct",
    "pagination": "infinite-scroll",
    "service": "serviceClass"
}

CompanyNote.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "many-to-one",
            "relationshipName": "company",
            "otherEntityName": "company",
            "otherEntityField": "id"
        }
    ],
    "fields": [
        {
            "fieldName": "note",
            "fieldType": "String",
            "fieldValidateRules": [
                "required",
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 1,
            "fieldValidateRulesMaxlength": 300
        },
        {
            "fieldName": "time",
            "fieldType": "ZonedDateTime",
            "fieldValidateRules": [
                "required"
            ]
        }
    ],
    "changelogDate": "20170203172119",
    "entityTableName": "company_note",
    "dto": "mapstruct",
    "pagination": "no",
    "service": "serviceClass"
}

Employment.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "one-to-one",
            "relationshipName": "company",
            "otherEntityName": "company",
            "otherEntityField": "id",
            "ownerSide": true,
            "otherEntityRelationshipName": "employment"
        },
        {
            "relationshipType": "many-to-one",
            "relationshipName": "person",
            "otherEntityName": "person",
            "otherEntityField": "id"
        }
    ],
    "fields": [
        {
            "fieldName": "title",
            "fieldType": "String"
        },
        {
            "fieldName": "startDate",
            "fieldType": "LocalDate"
        },
        {
            "fieldName": "endDate",
            "fieldType": "LocalDate"
        }
    ],
    "changelogDate": "20170203172123",
    "entityTableName": "employment",
    "dto": "mapstruct",
    "pagination": "pagination",
    "service": "serviceClass"
}

NetworkLead.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "one-to-one",
            "relationshipName": "person",
            "otherEntityName": "person",
            "otherEntityField": "id",
            "ownerSide": true,
            "otherEntityRelationshipName": "networkLead"
        },
        {
            "relationshipType": "one-to-many",
            "relationshipName": "notes",
            "otherEntityName": "networkLeadContact",
            "otherEntityRelationshipName": "lead"
        },
        {
            "relationshipType": "many-to-one",
            "relationshipName": "user",
            "otherEntityName": "user",
            "otherEntityField": "login"
        }
    ],
    "fields": [
        {
            "fieldName": "status",
            "fieldType": "NetworkLeadStatus",
            "fieldValues": "ACTIVE,INACTIVE,ON_HOLD"
        },
        {
            "fieldName": "contactSchedule",
            "fieldType": "Cycle",
            "fieldValues": "DAILY,WEEKLY,BI_WEEKLY,MONTHLY,QUARTERLY,SEMI_ANNUALLY,ANNUALLY"
        }
    ],
    "changelogDate": "20170203172120",
    "entityTableName": "network_lead",
    "dto": "mapstruct",
    "pagination": "no",
    "service": "serviceClass"
}

NetworkLeadContact.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "many-to-one",
            "relationshipName": "lead",
            "otherEntityName": "networkLead",
            "otherEntityField": "id"
        }
    ],
    "fields": [
        {
            "fieldName": "note",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 1,
            "fieldValidateRulesMaxlength": 200
        },
        {
            "fieldName": "time",
            "fieldType": "ZonedDateTime",
            "fieldValidateRules": [
                "required"
            ]
        },
        {
            "fieldName": "type",
            "fieldType": "ContactType",
            "fieldValues": "EMAIL,VMAIL,PHONE,MEETING,BREAKFAST,LUNCH,DINNER,COFFEE,TEXT"
        }
    ],
    "changelogDate": "20170203172121",
    "entityTableName": "network_lead_contact",
    "dto": "mapstruct",
    "pagination": "no",
    "service": "serviceClass"
}

Person.json

{
    "fluentMethods": true,
    "relationships": [
        {
            "relationshipType": "one-to-one",
            "relationshipName": "currentEmployment",
            "otherEntityName": "employment",
            "otherEntityField": "id",
            "ownerSide": true,
            "otherEntityRelationshipName": "person"
        },
        {
            "relationshipType": "one-to-many",
            "relationshipName": "employmentHistory",
            "otherEntityName": "employment",
            "otherEntityRelationshipName": "person"
        },
        {
            "relationshipType": "many-to-many",
            "otherEntityRelationshipName": "",
            "relationshipName": "connectedTo",
            "otherEntityName": "person",
            "otherEntityField": "id",
            "ownerSide": true
        },
        {
            "relationshipType": "many-to-many",
            "otherEntityRelationshipName": "network",
            "relationshipName": "user",
            "otherEntityName": "user",
            "otherEntityField": "login",
            "ownerSide": true
        }
    ],
    "fields": [
        {
            "fieldName": "firstName",
            "fieldType": "String"
        },
        {
            "fieldName": "lastName",
            "fieldType": "String"
        },
        {
            "fieldName": "email",
            "fieldType": "String"
        },
        {
            "fieldName": "phoneNumber",
            "fieldType": "String"
        },
        {
            "fieldName": "city",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 50
        },
        {
            "fieldName": "state",
            "fieldType": "State",
            "fieldValues": "ALABAMA,ALASKA,ARIZONA,ARKANSAS,CALIFORNIA,COLORADO,CONNECTICUT,DELAWARE,FLORIDA,GEORGIA,HAWAII,IDAHO,ILLINOIS,INDIANA,IOWA,KANSAS,KENTUCKY,LOUISIANA,MAINE,MARYLAND,MASSACHUSETTS,MICHIGAN,MINNESOTA,MISSISSIPPI,MISSOURI,MONTANA,NEBRASKA,NEVADA,NEW_HAMPSHIRE,NEW_JERSEY,NEW_MEXICO,NEW_YORK,NORTH_CAROLINA,NORTH_DAKOTA,OHIO,OKLAHOMA,OREGON,PENNSYLVANIA,RHODE_ISLAND,SOUTH_CAROLINA,SOUTH_DAKOTA,TENNESSEE,TEXAS,UTAH,VERMONT,VIRGINIA,WASHINGTON,WEST_VIRGINIA,WISCONSIN,WYOMING,DISTRICT_OF_COLUMBIA"
        },
        {
            "fieldName": "postalCode",
            "fieldType": "String",
            "fieldValidateRules": [
                "minlength",
                "maxlength"
            ],
            "fieldValidateRulesMinlength": 5,
            "fieldValidateRulesMaxlength": 10
        },
        {
            "fieldName": "linkedinId",
            "fieldType": "String"
        },
        {
            "fieldName": "facebookId",
            "fieldType": "String"
        },
        {
            "fieldName": "twitterId",
            "fieldType": "String"
        },
        {
            "fieldName": "googlePlusId",
            "fieldType": "String"
        }
    ],
    "changelogDate": "20170203172122",
    "entityTableName": "person",
    "dto": "mapstruct",
    "pagination": "infinite-scroll",
    "service": "serviceClass"
}
Browsers and Operating System

java version "1.8.0_112" Java(TM) SE Runtime Environment (build 1.8.0_112-b16) Java HotSpot(TM) 64-Bit Server VM (build 25.112-b16, mixed mode)

git version 2.10.1 (Apple Git-78)

node: v6.9.4

npm: 4.1.1

bower: 1.8.0

gulp: [11:07:31] CLI version 1.2.2

yeoman: 1.8.5

yarn: 0.19.1

Docker version 1.13.0, build 49bf474

docker-compose version 1.10.0, build 4bd6f1a

pascalgrimaud commented 7 years ago

I think the problem comes from: "fieldName": "type" in NetworkLeadContact.json

With Angular2, there can be some entities name which need to be excluded. Only the community can report it when using JHipster4.

Thanks for using properly the template and yo jhipster:info

gmarziou commented 7 years ago

I also added typescript reserved words

jhipster/jhipster-core#104