You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@labs.apache.org by si...@apache.org on 2009/12/11 18:00:41 UTC
svn commit: r889700 -
/labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js
Author: simoneg
Date: Fri Dec 11 17:00:40 2009
New Revision: 889700
URL: http://svn.apache.org/viewvc?rev=889700&view=rev
Log:
LABS-502 : support drop downs
Modified:
labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js
Modified: labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js
URL: http://svn.apache.org/viewvc/labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js?rev=889700&r1=889699&r2=889700&view=diff
==============================================================================
--- labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js (original)
+++ labs/magma/trunk/website-beansview/src/main/resources/org/apache/magma/website/beansview/dynaForm.js Fri Dec 11 17:00:40 2009
@@ -14,6 +14,21 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
+DynaForm_hideall = function() {
+ var head = document.getElementsByTagName('head')[0],
+ style = document.createElement('style'),
+ rules = document.createTextNode('h1 { background: red; }');
+
+ style.type = 'text/css';
+ if(style.styleSheet)
+ style.styleSheet.cssText = rules.nodeValue;
+ else style.appendChild(rules);
+ head.appendChild(style);
+}
+
+DynaForm_hideall();
+
addOnload(function() {
$('.MagmaDynaBlock').each(function() {
if ($('.NotNullable', this).length == 0) {
@@ -78,7 +93,7 @@
DynaForm_unset = function(form, i) {
var block = $('.block_' + i,form);
block.slideUp('normal');
- $('input', block).val('');
+ $('input,select,textarea', block).val('');
$('.MagmaDynaBlockRemove', block).remove();
form.df_set[i] = false;
DynaForm_resetSelection(form);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org