feat: add Z12/Z13 bind APIs, stock import, and sync docs

Enable auto default sync channels on agent activate, bind-code/phone confirm flows, publish ALTER, and align admin/yuheng docs with the production bind path.
This commit is contained in:
whm
2026-08-05 11:47:20 +08:00
parent b04b180d30
commit cb56e6847e
31 changed files with 1882 additions and 91 deletions

View File

@@ -140,6 +140,19 @@ func (s *MemoryStore) ListByTenant(_ context.Context, tenantID int64) ([]AppSumm
return out, nil
}
func (s *MemoryStore) ListPublishedApps(_ context.Context) ([]*AppRecord, error) {
s.mu.RLock()
defer s.mu.RUnlock()
out := make([]*AppRecord, 0)
for _, app := range s.apps {
if app == nil || app.Status != StatusPublished {
continue
}
out = append(out, cloneApp(app))
}
return out, nil
}
func summarizeApp(app *AppRecord) AppSummary {
sum := AppSummary{
AppID: app.AppID,