mirror of
https://github.com/haiwen/seahub.git
synced 2025-06-20 20:32:44 +00:00
26 lines
689 B
JavaScript
26 lines
689 B
JavaScript
|
define([
|
||
|
'underscore',
|
||
|
'backbone',
|
||
|
'common'
|
||
|
], function(_, Backbone, Common) {
|
||
|
|
||
|
'use strict';
|
||
|
|
||
|
var GroupRepo = Backbone.Model.extend({
|
||
|
|
||
|
getIconUrl: function(size) {
|
||
|
var is_encrypted = this.get('encrypted');
|
||
|
var is_readonly = this.get('permission') == "r" ? true : false;
|
||
|
return Common.getLibIconUrl(is_encrypted, is_readonly, size);
|
||
|
},
|
||
|
|
||
|
getIconTitle: function() {
|
||
|
var is_encrypted = this.get('encrypted');
|
||
|
var is_readonly = this.get('permission') == "r" ? true : false;
|
||
|
return Common.getLibIconTitle(is_encrypted, is_readonly);
|
||
|
}
|
||
|
});
|
||
|
|
||
|
return GroupRepo;
|
||
|
});
|