Skip to content

Commit

Permalink
Plans fixes
Browse files Browse the repository at this point in the history
* Plans: CP html element fix
* Plans: CP components adding fix
  • Loading branch information
sergejey committed Oct 6, 2019
1 parent 5d78f78 commit 52ceeeb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions modules/plans/components.inc.php
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@
SQLUpdate('plan_components',$component); SQLUpdate('plan_components',$component);
} else { } else {
$component['ID']=SQLInsert('plan_components',$component); $component['ID']=SQLInsert('plan_components',$component);
$component_id = $component['ID'];
} }
$out['OK']=1; $out['OK']=1;
//$this->redirect("?view_mode=".$this->view_mode."&id=".$plan_id."&tab=".$this->tab); //$this->redirect("?view_mode=".$this->view_mode."&id=".$plan_id."&tab=".$this->tab);
Expand Down
1 change: 1 addition & 0 deletions modules/plans/plan_component.class.php
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ function processProperties(&$properties)
} else { } else {
$property['VALUE'] = $property['DEFAULT']; $property['VALUE'] = $property['DEFAULT'];
} }
$property['VALUE_HTML']=htmlspecialchars($property['VALUE']);
} }
} }


Expand Down
2 changes: 1 addition & 1 deletion templates/plans/plans_components.html
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
</select> </select>
[#endif TYPE#] [#endif TYPE#]
[#if TYPE=="int" || TYPE=="text" || TYPE=="float"#] [#if TYPE=="int" || TYPE=="text" || TYPE=="float"#]
<input type="text" name="property_[#NAME#]" value="[#VALUE#]" class="form-control" placeholder="[#DEFAULT#]"> <input type="text" name="property_[#NAME#]" value="[#VALUE_HTML#]" class="form-control" placeholder="[#DEFAULT#]">
[#endif TYPE#] [#endif TYPE#]
[#if TYPE=="rgb"#] [#if TYPE=="rgb"#]
<input type="text" name="property_[#NAME#]" id="property_[#NAME#]" value="[#VALUE#]" class="form-control" placeholder="[#DEFAULT#]"> <input type="text" name="property_[#NAME#]" id="property_[#NAME#]" value="[#VALUE#]" class="form-control" placeholder="[#DEFAULT#]">
Expand Down

0 comments on commit 52ceeeb

Please sign in to comment.