@adminforth/bulk-ai-flow 1.17.4 → 1.17.6
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/build.log +2 -2
- package/custom/VisionAction.vue +33 -1
- package/dist/custom/VisionAction.vue +33 -1
- package/package.json +2 -2
package/build.log
CHANGED
|
@@ -13,5 +13,5 @@ custom/package-lock.json
|
|
|
13
13
|
custom/package.json
|
|
14
14
|
custom/tsconfig.json
|
|
15
15
|
|
|
16
|
-
sent
|
|
17
|
-
total size is
|
|
16
|
+
sent 90,400 bytes received 172 bytes 181,144.00 bytes/sec
|
|
17
|
+
total size is 89,755 speedup is 0.99
|
package/custom/VisionAction.vue
CHANGED
|
@@ -625,6 +625,7 @@ async function runAiAction({
|
|
|
625
625
|
recordId: checkbox,
|
|
626
626
|
...(customPrompt !== undefined ? { customPrompt: JSON.stringify(customPrompt) } : {}),
|
|
627
627
|
},
|
|
628
|
+
silentError: true,
|
|
628
629
|
});
|
|
629
630
|
|
|
630
631
|
if (res?.error) {
|
|
@@ -658,6 +659,7 @@ async function runAiAction({
|
|
|
658
659
|
path: `/plugin/${props.meta.pluginInstanceId}/get-job-status`,
|
|
659
660
|
method: 'POST',
|
|
660
661
|
body: { jobId },
|
|
662
|
+
silentError: true,
|
|
661
663
|
});
|
|
662
664
|
//check for errors
|
|
663
665
|
if (!jobResponse) {
|
|
@@ -892,8 +894,34 @@ function click() {
|
|
|
892
894
|
}
|
|
893
895
|
|
|
894
896
|
function saveSettings() {
|
|
897
|
+
const promptsToSaveGenerateImages = Object.fromEntries(
|
|
898
|
+
Object.entries(generationPrompts.value.generateImages).filter(
|
|
899
|
+
([key, value]) => value !== props.meta.generationPrompts.imageGenerationPrompts[key].prompt
|
|
900
|
+
)
|
|
901
|
+
);
|
|
902
|
+
|
|
903
|
+
const promptsToSaveAnalyzeImages = Object.fromEntries(
|
|
904
|
+
Object.entries(generationPrompts.value.imageFieldsPrompts).filter(
|
|
905
|
+
([key, value]) => value !== props.meta.generationPrompts.imageFieldsPrompts[key]
|
|
906
|
+
)
|
|
907
|
+
);
|
|
908
|
+
|
|
909
|
+
const promptsToSaveAnalyzeNoImages = Object.fromEntries(
|
|
910
|
+
Object.entries(generationPrompts.value.plainFieldsPrompts).filter(
|
|
911
|
+
([key, value]) => value !== props.meta.generationPrompts.plainFieldsPrompts[key]
|
|
912
|
+
)
|
|
913
|
+
);
|
|
914
|
+
|
|
915
|
+
const promptsToSave = {
|
|
916
|
+
...(Object.keys(promptsToSaveAnalyzeNoImages).length > 0 ? { plainFieldsPrompts: promptsToSaveAnalyzeNoImages } : {}),
|
|
917
|
+
...(Object.keys(promptsToSaveAnalyzeImages).length > 0 ? { imageFieldsPrompts: promptsToSaveAnalyzeImages } : {}),
|
|
918
|
+
...(Object.keys(promptsToSaveGenerateImages).length > 0 ? { generateImages: promptsToSaveGenerateImages } : {}),
|
|
919
|
+
};
|
|
920
|
+
|
|
921
|
+
console.log('Saving prompts:', promptsToSave);
|
|
922
|
+
|
|
923
|
+
localStorage.setItem(`bulkAiFlowGenerationPrompts_${props.meta.pluginInstanceId}`, JSON.stringify(promptsToSave));
|
|
895
924
|
popupMode.value = 'confirmation';
|
|
896
|
-
localStorage.setItem(`bulkAiFlowGenerationPrompts_${props.meta.pluginInstanceId}`, JSON.stringify(generationPrompts.value));
|
|
897
925
|
}
|
|
898
926
|
|
|
899
927
|
async function getGenerationPrompts() {
|
|
@@ -923,10 +951,13 @@ async function getGenerationPrompts() {
|
|
|
923
951
|
}
|
|
924
952
|
|
|
925
953
|
function resetPromptToDefault(categoryKey, promptKey) {
|
|
954
|
+
console.log('Resetting prompt:', categoryKey, promptKey);
|
|
955
|
+
console.log('Default prompt:', props.meta.generationPrompts);
|
|
926
956
|
if (categoryKey === 'generateImages') {
|
|
927
957
|
generationPrompts.value[categoryKey][promptKey] = props.meta.generationPrompts.imageGenerationPrompts[promptKey].prompt;
|
|
928
958
|
return;
|
|
929
959
|
}
|
|
960
|
+
console.log('Resetting prompt to the:', props.meta.generationPrompts[categoryKey][promptKey]);
|
|
930
961
|
generationPrompts.value[categoryKey][promptKey] = props.meta.generationPrompts[categoryKey][promptKey];
|
|
931
962
|
}
|
|
932
963
|
|
|
@@ -1004,6 +1035,7 @@ async function regenerateCell(recordInfo: any) {
|
|
|
1004
1035
|
actionType: actionType,
|
|
1005
1036
|
prompt: generationPromptsForField[recordInfo.fieldName] || null,
|
|
1006
1037
|
},
|
|
1038
|
+
silentError: true,
|
|
1007
1039
|
});
|
|
1008
1040
|
} catch (e) {
|
|
1009
1041
|
regeneratingFieldsStatus.value[recordInfo.recordId][recordInfo.fieldName] = false;
|
|
@@ -625,6 +625,7 @@ async function runAiAction({
|
|
|
625
625
|
recordId: checkbox,
|
|
626
626
|
...(customPrompt !== undefined ? { customPrompt: JSON.stringify(customPrompt) } : {}),
|
|
627
627
|
},
|
|
628
|
+
silentError: true,
|
|
628
629
|
});
|
|
629
630
|
|
|
630
631
|
if (res?.error) {
|
|
@@ -658,6 +659,7 @@ async function runAiAction({
|
|
|
658
659
|
path: `/plugin/${props.meta.pluginInstanceId}/get-job-status`,
|
|
659
660
|
method: 'POST',
|
|
660
661
|
body: { jobId },
|
|
662
|
+
silentError: true,
|
|
661
663
|
});
|
|
662
664
|
//check for errors
|
|
663
665
|
if (!jobResponse) {
|
|
@@ -892,8 +894,34 @@ function click() {
|
|
|
892
894
|
}
|
|
893
895
|
|
|
894
896
|
function saveSettings() {
|
|
897
|
+
const promptsToSaveGenerateImages = Object.fromEntries(
|
|
898
|
+
Object.entries(generationPrompts.value.generateImages).filter(
|
|
899
|
+
([key, value]) => value !== props.meta.generationPrompts.imageGenerationPrompts[key].prompt
|
|
900
|
+
)
|
|
901
|
+
);
|
|
902
|
+
|
|
903
|
+
const promptsToSaveAnalyzeImages = Object.fromEntries(
|
|
904
|
+
Object.entries(generationPrompts.value.imageFieldsPrompts).filter(
|
|
905
|
+
([key, value]) => value !== props.meta.generationPrompts.imageFieldsPrompts[key]
|
|
906
|
+
)
|
|
907
|
+
);
|
|
908
|
+
|
|
909
|
+
const promptsToSaveAnalyzeNoImages = Object.fromEntries(
|
|
910
|
+
Object.entries(generationPrompts.value.plainFieldsPrompts).filter(
|
|
911
|
+
([key, value]) => value !== props.meta.generationPrompts.plainFieldsPrompts[key]
|
|
912
|
+
)
|
|
913
|
+
);
|
|
914
|
+
|
|
915
|
+
const promptsToSave = {
|
|
916
|
+
...(Object.keys(promptsToSaveAnalyzeNoImages).length > 0 ? { plainFieldsPrompts: promptsToSaveAnalyzeNoImages } : {}),
|
|
917
|
+
...(Object.keys(promptsToSaveAnalyzeImages).length > 0 ? { imageFieldsPrompts: promptsToSaveAnalyzeImages } : {}),
|
|
918
|
+
...(Object.keys(promptsToSaveGenerateImages).length > 0 ? { generateImages: promptsToSaveGenerateImages } : {}),
|
|
919
|
+
};
|
|
920
|
+
|
|
921
|
+
console.log('Saving prompts:', promptsToSave);
|
|
922
|
+
|
|
923
|
+
localStorage.setItem(`bulkAiFlowGenerationPrompts_${props.meta.pluginInstanceId}`, JSON.stringify(promptsToSave));
|
|
895
924
|
popupMode.value = 'confirmation';
|
|
896
|
-
localStorage.setItem(`bulkAiFlowGenerationPrompts_${props.meta.pluginInstanceId}`, JSON.stringify(generationPrompts.value));
|
|
897
925
|
}
|
|
898
926
|
|
|
899
927
|
async function getGenerationPrompts() {
|
|
@@ -923,10 +951,13 @@ async function getGenerationPrompts() {
|
|
|
923
951
|
}
|
|
924
952
|
|
|
925
953
|
function resetPromptToDefault(categoryKey, promptKey) {
|
|
954
|
+
console.log('Resetting prompt:', categoryKey, promptKey);
|
|
955
|
+
console.log('Default prompt:', props.meta.generationPrompts);
|
|
926
956
|
if (categoryKey === 'generateImages') {
|
|
927
957
|
generationPrompts.value[categoryKey][promptKey] = props.meta.generationPrompts.imageGenerationPrompts[promptKey].prompt;
|
|
928
958
|
return;
|
|
929
959
|
}
|
|
960
|
+
console.log('Resetting prompt to the:', props.meta.generationPrompts[categoryKey][promptKey]);
|
|
930
961
|
generationPrompts.value[categoryKey][promptKey] = props.meta.generationPrompts[categoryKey][promptKey];
|
|
931
962
|
}
|
|
932
963
|
|
|
@@ -1004,6 +1035,7 @@ async function regenerateCell(recordInfo: any) {
|
|
|
1004
1035
|
actionType: actionType,
|
|
1005
1036
|
prompt: generationPromptsForField[recordInfo.fieldName] || null,
|
|
1006
1037
|
},
|
|
1038
|
+
silentError: true,
|
|
1007
1039
|
});
|
|
1008
1040
|
} catch (e) {
|
|
1009
1041
|
regeneratingFieldsStatus.value[recordInfo.recordId][recordInfo.fieldName] = false;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adminforth/bulk-ai-flow",
|
|
3
|
-
"version": "1.17.
|
|
3
|
+
"version": "1.17.6",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"handlebars": "^4.7.8"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
|
-
"adminforth": "^2.13.0-next.
|
|
33
|
+
"adminforth": "^2.13.0-next.60"
|
|
34
34
|
},
|
|
35
35
|
"release": {
|
|
36
36
|
"plugins": [
|