* fix: prevent model create from wiping existing pricing for same name * fix(models): keep create from wiping pricing for any existing name Prefilling from the drawer's open-time model name only covered the missing-models entry point. Submit deletes the pricing entries for the name in the form, which is editable and starts empty from the toolbar "Create model" button, so both a hand-typed existing name and a renamed prefill still dropped the configured pricing. Track the name whose pricing was actually read into the form and scope the delete-then-readd to it, or to a name the user explicitly priced. Editing still clears pricing by emptying the fields, a prefilled create does too, and a name the form never loaded is left alone -- which also stops an edit that renames onto an existing name from destroying that name's pricing. Read the prefill through one shared readPricingConfig instead of duplicating the seven-map parse in both branches, and open the advanced section for ratios that are configured as 0 rather than only truthy ones.
| Name |
Last commit
|
Last Update |
|---|---|---|
| .agents/skills | Loading commit data... | |
| .github | Loading commit data... | |
| bin | Loading commit data... | |
| common | Loading commit data... | |
| constant | Loading commit data... | |
| controller | Loading commit data... | |
| docs | Loading commit data... | |
| dto | Loading commit data... | |
| electron | Loading commit data... | |
| i18n | Loading commit data... | |
| logger | Loading commit data... | |
| middleware | Loading commit data... | |
| model | Loading commit data... | |
| oauth | Loading commit data... | |
| pkg | Loading commit data... | |
| relay | Loading commit data... | |
| router | Loading commit data... | |
| service | Loading commit data... | |
| setting | Loading commit data... | |
| types | Loading commit data... | |
| web | Loading commit data... | |
| .dockerignore | Loading commit data... | |
| .env.example | Loading commit data... | |
| .gitattributes | Loading commit data... | |
| .gitignore | Loading commit data... | |
| AGENTS.md | Loading commit data... | |
| CLAUDE.md | Loading commit data... | |
| Dockerfile | Loading commit data... | |
| Dockerfile.dev | Loading commit data... | |
| LICENSE | Loading commit data... | |
| NOTICE | Loading commit data... | |
| README.en.md | Loading commit data... | |
| README.fr.md | Loading commit data... | |
| README.ja.md | Loading commit data... | |
| README.md | Loading commit data... | |
| README.zh_CN.md | Loading commit data... | |
| README.zh_TW.md | Loading commit data... | |
| THIRD-PARTY-LICENSES.md | Loading commit data... | |
| VERSION | Loading commit data... | |
| docker-compose.dev.yml | Loading commit data... | |
| docker-compose.yml | Loading commit data... | |
| go.mod | Loading commit data... | |
| go.sum | Loading commit data... | |
| main.go | Loading commit data... | |
| makefile | Loading commit data... | |
| new-api.service | Loading commit data... | |
| trusted_proxies.go | Loading commit data... | |
| trusted_proxies_test.go | Loading commit data... |