1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-01 23:20:51 +00:00

[dir view] added 'file comment'

This commit is contained in:
llj
2017-09-26 10:35:16 +08:00
parent f3ad5e9685
commit b55446551b
10 changed files with 427 additions and 7 deletions

View File

@@ -14,10 +14,11 @@ define([
'app/views/dirent-details',
'app/views/fileupload',
'app/views/share',
'app/views/file-comments',
'app/views/widgets/dropdown'
], function($, progressbar, magnificPopup, simplemodal, _, Backbone, Common,
FileTree, Cookies, DirentCollection, DirentView, DirentGridView,
DirentDetailsView, FileUploadView, ShareView, DropdownView) {
DirentDetailsView, FileUploadView, ShareView, FileCommentsView, DropdownView) {
'use strict';
var DirView = Backbone.View.extend({
@@ -74,6 +75,7 @@ define([
this.fileUploadView = new FileUploadView({dirView: this});
this.direntDetailsView = new DirentDetailsView();
this.fileCommentsView = new FileCommentsView();
this.render();
@@ -159,6 +161,7 @@ define([
this.attached = false;
this.direntDetailsView.hide();
this.fileCommentsView.hide();
},
/***** private functions *****/
@@ -174,6 +177,9 @@ define([
},
reset: function() {
this.direntDetailsView.hide();
this.fileCommentsView.hide();
this.renderPath();
this.renderDirOpBar();
@@ -673,8 +679,8 @@ define([
var dirent_name = $.trim($input.val());
if (!dirent_name) {
Common.showFormError(form_id, gettext("It is required."));
return false;
Common.showFormError(form_id, gettext("It is required."));
return false;
};
if (dirent_name.indexOf('/') != -1) {