
    `                         S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  SSK	Jr   " S	 S
\R                  5      rg)z>Command to list all Project IDs linked with a billing account.    )absolute_import)division)unicode_literals)billing_client)base)flags)utilsc                   .    \ rS rSrSr\S 5       rS rSrg)List   a   List all active projects associated with the specified billing account.

*{command}* ACCOUNT_ID -- lists all active projects, for the specified
billing account id.

## EXAMPLES

To list projects linked to billing account `0X0X0X-0X0X0X-0X0X0X`, run:

    $ {command} 0X0X0X-0X0X0X-0X0X0X
c                 Z   U R                  SS9n[        R                  " 5       R                  U5        [        R                  " SS9R                  U5        [
        R                  R                  U 5        U R                  R                  S5        U R                  R                  S 5        g )NT)requiredF)
positionalz
          table(
            projectId,
            billingAccountName.basename():label=BILLING_ACCOUNT_ID,
            billingEnabled
          )
    )add_mutually_exclusive_groupr   GetOldAccountIdArgumentAddToParserGetAccountIdArgumentr   URI_FLAGRemoveFromParserdisplay_info	AddFormatAddCacheUpdater)parseraccount_args_groups     -lib/surface/billing/accounts/projects/list.pyArgs	List.Args(   s    <<d<K	!!#//0BC	%0<<=OPMM""6*
!! # 	 ''-    c                     [         R                  " 5       n[        R                  " UR                  =(       d    UR
                  5      nUR                  X1R                  S9$ )zRun the list command.)limit)r   ProjectsClientr	   ParseAccountidbilling_accountr   r    )selfargsclientaccount_refs       r   RunList.Run9   sD    **,F$$TWW%D0D0DEK;;{**;55r    N)	__name__
__module____qualname____firstlineno____doc__staticmethodr   r)   __static_attributes__r+   r   r   r   r      s     
 . . 6r   r   N)r0   
__future__r   r   r   googlecloudsdk.api_lib.billingr   googlecloudsdk.callioper   "googlecloudsdk.command_lib.billingr   r	   ListCommandr   r+   r   r   <module>r8      s2    E &  ' 9 ( 4 4"64 "6r   