Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
T treasure
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 12
    • Issues 12
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • External wiki
    • External wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • FE
  • treasure
  • Issues
  • #47

Closed
Open
Created Oct 21, 2021 by lizijian@lizijian

request请求对参数做过滤及移除空值处理时,没有做深拷贝处理,导致原数据被删除,双向绑定失效

原因

参数数据与表单项通过v-model建立双向绑定,当某一项数据为''或null时,传入request中该字段被删除,导致v-model绑定的原数据被删除,双向绑定失效

解决方法

使用deepCopy(params)方法或JSON.parse(JSON.stringify(params))深拷贝一下
Edited Oct 21, 2021 by lizijian
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking