Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[t-input] 使用number类型绑定数值无法编译成功 #2473

Closed
liugt34 opened this issue Dec 5, 2023 · 2 comments
Closed

[t-input] 使用number类型绑定数值无法编译成功 #2473

liugt34 opened this issue Dec 5, 2023 · 2 comments
Labels
question This is a question, not a bug

Comments

@liugt34
Copy link

liugt34 commented Dec 5, 2023

tdesign-miniprogram 版本

1.2.3

重现链接

No response

重现步骤

<t-input label="出勤人数 " type="number" placeholder="请输入出勤人数" align="right" suffix="人" t-class-label="input_required" maxlength="100" model:value="{{peopleNo}}" clearable />

data中 peopleNo: 0,编译报错
image

改成 peopleNo: ‘0’, 正常编译

期望结果

可以绑定数值类型,这样更符合逻辑

实际结果

无法绑定数值类型

基础库版本

No response

补充说明

No response

Copy link
Contributor

github-actions bot commented Dec 5, 2023

👋 @liugt34,感谢给 TDesign 提出了 issue。
请根据 issue 模版确保背景信息的完善,我们将调查并尽快回复你。

@betavs
Copy link
Collaborator

betavs commented Dec 5, 2023

<t-input
  label="出勤人数 "
  type="number"
  placeholder="请输入出勤人数"
  align="right"
  suffix=""
  t-class-label="input_required"
  maxlength="100"
  value="{{peopleNo}}"
  clearable
/>

@betavs betavs added the question This is a question, not a bug label Dec 5, 2023
@anlyyao anlyyao closed this as completed Jan 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question This is a question, not a bug
Projects
None yet
Development

No branches or pull requests

3 participants