testlink日本語化 - const.inc.php

  1. <?php
  2. /**
  3.  * TestLink Open Source Project - http://testlink.sourceforge.net/
  4.  * This script is distributed under the GNU General Public License 2 or later.
  5.  *
  6.  * Filename $RCSfile: const.inc.php,v $
  7.  *
  8.  * @version $Revision: 1.37 $
  9.  * @modified $Date: 2007/08/27 06:36:40 $ by $Author: franciscom $
  10.  * @author Martin Havl叩t
  11.  *
  12.  * SCOPE:
  13.  * Global Constants used throughout TestLink
  14.  * Script is included via config.inc.php
  15.  * There should be changed for your environment
  16.  *
  17.  *-------------------------------------------------------------------
  18.  * Revisions:
  19.  * 20070822 - franciscom - localisation ru_RU
  20.  * 20070818 - franciscom - $g_default_roleid
  21.  * 20070705 - franciscom - config of $g_req_status.
  22.  * 20070624 - franciscom - $g_title_sep*
  23.  * 20070607 - franciscom
  24.  * to solve BUGID: 887
  25.  * GET_ACTIVE_BUILD, GET_INACTIVE_BUILD
  26.  * GET_OPEN_BUILD,GET_CLOSED_BUILD
  27.  *
  28.  * 20070523 - franciscom
  29.  * MENU_ITEM_OPEN, MENU_ITEM_CLOSE
  30.  *
  31.  * 20070519 - franciscom
  32.  * $g_locales_html_select_date_field_order
  33.  *
  34.  *-------------------------------------------------------------------
  35.  * Japanese translation
  36.  *-------------------------------------------------------------------
  37.  * Testing Engineer's Forum (TEF) in Japan
  38.  * Working Group of TestLink Japanese Translation Project
  39.  *
  40.  * http://blues.se.uec.ac.jp/swtest/forum.html
  41.  * http://www38.atwiki.jp/testlink/
  42.  * http://sourceforge.jp/projects/testlinkjp/
  43.  *
  44.  * @modified $Date$ $Author$
  45.  *-------------------------------------------------------------------
  46. **/
  47.  
  48. // ----------------------------------------------------------------------------
  49. /** [GLOBAL] */
  50.  
  51. // ----------------------------------------------------------------------------
  52. /** [GUI] */
  53.  
  54. /* Release MUST BE changed at the release day */
  55. define('TL_VERSION', '1.7.0 RC 3');
  56. define('TL_BACKGROUND_DEFAULT', "#9BD"); // default color
  57.  
  58. // planAddTC_m1-tpl
  59. define('TL_STYLE_FOR_ADDED_TC', "background-color:yellow;");
  60.  
  61.  
  62. define('TL_COOKIE_KEEPTIME', (time()+60*60*24*30)); // 30 days
  63.  
  64. // Configurable templates this can help if you want to use a non standard template.
  65. // i.e. you want to develop a new one without loosing the original template.
  66. //
  67. $g_tpl = array(
  68. 'tcView' => "tcView.tpl",
  69. 'tcSearchView' => "tcSearchView.tpl",
  70. 'tcEdit' => "tcEdit.tpl",
  71. 'tcNew' => "tcNew.tpl",
  72. 'execSetResults' => "execSetResults.tpl",
  73. 'tcView' => "tcView.tpl",
  74. 'tcSearchView' => "tcView.tpl",
  75. 'usersview' => "usersview.tpl"
  76. );
  77.  
  78.  
  79.  
  80. // -------------------------------------------------------------------
  81. /** [LDAP authentication errors */
  82. //
  83. // Based on mantis issue tracking system code
  84. // ERROR_LDAP_*
  85. define( 'ERROR_LDAP_AUTH_FAILED', 1400 );
  86. define( 'ERROR_LDAP_SERVER_CONNECT_FAILED', 1401 );
  87. define( 'ERROR_LDAP_UPDATE_FAILED', 1402 );
  88. define( 'ERROR_LDAP_USER_NOT_FOUND', 1403 );
  89. define( 'ERROR_LDAP_BIND_FAILED', 1404 );
  90.  
  91.  
  92.  
  93. // ----------------------------------------------------------------------------
  94. /** [LOCALIZATION] */
  95.  
  96. // String that will used as prefix, to generate an string when a label to be localized
  97. // is passed to lang_get() to be translated, by the label is not present in the strings
  98. // file.
  99. // The resulting string will be: TL_LOCALIZE_TAG . label
  100. // Example:
  101. // want to translate "Hello" -> LOCALIZE: Hello
  102. //
  103. define('TL_LOCALIZE_TAG',"LOCALIZE: ");
  104.  
  105. // These are the supported locales.
  106. // This array will be used to create combo box at user interface.
  107. // Please mantain the alphabetical order when adding new locales.
  108. // Attention:
  109. // The locale selected by default in the combo box when
  110. // creating a new user WILL BE fixed by the value of the default locale,
  111. // NOT by the order of the elements in this array.
  112. //
  113. $g_locales = array(
  114. 'zh_CN' => 'Chinese Simplified',
  115. 'en_GB' => 'English (UK)',
  116. 'en_US' => 'English (US)',
  117. 'fr_FR' => 'Fran&ccedil;ais',
  118. 'de_DE' => 'German',
  119. 'it_IT' => 'Italian',
  120. 'pl_PL' => 'Polski',
  121. 'pt_BR' => 'Portuguese (Brazil)',
  122. 'es_AR' => 'Spanish (Argentine)',
  123. 'es_ES' => 'Spanish',
  124. 'ru_RU' => 'Russian',
  125. 'jp_JP' => 'Japanese'
  126. );
  127.  
  128. // see strftime() in PHP manual
  129. // Very IMPORTANT:
  130. // setting according local is done in testlinkInitPage() using set_dt_formats()
  131. // Default values
  132. $g_date_format ="%d/%m/%Y";
  133. $g_timestamp_format = "%d/%m/%Y %H:%M:%S";
  134.  
  135. $g_locales_date_format = array(
  136. 'en_GB' => "%d/%m/%Y",
  137. 'en_US' => "%m/%d/%Y",
  138. 'it_IT' => "%d/%m/%Y",
  139. 'es_AR' => "%d/%m/%Y",
  140. 'es_ES' => "%d/%m/%Y",
  141. 'de_DE' => "%d.%m.%Y",
  142. 'pl_PL' => "%d.%m.%Y",
  143. 'fr_FR' => "%d/%m/%Y",
  144. 'pt_BR' => "%d/%m/%Y",
  145. 'ru_RU' => "%d/%m/%Y",
  146. 'zh_CN' => "%Y鐃緒申%m鐃緒申%d鐃緒申",
  147. 'jp_JP' => "%Y/%m/%d"
  148. );
  149.  
  150. $g_locales_timestamp_format = array(
  151. 'en_GB' => "%d/%m/%Y %H:%M:%S",
  152. 'en_US' => "%m/%d/%Y %H:%M:%S",
  153. 'it_IT' => "%d/%m/%Y %H:%M:%S",
  154. 'es_AR' => "%d/%m/%Y %H:%M:%S",
  155. 'es_ES' => "%d/%m/%Y %H:%M:%S",
  156. 'de_DE' => "%d.%m.%Y %H:%M:%S",
  157. 'pl_PL' => "%d.%m.%Y %H:%M:%S",
  158. 'fr_FR' => "%d/%m/%Y %H:%M:%S",
  159. 'pt_BR' => "%d/%m/%Y %H:%M:%S",
  160. 'ru_RU' => "%d/%m/%Y %H:%M:%S",
  161. 'zh_CN' => "%Y鐃緒申%m鐃緒申%d鐃緒申 %H扮%M鐃緒申%S鐃緒申",
  162. 'jp_JP' => "%Y/%m/%d %H:%M:%S"
  163. );
  164.  
  165. // for smarty html_select_date custom function
  166. $g_locales_html_select_date_field_order = array(
  167. 'en_GB' => "dmY",
  168. 'en_US' => "mdY",
  169. 'it_IT' => "dmY",
  170. 'es_AR' => "dmY",
  171. 'es_ES' => "dmY",
  172. 'de_DE' => "dmY",
  173. 'pl_PL' => "dmY",
  174. 'fr_FR' => "dmY",
  175. 'pt_BR' => "dmY",
  176. 'ru_RU' => "dmY",
  177. 'zh_CN' => "Ymd",
  178. 'jp_JP' => "Ymd"
  179. );
  180.  
  181.  
  182.  
  183. // -------------------------------------------------------------------
  184. /** ATTACHMENTS */
  185.  
  186. /* some attachment related defines, no need to modify them */
  187. define("TL_REPOSITORY_TYPE_DB",1);
  188. define("TL_REPOSITORY_TYPE_FS",2);
  189.  
  190. define("TL_REPOSITORY_COMPRESSIONTYPE_NONE",1);
  191. define("TL_REPOSITORY_COMPRESSIONTYPE_GZIP",2);
  192.  
  193.  
  194. // Two models to manage attachment interface in the execution screen
  195. // $att_model_m1 -> shows upload button and title
  196. //
  197. $att_model_m1->show_upload_btn = true;
  198. $att_model_m1->show_title = true;
  199. $att_model_m1->num_cols = 4;
  200. $att_model_m1->show_upload_column = false;
  201.  
  202. // $att_model_m2 -> hides upload button and title
  203. //
  204. $att_model_m2->show_upload_btn = false;
  205. $att_model_m2->show_title = false;
  206. $att_model_m2->num_cols = 5;
  207. $att_model_m2->show_upload_column = true;
  208.  
  209.  
  210. // -------------------------------------------------------------------
  211. /** [MISC] */
  212.  
  213. /** [Test Case Status] */
  214.  
  215. // $g_tc_status
  216. // $g_tc_status_css
  217. // $g_tc_status_verbose_labels
  218. // $g_tc_status_for_ui
  219. //
  220. //
  221. // These are the possible Test Case statuses.
  222. //
  223. // Localisation Note:
  224. // IMPORTANT:
  225. // Do not do localisation here, i.e do not change "passed"
  226. // with the corresponding word in you national language.
  227. // These strings ARE NOT USED at User interface level.
  228. //
  229. // Labels showed to users will be created using lang_get()
  230. // function, getting key from:
  231. // $g_tc_status_verbose_labels
  232. // example:
  233. // lang_get($g_tc_status_verbose_labels["passed"]);
  234. //
  235. // If you add new statuses, please use custom_strings.txt to add your
  236. // localized strings
  237. //
  238. $g_tc_status = array (
  239. "failed" => 'f',
  240. "blocked" => 'b',
  241. "passed" => 'p',
  242. "not_run" => 'n',
  243. "not_available" => 'x',
  244. "unknown" => 'u',
  245. "all" => 'all'
  246. );
  247.  
  248. // Please if you add an status you need to add a corresponding CSS Class
  249. // in the CSS files (see the gui directory)
  250. $g_tc_status_css = array_flip($g_tc_status);
  251.  
  252.  
  253. // Used to get localized string to show to users
  254. // key: status
  255. // value: id to use with lang_get() to get the string, from strings.txt
  256. // or custom_strings.txt
  257. //
  258. $g_tc_status_verbose_labels = array(
  259. "all" => "test_status_all_status",
  260. "not_run" => "test_status_not_run",
  261. "passed" => "test_status_passed",
  262. "failed" => "test_status_failed",
  263. "blocked" => "test_status_blocked",
  264. "not_available" => "test_status_not_available",
  265. "unknown" => "test_status_unknown"
  266. );
  267.  
  268.  
  269. // Used to generate radio and buttons at user interface level.
  270. // Order is important, because this will be display order on User Interface
  271. //
  272. // key => verbose status as defined in $g_tc_status
  273. // value => string id defined in the strings.txt file,
  274. // used to localize the strings.
  275. //
  276. // $g_tc_status_for_ui = array(
  277. // "not_run" => "test_status_not_run",
  278. // "passed" => "test_status_passed",
  279. // "failed" => "test_status_failed",
  280. // "blocked" => "test_status_blocked"
  281. // );
  282.  
  283. $g_tc_status_for_ui = array(
  284. "passed" => "test_status_passed",
  285. "failed" => "test_status_failed",
  286. "blocked" => "test_status_blocked"
  287. );
  288.  
  289. // radio button selected by default
  290. $g_tc_status_for_ui_default="blocked";
  291.  
  292. // -------------------------------------------------------------------------------
  293.  
  294.  
  295. /** [Roles] */
  296. define("TL_ROLES_GUEST",5);
  297. define("TL_ROLES_NONE",3);
  298. define("TL_ROLES_NO_RIGHTS",3);
  299.  
  300. define("TL_ROLES_UNDEFINED",0);
  301. define("TL_ROLES_INHERITED",0);
  302.  
  303. // Roles with id > to this role can be deleted from user interface
  304. define("TL_LAST_SYSTEM_ROLE",9);
  305.  
  306.  
  307. // you can change the default role used for new users:
  308. // - created from the login page.
  309. // - created using user management features
  310. //
  311. // use custom_config.inc.php instead of doing changes here
  312. $g_default_roleid=TL_ROLES_GUEST;
  313.  
  314. // when a role is deleted, a new role must be assigned to all users
  315. // having role to be deleted
  316. // A right choice seems to be using $g_default_roleid.
  317. // You can change this adding a config line in custom_config.inc.php
  318. $g_role_replace_for_deleted_roles=$g_default_roleid;
  319.  
  320.  
  321. // used to mark up inactive objects (test projects, etc)
  322. define("TL_INACTIVE_MARKUP","* ");
  323.  
  324. // used on user management page to give different colour
  325. // to different roles.
  326. // If you don't want use colouring then configure in this way
  327. // $g_role_colour = array ( );
  328. //
  329. $g_role_colour = array (
  330. "admin" => 'white',
  331. "tester" => 'wheat',
  332. 'leader' => 'acqua',
  333. 'senior tester' => '#FFA',
  334. 'guest' => 'pink',
  335. 'test designer' => 'cyan',
  336. '<no rights>' => 'salmon',
  337. '<inherited>' => 'seashell'
  338. );
  339.  
  340.  
  341. $g_tc_risks = array('L1', 'L2', 'L3','M1', 'M2', 'M3','H1', 'H2', 'H3');
  342.  
  343.  
  344. // use when componing an title using several strings
  345. $g_title_sep=' : ';
  346. $g_title_sep_type2=' >> ';
  347. $g_title_sep_type3=' - ';
  348.  
  349. // used when created a test suite path, concatenating test suite names
  350. $g_testsuite_sep='/';
  351.  
  352.  
  353. // [Main page]
  354. // define('MENU_ITEM_OPEN','<div class="module-grey"><div><div><div>');
  355. // define('MENU_ITEM_CLOSE','</div></div></div></div>');
  356.  
  357. // using niftycorners
  358. define('MENU_ITEM_OPEN','<div class="menu_bubble">');
  359. define('MENU_ITEM_CLOSE','</div><p>');
  360.  
  361.  
  362.  
  363. // moved from requirements.inc.php
  364. define('TL_REQ_STATUS_VALID', 'V');
  365. define('TL_REQ_STATUS_NOT_TESTABLE', 'N');
  366.  
  367. $g_req_status=array(TL_REQ_STATUS_VALID => 'req_state_valid',
  368. TL_REQ_STATUS_NOT_TESTABLE => 'req_state_not_testable');
  369.  
  370.  
  371. //
  372. // [FUNCTION MAGIC NUMBERS] [DON'T BOTHER ABOUT]
  373. // used in several functions instead of MAGIC NUMBERS - Don't change
  374. define('ALL_PRODUCTS',0);
  375. define('TP_ALL_STATUS',null);
  376. define('FILTER_BY_PRODUCT',1);
  377. define('FILTER_BY_TESTPROJECT',FILTER_BY_PRODUCT);
  378. define('TP_STATUS_ACTIVE',1);
  379. define('NON_TESTABLE_REQ','n');
  380. define('VALID_REQ','v');
  381.  
  382. define('DSN',FALSE); // for method connect() of database.class
  383. define('ANY_BUILD',null);
  384. define('GET_NO_EXEC',1);
  385.  
  386.  
  387. define('ACTIVE',1);
  388. define('INACTIVE',0);
  389. define('OPEN',1);
  390. define('CLOSED',0);
  391.  
  392. // moved from testSetNavigator.php
  393. define('FILTER_BY_BUILD_OFF',0);
  394. define('FILTER_BY_OWNER_OFF',0);
  395. define('FILTER_BY_TC_STATUS_OFF',null);
  396.  
  397. // moved from testSetRemove.php
  398. define('WRITE_BUTTON_ONLY_IF_LINKED',1);
  399.  
  400. // moved from tc_exec_assignment.php
  401. define('FILTER_BY_TC_OFF',null);
  402. define('ALL_USERS_FILTER',null);
  403. define('ADD_BLANK_OPTION',true);
  404.  
  405.  
  406.  
  407. define('DO_LANG_GET',1);
  408. define('DONT_DO_LANG_GET',0);
  409.  
  410. //
  411. define('FILTER_BY_SHOW_ON_EXECUTION',1);
  412.  
  413. define('GET_ALSO_NOT_EXECUTED',null);
  414. define('GET_ONLY_EXECUTED','executed');
  415.  
  416. // generateTestSpecTree()
  417. define('HIDE_TESTCASES',1);
  418. define('SHOW_TESTCASES',0);
  419. define('FILTER_INACTIVE_TESTCASES',1);
  420. define('DO_NOT_FILTER_INACTIVE_TESTCASES',0);
  421.  
  422. define('DO_ON_TESTCASE_CLICK',1);
  423. define('NO_ADDITIONAL_ARGS','');
  424. define('NO_KEYWORD_ID_TO_FILTER',0);
  425.  
  426.  
  427. define('RECURSIVE_MODE',TRUE);
  428. define('NO_NODE_TYPE_TO_FILTER',null);
  429. define('ANY_OWNER',null);
  430.  
  431. define('ALL_BUILDS','a');
  432. define('ALL_TEST_SUITES','all');
  433.  
  434. define('GET_ACTIVE_BUILD',1);
  435. define('GET_INACTIVE_BUILD',0);
  436. define('GET_OPEN_BUILD',1);
  437. define('GET_CLOSED_BUILD',0);
  438.  
  439.  
  440. // bug_interface->buildViewBugLink()
  441. define('GET_BUG_SUMMARY',true);
  442.  
  443. // gen_spec_view()
  444. define('DO_PRUNE',1);
  445.  
  446. // getAllRoles()
  447. define('EXCLUDE_UNDEFINED_ROLE',0);
  448. // -------------------------------------------------------------------
  449. ?>
最終更新:2007年08月28日 20:51
ツールボックス

下から選んでください:

新しいページを作成する
ヘルプ / FAQ もご覧ください。