コード例 #1
0
class EditForm(base.EditForm):

    form_fields = form.Fields(IPropertyPortlet)
    form_fields['target'].custom_widget = UberSelectionWidget

    label = _(u"Edit Property Portlet")
    description = _(u"Portlets content a Property.")
コード例 #2
0
class IPropertyPortlet(IPortletDataProvider):

    target = schema.Choice(title=_(u"Browse for contents"),
                           description=_(u"Choose contents to display."),
                           required=True,
                           source=SearchableTextSourceBinder(
                               {'portal_type': ('Folder')},
                               default_query='path:'))
コード例 #3
0
class AddForm(base.AddForm):
    
    form_fields = form.Fields(IPropertySearchPortlet)
    
    label = _(u"Add Property Search Portlet")
    description = _(u"Portlets content a Property Search.")

    def create(self, data):
        return Assignment(**data)
コード例 #4
0
class AddForm(base.AddForm):

    form_fields = form.Fields(IPropertyPortlet)
    form_fields['target'].custom_widget = UberSelectionWidget

    label = _(u"Add Property Portlet")
    description = _(u"Portlets content a Property.")

    def create(self, data):
        return Assignment(**data)
コード例 #5
0
class EditForm(base.EditForm):
    
    form_fields = form.Fields(IPropertySearchPortlet) 

    label = _(u"Edit Property Search Portlet")
    description = _(u"Portlets content a Property Search.")
コード例 #6
0
 def getContratto(self):
     return [None, _(u'Vendita'), _(u'Affitto'), _(u'Stagionale')]
コード例 #7
0
 def getCondizioni(self):
     return [None, _(u'Non definite'),_(u' Nuova costruzione'),_(u'Ristrutturato'),_(u'Da ristrutturare'),_(u'Abitabile'),_(u'Ottime'),_(u'Seminuovo'),]
コード例 #8
0
 def getCategoria(self):
     return [None,_(u'Residenziale'), _(u'Commerciale'), _(u'Rustici e terreni'),
                 _(u'Uffici, fondi')]
コード例 #9
0
class IPropertySearchPortlet(IPortletDataProvider):
    
    title = schema.TextLine(
        title=_(u"Title portlet"),
        required=False,
    ) 
コード例 #10
0
class IProperty(form.Schema, IImageScaleTraversable):
    """
    Describe a place to live or work
    """

    # Campo utilizzato nella scheda
    id_agenzia = schema.TextLine(title=_(u"Agency ID"), required=False)

    dexteritytextindexer.searchable('rif')
    rif = schema.TextLine(title=_(u"Property ref."), required=False)

    dexteritytextindexer.searchable('contratto')
    contratto = schema.Choice(title=_("Contract"),
                              values=[_(u'V'), _(u'A'),
                                      _(u'S')],
                              required=False)

    data = schema.TextLine(
        title=_(u"Data inserimento o modifica"),
        required=False,
    )

    cod_regione = schema.TextLine(
        title=_(u"Codice Regione"),
        required=False,
    )

    regione = schema.TextLine(
        title=_(u"Regione"),
        required=False,
    )

    cod_provincia = schema.TextLine(
        title=_(u"Codice provincia"),
        required=False,
    )

    provincia = schema.TextLine(
        title=_(u"Provincia"),
        required=False,
    )

    sigla_provincia = schema.TextLine(
        title=_(u"Sigla provincia"),
        required=False,
    )

    cod_comune = schema.TextLine(
        title=_(u"Codice comune"),
        required=False,
    )

    dexteritytextindexer.searchable('comune')
    comune = schema.TextLine(
        title=_(u"Comune"),
        required=False,
    )

    cod_istat = schema.TextLine(
        title=_(u"Cod. ISTAT"),
        required=False,
    )

    cod_zona_comune = schema.TextLine(
        title=_(u"Cod. Zona comune"),
        required=False,
    )

    localita = schema.TextLine(
        title=_(u"Localita'"),
        required=False,
    )

    ubicazione = schema.TextLine(
        title=_(u"Ubicazione'"),
        required=False,
    )

    indirizzo = schema.TextLine(
        title=_(u"Indirizzo"),
        required=False,
    )

    civico = schema.TextLine(
        title=_(u"Num. civico"),
        required=False,
    )

    latitudine = schema.TextLine(
        title=_(u"latitudine"),
        required=False,
    )

    longitudine = schema.TextLine(
        title=_(u"longitudine"),
        required=False,
    )

    cod_tipologia = schema.TextLine(
        title=_("Codice tipologia"),
        required=False,
    )

    tipologia = schema.TextLine(
        title=_("Tipologia"),
        required=False,
    )

    dexteritytextindexer.searchable('categoria')
    categoria = schema.Choice(title=_("Categoria"),
                              values=[
                                  _(u'Residenziale'),
                                  _(u'Commerciale'),
                                  _(u'Rustici e terreni'),
                                  _(u'Uffici, fondi')
                              ],
                              required=False)

    # testo
    testo = schema.Text(
        title=_(u"Descrizione"),
        required=False,
    )

    full_description = RichText(
        title=_(u"Descrizione estesa"),
        required=False,
    )

    dexteritytextindexer.searchable('prezzo')
    prezzo = schema.TextLine(
        title=_(u"Prezzo"),
        required=False,
    )

    dexteritytextindexer.searchable('price')
    price = schema.Float(
        title=_(u"Prezzo vero"),
        required=False,
    )

    dexteritytextindexer.searchable('mq')
    mq = schema.TextLine(
        title=_(u"Superficie"),
        required=False,
    )

    dexteritytextindexer.searchable('vani')
    vani = schema.TextLine(
        title=_(u"Vani"),
        required=False,
    )

    piano = schema.TextLine(
        title=_(u"Piano"),
        required=False,
    )

    camere = schema.TextLine(
        title=_(u"Camere"),
        required=False,
    )

    bagni = schema.TextLine(
        title=_(u"Bagni"),
        required=False,
    )

    cod_condizioni = schema.TextLine(
        title=_(u"Codice condizioni"),
        required=False,
    )

    dexteritytextindexer.searchable('condizioni')
    condizioni = schema.Choice(
        title=_("Condizioni"),
        values=[
            _(u'Non definite'),
            _(u' Nuova costruzione'),
            _(u'Ristrutturato'),
            _(u'Da ristrutturare'),
            _(u'Abitabile'),
            _(u'Ottime'),
            _(u'Seminuovo'),
        ],
        required=False,
    )

    cod_riscaldamento = schema.TextLine(
        title=_(u"Codice riscaldamento"),
        required=False,
    )

    riscaldamento = schema.Choice(title=_("Riscaldamento"),
                                  values=[
                                      _(u'Non definite'),
                                      _(u'Centralizzato'),
                                      _(u'Autonomo'),
                                      _(u'Inesistente')
                                  ],
                                  required=False)

    classe_energetica = schema.TextLine(
        title=_(u"Classe energetica"),
        required=False,
    )

    epi = schema.TextLine(
        title=_(u"EPI"),
        required=False,
    )

    epi_um = schema.TextLine(
        title=_(u"EPI un. misura"),
        required=False,
    )

    cod_cucina = schema.TextLine(
        title=_(u"Codice cucina"),
        required=False,
    )

    cucina = schema.TextLine(
        title=_(u"Cucina"),
        required=False,
    )

    garage = schema.Bool(
        title=_(u"Garage"),
        required=False,
    )

    ascensore = schema.Bool(
        title=_(u"Ascensore"),
        required=False,
    )

    arredato = schema.Bool(
        title=_(u"Arredato"),
        required=False,
    )

    condizionatore = schema.Bool(
        title=_(u"Condizionatore"),
        required=False,
    )

    giardino = schema.Bool(
        title=_(u"Giardino"),
        required=False,
    )

    giardino_tipo = schema.TextLine(
        title=_(u"Tipo giardino"),
        required=False,
    )

    giardino_mq = schema.TextLine(
        title=_(u"Mq giardino"),
        required=False,
    )

    email = schema.TextLine(
        title=_(u"E-mail"),
        required=False,
    )

    # foto Element
    titolo1 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url1 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo2 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url2 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo3 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url3 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo4 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url4 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo5 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url5 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo6 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url6 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo7 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url7 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo8 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url8 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo9 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url9 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo10 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url10 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo11 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url11 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    # foto Element
    titolo12 = schema.TextLine(
        title=_(u"Foto"),
        required=False,
    )

    url12 = schema.TextLine(
        title=_(u"Url"),
        required=False,
    )

    trattativa_riservata = schema.TextLine(
        title=_(u"Trattativa riservata"),
        required=False,
    )

    skip_sync = schema.Bool(title=_("Skip sync"), required=False)