Commit b92d5d21 authored by hujun's avatar hujun

Merge remote-tracking branch 'origin/0702-v.2.2.0' into 0702-v.2.2.0

parents ce93d946 9ae6f5e5
<?php
namespace app\api_broker\controller;
/**
* Created by PhpStorm.
* User: zhuwei
* Date: 2018/7/4
* Time: 下午3:25
*/
use app\api_broker\extend\Basic;
use app\model\ACollectHouse;
use think\Request;
class CollectHouse extends Basic
{
protected $aCollectHouse;
public function __construct($request = null)
{
parent::__construct($request);
$this->aCollectHouse = new ACollectHouse();
}
/**
* 收藏或取消收藏商铺
* User: 朱伟
* Date: 2018-07-04
* Time: 15:35:40
*/
public function addCollectHouse(){
$params = $this->params;
/*$params = array(
"agents_id" => 1,
"house_id" => 4,
"status" => 2,
);*/
if (!isset($params["agents_id"]) or !isset($params["house_id"]) or !isset($params["status"])) {
return $this->response("101", "请求参数错误");
}
//先判断是否已经存在数据
$field = 'id,status';
$get_params['agents_id'] = $params["agents_id"];
$get_params['house_id'] = $params["house_id"];
$res = $this->aCollectHouse->getCollectHouse($field,$get_params);
if($res){//如果存在
if($res[0]['status'] != $params["status"] ){//如果存在-并且状态一致 不作处理 不一致则更新状态
$insert["id"] = $res[0]['id'];
$insert["status"] = $params["status"];
$res = $this->aCollectHouse->updateCollectHouse($insert);//int(1)
}else{
$res = true ;
}
}else{//不存在则新增数据
$insert["agents_id"] = $params['agents_id'];
$insert["house_id"] = $params['house_id'];
$insert["status"] = 1;
$res = $this->aCollectHouse->saveCollectHouse($insert);//int(1)
}
if ($res) {
return $this->response("200", "成功");
} else {
return $this->response("101", "失败");
}
}
}
\ No newline at end of file
<?php
namespace app\api_broker\controller;
/**
* Created by PhpStorm.
* User: zhuwei
* Date: 2018/7/4
* Time: 下午3:25
*/
use app\api_broker\extend\Basic;
use app\model\ACollectUser;
use think\Request;
class CollectUser extends Basic
{
protected $aCollectUser;
public function __construct($request = null)
{
parent::__construct($request);
$this->aCollectUser = new ACollectUser();
}
/**
* 收藏或取消收藏客户
* User: 朱伟
* Date: 2018-07-04
* Time: 15:35:40
*/
public function addCollectUser()
{
$params = $this->params;
/*$params = array(
"agents_id" => 2,
"user_id" => 3,
"status" => 2,
);*/
if (!isset($params["agents_id"]) or !isset($params["user_id"]) or !isset($params["status"])) {
return $this->response("101", "请求参数错误");
}
//先判断是否已经存在数据
$field = 'id,status';
$get_params['agents_id'] = $params["agents_id"];
$get_params['user_id'] = $params["user_id"];
$res = $this->aCollectUser->getCollectUser($field,$get_params);
if($res){//如果存在
if($res[0]['status'] != $params["status"] ){//如果存在-并且状态一致 不作处理 不一致则更新状态
$insert["id"] = $res[0]['id'];
$insert["status"] = $params["status"];
$res = $this->aCollectUser->updateCollectUser($insert);//int(1)
}else{
$res = true ;
}
}else{//不存在则新增数据
$insert["agents_id"] = $params['agents_id'];
$insert["user_id"] = $params['user_id'];
$insert["status"] = 1;
$res = $this->aCollectUser->saveCollectUser($insert);//int(1)
}
if ($res) {
return $this->response("200", "成功");
} else {
return $this->response("101", "失败");
}
}
}
\ No newline at end of file
...@@ -333,7 +333,7 @@ class OrderLog extends Basic ...@@ -333,7 +333,7 @@ class OrderLog extends Basic
{ {
$params = $this->params; $params = $this->params;
/* $params = array( /* $params = array(
"order_id" => 2, "order_id" => 38024,
);*/ );*/
if (!isset($params["order_id"])) { if (!isset($params["order_id"])) {
return $this->response("101", "请求参数错误"); return $this->response("101", "请求参数错误");
......
...@@ -79,7 +79,7 @@ class OrderLogService ...@@ -79,7 +79,7 @@ class OrderLogService
if ($father_id > 0) { if ($father_id > 0) {
//保存图片 //保存图片
$oImgModel = new OImg(); $oImgModel = new OImg();
$oImgModel->addImgAll($father_id,2,$transfer_img); $oImgModel->addImgAll($father_id, 2, $transfer_img);
$pushMarchIn = new PushMessageService($params["report_id"], 2); $pushMarchIn = new PushMessageService($params["report_id"], 2);
$pushMarchIn->pushMarchInMessage($params["report_id"], 2); //推送 $pushMarchIn->pushMarchInMessage($params["report_id"], 2); //推送
...@@ -283,12 +283,12 @@ class OrderLogService ...@@ -283,12 +283,12 @@ class OrderLogService
} }
//收款 //收款
$field_pay_log = "id,order_no,order_id,agent_id,agent_name,type,pay_type,money,house_number,industry_type, $field_pay_log = "id,order_no,father_id,order_id,agent_id,agent_name,type,pay_type,money,house_number,industry_type,
remark,transfer_img,real_money,source,create_time"; remark,transfer_img,real_money,source,create_time";
$payLogData = $oPayLogModel->selectPayLogByOrderNo($field_pay_log, [ "order_id" => $order_id ]); $payLogData = $oPayLogModel->selectPayLogByOrderNo($field_pay_log, [ "order_id" => $order_id ]);
if (count($payLogData) > 0) { if (count($payLogData) > 0) {
foreach ($payLogData as $k => $v) { $sortPayLogData = $this->arr2tree($payLogData);
foreach ($sortPayLogData as $k => $v) {
$v["step_name"] = "pay_log"; $v["step_name"] = "pay_log";
$v["img_path"] = CHAT_IMG_URL; $v["img_path"] = CHAT_IMG_URL;
$result[$sort++] = $v; $result[$sort++] = $v;
...@@ -321,6 +321,33 @@ class OrderLogService ...@@ -321,6 +321,33 @@ class OrderLogService
return $this->sortByTime($result); return $this->sortByTime($result);
} }
public function arr2tree($list)
{
$tree = $trees = [];
foreach ($list as $key => $item) {
if ($item["father_id"] == 0) {
$list[$key]["father_id"] = $item["id"];
}
}
foreach ($list as $value) {
$tree[$value["father_id"]][] = $value;
}
foreach ($tree as $i => $v) {
//查询图片
$oImgModel = new OImg();
$params["img_id"] = $v[0]["father_id"];
$params["img_type"] = 2;
$img_arr = $oImgModel->getImgList($params);
$trees[$i]["img"] = $img_arr;
$trees[$i]["list"] = $v;
$trees[$i]["create_time"] = $v[0]["create_time"];
}
sort($trees);
return $trees;
}
/** /**
* 查询流程 客户动态 * 查询流程 客户动态
......
...@@ -32,11 +32,20 @@ ...@@ -32,11 +32,20 @@
<p v-if="item.step_name==='follow_up_log'">对面积的要求:<span>{{item.area_requirement}}</span></p> <p v-if="item.step_name==='follow_up_log'">对面积的要求:<span>{{item.area_requirement}}</span></p>
<p v-if="item.step_name==='follow_up_log'">对价格的要求:<span>{{item.price_requirement}}</span></p> <p v-if="item.step_name==='follow_up_log'">对价格的要求:<span>{{item.price_requirement}}</span></p>
<p v-if="item.step_name==='follow_up_log'">所在区域:<span>{{item.area_detail+' '+item.business_area}}</span></p> <p v-if="item.step_name==='follow_up_log'">所在区域:<span>{{item.area_detail+' '+item.business_area}}</span></p>
<p v-if="item.step_name==='pay_log'">入账类型:<span>{{switchRzType(item.type)}}</span></p> <div v-if="item.step_name==='pay_log'">
<p v-if="item.step_name==='pay_log'">支付方式:<span>{{switchPayType(item.pay_type)}}</span></p> <div class="sp-pay-log-div" v-for="(item2, idnex2) in item.list">
<p v-if="item.step_name==='pay_log'">入账金额:<span class="span-active">{{item.money}}元</span></p> <p>入账类型:<span>{{switchRzType(item2.type)}}</span></p>
<p>支付方式:<span>{{switchPayType(item2.pay_type)}}</span></p>
<p>入账金额:<span class="span-active">{{item2.money}}元</span></p>
</div>
</div>
<p v-if="item.step_name==='pay_log'">商铺号:<span class="span-active">{{item.house_number}}</span></p> <p v-if="item.step_name==='pay_log'">商铺号:<span class="span-active">{{item.house_number}}</span></p>
<p v-if="item.step_name==='pay_log'">业态/品牌:<span>{{item.industry_type}}</span></p> <p v-if="item.step_name==='pay_log'">业态/品牌:<span>{{item.industry_type}}</span></p>
<ol v-if="item.step_name==='pay_log'" class="li-img-list">
<li v-for="(item2, idnex2) in item.img">
<a href="javascript:;" data-id="item2.id"><img :src="item.img_path+item2.img_name"></a>
</li>
</ol>
<p v-if="item.step_name==='refund'">退款金额:<span class="span-active">{{item.refund_money}}元</span></p> <p v-if="item.step_name==='refund'">退款金额:<span class="span-active">{{item.refund_money}}元</span></p>
<p v-if="item.step_name==='refund'" class="yinhangka-info">退款银行卡信息</p> <p v-if="item.step_name==='refund'" class="yinhangka-info">退款银行卡信息</p>
<p v-if="item.step_name==='refund'">姓名:<span>{{item.agent_name}}</span></p> <p v-if="item.step_name==='refund'">姓名:<span>{{item.agent_name}}</span></p>
...@@ -75,3 +84,13 @@ ...@@ -75,3 +84,13 @@
</body> </body>
</html> </html>
<!--
report 报备
march_in 进场
follow_up_log 跟进
pay_log 收款
refund 退款
bargain 成交报告
-->
\ No newline at end of file
...@@ -168,9 +168,9 @@ class Collection extends Basic ...@@ -168,9 +168,9 @@ class Collection extends Basic
*/ */
public function receiptImgList(){ public function receiptImgList(){
$params = $this->params; $params = $this->params;
$params = array( /*$params = array(
"id" => 6, "id" => 6,
); );*/
if(!isset($params["id"])){ if(!isset($params["id"])){
return $this->response("101","请求参数错误"); return $this->response("101","请求参数错误");
......
...@@ -127,6 +127,53 @@ ...@@ -127,6 +127,53 @@
.delet-pic-btn{ .delet-pic-btn{
color:red; color:red;
} }
/*css样式*/
.img-cont{
width:1000px;
height:570px;
border:2px solid #317ef3;
margin:50px auto;
}
.img-cont>div{
width:300px;
height:260px;
border:1px solid #777;
float:left;
margin:20px 0 0 20px;
}
.img-cont>div>div{
width:300px;
height:220px;
border:1px solid red;
}
.img-cont>div>a{
width:60px;
height:30px;
border-radius:4px;
line-height: 30px;
text-align: center;
color:#fff;
display: block;
background: #317ef3;
margin:5px 0 0 0px;
cursor: pointer;
}
.hide{
display: none !important;
}
.result{
width: 600px;
}
.result>img{
width: 200px;
height: 200px;
}
/*css样式*/
</style> </style>
<div id="page-content-wrapper"> <div id="page-content-wrapper">
<div class="container"> <div class="container">
...@@ -258,10 +305,11 @@ ...@@ -258,10 +305,11 @@
<li class="list-group-item"> <li class="list-group-item">
<div class="form-group full-width-100 full-pic-area"> <div class="form-group full-width-100 full-pic-area">
<!--<label for="">详情页轮播图(至少4张)</label>--> <!--input上传图片-->
<input readonly="readonly" type="text" name="xiangqing_pic_input" class="form-control" style="display: none" id="xiangqing_pic_input" placeholder="请选择图片"> <div id="container_body">
<button class="btn btn-default upload-image-btn" id="xiangqing_pic_btn" type="button" data-limittop="20">上传图片</button> <label>请选择一个图像文件:</label>
<span class="tip"></span> <input type="file" id="file_input"/>
</div>
</div> </div>
<ul class="img-pre-ul" id="xiangqing_pic_ul"> <ul class="img-pre-ul" id="xiangqing_pic_ul">
</ul> </ul>
......
...@@ -119,8 +119,7 @@ ...@@ -119,8 +119,7 @@
</select> <br /> </select> <br />
<span>商铺号:</span><span id="bargaininfo_shop_num"></span><br> <span>商铺号:</span><span id="bargaininfo_shop_num"></span><br>
<!--<span>预计收款时间:</span><span id="bargaininfo_expect_payback_time"></span><br>--> <!--<span>预计收款时间:</span><span id="bargaininfo_expect_payback_time"></span><br>-->
<span>预计收款时间:</span><input type="date" id="bargaininfo_expect_payback_time" placeholder="请输入"> <span>预计收款时间:</span><input type="date" id="bargaininfo_expect_payback_time" placeholder="请输入"><br>
<br>
<span>客户电话:</span><span id="bargaininfo_user_phone"></span><br> <span>客户电话:</span><span id="bargaininfo_user_phone"></span><br>
<span>成交日期:</span><span id="bargaininfo_create_time"></span><br> <span>成交日期:</span><span id="bargaininfo_create_time"></span><br>
<span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" type="number"> <span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" type="number">
......
...@@ -150,6 +150,7 @@ ...@@ -150,6 +150,7 @@
</select> <br /> </select> <br />
<span>商铺号:</span><span id="bargaininfo_shop_num"></span><br> <span>商铺号:</span><span id="bargaininfo_shop_num"></span><br>
<span>客户电话:</span><span id="bargaininfo_user_phone"></span><br> <span>客户电话:</span><span id="bargaininfo_user_phone"></span><br>
<span>预计收款时间:</span><input type="date" id="bargaininfo_expect_payback_time" readonly="readonly" placeholder="请输入"><br>
<span>成交日期:</span><span id="bargaininfo_create_time"></span><br> <span>成交日期:</span><span id="bargaininfo_create_time"></span><br>
<span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" disabled="disabled" type="number"> <span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" disabled="disabled" type="number">
</div> </div>
......
...@@ -150,6 +150,7 @@ ...@@ -150,6 +150,7 @@
</select> <br /> </select> <br />
<span>商铺号:</span><span id="bargaininfo_shop_num"></span><br> <span>商铺号:</span><span id="bargaininfo_shop_num"></span><br>
<span>客户电话:</span><span id="bargaininfo_user_phone"></span><br> <span>客户电话:</span><span id="bargaininfo_user_phone"></span><br>
<span>预计收款时间:</span><input type="date" id="bargaininfo_expect_payback_time" readonly="readonly" placeholder="请输入"><br>
<span>成交日期:</span><span id="bargaininfo_create_time"></span><br> <span>成交日期:</span><span id="bargaininfo_create_time"></span><br>
<span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" disabled="disabled" type="number"> <span>成交价:</span>&nbsp;<input class="form-control" id="bargaininfo_chengjiao_price" disabled="disabled" type="number">
</div> </div>
......
...@@ -462,3 +462,6 @@ ...@@ -462,3 +462,6 @@
</div> </div>
<!-- /.modal --> <!-- /.modal -->
</div> </div>
<div id="img_mask_area" title="点击任意位置可关闭">
<img />
</div>
\ No newline at end of file
...@@ -519,3 +519,6 @@ ...@@ -519,3 +519,6 @@
</div> </div>
<!-- /.modal --> <!-- /.modal -->
</div> </div>
<div id="img_mask_area" title="点击任意位置可关闭">
<img />
</div>
\ No newline at end of file
<?php
namespace app\model;
use think\Db;
use think\Model;
class ACollectHouse extends Model
{
// 设置当前模型对应的完整数据表名称
protected $table = 'a_collect_house';
public function saveCollectHouse($data) {
$time = date("Y-m-d h:i:sa", time());
$data['create_time'] = $time;
$data['update_time'] = $time;
return $this->insert($data);
}
/**
* 查询数据
* 朱伟 2018-07-04
*/
public function getCollectHouse($field,$params)
{
$result = Db::table($this->table)
->field($field)
//->alias('a')
->where($params)
->select();
//dump($this->getLastSql());
return $result;
}
/**
* 更新数据
* 朱伟 2018-07-04
*/
public function updateCollectHouse($params)
{
$result = $this->update($params);
//dump($this->getLastSql());
return $result;
}
}
<?php
namespace app\model;
use think\Db;
use think\Model;
class ACollectUser extends Model
{
// 设置当前模型对应的完整数据表名称
protected $table = 'a_collect_user';
public function saveCollectUser($data) {
$time = date("Y-m-d h:i:sa", time());
$data['create_time'] = $time;
$data['update_time'] = $time;
return $this->insert($data);
}
/**
* 查询数据
* 朱伟 2018-07-04
*/
public function getCollectUser($field,$params)
{
$result = Db::table($this->table)
->field($field)
//->alias('a')
->where($params)
->select();
//dump($this->getLastSql());
return $result;
}
/**
* 更新数据
* 朱伟 2018-07-04
*/
public function updateCollectUser($params)
{
$result = $this->update($params);
//dump($this->getLastSql());
return $result;
}
}
...@@ -104,7 +104,7 @@ class OImg extends BaseModel ...@@ -104,7 +104,7 @@ class OImg extends BaseModel
* @param string $field * @param string $field
* @return false|\PDOStatement|string|\think\Collection * @return false|\PDOStatement|string|\think\Collection
*/ */
public function getImgList(array $params, string $field = "id") public function getImgList(array $params, string $field = "id,img_name")
{ {
if (isset($params["img_id"])) { if (isset($params["img_id"])) {
$where_["img_id"] = $params["img_id"]; $where_["img_id"] = $params["img_id"];
...@@ -114,13 +114,12 @@ class OImg extends BaseModel ...@@ -114,13 +114,12 @@ class OImg extends BaseModel
} }
$where_["img_status"] = 0; $where_["img_status"] = 0;
$res = $this $data = $this->db_
->field($field) ->field($field)
->where($where_) ->where($where_)
->select(); ->select();
//var_dump($this->getLastSql()); // echo $this->getLastSql();
return $res; return $data;
} }
/** /**
......
...@@ -501,6 +501,9 @@ Route::group('broker', [ ...@@ -501,6 +501,9 @@ Route::group('broker', [
'getComment' => [ 'api_broker/news/getComment', [ 'method' => 'GET' ] ], //商学院评论列表 'getComment' => [ 'api_broker/news/getComment', [ 'method' => 'GET' ] ], //商学院评论列表
'commentNews' => [ 'api_broker/news/commentNews', [ 'method' => 'POST' ] ], //评论商学院文章 'commentNews' => [ 'api_broker/news/commentNews', [ 'method' => 'POST' ] ], //评论商学院文章
'addCollectUser' => [ 'api_broker/CollectUser/addCollectUser', [ 'method' => 'POST|GET' ] ], //监督执行列表 朱伟 2018-06-15
'addCollectHouse' => [ 'api_broker/CollectHouse/addCollectHouse', [ 'method' => 'POST|GET' ] ], //新增-监督执行 朱伟 2018-06-20
]); ]);
......
...@@ -130,3 +130,7 @@ body{ ...@@ -130,3 +130,7 @@ body{
#main_list>li.main-li-first>.main-area>.right-area>h6{ #main_list>li.main-li-first>.main-area>.right-area>h6{
color: #ff9419; color: #ff9419;
} }
.sp-pay-log-div+.sp-pay-log-div{
padding-top: .3rem;
}
<template> <template>
<li @click="goPage"> <li>
<div class="flex"> <div class="flex">
<div class="flex"> <div class="flex">
<p>{{data.content}}</p>
<p>{{data.time}}</p>
</div>
<div class="flex-center">
<img-error :datasrc="data.img" :imgtype="'avatar'"></img-error> <img-error :datasrc="data.img" :imgtype="'avatar'"></img-error>
</div> </div>
<div>
<p>{{data.name}}</p>
<p>{{data.create_time}}</p>
<div>
<p>{{showContent}}</p>
<a class="comment-a-lookmore oh" href="javascript:;" @click="lookMore" v-show="!isLookMore"><span class="fl">查看更多</span></a>
<a class="comment-a-shouqi oh" href="javascript:;" @click="shouqi" v-show="isLookMore"><span>收起</span></a>
</div>
</div>
</div> </div>
</li> </li>
</template> </template>
...@@ -32,25 +37,31 @@ ...@@ -32,25 +37,31 @@
}, },
data: () => ({ data: () => ({
dealContent: '',
showContent: '',
isLookMore: false,
limitNumberNum: 40
}), }),
created() { created() {
let _this = this; let _this = this;
let _str = _this.data.comment_content;
let _len = _str.length;
let _lim = _this.limitNumberNum;
_this.showContent = _this.dealContent = _len>_lim ? _str.slice(0,_lim)+'...' : _str;
}, },
mounted() { mounted() {
let _this = this; let _this = this;
}, },
methods: { methods: {
goPage() { lookMore() {
let _this = this; let _this = this;
_this.$router.push({ _this.isLookMore = true;
path: '/articleDetail', _this.showContent = _this.data.comment_content;
query: { },
'id': '123' shouqi() {
} let _this = this;
}); _this.isLookMore = false;
_this.showContent = _this.dealContent;
} }
}, },
computed: { computed: {
...@@ -60,34 +71,63 @@ ...@@ -60,34 +71,63 @@
</script> </script>
<style scoped> <style scoped>
li{
padding: 0 .3rem;
background-color: white;
}
li>div{ li>div{
height: 2.2rem; padding: .3rem 0;
border-bottom: 1px solid #eee;
} }
li>div>div:nth-of-type(1){ li>div>div:nth-of-type(1){
flex-direction: column; padding-right: .24rem;
justify-content: center; }
padding-right: .5rem; li>div>div:nth-of-type(1)>img{
width: .75rem;
height: .75rem;
border-radius: .375rem;
} }
li>div>div:nth-of-type(1)>p:nth-of-type(1){ li>div>div:nth-of-type(2){}
color: #343434; li>div>div:nth-of-type(2)>p:nth-of-type(1){
color: #808080;
font-size: .3rem; font-size: .3rem;
} }
li>div>div:nth-of-type(1)>p:nth-of-type(2){ li>div>div:nth-of-type(2)>p:nth-of-type(2){
color: #999; color: #808080;
font-size: .24rem; font-size: .24rem;
padding-top: .2rem; padding-top: .1rem;
} }
li>div>div:nth-of-type(2){ li>div>div:nth-of-type(2)>div{
padding: .2rem 0 .2rem;
color: #1a1a1a;
position: relative;
}
.comment-a-lookmore,.comment-a-shouqi{
display: block;
line-height: .4rem;
color: #FF9419;
font-size: .26rem;
position: relative;
} }
li>div>div:nth-of-type(2)>img{ .comment-a-lookmore{
width: 2.2rem; width: 1.4rem;
height: 1.6rem; position: absolute;
object-fit: cover; right: 0;
bottom: .2rem;
} }
.comment-a-shouqi{
text-align: right;
}
.comment-a-lookmore::after{
content: '';
float: right;
width: .18rem;
height: .4rem;
padding-left: .18rem;
background: url(images/icon_down@2x.png) no-repeat center center/.18rem .13rem;
transform: rotate(180deg);
}
.comment-a-shouqi::after{
content: '';
width: .18rem;
height: .4rem;
padding-left: .36rem;
background: url(images/icon_down@2x.png) no-repeat center center/.18rem .13rem;
}
</style> </style>
\ No newline at end of file
...@@ -2,55 +2,36 @@ ...@@ -2,55 +2,36 @@
<div> <div>
<header-pulic :data="headerData"></header-pulic> <header-pulic :data="headerData"></header-pulic>
<article> <article>
<p>示例文字示例文字示例文字</p> <div class="article-bar">
<p>示例文字示例文字示例文字</p> <h1>{{articleTitle}}</h1>
<p>示例文字示例文字示例文字</p> <p>{{articleTime}}</p>
<p>示例文字示例文字示例文字</p> </div>
<p>示例文字示例文字示例文字</p> <div v-html="articleContent">{{articleContent}}</div>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
<p>示例文字示例文字示例文字</p>
</article> </article>
<div class="list-commnet-area"> <div class="list-commnet-area">
<h2>最新评论</h2> <h2>最新评论</h2>
<pagination-load :canload="!isStop" :distance="10" @load="getCommentList">
<ul> <ul>
<!--<li is="self-defined-li" v-for="(item2, index2) in item.dataList" :data="item2" :dataindex="index2"></li>--> <li is="self-defined-li" v-for="(item, index) in commentDataList" :data="item" :dataindex="index"></li>
</ul> </ul>
</pagination-load>
<div class="loading-gif-block" v-show="isLoading">正在加载...</div>
<div class="no-data-block" v-if="noDataFlag">暂无数据</div>
<div class="no-more-block" v-if="!noDataFlag&&isStop">没有更多了...</div>
</div> </div>
<div class="comment-area-seat"></div>
<div class="txt-comment-area" v-show="isCommentingFlag"> <div class="txt-comment-area" v-show="isCommentingFlag">
<div> <div class="mask-comment-area" @click="isCommentingFlag = false"></div>
<div class="real-comment-area">
<div class="flex-center"> <div class="flex-center">
<textarea v-model="commentContent"></textarea> <textarea v-model="commentContent"></textarea>
</div> </div>
<div class="oh"> <div class="oh">
<a class="fl flex-center" href="javascript:;" @click="isCommentingFlag = false">取消</a> <a class="fl flex-center" href="javascript:;" @click="isCommentingFlag = false">取消</a>
<a class="fr flex-center" href="javascript:;" @click="commentSend">发送</a> <a class="fr flex-center" href="javascript:;" @click="commentSend" v-show="!isSending">发送</a>
<a class="fr flex-center" href="javascript:;" v-show="isSending">发送ing</a>
</div> </div>
</div> </div>
</div> </div>
...@@ -83,23 +64,76 @@ ...@@ -83,23 +64,76 @@
'pagination-load': paginationLoad, 'pagination-load': paginationLoad,
'self-defined-li': selfDefinedLi 'self-defined-li': selfDefinedLi
}, },
data: () => ({ data() {
let _this = this;
return {
headerData: { headerData: {
'title': '文章详情', 'title': '文章详情',
'noborder': false, 'noborder': false,
'isBack': true 'isBack': true
}, },
articleId: _this.$route.query.id,
token: localStorage.getItem('token'),
articleTitle: '',
articleTime: '',
articleContent: '',
commentIcon, commentIcon,
isCommentingFlag: false, isCommentingFlag: false,//是否正在写评论
commentContent: '' commentContent: '',//评论的内容
}), isSending: false,//是否正在提交评论
isStop: false,
isLoading: false,
noDataFlag: false,
pageSize: 10,
page: 1,
commentDataList: []
};
},
created() { created() {
let _this = this; let _this = this;
_this.common.duringRequest({
'urlStr': '/broker/getComment',
startAction() {
_this.isLoading = true;
}, },
mounted() { endAction() {
let _this = this; _this.isLoading = false;
}
},{
'urlStr': '/broker/commentNews',
startAction() {
_this.isSending = true;
},
endAction() {
_this.isSending = false;
}
});
_this.axios({
method: 'get',
url: '/broker/getNewsInfo',
responseType: 'json',
data: {
'id': _this.articleId,
'AuthToken': _this.token
}
})
.then(function(response) {
if(response.data.code == 200) {
let _news = response.data.data.news;
_this.articleTitle = _news.title;
_this.articleTime = _news.create_time;
_this.articleContent = _news.content;
} else {
layer.tipsX(response.data.msg);
}
})
.catch(function(error) {
layer.tipsX(error);
});
//获取评论列表
_this.getCommentList();
}, },
methods: { methods: {
commentSend() { commentSend() {
...@@ -108,8 +142,70 @@ ...@@ -108,8 +142,70 @@
if(_len<100 || _len>500){ if(_len<100 || _len>500){
layer.tipsX('评论字数需在100~500之间,当前字数为'+_len); layer.tipsX('评论字数需在100~500之间,当前字数为'+_len);
}else{ }else{
_this.axios({
method: 'POST',
url: '/broker/commentNews',
responseType: 'json',
data: {
'content': _this.commentContent,
'news_id': _this.articleId,
'AuthToken': _this.token
}
})
.then(function(response) {
if(response.data.code == 200) {
_this.resetCommentList();
_this.getCommentList();
_this.isCommentingFlag = false; _this.isCommentingFlag = false;
} else {
layer.tipsX(response.data.msg);
}
})
.catch(function(error) {
layer.tipsX(error);
});
}
},
getCommentList() {
let _this = this;
_this.axios({
method: 'get',
url: '/broker/getComment',
responseType: 'json',
data: {
'pageNo': _this.page,
'pageSize': _this.pageSize,
'news_id': _this.articleId,
'AuthToken': _this.token
} }
})
.then(function(response) {
if(response.data.code == 200) {
let _list = response.data.data;
if(Array.isArray(_list)){
if(_list.length === 0) {
_this.page === 1 && (_this.noDataFlag = true);
_this.isStop = true;
} else {
_this.commentDataList.push(..._list); //这里使用push要注意,先把数组展开
_list.length < _this.pageSize && (_this.isStop = true);
_this.page++;
};
};
} else {
layer.tipsX(response.data.msg);
}
})
.catch(function(error) {
layer.tipsX(error);
});
},
resetCommentList() {
//重置评论列表的内容
let _this = this;
_this.commentDataList = [];
_this.page = 1;
_this.noDataFlag = false;
} }
}, },
computed: { computed: {
...@@ -119,6 +215,36 @@ ...@@ -119,6 +215,36 @@
</script> </script>
<style scoped> <style scoped>
article,.list-commnet-area{
background-color: white;
padding: .3rem;
}
article{
}
.article-bar>h1{
font-size: .4rem;
color: #1a1a1a;
}
.article-bar>p{
font-size: .3rem;
color: #999;
}
.article-bar+div{
padding-top: .3rem;
}
.list-commnet-area{
margin-top: .2rem;
}
.list-commnet-area>h2{
font-size: .32rem;
color: #1a1a1a;
}
.comment-area-seat{
height: .98rem;
}
.btn-comment-area{ .btn-comment-area{
position: fixed; position: fixed;
bottom: 0; bottom: 0;
...@@ -148,7 +274,11 @@ ...@@ -148,7 +274,11 @@
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.txt-comment-area>div{ .mask-comment-area{
width: 100%;
height: 100%;
}
.real-comment-area{
position: fixed; position: fixed;
left: 0; left: 0;
bottom: 0; bottom: 0;
...@@ -156,20 +286,20 @@ ...@@ -156,20 +286,20 @@
height: 2.6rem; height: 2.6rem;
background-color: #f4f4f4; background-color: #f4f4f4;
} }
.txt-comment-area>div>div:nth-of-type(1){ .real-comment-area>div:nth-of-type(1){
height: 1.8rem; height: 1.8rem;
} }
.txt-comment-area>div>div:nth-of-type(1)>textarea{ .real-comment-area>div:nth-of-type(1)>textarea{
width: 6.86rem; width: 6.86rem;
height: 1.4rem; height: 1.4rem;
border: #1px solid #e0e0e0; border: #1px solid #e0e0e0;
border-radius: .1rem; border-radius: .1rem;
background-color: white; background-color: white;
} }
.txt-comment-area>div>div:nth-of-type(2){ .real-comment-area>div:nth-of-type(2){
padding: 0 .3rem; padding: 0 .3rem;
} }
.txt-comment-area>div>div:nth-of-type(2)>a{ .real-comment-area>div:nth-of-type(2)>a{
box-sizing: border-box; box-sizing: border-box;
width: 1.2rem; width: 1.2rem;
height: .6rem; height: .6rem;
...@@ -178,8 +308,12 @@ ...@@ -178,8 +308,12 @@
color: #999; color: #999;
border: 1px solid #e0e0e0; border: 1px solid #e0e0e0;
} }
.txt-comment-area>div>div:nth-of-type(2)>a:nth-of-type(2){ .real-comment-area>div:nth-of-type(2)>a:nth-of-type(2){
background-color: #FA903F; background-color: #FA903F;
color: white; color: white;
} }
.real-comment-area>div:nth-of-type(2)>a:nth-of-type(3){
background-color: #999;
color: white;
}
</style> </style>
\ No newline at end of file
...@@ -3,24 +3,25 @@ ...@@ -3,24 +3,25 @@
<header-pulic :data="headerData"></header-pulic> <header-pulic :data="headerData"></header-pulic>
<nav> <nav>
<div class="nav-main"> <div class="nav-main">
<ul :style="'width: '+ulWid+'rem'"> <ul class="oh" :style="'width: '+ulWid+'rem'">
<li v-for="(item, index) in mainData" :key="item.labelName" :data-id="item.id" :class="{active:index === initTabNumMain}" @click="tabMain(index)">{{item.labelName}}</li> <li v-for="(item, index) in mainData" :key="item.labelName" :data-id="item.id" class="pointer-click-item" :class="{active:index === initTabNumMain}" @click="tabMain(index)">{{item.labelName}}</li>
</ul> </ul>
<div class="nav-bg-right"></div>
</div> </div>
<div class="nav-seat"></div> <div class="nav-seat"></div>
</nav> </nav>
<main> <main>
<section v-for="(item, index) in mainData"> <section v-for="(item, index) in mainData" v-show="index === initTabNumMain">
<pagination-load :canload="!isStop" :distance="10" @load="getLoad"> <pagination-load :canload="!item.isStop" :distance="30" @load="getList">
<ul> <ul>
<li is="self-defined-li" v-for="(item2, index2) in item.dataList" :data="item2" :dataindex="index2"></li> <li is="self-defined-li" v-for="(item2, index2) in item.dataList" :data="item2" :dataindex="index2"></li>
</ul> </ul>
</pagination-load> </pagination-load>
<div class="no-data-block" v-if="noDataFlag">暂无数据</div> <div class="no-data-block" v-show="item.noDataFlag">暂无数据</div>
<div class="no-more-block" v-if="!noDataFlag&&isStop">没有更多了...</div> <div class="no-more-block" v-show="!item.noDataFlag&&item.isStop">没有更多了...</div>
<div class="loading-gif-block" v-show="isLoading">正在加载...</div>
</section> </section>
</main> </main>
<div class="loading-gif-block" v-show="isLoading">正在加载...</div>
</div> </div>
</template> </template>
...@@ -46,31 +47,67 @@ ...@@ -46,31 +47,67 @@
'pagination-load': paginationLoad, 'pagination-load': paginationLoad,
'self-defined-li': selfDefinedLi 'self-defined-li': selfDefinedLi
}, },
data: () => ({ data() {
let _this = this;
let _token = _this.$route.query.token;
if(!_token) {
layer.tipsX('token获取出错');
return false;
};
return {
headerData: { headerData: {
'title': '商学院', 'title': '商学院',
'noborder': true, 'noborder': true,
'isBack': false 'isBack': false
}, },
token: _token,
ulWid: 6.9, ulWid: 6.9,
pageSize: 10,
initTabNumMain: 0, initTabNumMain: 0,
isStop: false, isLoading: false,//是否正在加载
isLoading: false, mainData: [{
noDataFlag: false, 'dataList': [],
mainData: [] 'id': 0,
}), 'page': 1,//页码
'isLoadOnce': false,//是否请求过一次数据
'isStop': false,//是否所有页的数据加载完毕
'noDataFlag': false,//是否是无数据
'labelName': '全部'
}]
}
},
created() { created() {
let _this = this; let _this = this;
_this.getLabel(()=>{
console.log(99); _this.common.duringRequest({
_this.getPageList(); 'urlStr': '/broker/business_school',
}) startAction() {
_this.isLoading = true;
}, },
mounted() { endAction() {
let _this = this; _this.isLoading = false;
}
});
_this.common.h5PageC(_this.token, () => {
_this.loadMain();
});
}, },
methods: { methods: {
loadMain() {
let _this = this;
_this.token = localStorage.getItem('token');
_this.getLabel(()=>{
_this.getList();
});
},
tabMain(index) {
let _this = this;
_this.initTabNumMain = index;
if(!_this.mainData[index].isLoadOnce) {
_this.getList();
};
},
getLabel(fn) { getLabel(fn) {
let _this = this; let _this = this;
_this.axios({ _this.axios({
...@@ -78,7 +115,7 @@ ...@@ -78,7 +115,7 @@
url: '/broker/getNewsLabel', url: '/broker/getNewsLabel',
responseType: 'json', responseType: 'json',
data: { data: {
'AuthToken': _this.$route.query.token, 'AuthToken': _this.token,
} }
}) })
.then(function(response) { .then(function(response) {
...@@ -87,12 +124,17 @@ ...@@ -87,12 +124,17 @@
let _len = _data.length; let _len = _data.length;
for(let i = 0;i<_len;i++){ for(let i = 0;i<_len;i++){
_this.mainData.push({ _this.mainData.push({
'isLoadOnce': false,
'dataList': [], 'dataList': [],
'id': _data[i].id, 'id': _data[i].id,
'page': 1,//页码
'isLoadOnce': false,//是否请求过一次数据
'isStop': false,//是否所有页的数据加载完毕
'noDataFlag': false,//是否是无数据
'labelName': _data[i].label_name 'labelName': _data[i].label_name
}); });
}; };
_this.ulWid = (_len*1.6>_this.ulWid)?(_len*1.6):_this.ulWid; _this.ulWid = ((_len+1)*1.6>_this.ulWid)?((_len+1)*1.6):_this.ulWid;
fn && fn(); fn && fn();
} else { } else {
layer.tipsX(response.data.msg); layer.tipsX(response.data.msg);
...@@ -102,23 +144,35 @@ ...@@ -102,23 +144,35 @@
layer.tipsX(error); layer.tipsX(error);
}); });
}, },
getPageList() { getList() {
let _this = this; let _this = this;
let _index = _this.initTabNumMain;
if(!_this.isLoading && !_this.mainData[_index].isStop) {
_this.axios({ _this.axios({
method: 'get', method: 'get',
//url: '/broker/business_school', url: '/broker/business_school',
url: 'http://c.tonglianjituan.com/broker/business_school',
responseType: 'json', responseType: 'json',
data: { data: {
'AuthToken': _this.$route.query.token, 'AuthToken': _this.token,
'pageNo': 1, 'pageNo': _this.mainData[_index].page,
'pageSize': 1000 'pageSize': _this.pageSize,
'label_id': _index
} }
}) })
.then(function(response) { .then(function(response) {
_this.mainData[_index].isLoadOnce = true;
if(response.data.code == 200) { if(response.data.code == 200) {
let _data = response.data.data; let _list = response.data.data.list;
if(Array.isArray(_list)){
if(_list.length === 0) {
_this.mainData[_index].page === 1 && (_this.mainData[_index].noDataFlag = true);
_this.mainData[_index].isStop = true;
} else {
_this.mainData[_index].dataList.push(..._list); //这里使用push要注意,先把数组展开
_list.length < _this.pageSize && (_this.mainData[_index].isStop = true);
_this.mainData[_index].page += 1;
};
};
} else { } else {
layer.tipsX(response.data.msg); layer.tipsX(response.data.msg);
} }
...@@ -126,12 +180,7 @@ ...@@ -126,12 +180,7 @@
.catch(function(error) { .catch(function(error) {
layer.tipsX(error); layer.tipsX(error);
}); });
}, };
tabMain() {
},
getLoad() {
} }
}, },
computed: { computed: {
...@@ -145,9 +194,8 @@ ...@@ -145,9 +194,8 @@
width: 7.5rem; width: 7.5rem;
} }
nav>.nav-main { nav>.nav-main {
box-sizing: border-box;
background-color: white; background-color: white;
width: 7.5rem; width: 6.9rem;
height: .9rem; height: .9rem;
line-height: .9rem; line-height: .9rem;
padding: 0 .3rem; padding: 0 .3rem;
...@@ -160,6 +208,14 @@ ...@@ -160,6 +208,14 @@
nav>.nav-main>ul{ nav>.nav-main>ul{
/*width: 10rem;*/ /*width: 10rem;*/
} }
nav>.nav-main>.nav-bg-right{
position: fixed;
right: 0;
top: .88rem;
width: .8rem;
height: .9rem;
background: url(images/img_more@2x.png) repeat-y center center/.8rem .27rem;
}
nav>.nav-seat { nav>.nav-seat {
height: .9rem; height: .9rem;
} }
......
...@@ -2,11 +2,11 @@ ...@@ -2,11 +2,11 @@
<li @click="goPage"> <li @click="goPage">
<div class="flex"> <div class="flex">
<div class="flex"> <div class="flex">
<p>{{data.content}}</p> <p>{{data.title}}</p>
<p>{{data.time}}</p> <p>{{data.create_time}}</p>
</div> </div>
<div class="flex-center"> <div class="flex-center">
<img-error :datasrc="data.img" :imgtype="'avatar'"></img-error> <img-error :datasrc="data.cover_plan" :imgtype="'div'"></img-error>
</div> </div>
</div> </div>
</li> </li>
...@@ -48,7 +48,7 @@ ...@@ -48,7 +48,7 @@
_this.$router.push({ _this.$router.push({
path: '/articleDetail', path: '/articleDetail',
query: { query: {
'id': '123' 'id': _this.data.id
} }
}); });
} }
...@@ -72,6 +72,7 @@ ...@@ -72,6 +72,7 @@
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
padding-right: .5rem; padding-right: .5rem;
flex: 1;
} }
li>div>div:nth-of-type(1)>p:nth-of-type(1){ li>div>div:nth-of-type(1)>p:nth-of-type(1){
color: #343434; color: #343434;
...@@ -83,7 +84,7 @@ ...@@ -83,7 +84,7 @@
padding-top: .2rem; padding-top: .2rem;
} }
li>div>div:nth-of-type(2){ li>div>div:nth-of-type(2){
flex: 2.2rem 0 0;
} }
li>div>div:nth-of-type(2)>img{ li>div>div:nth-of-type(2)>img{
width: 2.2rem; width: 2.2rem;
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
}, },
imgtype: { imgtype: {
type: String, type: String,
default: () => 'avatar' default: () => 'div'
} }
}, },
data() { data() {
......
...@@ -472,6 +472,7 @@ define(['doT', 'text!temp/commission_template_tpl.html', 'text!temp/reportList_s ...@@ -472,6 +472,7 @@ define(['doT', 'text!temp/commission_template_tpl.html', 'text!temp/reportList_s
$("#bargaininfo_type").val(data.data.trade_type); $("#bargaininfo_type").val(data.data.trade_type);
$("#bargaininfo_total_commission").val(data.data.commission); $("#bargaininfo_total_commission").val(data.data.commission);
$("#bargaininfo_create_time").html(data.data.create_time); $("#bargaininfo_create_time").html(data.data.create_time);
$("#bargaininfo_expect_payback_time").val(data.data.estimated_receipt_date);
$("#bargaininfo_yetai").val(data.data.industry_type); $("#bargaininfo_yetai").val(data.data.industry_type);
$("#bargaininfo_chengjiao_price").val(data.data.price); $("#bargaininfo_chengjiao_price").val(data.data.price);
......
define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css', 'ckfinder', 'ckfinderStart', 'pagination', 'bootstrapJs'], function(doT, template) { define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css', 'ckfinder', 'ckfinderStart', 'pagination', 'bootstrapJs'], function(doT, template) {
follow = { follow = {
pageNo: 1, pageNo: 1,
...@@ -12,37 +11,68 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -12,37 +11,68 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
ajaxObj: '', ajaxObj: '',
stopstatus: true, stopstatus: true,
boxphoto: '', boxphoto: '',
image_file: '',
init: function() { init: function() {
//初始化dot //初始化dot
$(document.body).append(template); $(document.body).append(template);
follow.getList(0); follow.getList(0);
follow.event(); follow.event();
}, },
event: function() { event: function() {
var _doc = $(document); var _doc = $(document);
var _imgMaskObj = $('#img_mask_area'); //预览大图的mask // 收款图片上传多张图片
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul // window.onload = function(){
_doc.on('click', 'a[href="#modal-time"]', function(e){ // var input = document.getElementById("file_input");
follow.house_id = $ (this).attr ("data-id"); // var result,div;
//
// if(typeof FileReader==='undefined'){
// result.innerHTML = "抱歉,你的浏览器不支持 FileReader";
// input.setAttribute('disabled','disabled');
// }else{
// input.addEventListener('change',readFile,false);
// }
// function readFile(){
// for(var i=0;i<this.files.length;i++){
// if (!input['value'].match(/.jpg|.gif|.png|.bmp/i)){  //判断上传文件格式
// return alert("上传的图片格式不正确,请重新选择")
//     }
// var reader = new FileReader();
// reader.readAsDataURL(this.files[i]);
// reader.onload = function(e){
// result = '<div id="result"><img src="'+this.result+'" alt=""/></div>';
// div = document.createElement('div');
// div.innerHTML = result;
// document.getElementById('body').appendChild(div);   //插入dom树 <br>          }
// }
// }
// };
// $('.span-del').click(function(){
// console.log(55);
// $(this).parent().remove();
// });
_doc.on('click', '.span-del', function(e) {
e.preventDefault();
e.stopPropagation();
$(this).parent().remove();
});
_doc.on('click', 'a[href="#modal-time"]', function(e) {
follow.house_id = $(this).attr("data-id");
e.preventDefault(); e.preventDefault();
e.stopPropagation(); e.stopPropagation();
// console.log('follow.house_id'); // console.log('follow.house_id');
$('.iframe-time-line').attr('src', '/app_broker/timeline_pc?order_id='+follow.house_id); $('.iframe-time-line').attr('src', '/app_broker/timeline_pc?order_id=' + follow.house_id);
}); });
$("#search").click(function() { $("#search").click(function() {
follow.getList(1); follow.getList(1);
}); });
//点击收款图片 2.2版本 //点击收款图片 2.2版本
// $(".add-pic").click(function() { // $(".add-pic").click(function() {
// follow.getaddPicList(); // //监听图片上传
// }); // follow.getaddPicList();
_doc.on('click', '.add-pic', function(){ // });
_doc.on('click', '.add-pic', function() {
follow.getaddPicList(); follow.getaddPicList();
}); });
...@@ -52,180 +82,89 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -52,180 +82,89 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
$("#export").click(function() { //导出列表 $("#export").click(function() { //导出列表
follow.exportList(); follow.exportList();
}); });
$ (document).delegate (".submit_edit2", "click", function () {//提交 $(document).delegate(".submit_edit2", "click", function() { //提交
follow.house_id2 = $ (this).attr ("data-id"); follow.house_id2 = $(this).attr("data-id");
console.log(follow.house_id2); console.log(follow.house_id2);
$("#real_money").val($(this).attr ("data-money")); $("#real_money").val($(this).attr("data-money"));
}); });
$ (document).delegate (".submit_edit", "click", function () {//提交 $(document).delegate(".submit_edit", "click", function() { //提交
follow.Submit_follow(); follow.Submit_follow();
}); });
$ (document).on ("input","#cus_fang", function () {//手机号搜索客方2 $(document).on("input", "#cus_fang", function() { //手机号搜索客方2
if($("#cus_fang").val()==''){ if($("#cus_fang").val() == '') {
$(".user-ul2").html(''); $(".user-ul2").html('');
}else{ } else {
follow.search_phone2(); follow.search_phone2();
} }
}); });
$ (document).delegate (".addphone2", "click", function () {//list2消失 $(document).delegate(".addphone2", "click", function() { //list2消失
follow.addphone2(this); follow.addphone2(this);
}); });
//图片上传 2.2版本
//图片上传,附件上传处理事件
$(".upload-image-btn").click(function() {
var _this = $(this),
_spFile = _this.data('spfile'),
_limitTop = _this.data('limittop'),
_fileNum = _this.parent().next().find('.delet-pic-btn').length; //根据删除按钮的个数,确定文件的个数
if(_limitTop && (_fileNum < _limitTop)) {
BrowseServer(_this.prev().attr('id'), function(url) {
console.log(url);
if(_spFile == 'pdf') {
if(/(\.pdf)$/i.test(url)) {
_this.parent().next().prepend('<li class="pdf-pre-li"><a class="pdf-pre-a" href="{0}" target="_blank" title="点击查看">{1}</a><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({
'0': url,
'1': dealFileName(decodeURI(url.slice(url.lastIndexOf('/') + 1)))
}));
} else {
alert('所选择的格式不是pdf,请重新选择');
return false;
}
} else {
if(/(\.jpg|\.jpeg|\.png|\.gif|\.bmp)$/i.test(url)) {
_this.parent().next().prepend('<li><img title="点击查看大图" src="{0}" /><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({
'0': url
}));
} else {
alert('所选择的格式不正确,请重新选择');
return false;
}
};
});
} else {
alert('上传上限为 ' + _limitTop);
return false;
};
});
//图片上传删除键事件
_doc.on('click', '.delet-pic-btn', function(e) {
var _this = $(this);
e.preventDefault();
e.stopPropagation();
if(confirm('确定删除该文件吗?')){
var _imgId = _this.parent().attr('data-imgid');
if(_imgId){
$.ajax({
type: 'POST',
url: '/index/delHouseFile',
data: {
'id': _imgId,
'house_id': 3104,
},
timeout: 30000,
dataType: 'json',
beforeSend: function() {},
success: function(_data) {
if(typeof _data === 'object') {
if(_data['code'] == '200') {
_this.parent().remove();
} else {
alert(_data['msg']);
}
} else {
alert('数据错误');
};
},
error: function() {
alert('enter error');
},
complete: function(xhr, textStatus){
if(textStatus === 'timeout') {
//处理超时的逻辑
alert('请求超时,请重试');
};
}
});
}else{
_this.parent().remove();
}
};
});
//图片预览点击放大事件 //图片预览点击放大事件
_doc.on('click', '.img-pre-ul>li>img', function(e) {
_imgMaskObj.show().find('img').attr('src', this.src);
});
_imgMaskObj.click(function(e) {
this.style.display = 'none';
});
//保存上传的图片 //保存上传的图片
_doc.on('click', '#saveBtn', function(e) { _doc.on('click', '#saveBtn', function(e) {
console.log(555);
var _this = $(this); var _this = $(this);
var _data={ var _data = {
id:3104, type: 1,
image1: follow.image_file
}; };
e.preventDefault(); e.preventDefault();
e.stopPropagation(); e.stopPropagation();
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul // $.ajax({
var _xiangqingPicObj = _imgUploadLunbo.find('li>img'); // type: 'GET',
var _urlCut = location.origin + '/resource/lib/Attachments/images/';//要截取的部分url // url: '/index/uploadImg',
$.each(_xiangqingPicObj, function(i, item) { // data: _data,
_data['slide_show[' + i + ']'] = item.src.replace(_urlCut, ''); //// timeout: 30000,
}); // dataType: 'json',
var _imgId = _this.parent().attr('data-imgid'); // beforeSend: function() {},
$.ajax({ // success: function(_data) {
type: 'POST', // if(typeof _data === 'object') {
url: '/index/houseEdit', //
data: _data, // } else {
// timeout: 30000, // alert('数据错误');
dataType: 'json', // };
beforeSend: function() {}, // },
success: function(_data) { // error: function() {
if(typeof _data === 'object') { // alert('enter error');
// },
} else { // complete: function(xhr, textStatus){
alert('数据错误'); // if(textStatus === 'timeout') {
}; // //处理超时的逻辑
}, // alert('请求超时,请重试');
error: function() { // };
alert('enter error'); // }
}, // });
complete: function(xhr, textStatus){
if(textStatus === 'timeout') {
//处理超时的逻辑
alert('请求超时,请重试');
};
}
});
}); });
//图片上传 2.2版本 //图片上传 2.2版本
}, },
addphone2:function(obj){ addphone2: function(obj) {
var user_ht=$(obj).html(); var user_ht = $(obj).html();
$("#cus_fang").val(user_ht); $("#cus_fang").val(user_ht);
$(".user-ul2").html(''); $(".user-ul2").html('');
follow.agent_id = $ (obj).attr ("data-id"); follow.agent_id = $(obj).attr("data-id");
}, },
search_phone2:function(){//手机号 search_phone2: function() { //手机号
$.ajax ({ $.ajax({
url: '/index/select_by_phone', url: '/index/select_by_phone',
type: 'POST', type: 'POST',
async: true, async: true,
data: { data: {
"phone":$("#cus_fang").val() "phone": $("#cus_fang").val()
}, },
dataType: 'json', dataType: 'json',
success: function (data) { success: function(data) {
if (data.code == 200) { if(data.code == 200) {
var user_ul2 = ""; var user_ul2 = "";
$.each(data.data, function(i,item) { $.each(data.data, function(i, item) {
user_ul2+='<li class="addphone2" data-id="'+item.id+'">'+item.id+'-'+item.realname+'-'+item.phone+'</li>'; user_ul2 += '<li class="addphone2" data-id="' + item.id + '">' + item.id + '-' + item.realname + '-' + item.phone + '</li>';
}); });
$(".user-ul2").html(user_ul2); $(".user-ul2").html(user_ul2);
...@@ -249,40 +188,77 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -249,40 +188,77 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
success: function(data) { success: function(data) {
if(data.code == 200) { if(data.code == 200) {
follow.getList(0); follow.getList(0);
} else { } else {}
}
} }
}); });
}, },
//点击收款图片 调用的接口 //点击收款图片 调用的接口
getaddPicList: function() { //提交 getaddPicList: function() {
var _imgUploadLunbo = $('#xiangqing_pic_ul'); //详情页轮播图ul
var _urlCut = location.origin + '/resource/lib/Attachments/images/';//要截取的部分url
_imgUploadLunbo.empty();
$.ajax({
'type': 'GET',
'url': '/index/houseEdit',
data: {
"id": 3104,
},
dataType: "json",
success: function(data) {
if(data.code == 200) {
var _data = data['data'];
for(var i in _data['slide_show']) {
_imgUploadLunbo.append('<li data-imgid="{id}"><img title="点击查看大图" src="{0}" /><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({
'0': _urlCut + _data['slide_show'][i]['img_name'],
'id': _data['slide_show'][i]['id']
}));
};
// follow.getList(0); var input = document.getElementById("file_input");
var result, div;
if(typeof FileReader === 'undefined') {
result.innerHTML = "抱歉,你的浏览器不支持 FileReader";
input.setAttribute('disabled', 'disabled');
} else { } else {
input.addEventListener('change', readFile, false);
};
function readFile() {
console.log(this.files);
// var _this=$(this);
for(var i = 0; i < this.files.length; i++) {
if(!input['value'].match(/.jpg|.gif|.png|.bmp/i)) {   //判断上传文件格式
return alert("上传的图片格式不正确,请重新选择")    
}
var reader = new FileReader();
reader.readAsDataURL(this.files[i]);
reader.onload = function(e) {
result = '<div class="result"><img src="' + this.result + '" alt=""/> <span class="span-del">删除</span></div>';
div = document.createElement('div');
div.innerHTML = result;
document.getElementById('container_body').appendChild(div);   
} }
};
var formData = new FormData();
formData.append('type',1);
formData.append('image',this.files[0]);
console.log(this.files[0]);
console.log(formData);
$.ajax({
type: 'post',
url: '/index/uploadImg',
data: formData,
dataType: 'json',
contentType: false,
cache: false,
processData:false,
beforeSend: function() {},
success: function(_data) {
if(typeof _data === 'object') {
} else {
alert('数据错误');
};
},
error: function() {
alert('enter error');
},
complete: function(xhr, textStatus) {
if(textStatus === 'timeout') {
//处理超时的逻辑
alert('请求超时,请重试');
};
} }
}); });
};
}, },
// 导出列表 //删除图片
// 导出列表
exportList: function(pageNo) { exportList: function(pageNo) {
console.log(2); console.log(2);
follow.pageNo = pageNo; follow.pageNo = pageNo;
...@@ -298,8 +274,8 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -298,8 +274,8 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
var store_name = $('#store_name').val(); var store_name = $('#store_name').val();
var report_phone = $('#applicant_phone').val(); var report_phone = $('#applicant_phone').val();
var report_name = $('#applicant_name').val(); var report_name = $('#applicant_name').val();
window.open('/index/getCollection?'+ window.open('/index/getCollection?' +
'excel='+ excel_two +'&user_name=' + user_name + '&start_time=' + start_time + '&end_time=' + end_time + '&internal_title=' + internal_title + '&user_phone=' + user_phone + '&id=' + id+ '&store_name=' + store_name+ '&report_phone=' + report_phone+ '&report_name=' + report_name); 'excel=' + excel_two + '&user_name=' + user_name + '&start_time=' + start_time + '&end_time=' + end_time + '&internal_title=' + internal_title + '&user_phone=' + user_phone + '&id=' + id + '&store_name=' + store_name + '&report_phone=' + report_phone + '&report_name=' + report_name);
}, },
getList: function(pageNo) { getList: function(pageNo) {
...@@ -308,15 +284,15 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -308,15 +284,15 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
console.log($('#shop_name').val()); console.log($('#shop_name').val());
follow.pageNo = pageNo; follow.pageNo = pageNo;
var params = {}; var params = {};
params.user_name =$.trim($('#customer_name').val()); params.user_name = $.trim($('#customer_name').val());
params.start_time =$('#start_date').val(); params.start_time = $('#start_date').val();
params.end_time =$('#end_date').val(); params.end_time = $('#end_date').val();
params.internal_title =$('#shop_name').val(); params.internal_title = $('#shop_name').val();
params.user_phone =$('#customer_phone').val(); params.user_phone = $('#customer_phone').val();
params.id =$('#shop_num').val()*1; params.id = $('#shop_num').val() * 1;
params.store_name =$('#store_name').val(); params.store_name = $('#store_name').val();
params.report_phone =$('#applicant_phone').val(); params.report_phone = $('#applicant_phone').val();
params.report_name =$('#applicant_name').val(); params.report_name = $('#applicant_name').val();
params.pageNo = follow.pageNo; params.pageNo = follow.pageNo;
params.pageSize = follow.pageSize; params.pageSize = follow.pageSize;
...@@ -329,67 +305,66 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -329,67 +305,66 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
beforeSend: function() {}, beforeSend: function() {},
success: function(data) { success: function(data) {
if(typeof data === 'object') { if(typeof data === 'object') {
if (data.code == 200) { if(data.code == 200) {
var doTtmpl = doT.template(document.getElementById('get_collection_tpl').innerHTML); var doTtmpl = doT.template(document.getElementById('get_collection_tpl').innerHTML);
$("#follow_list").html(doTtmpl(data.data.list)); $("#follow_list").html(doTtmpl(data.data.list));
// 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他 // 支付方式 10支付宝 20 微信 30pos机器 40转账 50现金 60其他
$("#follow_list tr").each(function (e) { $("#follow_list tr").each(function(e) {
//e代表索引 从0开始 eq(0)就是第一行 //e代表索引 从0开始 eq(0)就是第一行
var temp = $("#follow_list").find("tr").eq(e).find("td").eq(5).html(); //获取一列的值 var temp = $("#follow_list").find("tr").eq(e).find("td").eq(5).html(); //获取一列的值
var temp_two = $("#follow_list").find("tr").eq(e).find("td").eq(6).html(); var temp_two = $("#follow_list").find("tr").eq(e).find("td").eq(6).html();
// null // null
var temp_one = $("#follow_list").find("tr").eq(e).find("td").eq(1).html(); var temp_one = $("#follow_list").find("tr").eq(e).find("td").eq(1).html();
if(temp_two*1==10){ if(temp_two * 1 == 10) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("支付宝") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("支付宝")
} }
if(temp_two*1==20){ if(temp_two * 1 == 20) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("微信") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("微信")
} }
if(temp_two*1==30){ if(temp_two * 1 == 30) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("pos机器") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("pos机器")
} }
if(temp_two*1==40){ if(temp_two * 1 == 40) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("转账") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("转账")
} }
if(temp_two*1==50){ if(temp_two * 1 == 50) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("现金") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("现金")
} }
if(temp_two*1==60){ if(temp_two * 1 == 60) {
$("#follow_list").find("tr").eq(e).find("td").eq(6).html("其他") $("#follow_list").find("tr").eq(e).find("td").eq(6).html("其他")
} }
// 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他 // 付款类型 10意向金 20定金 30保管金 40押金 50 租金 60 进场费 70转让费 80其他
if(temp*1==10){ if(temp * 1 == 10) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("意向金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("意向金")
} }
if(temp*1==20){ if(temp * 1 == 20) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("定金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("定金")
} }
if(temp*1==30){ if(temp * 1 == 30) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("保管金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("保管金")
} }
if(temp*1==40){ if(temp * 1 == 40) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("押金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("押金")
} }
if(temp*1==50){ if(temp * 1 == 50) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("租金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("租金")
} }
if(temp*1==60){ if(temp * 1 == 60) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("进场费") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("进场费")
} }
if(temp*1==70){ if(temp * 1 == 70) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("转让费") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("转让费")
} }
if(temp*1==80){ if(temp * 1 == 80) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("其他") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("其他")
} }
if(temp*1==90){ if(temp * 1 == 90) {
$("#follow_list").find("tr").eq(e).find("td").eq(5).html("佣金") $("#follow_list").find("tr").eq(e).find("td").eq(5).html("佣金")
} }
// null 佣金 // null 佣金
if(temp_one=='null'){ if(temp_one == 'null') {
$("#follow_list").find("tr").eq(e).find("td").eq(1).html(" ") $("#follow_list").find("tr").eq(e).find("td").eq(1).html(" ")
} }
}); });
...@@ -397,7 +372,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -397,7 +372,7 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
$("#money_total").html(data.data.money_total) $("#money_total").html(data.data.money_total)
/*分页代码*/ /*分页代码*/
add_page(data.data.total,pageNo,follow.pageSize,follow.getList); add_page(data.data.total, pageNo, follow.pageSize, follow.getList);
/* $("#pagediv").pagination({ /* $("#pagediv").pagination({
length:data.data.total, length:data.data.total,
current: pageNo, current: pageNo,
...@@ -406,18 +381,18 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css ...@@ -406,18 +381,18 @@ define(['doT', 'text!temp/get_collection_template_tpl.html', 'css!style/home.css
follow.getList(el.num.current); follow.getList(el.num.current);
} }
});*/ });*/
}else { } else {
alert(data['msg']); alert(data['msg']);
}; };
}else{ } else {
alert('数据错误'); alert('数据错误');
}; };
}, },
error: function() { error: function() {
alert('error'); alert('error');
}, },
complete: function(xhr, textStatus){ complete: function(xhr, textStatus) {
if(textStatus === 'timeout'){ if(textStatus === 'timeout') {
alert('请求超时'); alert('请求超时');
}; };
} }
......
...@@ -450,7 +450,7 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'text!temp/reportList_s ...@@ -450,7 +450,7 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'text!temp/reportList_s
$("#bargaininfo_type").val(data.data.trade_type); $("#bargaininfo_type").val(data.data.trade_type);
$("#bargaininfo_total_commission").val(data.data.commission); $("#bargaininfo_total_commission").val(data.data.commission);
$("#bargaininfo_create_time").html(data.data.create_time); $("#bargaininfo_create_time").html(data.data.create_time);
$("#bargaininfo_expect_payback_time").html(data.data.payback_time); $("#bargaininfo_expect_payback_time").val(data.data.estimated_receipt_date);
$("#bargaininfo_yetai").val(data.data.industry_type); $("#bargaininfo_yetai").val(data.data.industry_type);
$("#bargaininfo_chengjiao_price").val(data.data.price); $("#bargaininfo_chengjiao_price").val(data.data.price);
...@@ -490,7 +490,7 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'text!temp/reportList_s ...@@ -490,7 +490,7 @@ define(['doT', 'text!temp/reportList_template_tpl.html', 'text!temp/reportList_s
'trade_type': $('#bargaininfo_type').val(), 'trade_type': $('#bargaininfo_type').val(),
'industry_type': $.trim($('#bargaininfo_yetai').val()), 'industry_type': $.trim($('#bargaininfo_yetai').val()),
'price': $('#bargaininfo_chengjiao_price').val(), 'price': $('#bargaininfo_chengjiao_price').val(),
'payback_time': $('#bargaininfo_expect_payback_time').val(), 'estimated_receipt_date': $('#bargaininfo_expect_payback_time').val(),
'step': bargain.mainTabIndex+1 'step': bargain.mainTabIndex+1
}; };
......
...@@ -487,7 +487,7 @@ define (['doT', 'text!temp/schoolBusiness_template_tpl.html','ckfinder','ckfinde ...@@ -487,7 +487,7 @@ define (['doT', 'text!temp/schoolBusiness_template_tpl.html','ckfinder','ckfinde
// 封面图一张 // 封面图一张
if(_data['cover_plan']){ if(_data['cover_plan']){
_imgUploadLiebiao.html('<li><img title="点击查看大图" src="{0}" /><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({ _imgUploadLiebiao.html('<li><img title="点击查看大图" src="{0}" /><a href="javascript:;" class="delet-pic-btn">删除</a></li>'.stringFormatObj({
'0': _urlCut + _data['cover_plan'] '0': _data['cover_plan']
})); }));
}; };
// 封面图一张 // 封面图一张
...@@ -532,15 +532,15 @@ define (['doT', 'text!temp/schoolBusiness_template_tpl.html','ckfinder','ckfinde ...@@ -532,15 +532,15 @@ define (['doT', 'text!temp/schoolBusiness_template_tpl.html','ckfinder','ckfinde
var _data = {}; var _data = {};
//字符串形式 传过去 //字符串形式 传过去
$.each(_liebiaoPicObj, function(i, item) { // $.each(_liebiaoPicObj, function(i, item) {
_data['file_img[' + i + ']'] = item.src.replace(_urlCut, ''); // _data['file_img'] = item.src.replace(_urlCut, '');
// _data['file_img[' + i + ']'] = item.src; //// _data['file_img[' + i + ']'] = item.src;
//
}); // });
_data.title = $("#announcement_title").val(); _data.title = $("#announcement_title").val();
_data.title2 = $("#district_id2").val();//商学院标签id _data.s_label_id = $("#district_id2").val();//商学院标签id
// _data.file_img = _liebiaoPicObj[0].src.replace(_urlCut, '');//封面图 剪切后的字符串 _data.file_img = _liebiaoPicObj[0].src.replace(_urlCut, '');//封面图 剪切后的字符串
_data.content = _dajiangtangVal; _data.content = _dajiangtangVal;
// if (params.title == '') { // if (params.title == '') {
// alert('标题不能为空'); // alert('标题不能为空');
......
...@@ -468,6 +468,7 @@ define(['doT', 'text!temp/tax_template_tpl.html', 'text!temp/reportList_shuiFee2 ...@@ -468,6 +468,7 @@ define(['doT', 'text!temp/tax_template_tpl.html', 'text!temp/reportList_shuiFee2
$("#bargaininfo_type").val(data.data.trade_type); $("#bargaininfo_type").val(data.data.trade_type);
$("#bargaininfo_total_commission").val(data.data.commission); $("#bargaininfo_total_commission").val(data.data.commission);
$("#bargaininfo_create_time").html(data.data.create_time); $("#bargaininfo_create_time").html(data.data.create_time);
$("#bargaininfo_expect_payback_time").val(data.data.estimated_receipt_date);
$("#bargaininfo_yetai").val(data.data.industry_type); $("#bargaininfo_yetai").val(data.data.industry_type);
$("#bargaininfo_chengjiao_price").val(data.data.price); $("#bargaininfo_chengjiao_price").val(data.data.price);
......
...@@ -399,9 +399,9 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', ' ...@@ -399,9 +399,9 @@ define (['doT', 'text!temp/user_template_tpl.html','ckfinder','ckfinderStart', '
var params = {}; var params = {};
// 增加客户id的搜索 客户姓名和手机号搜索分开 // 增加客户id的搜索 客户姓名和手机号搜索分开
// params.name = $("input[name='user']").val(); params.user_nick = $("input[name='user']").val();
// params.phone = $("input[name='phone']").val(); params.phone = $("input[name='phone']").val();
// params.nameID = $("input[name='nameID']").val(); params.id = $("input[name='userID']").val();
params.phone = $("input[name='phone']").val(); params.phone = $("input[name='phone']").val();
params.invite_phone = $("input[name='invite_phone']").val(); params.invite_phone = $("input[name='invite_phone']").val();
params.start_date = $("#start_date").val(); params.start_date = $("#start_date").val();
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</td> </td>
<!--<td>[%= it[item]["label_name"] %]</td>--> <!--<td>[%= it[item]["label_name"] %]</td>-->
<!--没有评论数字段--> <!--没有评论数字段-->
<td>[%= it[item]["create_time"] %]</td> <td>[%= it[item]["comment_number"] %]</td>
<td> <td>
<a class="btn1 btn-success" href="new_text.html?id=[%= it[item]["id"] %]" data-createTime='[%= it[item]["create_time"] %]' data-title='[%= it[item]["title"] %]' data-id='[%= it[item]["id"] %]' data-content='[%= it[item]["content"] %]' target="_blank"> <a class="btn1 btn-success" href="new_text.html?id=[%= it[item]["id"] %]" data-createTime='[%= it[item]["create_time"] %]' data-title='[%= it[item]["title"] %]' data-id='[%= it[item]["id"] %]' data-content='[%= it[item]["content"] %]' target="_blank">
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</a> </a>
[% if(check_auth('index/delNews')) { %] [% if(check_auth('index/delNews')) { %]
<!--删除权限--> <!--删除权限-->
<a class="btn1 btn-success announcement-del" href="#modal-delete" data-toggle="modal" data-id='[%= it[item]["id"] %]'>删除</a> <a class="btn1 btn-danger announcement-del" href="#modal-delete" data-toggle="modal" data-id='[%= it[item]["id"] %]'>删除</a>
[% } %] [% } %]
</td> </td>
......
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