Added javascript to give a #URL when clicking on tabs (good for backup in browser, and bookmarks)
svn: r19717
This commit is contained in:
parent
61bd569c29
commit
1bd9848b1a
@ -4,14 +4,33 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
$('#general-tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
$('#general-tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#general-tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
||||
{% include "detail_breadcrumb.html" %}
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,8 +4,19 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$('#tabs').tabs();
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
$('.wysiwyg').htmlarea({
|
||||
toolbar: [
|
||||
"bold", "italic", "underline",
|
||||
@ -17,10 +28,10 @@
|
||||
// FIXME: add font, fontsize, backcolor
|
||||
// FIXME: find easier way:
|
||||
$('.jHtmlArea').contents().find('iframe').contents().find('body').css({"background-color": "white"});
|
||||
});
|
||||
function setnotetext() {
|
||||
});
|
||||
function setnotetext() {
|
||||
document.getElementById('notetext').value = $('.jHtmlArea').contents().find('iframe').contents().find('body').html();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,13 +4,22 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
||||
{% include "detail_breadcrumb.html" %}
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
@ -4,10 +4,20 @@
|
||||
{% block content %}
|
||||
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
|
||||
$('#tabs').tabs();
|
||||
});
|
||||
$(function(){
|
||||
var selectedTab = 0;
|
||||
$('#tabs li a').each(function(index) {
|
||||
if ($(this).attr('href').replace("#", "#tab-") == document.location.hash) {
|
||||
selectedTab = index;
|
||||
}
|
||||
});
|
||||
$('#tabs').tabs({
|
||||
'select': function(event, ui){
|
||||
document.location.hash = "tab-" + ui.panel.id;
|
||||
},
|
||||
'selected' : selectedTab
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="content" id="IndividualDetail">
|
||||
|
Loading…
x
Reference in New Issue
Block a user