summaryrefslogtreecommitdiff
path: root/app/client/modules/morph/morph.tasks.js
blob: ad88fc02a424d251684886add5e7d6aa0aded1a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import uuidv1 from 'uuid/v1'

import socket from '../../socket'
import types from '../../types'

import actions from '../../actions'

import module from './morph.module'

export const morph_task = (state, folder) => dispatch => {
  const task = {
    module: module.name,
    activity: 'morph',
    dataset: state.a,
    folder_id: folder.id,
    opt: {
      ...state,
      dataset_module: 'pix2pihd',
    },
  }
  return actions.queue.add_task(task)
}