From b7de0d5e8f5aac915fe58378dd2592f1b4917d95 Mon Sep 17 00:00:00 2001 From: daitingting Date: Wed, 23 May 2018 16:13:49 +0800 Subject: [PATCH 01/16] * Adjust width for actions. --- module/task/view/recordestimate.html.php | 74 ++++++++++++------------ 1 file changed, 38 insertions(+), 36 deletions(-) diff --git a/module/task/view/recordestimate.html.php b/module/task/view/recordestimate.html.php index 3bcc5e6193..63df990799 100644 --- a/module/task/view/recordestimate.html.php +++ b/module/task/view/recordestimate.html.php @@ -45,44 +45,46 @@ task->consumedThisTime;?> task->leftThisTime;?> comment;?> - + actions;?> - - - - id;?> - date;?> - consumed;?> - left;?> - work;?> - - status == 'wait' or $task->status == 'pause' or $task->status == 'doing') - { - common::printIcon('task', 'editEstimate', "estimateID=$estimate->id", '', 'list', 'pencil', '', 'showinonlybody', true); - common::printIcon('task', 'deleteEstimate', "estimateID=$estimate->id", '', 'list', 'remove', 'hiddenwin', 'showinonlybody'); - } - ?> - - - - - status, array('wait', 'pause', 'doing'))):?> - - - - - - - - - - - - - - + + + + + id;?> + date;?> + consumed;?> + left;?> + work;?> + + status == 'wait' or $task->status == 'pause' or $task->status == 'doing') + { + common::printIcon('task', 'editEstimate', "estimateID=$estimate->id", '', 'list', 'pencil', '', 'showinonlybody', true); + common::printIcon('task', 'deleteEstimate', "estimateID=$estimate->id", '', 'list', 'trash', 'hiddenwin', 'showinonlybody'); + } + ?> + + + + + status, array('wait', 'pause', 'doing'))):?> + + + + + + + + + + + + + + + From bfc735fb2206555abb1ab279210c72c657fda97b Mon Sep 17 00:00:00 2001 From: Catouse Date: Thu, 24 May 2018 17:19:13 +0800 Subject: [PATCH 02/16] * refactor codes. --- module/dept/view/browse.html.php | 8 ++--- module/dept/view/edit.html.php | 50 ++++++++++++++++------------ module/tree/view/browsetask.html.php | 5 ++- module/tree/view/edit.html.php | 2 +- 4 files changed, 36 insertions(+), 29 deletions(-) diff --git a/module/dept/view/browse.html.php b/module/dept/view/browse.html.php index 3e43eb538b..8a3e0221cd 100644 --- a/module/dept/view/browse.html.php +++ b/module/dept/view/browse.html.php @@ -130,11 +130,11 @@ $(function() var action = event.action, $target = $(event.target), item = event.item; if(action.type === 'edit') { - $target.modalTrigger( - { + new $.zui.ModalTrigger({ type: 'ajax', - url: action.linkTemplate.format(item.id) - }).trigger('click'); + url: action.linkTemplate.format(item.id), + keyboard: true + }).show(); } else if(action.type === 'delete') { diff --git a/module/dept/view/edit.html.php b/module/dept/view/edit.html.php index 339db03750..b020116598 100644 --- a/module/dept/view/edit.html.php +++ b/module/dept/view/edit.html.php @@ -15,24 +15,32 @@ $webRoot = $this->app->getWebRoot(); $jsRoot = $webRoot . "js/"; ?> -
- - - - - - - - - - - - - - - - -
dept->parent;?>parent, "class='form-control chosen'");?>
dept->name;?>name, "class='form-control' autocomplete='off'");?>
dept->manager;?>manager, "class='form-control chosen'", true);?>
- -
-
+ diff --git a/module/tree/view/browsetask.html.php b/module/tree/view/browsetask.html.php index 0943e62721..8bc2395991 100644 --- a/module/tree/view/browsetask.html.php +++ b/module/tree/view/browsetask.html.php @@ -178,12 +178,11 @@ $(function() var action = event.action, $target = $(event.target), item = event.item; if(action.type === 'edit') { - $target.modalTrigger( - { + new $.zui.ModalTrigger({ type: 'ajax', url: action.linkTemplate.format(item.id), keyboard: true - }).trigger('click'); + }).show(); } else if(action.type === 'delete') { diff --git a/module/tree/view/edit.html.php b/module/tree/view/edit.html.php index c405a18f5e..12631222ac 100644 --- a/module/tree/view/edit.html.php +++ b/module/tree/view/edit.html.php @@ -17,7 +17,7 @@ $jsRoot = $webRoot . "js/";