#12 [frontend] allow hiding "quick enable" helper
Merged 7 years ago by praiskup. Opened 7 years ago by praiskup.
Unknown source hide-quick-enable  into  master

@@ -102,3 +102,6 @@

  

  REDIS_HOST = "127.0.0.1"

  REDIS_PORT = 6379

+ 

+ # Hide page parts not relevant to this Copr instance:

+ # LAYOUT_OVERVIEW_HIDE_QUICK_ENABLE = False

@@ -60,3 +60,6 @@

  

  # no need to filter cla_* groups, they are already filtered by fedora openid

  BLACKLISTED_GROUPS = ['fedorabugs', 'packager', 'provenpackager']

+ 

+ # Hide page parts not relevant to this Copr instance:

+ # LAYOUT_OVERVIEW_HIDE_QUICK_ENABLE = False

@@ -56,6 +56,8 @@

  

      SRPM_STORAGE_DIR = "/var/lib/copr/data/srpm_storage/"

  

+     LAYOUT_OVERVIEW_HIDE_QUICK_ENABLE = False

+ 

  

  class ProductionConfig(Config):

      DEBUG = False

@@ -130,6 +130,8 @@

        </div>

      {% endif %}

      </div>

+ 

+     {% if not config.LAYOUT_OVERVIEW_HIDE_QUICK_ENABLE %}

      <div class="panel panel-default">

        <div class="panel-heading">

          <h3 class="panel-title"> Quick Enable </h3>
@@ -142,6 +144,8 @@

            <small><span class="pficon pficon-info"></span> More info about enabling Copr repositories</small></a>

        </div>

      </div>

+     {% endif %}

+ 

      {% if g.user and g.user.can_edit(copr) and copr and copr.owner and not copr.auto_createrepo %}

      <div class="panel panel-default">

        <div class="panel-heading">

no initial comment

I would probably like default value to be False if possible.

Also here, I would probably like default value to be False if possible. I think it is more appropriate default for something containing 'HIDE' in its name.

rebased

7 years ago

rebased

7 years ago

Ok, one more note. Could you also put that new config key into coprs_frontend/coprs/config.py with False as default? I like to have that file as quick config params overview.

rebased

7 years ago

Pull-Request has been merged by praiskup

7 years ago

Thanks for the review!