@@ -, +, @@ --- C4/Budgets.pm | 10 +++++- acqui/acqui-home.pl | 36 ++++++++++++---------- koha-tmpl/intranet-tmpl/prog/css/staff-global.css | 34 ++++++++++++++++++++ .../prog/en/includes/onboardinginclude1.inc | 21 +++---------- .../prog/en/includes/onboardinginclude2.inc | 19 ++---------- .../prog/en/includes/onboardinginclude3.inc | 21 ++----------- .../prog/en/modules/acqui/acqui-home.tt | 24 +-------------- .../prog/en/modules/admin/aqbudgetperiods.tt | 2 +- 8 files changed, 74 insertions(+), 93 deletions(-) --- a/C4/Budgets.pm +++ a/C4/Budgets.pm @@ -148,9 +148,17 @@ sub GetPeriodsCount { # ------------------------------------------------------------------- +=head2 GetHighestBudgetPeriod + + &my $budgetid = C4::Budgets->GetHighestBudgetPeriod(); + +Retrieve the highest budget + +=cut + sub GetHighestBudgetPeriod{ my $dbh = C4::Context->dbh; - warn my $data = $dbh->selectrow_array("SELECT MAX(budget_period_id) FROM aqbudgetperiods"); + my $data = $dbh->selectrow_array("SELECT MAX(budget_period_id) FROM aqbudgetperiods"); return $data; } # ------------------------------------------------------------------- --- a/acqui/acqui-home.pl +++ a/acqui/acqui-home.pl @@ -53,6 +53,7 @@ my ( $template, $loggedinuser, $cookie, $userflags ) = get_template_and_user( my $status = $query->param('status') || "ASKED"; my $suggestions_count = CountSuggestion($status); +my $userid = $query->param('userid'); my $budget_arr = GetBudgetHierarchy; @@ -124,11 +125,6 @@ $template->param( suggestions_count => $suggestions_count, ); - - - - - my $aqstep; my $cur = Koha::Acquisition::Currencies->get_active; @@ -141,18 +137,24 @@ if ( $cur ) { my $budget = GetPeriodsCount(); my $budgetid = C4::Budgets->GetHighestBudgetPeriod(); if (!@budget_loop){ -if (!$cur) { - $aqstep = 1; - $template->param( step => $aqstep ); -} elsif ($budget && $budgetid == 1){ - $aqstep = 3; - $template->param( step => $aqstep ); -} elsif ($budgetid > 1) { - print $query->redirect("/cgi-bin/koha/admin/aqbudgetperiods.pl"); - exit; -} else { - $aqstep = 2; - $template->param( step => $aqstep ); + if (!$cur) { + $aqstep = 1; + $template->param( step => $aqstep ); + } elsif ($budget && $budgetid == 1){ + $aqstep = 3; + $template->param( step => $aqstep ); + } elsif ($budgetid > 1) { + print $query->redirect("/cgi-bin/koha/admin/aqbudgetperiods.pl"); + exit; + } else { + $aqstep = 2; + $template->param( step => $aqstep ); + } } + +if ( C4::Context->IsSuperLibrarian() ) { + my $displayonboard = 1; + $template->param( displayonboard => $displayonboard ); } + output_html_with_http_headers $query, $cookie, $template->output; --- a/koha-tmpl/intranet-tmpl/prog/css/staff-global.css +++ a/koha-tmpl/intranet-tmpl/prog/css/staff-global.css @@ -3025,3 +3025,37 @@ div#aqhelp{ padding:20px; width:50%; } + +#onboardingModal{ + z-index:1; + background-color:#EDF4F6; + padding: .2em 0; + width: 32%; + float:right; + position:relative; + top: 10px; + padding-left:10px; + padding-right:10px; + border-radius:10px; +} + +#acqui-onboard{ + text-align: center; + padding-bottom:15px; +} + +#currency_code_onboard{ + width:40%; +} + +#budget_period_description_onboard{ + width:55%; +} + +#budget_name_onboard{ + width:55%; +} + +#budget_code_onboard{ + width:55%; +} --- a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude1.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude1.inc @@ -1,21 +1,8 @@ - -
-

Acquisition onboarding wizard

+

Acquisition onboarding wizard

+

This onboarding wizard will take you through the process of setting up Acquistions

-

Start by completing this form to create a currency which you will be used to create your first budget and fund.
+

Start by completing this form to create a currency which you will use to create your first budget and fund.
A fund is the accounting value you use to create orders

@@ -33,7 +20,7 @@ [% currency.currency %] [% ELSE %] - Required + Required [% END %] --- a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude2.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude2.inc @@ -1,23 +1,10 @@ -
[% IF displayonboardscreen == "acquisitions" %] -

Acquisition onboarding wizard

+

Acquisition onboarding wizard

Create a budget which is the highest level value in acquisitions accountancy.
After creating this budget you will be prompted to create a fund which is what you will use to set up orders.

- If you have previously created a budget (which was subsequently deleted) then you will be redirected to the Budget Administration page after creating a budget using this form. On the Budget Administration page click Actions->Add fund to create a fund + If you have previously created a budget (which was subsequently deleted) then you will be redirected to the budget administration page after creating a budget using this form. On the budget administration page click Actions->Add fund to create a fund

Create a budget

@@ -39,7 +26,7 @@
  • - +
  • --- a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude3.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/onboardinginclude3.inc @@ -1,21 +1,6 @@ [% USE Price %] - - -
    -

    Acquisition onboarding wizard

    +

    Acquisition onboarding wizard

    Fill out this form to create a fund which will be assigned to the budget you just created.
    A fund is an accounting value you will use to set up orders


    @@ -46,12 +31,12 @@
  • - +
  • - +
  • --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/acqui-home.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/acqui-home.tt @@ -111,7 +111,7 @@ $(document).ready(function() { [% INCLUDE 'acquisitions-toolbar.inc' %] [% UNLESS ( loop_budget ) %] - [% IF ( CAN_user_acquisition_period_manage ) %] + [% IF ( CAN_user_acquisition_period_manage ) && displayonboard %] [% displayonboardscreen = "acquisitions" %] [% IF step == 1 %] [% INCLUDE onboardinginclude1.inc %] @@ -254,28 +254,6 @@ $(document).ready(function() {
  • [% END %] - - -

    -
    -

    Next steps

    -

    1. Create your first vendor

    -

    A vendor is the organisation your institution purchases items from i.e. suppliers
    - You must create a vendor before you can create any orders

    - Click here to create a vendor. -

    -

    2. Create your first basket

    -

    A basket is the conceptual container that holds orders. Each basket is assigned to a single vendor so you can perform multiple separate orders from a single vendor simultaneously. Because of its reliance on vendor the basket must be created after the vendor

    - To create a basket, click the 'New basket' button on the Vendor Information page which is displayed after you create a vendor -

    -

    3. Create an order

    -

    An order is a assignment of items purchased from a single vendor at a single time

    - You create an order by clicking "Add to basket" in the Basket page. From here you can choose the item(s) you want to purchase from existing MARC records in your Koha catalogue, subscription, new item record, external source, staged file (bibliographic file in the process of being uploaded), or from popularly held items. -

    -

    - For further information about creating a vendor, basket and order go to the Koha manual: - Koha manual Acquisitions section -
    --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgetperiods.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgetperiods.tt @@ -340,7 +340,7 @@
  • - +
    [% INCLUDE 'date-format.inc' %]
  • --