function createChnlTree() {
var chnlList=[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/',
desc:'社保',
chnlid:'55806',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55807',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55809',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'55810',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55814',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/ylbx/',
desc:'养老保险',
chnlid:'55815',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/gsbx/',
desc:'工伤保险',
chnlid:'55821',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/sybx/',
desc:'失业保险',
chnlid:'55824',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/yilbx/',
desc:'医疗保险',
chnlid:'55827',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/shybx/',
desc:'生育保险',
chnlid:'55828',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/sb/jnjs/',
desc:'缴纳基数',
chnlid:'55829',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/zf/',
desc:'住房',
chnlid:'55834',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55835',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55837',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'55838',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55841',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/zf/gjj/',
desc:'公积金',
chnlid:'55842',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/zf/bzxzf/',
desc:'保障性住房',
chnlid:'55864',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/',
desc:'交通',
chnlid:'55865',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55866',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55868',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'57571',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55872',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/jdcyw/',
desc:'机动车业务',
chnlid:'55873',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/jszyw/',
desc:'驾驶证业务',
chnlid:'55880',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/jtwfcl/',
desc:'交通违法处理',
chnlid:'55881',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/dljtsgcl/',
desc:'道路交通事故处理',
chnlid:'55884',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/bllnrblyw/',
desc:'便利老年人办理业务',
chnlid:'55885',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jt/gzcx/',
desc:'公众出行',
chnlid:'55887',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/',
desc:'教育',
chnlid:'55894',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55895',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55897',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'55898',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55903',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/sfbz/',
desc:'收费标准',
chnlid:'55904',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/xqjy/',
desc:'学前教育',
chnlid:'55907',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/xxjy/',
desc:'小学教育',
chnlid:'55909',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/czjy/',
desc:'初中教育',
chnlid:'55911',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/gzjy/',
desc:'高中教育',
chnlid:'55914',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/gdyjxjy/',
desc:'高等与继续教育',
chnlid:'55917',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jy/qtjy/',
desc:'其他教育',
chnlid:'55918',
isActive:false
},
{
url:'https://www.eeafj.cn/syyxfw/',
desc:'院校服务',
chnlid:'57874',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/',
desc:'就业创业',
chnlid:'55920',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55921',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55923',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'55924',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55928',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/syry/',
desc:'失业人员',
chnlid:'55929',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/cyry/',
desc:'创业人员',
chnlid:'55933',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/bys/',
desc:'毕业生',
chnlid:'55935',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/tyjr/',
desc:'退役军人',
chnlid:'55939',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/cjr/',
desc:'残疾人',
chnlid:'55942',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/jycy/rcsc/',
desc:'人才市场',
chnlid:'55950',
isActive:false
},
{
url:'https://flbook.com.cn/c/Dh5wMw8RE4',
desc:'政策一本通',
chnlid:'57875',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/shjzhfl/',
desc:'社会救助和福利',
chnlid:'55952',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55953',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55955',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'55956',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策解读":{
desc:'政策解读',
chnlid:'55957',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55960',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/shjzhfl/shjz/',
desc:'社会救助',
chnlid:'55961',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/shjzhfl/shfl/',
desc:'社会福利',
chnlid:'55965',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/shjzhfl/tjsj/',
desc:'统计数据',
chnlid:'55973',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/shjzhfl/fwzq/',
desc:'服务专区',
chnlid:'55970',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/hysy/',
desc:'婚姻生育',
chnlid:'55974',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'55975',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'55977',
jsonData:
[
{
"docTitle":"福建省南安市助产机构名单",
"docImg":"2025-07-31",
"docPubUrL":"https://www.nanan.gov.cn/wsbs/ztfw/hysy/bs/202406/t20240614_3047151.htm",
"docKeyWord":""
}
]
},
"专题入口":{
desc:'专题入口',
chnlid:'55978',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策解读":{
desc:'政策解读',
chnlid:'55979',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'55982',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/hysy/hyfw/',
desc:'婚姻服务',
chnlid:'55983',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/hysy/cqfw/',
desc:'产前服务',
chnlid:'55987',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/hysy/chfw/',
desc:'产后服务',
chnlid:'55994',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/hysy/syfw/',
desc:'收养服务',
chnlid:'56004',
isActive:false
}
]
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/yljk/',
desc:'医疗健康',
chnlid:'56009',
defaultItems:{
"常见问题":{
desc:'常见问题',
chnlid:'56010',
jsonData:
404 Not Found
404 Not Found
nginx
},
"办事服务":{
desc:'办事服务',
chnlid:'56012',
jsonData:
404 Not Found
404 Not Found
nginx
},
"专题入口":{
desc:'专题入口',
chnlid:'56013',
jsonData:
404 Not Found
404 Not Found
nginx
},
"政策文件":{
desc:'政策文件',
chnlid:'56016',
jsonData:
404 Not Found
404 Not Found
nginx
}
},
fieldItems:[
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/yljk/ysyy/',
desc:'优生优育',
chnlid:'56017',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/yljk/yljkfw/',
desc:'医疗健康服务',
chnlid:'56021',
isActive:false
},
{
url:'http://www.nanan.gov.cn/wsbs/ztfw/yljk/jkbk/',
desc:'健康百科',
chnlid:'56029',
isActive:false
}
]
}
]
return chnlList;
}
avalon.define("field",function($scope){
$scope.defaultItems={};
//头部领域主题简称
$scope.chnldesc="";
$scope.fieldItems=[];
//办事服务数据集
$scope.serviceItems=[];
//专题入口数据集
$scope.subjectItems=[];
//图解数据集
$scope.diagramItems=[];
//政策数据集
$scope.policyItems=[];
//常见问题集
$scope.requestionItems=[];
//检索词
$scope.searchWord=_searchTag;
$scope.innerPageBgClassObj={
"社保":"sb_bg",
"住房":"zf_bg",
"交通":"jt_bg",
"教育":"jyly_bg",
"就业创业":"jycy_bg",
"社会救助与福利":"shjz_bg",
"婚姻生育":"hysy_bg",
"医疗健康":"yljk_bg",
"企业开办":"qykb_bg"
};
//innerPageBgClassName
$scope.innerPageBgClassName="";
//默认领域对象用于完成互动知识库检索
$scope.defaultNthemeObj={
_key:'',
_value:''
};
$scope.getCurrChnlTree=function(){
var _channelItems=createChnlTree();
for (var index1 =0; index1 < _channelItems.length;index1++) {
var element1 = _channelItems [index1];
if(location.href.indexOf(element1.url)!=-1){
$scope.chnldesc=element1.desc;
$scope.innerPageBgClassName=$scope.innerPageBgClassObj[$scope.chnldesc];
for (var index2 = 0; index2 < element1.fieldItems.length; index2++) {
var element2 = element1.fieldItems[index2];
if(location.href.indexOf(element2.url)!=-1){
element2.isActive=true;
break;
}
}
$scope.defaultItems = JSON.parse(JSON.stringify(element1.defaultItems));
$scope.fieldItems = JSON.parse(JSON.stringify(element1.fieldItems));
break;
}
}
}
$scope.filterList=function(_list,_key){
var _arr_var1=[];
if(!_key) return [];
var _list_Var1=JSON.parse(JSON.stringify(_list));
avalon.each(_list_Var1,function(i,o){
if(o.docKeyWord&&o.docKeyWord.indexOf(_key)!=-1){
_arr_var1.push(o);
}
})
return _arr_var1;
}
//获取办事服务数据集
$scope.dealServiceData=function(){
if($scope.defaultItems['办事服务']){
$scope.serviceItems=$scope.filterList($scope.defaultItems['办事服务']['jsonData'],$scope.searchWord);
}
}
//获取专题入口数据集
$scope.dealSubjectData=function(){
if($scope.defaultItems['专题入口']){
$scope.subjectItems=$scope.filterList($scope.defaultItems['专题入口']['jsonData'],$scope.searchWord);
}
}
//获取图解数据集
$scope.dealDiagramData=function(){
if($scope.defaultItems['图解']){
$scope.diagramItems=$scope.filterList($scope.defaultItems['图解']['jsonData'],$scope.searchWord);
}
}
//获取政策数据集
$scope.dealPolicyData=function(){
if($scope.defaultItems['政策文件']){
$scope.policyItems=$scope.filterList($scope.defaultItems['政策文件']['jsonData'],$scope.searchWord);
}
}
//获取常见问题数据集
$scope.dealRuestionData=function(){
if($scope.defaultItems['常见问题']){
var _list_temp=[];
var _reqList=$scope.defaultItems['常见问题']['jsonData'];
var _maxLen=_reqList.length>=5 ? 5:_reqList.length;
for (var index = 0; index < _maxLen; index++) {
var element = _reqList[index];
_list_temp.push(element);
}
$scope.requestionItems=_list_temp;
}
}
$scope.dealData=function(){
$scope.dealServiceData();
$scope.dealSubjectData();
$scope.dealDiagramData();
$scope.dealPolicyData();
$scope.dealRuestionData();
}
$scope.getCurrChnlTree();
$scope.dealData();
})