This commit is contained in:
zhaoke
2023-09-08 13:36:12 +08:00
parent f21d9727c6
commit f6cb9fa342
4 changed files with 12 additions and 5 deletions
+7 -2
View File
@@ -38,7 +38,7 @@ class artifactrepo extends control
$this->view->recTotal = $recTotal;
$this->view->recPerPage = $recPerPage;
$this->view->artifactRepos = $artifactRepos;
$this->view->products = $this->loadModel('product')->getPairs('', 0, '', 'all');
$this->view->products = $this->loadModel('product')->getPairs('all', 0, '', 'all');
$this->view->pageLink = $this->createLink('artifactrepo', 'browse', "browseType={$browseType}&orderBy={$orderBy}&recTotal={$recTotal}&recPerPage={$recPerPage}&pageID={$pageID}");
$this->display();
@@ -105,9 +105,14 @@ class artifactrepo extends control
$artifactRepo = $this->artifactrepo->getByID($artifactRepoID);
$products = $this->loadModel('product')->getPairs('', 0, '', 'all');
$linkedProducts = $this->loadModel('product')->getByIdList(explode(',', $artifactRepo->products));
$linkedProductPairs = array_combine(array_keys($linkedProducts), helper::arrayColumn($linkedProducts, 'name'));
$products = $products + $linkedProductPairs;
$this->view->title = $this->lang->artifactrepo->edit;
$this->view->artifactRepo = $artifactRepo;
$this->view->products = $this->loadModel('product')->getPairs('', 0, '', 'all');
$this->view->products = $products;
$this->display();
}
+2 -1
View File
@@ -26,8 +26,9 @@ foreach($artifactRepos as $repo)
foreach($productList as $productID)
{
if(!isset($products[$productID])) continue;
$repo->productNames .= ' ' . zget($products, $productID, $productID);
$repo->productNames .= ', ' . zget($products, $productID, $productID);
}
$repo->productNames = trim($repo->productNames, ', ');
}
}
$artifactRepos = initTableData($artifactRepos, $config->artifactrepo->dtable->fieldList, $this->artifactrepo);
+1 -1
View File
@@ -99,7 +99,7 @@ class repo extends control
}
$successJobs = $this->loadModel('compile')->getSuccessJobs($jobIDList);
$products = $this->loadModel('product')->getPairs('', 0, '', 'all');
$products = $this->loadModel('product')->getPairs('all', 0, '', 'all');
$projects = $this->loadModel('project')->getPairs();
session_start();
+2 -1
View File
@@ -35,8 +35,9 @@ foreach($repoList as $repo)
foreach($productList as $productID)
{
if(!isset($products[$productID])) continue;
$repo->productNames .= ' ' . zget($products, $productID, $productID);
$repo->productNames .= ', ' . zget($products, $productID, $productID);
}
$repo->productNames = trim($repo->productNames, ', ');
}
$repo->projectNames = '';