강민수
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    @llingo 안녕하세요 링고 ## STEP3 내용 및 핵심경험 * 화면 제목 ‘재고 추가’ 및 ‘닫기’ 버튼 구현 * 닫기를 터치하면 이전화면으로 복귀 * 화면 진입시 과일의 현재 재고 수량 표시 * -, + 를 통한 재고 수정 * *iPhone 12 외에 다른 시뮬레이터에서도 UI가 정상적으로 보일 수 있도록 오토레이아웃 적용 #### 핵심 경험 > * 내비게이션 바 및 바 버튼 아이템의 활용 > * 얼럿 컨트롤러 활용 > * Stepper 활용 > * Modality의 활용 > * 화면 사이의 데이터 공유 > * 오토레이아웃 시작하기 ## 해결하지 못한 점 ### 네비게이션과 모달리티 화면 기법 * HIG에 따르면 정보의 깊이에 따라서 화면 전환을 달리 해주는 것이 좋다고 생각합니다 (정보를 더 깊이 들어가면 네비게이션, 정보가 전환되면 모달리티).저희는 주문을 하려면 재고가 있어야하고 그 결과 정보가 깊이 들어간다고 생각하여 `재고수정` 버튼을 누르거나 재료가 부족할 때 `재고수정을 할까요?`에서 `예` 버튼을 눌러면 네비게이션으로 이동하게 구현했습니다. * 하지만 재고수정과 쥬스 주문은 주문과 수정의 별개의 정보라고 생각한다면 모달리티로 전환해주는 것이 좋다고 생각합니다. 어느 방법이 타당하다고 생각하시는지 궁금합니다 ## 고민한점 && 조언을 얻고 싶은 부분 ### 데이터 전달 방식 * 싱글톤 * delegate ### 오토레이아웃 실제 화면 * 스토리보드로 ### 네비게이션 화면전환시 자동으로 생기는 뒤로가기 버튼 #### 문제점 * 네비게이션으로 화면전환 시 자동으로 뒤로가기 버튼이 생기는데, STEP3의 경우 뒤로가기 버튼이 없고 닫기 버튼이 우측에 구현되어 있었습니다. #### 해결방법 ```swift override func viewDidLoad() { super.viewDidLoad() self.navigationItem.hidesBackButton = true } @IBAction private func didTapDismissButton(_ sender: UIButton) { self.navigationController?.popViewController(animated: true) } ``` * 네비게이션 아이템의 프로퍼티 중 hidesBackButton이라는 프로퍼티가 뒤로가기 버튼을 숨길 수 있게 해줘서 hidesBackButton의 값을 true로 줘서 숨겼습니다. * 또, 네비게이션 바의 우측에 "닫기"버튼을 추가하여 이 버튼을 클릭할 시 -----------------질문-------------------------- ## 질문 1. FruitStockViewController으로의 화면전환을 모달리티, 네비게이션 어느게 타당한지? 2. 싱글톤, delegation pattern 둘다 데이터 공유 하는 방식인데 두 방식을 같이 써야하는지 하나만 사용해야하는지 궁금합니다., 만약 싱글톤을 안쓰게 된다면 FruitStockViewController내에는 딕셔너리 인스턴스만 있고 JuiceMaker뷰 컨트롤러에서 JuiceMaker 인스턴스를 통해 재고를 바꿔줘야하는 형태로 가야하는지? 3. 스토리보드 내에서 다른 폰을 한꺼번에 확인 가능한지? 4. updateLabel함수는 전체 Label을 바꿔주는 함수인데 바뀌는 부분만 해결할 수 있게 만들어 주고 싶은데 어떻게 하는게 좋을지 모르겠습니다. ## 정리 1. 데이터 공유 방식 (pattern) * delegate 사용 -> 의존성 약화를 위해서 사용 * JuiceMakerViewController -> FruitStockViewController로 넘어갈 경우에는 단순히 메소드만 구현(양방향으로 delegation 구현시 의존성이 높아짐) * FruitStockViewController -> JuiceMakerViewController로 넘어갈 경우 delegate로 구현 * 싱글톤 사용시 각각의 ViewController간에 결합도가 높아지기 떄문 2. 화면 전환 방식 * Navigation 방식 * 주문을 하려면 재고가 필요하고 정보의 깊어져간다고 생각하여 사용 3. UML * 클래스 다이어그램 4. 팀 그라운드 룰의 경우 하단 부분으로 배치

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully