[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SF.net SVN: ledger-smb:[6055] trunk/UI



Revision: 6055
          http://sourceforge.net/p/ledger-smb/code/6055
Author:   einhverfr
Date:     2013-09-19 01:39:03 +0000 (Thu, 19 Sep 2013)
Log Message:
-----------
Layout improvements for content forms

Modified Paths:
--------------
    trunk/UI/Contact/divs/address.html
    trunk/UI/Contact/divs/bank_act.html
    trunk/UI/Contact/divs/contact_info.html
    trunk/UI/Contact/divs/notes.html
    trunk/UI/lib/setup.js

Modified: trunk/UI/Contact/divs/address.html
===================================================================
--- trunk/UI/Contact/divs/address.html	2013-09-18 15:50:10 UTC (rev 6054)
+++ trunk/UI/Contact/divs/address.html	2013-09-19 01:39:03 UTC (rev 6055)
@@ -86,7 +86,7 @@
 		name="location_id" 
 		value= DISPLAY.id
 	}; 
-       ?> <div>
+       ?> <div class="tabular col-1"><div>
              <?lsmb IF credit_act.id;
                        INCLUDE select element_data = {
                           name            = "attach_to"
@@ -96,9 +96,10 @@
                           label           = text('Attach To') #'
                        };
                      ELSE ?>
+         </div>
+	<div> 
              <label><?lsmb text('Attach to') ?></label><?lsmb text('Entity');
                     END; ?>
-	<div> 
                 <?lsmb INCLUDE select element_data = {
                        name           = "location_class"
                        default_values = [DISPLAY.location_class]
@@ -107,7 +108,6 @@
                        value_attr     = "id"
                        label          = text('Type')
                 } ?>
-		</select>
 	</div>
 	<div> 
 		<?lsmb INCLUDE input element_data = {
@@ -120,7 +120,6 @@
 	</div>
 	<div> 
 		<?lsmb PROCESS input element_data = {
-                        label = ":"
 			name = "line_two"
 			class = "addl-address"
 			value = DISPLAY.line_two
@@ -130,7 +129,6 @@
 	</div>
 	<div> 
 		<?lsmb PROCESS input element_data = {
-                        label = ":"
 			name = "line_three"
 			class = "addl-address"
 			value = DISPLAY.line_three
@@ -175,7 +173,7 @@
 			name = "country_id"
 			label = text('Country') 
 		} ?>
-	</div>
+	</div></div>
 	<div>
              <?lsmb PROCESS button element_data = {
 		class = "submit" 

Modified: trunk/UI/Contact/divs/bank_act.html
===================================================================
--- trunk/UI/Contact/divs/bank_act.html	2013-09-18 15:50:10 UTC (rev 6054)
+++ trunk/UI/Contact/divs/bank_act.html	2013-09-19 01:39:03 UTC (rev 6055)
@@ -39,7 +39,7 @@
 		type="hidden" 
 		name="bank_account_id" 
 		value=request.id
-	} ?>
+	} ?><div class="tabular col-1">
 	<div>
 	<?lsmb INCLUDE input element_data = {
 		type="text" 
@@ -57,7 +57,7 @@
 		value=request.iban
 		size=20
 	} #' ?>
-	</div>
+	</div></div>
 	<div><?lsmb PROCESS button element_data = {
 		name="action" 
 		value="save_bank_account"

Modified: trunk/UI/Contact/divs/contact_info.html
===================================================================
--- trunk/UI/Contact/divs/contact_info.html	2013-09-18 15:50:10 UTC (rev 6054)
+++ trunk/UI/Contact/divs/contact_info.html	2013-09-19 01:39:03 UTC (rev 6055)
@@ -63,6 +63,7 @@
 		name="contact_id" 
 		value=request.contact_id
 	} ?>
+        <div class="tabular col-1">
         <div>
            
              <?lsmb IF credit_act.id;
@@ -76,6 +77,7 @@
                      ELSE ?>
              <label><?lsmb text('Attach to') ?></label><?lsmb text('Entity');
                     END; ?>
+        </div>
 	<div>
 		<?lsmb PROCESS select element_data = {
 			name = "class_id"
@@ -94,7 +96,7 @@
 			value = request.description
 			type = "text"
 			size = "20"
-		} #' ?>
+		}  ?>
 	</div>
 	<div>
 		<?lsmb PROCESS input element_data = {
@@ -104,7 +106,7 @@
 			type = "text"
 			size = "20"
 		} #' ?>
-	</div>
+	</div></div>
 	<div><?lsmb PROCESS button element_data = {
 		name = "action",
 		value = "save_contact",

Modified: trunk/UI/Contact/divs/notes.html
===================================================================
--- trunk/UI/Contact/divs/notes.html	2013-09-18 15:50:10 UTC (rev 6054)
+++ trunk/UI/Contact/divs/notes.html	2013-09-19 01:39:03 UTC (rev 6055)
@@ -21,6 +21,7 @@
 		name="credit_id" 
 		value=credit_act.id
 	} ?>
+<div class="tabular col-1">
 <div class="input">
    <?lsmb PROCESS input element_data = {
       label = text('Subject'),
@@ -47,8 +48,8 @@
 <div class="input"><?lsmb PROCESS textarea element_data = {
 	label = text('Notes')
 	name = 'note'
-          id = 'note_note'
-} ?></div>
+          id = 'note_entry_note'
+} ?></div></div>
 <div class="input">
 <?lsmb PROCESS button element_data = {
 	text = text('Save')

Modified: trunk/UI/lib/setup.js
===================================================================
--- trunk/UI/lib/setup.js	2013-09-18 15:50:10 UTC (rev 6054)
+++ trunk/UI/lib/setup.js	2013-09-19 01:39:03 UTC (rev 6055)
@@ -8,7 +8,7 @@
 
 function construct_form_node(query, cls, registry,
                         textbox, checkbox, datebox, radio, select, button, 
-                        input)
+                        textarea, input)
 {
     
     if (input.nodeName == 'INPUT'){ 
@@ -17,12 +17,10 @@
         } else if (input.type == 'text'){
             if (cls.contains(input, 'date')){
                 // logic to pick dates
-                // TODO.  This looks pretty complex
-                // and the documentation in Dojo appears
-                // to be in flux.  I am setting this
-                // as a standard text box for now and
-                // letting others turn this into a 
-                // DateTextBox --CT
+                //
+                // I have now changed it to a DateTextBox, but apparently we 
+                // also have a wrapped version which we should use.  Will move 
+                // that over shortly. --CT
                 var df = dateformat;
                 df.replace('mm', 'MM');
                 var val = input.value;
@@ -107,12 +105,10 @@
          );
      
      } else if (input.nodeName == 'TEXTAREA'){
-        return require(['dijit/form/Textarea'],
-                function(textarea){
-                    return new textarea(
+          return new textarea(
                       { "name": input.name,
                        "value": input.innerHTML,
-                       "label": input.title }, input)});
+                       "label": input.title }, input);
      }
      return undefined; 
 }
@@ -143,10 +139,11 @@
               'dijit/form/Select',
               'dijit/form/Button',
               'dijit/layout/ContentPane',
+              'dijit/form/Textarea',
               'dojo/ready'
              ],
       function(query, registry, cls, construct, table, textbox, checkbox, datebox, 
-               radio, select, button, contentpane)
+               radio, select, button, textarea, contentpane)
       {
              query('.tabular').forEach(
                   function(node){
@@ -190,11 +187,12 @@
                              var widget = construct_form_node(
                                                query, cls, registry, textbox, checkbox, 
                                                datebox, radio, select,
-                                               button, input
+                                               button, textarea, input
                              );
                              if (widget !== undefined){
                                 ++counter;
                                 if (input.nodeName == 'BUTTON'){
+                                    console.log(input);
                                     var mycp = new contentpane(
                                         { content: "" }
                                     );
@@ -222,7 +220,7 @@
                       var widget = construct_form_node(
                                            query, cls, registry, textbox, checkbox, 
                                            datebox, radio, select,
-                                           button, node
+                                           button, textarea, node
                       );
                       if (widget !== undefined){
                           if (widget.declaredClass !== undefined){

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.


------------------------------------------------------------------------------
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
_______________________________________________
Ledger-smb-commits mailing list
..hidden..
https://lists.sourceforge.net/lists/listinfo/ledger-smb-commits