def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(CategoriaForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Div( Div(Row( Div(Field('descripcion', placeholder="Ingrese un nombre"), css_class='col-md-6'), Div(FieldWithButtons( 'departamento', StrictButton("Agregar", id='addDepartamento')), css_class='col-md-6'), ), css_class='modal-body'), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(ProductoForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Field('nombre', placeholder="username"), css_class='col-md-6'), Div(Field('codigo', placeholder="username"), css_class='col-md-3'), Div(Field('fechaVencimiento', placeholder="YYYY-MM-DD"), css_class='col-md-3'), ), Row( Div(FieldWithButtons( 'categoria', StrictButton("Agregar", id='addCategoria')), css_class='col-md-4'), Div(FieldWithButtons('unidad_medida', StrictButton("Agregar", id='addUnidad')), css_class='col-md-4'), Div(Field('precioC', placeholder="username"), css_class='col-md-2'), Div(Field('precioV', placeholder="username"), css_class='col-md-2'), ), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(TrabajadorForm, self).__init__(*args, **kwargs) self.fields['photo'] = forms.ImageField( label='', required=False, initial='persons/default.png', help_text=u'<small class="help-error"></small> %s' % _(u'JPG, GIF, o PNG.'), ) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Div(Field('photo'), css_class='text-center'), css_class='col-md-4'), Div(Div(Field('nombre', placeholder='Ingrese un nombre')), Div( Field('apellidos', placeholder='Ingrese sus apellidos'), ), Div(Field('tipo_documento', ), ), Div(Field('numero', placeholder='Ingrese un número'), ), Div(Field('fecha_de_nacimiento', placeholder='YYYY-MM-DD'), ), FormActions( smtSave(), btnCancel(), ), css_class='col-md-8'), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(UnidadMedidaForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Div( Div(Row( Div(Field('nombre', placeholder="Ingrese un nombre"), css_class='col-md-8'), Div(Field('simbolo', placeholder="Ejem. Kg."), css_class='col-md-4'), ), Row( Div(Field('cant_equivalencia', placeholder="Cant. de conversión"), css_class='col-md-4'), Div(FieldWithButtons( 'unidad_medida_venta', StrictButton("Agregar", id='addUnidadV')), css_class='col-md-8'), ), css_class='modal-body'), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(HistoriaForm, self).__init__(*args, **kwargs) self.fields['num_historia'] = forms.CharField( label=capfirst(_(u'N° Historia:')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.helper = FormHelper() self.helper.layout = Layout( Div(Div(Row( Div(Field('num_historia', css_class='input-required'), css_class='col-md-6'), Div(Field('veterinario', ), css_class='col-md-6'), ), css_class='modal-body'), Div(Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer '), css_class='modal-lg modal-dialog'), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(DepartamentoForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Div( Div(Row(Div(Field('descripcion', css_class='col-md-3')), ), css_class='modal-body'), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(NotasForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Field('descripcion', placeholder='Ingrese un la nota'), css_class='col-md-12'), ), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(RazaForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Field('nombre', placeholder='Ingrese un nombre', css_class='input-required'), css_class='col-md-3'), ), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(ProveedorForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Field('razon_social', placeholder="Ingrese el nombre de la empresa"), css_class='col-md-5'), Div(Field('tipodoc'), css_class='col-md-4'), Div(Field('numdoc', placeholder="Ingrese un número"), css_class='col-md-3'), ), Row( Div(Field('representante_legal', placeholder="Ingrese el nombre completo"), css_class='col-md-5'), Div(Field('direccion', placeholder="Ingrese un dirección"), css_class='col-md-4'), Div(Field('telefono', placeholder="Ingrese un número"), css_class='col-md-3'), ), Row( Div(Field('email', placeholder="Ingrese un correo"), css_class='col-md-4'), Div(Field('enti_bancaria', placeholder="Ingrese el nombre"), css_class='col-md-4'), Div(Field('num_cuenta', placeholder="Ingrese un número"), css_class='col-md-4'), ), Div( Row(FormActions( smtSave(), btnCancel(), btnReset(), ), ), css_class='modal-footer', ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(VacunacionForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.layout = Layout( Row( Div(Field('motivo', placeholder='Ingrese el motivo de vacunación'), css_class='col-md-12'), Div(Field('vacuna',), css_class='col-md-12'), Div(Field('observacion', placeholder='Ingrese un la nota'), css_class='col-md-12'), ), Div(Row( FormActions( smtSave(), btnCancel(), btnReset(), ), ),), )
def __init__(self, *args, **kwargs): super(RegistrationEnterpriseAssociationForm, self).__init__(*args, **kwargs) self.fields['name'] = forms.CharField( label=capfirst(_(u'Enterprise')), required=True, help_text=u'<small class="help-error"></small> %s' % _( u' '), ) self.fields['association_name'] = forms.CharField( label=capfirst(_(u'Association')), required=True, help_text=u'<small class="help-error"></small> %s' % _( u' '), ) self.fields['acept'] = forms.BooleanField( label=capfirst(_(u'I accept the Terms of Service and Privacy Policy.')), required=True, # widget=forms.CheckboxInput(), help_text=u'<small class="help-error"></small> %s' % _( u' '), ) self.fields['logo'] = forms.ImageField( label=capfirst(_(u'logo')), required=False, initial='enterprises/default.png', help_text=u'<small class="help-error"></small> %s' % _( u'Available formats are JPG, GIF, and PNG.'), ) self.fields['solution'].required = True self.fields['solution'].help_text = u'<small class="help-error"></small> %s' % _( u' ') self.fields['type_e'].help_text = u'<small class="help-error"></small> %s' % _( u' ') self.fields['tax_id'].help_text = u'<small class="help-error"></small> %s' % _( u' ') self.helper = FormHelper() self.helper.form_id = 'form' self.helper.form_class = 'js-validate form-vertical' self.helper.layout = Layout( TabHolder( Tab(_('Enterprise'), Row( Div(Field('name', autofocus=True, css_class='input-required'), css_class='col-md-6'), Div(Field('tax_id', css_class='input-required', ), css_class='col-md-6'), ), Row( Div(Field('association_name', css_class='input-required',), css_class='col-md-6'), Div(Field('type_e', css_class='input-required', ), css_class='col-md-6'), ), Row( Div(Field('solution', css_class='input-required',), css_class='col-md-6'), ), ), Tab(_('Image'), Field('logo', css_class="") ), ), Row( Div(Field('acept', css_class='input-required',), css_class='col-md-12'), ), Row( FormActions( smtSave(), btnCancel(), btnReset(), ), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(AtencionForm, self).__init__(*args, **kwargs) self.helper = FormHelper() self.helper.form_class = 'js-validate form-vertical' self.helper.form_id = 'form' self.helper.layout = Layout( Row( Div(Field('motivo_atencion', css_class="input-required"), css_class='col-md-12'), ), Row( Div(Field('temperatura', css_class='input-required'), css_class='col-md-2'), Div(Field('fc', css_class="input-required"), css_class='col-md-2'), Div(Field('fr', css_class='input-required'), css_class='col-md-2'), Div(Field('kg', css_class='input-required'), css_class='col-md-2'), Div(Field('porcentaje', css_class='input-required'), css_class='col-md-2'), Div(Field('tlc', css_class='input-required'), css_class='col-md-2'), ), Row( Div(Field('anamnesis'), css_class='col-md-12'), ), Row( Div(Field('hallasgos_clinicos'), css_class='col-md-12'), ), Row( Div(Field('diagnostico'), css_class='col-md-12'), ), Row( Div(Field('dx'), css_class='col-md-12'), ), Row( Div(Field('pronostico'), css_class='col-md-12'), ), Row( Div(Field('pruebas_auxiliares'), css_class='col-md-12'), ), Row( Div(Field('tratamiento'), css_class='col-md-12'), ), Row( Div(Field('observacion'), css_class='col-md-12'), ), Row( FormActions( smtSave(), btnCancel(), btnReset(), ), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(HistoriaMascotaForm, self).__init__(*args, **kwargs) self.fields['num_historia'] = forms.CharField( label=capfirst(_(u'N° Historia')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['caracter'] = forms.ChoiceField( label=capfirst(_(u'caracter')), required=True, choices=CARACTER, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['actividad'] = forms.ChoiceField( label=capfirst(_(u'actividad')), required=True, choices=ACTIVIDAD, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['habitar'] = forms.ChoiceField( label=capfirst(_(u'habitar')), required=True, choices=HABITAT, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['alimentacion'] = forms.ChoiceField( label=capfirst(_(u'alimentacion')), required=True, choices=ALIMENTACION, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['aptitup'] = forms.ChoiceField( label=capfirst(_(u'aptitup')), required=True, choices=APTITUP, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['convive'] = forms.ChoiceField( label=capfirst(_(u'convive')), required=True, choices=CONVIVE, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['historia'] = forms.BooleanField( label=capfirst(_(u'historia')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.helper = FormHelper() self.helper.form_method = 'post' self.helper.form_class = 'js-validate form-vertical form-mascota' self.helper.layout = Layout( Field('person_id', ), Row( Div(HTML( '''<h2 class="subtitle-mascota">*Datos Personales:</h2>''' ), css_class="col-xs-12"), Div(Div(Field( 'num_historia', css_class='input-required form-control-mascota', placeholder="Ingrese el numero de Historia del paciente"), css_class="col-md-3"), css_class='col-md-12 div-mascota-forms'), ), Row( Div(HTML( '''<h2 class="subtitle-mascota">*Reseña del Paciente:</h2>''' ), css_class="col-xs-12"), Div(Div(Field('caracter', css_class='input-required'), css_class='col-md-4'), Div(Field('actividad', css_class='input-required'), css_class='col-md-4'), Div(Field('habitar', css_class='input-required'), css_class='col-md-4'), Row( Div(Div(Field('alimentacion', css_class='input-required'), css_class='col-md-4'), Div(Field('aptitup', css_class='input-required'), css_class='col-md-4'), Div(InlineRadios('convive'), css_class='col-md-4'), Div(Field('historia', css_class='input-required'), css_class='estado-historia '), css_class="col-md-12"), ), css_class="col-md-12 div-mascota-forms"), ), Row( Div(FormActions( smtSave(), btnCancel(), btnReset(), ), css_class="col-md-12 btn-controls"), ), )
def __init__(self, *args, **kwargs): self.request = kwargs.pop('request', None) self.object = kwargs.pop('object', None) super(MascotaHistoriDetailForm, self).__init__(*args, **kwargs) self.fields['num_historia'] = forms.CharField( label=capfirst(_(u'num_historia')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['created_ath'] = forms.CharField( label=capfirst(_(u'created_ath')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['usuario'] = forms.CharField( label=capfirst(_(u'usuario')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['nombre'] = forms.CharField( label=capfirst(_(u'nombre')), required=True, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['duenho'] = forms.ChoiceField( label=capfirst(_(u'duenho')), required=True, # widget=forms.RadioSelect(), help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['direccion'] = forms.CharField( label=capfirst(_(u'direccion')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['direccion'] = forms.CharField( label=capfirst(_(u'direccion')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['direccion'] = forms.CharField( label=capfirst(_(u'direccion')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['ciudad'] = forms.CharField( label=capfirst(_(u'ciudad')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['telefono'] = forms.CharField( label=capfirst(_(u'telefono')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['edad'] = forms.CharField( label=capfirst(_(u'edad')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['genero'] = forms.CharField( label=capfirst(_(u'genero')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['especie'] = forms.CharField( label=capfirst(_(u'especie')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['raza'] = forms.CharField( label=capfirst(_(u'raza')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['color'] = forms.CharField( label=capfirst(_(u'color')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['actividad'] = forms.CharField( label=capfirst(_(u'actividad')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.fields['alimentacion'] = forms.CharField( label=capfirst(_(u'alimentacion')), required=False, help_text=u'<small class="help-error"></small> %s' % _(u' '), ) self.helper = FormHelper() self.helper.layout = Layout( TabHolder( Tab( _('Informacion del Dueño'), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.duenho.label }} </label> <div class="controls ">{{ form.duenho.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.direccion.label }} </label> <div class="controls ">{{ form.direccion.value }}</div> </div> '''), css_class='col-md-6'), ), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.ciudad.label }} </label> <div class="controls ">{{ form.ciudad.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.telefono.label }} </label> <div class="controls ">{{ form.telefono.value }}</div> </div> '''), css_class='col-md-6'), ), ), Tab( _('Informacion Mascota'), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.nombre.label }} </label> <div class="controls ">{{ form.nombre.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.edad.label }} </label> <div class="controls ">{{ form.edad.value }}</div> </div> '''), css_class='col-md-6'), ), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.genero.label }} </label> <div class="controls ">{{ form.genero.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.especie.label }} </label> <div class="controls ">{{ form.especie.value }}</div> </div> '''), css_class='col-md-6'), ), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.raza.label }} </label> <div class="controls ">{{ form.raza.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.color.label }} </label> <div class="controls ">{{ form.color.value }}</div> </div> '''), css_class='col-md-6'), ), ), Tab( _('Historial'), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.num_historia.label }} </label> <div class="controls ">{{ form.num_historia.value }}</div> </div> '''), css_class='col-md-6'), Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.created_ath.label }} </label> <div class="controls ">{{ form.created_ath.value }}</div> </div> '''), css_class='col-md-6'), ), Row( Div(HTML(''' <div class="form-group"> <label class="control-label"> {{ form.usuario.label }} </label> <div class="controls ">{{ form.usuario.value }}</div> </div> '''), css_class='col-md-6'), ), ), ), Row(FormActions(btnCancel(), ), ), )