Sha256: 21aff43d67f7f18fe0ad24f43f7f52964fac212ff1c7155ad2fb7546fcf8ea3d
Contents?: true
Size: 745 Bytes
Versions: 6
Compression:
Stored size: 745 Bytes
Contents
module Tr3llo module Command module List module ArchiveCards extend self def execute(key) list_id = Entities.parse_id(:list, key) interface = Application.fetch_interface!() interface.print_frame do is_approved = interface.input.yes?("Are you sure you want to archive all cards?") if is_approved archive_cards(list_id) interface.puts("All cards on the list have been archived.") end end end private def archive_cards(list_id) API::List.archive_cards(list_id) end def interface Application.fetch_interface!() end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems