This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Directive to instantly enable/disable multiple checkboxes based on a master checkbox. | |
| * Changing slave checkboxes will update the master checkbox accordingly, including the indeterminate state. | |
| * | |
| * Usage example: | |
| * | |
| * <label><input type="checkbox" select-all="theProperties"> Select all</label> | |
| * <div ng-repeat="property in properties"> | |
| * <label><input type="checkbox" rel="theProperties" ng-model="property.checked"> {{ property.label }}</label> | |
| * </div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * parseNumeric('123') === 123 | |
| * parseNumeric('10 abc') === undefined | |
| * parseNumeric('10.10%') === 10.1 | |
| * parseNumeric(' 10.1000 ') === 10.1 | |
| * parseNumeric('10. 01%' ) === undefined | |
| * parseNumeric('10.0 %') === 10 | |
| */ | |
| function parseNumeric(number) { | |
| var num = ('' + number).trim(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $stateProvider.state('projects.edit.section', { | |
| url: '/:sectionCode', | |
| templateUrl: function(stateParams) { | |
| return 'partials/project/' + stateParams.sectionCode + '.html'; | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if (!defined('SED_CODE')){die('Wrong URL.'); } | |
| $currenttpl = file_get_contents($mskin); | |
| if (mb_strpos($currenttpl, "{PAGE_TEXT_ID_") !== false) | |
| { | |
| $matches = array(); | |
| preg_match_all("#{(?P<tag>PAGE_TEXT_ID_(?P<id>[0-9]+))}#", $currenttpl, $matches, PREG_SET_ORDER); | |
| foreach ($matches as $match){ | |
| $p_tag = $match['tag']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| defined('COT_CODE') or die('Wrong URL.'); | |
| class ProjectController extends RESTController | |
| { | |
| public function create() | |
| { | |
| $this->respondsTo('POST'); | |
| $data = Project::import(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| defined('COT_CODE') or die('Wrong URL.'); | |
| class Member extends CotORM | |
| { | |
| protected $table_name = 'users'; | |
| protected $columns = array( | |
| 'id' => array( | |
| 'type' => 'int', |
NewerOlder