+ }],
+ listeners: {
+ scope: me,
+ beforerender: function(e, eOpts) {
+ var nameField = this.findField("name");
+ if (me.parenttype === "Snapshot") {
+ nameField.hide();
+ nameField.allowBlank = true;
+ } else {
+ nameField.show();
+ nameField.allowBlank = false;
+ }
+ }
+ }
+ },{
+ xtype: "textfield",
+ name: "mountpoint",
+ fieldLabel: _("Mountpoint"),
+ allowBlank: true,
+ plugins: [{
+ ptype: "fieldinfo",
+ text: _("Optional mountpoint of the filesystem. If left blank parent mountpoint will be prepended to name of the filesystem.")
+ }],
+ listeners: {
+ scope: me,
+ beforerender: function(e, eOpts) {
+ var mountField = this.findField("mountpoint");
+ if (combodata[0][0] === "filesystem") {
+ mountField.show();
+ } else {
+ mountField.hide();
+ }
+ }
+ }
+ },{
+ xtype: "textfield",
+ name: "clonename",
+ id: "clonename",
+ fieldLabel: _("Clone name"),
+ allowBlank: false,
+ plugins: [{
+ ptype: "fieldinfo",
+ text: _("Name of the new Clone. It can be placed anywhere within the ZFS hierarchy.")
+ }],
+ listeners: {
+ scope: me,
+ beforerender: function(e, eOpts) {
+ var cloneField = this.findField("clonename");
+ if (me.parenttype === "Snapshot") {
+ cloneField.show();
+ cloneField.allowBlank = false;
+ } else {
+ cloneField.hide();
+ cloneField.allowBlank = true;
+ }
+ }
+ }