Merge pull request #163 from misol/improve/save-the-mobile

설문조사 스킨 다듬기 PR
This commit is contained in:
MinSoo Kim 2016-01-26 20:00:58 +09:00
commit 3c375c807d
26 changed files with 767 additions and 950 deletions

View file

@ -31,14 +31,14 @@ $(function(){
, onSelect:function(){
$(this).prev('input[type="hidden"]').val(this.value.replace(/-/g,""));
}
,minDate: new Date("{date('Y-m-d',time()+60*60*24*30)}")
,defaultDate: new Date("{date('Y-m-d',time()+60*60*24*30)}")
,minDate: new Date("{date('Y-m-d',time())}")
};
$.extend(option,$.datepicker.regional['{$lang_type}']);
$.extend(option,$.datepicker.regional['{str_replace('jp','ja',$lang_type)}']);
$(".inputDate").datepicker(option);
});
})(jQuery);
</script>
</div>
</div>
<div class="x_control-group">
@ -46,7 +46,7 @@ $(function(){
<div class="x_controls">
<select id="skin" name="skin">
<!--@foreach($skin_list as $skin=>$skin_info)-->
<option value="{$skin}">{$skin_info->title} (skin by <!--@foreach($skin_info->author as $author=>$author_info)-->{@ $authorname = array(); $authorname[] = $author_info->name; }<!--@end-->{implode(",",$authorname)})</option>
<option value="{$skin}">{$skin_info->title} (by {@ $authorname = array();}<!--@foreach($skin_info->author as $author=>$author_info)-->{@ $authorname[] = $author_info->name; }<!--@end-->{implode(",",$authorname)})</option>
<!--@end-->
</select>
</div>

View file

@ -7,16 +7,16 @@
* 부모창의 위지윅에디터에 데이터를 삽입
**/
function completeInsertPoll(ret_obj) {
if(typeof(opener)=="undefined") return null;
if(typeof(opener)=="undefined") return null;
var fo_obj = get_by_id('fo_component');
var skin = fo_obj.skin.options[fo_obj.skin.selectedIndex].value;
var fo_obj = get_by_id('fo_component');
var skin = fo_obj.skin.options[fo_obj.skin.selectedIndex].value;
var poll_srl = ret_obj["poll_srl"];
if(!poll_srl) return null;
var poll_srl = ret_obj["poll_srl"];
if(!poll_srl) return null;
var text = "<img src=\"../../../../common/img/blank.gif\" poll_srl=\""+poll_srl+"\" editor_component=\"poll_maker\" skin=\""+skin+"\" style=\"display:block;width:400px;height:300px;border:2px dotted #4371B9;background:url(./modules/editor/components/poll_maker/tpl/poll_maker_component.gif) no-repeat center;\" />";
alert(ret_obj['message']);
var text = "<img src=\"../../../../common/img/blank.gif\" poll_srl=\""+poll_srl+"\" editor_component=\"poll_maker\" skin=\""+skin+"\" style=\"display:block;width:400px;height:300px;border:2px dotted #4371B9;background:url(./modules/editor/components/poll_maker/tpl/poll_maker_component.gif) no-repeat center;\" />";
alert(ret_obj['message']);
opener.editorFocus(opener.editorPrevSrl);
@ -24,9 +24,9 @@ function completeInsertPoll(ret_obj) {
opener.editorReplaceHTML(iframe_obj, text);
opener.editorFocus(opener.editorPrevSrl);
window.close();
window.close();
return null;
return null;
}
jQuery(function($){

View file

@ -1 +0,0 @@
function completeInsertPoll(e){if("undefined"==typeof opener)return null;var t=get_by_id("fo_component"),o=t.skin.options[t.skin.selectedIndex].value,n=e.poll_srl;if(!n)return null;var l='<img src="../../../../common/img/blank.gif" poll_srl="'+n+'" editor_component="poll_maker" skin="'+o+'" style="display:block;width:400px;height:300px;border:2px dotted #4371B9;background:url(./modules/editor/components/poll_maker/tpl/poll_maker_component.gif) no-repeat center;" />';alert(e.message),opener.editorFocus(opener.editorPrevSrl);var i=opener.editorGetIFrame(opener.editorPrevSrl);return opener.editorReplaceHTML(i,l),opener.editorFocus(opener.editorPrevSrl),window.close(),null}jQuery(function(e){function t(){var t=e(".poll_box");$inputs=t.find("input"),poll_idx=0,$inputs.attr("name",function(e,t){return/^checkcount_/.test(t)&&poll_idx++,t.replace(/^([a-z]+_)(?:tidx|\d+)/,"$1"+poll_idx)}),t.length>1?t.find("button._del_poll").show():t.find("button._del_poll").hide()}function o(){var o=e("#poll_source");o.before(o.clone(!0).removeAttr("id").addClass("poll_box").css("display","block")),t()}var n;return n=e(opener.editorPrevNode),n.length&&"poll_maker"==n.attr("editor_component")?(alert(msg_poll_cannot_modify),window.close()):(e("#add_poll").click(function(){o(),setFixedPopupSize()}),e("button._add_item").click(function(){var t,o,n;t=e(this).prev().children("table").find(">tbody>tr:last"),o=t.clone(),match=t.find("td>input").attr("name").match(/item_(\d+)_(\d+)$/),match&&(match[2]++,(n=o.find("th")).html(n.html().replace(/ \d+/," "+match[2])),o.find("td>input").attr("name","item_"+match[1]+"_"+match[2]),t.after(o),setFixedPopupSize())}),e("button._del_item").click(function(){var t,o;t=e(this).prevAll("div").children("table").find(">tbody>tr:last"),o=t.find("td>input").attr("name").match(/item_(\d+)_(\d+)/),o&&2!=o[2]&&(t.remove(),setFixedPopupSize())}),e("button._del_poll").click(function(){e(this).parent(".poll_box").remove(),t()}),void o())}),jQuery(window).load(setFixedPopupSize);