Changeset 20647
- Timestamp:
- 2011/03/15 15:57:08 (11 years ago)
- Location:
- branches/version-2_5-dev/data
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_5-dev/data/Smarty/templates/admin/design/main_edit.tpl
r20618 r20647 84 84 <tr> 85 85 <td colspan="2"> 86 <label for="header-chk"><input type="checkbox" name="header_chk" id="header-chk" checked="<!--{$arrPageData.header_chk}-->"/>共通のヘッダーを使用する</label> 87 <label for="footer-chk"><input type="checkbox" name="footer_chk" id="footer-chk" checked="<!--{$arrPageData.footer_chk}-->"/>共通のフッターを使用する</label>86 <label for="header-chk"><input type="checkbox" name="header_chk" id="header-chk" <!--{if $arrPageData.header_chk != "2"}-->checked="checked"<!--{/if}--> />共通のヘッダーを使用する</label> 87 <label for="footer-chk"><input type="checkbox" name="footer_chk" id="footer-chk" <!--{if $arrPageData.footer_chk != "2"}-->checked="checked"<!--{/if}--> />共通のフッターを使用する</label> 88 88 <div> 89 89 <textarea id="tpl_data" class="top" name="tpl_data" rows=<!--{$text_row}--> style="width: 98%;"><!--{$arrPageData.tpl_data|h|smarty:nodefaults}--></textarea> -
branches/version-2_5-dev/data/class/pages/admin/design/LC_Page_Admin_Design_MainEdit.php
r20618 r20647 152 152 $templatePath = $this->objLayout->getTemplatePath($device_type_id); 153 153 $arrPageData[0]['tpl_data'] = file_get_contents($templatePath . $arrPageData[0]['filename'] . ".tpl"); 154 155 // チェックボックスの値変更156 $arrPageData[0]['header_chk'] = SC_Utils_Ex::sfChangeCheckBox($arrPageData[0]['header_chk'], true);157 $arrPageData[0]['footer_chk'] = SC_Utils_Ex::sfChangeCheckBox($arrPageData[0]['footer_chk'], true);158 154 159 155 // ディレクトリを画面表示用に編集 -
branches/version-2_5-dev/data/class/util/SC_Utils.php
r20541 r20647 1133 1133 } 1134 1134 1135 // チェックボックスの型を変換する1136 function sfChangeCheckBox($data , $tpl = false){1137 if ($tpl) {1138 if ($data == 1){1139 return 'checked';1140 }else{1141 return "";1142 }1143 }else{1144 if ($data == 'on'){1145 return 1;1146 }else{1147 return 2;1148 }1149 }1150 }1151 1152 1135 // 2つの配列を用いて連想配列を作成する 1153 1136 function sfArrCombine($arrKeys, $arrValues) {
Note: See TracChangeset
for help on using the changeset viewer.