推广公会归属管理 改为公会归属不可选择

master
chenzhi 5 years ago
parent d7737291ed
commit dd86a85485

@ -1309,11 +1309,16 @@ class PromoteController extends ThinkController
//为数据权限添加
setPowerPromoteIds($map, 'pb.promote_id');
$model = M('promote_belong', 'tab_');
$field = "
pb.id,pb.promote_id,pb.verify_status,pb.company_relation,pb.remark,pb.can_view_recharge,pb.approver_name,pb.applicant_name,pb.verify_time,pb.applicant_time,pb.company_type,
pc.company_name,
p.company_belong,p.account,p.mobile_phone,p.admin_id,p.ver_status,p.status,p.create_time
";
$list_data = $model->alias('pb')
->join('left join tab_promote as p on p.id=pb.promote_id')
->join('left join tab_promote_company as pc on pc.id = p.company_id')
->where($map)
->field('p.*,pb.*, pc.company_name')
->field($field)
->page($p, $row)
->order('verify_status asc,applicant_time asc')
->select();

@ -53,19 +53,20 @@
<select id="promote_id" name="promote_id" class="select_gallery" style="width:120px;">
<option value="">请选择会长账号</option>
<volist name=":promote_listsOther(1)" id="vo">
<option promote_id-id="{$vo.id}" value="{$vo.id}" <if condition="$vo.id eq $_GET['promote_id']">selected=selected</if>>{$vo.account}</option>
<option data-company_belong="{$vo['company_belong']}" data-belong="{:getCompanyBlong($vo['company_belong'])}" promote_id-id="{$vo.id}" value="{$vo.id}" <if condition="$vo.id eq $_GET['promote_id']">selected=selected</if>>{$vo.account}</option>
</volist>
</select>
</td>
</tr>
<tr>
<tr id="company_belong_box" style="display: none;">
<td class="l">工会归属:</td>
<td class="r table_radio">
<span class="form_radio">
<label >
<input type="radio" value="3" name="company_belong" checked="checked" class="company_belong">
<input id="company_belong" name="company_belong" value="" type="hidden">
<span class="form_radio" id="company_belong_str">
<!-- <label >
<input type="radio" value="3" name="company_belong" class="company_belong" checked="checked">
</label >
<label >
<input type="radio" value="0" name="company_belong" class="company_belong"> 内团
@ -75,7 +76,7 @@
</label>
<label >
<input type="radio" value="2" name="company_belong" class="company_belong"> 外团-分发联盟
</label >
</label > -->
</span>
<!-- <span class="notice-text"></span>-->
</td>
@ -171,8 +172,16 @@
Think.setValue("category", {$data.category|default = 0});
$(".select_gallery").select2();
$(function(){
$("#promote_id").on("select2:select",function(e){
console.log(e);
$("#promote_id").on("change",function(e){
var belong = $("#promote_id option:selected").data();
$("#company_belong_str").html(belong.belong);
$("#company_belong").val(belong.company_belong);
if(belong.company_belong > -1){
$("#company_belong_box").show();
}else{
$("#company_belong_box").hide();
}
})
// showTab();
});

@ -50,12 +50,15 @@
<tr>
<td class="l">会长账号:</td>
<td class="r">
<select id="promote_id" name="promote_id" class="select_gallery" style="width:120px;">
<input id="promote_id" name="promote_id" value="{$data['promote_id']}" type="hidden">
{:getPromoteName($data['promote_id'])}
<!-- <select id="promote_id" name="promote_id" class="select_gallery" style="width:120px;">
<option value="">请选择会长账号</option>
<volist name=":promote_listsOther(1)" id="vo">
<option promote_id-id="{$vo.id}" value="{$vo.id}" <if condition="$vo.id eq $data['promote_id']">selected=selected</if>>{$vo.account}</option>
</volist>
</select>
</select> -->
</td>
</tr>
<input type="hidden" name="promote_id" value="{$data['promote_id']}">
@ -64,8 +67,10 @@
<tr>
<td class="l">工会归属:</td>
<td class="r table_radio">
<input id="company_belong" name="company_belong" value="{$data['company_belong']}" type="hidden">
<span class="form_radio">
<label >
{:getCompanyBlong($data['company_belong'])}
<!-- <label >
<input type="radio" value="3" name="company_belong" <?php if($data['company_belong'] ==3):?>
checked="checked"
<?php endif?> class="company_belong"> 无
@ -84,7 +89,7 @@
<input type="radio" value="2" name="company_belong" <?php if($data['company_belong'] ==2):?>
checked="checked"
<?php endif?> class="company_belong"> 外团-分发联盟
</label>
</label> -->
</span>
<!-- <span class="notice-text"></span>-->
</td>

Loading…
Cancel
Save