* zin: optimize zin tool generated template
This commit is contained in:
+11
-4
@@ -833,8 +833,15 @@ function getPageTemplate(info)
|
||||
|
||||
lines.unshift(
|
||||
'<?php',
|
||||
'declare(strict_types=1);',
|
||||
'/**',
|
||||
` * The ${info.methodName} view of ${info.moduleName} of ZenTaoPMS.`,
|
||||
` * The ${info.methodName} view file of ${info.moduleName} module of ZenTaoPMS.`,
|
||||
' *',
|
||||
' * @copyright Copyright 2009-2023 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.zentao.net)',
|
||||
' * @license ZPL(https://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)',
|
||||
' * @author yourname<yourname@easycorp.ltd>',
|
||||
` * @package ${info.moduleName}`,
|
||||
' * @link http://www.zentao.net',
|
||||
' */',
|
||||
'',
|
||||
'/*',
|
||||
@@ -844,12 +851,12 @@ function getPageTemplate(info)
|
||||
'',
|
||||
` + Familiar with the use of these widgets in zin: ${widgets.join(', ')}.`,
|
||||
variables.length ? ` + Check the following variables which used in widgets: ${variables.map(x => `$${x}`).join(', ')}.` : null,
|
||||
featureBar.items && featureBar.items.length ? ` + Check the ${featureBar.items.length.length} items difinition in featureBar widget.` : null,
|
||||
toolbar && toolbar.length ? ` + Check the ${toolbar.length} items difinition in toolbar widget.` : null,
|
||||
featureBar.items && featureBar.items.length ? ` + Check the ${featureBar.items.length} items definition in featureBar widget.` : null,
|
||||
toolbar && toolbar.length ? ` + Check the ${toolbar.length} items definition in toolbar widget.` : null,
|
||||
` + Check the origin code in module/${info.moduleName}/view/${info.methodName}.html.php, and ensure that all features have been implemented.`,
|
||||
` + Check the origin js code in module/${info.moduleName}/js/common.js and module/${info.moduleName}/js/${info.methodName}.js`,
|
||||
` + Check the origin css code in module/${info.moduleName}/css/common.css and module/${info.moduleName}/css/${info.methodName}.css`,
|
||||
' + Remove the comments which starts with "zin:"',
|
||||
' + Remove the comments which start with "zin:"',
|
||||
' + Test according to the new design draft and the original implementation',
|
||||
' */',
|
||||
'',
|
||||
|
||||
Reference in New Issue
Block a user