From defac79722307d68191e9d28346a9fd8502319da Mon Sep 17 00:00:00 2001 From: Malf Furious Date: Wed, 19 Sep 2018 18:06:24 -0400 Subject: datamods: Add default stages to new pads As a convenience, I'm adding a basic set of stages to new pads. These stages are "To Do", "In Progress" ('Done' being closed issues). This implements a very simple workflow for new pads. --- app/model/datamods.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'app') diff --git a/app/model/datamods.php b/app/model/datamods.php index b658314..8eaff23 100644 --- a/app/model/datamods.php +++ b/app/model/datamods.php @@ -17,6 +17,7 @@ require_once "class/agent.class.php"; require_once "class/user.class.php"; require_once "class/group.class.php"; require_once "class/pad.class.php"; +require_once "class/stage.class.php"; /* * Action: dm-group-add - New group modal @@ -54,6 +55,11 @@ if (isAction("dm-pad-add")) } $pad = pad::initNew($form->name, $owner); + $td = stage::initNew("To Do", $pad); + $ip = stage::initNew("In Progress", $pad); + + $pad->insertStage($td); + $td->insertStage($ip); } ?> -- cgit v1.2.3