* [task#132858] add edit app control method.

This commit is contained in:
liyang
2024-11-21 10:44:26 +08:00
committed by 曹延义
parent 45d3388edc
commit 4c6bb2f98b
+19 -1
View File
@@ -565,7 +565,7 @@ class system extends control
* @access public
* @return void
*/
public function create($productID)
public function create(int $productID)
{
if($_POST)
{
@@ -576,6 +576,7 @@ class system extends control
->setDefault('product', $productID)
->setDefault('status', 'active')
->setDefault('createdBy', $this->app->user->account)
->setIF($integrated == '0', 'children', '')
->get();
$systemID = $this->system->create($formData);
@@ -589,4 +590,21 @@ class system extends control
$this->view->systemList = $this->system->getPairs('0');
$this->display();
}
/**
* 编辑应用。
* Edit application.
*
* @param int $id
* @access public
* @return void
*/
public function edit(int $id)
{
$system = $this->system->fetchByID($id);
$this->view->title = $this->lang->system->edit;
$this->view->system = $system;
$this->view->systemList = $this->system->getPairs('0');
$this->display();
}
}