<commit_before>class GroupsBundleCreateView extends JView

  constructor:(options, data)->
    super

    {group} = @getData()

    @createButton = new KDButtonView
      style     : "clean-gray"
      title     : "Create bundle"
      callback  : =>
        group.createBundle (err, bundle) =>
          return error err  if err?

          @emit 'BundleCreated', bundle

  pistachio:->
    """
    <h3>Get started</h3>
    <p>This group doesn't have a bundle yet, but you can create one now!</p>
    {{> @createButton}}
    """

class GroupsBundleEditView extends JView

  computeUnitMap =
    vms   : 1
    cpu   : 1
    ram   : 0.25
    disk  : 0.5

  computeUnitVisibility =
    users : yes
    vms   : yes
    cpu   : no
    ram   : no
    disk  : no

  mapPlansToRadios: (plan) ->
    @plansByCode[plan.code] = plan
    { category, resource, upperBound } = plan.usage
    {
      title       : @getPlanTitle category, resource, upperBound<commit_msg>group bundle: add per user limits<commit_after>class GroupsBundleCreateView extends JView

  constructor:(options, data)->
    super

    {group} = @getData()

    @createButton = new KDButtonView
      style     : "clean-gray"
      title     : "Create bundle"
      callback  : =>
        group.createBundle (err, bundle) =>
          return error err  if err?

          @emit 'BundleCreated', bundle

  pistachio:->
    """
    <h3>Get started</h3>
    <p>This group doesn't have a bundle yet, but you can create one now!</p>
    {{> @createButton}}
    """

class GroupsBundleEditView extends JView

  computeUnitMap =
    vms   : 1
    cpu   : 1
    ram   : 0.25
    disk  : 0.5

  computeUnitVisibility =
    users       : yes
    vms         : yes
    cpu         : no
    ram         : no
    disk        : no
    cpuPerUser  : no
    ramPerUser  : no
    diskPerUser : no

  mapPlansToRadios: (plan) ->
    @plansByCode[plan.code] = plan
    { category, resource, upperBound } = plan.usage
    {
      title       : @getPlanTitle category, resource, upperBound
{'fraction_non_alphanumeric': 0.10064134188455846, 'fraction_numerical': 0.008880118401578688, 'mean_word_length': 2.0588235294117645, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4233802', 'n_tokens_mistral': 663, 'n_tokens_neox': 630, 'n_words': 176}