feat:寄卖增加对接客服,db脚本迁移修复

This commit is contained in:
2026-10-27 13:39:48 +08:00
parent 0de0fd7b58
commit 622bd779dd
25 changed files with 1515 additions and 106 deletions
@@ -7,11 +7,25 @@ import {
publishWorkerConsignment,
submitWorkerConsignmentGiftEvidence,
} from '../../services/worker-platform/consignment-worker-service.js'
import { fetchWorkerConsignmentContacts } from '../../services/worker-platform/consignment-contact-service.js'
import { sendRouteError } from '../../utils/http.js'
import { getRequiredWorkerSession, requireActiveWorker } from './session.js'
const router = Router()
/**
* GET /api/v1/worker/consignment/contacts
* 打手发布寄卖时的「对接客服」下拉:只返回启用中的名单
*/
router.get('/consignment/contacts', async (req, res) => {
try {
const result = await fetchWorkerConsignmentContacts()
res.json({ ok: true, data: result })
} catch (error) {
sendRouteError(res, error, '获取对接客服失败', '[worker/consignment/contacts]')
}
})
/**
* POST /api/v1/worker/consignment/publish
* 打手在接单平台直接提报苏尔南手枪寄卖