@anker-in/ui 0.2.3 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.next-refresh +1 -0
- package/dist/demo-room.js +45 -1
- package/dist/demo-room.js.map +1 -1
- package/dist/demo-room.mjs +45 -1
- package/dist/demo-room.mjs.map +1 -1
- package/dist/index.css +36 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +445 -5
- package/dist/index.d.ts +445 -5
- package/dist/index.js +8842 -4992
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7894 -4050
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
1785494036632 initial sync
|
package/dist/demo-room.js
CHANGED
|
@@ -603,7 +603,7 @@ function useDemoRooms(client, params, options) {
|
|
|
603
603
|
return () => {
|
|
604
604
|
cancelled = true;
|
|
605
605
|
};
|
|
606
|
-
}, [client, params.team_code, params.brand_website, params.locale, enabled]);
|
|
606
|
+
}, [client, params.team_code, params.brand_website, params.business_type, params.locale, enabled]);
|
|
607
607
|
return state;
|
|
608
608
|
}
|
|
609
609
|
var AntdMobileIsolated = ({
|
|
@@ -1335,6 +1335,7 @@ var DemoRoomApiClient = class {
|
|
|
1335
1335
|
* 获取门店列表
|
|
1336
1336
|
* @param params.team_code 团队编码
|
|
1337
1337
|
* @param params.brand_website 品牌站点
|
|
1338
|
+
* @param params.business_type 业务类型(可选)
|
|
1338
1339
|
* @param params.locale 语言偏好(可选)
|
|
1339
1340
|
*/
|
|
1340
1341
|
async getDemoRooms(params) {
|
|
@@ -1345,6 +1346,9 @@ var DemoRoomApiClient = class {
|
|
|
1345
1346
|
if (params.brand_website) {
|
|
1346
1347
|
searchParams.append("brand_website", params.brand_website);
|
|
1347
1348
|
}
|
|
1349
|
+
if (params.business_type) {
|
|
1350
|
+
searchParams.append("business_type", params.business_type);
|
|
1351
|
+
}
|
|
1348
1352
|
if (params.locale) {
|
|
1349
1353
|
searchParams.append("locale", params.locale);
|
|
1350
1354
|
}
|
|
@@ -1374,6 +1378,7 @@ var DemoRoomApiClient = class {
|
|
|
1374
1378
|
* @param params.start_date 开始日期 (YYYY-MM-DD)
|
|
1375
1379
|
* @param params.end_date 结束日期 (YYYY-MM-DD)
|
|
1376
1380
|
* @param params.timezone 时区(可选)
|
|
1381
|
+
* @param params.business_type 预约用途类型(可选,如 'pod')
|
|
1377
1382
|
*/
|
|
1378
1383
|
async getTimeslots(code, params) {
|
|
1379
1384
|
const searchParams = new URLSearchParams({
|
|
@@ -1383,6 +1388,9 @@ var DemoRoomApiClient = class {
|
|
|
1383
1388
|
if (params.timezone) {
|
|
1384
1389
|
searchParams.append("timezone", params.timezone);
|
|
1385
1390
|
}
|
|
1391
|
+
if (params.business_type) {
|
|
1392
|
+
searchParams.append("business_type", params.business_type);
|
|
1393
|
+
}
|
|
1386
1394
|
return this.request(
|
|
1387
1395
|
`/api/v1/store/demorooms/${code}/timeslots?${searchParams.toString()}`
|
|
1388
1396
|
);
|
|
@@ -1448,6 +1456,42 @@ var DemoRoomApiClient = class {
|
|
|
1448
1456
|
);
|
|
1449
1457
|
return response.booking;
|
|
1450
1458
|
}
|
|
1459
|
+
/**
|
|
1460
|
+
* 编辑预约
|
|
1461
|
+
* @param token 预约凭证 (cancel_token)
|
|
1462
|
+
* @param data 编辑数据
|
|
1463
|
+
*/
|
|
1464
|
+
async editBooking(token, data) {
|
|
1465
|
+
return this.request(`/api/v1/store/bookings/${token}/edit`, {
|
|
1466
|
+
method: "POST",
|
|
1467
|
+
body: JSON.stringify(data)
|
|
1468
|
+
});
|
|
1469
|
+
}
|
|
1470
|
+
/**
|
|
1471
|
+
* 签到预约(模式1:精确签到)
|
|
1472
|
+
* @param data 签到数据
|
|
1473
|
+
*/
|
|
1474
|
+
async checkinBooking(data) {
|
|
1475
|
+
const response = await this.request(
|
|
1476
|
+
"/api/v1/store/bookings/checkin",
|
|
1477
|
+
{
|
|
1478
|
+
method: "POST",
|
|
1479
|
+
body: JSON.stringify(data)
|
|
1480
|
+
}
|
|
1481
|
+
);
|
|
1482
|
+
return response.booking;
|
|
1483
|
+
}
|
|
1484
|
+
/**
|
|
1485
|
+
* 查询 POD 作品信息(模式1:精确查询)
|
|
1486
|
+
* @param bookingToken 预约凭证
|
|
1487
|
+
*/
|
|
1488
|
+
async getBookingDesign(bookingToken) {
|
|
1489
|
+
const searchParams = new URLSearchParams();
|
|
1490
|
+
searchParams.append("booking_token", bookingToken);
|
|
1491
|
+
return this.request(
|
|
1492
|
+
`/api/v1/store/bookings/design?${searchParams.toString()}`
|
|
1493
|
+
);
|
|
1494
|
+
}
|
|
1451
1495
|
};
|
|
1452
1496
|
function createDemoRoomApi(config) {
|
|
1453
1497
|
return new DemoRoomApiClient(config);
|