This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title></title> | |
<meta charset="utf-8" /> | |
<script> | |
function Auth() { | |
var URL = 'https://notify-bot.line.me/oauth/authorize?'; | |
URL += 'response_type=code'; | |
URL += '&client_id=你的Client_id'; | |
URL += '&redirect_uri=http://localhost:5467/index.html'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
<meta charset="utf-8" /> | |
<script> | |
function Auth() { | |
var URL = 'https://access.line.me/dialog/oauth/weblogin?'; | |
URL += 'response_type=code'; | |
URL += '&client_id=你的ChannelID'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.UI; | |
using System.Web.UI.WebControls; | |
using isRock.Framework.PageMethods; | |
namespace WebApplication16 | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="default.aspx.cs" Inherits="WebApplication16._default" %> | |
<!DOCTYPE html> | |
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head runat="server"> | |
<title>asp.net WebForms SPA Vue Binding </title> | |
<script src="Scripts/jquery-1.9.1.min.js"></script> | |
<script src="Scripts/vue.min.js"></script> | |
<script src="Scripts/isRockFx.js"></script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>asp.net WebAPI SPA with Vue.js Binding </title> | |
<script src="Scripts/jquery-1.9.1.min.js"></script> | |
<script src="Scripts/vue.min.js"></script> | |
<script src="Scripts/isRockFx.js"></script> | |
<link href="Content/bootstrap.min.css" rel="stylesheet" /> | |
<script> | |
var vd_StudentInfo; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public ExecuteCommandDefaultResult<List<StudentInfo>> GetData() | |
{ | |
//準備假資料 | |
List<StudentInfo> returnData = new List<StudentInfo>(); | |
returnData.Add(new StudentInfo { StudentName = "王曉明", Height = 170, Weight = 72 }); | |
returnData.Add(new StudentInfo { StudentName = "張曉春", Height = 180, Weight = 75 }); | |
returnData.Add(new StudentInfo { StudentName = "田豐盛", Height = 175, Weight = 60 }); | |
returnData.Add(new StudentInfo { StudentName = "楊明山", Height = 165, Weight = 90 }); | |
returnData.Add(new StudentInfo { StudentName = "令狐衝", Height = 172, Weight = 80 }); | |
//計算BMI |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<tbody> | |
<tr v-for="item in items"> | |
<td> | |
<button class="btn btn-outline btn-primary btn-xs" v-on:click="edit(item)">編輯</button> | |
<button class="btn btn-outline btn-primary btn-xs" v-on:click="remove(item)">刪除</button> | |
</td> | |
<td> | |
<span>{{item.StudentName}}</span> | |
</td> | |
<td> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var vd_StudentInfo; //儲存資料 | |
var vm_StudentInfo; //Vue instance | |
//設定資料繫結 | |
function SetBinding() { | |
//create vue instance | |
vm_StudentInfo = new Vue( | |
{ | |
el: '#tableBody', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// 刪除一筆資料 | |
/// </summary> | |
/// <param name=""></param> | |
/// <returns></returns> | |
public ExecuteCommandDefaultResult<List<StudentInfo>> Remove(Guid guid) | |
{ | |
//找到資料 | |
var ret = from c in StudentInfomation | |
where c.guid == guid |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>AspNetWithVueBinding </title> | |
<script src="Scripts/jquery-1.9.1.min.js"></script> | |
<script src="Scripts/vue.min.js"></script> | |
<script src="Scripts/isRockFx.js"></script> | |
<link href="Content/bootstrap.min.css" rel="stylesheet" /> | |
<script src="Scripts/utility.js"></script> | |
<script> | |
Vue.config.debug = true; //vue debug mode |