From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 6D460E008D7; Sun, 14 Oct 2018 13:02:59 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, * medium trust * [147.11.146.13 listed in list.dnswl.org] Received: from mail1.windriver.com (mail1.windriver.com [147.11.146.13]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id C77F0E00826 for ; Sun, 14 Oct 2018 13:02:58 -0700 (PDT) Received: from ALA-HCA.corp.ad.wrs.com ([147.11.189.40]) by mail1.windriver.com (8.15.2/8.15.1) with ESMTPS id w9EK2wFv013366 (version=TLSv1 cipher=AES128-SHA bits=128 verify=FAIL) for ; Sun, 14 Oct 2018 13:02:58 -0700 (PDT) Received: from ala-dreyna-lx3.corp.ad.wrs.com (147.11.157.217) by ALA-HCA.corp.ad.wrs.com (147.11.189.40) with Microsoft SMTP Server (TLS) id 14.3.408.0; Sun, 14 Oct 2018 13:02:57 -0700 From: David Reyna To: Date: Sun, 14 Oct 2018 12:59:51 -0700 Message-ID: <1539547191-5439-1-git-send-email-david.reyna@windriver.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 X-Originating-IP: [147.11.157.217] Subject: [PATCH] toaster: bad link for distro conf file X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 14 Oct 2018 20:02:59 -0000 Content-Type: text/plain From: David Reyna The distro source path link is missing "conf/distro/", and the display is using the machine link instead of the distro link. [YOCTO #12957] Signed-off-by: David Reyna --- bitbake/lib/toaster/orm/models.py | 2 +- bitbake/lib/toaster/toastergui/tables.py | 8 +++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index 849c22e..7720290 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py @@ -1877,7 +1877,7 @@ class Distro(models.Model): description = models.CharField(max_length=255) def get_vcs_distro_file_link_url(self): - path = self.name+'.conf' + path = 'conf/distro/%s.conf' % self.name return self.layer_version.get_vcs_file_link_url(path) def __unicode__(self): diff --git a/bitbake/lib/toaster/toastergui/tables.py b/bitbake/lib/toaster/toastergui/tables.py index 03bd2ae..9ff756b 100644 --- a/bitbake/lib/toaster/toastergui/tables.py +++ b/bitbake/lib/toaster/toastergui/tables.py @@ -1615,14 +1615,12 @@ class DistrosTable(ToasterTable): hidden=True, field_name="layer_version__get_vcs_reference") - wrtemplate_file_template = '''conf/machine/{{data.name}}.conf - ''' - + distro_file_template = '''conf/distro/{{data.name}}.conf + {% if 'None' not in data.get_vcs_distro_file_link_url %}{% endif %}''' self.add_column(title="Distro file", hidden=True, static_data_name="templatefile", - static_data_template=wrtemplate_file_template) - + static_data_template=distro_file_template) self.add_column(title="Select", help_text="Sets the selected distro to the project", -- 1.9.1