Tipo music-ui-規劃原則
Upcoming SlideShare
Loading in...5
×
 

Tipo music-ui-規劃原則

on

  • 269 views

 

Statistics

Views

Total Views
269
Views on SlideShare
269
Embed Views
0

Actions

Likes
0
Downloads
0
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Tipo music-ui-規劃原則 Presentation 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"] = " 匯入失敗 !!"; }