Hilaire | 2 Mar 11:20 2015
Picon

WebMenu limitation?

Hi there,

I found my self stick in the following situation:

I have a collection of association as
countries := {#en->'English' . #es ->'Spain'. #uk->'United Kingdom'}
I want to display in a WebMenu the values of these association, and
store the key in my model.

It appears I can't just do that.

I can store the key, but only the keys are displayed in the menu..
Or I can display the wished text, but at best the association is stored
in my model...

self
        addMenuAspect: #value
        collection: countries
        selectedToAspect: #code
        of: model.

Am I missing something ?

Thanks

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu
(Continue reading)

Hilaire | 1 Mar 19:02 2015
Picon

Autoconversion issues

Hi there,

I have been hit by the same issue exposed there:
http://forum.world.st/AIDA-Web-f122435.html

Other examples:

1/
In a field where you want number, say float:
if you enter a float ok
if you enter an integer, next input are coerced to integer and you can
not input float anymore (you can make a forced conversion in your model,
but it is wrong, because you may want your model to work with Float)
as it
2/
In a field you input ScaledDecimal, say 25.99s2
at next input, your field is set as 25.99s2, what is supped to
understand the user there?

IMHU, autoconversions will always bring issues.

Suggestion:
Refactor the autoconversion methods
Add a bloc attribute to WebFormElement to let the user processes the
conversion as wished

Thanks

Hilaire

(Continue reading)

Hilaire | 1 Mar 15:00 2015
Picon

WebMenu proposal for changes

Hi there,

I have factored a bit WebMenu to let the user set a text to display for
a nil value.

From the menu list you may want the user to select an entry explicitly
named "I am nil" to set the model to nil.
This also remove, for the situation, the unused empty entry in the menu.

Usage:
    form := self addMenuAspect: #symbol collection: aCollection
selectedToAspect: #item of: model.
    form textForEmpty: I am nil".

aCollection should contain a nil element.

Janko it will be nice you take a look to it because I am still unused
about AidaWeb internal.
Then I will commit it to the SmaltalkHub repo.

Thanks

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

(Continue reading)

Hilaire | 23 Feb 21:36 2015
Picon

Broken TODO tutorial with Aida6.6

Hello there,

The TODO tutorial with Aida6.6 (pharo version from website) does not
work. It brings errors.

I can try to fix it but is there any interest? I fell like Aida
community is more or less in abandon state, am I missing something?

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

Hilaire | 22 Feb 21:54 2015
Picon

ViewTabs missing active class

Hello there,

The ViewTabs miss the #active class.

It looks like the css styles for viewtabs where not updated after some
code changes:

For example one can change #selected to #active (padding is a bit too
big, btw), in the last two css declarations:

DefaultWebStyle>>cssTabs1
[...]
ul.tabs1 li.active {
  background-image:url("/img/tab1leftongif.gif");
  }
ul.tabs1 li.active a {
  background-image:url("/img/tab1rightongif.gif");
  color:#333;
  padding-bottom:4px;
  }

How can I submit the fix for the whole cssTabs styles?

Thanks

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu
(Continue reading)

Hilaire | 21 Feb 22:25 2015
Picon

WebWidget and validation

Hello there,

It turns to be done naturally
http://blog.drgeo.eu/post/2015/Form-validation-and-WebWidget

I have however a question, at the end of the article, any idea how to
solve it?

Thanks

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

Hilaire | 20 Feb 21:57 2015
Picon

Aida and WebWidget

Hello there,

I continue my learning of Aida, with reusable component.
http://blog.drgeo.eu/post/2015/WebWidget-in-question

So far so good.

I more than welcome feedbacks to improve my understanding.

Thanks

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

Hilaire | 19 Feb 21:34 2015
Picon

Ajax for the dummy

Hello,

A second simple reflexion on Aida
http://blog.drgeo.eu/post/2015/Ajax-for-the-dummies

Do not hesitate to correct or to update me on the mater.

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

Hilaire | 18 Feb 15:50 2015
Picon

Some though on Aida

Hello,

A small note after playing a bit with Aida
http://blog.drgeo.eu/post/2015/Aida-and-input-field-validation

Hilaire

--

-- 
Dr. Geo - http://drgeo.eu
iStoa - http://istoa.drgeo.eu

Hilaire | 18 Feb 12:56 2015
Picon

Aida and Ajax

Hello,

For a total Ajax neophyte, Aida is really generous when it comes to add
practical round-trip information/update between the client and the server.

The code snippet bellow just update a WebElement accordingly the state
of an another form, itself mapped to a server model.

I am still wondering how it is processes underneath but it is really great.

Thanks

Hilaire

viewMain
    | html check message |

    html := WebElement new.

    check := html addCheckboxAspect: #contents for: (value :=
ValueHolder new contents: true).
    message := self myMessage.
    html addBreak; add: message.
    check onChangePostAndUpdate: message.
    [...]

myMessage
    | html |
    html := WebElement newSpan.
    html style: ''.
(Continue reading)

Hilaire | 17 Feb 15:56 2015
Picon

Exploring validation

Hello there!

I have been playing with the AddressBook tutorial and to extend my
exploration of Aida, I am trying to add field validation for Email input.
I have been looking at the examples use in Aida and edited the code
accordingly, but I still miss something. As I don't have proper report
error, the validation code is working thought.

My modifications are as follow:

ADemoAddressBookApp>>editView

    [...]

    e addTextH1: 'Add/Edit the address'.

    self inError ifTrue: [e addText: self errorReport].

    e cell

        addText: 'First name:';

        addBreak.

    [...]

    e cell

        addText: 'Email:';

(Continue reading)


Gmane