wisest owl (wisest_owl) wrote in changelog,
wisest owl
wisest_owl
changelog

[livejournal] r18039: LJSUP-7725. I can not add a user to comm...

Committer: gprochaev
LJSUP-7725. I can not add a user to community

Fixes:
1. Add hidden fields for active maintainers
2. Add disable flag for empty form fields

U   trunk/htdocs/community/members.bml
Modified: trunk/htdocs/community/members.bml
===================================================================
--- trunk/htdocs/community/members.bml	2011-01-18 06:00:28 UTC (rev 18038)
+++ trunk/htdocs/community/members.bml	2011-01-18 07:22:09 UTC (rev 18039)
@@ -661,6 +661,7 @@
             $ret .= "<td style='text-align: center;'>";
             $ret .= LJ::html_check({ 'name' => "edit_$_->{'userid'}_$key",
                                      'selected' => $_->{$key}, $key =~ /moderate|admin/ ? %disabled : () });
+            $ret .= LJ::html_hidden({ 'name' => "edit_$_->{'userid'}_$key", value => $_->{$key} ? 'on' : '' }) if %disabled;
             $wstr .= $attrshort_r{$key} if $_->{$key};
             $ret .= "</td>";
         }
@@ -679,7 +680,7 @@
                 if ($key eq 'member' || $key eq 'post') {
                     $ret .= LJ::html_check({ name => "add_${_}_$key", selected => 1, });
                 } else {
-                    $ret .= LJ::html_check({ name => "add_${_}_$key" });
+                    $ret .= LJ::html_check({ name => "add_${_}_$key", %disabled });
                 }
                 $ret .= "</td>";
             }

Tags: bml, livejournal, wisest-owl
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments