@blueking/ai-ui-sdk 0.1.2-beta.11 → 0.1.2-beta.15
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/components/render-aside/index.vue.css +9 -9
- package/dist/components/render-aside/index.vue.js +1 -1
- package/dist/components/render-auth/auth-dialog-fn.d.ts +1 -1
- package/dist/components/render-auth/auth-dialog-fn.ts.js +2 -2
- package/dist/components/render-auth/auth-dialog.script.vue.js.js +7 -4
- package/dist/components/render-auth/auth-dialog.vue.d.ts +1 -1
- package/dist/components/render-auto-height-textarea/index.vue.css +11 -11
- package/dist/components/render-auto-height-textarea/index.vue.js +1 -1
- package/dist/components/render-choose-tag/index.vue.css +8 -8
- package/dist/components/render-choose-tag/index.vue.js +1 -1
- package/dist/components/render-collapse/index.vue.css +2 -2
- package/dist/components/render-collapse/index.vue.js +1 -1
- package/dist/components/render-dataset/components/edit-dataset-data/index.vue.css +3 -3
- package/dist/components/render-dataset/components/edit-dataset-data/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/index.vue.css +4 -4
- package/dist/components/render-dataset/components/operation-record/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/table/index.vue.css +1 -1
- package/dist/components/render-dataset/components/operation-record/table/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.css +2 -2
- package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset/index.vue.css +2 -2
- package/dist/components/render-dataset/components/plus-dataset/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/footer.vue.css +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/footer.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/index.script.vue.js.js +5 -3
- package/dist/components/render-dataset/components/plus-dataset-data/form/index.vue.css +2 -2
- package/dist/components/render-dataset/components/plus-dataset-data/form/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/index.script.vue.js.js +2 -1
- package/dist/components/render-dataset/components/source-type-icon/index.script.vue.js.js +2 -2
- package/dist/components/render-dataset/components/source-type-icon/index.vue.js +0 -2
- package/dist/components/render-dataset/index.script.vue.js.js +10 -1
- package/dist/components/render-dataset/index.vue.css +1 -1
- package/dist/components/render-dataset/index.vue.js +1 -1
- package/dist/components/render-dataset-detail/index.script.vue.js.js +32 -1
- package/dist/components/render-dataset-detail-origin-data/components/batch-operation/index.script.vue.js.js +3 -2
- package/dist/components/render-dataset-detail-origin-data/components/table/index.script.vue.js +5 -5
- package/dist/components/render-dataset-detail-origin-data/components/table/index.vue.css +1 -1
- package/dist/components/render-dataset-detail-origin-data/components/table/index.vue.js +1 -1
- package/dist/components/render-dataset-detail-origin-data/index.vue.css +3 -3
- package/dist/components/render-dataset-detail-origin-data/index.vue.js +1 -1
- package/dist/components/render-dataset-list/components/main.vue.css +3 -3
- package/dist/components/render-dataset-list/components/main.vue.js +1 -1
- package/dist/components/render-dataset-list/components/table.script.vue.js.js +2 -1
- package/dist/components/render-expand-collapse/index.vue.css +3 -3
- package/dist/components/render-expand-collapse/index.vue.js +1 -1
- package/dist/components/render-file-card/index.vue.css +11 -11
- package/dist/components/render-file-card/index.vue.js +1 -1
- package/dist/components/render-file-type-icon/index.vue.css +5 -5
- package/dist/components/render-file-type-icon/index.vue.js +1 -1
- package/dist/components/render-header/index.vue.css +5 -5
- package/dist/components/render-header/index.vue.js +1 -1
- package/dist/components/render-router-tab/index.vue.css +3 -3
- package/dist/components/render-router-tab/index.vue.js +1 -1
- package/dist/event/index.d.ts +3 -3
- package/dist/event/index.ts.js +2 -2
- package/dist/hooks/use-chat.ts.js +1 -1
- package/dist/hooks/use-dataset-http.d.ts +1 -1
- package/dist/hooks/use-dataset-http.ts.js +6 -3
- package/dist/http/fetch/error-interceptor.ts.js +6 -1
- package/dist/types/enum.d.ts +2 -1
- package/dist/types/enum.ts.js +1 -0
- package/package.json +1 -1
- package/dist/components/render-dataset/components/source-type-icon/index.vue.css +0 -10
@@ -1,12 +1,12 @@
|
|
1
1
|
|
2
|
-
.aside-home[data-v-
|
2
|
+
.aside-home[data-v-y2r466pv] {
|
3
3
|
width: 300px;
|
4
4
|
height: 100%;
|
5
5
|
background: #FFFFFF;
|
6
6
|
padding: 16px;
|
7
7
|
border-right: 1px solid #eaebf0;
|
8
8
|
}
|
9
|
-
[data-v-
|
9
|
+
[data-v-y2r466pv] .aside-item {
|
10
10
|
width: 268px;
|
11
11
|
line-height: 36px;
|
12
12
|
border-radius: 2px;
|
@@ -16,30 +16,30 @@
|
|
16
16
|
justify-content: space-between;
|
17
17
|
color: #979BA5;
|
18
18
|
}
|
19
|
-
[data-v-
|
19
|
+
[data-v-y2r466pv] .aside-item.is-tab {
|
20
20
|
background: #F5F7FA;
|
21
21
|
cursor: pointer;
|
22
22
|
color: #4D4F56;
|
23
23
|
}
|
24
|
-
[data-v-
|
24
|
+
[data-v-y2r466pv] .aside-item.is-tab:hover {
|
25
25
|
background: #F0F5FF;
|
26
26
|
}
|
27
|
-
[data-v-
|
27
|
+
[data-v-y2r466pv] .aside-item.active {
|
28
28
|
background: #F0F5FF;
|
29
29
|
color: #3A84FF;
|
30
30
|
font-weight: 700;
|
31
31
|
}
|
32
|
-
[data-v-
|
32
|
+
[data-v-y2r466pv] .aside-item.active .tab-num {
|
33
33
|
background: #3A84FF;
|
34
34
|
color: #fff;
|
35
35
|
}
|
36
|
-
[data-v-
|
36
|
+
[data-v-y2r466pv] .aside-item.active .active-text {
|
37
37
|
color: #3A84FF;
|
38
38
|
}
|
39
|
-
[data-v-
|
39
|
+
[data-v-y2r466pv] .aside-item .tab-name {
|
40
40
|
flex: 1;
|
41
41
|
}
|
42
|
-
[data-v-
|
42
|
+
[data-v-y2r466pv] .aside-item .tab-num {
|
43
43
|
background: #EAEBF0;
|
44
44
|
border-radius: 2px;
|
45
45
|
margin-left: 5px;
|
@@ -1,2 +1,2 @@
|
|
1
1
|
import type { IPermissionApplyData } from '@/types/permission';
|
2
|
-
export declare const renderAuthDialog: (perm: IPermissionApplyData) => void;
|
2
|
+
export declare const renderAuthDialog: (perm: IPermissionApplyData, cancelCallback?: Function) => void;
|
@@ -7,8 +7,8 @@ const getVnode = ()=>{
|
|
7
7
|
render(vNode, document.body);
|
8
8
|
return vNode;
|
9
9
|
};
|
10
|
-
export const renderAuthDialog = (perm)=>{
|
10
|
+
export const renderAuthDialog = (perm, cancelCallback)=>{
|
11
11
|
var _vNode_component_exposed, _vNode_component;
|
12
12
|
const vNode = getVnode();
|
13
|
-
(_vNode_component = vNode.component) === null || _vNode_component === void 0 ? void 0 : (_vNode_component_exposed = _vNode_component.exposed) === null || _vNode_component_exposed === void 0 ? void 0 : _vNode_component_exposed.handleShow(perm);
|
13
|
+
(_vNode_component = vNode.component) === null || _vNode_component === void 0 ? void 0 : (_vNode_component_exposed = _vNode_component.exposed) === null || _vNode_component_exposed === void 0 ? void 0 : _vNode_component_exposed.handleShow(perm, cancelCallback);
|
14
14
|
};
|
@@ -6,24 +6,27 @@ export default /*@__PURE__*/ _defineComponent({
|
|
6
6
|
const isShow = ref(false);
|
7
7
|
const perm = ref();
|
8
8
|
const tableData = ref();
|
9
|
+
let cancelCallback;
|
9
10
|
const handleApply = ()=>{
|
10
11
|
var _perm_value;
|
11
12
|
window.open((_perm_value = perm.value) === null || _perm_value === void 0 ? void 0 : _perm_value.apply_url, '_blank');
|
12
13
|
};
|
13
14
|
const handleClosed = ()=>{
|
14
15
|
isShow.value = false;
|
16
|
+
cancelCallback === null || cancelCallback === void 0 ? void 0 : cancelCallback();
|
15
17
|
};
|
16
|
-
const handleShow = (data)=>{
|
17
|
-
var _data_permission,
|
18
|
+
const handleShow = (data, callback)=>{
|
19
|
+
var _data_permission, _data_permission_actions, _data_permission1, _data_permission_actions__related_resource_types__instances__at, _data_permission_actions__related_resource_types__instances_, _data_permission_actions__related_resource_types__instances, _data_permission_actions__related_resource_types_, _data_permission_actions__related_resource_types, _data_permission_actions_, _data_permission2;
|
18
20
|
perm.value = data;
|
19
21
|
isShow.value = true;
|
20
22
|
tableData.value = [
|
21
23
|
{
|
22
24
|
system_name: data === null || data === void 0 ? void 0 : (_data_permission = data.permission) === null || _data_permission === void 0 ? void 0 : _data_permission.system_name,
|
23
|
-
name: data === null || data === void 0 ? void 0 : (_data_permission1 = data.permission) === null || _data_permission1 === void 0 ? void 0 : (
|
24
|
-
instance_name: data === null || data === void 0 ? void 0 : (_data_permission2 = data.permission) === null || _data_permission2 === void 0 ? void 0 : (
|
25
|
+
name: data === null || data === void 0 ? void 0 : (_data_permission1 = data.permission) === null || _data_permission1 === void 0 ? void 0 : (_data_permission_actions = _data_permission1.actions) === null || _data_permission_actions === void 0 ? void 0 : _data_permission_actions.map((item)=>item.name).join(','),
|
26
|
+
instance_name: data === null || data === void 0 ? void 0 : (_data_permission2 = data.permission) === null || _data_permission2 === void 0 ? void 0 : (_data_permission_actions_ = _data_permission2.actions[0]) === null || _data_permission_actions_ === void 0 ? void 0 : (_data_permission_actions__related_resource_types = _data_permission_actions_.related_resource_types) === null || _data_permission_actions__related_resource_types === void 0 ? void 0 : (_data_permission_actions__related_resource_types_ = _data_permission_actions__related_resource_types[0]) === null || _data_permission_actions__related_resource_types_ === void 0 ? void 0 : (_data_permission_actions__related_resource_types__instances = _data_permission_actions__related_resource_types_.instances) === null || _data_permission_actions__related_resource_types__instances === void 0 ? void 0 : (_data_permission_actions__related_resource_types__instances_ = _data_permission_actions__related_resource_types__instances[0]) === null || _data_permission_actions__related_resource_types__instances_ === void 0 ? void 0 : (_data_permission_actions__related_resource_types__instances__at = _data_permission_actions__related_resource_types__instances_.at(-1)) === null || _data_permission_actions__related_resource_types__instances__at === void 0 ? void 0 : _data_permission_actions__related_resource_types__instances__at.name
|
25
27
|
}
|
26
28
|
];
|
29
|
+
cancelCallback = callback;
|
27
30
|
};
|
28
31
|
__expose({
|
29
32
|
handleShow
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import type { IPermissionApplyData } from '@/types/permission';
|
2
2
|
declare const _default: import("vue").DefineComponent<{}, {
|
3
|
-
handleShow: (data: IPermissionApplyData) => void;
|
3
|
+
handleShow: (data: IPermissionApplyData, callback?: Function) => void;
|
4
4
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
5
5
|
export default _default;
|
@@ -1,40 +1,40 @@
|
|
1
1
|
|
2
|
-
.send-container[data-v-
|
2
|
+
.send-container[data-v-wa7t9ohs] {
|
3
3
|
position: relative;
|
4
4
|
}
|
5
|
-
.send-container[data-v-
|
5
|
+
.send-container[data-v-wa7t9ohs]:has(textarea:focus) {
|
6
6
|
z-index: 2;
|
7
7
|
}
|
8
|
-
.send-container:hover .send-clear[data-v-
|
8
|
+
.send-container:hover .send-clear[data-v-wa7t9ohs] {
|
9
9
|
display: inline-flex !important;
|
10
10
|
}
|
11
|
-
.send-input[data-v-
|
11
|
+
.send-input[data-v-wa7t9ohs] {
|
12
12
|
width: 100%;
|
13
13
|
flex-direction: row;
|
14
14
|
height: var(--origin-height);
|
15
15
|
}
|
16
|
-
.send-input[data-v-
|
16
|
+
.send-input[data-v-wa7t9ohs]:has(textarea:focus) {
|
17
17
|
height: var(--text-height);
|
18
18
|
}
|
19
|
-
.send-input[data-v-
|
19
|
+
.send-input[data-v-wa7t9ohs] textarea {
|
20
20
|
font-size: 12px;
|
21
21
|
line-height: 16px;
|
22
22
|
padding: 7px;
|
23
23
|
resize: none !important;
|
24
24
|
}
|
25
|
-
.send-input[data-v-
|
25
|
+
.send-input[data-v-wa7t9ohs] textarea::-webkit-scrollbar {
|
26
26
|
width: 4px;
|
27
27
|
height: 4px;
|
28
28
|
}
|
29
|
-
.send-input[data-v-
|
29
|
+
.send-input[data-v-wa7t9ohs] textarea::-webkit-scrollbar-thumb {
|
30
30
|
height: 5px;
|
31
31
|
border-radius: 3px;
|
32
32
|
background-color: #dcdee5;
|
33
33
|
}
|
34
|
-
.send-input[data-v-
|
34
|
+
.send-input[data-v-wa7t9ohs] textarea::placeholder {
|
35
35
|
line-height: 16px;
|
36
36
|
}
|
37
|
-
.send-clear[data-v-
|
37
|
+
.send-clear[data-v-wa7t9ohs] {
|
38
38
|
display: none !important;
|
39
39
|
position: absolute;
|
40
40
|
right: 10px;
|
@@ -43,6 +43,6 @@
|
|
43
43
|
font-size: 14px;
|
44
44
|
cursor: pointer;
|
45
45
|
}
|
46
|
-
.send-clear[data-v-
|
46
|
+
.send-clear[data-v-wa7t9ohs]:hover {
|
47
47
|
color: #313238;
|
48
48
|
}
|
@@ -1,27 +1,27 @@
|
|
1
1
|
|
2
|
-
.plus-tag-input[data-v-
|
2
|
+
.plus-tag-input[data-v-v2eoc0ky] {
|
3
3
|
padding: 7px 12px;
|
4
4
|
width: 100%;
|
5
5
|
}
|
6
|
-
.plus-tag-input .plus-tag-done[data-v-
|
6
|
+
.plus-tag-input .plus-tag-done[data-v-v2eoc0ky] {
|
7
7
|
cursor: pointer;
|
8
8
|
font-size: 22px;
|
9
9
|
color: #2DCB56;
|
10
10
|
margin: 0 5px 0 10px;
|
11
11
|
}
|
12
|
-
.plus-tag-input .plus-tag-error[data-v-
|
12
|
+
.plus-tag-input .plus-tag-error[data-v-v2eoc0ky] {
|
13
13
|
cursor: pointer;
|
14
14
|
font-size: 16px;
|
15
15
|
color: #C4C6CC;
|
16
16
|
margin-right: 5px;
|
17
17
|
}
|
18
|
-
.plus-tag-input .plus-tag-form[data-v-
|
18
|
+
.plus-tag-input .plus-tag-form[data-v-v2eoc0ky] {
|
19
19
|
flex: 1;
|
20
20
|
}
|
21
|
-
.plus-tag-input .plus-tag-form-item[data-v-
|
21
|
+
.plus-tag-input .plus-tag-form-item[data-v-v2eoc0ky] {
|
22
22
|
margin-bottom: 0;
|
23
23
|
}
|
24
|
-
.plus-tag[data-v-
|
24
|
+
.plus-tag[data-v-v2eoc0ky] {
|
25
25
|
cursor: pointer;
|
26
26
|
width: 100%;
|
27
27
|
display: flex;
|
@@ -30,10 +30,10 @@
|
|
30
30
|
font-size: 12px;
|
31
31
|
line-height: 20px;
|
32
32
|
}
|
33
|
-
.plus-tag .bkaidev-plus-circle[data-v-
|
33
|
+
.plus-tag .bkaidev-plus-circle[data-v-v2eoc0ky] {
|
34
34
|
font-size: 14px;
|
35
35
|
margin-right: 6px;
|
36
36
|
}
|
37
|
-
.plus-tag[data-v-
|
37
|
+
.plus-tag[data-v-v2eoc0ky]:hover {
|
38
38
|
color: #3A84FF;
|
39
39
|
}
|
@@ -1,10 +1,10 @@
|
|
1
1
|
|
2
|
-
.collapse-title[data-v-
|
2
|
+
.collapse-title[data-v-lj1692u8] {
|
3
3
|
height: 28px;
|
4
4
|
background: #F0F1F5;
|
5
5
|
border-radius: 2px;
|
6
6
|
padding: 0 12px;
|
7
7
|
}
|
8
|
-
.collapse-title .is-hidden[data-v-
|
8
|
+
.collapse-title .is-hidden[data-v-lj1692u8] {
|
9
9
|
transform: rotate(-90deg);
|
10
10
|
}
|
@@ -1,15 +1,15 @@
|
|
1
1
|
|
2
|
-
.content[data-v-
|
2
|
+
.content[data-v-l9kpm6hr] {
|
3
3
|
padding: 18px 24px 0;
|
4
4
|
height: 100%;
|
5
5
|
overflow: auto;
|
6
6
|
}
|
7
|
-
.data-set-edit-slider .value-content[data-v-
|
7
|
+
.data-set-edit-slider .value-content[data-v-l9kpm6hr] {
|
8
8
|
padding: 16px;
|
9
9
|
border: 1px solid #DCDEE5;
|
10
10
|
line-height: 22px;
|
11
11
|
}
|
12
|
-
.data-set-edit-slider[data-v-
|
12
|
+
.data-set-edit-slider[data-v-l9kpm6hr] .bk-sideslider-title {
|
13
13
|
justify-content: space-between;
|
14
14
|
width: 100%;
|
15
15
|
}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-l9kpm6hr";
|
3
3
|
script.__file = "./src/components/render-dataset/components/edit-dataset-data/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
@@ -1,18 +1,18 @@
|
|
1
1
|
|
2
|
-
.content[data-v-
|
2
|
+
.content[data-v-w9wqkvkg] {
|
3
3
|
padding: 0 24px 0px 32px;
|
4
4
|
height: 100%;
|
5
5
|
}
|
6
|
-
.content .toolbar[data-v-
|
6
|
+
.content .toolbar[data-v-w9wqkvkg] {
|
7
7
|
margin: 16px 0;
|
8
8
|
display: flex;
|
9
9
|
align-items: center;
|
10
10
|
justify-content: right;
|
11
11
|
gap: 8px;
|
12
12
|
}
|
13
|
-
.content .toolbar .record-search[data-v-
|
13
|
+
.content .toolbar .record-search[data-v-w9wqkvkg] {
|
14
14
|
width: 360px;
|
15
15
|
}
|
16
|
-
.content .toolbar .record-data-picker[data-v-
|
16
|
+
.content .toolbar .record-data-picker[data-v-w9wqkvkg] {
|
17
17
|
width: 260px;
|
18
18
|
}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-w9wqkvkg";
|
3
3
|
script.__file = "./src/components/render-dataset/components/operation-record/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-t8w4uh34";
|
3
3
|
script.__file = "./src/components/render-dataset/components/operation-record/table/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.css
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
|
2
|
-
.content[data-v-
|
2
|
+
.content[data-v-tx2olt3x] {
|
3
3
|
padding: 18px 24px 0;
|
4
4
|
height: 100%;
|
5
5
|
overflow: auto;
|
6
6
|
}
|
7
|
-
.content .value-content[data-v-
|
7
|
+
.content .value-content[data-v-tx2olt3x] {
|
8
8
|
margin-top: 8px;
|
9
9
|
padding: 16px;
|
10
10
|
border: 1px solid #DCDEE5;
|
package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-tx2olt3x";
|
3
3
|
script.__file = "./src/components/render-dataset/components/operation-record/view-op-result/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
@@ -1,8 +1,8 @@
|
|
1
1
|
|
2
|
-
.dataset-data-content[data-v-
|
2
|
+
.dataset-data-content[data-v-m08rodyn] {
|
3
3
|
padding: 20px 24px;
|
4
4
|
height: 100%;
|
5
5
|
}
|
6
|
-
.dataset-data-slider[data-v-
|
6
|
+
.dataset-data-slider[data-v-m08rodyn] .bk-modal-content {
|
7
7
|
scrollbar-gutter: inherit !important;
|
8
8
|
}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './footer.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-iv7edpuv";
|
3
3
|
script.__file = "./src/components/render-dataset/components/plus-dataset-data/form/footer.vue";
|
4
4
|
import './footer.vue.css';
|
5
5
|
export default script;
|
package/dist/components/render-dataset/components/plus-dataset-data/form/index.script.vue.js.js
CHANGED
@@ -101,9 +101,11 @@ export default /*@__PURE__*/ _defineComponent({
|
|
101
101
|
}, props.datasetData);
|
102
102
|
};
|
103
103
|
watch(()=>props.isShow, ()=>{
|
104
|
-
|
105
|
-
|
106
|
-
|
104
|
+
if (props.isShow) {
|
105
|
+
handleInitData();
|
106
|
+
handleInitFormLeaveConfirm(renderDatasetData.value);
|
107
|
+
handleClearValidate();
|
108
|
+
}
|
107
109
|
});
|
108
110
|
return (_ctx, _cache)=>{
|
109
111
|
const _component_bk_sideslider = _resolveComponent("bk-sideslider");
|
@@ -1,7 +1,7 @@
|
|
1
1
|
|
2
|
-
.plus-dataset-data[data-v-
|
2
|
+
.plus-dataset-data[data-v-0qrvwy7y] {
|
3
3
|
padding: 20px 24px;
|
4
4
|
}
|
5
|
-
.plus-dataset-sideslider[data-v-
|
5
|
+
.plus-dataset-sideslider[data-v-0qrvwy7y] .bk-modal-content {
|
6
6
|
scrollbar-gutter: inherit !important;
|
7
7
|
}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-0qrvwy7y";
|
3
3
|
script.__file = "./src/components/render-dataset/components/plus-dataset-data/form/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
@@ -39,7 +39,8 @@ export default /*@__PURE__*/ _defineComponent({
|
|
39
39
|
const handlePermissionMouseClick = (callback)=>{
|
40
40
|
var _props_datasetData;
|
41
41
|
handleMouseClick(callback, props.manageDataset, [
|
42
|
-
ResourcePermissionAction.ManageDataset
|
42
|
+
ResourcePermissionAction.ManageDataset,
|
43
|
+
ResourcePermissionAction.ViewDataset
|
43
44
|
], (_props_datasetData = props.datasetData) === null || _props_datasetData === void 0 ? void 0 : _props_datasetData.datasetId);
|
44
45
|
};
|
45
46
|
const handleShowForm = ()=>{
|
@@ -12,10 +12,10 @@ export default /*@__PURE__*/ _defineComponent({
|
|
12
12
|
let icon = '';
|
13
13
|
switch(props.sourceType){
|
14
14
|
case DatasetDataSourceType.UploadFile:
|
15
|
-
icon = 'ai-ui-sdk-icon ai-ui-sdk-wenben';
|
15
|
+
icon = 'ai-ui-sdk-icon ai-ui-sdk-wenben g-text-14 g-mr-2 g-text-gray';
|
16
16
|
break;
|
17
17
|
case DatasetDataSourceType.ManualImport:
|
18
|
-
icon = 'ai-ui-sdk-icon ai-ui-sdk-markdown';
|
18
|
+
icon = 'ai-ui-sdk-icon ai-ui-sdk-markdown g-text-14 g-mr-2 g-text-gray';
|
19
19
|
break;
|
20
20
|
}
|
21
21
|
return icon;
|
@@ -7,7 +7,7 @@ const _hoisted_2 = {
|
|
7
7
|
class: "dataset-main"
|
8
8
|
};
|
9
9
|
import { ref, toRef, watch } from 'vue';
|
10
|
-
import { useRouter } from 'vue-router';
|
10
|
+
import { useRoute, useRouter } from 'vue-router';
|
11
11
|
import RenderAside from '../render-aside/index.vue.js';
|
12
12
|
import RenderExpandCollapse from '../render-expand-collapse/index.vue.js';
|
13
13
|
import { useDatasetHttp } from '../../hooks/use-dataset-http.ts.js';
|
@@ -22,6 +22,7 @@ export default /*@__PURE__*/ _defineComponent({
|
|
22
22
|
},
|
23
23
|
setup (__props) {
|
24
24
|
const props = __props;
|
25
|
+
const route = useRoute();
|
25
26
|
const router = useRouter();
|
26
27
|
const { getDatasetMineInfo } = useDatasetHttp(props.apiPrefix, toRef(props, 'spaceId'));
|
27
28
|
const tabs = ref([
|
@@ -72,6 +73,14 @@ export default /*@__PURE__*/ _defineComponent({
|
|
72
73
|
watch(()=>props.spaceId, handleGetDatasetMineInfo, {
|
73
74
|
immediate: true
|
74
75
|
});
|
76
|
+
const handleTabChange = ()=>{
|
77
|
+
if (route.name !== 'dataset-list') {
|
78
|
+
router.push({
|
79
|
+
name: 'dataset-list'
|
80
|
+
});
|
81
|
+
}
|
82
|
+
};
|
83
|
+
watch(()=>tabId.value, handleTabChange);
|
75
84
|
return (_ctx, _cache)=>{
|
76
85
|
const _component_router_view = _resolveComponent("router-view");
|
77
86
|
const _directive_bkloading = _resolveDirective("bkloading");
|
@@ -1,9 +1,12 @@
|
|
1
1
|
import { defineComponent as _defineComponent } from 'vue';
|
2
2
|
import { createVNode as _createVNode, resolveDynamicComponent as _resolveDynamicComponent, openBlock as _openBlock, createBlock as _createBlock, resolveComponent as _resolveComponent, withCtx as _withCtx, Fragment as _Fragment, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from "vue";
|
3
|
+
import { Message } from 'bkui-vue';
|
3
4
|
import { onBeforeMount, ref, toRef } from 'vue';
|
5
|
+
import { useRouter } from 'vue-router';
|
4
6
|
import RenderHeader from './components/header.vue.js';
|
5
7
|
import RenderTab from './components/tab.vue.js';
|
6
8
|
import { useDatasetHttp } from '../../hooks/use-dataset-http.ts.js';
|
9
|
+
import { HttpErrorCode } from '../../types/enum.ts.js';
|
7
10
|
export default /*@__PURE__*/ _defineComponent({
|
8
11
|
props: {
|
9
12
|
apiPrefix: {},
|
@@ -15,13 +18,41 @@ export default /*@__PURE__*/ _defineComponent({
|
|
15
18
|
},
|
16
19
|
setup (__props) {
|
17
20
|
const props = __props;
|
21
|
+
const router = useRouter();
|
18
22
|
const loading = ref(false);
|
19
23
|
const dataset = ref();
|
20
24
|
const { getDataset } = useDatasetHttp(props.apiPrefix, toRef(props, 'spaceId'));
|
25
|
+
const handleGoToNotFound = ()=>{
|
26
|
+
router.push({
|
27
|
+
name: 'dataset-detail-not-found'
|
28
|
+
});
|
29
|
+
};
|
30
|
+
const handleNoPermission = (data)=>{
|
31
|
+
const cancelCallback = ()=>{
|
32
|
+
router.push({
|
33
|
+
name: 'dataset-list'
|
34
|
+
});
|
35
|
+
};
|
36
|
+
import('../render-auth/auth-dialog-fn.ts.js').then(({ renderAuthDialog })=>{
|
37
|
+
renderAuthDialog(data, cancelCallback);
|
38
|
+
});
|
39
|
+
};
|
21
40
|
const handleInit = ()=>{
|
22
41
|
loading.value = true;
|
23
42
|
getDataset(props.datasetId).then((data)=>{
|
24
43
|
dataset.value = data;
|
44
|
+
}).catch((error)=>{
|
45
|
+
if (error.code === HttpErrorCode.NotFound) {
|
46
|
+
handleGoToNotFound();
|
47
|
+
} else if (error.code === HttpErrorCode.IamNoPermission) {
|
48
|
+
handleNoPermission(error.response);
|
49
|
+
} else {
|
50
|
+
Message({
|
51
|
+
theme: 'error',
|
52
|
+
message: error.message,
|
53
|
+
width: 'auto'
|
54
|
+
});
|
55
|
+
}
|
25
56
|
}).finally(()=>{
|
26
57
|
loading.value = false;
|
27
58
|
});
|
@@ -35,7 +66,7 @@ export default /*@__PURE__*/ _defineComponent({
|
|
35
66
|
loading: loading.value
|
36
67
|
}, {
|
37
68
|
default: _withCtx(()=>[
|
38
|
-
|
69
|
+
dataset.value ? (_openBlock(), _createElementBlock(_Fragment, {
|
39
70
|
key: 0
|
40
71
|
}, [
|
41
72
|
_createVNode(RenderHeader, {
|
@@ -28,7 +28,8 @@ export default /*@__PURE__*/ _defineComponent({
|
|
28
28
|
const deleteRef = ref();
|
29
29
|
const handlePermissionMouseClick = ()=>{
|
30
30
|
handleMouseClick(handleShowDelete, props.manageDataset, [
|
31
|
-
ResourcePermissionAction.ManageDataset
|
31
|
+
ResourcePermissionAction.ManageDataset,
|
32
|
+
ResourcePermissionAction.ViewDataset
|
32
33
|
], props.datasetId);
|
33
34
|
};
|
34
35
|
const handleShowDelete = ()=>{
|
@@ -41,7 +42,7 @@ export default /*@__PURE__*/ _defineComponent({
|
|
41
42
|
showMore.value = false;
|
42
43
|
};
|
43
44
|
const handleDeleteDatasetDatas = ()=>{
|
44
|
-
batchDeleteDatasetData(props.selectedDatasetDatas.map((item)=>item.id)).then(()=>{
|
45
|
+
batchDeleteDatasetData(props.selectedDatasetDatas.map((item)=>item.id), props.datasetId).then(()=>{
|
45
46
|
emits('update:selectedDatasetDatas', []);
|
46
47
|
emits('success-delete');
|
47
48
|
});
|
package/dist/components/render-dataset-detail-origin-data/components/table/index.script.vue.js
CHANGED
@@ -56,14 +56,14 @@ export default /*@__PURE__*/ _defineComponent({
|
|
56
56
|
ResourcePermissionAction.ManageDataset
|
57
57
|
], props.datasetId);
|
58
58
|
};
|
59
|
-
const handleShowEditDatasetData = (row)=>{
|
59
|
+
const handleShowEditDatasetData = (row, index)=>{
|
60
60
|
isShowEditDatasetData.value = true;
|
61
61
|
tempDatasetData.value = row;
|
62
|
+
tempDatasetDataIndex.value = index;
|
62
63
|
};
|
63
|
-
const handleShowOperationRecord = (row
|
64
|
+
const handleShowOperationRecord = (row)=>{
|
64
65
|
isShowOperationRecord.value = true;
|
65
66
|
tempDatasetData.value = row;
|
66
|
-
tempDatasetDataIndex.value = index;
|
67
67
|
};
|
68
68
|
const handleHidePopover = (row)=>{
|
69
69
|
popoverRef.value[row.id].hide();
|
@@ -210,7 +210,7 @@ export default /*@__PURE__*/ _defineComponent({
|
|
210
210
|
onMouseenter: _cache[0] || (_cache[0] = ($event)=>_unref(handleMouseEnter)(_ctx.manageDataset)),
|
211
211
|
onMousemove: _cache[1] || (_cache[1] = (event)=>_unref(handleMouseMove)(event, _ctx.manageDataset)),
|
212
212
|
onMouseleave: _unref(handleMouseLeave),
|
213
|
-
onClick: ($event)=>handlePermissionMouseClick(row, ()=>handleShowEditDatasetData(row))
|
213
|
+
onClick: ($event)=>handlePermissionMouseClick(row, ()=>handleShowEditDatasetData(row, index))
|
214
214
|
}, {
|
215
215
|
default: _withCtx(()=>_cache[9] || (_cache[9] = [
|
216
216
|
_createTextVNode(" 编辑 ")
|
@@ -245,7 +245,7 @@ export default /*@__PURE__*/ _defineComponent({
|
|
245
245
|
onMouseenter: _cache[2] || (_cache[2] = ($event)=>_unref(handleMouseEnter)(_ctx.manageDataset)),
|
246
246
|
onMousemove: _cache[3] || (_cache[3] = (event)=>_unref(handleMouseMove)(event, _ctx.manageDataset)),
|
247
247
|
onMouseleave: _unref(handleMouseLeave),
|
248
|
-
onClick: ($event)=>handlePermissionMouseClick(row, ()=>handleShowOperationRecord(row
|
248
|
+
onClick: ($event)=>handlePermissionMouseClick(row, ()=>handleShowOperationRecord(row))
|
249
249
|
}, {
|
250
250
|
default: _withCtx(()=>_cache[10] || (_cache[10] = [
|
251
251
|
_createTextVNode(" 操作记录 ")
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import script from './index.script.vue.js';
|
2
|
-
script.__scopeId = "data-v-
|
2
|
+
script.__scopeId = "data-v-sm5fezpt";
|
3
3
|
script.__file = "./src/components/render-dataset-detail-origin-data/components/table/index.vue";
|
4
4
|
import './index.vue.css';
|
5
5
|
export default script;
|
@@ -1,15 +1,15 @@
|
|
1
1
|
|
2
|
-
.origin-data-content[data-v-
|
2
|
+
.origin-data-content[data-v-q0elntm9] {
|
3
3
|
padding: 24px;
|
4
4
|
height: calc(100% - 52px - 44px);
|
5
5
|
}
|
6
|
-
.origin-data-panel[data-v-
|
6
|
+
.origin-data-panel[data-v-q0elntm9] {
|
7
7
|
height: 100%;
|
8
8
|
padding: 20px;
|
9
9
|
background: #ffffff;
|
10
10
|
box-shadow: 0 2px 4px 0 #1919290d;
|
11
11
|
border-radius: 2px;
|
12
12
|
}
|
13
|
-
.origin-data-panel .toolbar-search[data-v-
|
13
|
+
.origin-data-panel .toolbar-search[data-v-q0elntm9] {
|
14
14
|
width: 6.17rem;
|
15
15
|
}
|
@@ -1,15 +1,15 @@
|
|
1
1
|
|
2
|
-
.main-content[data-v-
|
2
|
+
.main-content[data-v-4wxy3aig] {
|
3
3
|
padding: 20px 24px;
|
4
4
|
height: calc(100% - 52px);
|
5
5
|
}
|
6
|
-
.main-panel[data-v-
|
6
|
+
.main-panel[data-v-4wxy3aig] {
|
7
7
|
height: 100%;
|
8
8
|
padding: 20px 24px 0;
|
9
9
|
background: #ffffff;
|
10
10
|
box-shadow: 0 2px 4px 0 #1919290d;
|
11
11
|
border-radius: 2px;
|
12
12
|
}
|
13
|
-
.main-search[data-v-
|
13
|
+
.main-search[data-v-4wxy3aig] {
|
14
14
|
width: 6.17rem;
|
15
15
|
}
|
@@ -181,7 +181,8 @@ export default /*@__PURE__*/ _defineComponent({
|
|
181
181
|
const handleManagePermissionMouseClick = (callback, row)=>{
|
182
182
|
var _row_permission;
|
183
183
|
handleMouseClick(callback, (_row_permission = row.permission) === null || _row_permission === void 0 ? void 0 : _row_permission.manageDataset, [
|
184
|
-
ResourcePermissionAction.ManageDataset
|
184
|
+
ResourcePermissionAction.ManageDataset,
|
185
|
+
ResourcePermissionAction.ViewDataset
|
185
186
|
], row.id);
|
186
187
|
};
|
187
188
|
const handleGetDatasetList = (params)=>{
|
@@ -1,5 +1,5 @@
|
|
1
1
|
|
2
|
-
.expend-collapse-home[data-v-
|
2
|
+
.expend-collapse-home[data-v-zl98wbev] {
|
3
3
|
width: 16px;
|
4
4
|
height: 64px;
|
5
5
|
background: #DCDEE5;
|
@@ -15,9 +15,9 @@
|
|
15
15
|
cursor: pointer;
|
16
16
|
z-index: 1550;
|
17
17
|
}
|
18
|
-
.expend-collapse-home[data-v-
|
18
|
+
.expend-collapse-home[data-v-zl98wbev]:hover {
|
19
19
|
background: #979BA5;
|
20
20
|
}
|
21
|
-
.expend-collapse-home.is-close[data-v-
|
21
|
+
.expend-collapse-home.is-close[data-v-zl98wbev] {
|
22
22
|
left: 0;
|
23
23
|
}
|
@@ -1,21 +1,21 @@
|
|
1
1
|
|
2
|
-
.upload-file-home[data-v-
|
2
|
+
.upload-file-home[data-v-323kznzp] {
|
3
3
|
position: relative;
|
4
4
|
background: #FFFFFF;
|
5
5
|
border: 1px solid #DCDEE5;
|
6
6
|
border-radius: 4px;
|
7
7
|
padding: 12px 12px 10px 12px;
|
8
8
|
}
|
9
|
-
.upload-file-home[data-v-
|
9
|
+
.upload-file-home[data-v-323kznzp]:hover {
|
10
10
|
border: 1px solid #3A84FF;
|
11
11
|
}
|
12
|
-
.upload-file-home:hover .file-icons[data-v-
|
12
|
+
.upload-file-home:hover .file-icons[data-v-323kznzp] {
|
13
13
|
display: flex;
|
14
14
|
}
|
15
|
-
.upload-file-home .file-icon[data-v-
|
15
|
+
.upload-file-home .file-icon[data-v-323kznzp] {
|
16
16
|
font-size: 32px;
|
17
17
|
}
|
18
|
-
.upload-file-home .file-content[data-v-
|
18
|
+
.upload-file-home .file-content[data-v-323kznzp] {
|
19
19
|
font-size: 12px;
|
20
20
|
flex: 1;
|
21
21
|
align-items: flex-start;
|
@@ -23,28 +23,28 @@
|
|
23
23
|
font-weight: normal;
|
24
24
|
width: 0;
|
25
25
|
}
|
26
|
-
.upload-file-home .file-content .file-name[data-v-
|
26
|
+
.upload-file-home .file-content .file-name[data-v-323kznzp] {
|
27
27
|
width: 100%;
|
28
28
|
font-size: 14px;
|
29
29
|
line-height: 20px;
|
30
30
|
}
|
31
|
-
.upload-file-home .file-content .file-size[data-v-
|
31
|
+
.upload-file-home .file-content .file-size[data-v-323kznzp] {
|
32
32
|
font-size: 12px;
|
33
33
|
color: #979BA5;
|
34
34
|
line-height: 20px;
|
35
35
|
}
|
36
|
-
.upload-file-home .file-icons[data-v-
|
36
|
+
.upload-file-home .file-icons[data-v-323kznzp] {
|
37
37
|
display: none;
|
38
38
|
color: #979BA5;
|
39
39
|
}
|
40
|
-
.upload-file-home .file-icons .bkaidev-icon[data-v-
|
40
|
+
.upload-file-home .file-icons .bkaidev-icon[data-v-323kznzp] {
|
41
41
|
cursor: pointer;
|
42
42
|
margin-right: 15px;
|
43
43
|
font-size: 16px;
|
44
44
|
}
|
45
|
-
.upload-file-home .file-icons .bkaidev-icon[data-v-
|
45
|
+
.upload-file-home .file-icons .bkaidev-icon[data-v-323kznzp]:hover {
|
46
46
|
color: #3A84FF;
|
47
47
|
}
|
48
|
-
.upload-file-home .file-icons .bkaidev-delete[data-v-
|
48
|
+
.upload-file-home .file-icons .bkaidev-delete[data-v-323kznzp] {
|
49
49
|
margin: 0;
|
50
50
|
}
|
@@ -1,16 +1,16 @@
|
|
1
1
|
|
2
|
-
.ai-ui-sdk-icon.ai-ui-sdk-pdf[data-v-
|
2
|
+
.ai-ui-sdk-icon.ai-ui-sdk-pdf[data-v-11gp6ld6] {
|
3
3
|
color: #EA3636;
|
4
4
|
}
|
5
|
-
.ai-ui-sdk-icon.ai-ui-sdk-doc-2[data-v-
|
5
|
+
.ai-ui-sdk-icon.ai-ui-sdk-doc-2[data-v-11gp6ld6], .ai-ui-sdk-icon.ai-ui-sdk-ppt-2[data-v-11gp6ld6], .ai-ui-sdk-icon.ai-ui-sdk-markdown[data-v-11gp6ld6] {
|
6
6
|
color: #3A84FF;
|
7
7
|
}
|
8
|
-
.ai-ui-sdk-icon.ai-ui-sdk-folder-fill[data-v-
|
8
|
+
.ai-ui-sdk-icon.ai-ui-sdk-folder-fill[data-v-11gp6ld6] {
|
9
9
|
color: #C4C6CC;
|
10
10
|
}
|
11
|
-
.ai-ui-sdk-icon.ai-ui-sdk-excel[data-v-
|
11
|
+
.ai-ui-sdk-icon.ai-ui-sdk-excel[data-v-11gp6ld6] {
|
12
12
|
color: #2DCB56;
|
13
13
|
}
|
14
|
-
.ai-ui-sdk-icon.ai-ui-sdk-wangye[data-v-
|
14
|
+
.ai-ui-sdk-icon.ai-ui-sdk-wangye[data-v-11gp6ld6] {
|
15
15
|
color: #14A568;
|
16
16
|
}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
|
2
|
-
.header-home[data-v-
|
2
|
+
.header-home[data-v-qn5f20ae] {
|
3
3
|
width: 100%;
|
4
4
|
height: 52px;
|
5
5
|
background: #FFFFFF;
|
@@ -7,14 +7,14 @@
|
|
7
7
|
position: relative;
|
8
8
|
z-index: 2;
|
9
9
|
}
|
10
|
-
.header-title[data-v-
|
10
|
+
.header-title[data-v-qn5f20ae] {
|
11
11
|
position: absolute;
|
12
12
|
left: 24px;
|
13
13
|
top: 14px;
|
14
14
|
font-size: 16px;
|
15
15
|
color: #313238;
|
16
16
|
}
|
17
|
-
.header-main[data-v-
|
17
|
+
.header-main[data-v-qn5f20ae] {
|
18
18
|
display: flex;
|
19
19
|
align-items: center;
|
20
20
|
justify-content: flex-end;
|
@@ -22,13 +22,13 @@
|
|
22
22
|
height: 100%;
|
23
23
|
margin: 0 auto;
|
24
24
|
}
|
25
|
-
.header-select[data-v-
|
25
|
+
.header-select[data-v-qn5f20ae] {
|
26
26
|
width: 300px;
|
27
27
|
margin-right: 8px;
|
28
28
|
z-index: 9;
|
29
29
|
font-size: 12px;
|
30
30
|
}
|
31
|
-
.header-input[data-v-
|
31
|
+
.header-input[data-v-qn5f20ae] {
|
32
32
|
width: 300px;
|
33
33
|
font-size: 12px;
|
34
34
|
}
|
@@ -1,12 +1,12 @@
|
|
1
1
|
|
2
|
-
.router-tab[data-v-
|
2
|
+
.router-tab[data-v-6uf5k7kh] {
|
3
3
|
margin-top: 2px;
|
4
4
|
height: 42px;
|
5
5
|
background: #FFFFFF;
|
6
6
|
box-shadow: 0 2px 4px 0 #1919290d;
|
7
7
|
padding: 0 45px;
|
8
8
|
}
|
9
|
-
.router-tab a[data-v-
|
9
|
+
.router-tab a[data-v-6uf5k7kh] {
|
10
10
|
padding: 0 8px;
|
11
11
|
margin-right: 24px;
|
12
12
|
font-size: 14px;
|
@@ -15,7 +15,7 @@
|
|
15
15
|
color: #4D4F56;
|
16
16
|
box-sizing: border-box;
|
17
17
|
}
|
18
|
-
.router-tab a.router-link-exact-active[data-v-
|
18
|
+
.router-tab a.router-link-exact-active[data-v-6uf5k7kh] {
|
19
19
|
color: #3A84FF;
|
20
20
|
border-bottom: 2px solid #3A84FF;
|
21
21
|
}
|
package/dist/event/index.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
1
|
import { EventType } from '../types/enum';
|
2
|
-
export declare const addEventListener: (event: EventType, callback: (
|
3
|
-
export declare const removeEventListener: (event: EventType, callback: (
|
4
|
-
export declare const emitEvent: (event: EventType,
|
2
|
+
export declare const addEventListener: (event: EventType, callback: (data: unknown) => void) => void;
|
3
|
+
export declare const removeEventListener: (event: EventType, callback: (data: unknown) => void) => void;
|
4
|
+
export declare const emitEvent: <T>(event: EventType, data: T) => void;
|
package/dist/event/index.ts.js
CHANGED
@@ -10,8 +10,8 @@ export const addEventListener = (event, callback)=>{
|
|
10
10
|
export const removeEventListener = (event, callback)=>{
|
11
11
|
events[event] = events[event].filter((e)=>e !== callback);
|
12
12
|
};
|
13
|
-
export const emitEvent = (event,
|
13
|
+
export const emitEvent = (event, data)=>{
|
14
14
|
events[event].forEach((e)=>{
|
15
|
-
e(
|
15
|
+
e(data);
|
16
16
|
});
|
17
17
|
};
|
@@ -219,7 +219,7 @@ export const useChat = ({ handleStart, handleText, handleReferenceDoc, handleThi
|
|
219
219
|
// 合并新旧配置
|
220
220
|
currentRequestOptions.value = _object_spread({}, currentRequestOptions.value, newOptions);
|
221
221
|
// 如果 URL 变更,重新获取 API
|
222
|
-
if (newOptions.url) {
|
222
|
+
if (newOptions.url || newOptions.headers) {
|
223
223
|
apiImpl = useSessionHttp(currentRequestOptions.value.url, currentRequestOptions.value.headers);
|
224
224
|
}
|
225
225
|
}
|
@@ -23,7 +23,7 @@ export declare const useDatasetHttp: (apiPrefix?: string, spaceId?: Ref<string>)
|
|
23
23
|
updateDatasetData: (data: IDatasetDataForm, id: number) => Promise<import("@/types/dataset").IDatasetData>;
|
24
24
|
deleteDatasetData: (id: number) => Promise<IDatasetDataApi>;
|
25
25
|
getDatasetData: (id: number) => Promise<import("@/types/dataset").IDatasetData>;
|
26
|
-
batchDeleteDatasetData: (ids: number[]) => Promise<IDatasetDataApi>;
|
26
|
+
batchDeleteDatasetData: (ids: number[], datasetId: number) => Promise<IDatasetDataApi>;
|
27
27
|
uploadDatasetDataFiles: (files: File[]) => Promise<import("@/types/dataset").IDatasetDataFile[]>;
|
28
28
|
downloadDatasetDataTemplateFile: (id: number) => void;
|
29
29
|
registerUser: (data: IUserInfoForm) => Promise<unknown>;
|
@@ -75,7 +75,9 @@ export const useDatasetHttp = (apiPrefix, spaceId)=>{
|
|
75
75
|
const getDataset = (id)=>fetch.get(`${apiPrefix}/${datasetPerfix}/dataset/${id}/`, undefined, {
|
76
76
|
headers: {
|
77
77
|
'x-space-id': spaceId === null || spaceId === void 0 ? void 0 : spaceId.value
|
78
|
-
}
|
78
|
+
},
|
79
|
+
noCheckPermission: true,
|
80
|
+
globalError: false
|
79
81
|
}).then(transferDatasetApi2Dataset);
|
80
82
|
// 创建数据集
|
81
83
|
const createDataset = (data)=>fetch.post(`${apiPrefix}/${datasetPerfix}/dataset/`, transferDatasetForm2DatasetFormApi(data), {
|
@@ -129,8 +131,9 @@ export const useDatasetHttp = (apiPrefix, spaceId)=>{
|
|
129
131
|
}
|
130
132
|
}).then(transferDatasetDataApi2DatasetData);
|
131
133
|
// 批量删除数据集数据
|
132
|
-
const batchDeleteDatasetData = (ids)=>fetch.post(`${apiPrefix}/${datasetPerfix}/dataset_item/batch_delete/`, {
|
133
|
-
ids
|
134
|
+
const batchDeleteDatasetData = (ids, datasetId)=>fetch.post(`${apiPrefix}/${datasetPerfix}/dataset_item/batch_delete/`, {
|
135
|
+
ids,
|
136
|
+
dataset_id: datasetId
|
134
137
|
}, {
|
135
138
|
headers: {
|
136
139
|
'x-space-id': spaceId === null || spaceId === void 0 ? void 0 : spaceId.value
|
@@ -8,6 +8,11 @@ export default ((data, config)=>{
|
|
8
8
|
const code = (data === null || data === void 0 ? void 0 : (_data_error1 = data.error) === null || _data_error1 === void 0 ? void 0 : _data_error1.code) || (data === null || data === void 0 ? void 0 : data.code) || (data === null || data === void 0 ? void 0 : (_data_response1 = data.response) === null || _data_response1 === void 0 ? void 0 : _data_response1.code) || -1;
|
9
9
|
const item = (data === null || data === void 0 ? void 0 : (_data_error2 = data.error) === null || _data_error2 === void 0 ? void 0 : _data_error2.data) || (data === null || data === void 0 ? void 0 : data.data) || (data === null || data === void 0 ? void 0 : (_data_response2 = data.response) === null || _data_response2 === void 0 ? void 0 : _data_response2.data) || data;
|
10
10
|
// 异常情况下,先 emit event
|
11
|
-
emitEvent(EventType.Error,
|
11
|
+
emitEvent(EventType.Error, {
|
12
|
+
code,
|
13
|
+
message,
|
14
|
+
data: item,
|
15
|
+
config
|
16
|
+
});
|
12
17
|
return Promise.reject(new RequestError(code, message, item));
|
13
18
|
});
|
package/dist/types/enum.d.ts
CHANGED
@@ -50,7 +50,8 @@ export declare enum HttpErrorCode {
|
|
50
50
|
TagRepeat = "1513405",
|
51
51
|
Aborted = 20,
|
52
52
|
UnLogin = 401,
|
53
|
-
IamNoPermission = "IAM_NO_PERMISSION"
|
53
|
+
IamNoPermission = "IAM_NO_PERMISSION",
|
54
|
+
NotFound = "NOT_FOUND"
|
54
55
|
}
|
55
56
|
export declare enum ApiValueType {
|
56
57
|
String = "string",
|
package/dist/types/enum.ts.js
CHANGED
@@ -56,6 +56,7 @@ export var HttpErrorCode;
|
|
56
56
|
HttpErrorCode[HttpErrorCode["Aborted"] = 20] = "Aborted";
|
57
57
|
HttpErrorCode[HttpErrorCode["UnLogin"] = 401] = "UnLogin";
|
58
58
|
HttpErrorCode["IamNoPermission"] = "IAM_NO_PERMISSION";
|
59
|
+
HttpErrorCode["NotFound"] = "NOT_FOUND";
|
59
60
|
})(HttpErrorCode || (HttpErrorCode = {}));
|
60
61
|
export var ApiValueType;
|
61
62
|
(function(ApiValueType) {
|
package/package.json
CHANGED