Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
wullerot committed Jun 20, 2017
1 parent 618cdb9 commit 032cdd6
Show file tree
Hide file tree
Showing 12 changed files with 30 additions and 28 deletions.

This file was deleted.

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@import "vars";

@import "widgets/filer_file";
Original file line number Diff line number Diff line change
@@ -1,3 +1,14 @@
// Old clean
form .form-row .filer-dropzone .filerFile .filerClearer {
display: inline-block;
padding: 7px !important;
}

form .form-row .filer-dropzone .filerFile .filerClearer svg {
fill: #ff0000;
}


.filer-gui-file-widget {

.preview {
Expand Down Expand Up @@ -46,4 +57,4 @@
height: 100px;
margin: 0 20px 0 0;
}
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,17 @@
&nbsp;<span class="description_text"></span>
{% endif %}

<img class="filerClearer {% if not object %}hidden{% endif %}" src="{% static admin_icon_delete %}"
width="10" height="10" alt="{% trans 'Clear' %}" title="{% trans 'Clear' %}"
data-no-icon-file="{% static 'filer/icons/nofile_48x48.png' %}">
<span class="filerClearer {% if not object %}hidden{% endif %}" title="{% trans 'Clear' %}">{% include 'admin/filer_gui/svg/icon-close.svg' %}</span>

<a href="{{ lookup_url }}" class="js-related-lookup related-lookup {% if object %}related-lookup-change{% endif %} lookup" id="{{ id }}_lookup"
title="{% trans 'Lookup' %}"{% if LTE_DJANGO_1_7 %} onclick="return showRelatedObjectLookupPopup(this);"{% endif %}>
<span class="choose-file"><span class="fa fa-picture-o"></span>{% trans 'Choose File' %}</span>
<span class="edit-file"><span class="fa fa-pencil"></span></span>
<span class="edit-file"><span class="fa fa-search"></span></span>
</a>

<br>

{{ hidden_input }}
{{ rawid_input }}
<script type="text/javascript" id="{{id}}_javascript">
django.jQuery(document).ready(function(){
var plus = django.jQuery('#add_{{ id }}');
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{% extends 'admin/filer_gui/widgets/admin_file_original.html' %}
17 changes: 3 additions & 14 deletions filer_addons/filer_gui/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,30 +8,20 @@
from django.utils.http import urlencode
from django.utils.safestring import mark_safe

from filer import settings as filer_settings
from filer.fields.file import AdminFileWidget
from filer.models import File


logger = logging.getLogger(__name__)


class FilerGuiFileWidget(AdminFileWidget):

template_name = 'admin/filer_gui/widgets/admin_file.html'
template_name = 'admin/filer_gui/widgets/admin_file_original.html'

class Media:
css = {
'all': [
'admin/filer_addons/css/filer_gui.css',
]
}

"""
css = {
'all': [
'filer/css/admin_filer.css',
'admin/filer_addons/css/filer_gui.css',
'admin/filer_gui/css/filer_gui.css',
]
}
js = (
Expand All @@ -40,7 +30,6 @@ class Media:
'filer/js/addons/popup_handling.js',
'filer/js/addons/widget.js',
)
"""

def get_url_params(self):
params = self.url_parameters()
Expand Down Expand Up @@ -83,4 +72,4 @@ def render(self, name, value, attrs=None):


class FilerGuiImageWidget(FilerGuiFileWidget):
template_name = 'admin/filer_gui/widgets/admin_image.html'
template_name = 'admin/filer_gui/widgets/admin_image_original.html'
8 changes: 4 additions & 4 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ var sass_conf = {


gulp.task('sass', function () {
return gulp.src('filer_addons/filer_gui/static/admin/filer_addons/scss/**/*.scss')
return gulp.src('filer_addons/filer_gui/static/admin/filer_gui/scss/**/*.scss')
.pipe(sass(sass_conf).on('error', sass.logError))
.pipe(gulp.dest('filer_addons/filer_gui/static/admin/filer_addons/css'));
.pipe(gulp.dest('filer_addons/filer_gui/static/admin/filer_gui/css'));
});

gulp.task('watch', function () {
gulp.watch('filer_addons/filer_gui/static/admin/filer_addons/scss/**/*.scss', ['sass']);
});
gulp.watch('filer_addons/filer_gui/static/admin/filer_gui/scss/**/*.scss', ['sass']);
});

0 comments on commit 032cdd6

Please sign in to comment.