component-shipinlv 1.1.15 → 1.1.17
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +3 -0
- package/dist/VideoPublish/account-manage/home.js +8 -1
- package/dist/VideoPublish/account-manage/setting/index.js +5 -0
- package/dist/VideoPublish/create-task/index.js +6 -1
- package/dist/lib/Tool.d.ts +1 -1
- package/dist/lib/accountManageSettingConfig.js +8 -8
- package/dist/window.d.ts +2 -0
- package/package.json +1 -1
@@ -6,6 +6,7 @@ import { VideoPlatform } from "../..";
|
|
6
6
|
import HomePageAccountList from "./list";
|
7
7
|
import Time from "../../UI/Time";
|
8
8
|
import { IeOutlined } from "@ant-design/icons";
|
9
|
+
import Tool from "../../lib/Tool";
|
9
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
10
11
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
11
12
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
@@ -89,11 +90,17 @@ var VideoPublishAccountManageHomePage = function VideoPublishAccountManageHomePa
|
|
89
90
|
_useState4 = _slicedToArray(_useState3, 1),
|
90
91
|
openMenuItems = _useState4[0];
|
91
92
|
var onOpen = function onOpen(key) {
|
93
|
+
var _window$getBridge;
|
92
94
|
switch (key) {
|
93
95
|
case 'creator':
|
94
|
-
|
96
|
+
var url = '';
|
97
|
+
if (accountDetail.platform === 'douyin') {
|
98
|
+
url = 'https://creator.douyin.com/creator-micro/home';
|
99
|
+
}
|
100
|
+
(_window$getBridge = window.getBridge()) === null || _window$getBridge === void 0 || _window$getBridge.openVideoAccountBrowser(accountDetail.platform, '', accountDetail.accountId, url);
|
95
101
|
break;
|
96
102
|
}
|
103
|
+
Tool.toast('正在打开浏览器, 请稍等...', 8);
|
97
104
|
};
|
98
105
|
return /*#__PURE__*/_jsxs("div", {
|
99
106
|
className: "videoPublishAccountManageHome",
|
@@ -97,6 +97,11 @@ var AccountManageSettingPage = function AccountManageSettingPage(_ref) {
|
|
97
97
|
label: "\u8C37\u6B4C\u6D4F\u89C8\u5668\uFF08Chrome\uFF09\u4F4D\u7F6E"
|
98
98
|
// name="disabledApplyTask"
|
99
99
|
,
|
100
|
+
extra: /*#__PURE__*/_jsxs("div", {
|
101
|
+
children: ["Chrome \u7248\u672C\u63A8\u8350 110 \u4EE5\u4E0A\uFF08\u6253\u5F00 \u8C37\u6B4C\u6D4F\u89C8\u5668\uFF0C\u8F93\u5165 ", /*#__PURE__*/_jsx("a", {
|
102
|
+
children: "chrome://settings/help"
|
103
|
+
}), " \u53EF\u67E5\u8BE2\u7248\u672C\uFF09"]
|
104
|
+
}),
|
100
105
|
children: /*#__PURE__*/_jsx(FileSelect, {
|
101
106
|
path: formData.chromePath,
|
102
107
|
disabled: false,
|
@@ -16,6 +16,7 @@ import { useRequest } from "@umijs/hooks";
|
|
16
16
|
import * as VideoPublishController from "../../service/api/VideoPublishController";
|
17
17
|
import fileSelect from "../../base/fileSelect";
|
18
18
|
import VideoPublishCreateTaskBase from "./base";
|
19
|
+
import dayjs from "dayjs";
|
19
20
|
import { jsx as _jsx } from "react/jsx-runtime";
|
20
21
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
21
22
|
var VideoPublishCreateTask = function VideoPublishCreateTask(_ref) {
|
@@ -173,6 +174,8 @@ var VideoPublishCreateTask = function VideoPublishCreateTask(_ref) {
|
|
173
174
|
if (data.startTime) {
|
174
175
|
var _values$startTime;
|
175
176
|
data.startTime = values.startTime ? parseInt((((_values$startTime = values.startTime) === null || _values$startTime === void 0 ? void 0 : _values$startTime.valueOf()) * 0.001).toFixed(0)) : 0;
|
177
|
+
} else {
|
178
|
+
data.startTime = Math.floor(Date.now() * 0.001);
|
176
179
|
}
|
177
180
|
if (videoList.length === 0) {
|
178
181
|
Tool.toastError('视频为空,请选择视频');
|
@@ -199,7 +202,9 @@ var VideoPublishCreateTask = function VideoPublishCreateTask(_ref) {
|
|
199
202
|
labelCol: {
|
200
203
|
span: formLabelSpan
|
201
204
|
},
|
202
|
-
initialValues: _objectSpread({}, formData),
|
205
|
+
initialValues: _objectSpread(_objectSpread({}, formData), {}, {
|
206
|
+
startTime: typeof formData.startTime === 'number' ? dayjs(formData.startTime) : null
|
207
|
+
}),
|
203
208
|
disabled: disabled || loadingTask,
|
204
209
|
scrollToFirstError: true,
|
205
210
|
onFinish: onFinish,
|
package/dist/lib/Tool.d.ts
CHANGED
@@ -161,7 +161,7 @@ declare const Tool: {
|
|
161
161
|
OsPathSeparator(): string;
|
162
162
|
getTitleByPath(path: string): string;
|
163
163
|
h5Pay(query: Pay.H5PayQuery): void;
|
164
|
-
notification(type: "success" | "
|
164
|
+
notification(type: "success" | "error" | "info" | "warning", message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
|
165
165
|
notificationSuccess(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
|
166
166
|
notificationError(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
|
167
167
|
notificationWarning(message: string, description?: import("react").ReactNode, options?: NotificationOptions): void;
|
@@ -7,16 +7,16 @@ var AccountManageSettingConfig = function AccountManageSettingConfig(data) {
|
|
7
7
|
store.set(AccountManageSettingConfigKey, _objectSpread({}, data));
|
8
8
|
return data;
|
9
9
|
}
|
10
|
-
console.log('AccountManageSettingConfig get');
|
11
10
|
var chromePath = (_window$getBridge = (_window = window).getBridge) === null || _window$getBridge === void 0 ? void 0 : _window$getBridge.call(_window).getChromiumPath();
|
12
|
-
|
11
|
+
console.log('AccountManageSettingConfig get:', chromePath);
|
12
|
+
var storeData = store.get(AccountManageSettingConfigKey);
|
13
|
+
var outData = _objectSpread(_objectSpread({
|
13
14
|
isChromeOpen: false,
|
14
|
-
disabledApplyTask: false
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
}
|
15
|
+
disabledApplyTask: false
|
16
|
+
}, storeData), {}, {
|
17
|
+
// 优先用存储的;
|
18
|
+
chromePath: storeData.chromePath || chromePath
|
19
|
+
});
|
20
20
|
return outData;
|
21
21
|
};
|
22
22
|
export default AccountManageSettingConfig;
|
package/dist/window.d.ts
CHANGED
@@ -18,6 +18,8 @@ declare interface Window{
|
|
18
18
|
onLog: ( log: ( query: any ) => void ) => void;
|
19
19
|
getChromiumPath: () => string;
|
20
20
|
getClientUniqueKey: () => string;
|
21
|
+
|
22
|
+
openVideoAccountBrowser: ( platform: string, subPlatform: string, accountId: string, url: string ) => void;
|
21
23
|
};
|
22
24
|
|
23
25
|
getClientIdentity: () => Promise<string>;
|