后台代码: //解析jObject字符串 json_wang 2015/01/27 //var passengerListStr = BookingTicket_PassengerList_HiddenField.Value; //var TrainFormPassengerList = new List<TrainFormPassenger>(); //if (!string.IsNullOrEmpty(passengerListStr)) //{ // JObject jo = JObje…
Visual Studio中如何批量删除cs代码中的#region和#endregion,不删除它们中间的代码,只删除这两个标记及标记的注解的方法.Vs中提供了很强大的文本查找与替换功能,简单的替换只需输入原字符串和要替换成的字符串即可.但是复杂一些的可能就需要用到正则替换了,vs中也是支持正则表达式替换的.如题例子代码: #region 要被替换的注释 public void codeo() { } #endregion #region 要被替换的注释1 public void codeo1(…
field: 'rightType', title: '权益类型', //width: 100, align: 'left', valign: 'top', sortable: true, formatter:rightTypeFormat 其实是采用了转换函数实现前台页面显示中文 //显示格式化,将value的值转换为中文 function rightTypeFormat(value, row, index) { if (value == "") { value = "请选…
有时候需要在前台自定义对象,然后把对象封装在list中,在传送到后台,这样的思想也比较合理 1. 前台代码 $scope.saveScore = function () { $scope.userScoreList = new Array();//自定义数组 angular.forEach ($scope.records, function (record, index) { if (record.score != null) { $scope.userScoreModel = {'userAn…
1.定义一个简单的类 User.java public class User { private Integer id; private String name; public Integer getId() { return id; } public void setId(Integer id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.n…
引用地址: http://www.cnblogs.com/silenkee/articles/1609831.html   页面中加入了UpdatePanel后,Response.Write("<script>function dis (){alert('这是调用写在server的JS');}</script>")来调用客户端脚本,无任何提示的无反应.难道没有办法调用客户端脚本了?      方法是有的,那就是采用 ScriptManager.RegisterS…
后端 //添加 @RequestMapping(value = "checkChoise") @ResponseBody ResultJson checkChoise(@RequestBody List<String> arr) { ResultJson resultJson = new ResultJson(); System.out.println("str:"+arr); resultJson.setStatus(0); resultJson.se…
using System;using System.Collections;using System.ComponentModel;using System.Data;using System.Drawing;using System.Web;using System.Web.SessionState;using System.Web.UI;using System.Web.UI.WebControls;using System.Web.UI.HtmlControls;using System.…
解决方法: 在for循环前加上/* <![CDATA[ */,在for循环后加/* ]]> */,这样就能正常解析了:如下 /* <![CDATA[ */ for (var i = 0; i < 10; i++) { console.log(i); } /* ]]> */…
//后台cs代码: using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class Login_jg : System.Web.UI.Page { protected void Page_Load(object sender, EventArg…