Browse Source

v1.5.1 - Cleaned up version strings + now using version.txt directly

pull/1/head
Jeremie Francois (on alpha) 4 years ago
parent
commit
8f99633ac9
  1. 43
      .gitignore
  2. 16
      README.md
  3. 5
      common.php
  4. 1
      lang/de.php
  5. 1
      lang/en.php
  6. 1
      lang/ru.php
  7. 31
      setup.php
  8. 16
      themes/default/index.php
  9. 2
      version.txt

43
.gitignore

@ -1,41 +1,6 @@
obj
*.orig
*.o
*.gch
*.bak
*.stl
*.gcode
.ide
.pioenvs
.piolibdeps
*.gcode
*.b#?
*.s#?
obj
*.orig
*.o
*.gch
*.bak
*.stl
*.gcode
.ide
.pioenvs
.piolibdeps
*.gcode
*.b#?
*.s#?
obj
*.orig
*.o
*.gch
*.bak
*.stl
*.gcode
.ide
.pioenvs
.piolibdeps
*.gcode
*.b#?
*.s#?
todolist-*-*.db
.htaccess
.htusers
.idea
backup.db
todolist-*-*.db

16
README.md

@ -18,15 +18,17 @@ the respective task (and its notes will be opened). The prefixed value in the se
forces a search by id only. Looking for "123" will match titles, notes or ids of the tasks, which
is still convenient to find all the tasks that refer to 123 alike.
- the incomping index URL also can provide the search string (use "?i=taskid" or "?s=keyword"). Thus,
- the incoming index URL also can provide the search string (use "?i=taskid" or "?s=keyword"). Thus,
pointing directly to a specific task is done with ?i=123. This is convenient in order to send links
by email, e.g. When you want all related tasks and cross-references you way prefer "?s=123"
by email, e.g. When you want all related tasks and cross-references you may prefer "?s=123"
- CSS can be customized (there are already a few special prefixes: =state, @user, !highlight). I intend
to use them like "=acknoledges" or "=closed" for bug tracking, and be able to assign someone with @buddy.
- style of tags can be customized, in addition to a few special notations: =state, @user, !highlight.
I intend to use them like "=acknoledged" or "=closed" for bug tracking, to use "!discussion", and
to assign someone to a task with @buddy for example.
- the tag list at the end of a task being edited now also shows tags from other lists. There is a setting
to chage this. The grayed tags are "borrowed" from the other lists.
to change this but it helps keep things tidy. The grayed tags are "borrowed" from the other lists.
- I have added a backup system in case you are using sqlite (which I always receommend unless you really
have a reason to use mysql). Backups are kept according to the main settings.
- I added a backup system in case you are using sqlite (which I always receommend unless you really
have a reason to use mysql). Backuped files are kept according to the main settings, and restoration
must be done manually if ever something terrible happens

5
common.php

@ -6,6 +6,11 @@
Licensed under the GNU GPL v2 license. See file COPYRIGHT for details.
*/
function get_version()
{
return trim(file_get_contents('version.txt'));
}
function htmlarray($a, $exclude=null)
{
htmlarray_ref($a, $exclude);

1
lang/de.php

@ -6,7 +6,6 @@
Original name: Deutsch
Author: Pascal / Rene Wagner
Author Url: http://www.pascal90.de / https://github.com/guzzisti
AppVersion: v1.5.0
Date: 2017/10/22
*/

1
lang/en.php

@ -6,7 +6,6 @@
Original name: English
Author: Max Pozdeev & Jeremie Francois
Author Url: http://www.mytinytodo.net & www.tecrd.com
AppVersion: v1.5.0
Date: 2017/09/18
*/

1
lang/ru.php

@ -6,7 +6,6 @@
Original name: Русский
Author: Max Pozdeev
Author Url: http://www.mytinytodo.net
AppVersion: v1.4.2
Date: 2011-03-21
*/

31
.ht_setup.php → setup.php

@ -44,14 +44,13 @@ else
$dbtype = '';
}
$lastVer = '1.4';
echo '<html><head><meta name="robots" content="noindex,nofollow"><title>myTinyTodo 1.4.3x Setup</title></head><body>';
echo "<h1><b>myTinyTodo 1.4.3 Setup</b></h1><br><br>";
$lastDatabaseVersion = '1.4'; // the last *database* schema revision, hence rarely what get_version() returns!
echo '<html><head><meta name="robots" content="noindex,nofollow"><title>myTinyTodo '.get_version().' Setup</title></head><body>';
echo "<h1><b>myTinyTodo ".get_version()." Setup</b></h1><br><br>";
# determine current installed version
$ver = get_ver($db, $dbtype);
if(!$ver)
$this_db_ver = get_db_ver($db, $dbtype);
if(!$this_db_ver)
{
# Which DB to select
if(!isset($_POST['installdb']) && !isset($_POST['install']))
@ -89,7 +88,7 @@ if(!$ver)
}
# install database
if($dbtype == 'mysql')
if($dbtype == 'mysql')
{
try
{
@ -224,39 +223,39 @@ if(!$ver)
$db->ex("INSERT INTO {$db->prefix}lists (uuid,name,d_created) VALUES (?,?,?)", array(generateUUID(), 'Todo', time()));
}
elseif($ver == $lastVer)
elseif($this_db_ver == $lastDatabaseVersion)
{
exitMessage("Installed version does not require database update.");
}
else
{
if(!in_array($ver, array('1.1','1.2','1.3.0','1.3.1'))) {
exitMessage("Can not update. Unsupported database version ($ver).");
if(!in_array($this_db_ver, array('1.1','1.2','1.3.0','1.3.1'))) {
exitMessage("Can not update. Unsupported database version ($this_db_ver).");
}
if(!isset($_POST['update'])) {
exitMessage("Update database v$ver
exitMessage("Update database v$this_db_ver
<form name=frm method=post><input type=hidden name=update value=1><input type=hidden name=tz value=-1><input type=submit value=' Update '></form>
<script type=\"text/javascript\">var tz = -1 * (new Date()).getTimezoneOffset(); document.frm.tz.value = tz;</script>
");
}
# update process
if($ver == '1.3.1')
if($this_db_ver == '1.3.1')
{
update_131_14($db, $dbtype);
}
if($ver == '1.3.0')
if($this_db_ver == '1.3.0')
{
update_130_131($db, $dbtype);
update_131_14($db, $dbtype);
}
if($ver == '1.2')
if($this_db_ver == '1.2')
{
update_12_13($db, $dbtype);
update_130_131($db, $dbtype);
update_131_14($db, $dbtype);
}
elseif($ver == '1.1')
elseif($this_db_ver == '1.1')
{
update_11_12($db, $dbtype);
update_12_13($db, $dbtype);
@ -268,7 +267,7 @@ echo "Done<br><br> <b>Attention!</b> Delete this file for security reasons.";
printFooter();
function get_ver($db, $dbtype)
function get_db_ver($db, $dbtype)
{
if(!$db || $dbtype == '') return '';
if(!$db->table_exists($db->prefix.'todolist')) return '';

16
themes/default/index.php

@ -4,16 +4,16 @@
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php mttinfo('title'); ?></title>
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>style.css?v=1.4.3" media="all" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>style.css" media="all" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>tags.css" media="all" />
<?php if(Config::get('rtl')): ?>
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>style_rtl.css?v=1.4.3" media="all" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>style_rtl.css" media="all" />
<?php endif; ?>
<?php if(isset($_GET['pda'])): ?>
<meta name="viewport" id="viewport" content="width=device-width" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>pda.css?v=1.4.3" media="all" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>pda.css" media="all" />
<?php else: ?>
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>print.css?v=1.4.3" media="print" />
<link rel="stylesheet" type="text/css" href="<?php mttinfo('template_url'); ?>print.css" media="print" />
<link rel="shortcut icon" href="favicon.ico" />
<?php endif; ?>
<meta name="viewport" content="width=device-width, initial-scale = 1.0, maximum-scale=2.0, user-scalable=no" />
@ -24,9 +24,9 @@
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>jquery/jquery-1.4.4.min.js"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>jquery/jquery-ui-1.8.7.custom.min.js"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>jquery/jquery.autocomplete-1.1.js"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo.js?v=1.4.3"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo_lang.php?v=1.4.3"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo_ajax_storage.js?v=1.4.3"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo.js"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo_lang.php"></script>
<script type="text/javascript" src="<?php mttinfo('mtt_url'); ?>mytinytodo_ajax_storage.js"></script>
<script type="text/javascript">
@ -290,7 +290,7 @@ $().ready(function(){
<div id="space"></div>
</div>
<div id="footer"><div id="footer_content">Powered by <strong><a href="https://github.com/MoonCactus/myTDX/">myTDX</a></strong> 1.5.0</div></div>
<div id="footer"><div id="footer_content">Powered by <strong><a href="https://github.com/MoonCactus/myTDX/">myTDX</a></strong> <?php echo get_version();?></div></div>
</div>
</body>

2
version.txt

@ -1 +1 @@
1.5.0
1.5.1
Loading…
Cancel
Save