Отказ сервиса M2M в ЛК — словами (наша расшифровка или текст НРД), M2M43; «передавать информацию о расходах» в QUIK — по заявке клиента
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014FsEKyJrYF69Cj9ZXzFLRi
This commit is contained in:
@@ -72,13 +72,14 @@ func quikOutgoingBeforeSend(ctx context.Context, rc *RuntimeConfig, req *m2m.M2M
|
||||
return nil
|
||||
}
|
||||
inn := string(req.Data.ReceivingDepository.INN)
|
||||
passExpenses := req.Header.CostInfo.Yes != nil // «передавать информацию о расходах» — как в заявке клиента
|
||||
var done []string
|
||||
for _, sec := range req.Data.TransferredSecurities.Securities {
|
||||
isin, qty := quikSecISIN(sec), quikSecQty(sec.Quantity)
|
||||
if isin == "" || qty <= 0 {
|
||||
continue
|
||||
}
|
||||
if _, err := QuikOutRegister(ctx, rc, guid, code, contract, isin, qty, inn, "", true); err != nil {
|
||||
if _, err := QuikOutRegister(ctx, rc, guid, code, contract, isin, qty, inn, "", passExpenses); err != nil {
|
||||
for _, d := range done {
|
||||
_, _ = QuikOutDeny(ctx, rc, guid, d, "Отмена: не удалось заблокировать другую бумагу перевода")
|
||||
}
|
||||
@@ -354,7 +355,7 @@ func registerQuikOps(mux *http.ServeMux, rc *RuntimeConfig, svc *Service) {
|
||||
flash("QUIK МНП: бумага " + isin + " не найдена в заявке")
|
||||
return
|
||||
}
|
||||
if _, err := QuikOutRegister(ctx, rc, guid, code, contract, isin, qty, string(deal.Request.Data.ReceivingDepository.INN), "", true); err != nil {
|
||||
if _, err := QuikOutRegister(ctx, rc, guid, code, contract, isin, qty, string(deal.Request.Data.ReceivingDepository.INN), "", deal.Request.Header.CostInfo.Yes != nil); err != nil {
|
||||
flash("QUIK МНП: " + err.Error())
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user