var type = localStorage.getItem( "type" )
table.on( 'rowDouble(test)' , function( obj) {
var data = obj.data;
var ProjectID = data.ProjectID;
console.log( data)
localStorage.setItem( "type" , data.type)
//弹框( 全屏)
var index = layer.open( {
title: "渠道项目详情" , //不显示标题栏
type: 2,
content: '/Views/Pro_Project/Pro_ProjectUpdate.html?op=1&ProjectID=' +
ProjectID,
area: [ '1721px' , '866px' ] ,
maxmin: true
} ) ;
layer.full( index) ;
} ) ;
xgweb.ajaxGet( xgweb.apiAdd( ) + "AreaSection/SelectAllAreaSection" , {
} , function( res) {
var ret = res.data;
console.log( ret) ;
if ( ret == null) {
layer.alert( "没有获取到可用片区!" ) ;
} else {
var htmls = "" ;
console.log( ret)
areas = [ ] ;
if( type== "Pro" ) {
for ( var i = 0; i < ret.length; i++) {
ret[ i] .AreaName= ret[ i] .AreaName.replace( /\s*/g,"" ) ;
areas.push( ret[ i] .AreaID)
if ( i == 2) {
htmls += "<input type='checkbox' value=" + ret[ i] .AreaID + " id=" + ret[ i] .AreaID +
" title=" + ret[ i] .AreaName.replace( /( \n) /g, "" ) + " lay-skin='primary' name='QuName'/>" ;
htmls += "<input type='text' id='" + ret[ i] .AreaID + "Policy' disabled style='border:none;background:transparent;'/>" ;
htmls += "</br>" ;
} else {
htmls += "<input type='checkbox' value=" + ret[ i] .AreaID + " id=" + ret[ i] .AreaID +
" title=" + ret[ i] .AreaName.replace( /( \n) /g, "" ) + " lay-skin='primary' name='QuName'/>" ;
htmls += "" +"<input type='text' id='" + ret[ i] .AreaID + "Policy' disabled style='border:none;background:transparent; ' />" ;
htmls += "</br>" ;
}
}
} else if( type== "Bus" ) {
for ( var i = 0; i < ret.length; i++) {
ret[ i] .AreaName= ret[ i] .AreaName.replace( /\s*/g,"" ) ;
areas.push( ret[ i] .AreaID)
if ( i == 2) {
htmls += "<input type='checkbox' value=" + ret[ i] .AreaID + " id=" + ret[ i] .AreaID +
" title=" + ret[ i] .AreaName.replace( /( \n) /g, "" ) + " lay-skin='primary' name='QuName'/>" ;
htmls += "<input type='text' disabled id='" + ret[ i] .AreaID + "Policy' />" ;
htmls += "</br>" ;
} else {
htmls += "<input type='checkbox' value=" + ret[ i] .AreaID + " id=" + ret[ i] .AreaID +
" title=" + ret[ i] .AreaName.replace( /( \n) /g, "" ) + " lay-skin='primary' name='QuName'/>" ;
htmls += "" +"<input type='text' id='" + ret[ i] .AreaID + "Policy' />" ;
htmls += "</br>" ;
}
}
}