from django import forms
from django.contrib.auth.models import User
from .models import Dataset, Subject
from django.utils.translation import ugettext_lazy as _


class DatasetForm(forms.ModelForm):
	class Meta:
		model = Dataset
		fields = ['dataset_id', 'collection_site']
		labels={
			'dataset': _('Dataset'),
		'collection_site':_('Collection Site')
		}
		help_texts={
			'dataset': _('The name of the dataset this subject is a part of.'),
			'collection_site':_('The location the dataset was collected.')
		}

class SubjectForm(forms.ModelForm):
	class Meta:
		model = Subject
		fields = ['dataset', 'sub_id', 'sess_id', 'func_scan', 'struct_scan','an', 'slice_timing', 'dti_file', 'bvals_file', 'bvecs_file']
		labels={
			'dataset': _('Dataset'),
			'sub_id': _('Subject ID'),
			'sess_id': _('Session ID'),
			'func_scan':_('Functional Scan'),
			'struct_scan':_('Structural Scan'),
			'an':_('Structural scan type'),
			'slice_timing':_('Slice Timing Method'),
			'dti_file':_('DTI Image'),
			'bvals_file':_('DTI b-values File'),
			'bvecs_file':_('DTI b-vectors File'),
		}
		help_texts={
			'dataset': _('The name of the dataset this subject is a part of.'),
			'sub_id': _('A unique identifier for the subject.'),
			'sess_id': _('A session name for the subject.'),
			'func_scan':_('the fMRI of this subject.'),
			'struct_scan':_('the structural MRI of this subject.'),
			'an':_('The Type of structural scan.'),
			'slice_timing':_('The method in which slices were acquired.'),
			'dti_file':_('DTI image file for NDMG pipeline'),
			'bvals_file':_('DTI b-values file for NDMG pipeline'),
			'bvecs_file':_('DRI b-vectors file for NDMG pipeline')
		}

@@ -708,18 +708,99 @@
 cs_file'
+, 'state', 'bucket', 'bidsdir', 'jobdir', 'creds_file', 'datasetname', 'modality'
 %5D%0A
-
 %09%09labels
@@ -1157,16 +1157,264 @@
 File'),%0A
+%09%09%09'state':_('Analysis Level'),%0A%09%09%09'bucket':_('S3 Bucket Name'),%0A%09%09%09'bidsdir':_('S3 Bucket BIDS Directory'),%0A%09%09%09'jobdir':_('Job Directory'),%0A%09%09%09'creds_file':_('AWS Credentials File'),%0A%09%09%09'datasetname':_('Dataset Name'),%0A%09%09%09'modality':_('Modality')%0A
 %09%09%7D%0A%09%09he
@@ -1925,24 +1925,24 @@
 pipeline'),%0A
-
 %09%09%09'bvecs_fi
@@ -1986,13 +1986,371 @@
 peline')
+,%0A%09%09%09'state':_('Level of analysis to perform'),%0A%09%09%09'bucket':_('Name of S3 bucket where data lives'),%0A%09%09%09'bidsdir':_('Path on S3 bucket where data lives'),%0A%09%09%09'jobdir':_('Directory of jobs to kill or check status'),%0A%09%09%09'creds_file':_('File containing user credentials for AWS services'),%0A%09%09%09'datasetname':_('Dataset name'),%0A%09%09%09'modality':_('Modality of data')
 %0A%09%09%7D%0A

Update forms.py