Authored by 张帅

Merge branch 'test6.8.7' of http://git.yoho.cn/platform/platform-cms into test6.8.7

... ... @@ -50,7 +50,10 @@
<td >
<div style="float: left;width:600px;" >
<span style="color:red">*</span><label>选择用户</label> <br>
<input id="articleUid" name="authorUid" style="width:100% " class="easyui-textbox" /> <br>
<input id="articleUid" name="authorUid" style="width:100% " class="easyui-textbox" />
<a id="userBotton" class="btn btn-small" style="font-size: 18px; " >确认</a>
<br>
<span style="color:red"> 必填项,选择某个用户身份后,才能发布</span>
</div>
<div id="userInfo" style="float: left;margin-left: 30px;">
... ... @@ -179,26 +182,24 @@
}
});
$("#articleUid").textbox({
required: true,
missingMessage: "发布用户不能为空",
prompt: "请输入发布用户",
onChange: function () {
$("#userBotton").linkbutton({
iconCls : "icon-search",
onClick : function() {
//发送请求
$.ajax({
type: "POST",
url: serverContextPath + "/grassArticle/getUserInfo", //提交到后端的url
dataType: 'json',
data:{
uid : $(this).textbox("getValue")
uid : $("#articleUid").textbox("getValue")
},
success: function (result) {
if(result.code == 200) {
if(result.data !=null && result.data !=''){
var headIco = result.data.headIco.substring(0, result.data.headIco.indexOf("?"));
var html = '';
html += "<span style='font-size: 18px;'>头像:&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
html += "<span style='font-size: 18px;'>昵称:&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
html += "<span style='font-size: 18px;'>&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
html += "<span style='font-size: 18px;'>&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
$("#userInfo").html(html);
}else{
var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请检查uid输入是否正确</span>';
... ... @@ -215,6 +216,42 @@
}
});
$("#articleUid").textbox({
required: true,
missingMessage: "发布用户不能为空",
prompt: "请输入发布用户",
onChange: function () {
//发送请求
// $.ajax({
// type: "POST",
// url: serverContextPath + "/grassArticle/getUserInfo", //提交到后端的url
// dataType: 'json',
// data:{
// uid : $(this).textbox("getValue")
// },
// success: function (result) {
// if(result.code == 200) {
// if(result.data !=null && result.data !=''){
// var headIco = result.data.headIco.substring(0, result.data.headIco.indexOf("?"));
// var html = '';
// html += "<span style='font-size: 18px;'>&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
// html += "<span style='font-size: 18px;'>&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
// $("#userInfo").html(html);
// }else{
// var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请检查uid输入是否正确</span>';
// $("#userInfo").html(html);
// }
// }
// else {
// var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请稍后重试</span>';
// $("#userInfo").html(html);
// }
//
// }
// });
}
});
/*字数限制*/
// $("#content").on("input propertychange", function() {
// debugger
... ...
... ... @@ -61,9 +61,11 @@
<tr style="height: 60px">
<td style="width:100% ">
<div style="float: left;width:600px;" >
<div style="float: left;width:700px;" >
<span style="color:red">*</span><label>选择用户</label> <br>
<input id="articleUid" name="authorUid" style="width:100% " class="easyui-textbox" /> <br>
<input id="articleUid" name="authorUid" style="width:600px " class="easyui-textbox" />
<a id="userBotton" class="btn btn-small" style="font-size: 18px; " >确认</a>
<br>
<span style="color:red"> 必填项,选择某个用户身份后,才能发布</span>
</div>
<div id="userInfo" style="float: left;margin-left: 30px;">
... ... @@ -189,6 +191,39 @@
getEditDialog();
}
});
$("#userBotton").linkbutton({
iconCls : "icon-search",
onClick : function() {
//发送请求
$.ajax({
type: "POST",
url: serverContextPath + "/grassArticle/getUserInfo", //提交到后端的url
dataType: 'json',
data:{
uid : $("#articleUid").textbox("getValue")
},
success: function (result) {
if(result.code == 200) {
if(result.data !=null && result.data !=''){
var headIco = result.data.headIco.substring(0, result.data.headIco.indexOf("?"));
var html = '';
html += "<span style='font-size: 18px;'>&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
html += "<span style='font-size: 18px;'>&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
$("#userInfo").html(html);
}else{
var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请检查uid输入是否正确</span>';
$("#userInfo").html(html);
}
}
else {
var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请稍后重试</span>';
$("#userInfo").html(html);
}
}
});
}
});
$("#timerBotton").linkbutton({
iconCls : "icon-search",
... ... @@ -231,33 +266,33 @@
prompt: "请输入发布用户",
onChange: function () {
//发送请求
$.ajax({
type: "POST",
url: serverContextPath + "/grassArticle/getUserInfo", //提交到后端的url
dataType: 'json',
data:{
uid : $(this).textbox("getValue")
},
success: function (result) {
if(result.code == 200) {
if(result.data !=null && result.data !=''){
var headIco = result.data.headIco.substring(0, result.data.headIco.indexOf("?"));
var html = '';
html += "<span style='font-size: 18px;'>头像:&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
html += "<span style='font-size: 18px;'>昵称:&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
$("#userInfo").html(html);
}else{
var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请检查uid输入是否正确</span>';
$("#userInfo").html(html);
}
}
else {
var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请稍后重试</span>';
$("#userInfo").html(html);
}
}
});
// $.ajax({
// type: "POST",
// url: serverContextPath + "/grassArticle/getUserInfo", //提交到后端的url
// dataType: 'json',
// data:{
// uid : $(this).textbox("getValue")
// },
// success: function (result) {
// if(result.code == 200) {
// if(result.data !=null && result.data !=''){
// var headIco = result.data.headIco.substring(0, result.data.headIco.indexOf("?"));
// var html = '';
// html += "<span style='font-size: 18px;'>&nbsp&nbsp<img src='"+headIco+"' width='80px;' height='80px;'></span>&nbsp&nbsp&nbsp&nbsp";
// html += "<span style='font-size: 18px;'>&nbsp&nbsp<label>"+result.data.nickName+"</label></span>";
// $("#userInfo").html(html);
// }else{
// var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请检查uid输入是否正确</span>';
// $("#userInfo").html(html);
// }
// }
// else {
// var html = '<span style="color:red;font-size: 18px;">获取用户信息失败,请稍后重试</span>';
// $("#userInfo").html(html);
// }
//
// }
// });
}
});
... ...