<commit_before>- if (@branch)
  .graph
    = ofc2(450, 200, url(:graph_data, :action => 'branch', :id => @branch.id, :scope_unit => 'months', :scope_size => 3) )

- if @branch
  %h1== Branch: <i>#{@branch.name}</i>
  %table.narrow.form{ :style => "width: 40%;" }
    %tr.odd
      %td Name
      %td
        %b= @branch.name
        == (code: #{@branch.code}, id: #{@branch.id})
    %tr
      %td Manager
      %td= link_to @branch.manager.name, resource(@branch.manager)
    %tr
      %td No. of centers
      %td=@branch.centers.count
    %tr
      %td Address
      %td=@branch.address
    %tr
      %td Contact number
      %td=@branch.contact_number
    %tr
      %td Landmark
      %td=@branch.landmark
    %tr
      %td Area
      - area = @branch.area
      %td=link_to(area.name, resource(area)) if area
  %p
    = link_to_with_rights 'edit this branch\'s details ', resource(@branch, :edit), :class => "edit"
    = link_to_with_rights 'create a new center', resource(@branch, :centers, :new), :class => "add"

  %div.tab_container
    %ul.tabs
      %li#centers
        Centers
      %li#info
        Info
      %li#exceptions
        Exceptions
      %li#documents
        Documents
      %li#comments
        Comments
      %li#audit
        Audit
      %li#history
        History
      %li#accounting
        Accounting
      - if Mfi.first.branch_diary_enabled
        %li#branch_diary
          Diary
      - if Mfi.first.stock_register_enabled
        %li#stock_register
          Stock
      - if Mfi.first.map_enabled
        %li#map
          Map
               
    %div.tab
      %div#centers_list
        =partial "centers/list"
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/info/moreinfo/#{@branch.id}?for=branch"}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/info/exceptions/#{@branch.id}?for=branch"}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:documents, :parent_id => @branch.id, :parent_model => Branch)}
    %div.tab
      = partial 'comments/index', :object => @branch
      %p
        %h3 Add a comment
        = partial 'comments/form'
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:audit_items, :id => @branch.id, :model => "Branch")}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => audit_trail_url}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/accounts/branch?branch_id=#{@branch.id}"}
    - if Mfi.first.branch_diary_enabled
      %div.tab
        %input{:type => "hidden", :name => "_load_remote", :value => resource(:branch_diaries, :branch_id => @branch.id, :model => "Branch")}
    - if Mfi.first.stock_register_enabled
      %div.tab
        %input{:type => "hidden", :name => "_load_remote", :value => resource(:stock_registers, :branch_id => @branch.id, :model => "Branch")}
    - if Mfi.first.map_enabled        
      %div.tab
        = js_include_tag :map
        = partial "locations/map", {:obj => @branch}
   

      
<commit_msg>asset register tab added<commit_after>- if (@branch)
  .graph
    = ofc2(450, 200, url(:graph_data, :action => 'branch', :id => @branch.id, :scope_unit => 'months', :scope_size => 3) )

- if @branch
  %h1== Branch: <i>#{@branch.name}</i>
  %table.narrow.form{ :style => "width: 40%;" }
    %tr.odd
      %td Name
      %td
        %b= @branch.name
        == (code: #{@branch.code}, id: #{@branch.id})
    %tr
      %td Manager
      %td= link_to @branch.manager.name, resource(@branch.manager)
    %tr
      %td No. of centers
      %td=@branch.centers.count
    %tr
      %td Address
      %td=@branch.address
    %tr
      %td Contact number
      %td=@branch.contact_number
    %tr
      %td Landmark
      %td=@branch.landmark
    %tr
      %td Area
      - area = @branch.area
      %td=link_to(area.name, resource(area)) if area
  %p
    = link_to_with_rights 'edit this branch\'s details ', resource(@branch, :edit), :class => "edit"
    = link_to_with_rights 'create a new center', resource(@branch, :centers, :new), :class => "add"

  %div.tab_container
    %ul.tabs
      %li#centers
        Centers
      %li#info
        Info
      %li#exceptions
        Exceptions
      %li#documents
        Documents
      %li#comments
        Comments
      %li#audit
        Audit
      %li#history
        History
      %li#accounting
        Accounting
      - if Mfi.first.branch_diary_enabled
        %li#branch_diary
          Diary
      - if Mfi.first.stock_register_enabled
        %li#stock_register
          Stock
      - if Mfi.first.asset_register_enabled
        %li#asset_register
          Asset
      - if Mfi.first.map_enabled
        %li#map
          Map
               
    %div.tab
      %div#centers_list
        =partial "centers/list"
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/info/moreinfo/#{@branch.id}?for=branch"}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/info/exceptions/#{@branch.id}?for=branch"}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:documents, :parent_id => @branch.id, :parent_model => Branch)}
    %div.tab
      = partial 'comments/index', :object => @branch
      %p
        %h3 Add a comment
        = partial 'comments/form'
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:audit_items, :id => @branch.id, :model => "Branch")}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => audit_trail_url}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => "/accounts/branch?branch_id=#{@branch.id}"}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:branch_diaries, :branch_id => @branch.id, :model => "Branch")}
    %div.tab
      %input{:type => "hidden", :name => "_load_remote", :value => resource(:stock_registers, :branch_id => @branch.id, :model => "Branch")}
    %div.tab
    - if Mfi.first.map_enabled        
      %div.tab
        = js_include_tag :map
        = partial "locations/map", {:obj => @branch}
   

      

{'fraction_non_alphanumeric': 0.16551834641884314, 'fraction_numerical': 0.0038455375741067136, 'mean_word_length': 2.4034896401308616, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 89, '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': '5879128', 'n_tokens_mistral': 2161, 'n_tokens_neox': 2123, 'n_words': 444}