川少博客 2022-01-13 19:00 采纳率: 0%
浏览 10

关于#ts#的问题,如何解决?(标签-ssL|关键词-seT)

问题遇到的现象和发生背景

接手别人的项目,就有这个问题,在本地运行是能的就是抱着个错,然后打包不行,求问哪位解决一下
https://img-mid.csdnimg.cn/release/static/image/mid/ask/418290170246197.png

操作环境、软件版本等信息

报错
一、Type '{ id: any; enterpriseName: any; enterpriseAbbreviation: any; enterpriseTax: any; businessLicense: never; legalRepresentative: any; province: any; bankAccount: any; bankAccounts: any; enterprisePerson: any; phoneNum: any; companyTel: any; companyAddress: any; legalRepresentativeIdCard: any; }' is not assignable to type '{ enterpriseName: string; enterpriseAbbreviation: string; enterpriseTax: string; businessLicense: never[]; legalRepresentative: string; province: {}; bankAccount: string; bankAccounts: string; ... 4 more ...; legalRepresentativeIdCard: string; }'.
Object literal may only specify known properties, and 'id' does not exist in type '{ enterpriseName: string; enterpriseAbbreviation: string; enterpriseTax: string; businessLicense: never[]; legalRepresentative: string; province: {}; bankAccount: string; bankAccounts: string; ... 4 more ...; legalRepresentativeIdCard: string; }'.
二、Property 'id' does not exist on type '{ bankAccount: string; bankOfDeposit: string; contactsTel: string; enterpriseAbbreviation: string; enterpriseAddress: string; enterpriseContacts: string; enterpriseName: string; enterpriseTaxNo: string; ... 4 more ...; businessLicenseId: string; }
三、
Property 'id' does not exist on type '{ enterpriseName: string; enterpriseAbbreviation: string; enterpriseTax: string; businessLicense: never[]; legalRepresentative: string; province: {}; bankAccount: string; bankAccounts: string; ... 4 more ...; legalRepresentativeIdCard: string; }'.

尝试过的解决方法
我想要达到的结果
  • 写回答

1条回答 默认 最新

  • 禅思院 前端领域优质创作者 2022-01-14 10:00
    关注

    服啦 不会ts 就不要拉 看到好多any 瞬间不想看拉

    评论

报告相同问题?

问题事件

  • 创建了问题 1月13日

悬赏问题

  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100
  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)
  • ¥15 keil里为什么main.c定义的函数在it.c调用不了
  • ¥50 切换TabTip键盘的输入法
  • ¥15 可否在不同线程中调用封装数据库操作的类
  • ¥15 微带串馈天线阵列每个阵元宽度计算
  • ¥15 keil的map文件中Image component sizes各项意思
  • ¥20 求个正点原子stm32f407开发版的贪吃蛇游戏