Skip to content

Commit

Permalink
Upgrade to release v1.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik-v committed Nov 10, 2014
1 parent 702a264 commit a561a2a
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 24 deletions.
10 changes: 9 additions & 1 deletion CHANGE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
Version 1.1.0
=============
**Date:** 10-Nov-2014

- PSR4 alias change
- Set dependency on Krajee base components
- Set release to stable

Version 1.0.0
=============
**Date:** 09-May-2014

Initial release
- Initial release
6 changes: 3 additions & 3 deletions daterange/DateRangePicker.php → DateRangePicker.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* @copyright Copyright © Kartik Visweswaran, Krajee.com, 2014
* @package yii2-date-range
* @version 1.0.0
* @version 1.1.0
*/

namespace kartik\daterange;
Expand All @@ -23,7 +23,7 @@
* @author Kartik Visweswaran <kartikv2@gmail.com>
* @since 1.0
*/
class DateRangePicker extends \kartik\widgets\InputWidget
class DateRangePicker extends \kartik\base\InputWidget
{
const PLUGIN_NAME = 'daterangepicker';

Expand Down Expand Up @@ -178,7 +178,7 @@ protected function checkLocale() {
return true;
}
$s = DIRECTORY_SEPARATOR;
$file = __DIR__ . "{$s}..{$s}assets{$s}js{$s}locales{$s}daterange-{$this->language}.js";
$file = __DIR__ . "{$s}assets{$s}js{$s}locales{$s}daterange-{$this->language}.js";
return (file_exists($file));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* @copyright Copyright &copy; Kartik Visweswaran, Krajee.com, 2014
* @package yii2-date-range
* @version 1.0.0
* @version 1.1.0
*/

namespace kartik\daterange;
Expand All @@ -14,13 +14,13 @@
* @author Kartik Visweswaran <kartikv2@gmail.com>
* @since 1.0
*/
class DateRangePickerAsset extends \kartik\widgets\AssetBundle
class DateRangePickerAsset extends \kartik\base\AssetBundle
{
public $depends = ['\kartik\daterange\MomentAsset'];

public function init()
{
$this->setSourcePath(__DIR__ . '/../assets');
$this->setSourcePath(__DIR__ . '/assets');
$this->setupAssets('css', ['css/daterangepicker', 'css/daterangepicker-kv']);
$this->setupAssets('js', ['js/daterangepicker']);
parent::init();
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2013, Kartik Visweswaran
Copyright (c) 2014, Kartik Visweswaran
Krajee.com
All rights reserved.

Expand Down
6 changes: 3 additions & 3 deletions daterange/LanguageAsset.php → LanguageAsset.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* @copyright Copyright &copy; Kartik Visweswaran, Krajee.com, 2014
* @package yii2-date-range
* @version 1.0.0
* @version 1.1.0
*/

namespace kartik\daterange;
Expand All @@ -14,14 +14,14 @@
* @author Kartik Visweswaran <kartikv2@gmail.com>
* @since 1.0
*/
class LanguageAsset extends \kartik\widgets\AssetBundle
class LanguageAsset extends \kartik\base\AssetBundle
{
public $jsOptions = ['position' => \yii\web\View::POS_HEAD];
public $depends = ['\kartik\daterange\MomentAsset'];

public function init()
{
$this->setSourcePath(__DIR__ . '/../assets/js/locales');
$this->setSourcePath(__DIR__ . '/assets/js/locales');
parent::init();
}

Expand Down
6 changes: 3 additions & 3 deletions daterange/MomentAsset.php → MomentAsset.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/**
* @copyright Copyright &copy; Kartik Visweswaran, Krajee.com, 2014
* @package yii2-date-range
* @version 1.0.0
* @version 1.1.0
*/

namespace kartik\daterange;
Expand All @@ -14,13 +14,13 @@
* @author Kartik Visweswaran <kartikv2@gmail.com>
* @since 1.0
*/
class MomentAsset extends \kartik\widgets\AssetBundle
class MomentAsset extends \kartik\base\AssetBundle
{
public $jsOptions = ['position' => \yii\web\View::POS_HEAD];

public function init()
{
$this->setSourcePath(__DIR__ . '/../assets');
$this->setSourcePath(__DIR__ . '/assets');
$this->setupAssets('js', ['js/moment']);
parent::init();
}
Expand Down
10 changes: 2 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,15 @@ Additional enhancements added for this widget (by Krajee):
- style the container options as per your need using templates
- automatically disable date-range based on disabled/readonly options.

> NOTE: This extension depends on the [kartik-v/yii2-widgets](https://github.com/kartik-v/yii2-widgets) extension which in turn depends on the
[yiisoft/yii2-bootstrap](https://github.com/yiisoft/yii2/tree/master/extensions/bootstrap) extension. Check the
[composer.json](https://github.com/kartik-v/yii2-date-range/blob/master/composer.json) for this extension's requirements and dependencies.
Note: Yii 2 framework is still in active development, and until a fully stable Yii2 release, your core yii2-bootstrap packages (and its dependencies)
may be updated when you install or update this extension. You may need to lock your composer package versions for your specific app, and test
for extension break if you do not wish to auto update dependencies.

### Demo
You can see detailed [documentation](http://demos.krajee.com/date-range) on usage of the extension.

## Installation

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

> Note: You must set the `minimum-stability` to `dev` in the **composer.json** file in your application root folder before installation of this extension.
> Note: Check the [composer.json](https://github.com/kartik-v/yii2-date-range/blob/master/composer.json) for this extension's requirements and dependencies.
Read this [web tip /wiki](http://webtips.krajee.com/setting-composer-minimum-stability-application/) on setting the `minimum-stability` settings for your application's composer.json.

Either run

Expand Down
5 changes: 3 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@
"homepage": "http://www.krajee.com/"
}
],
"minimum-stability": "stable",
"require": {
"kartik-v/yii2-widgets": "*"
"kartik-v/yii2-krajee-base": "*"
},
"autoload": {
"psr-4": {
"kartik\\": ""
"kartik\\daterange\\": ""
}
}
}

0 comments on commit a561a2a

Please sign in to comment.