From 726af24771df4f955d8b46a49dd495c6a3c35977 Mon Sep 17 00:00:00 2001 From: fujia Date: Fri, 23 Jul 2010 01:33:16 +0000 Subject: [PATCH] + add template to bug steps. + create zt_userTPL. --- db/update1.1.sql | 12 ++++++++ module/bug/view/createtpls.html.php | 48 +++++++++++++++++++++++++++++ module/common/view/alert.html.php | 3 ++ 3 files changed, 63 insertions(+) create mode 100644 module/bug/view/createtpls.html.php create mode 100644 module/common/view/alert.html.php diff --git a/db/update1.1.sql b/db/update1.1.sql index 5d2eede807..6f8aff0d1f 100644 --- a/db/update1.1.sql +++ b/db/update1.1.sql @@ -28,3 +28,15 @@ CREATE TABLE IF NOT EXISTS `zt_docLib` ( ALTER TABLE `zt_module` CHANGE `product` `root` MEDIUMINT( 8 ) UNSIGNED NOT NULL DEFAULT '0'; ALTER TABLE `zt_module` CHANGE `view` `type` CHAR( 30 ) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL; update zt_module set `type` = 'story' where `type` = 'product'; +-- tpl +CREATE TABLE IF NOT EXISTS `zt_userTPL` ( + `id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, + `company` mediumint(8) unsigned NOT NULL, + `account` char(30) NOT NULL, + `type` char(30) NOT NULL, + `title` varchar(150) NOT NULL, + `content` text NOT NULL, + PRIMARY KEY (`id`), + KEY `company` (`company`), + KEY `account` (`account`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; diff --git a/module/bug/view/createtpls.html.php b/module/bug/view/createtpls.html.php new file mode 100644 index 0000000000..ec310597b4 --- /dev/null +++ b/module/bug/view/createtpls.html.php @@ -0,0 +1,48 @@ + + + $template) +{ + echo ""; + echo ($key + 1) . ". $template->title"; + echo html::commonButton('x', "onclick=deleteTemplate($template->id)"); + echo ""; + echo '
'; +} +echo html::commonButton($lang->save, 'onclick=saveTemplate()'); diff --git a/module/common/view/alert.html.php b/module/common/view/alert.html.php new file mode 100644 index 0000000000..91d5436ef8 --- /dev/null +++ b/module/common/view/alert.html.php @@ -0,0 +1,3 @@ +getExtViewFile(__FILE__)){include $extView; return helper::cd();}?> + +