Commit c92e8a72 authored by xishifeng's avatar xishifeng

暂存

parent ca1cabc7
...@@ -158,7 +158,6 @@ ...@@ -158,7 +158,6 @@
padding-bottom: 20px; padding-bottom: 20px;
margin: 0; margin: 0;
} }
/*************************分页加载相关样式loading*********************************/
.loading_pic { .loading_pic {
font-size: 20px; font-size: 20px;
...@@ -190,6 +189,10 @@ ...@@ -190,6 +189,10 @@
text-align: center; text-align: center;
display: none; display: none;
} }
/**/
#li_dujia_area{
/*display: none;*/
}
</style> </style>
<div class="container"> <div class="container">
<div class="row"> <div class="row">
...@@ -201,76 +204,93 @@ ...@@ -201,76 +204,93 @@
<ul class="list-group"> <ul class="list-group">
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="shangpu_type">商铺类型</label> <label for="shangpuType">商铺类型</label>
<select class="form-control" name="shangpu_type" id="shangpu_type"> <select class="form-control" name="shangpuType" id="shangpuType">
<option value="0">商场</option> <option value="0">商场</option>
<option value="1">街铺</option> <option value="1">街铺</option>
</select> </select>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="show_all">显示给C端用户看</label> <label for="show_all">显示给C端用户看</label>
<select class="form-control" name="show_all" id="show_all"> <select class="form-control" name="showCd" id="showCd">
<option value="0"></option> <option value="0"></option>
<option value="1"></option> <option value="1"></option>
</select> </select>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="exclusive_type">是否独家</label> <label for="exclusiveType">是否独家</label>
<select class="form-control" name="exclusive_type" id="exclusive_type"> <select class="form-control" name="exclusiveType" id="exclusiveType">
<option value="0"></option> <option value="1"></option>
<option value="1"></option> <option value="0"></option>
</select> </select>
</div> </div>
</li> </li>
<li class="list-group-item" id="li_dujia_area">
<div class="form-group">
<label for="">独家代理有效期</label>
<div class="input-group">
<input type="date" class="form-control" id="exclusiveDate1" placeholder="请输入">
<div class="input-group-addon"></div>
<input type="date" class="form-control" id="exclusiveDate2" placeholder="请输入">
</div>
</div>
<div class="form-group phone-list-container" style="width: 45px;margin-right: 0;">
<label for="">独家方</label>
</div>
<div class="form-group phone-list-container">
<input type="tel" class="form-control phone_jia" id="exclusiveTel" placeholder="请输入">
<ul></ul>
</div>
</li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group phone-list-container" style="width: 70px;"> <div class="form-group phone-list-container" style="width: 70px;">
<label for="">案场人电话</label> <label for="">案场人电话</label>
</div> </div>
<div class="form-group phone-list-container"> <div class="form-group phone-list-container">
<input type="tel" class="form-control acqx_phone_jia" placeholder="请输入"> <input type="tel" class="form-control phone_jia" placeholder="请输入">
<ul></ul> <ul></ul>
</div> </div>
<!--<div class="form-group phone-list-container"> <!--<div class="form-group phone-list-container">
<input type="tel" class="form-control acqx_phone_jia" placeholder="请输入"> <input type="tel" class="form-control phone_jia" placeholder="请输入">
<ul></ul> <ul></ul>
<img src="/resource/image/search_gb.png" class="input-cancel-pic" /> <img src="/resource/image/search_gb.png" class="input-cancel-pic" />
</div>--> </div>-->
<img src="/resource/image/jia2@2x.png" class="input-add-tel" id="acr_tel_jia" /> <img src="/resource/image/jia2@2x.png" data-hideid='1' class="input-add-tel" id="acr_tel_jia" />
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group phone-list-container" style="width: 70px;"> <div class="form-group phone-list-container" style="width: 70px;">
<label for="">盘方</label> <label for="">盘方</label>
</div> </div>
<div class="form-group phone-list-container"> <div class="form-group phone-list-container">
<input type="tel" class="form-control acqx_phone_jia" placeholder="请输入"> <input type="tel" class="form-control phone_jia" placeholder="请输入">
<ul></ul> <ul></ul>
</div> </div>
<img src="/resource/image/jia2@2x.png" class="input-add-tel" id="pf_tel_jia" /> <img src="/resource/image/jia2@2x.png" data-hideid='0' class="input-add-tel" id="pf_tel_jia" />
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group phone-list-container" style="width: 70px;"> <div class="form-group phone-list-container" style="width: 70px;">
<label for="">案场权限人</label> <label for="">案场权限人</label>
</div> </div>
<div class="form-group phone-list-container"> <div class="form-group phone-list-container">
<input type="tel" class="form-control acqx_phone_jia" placeholder="请输入"> <input type="tel" class="form-control phone_jia" placeholder="请输入">
<ul></ul> <ul></ul>
</div> </div>
<img src="/resource/image/jia2@2x.png" class="input-add-tel" id="acqx_tel_jia" /> <img src="/resource/image/jia2@2x.png" data-hideid='0' class="input-add-tel" id="acqx_tel_jia" />
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="internal_name">对内商铺名称</label> <label for="internalName">对内商铺名称</label>
<input type="text" class="form-control" placeholder="请输入" name="internal_name" id="internal_name"> <input type="text" class="form-control" placeholder="请输入" name="internalName" id="internalName">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="foreign_name">对外商铺名称</label> <label for="foreignName">对外商铺名称</label>
<input type="text" class="form-control" placeholder="请输入" name="foreign_name" id="foreign_name"> <input type="text" class="form-control" placeholder="请输入" name="foreignName" id="foreignName">
</div> </div>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="group">租金模式</label> <label for="group">租金模式</label>
<select class="form-control" name="group" id="group"> <select class="form-control" name="zujinType" id="zujinType">
<option value="1" selected="selected">月租金</option> <option value="1" selected="selected">月租金</option>
<option value="2">营业额扣点</option> <option value="2">营业额扣点</option>
<option value="3">每平方米租金</option> <option value="3">每平方米租金</option>
...@@ -279,21 +299,21 @@ ...@@ -279,21 +299,21 @@
<div class="form-group"> <div class="form-group">
<label class="" for="price">月租均价</label> <label class="" for="price">月租均价</label>
<div class="input-group"> <div class="input-group">
<input type="number" class="form-control input-100-width" name="price" id="price" placeholder="请输入"> <input type="number" class="form-control input-100-width" name="moonPrice" id="moonPrice" placeholder="请输入">
<div class="input-group-addon">元/月</div> <div class="input-group-addon">元/月</div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="management_fee">物业管理费</label> <label for="management_fee">物业管理费</label>
<div class="input-group"> <div class="input-group">
<input type="number" class="form-control input-100-width" name="management_fee" id="management_fee" placeholder="请输入"> <input type="number" class="form-control input-100-width" name="wuyePrice" id="wuyePrice" placeholder="请输入">
<div class="input-group-addon">元/月</div> <div class="input-group-addon">元/月</div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">进场费</label> <label for="">进场费</label>
<div class="input-group"> <div class="input-group">
<input type="number" class="form-control input-100-width" id="" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="jinchangPrice" placeholder="请输入">
<div class="input-group-addon">元/月</div> <div class="input-group-addon">元/月</div>
</div> </div>
</div> </div>
...@@ -301,25 +321,25 @@ ...@@ -301,25 +321,25 @@
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="">剩余铺数</label> <label for="">剩余铺数</label>
<input type="number" class="form-control input-100-width" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="roomShengyuNum" placeholder="请输入">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">总铺数</label> <label for="">总铺数</label>
<input type="number" class="form-control input-100-width" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="roomAllNum" placeholder="请输入">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">商铺面积</label> <label for="">商铺面积</label>
<div class="input-group"> <div class="input-group">
<input type="number" class="form-control input-100-width" id="" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="roomArea1" placeholder="请输入">
<div class="input-group-addon"></div> <div class="input-group-addon"></div>
<input type="number" class="form-control input-100-width" id="" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="roomArea2" placeholder="请输入">
<div class="input-group-addon"></div> <div class="input-group-addon"></div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">商业面积</label> <label for="">商业面积</label>
<div class="input-group"> <div class="input-group">
<input type="number" class="form-control input-100-width" id="" placeholder="请输入"> <input type="number" class="form-control input-100-width" id="businessArea" placeholder="请输入">
<div class="input-group-addon"></div> <div class="input-group-addon"></div>
</div> </div>
</div> </div>
...@@ -327,16 +347,16 @@ ...@@ -327,16 +347,16 @@
<li class="list-group-item"> <li class="list-group-item">
<label for="">业态(可多选)</label> <label for="">业态(可多选)</label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="餐饮美食">餐饮美食 <input type="checkbox" class="yetai" id="" value="餐饮美食">餐饮美食
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="百货零售">百货零售 <input type="checkbox" class="yetai" id="" value="百货零售">百货零售
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="休闲娱乐">休闲娱乐 <input type="checkbox" class="yetai" id="" value="休闲娱乐">休闲娱乐
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="其他">其他 <input type="checkbox" class="yetai" id="" value="其他">其他
</label> </label>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
...@@ -345,8 +365,8 @@ ...@@ -345,8 +365,8 @@
<select class="form-control" id="province_internal" name="province_internal"></select> <select class="form-control" id="province_internal" name="province_internal"></select>
<select class="form-control" id="city_internal" name="city_internal"></select> <select class="form-control" id="city_internal" name="city_internal"></select>
<select class="form-control" id="disc_internal" name="disc_internal"></select> <select class="form-control" id="disc_internal" name="disc_internal"></select>
<input type="text" class="form-control" placeholder="请输入详细地址"> <input type="text" class="form-control" id="address_internal" placeholder="请输入详细地址">
<button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bs-example-modal-lg" id="position_btn">选择地址定位</button> <button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bs-example-modal-lg" id="position_btn">定位</button>
</div> </div>
<div class="form-group"> <div class="form-group">
...@@ -361,38 +381,38 @@ ...@@ -361,38 +381,38 @@
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="">对外地址</label> <label for="">对外地址</label>
<select class="form-control" id="province_external" name="province_external"></select> <input type="text" class="form-control input-100-width" title="与对内地址一致,请通过修改对内地址,来改变此值" readonly="readonly" id="province_external" value="上海" />
<select class="form-control" id="city_external" name="city_external"></select> <input type="text" class="form-control input-100-width" title="与对内地址一致,请通过修改对内地址,来改变此值" readonly="readonly" id="city_external" value="上海" />
<select class="form-control" id="disc_external" name="disc_external"></select> <input type="text" class="form-control input-100-width" title="与对内地址一致,请通过修改对内地址,来改变此值" readonly="readonly" id="disc_external" value="黄浦" />
<input type="text" class="form-control" placeholder="请输入详细地址"> <input type="text" class="form-control" id="address_external" placeholder="请输入详细地址">
</div> </div>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">交通</label> <label for="">交通</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="traffic"></textarea>
</div> </div>
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">已入住</label> <label for="">已入住</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="hasMoved"></textarea>
</div> </div>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group"> <div class="form-group">
<label for="">营业时间</label> <label for="">营业时间</label>
<input type="text" class="form-control"> <input type="text" class="form-control" id="yingyeTime">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">开盘时间</label> <label for="">开盘时间</label>
<input type="date" class="form-control"> <input type="date" class="form-control" id="kaipanTime">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">开业时间</label> <label for="">开业时间</label>
<input type="date" class="form-control"> <input type="date" class="form-control" id="kaiyeTime">
</div> </div>
<div class="form-group"> <div class="form-group">
<label for="">是否有燃气</label> <label for="">是否有燃气</label>
<select class="form-control"> <select class="form-control" id="hasGas">
<option value="0" selected="selected"></option> <option value="0" selected="selected"></option>
<option value="1">没有</option> <option value="1">没有</option>
</select> </select>
...@@ -402,7 +422,7 @@ ...@@ -402,7 +422,7 @@
<div class="form-group"> <div class="form-group">
<label for="">微楼书</label> <label for="">微楼书</label>
<div class="input-group"> <div class="input-group">
<input type="text" class="form-control input-360-width" id="" placeholder="请填入微楼书网页链接"> <input type="text" class="form-control input-360-width" id="weilouLink" placeholder="请填入微楼书网页链接">
<div class="input-group-addon">如(https://www.fujuhaofang.com)</div> <div class="input-group-addon">如(https://www.fujuhaofang.com)</div>
</div> </div>
</div> </div>
...@@ -410,7 +430,7 @@ ...@@ -410,7 +430,7 @@
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group" style="width: 100%;"> <div class="form-group" style="width: 100%;">
<label for="" style="width: 100%;">大讲堂</label> <label for="" style="width: 100%;">大讲堂</label>
<div class="input-group" style="width: 100%;"> <div class="input-group" style="width: 100%;" id="dajiangtang">
<?php <?php
create_editor('describe'); create_editor('describe');
?> ?>
...@@ -420,73 +440,73 @@ ...@@ -420,73 +440,73 @@
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">佣金规则</label> <label for="">佣金规则</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="yongjinRule"></textarea>
</div> </div>
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">对内项目优势</label> <label for="">对内项目优势</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="internalYoushi"></textarea>
</div> </div>
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">对外项目优势</label> <label for="">对外项目优势</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="foreignYoushi"></textarea>
</div> </div>
<div class="form-group full-width-100"> <div class="form-group full-width-100">
<label for="">签约规则</label> <label for="">签约规则</label>
<textarea class="form-control textarea-500-width" rows="3"></textarea> <textarea class="form-control textarea-500-width" rows="3" id="qianyueRule"></textarea>
</div> </div>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
<label for="">商铺标签(可多选)</label> <label for="">商铺标签(可多选)</label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="临近地铁" name="shangpu_tags[]">临近地铁 <input type="checkbox" class="roomTag" id="" value="临近地铁" name="shangpu_tags[]">临近地铁
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="临街旺铺" name="shangpu_tags[]">临街旺铺 <input type="checkbox" class="roomTag" id="" value="临街旺铺" name="shangpu_tags[]">临街旺铺
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="无进场费"name="shangpu_tags[]">无进场费 <input type="checkbox" class="roomTag" id="" value="无进场费"name="shangpu_tags[]">无进场费
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="办公室配套" name="shangpu_tags[]">办公室配套 <input type="checkbox" class="roomTag" id="" value="办公室配套" name="shangpu_tags[]">办公室配套
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="5A景区游客量大" name="shangpu_tags[]">5A景区游客量大 <input type="checkbox" class="roomTag" id="" value="5A景区游客量大" name="shangpu_tags[]">5A景区游客量大
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="餐饮综合体" name="shangpu_tags[]">餐饮综合体 <input type="checkbox" class="roomTag" id="" value="餐饮综合体" name="shangpu_tags[]">餐饮综合体
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="强大案场阵容"name="shangpu_tags[]">强大案场阵容 <input type="checkbox" class="roomTag" id="" value="强大案场阵容"name="shangpu_tags[]">强大案场阵容
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="综合市场" name="shangpu_tags[]">综合市场 <input type="checkbox" class="roomTag" id="" value="综合市场" name="shangpu_tags[]">综合市场
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="超高佣金" name="shangpu_tags[]">超高佣金 <input type="checkbox" class="roomTag" id="" value="超高佣金" name="shangpu_tags[]">超高佣金
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="居民区十字路口" name="shangpu_tags[]">居民区十字路口 <input type="checkbox" class="roomTag" id="" value="居民区十字路口" name="shangpu_tags[]">居民区十字路口
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="写字楼底商"name="shangpu_tags[]">写字楼底商 <input type="checkbox" class="roomTag" id="" value="写字楼底商"name="shangpu_tags[]">写字楼底商
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="住宅配套" name="shangpu_tags[]">住宅配套 <input type="checkbox" class="roomTag" id="" value="住宅配套" name="shangpu_tags[]">住宅配套
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="沿街一单收佣9.5w" name="shangpu_tags[]">沿街一单收佣9.5w <input type="checkbox" class="roomTag" id="" value="沿街一单收佣9.5w" name="shangpu_tags[]">沿街一单收佣9.5w
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="黄兴路1750" name="shangpu_tags[]">黄兴路1750 <input type="checkbox" class="roomTag" id="" value="黄兴路1750" name="shangpu_tags[]">黄兴路1750
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="大学门口"name="shangpu_tags[]">大学门口 <input type="checkbox" class="roomTag" id="" value="大学门口"name="shangpu_tags[]">大学门口
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="广灵二路" name="shangpu_tags[]">广灵二路 <input type="checkbox" class="roomTag" id="" value="广灵二路" name="shangpu_tags[]">广灵二路
</label> </label>
<label class="checkbox-inline"> <label class="checkbox-inline">
<input type="checkbox" id="" value="40831" name="shangpu_tags[]">40831 <input type="checkbox" class="roomTag" id="" value="40831" name="shangpu_tags[]">40831
</label> </label>
</li> </li>
<li class="list-group-item"> <li class="list-group-item">
...@@ -521,7 +541,7 @@ ...@@ -521,7 +541,7 @@
<span class="tip"></span> <span class="tip"></span>
</div> </div>
</li> </li>
<li class="list-group-item"><button type="submit" class="btn btn-default">保存</button></li> <li class="list-group-item"><button type="submit" class="btn btn-default" id="saveBtn">保存</button></li>
</ul> </ul>
</form> </form>
</div> </div>
......
...@@ -5,7 +5,48 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -5,7 +5,48 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
user.event (); user.event ();
}, },
event: function () { event: function () {
var _doc = $(document); var _doc = $(document),
_shangpuTypeObj = $('#shangpuType'),//商铺类型
_showCdObj = $('#showCd'),//显示给C端用户看
_exclusiveTypeObj = $('#exclusiveType'),//是否独家
_exclusiveDate1Obj = $('#exclusiveDate1'),//独家代理有效期开始时间
_exclusiveDate2Obj = $('#exclusiveDate2'),//独家代理有效期结束时间
_exclusiveTelObj = $('#exclusiveTel'),//独家方电话
_internalNameObj = $('#internalName'),//对内商铺名称
_foreignNameObj = $('#foreignName'),//对外商铺名称
_zujinTypeObj = $('#zujinType'),//租金模式
_moonPriceObj = $('#moonPrice'),//月租均价
_wuyePriceObj = $('#wuyePrice'),//物业管理费
_jinchangPriceObj = $('#jinchangPrice'),//进场费
_roomShengyuNumObj = $('#roomShengyuNum'),//剩余铺数
_roomAllNumObj = $('#roomAllNum'),//总铺数
_roomArea1Obj = $('#roomArea1'),//商铺面积起始值
_roomArea2Obj = $('#roomArea2'),//商铺面积结束值
_businessAreaObj = $('#businessArea'),//商业面积
_yetaiObj = $('.yetai'),//业态
_provinceInternalObj = $('#province_internal'),//对内地址省
_cityInternalObj = $('#city_internal'),//对内地址市
_discInternalObj = $('#disc_internal'),//对内地址区
_addressInternalObj = $('#address_internal'),//对内地址详细地址
_longitudeObj = $('#longitude'),//经度
_latitudeObj = $('#latitude'),//纬度
_provinceExternalObj = $('#province_external'),//对外地址省
_cityExternalObj = $('#city_external'),//对外地址市
_discExternalObj = $('#disc_external'),//对外地址区
_addressExternalObj = $('#address_external'),//对外地址详细地址
_trafficObj = $('#traffic'),//交通
_hasMovedObj = $('#hasMoved'),//已入住
_yingyeTimeObj = $('#yingyeTime'),//营业时间
_kaipanTimeObj = $('#kaipanTime'),//开盘时间
_kaiyeTimeObj = $('#kaiyeTime'),//开业时间
_hasGasObj = $('#hasGas'),//是否有燃气
_weilouLinkObj = $('#weilouLink'),//微楼书
_dajiangtangObj = $('#dajiangtang'),//大讲堂
_yongjinRuleObj = $('#yongjinRule'),//佣金规则
_internalYoushiObj = $('#internalYoushi'),//对内项目优势
_foreignYoushiObj = $('#foreignYoushi'),//对外项目优势
_qianyueRuleObj = $('#qianyueRule'),//签约规则
_roomTagObj = $('.roomTag');//商铺标签
$ ('#liebiao_pic_btn').click (function () { $ ('#liebiao_pic_btn').click (function () {
BrowseServer ('liebiao_pic_pre'); BrowseServer ('liebiao_pic_pre');
}); });
...@@ -67,8 +108,8 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -67,8 +108,8 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
e.stopPropagation(); e.stopPropagation();
valueCurrent = $(this).val(); valueCurrent = $(this).val();
if(valueCurrent != '') { if(valueCurrent != '') {
resetLoad(); addressResetLoad();
loadMain(valueCurrent); addressLoadMain(valueCurrent);
} else { } else {
ulHtml.html(''); ulHtml.html('');
loadItem.hide(); loadItem.hide();
...@@ -78,10 +119,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -78,10 +119,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
}); });
//key搜索 //key搜索
$(document).keydown(function(event) { _doc.keydown(function(event) {
if(event.keyCode == '13') { if(event.keyCode == '13') {
resetLoad(); addressResetLoad();
loadMain(valueCurrent); addressLoadMain(valueCurrent);
return false; return false;
}; };
}); });
...@@ -91,10 +132,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -91,10 +132,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
e.preventDefault(); e.preventDefault();
e.stopPropagation(); e.stopPropagation();
_inputObj.val('').focus(); _inputObj.val('').focus();
resetLoad(); addressResetLoad();
}); });
$(document).on('click', '#main_ul>ul>li', function(e) { _doc.on('click', '#main_ul>ul>li', function(e) {
e.preventDefault(); e.preventDefault();
e.stopPropagation(); e.stopPropagation();
var _this = $(this); var _this = $(this);
...@@ -102,23 +143,24 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -102,23 +143,24 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
$('#latitude').val(Number(_this.data('lat'))); $('#latitude').val(Number(_this.data('lat')));
}); });
function resetLoad() { function addressResetLoad() {
ulHtml.html(''); ulHtml.html('');
loadItem.hide(); loadItem.hide();
noMoreItem.show(); noMoreItem.show();
}; };
function loadMain(keyword) { function addressLoadMain(keyword) {
loadItem.show(); loadItem.show();
noMoreItem.hide(); noMoreItem.hide();
LocalSearch.setLocation(cityLimitItem.html()); LocalSearch.setLocation(cityLimitItem.html());
LocalSearch.search(keyword); LocalSearch.search(keyword);
}; };
/************************************************百度地址定位相关*************************************************************/ /************************************************百度地址定位相关****结束*************************************************************/
/************省市区选择处理**************/
//自动获取省列表,并追加后面的市和区 //自动获取省列表,并追加后面的市和区
getCityDisc({ getCityDisc({
'isGetProvince': true 'getType': 'province'
},function(_data){ },function(_data){
var _htmlTemp = ''; var _htmlTemp = '';
$.each(_data, function(i, item) { $.each(_data, function(i, item) {
...@@ -127,25 +169,51 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -127,25 +169,51 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
'1': item['name'] '1': item['name']
}); });
}); });
$.each($('#province_internal, #province_external'), function() { _provinceInternalObj.html(_htmlTemp).val('310000');
var _this = $(this); getCityDisc({
_this.html(_htmlTemp).val('310000'); 'dom': _provinceInternalObj,
getCityDisc({ 'getType': 'city'
'dom': _this, }, function(){
'isGetProvince': false getCityDisc({
}, function(){ 'dom': _provinceInternalObj.next(),
getCityDisc({ 'getType': 'disc'
'dom': _this.next(),
'isGetProvince': false
});
}); });
}); });
}); });
//获取省市区输入时的真实值和所见值的对应
function getText(_domObj, fn){
var _arrTemp = _domObj.find('option');
if(_arrTemp.length > 0){
$.each(_arrTemp, function(i, item) {
var _item = $(item);
if(_item.val() == _domObj.val()){
fn(_item.html());
return false;//jq跳出当前循环
};
});
}else{
fn('');
};
};
function mapInput(){
getText(_provinceInternalObj, function(_text){
_provinceExternalObj.val(_text);
});
getText(_cityInternalObj, function(_text){
_cityExternalObj.val(_text);
});
getText(_discInternalObj, function(_text){
_discExternalObj.val(_text);
});
return false;
};
//获取省市区事件封装 //获取省市区事件封装
function getCityDisc(_obj, fn){ function getCityDisc(_obj, fn){
var _data = {}; var _data = {};
if(!_obj['isGetProvince']){ if(_obj['getType'] != 'province'){
if(!!_obj['dom'].val()){ if(!!_obj['dom'].val()){
_data['parent_code'] = Number(_obj['dom'].val()) _data['parent_code'] = Number(_obj['dom'].val())
}else{ }else{
...@@ -166,7 +234,7 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -166,7 +234,7 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
if(typeof data === 'object') { if(typeof data === 'object') {
if (data.code == 200) { if (data.code == 200) {
//如果是获取的省列表,直接直接返回数组 //如果是获取的省列表,直接直接返回数组
if(_obj['isGetProvince']){ if(_obj['getType'] == 'province'){
fn(data['data']); fn(data['data']);
return false; return false;
}; };
...@@ -178,6 +246,7 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -178,6 +246,7 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
}); });
}); });
_obj['dom'].next().html(_htmlTemp); _obj['dom'].next().html(_htmlTemp);
_obj['getType'] == 'disc' && mapInput();
fn && fn(); fn && fn();
}else { }else {
alert(data['msg']); alert(data['msg']);
...@@ -198,33 +267,37 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -198,33 +267,37 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
}; };
//省选择框事件添加 //省选择框事件添加
$('#province_internal, #province_external').change(function(){ _provinceInternalObj.change(function(){
var _this = $(this); var _this = $(this);
getCityDisc({ getCityDisc({
'dom': _this, 'dom': _this,
'isGetProvince': false 'getType': 'city'
}, function(){ }, function(){
getCityDisc({ getCityDisc({
'dom': _this.next(), 'dom': _this.next(),
'isGetProvince': false 'getType': 'disc'
}); });
}); });
}); });
//市选择框事件添加 //市选择框事件添加
$('#city_internal, #city_external').change(function(){ _cityInternalObj.change(function(){
var _this = $(this); var _this = $(this);
getCityDisc({ getCityDisc({
'dom': _this, 'dom': _this,
'isGetProvince': false 'getType': 'disc'
}); });
}); });
_discInternalObj.change(function(){
mapInput();
});
/***************************************************省市区选择处理结束************************************************************/
$('#acr_tel_jia').click(function(){ $('.input-add-tel').click(function(){
var _this = $(this); var _this = $(this);
console.log(_this.parent().find('.acqx_phone_jia').length); if(_this.parent().find('.phone_jia').length < 5){
if(_this.parent().find('.acqx_phone_jia').length < 5){ _this.before('<div class="form-group phone-list-container"><input type="tel" class="form-control phone_jia" placeholder="请输入"><ul></ul><img src="/resource/image/search_gb.png" class="input-cancel-pic" /></div>');
_this.before('<div class="form-group phone-list-container"><input type="tel" class="form-control acqx_phone_jia" placeholder="请输入"><ul></ul><img src="/resource/image/search_gb.png" class="input-cancel-pic" /></div>');
}else{ }else{
alert('最多添加5个'); alert('最多添加5个');
}; };
...@@ -240,14 +313,14 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -240,14 +313,14 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
_this.parent().html(''); _this.parent().html('');
}); });
var _ajaxObjAcr = null; var _ajaxObjTel = null;
_doc.on('input', '.acqx_phone_jia' ,function(){ _doc.on('input', '.phone_jia' ,function(){
var _this = $(this); var _this = $(this);
var _thisVal = $.trim(_this.val()); var _thisVal = $.trim(_this.val());
console.log(_thisVal); console.log(_thisVal);
if(_thisVal != ''){ if(_thisVal != ''){
_ajaxObjAcr && _ajaxObjAcr.abort(); _ajaxObjTel && _ajaxObjTel.abort();
_ajaxObjAcr = $.ajax({ _ajaxObjTel = $.ajax({
type: 'GET', type: 'GET',
url: '/index/getBroker_new', url: '/index/getBroker_new',
data: { data: {
...@@ -262,9 +335,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -262,9 +335,10 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
if(data['data'].length > 0){ if(data['data'].length > 0){
var _htmlTemp = ''; var _htmlTemp = '';
$.each(data['data'], function(i, item) { $.each(data['data'], function(i, item) {
_htmlTemp += '<li>{0}-{1}<li>'.stringFormatObj({ _htmlTemp += '<li>{2}{0}-{1}<li>'.stringFormatObj({
'0': item['name'], '0': item['name'],
'1': item['phone'] '1': item['phone'],
'2': _this.parent().nextAll('.input-add-tel').data('hideid')?'':(item['id']+'-')
}); });
}); });
_this.next().html(_htmlTemp); _this.next().html(_htmlTemp);
...@@ -289,6 +363,93 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi ...@@ -289,6 +363,93 @@ define (['css!style/home.css','ckfinder','ckfinderStart', 'bootstrapJs'], functi
}); });
}; };
}); });
/***************************************************电话号码输入相关交互处理***************************************************/
_exclusiveTypeObj.change(function(){
if($(this).val() == '1'){
$('#li_dujia_area').slideDown();
}else{
$('#li_dujia_area').slideUp();
}
});
$('#saveBtn').click(function(e){
e.preventDefault();
e.stopPropagation();
console.log('save');
// var _data = {
// 'internal_title': $.trim($('#internal_name').val())
// };
var _data = {
'shop_type': 0,
'is_show': 0,
'phone': ['张三-18812345678','李四-18812345678'],
'agent_dish': ['1-张三-18812345678','2-李四-18812345678'],
'agent_data': ['1-张三-18812345678','2-李四-18812345678'],
'internal_title': '对内名称',
'external_title': '对外名称',
'rent_type': 1,
'rent_price': 500,
'slotting_fee': 499,
'residue_num': 0,
'total': 5,
'shop_area_start': 20,
'shop_area_end': 30,
'market_area': 100,
'industry_type': '',
'province': '上海',
'city': '上海',
'disc': '黄浦',
'external_address': '某某街道对内',
'longitude': 121.312255,
'latitude': 30.737202,
'external_address': '某某街对外',
'traffic': '交通内容',
'enter_num': '已入住内容',
'do_business_date': '营业时间文本',
'start_business_date': '2017-10-12',
'is_has_gas': 0,
'tiny_brochure_url': 'http://www.dd',
'auditorium': '<p>大讲堂内容</p>',
'fee_rule': '佣金规则',
'internal_item_advantage': '项目优势对内',
'external_item_advantage': '项目优势对外',
'singn_rule': '签约规则'
};
$.ajax({
type: 'POST',
url: '/index/houseEdit',
data: _data,
timeout: 30000,
traditional: true,
dataType: 'json',
beforeSend: function() {},
success: function(data) {
if(typeof data === 'object') {
if (data.code == 200) {
}else {
alert(data['msg']);
};
}else{
alert('数据错误');
};
},
error: function() {
alert('error');
},
complete: function(xhr, textStatus){
if(textStatus === 'timeout'){
alert('请求超时');
};
}
});
});
} }
}; };
return user; return user;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment