@@ -572,12 +572,12 @@ | |||
<script id="biddingHallListData" type="text/html"> | |||
{{each biddingHallListList as value i}} | |||
<tr> | |||
<td>1惠城区桥东街道...</td> | |||
<td>阶梯竞价</td> | |||
<td>2021-4-1 9:00</td> | |||
<td>2021-4-1 9:00</td> | |||
<td>100</td> | |||
<td>110</td> | |||
<td>{{value.projectName}}</td> | |||
<td>{{value.biddingType}}</td> | |||
<td>{{value.signupStopTime.substr(0,10)}}</td> | |||
<td>{{value.biddingStartTime.substr(0,10)}}</td> | |||
<td>{{value.price}}</td> | |||
<td>{{value.money}}</td> | |||
<td>进行中</td> | |||
<td> | |||
<input type="button" value="我要竞价" /> | |||
@@ -6,4 +6,10 @@ | |||
@purl /transaction/website/addMember | |||
@param | |||
*/ | |||
var userRegister = '/transaction/website/addMember' //修改用户信息类接口 | |||
var userRegister = '/transaction/website/addMember' //修改用户信息类接口 | |||
/* | |||
@purl /transaction/website/data/type | |||
@param | |||
*/ | |||
var Dictionaries = '/transaction/website/data/type'//成交公告字典 |
@@ -136,13 +136,7 @@ require(["jquery", "Tools","addressApi"], function ($, Tools) { | |||
} | |||
outLogin = function(){ | |||
var keys = document.cookie.match(/[^ =;]+(?==)/g) | |||
if (keys) { | |||
for (var i = keys.length; i--;) { | |||
document.cookie = keys[i] + '=0;path=/;expires=' + new Date(0).toUTCString() // 清除当前域名下的,例如:m.ratingdog.cn | |||
} | |||
location.reload(); | |||
} | |||
tools.removeAllCookie(); | |||
} | |||
goIndex = function(){ | |||
@@ -40,6 +40,7 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
var code = data.code; | |||
var msg = data.msg; | |||
if (code === 401) { | |||
_this.removeAllCookie(); | |||
_this.initDialog('系统提示', '登录状态已过期,您可以继续留在该页面,或者重新登录', function () { | |||
_this.skip('/view/login/login.html') | |||
}, '重新登录', function () { }, "取消") | |||
@@ -85,6 +86,7 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
var code = data.code; | |||
var msg = data.msg; | |||
if (code === 401) { | |||
_this.removeAllCookie(); | |||
_this.initDialog('系统提示', '登录状态已过期,您可以继续留在该页面,或者重新登录', function () { | |||
_this.skip('/view/login/login.html') | |||
}, '重新登录', function () { }, "取消") | |||
@@ -110,7 +112,6 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
var _this = this; | |||
// deptId=100& | |||
var url = ajaxJsUrl + uri + '?'; | |||
console.log(url); | |||
var headAttribute = '' | |||
if (Bearer && Bearer == true || _this.getCookie('Admin-Token') == '') { | |||
headAttribute = function (xhr) { | |||
@@ -140,9 +141,7 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
var code = data.code; | |||
var msg = data.msg; | |||
if (code === 401) { | |||
_this.removeCookie('Admin-Token'); | |||
_this.removeCookie('userName'); | |||
_this.removeAllCookie(); | |||
_this.initDialog('系统提示', '登录状态已过期,您可以继续留在该页面,或者重新登录', function () { | |||
_this.skip('/view/login/login.html') | |||
}, '重新登录', function () { }, "取消") | |||
@@ -198,9 +197,7 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
var code = data.code; | |||
var msg = data.msg; | |||
if (code === 401) { | |||
_this.removeCookie('Admin-Token'); | |||
_this.removeCookie('userName'); | |||
_this.removeAllCookie(); | |||
_this.initDialog('系统提示', '登录状态已过期,您可以继续留在该页面,或者重新登录', function () { | |||
_this.skip('/view/login/login.html') | |||
}, '重新登录', function () { }, "取消") | |||
@@ -396,6 +393,19 @@ define(['jquery', 'dialog'], function ($, dialog) { | |||
$("#webConfigAddress").html(content[0].configValue+' '+content[3].configValue); | |||
} | |||
}, | |||
/** | |||
* webConfigInformation 网站配置信息 | |||
* @param | |||
*/ | |||
removeAllCookie : function () { | |||
var keys = document.cookie.match(/[^ =;]+(?==)/g) | |||
if (keys) { | |||
for (var i = keys.length; i--;) { | |||
document.cookie = keys[i] + '=0;path=/;expires=' + new Date(0).toUTCString() // 清除当前域名下的,例如:m.ratingdog.cn | |||
} | |||
location.reload(); | |||
} | |||
}, | |||
}); | |||
return Tool; | |||
}); |
@@ -12,10 +12,12 @@ define(['jquery', "template", "Tools", 'swiper', 'itemsApi'], function ($, templ | |||
module.init = function (page) { | |||
//浏览次数 | |||
tools.doGet(outProject + '/'+getQueryVariable('id'), {}, module.projectNum(),true); | |||
//项目基本信息 | |||
tools.doGet(outProject + '/id/'+getQueryVariable('id'), {}, module.outProjectInformation,true); | |||
//项目基本信息 | |||
tools.doGet(showImg + '/'+getQueryVariable('id'), {}, module.showImgInformation,true); | |||
@@ -35,6 +37,10 @@ define(['jquery', "template", "Tools", 'swiper', 'itemsApi'], function ($, templ | |||
return(false); | |||
} | |||
module.projectNum = function(data){ | |||
console.log(data) | |||
} | |||
module.signup = function(data){ | |||
console.log(data) | |||
module.data.signup = data.data; | |||
@@ -293,6 +293,7 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
formAction = function (type){ | |||
var data = {}; | |||
//var password = $('#password').val(); | |||
module.data.userFormType = type ; | |||
if(type == 'company'){ | |||
//公司用户信息 | |||
var companyName = $('#companyName').val(); | |||
@@ -318,6 +319,10 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
data['companyCapital'] = companyCapital; | |||
data['companyLicense'] = companyLicense; | |||
data['address'] = address; | |||
tools.setCookie('userName',realname,24 * 60 * 60) | |||
tools.setCookie('idCardNum',idCardNum,24 * 60 * 60) | |||
tools.setCookie('address',address,24 * 60 * 60) | |||
} | |||
if(type == 'user'){ | |||
//个人用户信息 | |||
@@ -327,6 +332,10 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
data['idCardNum'] = userFormIdCard; | |||
data['realname'] = userFormRealName; | |||
data['address'] = userFormAddress; | |||
tools.setCookie('userName',userFormRealName,24 * 60 * 60) | |||
tools.setCookie('idCardNum',userFormIdCard,24 * 60 * 60) | |||
tools.setCookie('address',userFormAddress,24 * 60 * 60) | |||
} | |||
if(type == 'bank'){ | |||
//银行卡信息 | |||
@@ -336,6 +345,9 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
data['bankCardName'] = bankCardName; | |||
data['bankCardNum'] = bankCardNum; | |||
data['bankAddress'] = bankAddress; | |||
tools.setCookie('bankCardName',bankCardName,24 * 60 * 60) | |||
tools.setCookie('bankCardNum',bankCardNum,24 * 60 * 60) | |||
tools.setCookie('bankAddress',bankAddress,24 * 60 * 60) | |||
} | |||
//data['password'] = password; | |||
data['id'] = module.data.memberId; | |||
@@ -387,6 +399,8 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
data['realname'] = releaseRealName; | |||
data['phone'] = releasePhone; | |||
data['logintime'] = logintime; | |||
data['deptId'] = 100; | |||
data['memberId'] = module.data.memberId; | |||
@@ -394,7 +408,6 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
} | |||
module.Tips = function(data){ | |||
console.log(data) | |||
tools.initError(data.msg); | |||
} | |||
@@ -459,5 +472,12 @@ define(['jquery', "template", "Tools", "user", "paging","cupload","ajaxUploadIma | |||
} | |||
goSearch = function () { | |||
var searchTitle = $('#searchTitle').val(); | |||
var searchContent = $('#searchContent').val(); | |||
console.log(searchTitle) | |||
tools.doGet(userConsulting, {title:searchTitle,content:searchContent,memberId:module.data.memberId,pageNum:module.data.pageNum,pageSize:module.data.pageSize}, module.interactInformation); | |||
} | |||
return module; | |||
}); |
@@ -20,6 +20,7 @@ define(['jquery', "template", "Tools", "echarts", 'register', 'swiper'], functio | |||
//网站配置信息(网站名称 底部联系方式 公安备案号 网站备案号) | |||
tools.getWebConfig(); | |||
module.getType(); | |||
tools.doGet(Dictionaries+'/economic_type', {}, module.economicTypeDictionaries,true); | |||
}; | |||
@@ -34,6 +35,17 @@ define(['jquery', "template", "Tools", "echarts", 'register', 'swiper'], functio | |||
return(false); | |||
} | |||
//经济类型 | |||
module.economicTypeDictionaries = function (data) { | |||
if (data.code == 200) { | |||
var content = data.data; | |||
console.log(content) | |||
module.data.outProjectInformationDetail = content; | |||
var outProjectInformationData = template('outProjectInformationData', module.data); | |||
$("#economicType").html(outProjectInformationData); | |||
} | |||
} | |||
module.getType = function(){ | |||
var type = getQueryVariable("type"); | |||
if (type == 1){ | |||
@@ -103,6 +115,7 @@ define(['jquery', "template", "Tools", "echarts", 'register', 'swiper'], functio | |||
var address = $('#companyAddress').val(); | |||
var companyLicense = $('#companyLicense').val(); | |||
var companyCode = $('#companyCode').val(); | |||
var economicType = $('#economicType').val(); | |||
data['phone'] = phone; | |||
data['password'] = passwordVal; | |||
@@ -113,6 +126,7 @@ define(['jquery', "template", "Tools", "echarts", 'register', 'swiper'], functio | |||
data['companyName'] = companyName; | |||
data['companyLicense'] = companyLicense; | |||
data['companyCode'] = companyCode; | |||
data['economicType'] = economicType; | |||
} | |||
data['memberType'] = module.data.type; | |||
tools.doPost(userRegister, data, module.registerData, true) | |||
@@ -142,29 +156,55 @@ define(['jquery', "template", "Tools", "echarts", 'register', 'swiper'], functio | |||
var realName = $('#realName').val(); | |||
var idCardNum = $('#idCardNum').val(); | |||
var address = $('#address').val(); | |||
var companyRealName = $('#companyRealName').val(); | |||
var companyIdCardNum = $('#companyIdCardNum').val(); | |||
var companyAddress = $('#companyAddress').val(); | |||
/* 手机号 */ | |||
if (phone == '') { | |||
$('#phone')[0].focus() | |||
tools.initTips('请输入手机号', 'right', $('#phone')[0], 2000) | |||
return false; | |||
} | |||
/* 姓名 */ | |||
if (realName == '') { | |||
$('#realName')[0].focus() | |||
tools.initTips('请输入姓名', 'right', $('#realName')[0], 2000) | |||
return false; | |||
} | |||
/* 身份证号 */ | |||
if (idCardNum == '') { | |||
$('#idCardNum')[0].focus() | |||
tools.initTips('请输入身份证号', 'right', $('#idCardNum')[0], 2000) | |||
return false; | |||
if (module.data.type == 1) { | |||
/* 姓名 */ | |||
if (realName == '') { | |||
$('#realName')[0].focus() | |||
tools.initTips('请输入姓名', 'right', $('#realName')[0], 2000) | |||
return false; | |||
} | |||
/* 身份证号 */ | |||
if (idCardNum == '') { | |||
$('#idCardNum')[0].focus() | |||
tools.initTips('请输入身份证号', 'right', $('#idCardNum')[0], 2000) | |||
return false; | |||
} | |||
/* 地址 */ | |||
if (address == '') { | |||
$('#address')[0].focus() | |||
tools.initTips('请输入地址', 'right', $('#address')[0], 2000) | |||
return false; | |||
} | |||
} | |||
/* 地址 */ | |||
if (address == '') { | |||
$('#address')[0].focus() | |||
tools.initTips('请输入地址', 'right', $('#address')[0], 2000) | |||
return false; | |||
if (module.data.type == 2){ | |||
/* 姓名 */ | |||
if (companyRealName == '') { | |||
$('#companyRealName')[0].focus() | |||
tools.initTips('请输入姓名', 'right', $('#companyRealName')[0], 2000) | |||
return false; | |||
} | |||
/* 身份证号 */ | |||
if (companyIdCardNum == '') { | |||
$('#companyIdCardNum')[0].focus() | |||
tools.initTips('请输入身份证号', 'right', $('#companyIdCardNum')[0], 2000) | |||
return false; | |||
} | |||
/* 地址 */ | |||
if (companyAddress == '') { | |||
$('#companyAddress')[0].focus() | |||
tools.initTips('请输入地址', 'right', $('#companyAddress')[0], 2000) | |||
return false; | |||
} | |||
} | |||
/* 密码 */ | |||
if (passwordVal == '') { | |||
@@ -202,11 +202,14 @@ | |||
<td> | |||
<span>*</span>经济类型: | |||
</td> | |||
<td> | |||
<select id="economicType"> | |||
<option value="1">供应</option> | |||
<option value="2">求购</option> | |||
</select> | |||
<script id="outProjectInformationData" type="text/html"> | |||
{{each outProjectInformationDetail as value i}} | |||
<option value="{{value.dictValue}}">{{value.dictLabel}}</option> | |||
{{/each}} | |||
</script> | |||
<select id="economicType"></select> | |||
</td> | |||
<td> | |||
必须选择经济类型 | |||
@@ -395,10 +395,10 @@ | |||
<div class="fl releaseSupply" id="consultingInformation" style="display: none;"> | |||
<div class="searchCriteria" style="padding-top: 0;"> | |||
<p class="fl m-r-5">标题:</p> | |||
<input type="text" class="fl m-r-25"/> | |||
<input type="text" class="fl m-r-25" id="searchTitle"/> | |||
<p class="fl m-r-5">内容:</p> | |||
<input type="text" class="fl m-r-25"/> | |||
<input type="button" value="搜索" class="fl m-r-25"/> | |||
<input type="text" class="fl m-r-25" id="searchContent"/> | |||
<input type="button" value="搜索" class="fl m-r-25" onclick="goSearch()"/> | |||
<input type="button" onclick="goRelease()" value="我要发布" class="fl"/> | |||
<div class="clear"></div> | |||
</div> | |||