From 9ab9c376f73dc683b6856d8e9f290a76a0466754 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 17 Sep 2015 14:31:35 +0800 Subject: [PATCH] * adjust for task #2295. --- module/story/js/view.js | 5 +++++ module/story/view/view.html.php | 11 ++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/module/story/js/view.js b/module/story/js/view.js index c247ba48c4..c7329b89bb 100644 --- a/module/story/js/view.js +++ b/module/story/js/view.js @@ -1,3 +1,8 @@ $(function() { + if(canCreate) + { + link = createLink('story', 'create', 'productID=' + productID + '&moduleID=' + moduleID); + $('#modulemenu ul.nav li.right:first').before("
  • " + createStory + "
  • "); + } }); diff --git a/module/story/view/view.html.php b/module/story/view/view.html.php index 4545bdf8cd..dbe349db25 100644 --- a/module/story/view/view.html.php +++ b/module/story/view/view.html.php @@ -36,11 +36,6 @@ $browseLink = $app->session->storyList != false ? $app->session->storyList : $this->createLink('product', 'browse', "productID=$story->product&moduleID=$story->module"); $actionLinks = ''; - /* Add story convenient. */ - echo "
    "; - common::printIcon('story', 'create', "productID=$story->product&moduleID=$story->module", '', 'button', 'plus'); - echo '
    '; - if(!$story->deleted) { ob_start(); @@ -301,5 +296,11 @@ +story->create); +js::set('productID', $story->product); +js::set('moduleID', $story->module); +?>