Migrate image collections
This commit is contained in:
parent
f8cf865e04
commit
a7264fe1fc
|
@ -7,7 +7,6 @@ import VnForm from 'src/components/common/VnForm.vue';
|
||||||
import VnInput from 'src/components/common/VnInput.vue';
|
import VnInput from 'src/components/common/VnInput.vue';
|
||||||
import useNotify from 'src/composables/useNotify.js';
|
import useNotify from 'src/composables/useNotify.js';
|
||||||
|
|
||||||
const jApi = inject('jApi');
|
|
||||||
const api = inject('api');
|
const api = inject('api');
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const { notify } = useNotify();
|
const { notify } = useNotify();
|
||||||
|
@ -45,9 +44,8 @@ const isSubmitable = computed(() =>
|
||||||
|
|
||||||
const getImageCollections = async () => {
|
const getImageCollections = async () => {
|
||||||
try {
|
try {
|
||||||
imageCollections.value = await jApi.query(
|
const { data } = await api.get('imageCollections');
|
||||||
'SELECT name, `desc` FROM imageCollection ORDER BY `desc`'
|
imageCollections.value = data;
|
||||||
);
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Error getting image collections:', error);
|
console.error('Error getting image collections:', error);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue