60 lines
1.7 KiB
Plaintext
60 lines
1.7 KiB
Plaintext
@using WX.CRM.WebHelper;
|
|
@using WX.CRM.Model
|
|
@{
|
|
ViewBag.Title = "申请";
|
|
Layout = "~/Views/Shared/_Index_LayoutEdit.cshtml";
|
|
}
|
|
<style>
|
|
#ResidToolBox {
|
|
padding: 50px 50px 100px 50px;
|
|
}
|
|
</style>
|
|
<div id="ResidToolBox">
|
|
<div class="toolBox-row">
|
|
<select id="userIdType">
|
|
<option value="phone">客户手机</option>
|
|
<option value="resid">客户ID</option>
|
|
</select>
|
|
<input type="text" id="userId" value="" />
|
|
</div>
|
|
</div>
|
|
<div class="mvctool bgb">
|
|
@Html.ToolButtonPlain("btnSave", "icon-save", "保存", false, "")
|
|
</div>
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
$(function () {
|
|
$("#btnSave").click(function () {
|
|
var val = $("#userId").val();
|
|
var userIdType = $("#userIdType").val();
|
|
|
|
$.r_ajax({
|
|
url: "/Csvr/CustomerUC/BindUserSub?isAdd=@ViewBag.isAdd&resid=@ViewBag.resid&userIdType=" + userIdType +"&val="+val,
|
|
type: "POST",
|
|
data: $("#CreateForm").serialize(),
|
|
dataType: "json",
|
|
loading: true,
|
|
success: function (data) {
|
|
console.log(data)
|
|
if (data.s == true) {
|
|
$.messager.alert("操作提示", data.m, "info", function () {
|
|
window.parent.frameReturnByReload(true);
|
|
window.parent.frameReturnByClose();
|
|
window.parent.location.reload();
|
|
});
|
|
|
|
} else {
|
|
alert(data.m);
|
|
}
|
|
}
|
|
});
|
|
|
|
return false;
|
|
});
|
|
});
|
|
|
|
|
|
</script> |