• Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
190
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
0
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Tipo Music UI 規劃原則 By Jax
  • 2. 原則 • 只要是 button 就要有包含 Icon • 所有 User 操作的 Ajax 都要 Handle 等待、成功、失敗
  • 3. StatusMsg var StatusMsg = {  clear: function () { },  alert: function (str) { },  error: function (str) { },  wait: function (str) { }  }; 
  • 4. ltcAjax $.ltcAjax({ url: this.href, waitMsg: ' 刪除中 ...', button: this, success: function (msg) { StatusMsg.alert(msg); $(this.button).closest('tr').remove(); } });
  • 5. Message to Ajax try { _useListRepo.DeleteSong(useListSongSN); return Content(" 刪除成功 !!"); } catch (Exception ex) { _log.ErrorException(" 利用人 UseList  歌曲刪除失 敗 !!", ex); Response.TrySkipIisCustomErrors = true; Response.StatusCode = 400; return Content(" 刪除失敗 !!"); }
  • 6. Message to View try { // ... TempData["StatusSuccess"] = " 匯入成功 !!";                  return RedirectToAction("AnalysisMusicGroupOwner", new { BatchID = batchID }); } catch (TipoMusicException ex) { TempData["StatusError"] = ex.Message; TempData["ImportListErrorMessage"] = ex.ErrorMessages; } catch (Exception ex) { _log.ErrorException(" 利用人 UseList  匯入失敗 !!", ex); TempData["StatusError"] = " 匯入失敗 !!"; }
  • 7. Message to View try { // ... TempData["StatusSuccess"] = " 匯入成功 !!";                  return RedirectToAction("AnalysisMusicGroupOwner", new { BatchID = batchID }); } catch (TipoMusicException ex) { TempData["StatusError"] = ex.Message; TempData["ImportListErrorMessage"] = ex.ErrorMessages; } catch (Exception ex) { _log.ErrorException(" 利用人 UseList  匯入失敗 !!", ex); TempData["StatusError"] = " 匯入失敗 !!"; }