Fetches all collections when selecting parent or target collections. Ref. #206
This commit is contained in:
parent
644eb28528
commit
91061cdd7d
|
@ -696,10 +696,10 @@ export default {
|
|||
// Generates options for parent collection
|
||||
this.isFetchingCollections = true;
|
||||
this.fetchCollectionsForParent()
|
||||
.then((collections) => {
|
||||
this.collections = collections;
|
||||
this.isFetchingCollections = false;
|
||||
})
|
||||
.then((collections) => {
|
||||
this.collections = collections;
|
||||
this.isFetchingCollections = false;
|
||||
})
|
||||
.catch((error) => {
|
||||
this.$console.error(error);
|
||||
this.isFetchingCollections = false;
|
||||
|
|
|
@ -232,9 +232,6 @@ export default {
|
|||
'runImporter',
|
||||
'fetchMappingImporter'
|
||||
]),
|
||||
...mapActions('collection', [
|
||||
'fetchCollectionsForParent'
|
||||
]),
|
||||
...mapActions('bgprocess', [
|
||||
'fetchProcess'
|
||||
]),
|
||||
|
|
|
@ -447,7 +447,7 @@ export const fetchUsers = ({ commit }, { search, exceptions }) => {
|
|||
// Fetch Collections for choosing Parent Collection
|
||||
export const fetchCollectionsForParent = ({ commit }) => {
|
||||
return new Promise((resolve, reject) => {
|
||||
axios.tainacan.get('/collections/?fetch_only=name,id')
|
||||
axios.tainacan.get('/collections/?nopaging=1fetch_only=name,id')
|
||||
.then(res => {
|
||||
let collections = res.data;
|
||||
resolve( collections );
|
||||
|
|
Loading…
Reference in New Issue