Mark Inactive Customers and Suppliers in Reports (when no Filter).
[fa-stable.git] / includes / ui / simple_crud_class.inc
index f6375635ebaa6e3bcbac799342b099adbc50241b..9ab24aa5ddb4dcc3204017e16b7fb44c82ff1298 100644 (file)
@@ -251,6 +251,9 @@ class simple_crud {
                                $name = $fmt;
                                $fmt = array();
                        }
+                       if (is_string($fmt)) {
+                           $fmt = array('fmt' => $fmt);
+                       }
                        $post = isset($fmt['post']) ? $fmt['post'] : $name;
                        $fld = isset($fmt['fld']) ? $fmt['fld'] : $name;
 
@@ -270,6 +273,9 @@ class simple_crud {
                                $name = $fmt;
                                $fmt = array();
                        }
+                       if (is_string($fmt)) {
+                           $fmt = array('fmt' => $fmt);
+                       }
                        $post = isset($fmt['post']) ? $fmt['post'] : $name;
                        $fld = isset($fmt['fld']) ? $fmt['fld'] : $name;