Skip to content

Commit

Permalink
fix(frontedn/statetpl): simplify checked codes
Browse files Browse the repository at this point in the history
  • Loading branch information
suyuan32 committed Oct 27, 2024
1 parent 688dd01 commit 4ca78f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/vben/staterender.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
loading: record.pendingStatus,
onChange(checked, _) {
record.pendingStatus = true;
const newState = checked ? true : false;
const newState = !!checked;
update{{.modelName}}({ id: record.id, state: newState })
.then(() => {
record.state = newState;
Expand Down

0 comments on commit 4ca78f8

Please sign in to comment.