Skip to content

Conversation

@church29
Copy link
Contributor

Resolves #131

@drkitty
Copy link
Contributor

drkitty commented Mar 5, 2014

The NS spreadsheet view removes the "server" column, shifting the "glue" and "views" columns to the left (which is confusing, because then the column headings don't line up with the columns).

@drkitty
Copy link
Contributor

drkitty commented Mar 5, 2014

The MX spreadsheet view removes the "label" column in an analogous way.

church29 added 3 commits March 5, 2014 14:44
…Update_Confirm

Conflicts:
	vendor/src/bleach
	vendor/src/commonware
	vendor/src/django-appconf
	vendor/src/django-arecibo
	vendor/src/django-compressor
	vendor/src/django-cronjobs
	vendor/src/django-mobility
	vendor/src/django-mozilla-product-details
	vendor/src/django-multidb-router
	vendor/src/django-nose
	vendor/src/django-session-csrf
	vendor/src/django-sha2
	vendor/src/jingo
	vendor/src/jingo-minify
	vendor/src/nuggets
	vendor/src/schematic
	vendor/src/test-utils
	vendor/src/tower
@drkitty
Copy link
Contributor

drkitty commented Mar 6, 2014

In the confirmation box, there's a comma after every element in the list of changes, including the last item. I don't think we need the commas at all. Also, I'd change the first line to "Are you sure you want to make the following changes?" to make it absolutely clear that we're asking a question.

@drkitty
Copy link
Contributor

drkitty commented Mar 6, 2014

I think the "Submit" button is in a non-obvious place, although I can't think of a better place. "Exit spreadsheet mode" doesn't sound as if it'll discard your changes—it sounds more like it'll submit them. How about "Discard changes" instead?

@church29
Copy link
Contributor Author

Needs to be modified after #638

@church29
Copy link
Contributor Author

Can't figure out a clean way to do this without disabling asynchronous ajax.

@church29
Copy link
Contributor Author

This is good to go!

@drkitty
Copy link
Contributor

drkitty commented Jul 8, 2014

  • If you modify a VLAN's number, it complains that the name field is required.
  • If you modify a VLAN's name, it complains that the number field is required.

@drkitty
Copy link
Contributor

drkitty commented Jul 8, 2014

  • In the domain spreadsheet mode, the delegated field's check box always starts out checked, regardless of whether the value of the field is true or false. To set the value to true, you have to uncheck and then re-check the box.

@drkitty
Copy link
Contributor

drkitty commented Jul 8, 2014

Here's a patch that fixes the validation issues I noted, as well as an issue involving the VLAN name field and a bug involving ManyToManyFields.

diff --git a/cyder/base/views.py b/cyder/base/views.py
index 0f5e9a5..ecd02a7 100644
--- a/cyder/base/views.py
+++ b/cyder/base/views.py
@@ -452,6 +452,16 @@ def table_update(request, pk, obj_type=None):
         qd['label'], qd['domain'] = label, str(domain.pk)

     form = FormKlass(qd, instance=obj)
+    # Set the fields that weren't modified
+    for key in form.fields:
+        if key not in qd:
+            old_value = form.initial[key]
+            if isinstance(old_value, list):
+                # ManyToManyFields need special treatment
+                form.data.setlist(key, old_value)
+            else:
+                form.data[key] = old_value
+
     if form.is_valid():
         form.save()
         return HttpResponse()
diff --git a/cyder/cydhcp/vlan/models.py b/cyder/cydhcp/vlan/models.py
index defb55d..fd52110 100644
--- a/cyder/cydhcp/vlan/models.py
+++ b/cyder/cydhcp/vlan/models.py
@@ -48,7 +48,7 @@ class Vlan(BaseModel, ObjectUrlMixin):
         """For tables."""
         data = super(Vlan, self).details()
         data['data'] = [
-            ('Name', 'name', self),
+            ('Name', 'name', self.name),
             ('Number', 'number', self.number),
         ]
         return data
diff --git a/cyder/cydns/forms.py b/cyder/cydns/forms.py
index 1b77d91..c8bdd23 100644
--- a/cyder/cydns/forms.py
+++ b/cyder/cydns/forms.py
@@ -14,8 +14,6 @@ class ViewChoiceForm(ModelForm):


 class DNSForm(ViewChoiceForm):
-    comment = forms.CharField(widget=forms.HiddenInput, required=False)
-
     def clean(self):
         super(DNSForm, self).clean()
         validate_views(self.cleaned_data)

EDIT: Patch applied to the wrong commit. I fixed it so it now applies to the tip of this branch.

@church29
Copy link
Contributor Author

church29 commented Dec 1, 2014

@drkitty I never saw your patch. I will be fixing this pr with it and updated js when #710 is completed.

…Update_Confirm

Conflicts:
	cyder/base/views.py
	cyder/cydns/forms.py
	media/js/tables.js
@church29 church29 mentioned this pull request Feb 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Spreadsheet mode

3 participants