mirror of
https://github.com/fergalmoran/dss.git
synced 2026-01-06 17:04:30 +00:00
Added event create view
This commit is contained in:
1
core/serialisers/__init__.py
Normal file
1
core/serialisers/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
__author__ = 'fergalm'
|
||||
17
core/serialisers/json.py
Normal file
17
core/serialisers/json.py
Normal file
@@ -0,0 +1,17 @@
|
||||
from django.core.serializers import serialize
|
||||
from django.utils.simplejson import dumps, loads, JSONEncoder
|
||||
from django.db.models.query import QuerySet
|
||||
from django.utils.functional import curry
|
||||
|
||||
class DjangoJSONEncoder(JSONEncoder):
|
||||
def default(self, obj):
|
||||
if isinstance(obj, QuerySet):
|
||||
# `default` must return a python serializable
|
||||
# structure, the easiest way is to load the JSON
|
||||
# string produced by `serialize` and return it
|
||||
return loads(serialize('json', obj, fields=('id', 'name')))
|
||||
return JSONEncoder.default(self,obj)
|
||||
|
||||
# partial function, we can now use dumps(my_dict) instead
|
||||
# of dumps(my_dict, cls=DjangoJSONEncoder)
|
||||
dumps = curry(dumps, cls=DjangoJSONEncoder)
|
||||
20
spa/ajax.py
20
spa/ajax.py
@@ -1,22 +1,22 @@
|
||||
import uuid
|
||||
from django.conf.urls import url
|
||||
from django.contrib.auth.decorators import login_required
|
||||
from django.core import serializers
|
||||
from django.http import HttpResponse
|
||||
from annoying.decorators import render_to
|
||||
from django.shortcuts import render_to_response
|
||||
import json
|
||||
from django.utils import simplejson
|
||||
from django.views.decorators.csrf import csrf_exempt
|
||||
import os
|
||||
from core.utils import live
|
||||
from dss import localsettings, settings
|
||||
from spa.models import UserProfile, MixFavourite
|
||||
from spa.models import UserProfile, MixFavourite, Release, Label
|
||||
from spa.models.Mix import Mix
|
||||
from spa.models.Comment import Comment
|
||||
from spa.models.MixLike import MixLike
|
||||
from core.tasks import create_waveform_task
|
||||
import logging
|
||||
|
||||
from core.serialisers.json import dumps
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
class AjaxHandler(object):
|
||||
@@ -43,6 +43,7 @@ class AjaxHandler(object):
|
||||
url(r'^upload_image/(?P<mix_id>\d+)/$', 'spa.ajax.upload_image', name='ajax_upload_image'),
|
||||
url(r'^upload_avatar_image/$', 'spa.ajax.upload_avatar_image', name='ajax_upload_avatar_image'),
|
||||
url(r'^upload_mix_file_handler/$', 'spa.ajax.upload_mix_file_handler', name='ajax_upload_mix_file_handler'),
|
||||
url(r'^lookup/$', 'spa.ajax.lookup', name='ajax_lookup'),
|
||||
]
|
||||
return pattern_list
|
||||
|
||||
@@ -211,8 +212,17 @@ def upload_mix_file_handler(request):
|
||||
except Exception, ex:
|
||||
logger.exception("Error starting waveform generation task: %s" % ex.message)
|
||||
|
||||
return HttpResponse(_get_json("Success"))
|
||||
return HttpResponse(_get_json("Success"), mimetype='application/json')
|
||||
except Exception, ex:
|
||||
logger.exception("Error uploading mix")
|
||||
|
||||
return HttpResponse(_get_json("Failed"))
|
||||
return HttpResponse(_get_json("Failed"), mimetype='application/json')
|
||||
|
||||
@csrf_exempt
|
||||
def lookup(request):
|
||||
if 'query' in request.GET:
|
||||
release = Label.objects.all() #filter(name__startswith = request.GET['query'])
|
||||
json = dumps(release)
|
||||
return HttpResponse(json, mimetype='application/json')
|
||||
|
||||
return HttpResponse(_get_json("Key failure in lookup"), mimetype='application/json')
|
||||
|
||||
@@ -4,10 +4,11 @@ from tastypie import fields
|
||||
from tastypie.authorization import Authorization
|
||||
from tastypie.constants import ALL_WITH_RELATIONS
|
||||
from spa.api.v1.BackboneCompatibleResource import BackboneCompatibleResource
|
||||
from spa.models import Label
|
||||
from spa.models.Release import Release
|
||||
|
||||
from django.core.exceptions import ObjectDoesNotExist
|
||||
class ReleaseResource(BackboneCompatibleResource):
|
||||
release_audio = fields.ToManyField('spa.api.v1.ReleaseAudioResource.ReleaseAudioResource', 'release_audio', 'release')
|
||||
release_audio = fields.ToManyField('spa.api.v1.ReleaseAudioResource.ReleaseAudioResource', 'release_audio', 'release', null=True, blank=True)
|
||||
class Meta:
|
||||
queryset = Release.objects.all()
|
||||
filtering = {
|
||||
@@ -15,6 +16,23 @@ class ReleaseResource(BackboneCompatibleResource):
|
||||
}
|
||||
authorization = Authorization()
|
||||
|
||||
def obj_create(self, bundle, request=None, **kwargs):
|
||||
bundle.data['user'] = {'pk': request.user.pk}
|
||||
return super(ReleaseResource, self).obj_create(bundle, request, user=request.user.get_profile())
|
||||
|
||||
def hydrate(self, bundle):
|
||||
if 'release_label' in bundle.data:
|
||||
try:
|
||||
label = Label.objects.get(name__exact=bundle.data['release_label'])
|
||||
if label is not None:
|
||||
bundle.obj.release_label = label
|
||||
else:
|
||||
bundle.obj.release_label = Label(name=bundle.data['release_label'])
|
||||
except ObjectDoesNotExist:
|
||||
bundle.obj.release_label = Label(name=bundle.data['release_label'])
|
||||
|
||||
return bundle
|
||||
|
||||
def dehydrate(self, bundle):
|
||||
bundle.data['label'] = bundle.obj.release_label.name
|
||||
bundle.data['item_url'] = 'release/%s' % bundle.obj.id
|
||||
|
||||
@@ -54,5 +54,5 @@ class ReleaseAudio(_BaseModel):
|
||||
return settings.MEDIA_URL + 'waveforms/release/%d.%s' % (self.id, "png")
|
||||
|
||||
local_file = models.FileField(upload_to=release_file_name)
|
||||
release = models.ForeignKey(Release, related_name='release_audio')
|
||||
release = models.ForeignKey(Release, related_name='release_audio', null=True, blank=True)
|
||||
description = models.TextField()
|
||||
@@ -1,8 +1,12 @@
|
||||
import logging
|
||||
from django.db import models
|
||||
from django.utils import simplejson
|
||||
|
||||
class _BaseModel(models.Model):
|
||||
logger = logging.getLogger(__name__)
|
||||
class Meta:
|
||||
abstract = True
|
||||
app_label = 'spa'
|
||||
app_label = 'spa'
|
||||
|
||||
def tosimplejson(self):
|
||||
ret = simplejson.dump(self)
|
||||
|
||||
156
static/css/bootstrap/bootstrap-datepicker.css
vendored
Normal file
156
static/css/bootstrap/bootstrap-datepicker.css
vendored
Normal file
@@ -0,0 +1,156 @@
|
||||
/*!
|
||||
* Datepicker for Bootstrap
|
||||
*
|
||||
* Copyright 2012 Stefan Petre
|
||||
* Licensed under the Apache License v2.0
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
*/
|
||||
.datepicker {
|
||||
top: 0;
|
||||
left: 0;
|
||||
padding: 4px;
|
||||
margin-top: 1px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
/*.dow {
|
||||
border-top: 1px solid #ddd !important;
|
||||
}*/
|
||||
}
|
||||
.datepicker:before {
|
||||
content: '';
|
||||
display: inline-block;
|
||||
border-left: 7px solid transparent;
|
||||
border-right: 7px solid transparent;
|
||||
border-bottom: 7px solid #ccc;
|
||||
border-bottom-color: rgba(0, 0, 0, 0.2);
|
||||
position: absolute;
|
||||
top: -7px;
|
||||
left: 6px;
|
||||
}
|
||||
.datepicker:after {
|
||||
content: '';
|
||||
display: inline-block;
|
||||
border-left: 6px solid transparent;
|
||||
border-right: 6px solid transparent;
|
||||
border-bottom: 6px solid #ffffff;
|
||||
position: absolute;
|
||||
top: -6px;
|
||||
left: 7px;
|
||||
}
|
||||
.datepicker > div {
|
||||
display: none;
|
||||
}
|
||||
.datepicker table {
|
||||
width: 100%;
|
||||
margin: 0;
|
||||
}
|
||||
.datepicker td, .datepicker th {
|
||||
text-align: center;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.datepicker td.day:hover {
|
||||
background: #eeeeee;
|
||||
cursor: pointer;
|
||||
}
|
||||
.datepicker td.old, .datepicker td.new {
|
||||
color: #999999;
|
||||
}
|
||||
.datepicker td.active, .datepicker td.active:hover {
|
||||
background-color: #006dcc;
|
||||
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
|
||||
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: linear-gradient(top, #0088cc, #0044cc);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
|
||||
border-color: #0044cc #0044cc #002a80;
|
||||
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
color: #fff;
|
||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
.datepicker td.active:hover,
|
||||
.datepicker td.active:hover:hover,
|
||||
.datepicker td.active:active,
|
||||
.datepicker td.active:hover:active,
|
||||
.datepicker td.active.active,
|
||||
.datepicker td.active:hover.active,
|
||||
.datepicker td.active.disabled,
|
||||
.datepicker td.active:hover.disabled,
|
||||
.datepicker td.active[disabled],
|
||||
.datepicker td.active:hover[disabled] {
|
||||
background-color: #0044cc;
|
||||
}
|
||||
.datepicker td.active:active,
|
||||
.datepicker td.active:hover:active,
|
||||
.datepicker td.active.active,
|
||||
.datepicker td.active:hover.active {
|
||||
background-color: #003399 \9;
|
||||
}
|
||||
.datepicker td span {
|
||||
display: block;
|
||||
width: 47px;
|
||||
height: 54px;
|
||||
line-height: 54px;
|
||||
float: left;
|
||||
margin: 2px;
|
||||
cursor: pointer;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.datepicker td span:hover {
|
||||
background: #eeeeee;
|
||||
}
|
||||
.datepicker td span.active {
|
||||
background-color: #006dcc;
|
||||
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
|
||||
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
|
||||
background-image: linear-gradient(top, #0088cc, #0044cc);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
|
||||
border-color: #0044cc #0044cc #002a80;
|
||||
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
color: #fff;
|
||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
.datepicker td span.active:hover,
|
||||
.datepicker td span.active:active,
|
||||
.datepicker td span.active.active,
|
||||
.datepicker td span.active.disabled,
|
||||
.datepicker td span.active[disabled] {
|
||||
background-color: #0044cc;
|
||||
}
|
||||
.datepicker td span.active:active, .datepicker td span.active.active {
|
||||
background-color: #003399 \9;
|
||||
}
|
||||
.datepicker td span.old {
|
||||
color: #999999;
|
||||
}
|
||||
.datepicker th.switch {
|
||||
width: 145px;
|
||||
}
|
||||
.datepicker thead tr:first-child th {
|
||||
cursor: pointer;
|
||||
}
|
||||
.datepicker thead tr:first-child th:hover {
|
||||
background: #eeeeee;
|
||||
}
|
||||
.input-append.date .add-on i, .input-prepend.date .add-on i {
|
||||
display: block;
|
||||
cursor: pointer;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
@@ -465,4 +465,9 @@ input[type=submit] {
|
||||
color: #111;
|
||||
border: 1px solid #666;
|
||||
background: #888;
|
||||
}
|
||||
.boxsizingBorder {
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
@@ -5,6 +5,7 @@ var AppRouter = Backbone.Router.extend({
|
||||
"/mix/upload":"mixUpload",
|
||||
"/mix/:id":"mixDetails",
|
||||
"/releases":"releaseList",
|
||||
"/release/add":"releaseAdd",
|
||||
"/release/:id":"releaseDetails",
|
||||
"/events":"eventList",
|
||||
"/event/:id":"eventDetails",
|
||||
@@ -92,6 +93,11 @@ var AppRouter = Backbone.Router.extend({
|
||||
}});
|
||||
}});
|
||||
},
|
||||
releaseAdd: function(){
|
||||
var html = new ReleaseCreateView({model: new Release({ release_date : getDateAsToday() })});
|
||||
$('#content').html(html.el);
|
||||
$('#site-content-fill').html('');
|
||||
},
|
||||
eventList:function (page) {
|
||||
var eventList = new EventCollection();
|
||||
eventList.fetch({
|
||||
@@ -137,7 +143,7 @@ utils.loadTemplate([
|
||||
'HeaderView', 'SidebarView', 'UserView',
|
||||
'MixListView', 'MixListItemView', 'MixView', 'MixCreateView',
|
||||
'CommentListView', 'CommentListItemView',
|
||||
'ReleaseListView', 'ReleaseListItemView', 'ReleaseItemView', 'ReleaseView', 'ReleaseAudioListView', 'ReleaseAudioItemView',
|
||||
'ReleaseListView', 'ReleaseListItemView', 'ReleaseItemView', 'ReleaseView', 'ReleaseCreateView', 'ReleaseAudioListView', 'ReleaseAudioItemView',
|
||||
'EventListView', 'EventListItemView', 'EventView', 'EventItemView'
|
||||
], function () {
|
||||
window.app = new AppRouter();
|
||||
|
||||
@@ -11,8 +11,8 @@ var ReleaseListItemView = Backbone.View.extend({
|
||||
}
|
||||
});
|
||||
var ReleaseListView = Backbone.View.extend({
|
||||
events: {
|
||||
"click tr" : "showDetails"
|
||||
events:{
|
||||
"click tr":"showDetails"
|
||||
},
|
||||
initialize:function () {
|
||||
this.render();
|
||||
@@ -24,13 +24,16 @@ var ReleaseListView = Backbone.View.extend({
|
||||
$('#release-list-container', el).append(new ReleaseListItemView({model:item}).render().el);
|
||||
});
|
||||
$("#release-table", this.el).tablesorter({
|
||||
sortList: [[0,0],[1,0]]
|
||||
sortList:[
|
||||
[0, 0],
|
||||
[1, 0]
|
||||
]
|
||||
});
|
||||
$('tr.rowlink', this.el).rowlink();
|
||||
|
||||
return this;
|
||||
},
|
||||
showDetails: function(row){
|
||||
showDetails:function (row) {
|
||||
window.app.navigate('#/release/' + $(row.currentTarget).data("id"), true);
|
||||
}
|
||||
});
|
||||
@@ -55,4 +58,92 @@ var ReleaseView = Backbone.View.extend({
|
||||
$('#release-description', this.el).html(this.model.get("description"));
|
||||
return this;
|
||||
}
|
||||
});
|
||||
var ReleaseCreateView = Backbone.View.extend({
|
||||
events:{
|
||||
"click #save-changes":"saveChanges",
|
||||
"change input":"changed",
|
||||
"change textarea":"changed"
|
||||
},
|
||||
initialize:function () {
|
||||
this.render();
|
||||
},
|
||||
render:function () {
|
||||
$(this.el).html(this.template({"item":this.model.toJSON()}));
|
||||
var el = this.el;
|
||||
var model = this.model;
|
||||
console.clear();
|
||||
var labels, mapped;
|
||||
$('.typeahead', this.el).typeahead({
|
||||
source:function (query, process) {
|
||||
$.get(
|
||||
'/ajax/lookup/',
|
||||
{ query:query },
|
||||
function (data) {
|
||||
labels = []
|
||||
mapped = {}
|
||||
$.each(data, function (i, item) {
|
||||
mapped[item.fields.name] = item;
|
||||
labels.push(item.fields.name);
|
||||
});
|
||||
process(labels);
|
||||
}, 'json');
|
||||
},
|
||||
updater: function(item){
|
||||
$('#release_label_id', el).val(mapped[item].pk);
|
||||
model.set('release_label_id', mapped[item].pk);
|
||||
return item;
|
||||
}
|
||||
});
|
||||
$('.datepicker', this.el).datepicker(
|
||||
{
|
||||
'format' : 'dd/mm/yyyy'
|
||||
}
|
||||
);
|
||||
$('textarea.tinymce', this.el).tinymce({
|
||||
script_url: "/static/js/libs/tiny_mce/tiny_mce.js",
|
||||
mode:"textareas",
|
||||
theme:"advanced",
|
||||
theme_advanced_toolbar_location:"top",
|
||||
theme_advanced_toolbar_align:"left",
|
||||
theme_advanced_buttons1:"fullscreen,separator,preview,separator,bold,italic,underline,strikethrough,separator,bullist,numlist,outdent,indent,separator,undo,redo,separator,link,unlink,anchor,separator,image,cleanup,help,separator,code",
|
||||
theme_advanced_buttons2:"",
|
||||
theme_advanced_buttons3:"",
|
||||
auto_cleanup_word:true,
|
||||
plugins:"table,save,advhr,advimage,advlink,emotions,iespell,insertdatetime,print,contextmenu,fullscreen,preview,searchreplace",
|
||||
plugin_insertdate_dateFormat:"%m/%d/%Y",
|
||||
plugin_insertdate_timeFormat:"%H:%M:%S",
|
||||
extended_valid_elements:"a[name|href|target=_blank|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
|
||||
fullscreen_settings:{
|
||||
theme_advanced_path_location:"top",
|
||||
theme_advanced_buttons1:"fullscreen,separator,preview,separator,cut,copy,paste,separator,undo,redo,separator,search,replace,separator,code,separator,cleanup,separator,bold,italic,underline,strikethrough,separator,forecolor,backcolor,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,help",
|
||||
theme_advanced_buttons2:"removeformat,styleselect,formatselect,fontselect,fontsizeselect,separator,bullist,numlist,outdent,indent,separator,link,unlink,anchor",
|
||||
theme_advanced_buttons3:"sub,sup,separator,image,insertdate,inserttime,separator,tablecontrols,separator,hr,advhr,visualaid,separator,charmap,emotions,iespell,flash,separator,print"
|
||||
}
|
||||
});
|
||||
},
|
||||
saveChanges:function () {
|
||||
var model = this.model;
|
||||
var el = this.el;
|
||||
var parent = this;
|
||||
this.model.set('release_description', $('#release-description', this.el).html());
|
||||
this.model.save(
|
||||
null, {
|
||||
success:function () {
|
||||
window.utils.showAlert("Success", "Release succesfully added", "alert-info", true);
|
||||
app.navigate('#/release/' + model.get('id'));
|
||||
},
|
||||
error:function () {
|
||||
alert("Error saving release");
|
||||
}
|
||||
});
|
||||
return false;
|
||||
},
|
||||
changed:function (evt) {
|
||||
var changed = evt.currentTarget;
|
||||
var value = $("#" + changed.id).val();
|
||||
var obj = "{\"" + changed.id + "\":\"" + value + "\"}";
|
||||
var objInst = JSON.parse(obj);
|
||||
this.model.set(objInst);
|
||||
}
|
||||
});
|
||||
401
static/js/libs/bootstrap/bootstrap-datepicker.js
vendored
Normal file
401
static/js/libs/bootstrap/bootstrap-datepicker.js
vendored
Normal file
@@ -0,0 +1,401 @@
|
||||
/* =========================================================
|
||||
* bootstrap-datepicker.js
|
||||
* http://www.eyecon.ro/bootstrap-datepicker
|
||||
* =========================================================
|
||||
* Copyright 2012 Stefan Petre
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
* ========================================================= */
|
||||
|
||||
!function( $ ) {
|
||||
|
||||
// Picker object
|
||||
|
||||
var Datepicker = function(element, options){
|
||||
this.element = $(element);
|
||||
this.format = DPGlobal.parseFormat(options.format||this.element.data('date-format')||'mm/dd/yyyy');
|
||||
this.picker = $(DPGlobal.template)
|
||||
.appendTo('body')
|
||||
.on({
|
||||
click: $.proxy(this.click, this),
|
||||
mousedown: $.proxy(this.mousedown, this)
|
||||
});
|
||||
this.isInput = this.element.is('input');
|
||||
this.component = this.element.is('.date') ? this.element.find('.add-on') : false;
|
||||
|
||||
if (this.isInput) {
|
||||
this.element.on({
|
||||
focus: $.proxy(this.show, this),
|
||||
blur: $.proxy(this.hide, this),
|
||||
keyup: $.proxy(this.update, this)
|
||||
});
|
||||
} else {
|
||||
if (this.component){
|
||||
this.component.on('click', $.proxy(this.show, this));
|
||||
} else {
|
||||
this.element.on('click', $.proxy(this.show, this));
|
||||
}
|
||||
}
|
||||
|
||||
this.viewMode = 0;
|
||||
this.weekStart = options.weekStart||this.element.data('date-weekstart')||0;
|
||||
this.weekEnd = this.weekStart == 0 ? 6 : this.weekStart - 1;
|
||||
this.fillDow();
|
||||
this.fillMonths();
|
||||
this.update();
|
||||
this.showMode();
|
||||
};
|
||||
|
||||
Datepicker.prototype = {
|
||||
constructor: Datepicker,
|
||||
|
||||
show: function(e) {
|
||||
this.picker.show();
|
||||
this.height = this.component ? this.component.outerHeight() : this.element.outerHeight();
|
||||
this.place();
|
||||
$(window).on('resize', $.proxy(this.place, this));
|
||||
if (e ) {
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
}
|
||||
if (!this.isInput) {
|
||||
$(document).on('mousedown', $.proxy(this.hide, this));
|
||||
}
|
||||
this.element.trigger({
|
||||
type: 'show',
|
||||
date: this.date
|
||||
});
|
||||
},
|
||||
|
||||
hide: function(){
|
||||
this.picker.hide();
|
||||
$(window).off('resize', this.place);
|
||||
this.viewMode = 0;
|
||||
this.showMode();
|
||||
if (!this.isInput) {
|
||||
$(document).off('mousedown', this.hide);
|
||||
}
|
||||
this.setValue();
|
||||
this.element.trigger({
|
||||
type: 'hide',
|
||||
date: this.date
|
||||
});
|
||||
},
|
||||
|
||||
setValue: function() {
|
||||
var formated = DPGlobal.formatDate(this.date, this.format);
|
||||
if (!this.isInput) {
|
||||
if (this.component){
|
||||
this.element.find('input').prop('value', formated);
|
||||
}
|
||||
this.element.data('date', formated);
|
||||
} else {
|
||||
this.element.prop('value', formated);
|
||||
}
|
||||
},
|
||||
|
||||
place: function(){
|
||||
var offset = this.component ? this.component.offset() : this.element.offset();
|
||||
this.picker.css({
|
||||
top: offset.top + this.height,
|
||||
left: offset.left
|
||||
});
|
||||
},
|
||||
|
||||
update: function(){
|
||||
this.date = DPGlobal.parseDate(
|
||||
this.isInput ? this.element.prop('value') : this.element.data('date'),
|
||||
this.format
|
||||
);
|
||||
this.viewDate = new Date(this.date);
|
||||
this.fill();
|
||||
},
|
||||
|
||||
fillDow: function(){
|
||||
var dowCnt = this.weekStart;
|
||||
var html = '<tr>';
|
||||
while (dowCnt < this.weekStart + 7) {
|
||||
html += '<th class="dow">'+DPGlobal.dates.daysMin[(dowCnt++)%7]+'</th>';
|
||||
}
|
||||
html += '</tr>';
|
||||
this.picker.find('.datepicker-days thead').append(html);
|
||||
},
|
||||
|
||||
fillMonths: function(){
|
||||
var html = '';
|
||||
var i = 0
|
||||
while (i < 12) {
|
||||
html += '<span class="month">'+DPGlobal.dates.monthsShort[i++]+'</span>';
|
||||
}
|
||||
this.picker.find('.datepicker-months td').append(html);
|
||||
},
|
||||
|
||||
fill: function() {
|
||||
var d = new Date(this.viewDate),
|
||||
year = d.getFullYear(),
|
||||
month = d.getMonth(),
|
||||
currentDate = this.date.valueOf();
|
||||
this.picker.find('.datepicker-days th:eq(1)')
|
||||
.text(DPGlobal.dates.months[month]+' '+year);
|
||||
var prevMonth = new Date(year, month-1, 28,0,0,0,0),
|
||||
day = DPGlobal.getDaysInMonth(prevMonth.getFullYear(), prevMonth.getMonth());
|
||||
prevMonth.setDate(day);
|
||||
prevMonth.setDate(day - (prevMonth.getDay() - this.weekStart + 7)%7);
|
||||
var nextMonth = new Date(prevMonth);
|
||||
nextMonth.setDate(nextMonth.getDate() + 42);
|
||||
nextMonth = nextMonth.valueOf();
|
||||
html = [];
|
||||
var clsName;
|
||||
while(prevMonth.valueOf() < nextMonth) {
|
||||
if (prevMonth.getDay() == this.weekStart) {
|
||||
html.push('<tr>');
|
||||
}
|
||||
clsName = '';
|
||||
if (prevMonth.getMonth() < month) {
|
||||
clsName += ' old';
|
||||
} else if (prevMonth.getMonth() > month) {
|
||||
clsName += ' new';
|
||||
}
|
||||
if (prevMonth.valueOf() == currentDate) {
|
||||
clsName += ' active';
|
||||
}
|
||||
html.push('<td class="day'+clsName+'">'+prevMonth.getDate() + '</td>');
|
||||
if (prevMonth.getDay() == this.weekEnd) {
|
||||
html.push('</tr>');
|
||||
}
|
||||
prevMonth.setDate(prevMonth.getDate()+1);
|
||||
}
|
||||
this.picker.find('.datepicker-days tbody').empty().append(html.join(''));
|
||||
var currentYear = this.date.getFullYear();
|
||||
|
||||
var months = this.picker.find('.datepicker-months')
|
||||
.find('th:eq(1)')
|
||||
.text(year)
|
||||
.end()
|
||||
.find('span').removeClass('active');
|
||||
if (currentYear == year) {
|
||||
months.eq(this.date.getMonth()).addClass('active');
|
||||
}
|
||||
|
||||
html = '';
|
||||
year = parseInt(year/10, 10) * 10;
|
||||
var yearCont = this.picker.find('.datepicker-years')
|
||||
.find('th:eq(1)')
|
||||
.text(year + '-' + (year + 9))
|
||||
.end()
|
||||
.find('td');
|
||||
year -= 1;
|
||||
for (var i = -1; i < 11; i++) {
|
||||
html += '<span class="year'+(i == -1 || i == 10 ? ' old' : '')+(currentYear == year ? ' active' : '')+'">'+year+'</span>';
|
||||
year += 1;
|
||||
}
|
||||
yearCont.html(html);
|
||||
},
|
||||
|
||||
click: function(e) {
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
var target = $(e.target).closest('span, td, th');
|
||||
if (target.length == 1) {
|
||||
switch(target[0].nodeName.toLowerCase()) {
|
||||
case 'th':
|
||||
switch(target[0].className) {
|
||||
case 'switch':
|
||||
this.showMode(1);
|
||||
break;
|
||||
case 'prev':
|
||||
case 'next':
|
||||
this.viewDate['set'+DPGlobal.modes[this.viewMode].navFnc].call(
|
||||
this.viewDate,
|
||||
this.viewDate['get'+DPGlobal.modes[this.viewMode].navFnc].call(this.viewDate) +
|
||||
DPGlobal.modes[this.viewMode].navStep * (target[0].className == 'prev' ? -1 : 1)
|
||||
);
|
||||
this.fill();
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case 'span':
|
||||
if (target.is('.month')) {
|
||||
var month = target.parent().find('span').index(target);
|
||||
this.viewDate.setMonth(month);
|
||||
} else {
|
||||
var year = parseInt(target.text(), 10)||0;
|
||||
this.viewDate.setFullYear(year);
|
||||
}
|
||||
this.showMode(-1);
|
||||
this.fill();
|
||||
break;
|
||||
case 'td':
|
||||
if (target.is('.day')){
|
||||
var day = parseInt(target.text(), 10)||1;
|
||||
var month = this.viewDate.getMonth();
|
||||
if (target.is('.old')) {
|
||||
month -= 1;
|
||||
} else if (target.is('.new')) {
|
||||
month += 1;
|
||||
}
|
||||
var year = this.viewDate.getFullYear();
|
||||
this.date = new Date(year, month, day,0,0,0,0);
|
||||
this.viewDate = new Date(year, month, day,0,0,0,0);
|
||||
this.fill();
|
||||
this.setValue();
|
||||
this.element.trigger({
|
||||
type: 'changeDate',
|
||||
date: this.date
|
||||
});
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
mousedown: function(e){
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
},
|
||||
|
||||
showMode: function(dir) {
|
||||
if (dir) {
|
||||
this.viewMode = Math.max(0, Math.min(2, this.viewMode + dir));
|
||||
}
|
||||
this.picker.find('>div').hide().filter('.datepicker-'+DPGlobal.modes[this.viewMode].clsName).show();
|
||||
}
|
||||
};
|
||||
|
||||
$.fn.datepicker = function ( option ) {
|
||||
return this.each(function () {
|
||||
var $this = $(this),
|
||||
data = $this.data('datepicker'),
|
||||
options = typeof option == 'object' && option;
|
||||
if (!data) {
|
||||
$this.data('datepicker', (data = new Datepicker(this, $.extend({}, $.fn.datepicker.defaults,options))));
|
||||
}
|
||||
if (typeof option == 'string') data[option]();
|
||||
});
|
||||
};
|
||||
|
||||
$.fn.datepicker.defaults = {
|
||||
};
|
||||
$.fn.datepicker.Constructor = Datepicker;
|
||||
|
||||
var DPGlobal = {
|
||||
modes: [
|
||||
{
|
||||
clsName: 'days',
|
||||
navFnc: 'Month',
|
||||
navStep: 1
|
||||
},
|
||||
{
|
||||
clsName: 'months',
|
||||
navFnc: 'FullYear',
|
||||
navStep: 1
|
||||
},
|
||||
{
|
||||
clsName: 'years',
|
||||
navFnc: 'FullYear',
|
||||
navStep: 10
|
||||
}],
|
||||
dates:{
|
||||
days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"],
|
||||
daysShort: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"],
|
||||
daysMin: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"],
|
||||
months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
|
||||
monthsShort: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
|
||||
},
|
||||
isLeapYear: function (year) {
|
||||
return (((year % 4 === 0) && (year % 100 !== 0)) || (year % 400 === 0))
|
||||
},
|
||||
getDaysInMonth: function (year, month) {
|
||||
return [31, (DPGlobal.isLeapYear(year) ? 29 : 28), 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month]
|
||||
},
|
||||
parseFormat: function(format){
|
||||
var separator = format.match(/[.\/-].*?/),
|
||||
parts = format.split(/\W+/);
|
||||
if (!separator || !parts || parts.length == 0){
|
||||
throw new Error("Invalid date format.");
|
||||
}
|
||||
return {separator: separator, parts: parts};
|
||||
},
|
||||
parseDate: function(date, format) {
|
||||
var parts = date.split(format.separator),
|
||||
date = new Date(1970, 1, 1, 0, 0, 0),
|
||||
val;
|
||||
if (parts.length == format.parts.length) {
|
||||
for (var i=0, cnt = format.parts.length; i < cnt; i++) {
|
||||
val = parseInt(parts[i], 10)||1;
|
||||
switch(format.parts[i]) {
|
||||
case 'dd':
|
||||
case 'd':
|
||||
date.setDate(val);
|
||||
break;
|
||||
case 'mm':
|
||||
case 'm':
|
||||
date.setMonth(val - 1);
|
||||
break;
|
||||
case 'yy':
|
||||
date.setFullYear(2000 + val);
|
||||
break;
|
||||
case 'yyyy':
|
||||
date.setFullYear(val);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return date;
|
||||
},
|
||||
formatDate: function(date, format){
|
||||
var val = {
|
||||
d: date.getDate(),
|
||||
m: date.getMonth() + 1,
|
||||
yy: date.getFullYear().toString().substring(2),
|
||||
yyyy: date.getFullYear()
|
||||
};
|
||||
val.dd = (val.d < 10 ? '0' : '') + val.d;
|
||||
val.mm = (val.m < 10 ? '0' : '') + val.m;
|
||||
var date = [];
|
||||
for (var i=0, cnt = format.parts.length; i < cnt; i++) {
|
||||
date.push(val[format.parts[i]]);
|
||||
}
|
||||
return date.join(format.separator);
|
||||
},
|
||||
headTemplate: '<thead>'+
|
||||
'<tr>'+
|
||||
'<th class="prev"><i class="icon-arrow-left"/></th>'+
|
||||
'<th colspan="5" class="switch"></th>'+
|
||||
'<th class="next"><i class="icon-arrow-right"/></th>'+
|
||||
'</tr>'+
|
||||
'</thead>',
|
||||
contTemplate: '<tbody><tr><td colspan="7"></td></tr></tbody>'
|
||||
};
|
||||
DPGlobal.template = '<div class="datepicker dropdown-menu">'+
|
||||
'<div class="datepicker-days">'+
|
||||
'<table class=" table-condensed">'+
|
||||
DPGlobal.headTemplate+
|
||||
'<tbody></tbody>'+
|
||||
'</table>'+
|
||||
'</div>'+
|
||||
'<div class="datepicker-months">'+
|
||||
'<table class="table-condensed">'+
|
||||
DPGlobal.headTemplate+
|
||||
DPGlobal.contTemplate+
|
||||
'</table>'+
|
||||
'</div>'+
|
||||
'<div class="datepicker-years">'+
|
||||
'<table class="table-condensed">'+
|
||||
DPGlobal.headTemplate+
|
||||
DPGlobal.contTemplate+
|
||||
'</table>'+
|
||||
'</div>'+
|
||||
'</div>';
|
||||
|
||||
}( window.jQuery )
|
||||
1
static/js/libs/tiny_mce/langs/ar.js
vendored
1
static/js/libs/tiny_mce/langs/ar.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/az.js
vendored
1
static/js/libs/tiny_mce/langs/az.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/be.js
vendored
1
static/js/libs/tiny_mce/langs/be.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/bg.js
vendored
1
static/js/libs/tiny_mce/langs/bg.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/bn.js
vendored
1
static/js/libs/tiny_mce/langs/bn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/br.js
vendored
1
static/js/libs/tiny_mce/langs/br.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/bs.js
vendored
1
static/js/libs/tiny_mce/langs/bs.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/cn.js
vendored
1
static/js/libs/tiny_mce/langs/cn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/cs.js
vendored
1
static/js/libs/tiny_mce/langs/cs.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/cy.js
vendored
1
static/js/libs/tiny_mce/langs/cy.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/da.js
vendored
1
static/js/libs/tiny_mce/langs/da.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/de.js
vendored
1
static/js/libs/tiny_mce/langs/de.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/dv.js
vendored
1
static/js/libs/tiny_mce/langs/dv.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/el.js
vendored
1
static/js/libs/tiny_mce/langs/el.js
vendored
File diff suppressed because one or more lines are too long
2
static/js/libs/tiny_mce/langs/en.js
vendored
2
static/js/libs/tiny_mce/langs/en.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/eo.js
vendored
1
static/js/libs/tiny_mce/langs/eo.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/es.js
vendored
1
static/js/libs/tiny_mce/langs/es.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/et.js
vendored
1
static/js/libs/tiny_mce/langs/et.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/eu.js
vendored
1
static/js/libs/tiny_mce/langs/eu.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/fr.js
vendored
1
static/js/libs/tiny_mce/langs/fr.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/gu.js
vendored
1
static/js/libs/tiny_mce/langs/gu.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/he.js
vendored
1
static/js/libs/tiny_mce/langs/he.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/hr.js
vendored
1
static/js/libs/tiny_mce/langs/hr.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/hu.js
vendored
1
static/js/libs/tiny_mce/langs/hu.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/hy.js
vendored
1
static/js/libs/tiny_mce/langs/hy.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/id.js
vendored
1
static/js/libs/tiny_mce/langs/id.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/it.js
vendored
1
static/js/libs/tiny_mce/langs/it.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ja.js
vendored
1
static/js/libs/tiny_mce/langs/ja.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ka.js
vendored
1
static/js/libs/tiny_mce/langs/ka.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/kl.js
vendored
1
static/js/libs/tiny_mce/langs/kl.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ko.js
vendored
1
static/js/libs/tiny_mce/langs/ko.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/lb.js
vendored
1
static/js/libs/tiny_mce/langs/lb.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/lt.js
vendored
1
static/js/libs/tiny_mce/langs/lt.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/lv.js
vendored
1
static/js/libs/tiny_mce/langs/lv.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/mk.js
vendored
1
static/js/libs/tiny_mce/langs/mk.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ml.js
vendored
1
static/js/libs/tiny_mce/langs/ml.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/mn.js
vendored
1
static/js/libs/tiny_mce/langs/mn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ms.js
vendored
1
static/js/libs/tiny_mce/langs/ms.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/my.js
vendored
1
static/js/libs/tiny_mce/langs/my.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/nb.js
vendored
1
static/js/libs/tiny_mce/langs/nb.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/nl.js
vendored
1
static/js/libs/tiny_mce/langs/nl.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/nn.js
vendored
1
static/js/libs/tiny_mce/langs/nn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/no.js
vendored
1
static/js/libs/tiny_mce/langs/no.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ps.js
vendored
1
static/js/libs/tiny_mce/langs/ps.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/pt.js
vendored
1
static/js/libs/tiny_mce/langs/pt.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ro.js
vendored
1
static/js/libs/tiny_mce/langs/ro.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/sc.js
vendored
1
static/js/libs/tiny_mce/langs/sc.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/se.js
vendored
1
static/js/libs/tiny_mce/langs/se.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/sl.js
vendored
1
static/js/libs/tiny_mce/langs/sl.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/sq.js
vendored
1
static/js/libs/tiny_mce/langs/sq.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/sr.js
vendored
1
static/js/libs/tiny_mce/langs/sr.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/sv.js
vendored
1
static/js/libs/tiny_mce/langs/sv.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ta.js
vendored
1
static/js/libs/tiny_mce/langs/ta.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/te.js
vendored
1
static/js/libs/tiny_mce/langs/te.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/th.js
vendored
1
static/js/libs/tiny_mce/langs/th.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/tn.js
vendored
1
static/js/libs/tiny_mce/langs/tn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/tr.js
vendored
1
static/js/libs/tiny_mce/langs/tr.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/tt.js
vendored
1
static/js/libs/tiny_mce/langs/tt.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/tw.js
vendored
1
static/js/libs/tiny_mce/langs/tw.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/ur.js
vendored
1
static/js/libs/tiny_mce/langs/ur.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/vi.js
vendored
1
static/js/libs/tiny_mce/langs/vi.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/zh-cn.js
vendored
1
static/js/libs/tiny_mce/langs/zh-cn.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/zh-tw.js
vendored
1
static/js/libs/tiny_mce/langs/zh-tw.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/zh.js
vendored
1
static/js/libs/tiny_mce/langs/zh.js
vendored
File diff suppressed because one or more lines are too long
1
static/js/libs/tiny_mce/langs/zu.js
vendored
1
static/js/libs/tiny_mce/langs/zu.js
vendored
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('ar.advhr_dlg',{size:"\u0627\u0644\u0627\u0631\u062a\u0641\u0627\u0639",noshade:"\u0644\u0627 \u0638\u0644",width:"\u0627\u0644\u0639\u0631\u0636",normal:"\u0627\u0644\u0637\u0628\u064a\u0639\u064a",widthunits:"\u0627\u0644\u0648\u062d\u062f\u0627\u062a"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('az.advhr_dlg',{size:"H\u00fcnd\u00fcrl\u00fcy\u00fc",noshade:"K\u00f6lg\u0259 yoxdur",width:"Eni",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('be.advhr_dlg',{size:"\u0412\u044b\u0448\u044b\u043d\u044f",noshade:"\u041d\u044f\u043c\u0430 \u0446\u0435\u043d\u044e",width:"\u0428\u044b\u0440\u044b\u043d\u044f",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('bg.advhr_dlg',{size:"\u0412\u0438\u0441\u043e\u0447\u0438\u043d\u0430",noshade:"\u0411\u0435\u0437 \u0441\u044f\u043d\u043a\u0430",width:"\u0428\u0438\u0440\u0438\u043d\u0430",normal:"\u041d\u043e\u0440\u043c\u0430\u043b\u043d\u0430",widthunits:"\u0415\u0434\u0438\u043d\u0438\u0446\u0438"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('bn.advhr_dlg',{size:"Height",noshade:"No shadow",width:"Width",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('br.advhr_dlg',{size:"Altura",noshade:"Sem sombra",width:"Largura",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('bs.advhr_dlg',{size:"Visina",noshade:"Bez sjene",width:"\u0160irina",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('ch.advhr_dlg',{size:"\u9ad8\u5ea6",noshade:"\u65e0\u9634\u5f71",width:"\u5bbd\u5ea6",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('cn.advhr_dlg',{size:"\u9ad8\u5ea6",noshade:"\u65e0\u9634\u5f71",width:"\u5bbd\u5ea6",normal:"\u5e38\u89c4",widthunits:"\u5355\u4f4d"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('cs.advhr_dlg',{size:"V\u00fd\u0161ka",noshade:"Bez st\u00ednu",width:"\u0160\u00ed\u0159ka",normal:"Norm\u00e1ln\u00ed",widthunits:"Jednotky"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('da.advhr_dlg',{size:"H\u00f8jde",noshade:"Ingen skygge",width:"Bredde",normal:"Normal",widthunits:"Enheder"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('de.advhr_dlg',{size:"H\u00f6he",noshade:"Kein Schatten",width:"Breite",normal:"Normal",widthunits:"Einheiten"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('dv.advhr_dlg',{size:"Height",noshade:"No shadow",width:"Width",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('el.advhr_dlg',{size:"\u038e\u03c8\u03bf\u03c2",noshade:"\u03a7\u03c9\u03c1\u03af\u03c2 \u03c3\u03ba\u03b9\u03ac",width:"\u03a0\u03bb\u03ac\u03c4\u03bf\u03c2",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('eo.advhr_dlg',{size:"Alteco",noshade:"Sen ombro",width:"Lar\u011deco",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('es.advhr_dlg',{size:"Alto",noshade:"Sin sombra",width:"Ancho",normal:"Normal",widthunits:"Unidades"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('et.advhr_dlg',{size:"K\u00f5rgus",noshade:"Ilma varjuta",width:"Laius",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('eu.advhr_dlg',{size:"Altuera",noshade:"Itzalik gabe",width:"Zabalera",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('fa.advhr_dlg',{size:"\u0627\u0631\u062a\u0641\u0627\u0639",noshade:"\u0628\u062f\u0648\u0646 \u0633\u0627\u06cc\u0647",width:"\u067e\u0647\u0646\u0627",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('fi.advhr_dlg',{size:"Korkeus",noshade:"Ei varjoa",width:"Leveys",normal:"Normaali",widthunits:"Yksik\u00f6t"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('he.advhr_dlg',{size:"\u05d2\u05d5\u05d1\u05d4",noshade:"\u05dc\u05dc\u05d0 \u05e6\u05dc",width:"\u05e8\u05d5\u05d7\u05d1",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('hi.advhr_dlg',{size:"Height",noshade:"No shadow",width:"Width",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('hr.advhr_dlg',{size:"Visina",noshade:"Bez sjene",width:"\u0160irina",normal:"Normal",widthunits:"Units"});
|
||||
@@ -1 +0,0 @@
|
||||
tinyMCE.addI18n('hu.advhr_dlg',{size:"Magass\u00e1g",noshade:"\u00c1rny\u00e9k n\u00e9lk\u00fcl",width:"Sz\u00e9less\u00e9g",normal:"Norm\u00e1l",widthunits:"M\u00e9rt\u00e9kegys\u00e9gek"});
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user