Discuz iOS应用开发 - bigApp iOS源码分析 - 应用配置获取流程

iOS应用如何获取BigApp插件里定义的配置?

在LoadingVC中请求数据

1
2
3
4
5
6
7
8
9
10
11
12
13
14
- (void)requestAppBaseDatas
{
WEAKSELF
[_configViewModel getAppBaseConfigWithBlock:^(BOOL result) {
/*
* 1、请求插件后面的配置信息
* 2、请求首页的indexcfg配置信息
* 3、请求所有的版块儿信息
*/
[weakSelf requestAppPlugcfg];
[weakSelf requestHomeIndexcfg];
[weakSelf requestForumsDatas];
}];
}

  • 请求插件后面的配置信息

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
     - (void)request_AppInfoWithBlock:(void(^)(id data, NSError *error))block
    {
    NSDictionary *dic = @{
    @"module" : @"plugcfg",
    @"iyzmobile" : @"1",
    @"iyzversion": kiyzversion
    };

    [[ClanNetAPI sharedJsonClient] requestCustomStyleWithPath:_kurl_base_path withParams:dic withMethodType:Get andBlock:^(id data, NSError *error) {
    if (error) {
    block(nil,error);
    }else{
    block(data,nil);
    }
    }];
    }
    • basePath:api/mobile/iyz_index.php
    • Params:

      1
      2
      3
      4
      5
      NSDictionary *dic = @{
      @"module" : @"plugcfg",
      @"iyzmobile" : @"1",
      @"iyzversion": kiyzversion
      };
    • returnValue:

      1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      11
      12
      13
      14
      15
      16
      17
      18
      19
      20
      21
      22
      23
      24
      25
      26
      27
      28
      29
      30
      31
      32
      33
      34
      35
      36
      37
      38
      39
      40
      41
      42
      43
      44
      45
      46
      47
      48
      49
      50
      51
      52
      53
      54
      55
      56
      57
      58
      59
      60
      61
      62
      63
      64
      65
      66
      67
      68
      69
      70
      71
      72
      73
      74
      75
      76
      77
      78
      79
      80
      81
      82
      83
      84
      85
      86
      87
      88
      89
      90
      91
      92
      93
      94
      95
      96
      97
      98
      99
      100
      101
      102
      103
      104
      105
      106
      107
      108
      109
      110
      111
      112
      113
      114
      115
      116
      117
      118
      119
      120
      121
      122
      123
      124
      125
      126
      127
      128
      129
      130
      131
      132
      133
      134
      135
      136
      137
      138
      139
      140
      141
      142
      143
      144
      145
      146
      147
      148
      149
      150
      151
      152
      153
      154
      155
      156
      157
      158
      159
      160
      161
      162
      163
      164
      165
      166
      167
      168
      169
      170
      171
      172
      173
      174
      175
      176
      177
      178
      179
      180
      181
      182
      183
      184
      185
      186
      187
      188
      189
      190
      191
      192
      193
      194
      195
      196
      197
      198
      199
      200
      201
      202
      203
      204
      205
      206
      207
      208
      209
      210
      211
      212
      213
      214
      215
      216
      217
      218
      219
      220
      221
      222
      223
      224
      225
      226
      227
      228
      229
      230
      231
      232
      233
      234
      235
      236
      237
      238
      239
      240
      241
      242
      243
      244
      245
      246
      247
      248
      249
      250
      251
      252
      253
      254
      255
      256
      257
      258
      259
      260
      261
      262
      263
      264
      265
      266
      267
      268
      269
      270
      271
      272
      273
      274
      275
      276
      277
      278
      279
      280
      281
      282
      283
      284
      285
      286
      287
      288
      289
      290
      291
      292
      293
      294
      295
      296
      297
      298
      299
      300
      301
      302
      303
      304
      305
      306
      307
      308
      309
      310
      311
      312
      313
      314
      315
      316
      317
      318
      319
      320
      321
      322
      323
      324
      325
      326
      327
      328
      329
      330
      331
      332
      333
      334
      335
      336
      337
      338
      339
      340
      341
      342
      343
      344
      345
      346
      347
      348
      349
      350
      351
      352
      353
      354
      355
      356
      357
      358
      359
      360
      361
      362
      363
      364
      365
      366
      367
      368
      369
      370
      371
      372
      373
      374
      375
      376
      377
      378
      379
      380
      381
      382
      383
      384
      385
      386
      387
      388
      389
      390
      391
      392
      393
      394
      395
      396
      397
      398
      399
      400
      401
      402
      403
      404
      405
      406
      407
      408
      409
      410
      411
      412
      413
      414
      415
      416
      417
      418
      419
      420
      421
      422
      423
      424
      425
      426
      427
      428
      429
      430
      431
      432
      433
      434
      435
      436
      437
      438
      439
      440
      441
      442
      443
      444
      445
      446
      447
      448
      449
      450
      451
      452
      453
      454
      455
      456
      457
      458
      459
      460
      461
      462
      463
      464
      465
      466
      467
      468
      469
      470
      471
      472
      473
      474
      475
      476
      477
      478
      479
      480
      481
      482
      483
      484
      485
      486
      487
      488
      489
      490
      491
      492
      493
      494
      495
      496
      497
      498
      499
      500
      501
      502
      503
      504
      505
      506
      507
      508
      509
      510
      511
      512
      513
      514
      515
      516
      517
      518
      519
      520
      521
      {
      config = {
      appdesc = "";
      appinfo = {
      "app_id" = 0;
      };
      "checkin_enabled" = 1;
      "display_style" = 0;
      iyzversion = 2;
      "login_info" = {
      "allow_avatar_change" = 1;
      "login_mod" = 0;
      "login_url" = "";
      "reg_mod" = 0;
      "reg_switch" = 1;
      "reg_url" = "";
      };
      "platform_login" = {
      qqlogin = "";
      "qqlogin_end" = "";
      "wechat_login" = 1;
      "weibo_login" = 0;
      };
      portalconfig = (
      {
      enable = 1;
      id = 0;
      module = "\U95e8\U6237\U9996\U9875";
      sort = 1;
      title = "\U9996\U9875";
      type = 4;
      }
      );
      "push_enabled" = 0;
      qqlogin = "";
      "qqlogin_end" = "";
      "reply_button_type" = 0;
      searchsetting = {
      enable = 1;
      enablesphinxon = 0;
      setting = (
      {
      key = portal;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      },
      {
      key = forum;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      },
      {
      key = blog;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      },
      {
      key = album;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      },
      {
      key = group;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      },
      {
      key = collection;
      maxsearchresults = 500;
      maxspm = 10;
      searchctrl = 10;
      status = 1;
      }
      );
      };
      "smiley_info" = {
      code = 1;
      md5 = cd6ce2f9cb75d8f41dc96d3c0b8952b9;
      message = success;
      "zip_info" = (
      {
      "pic_directory" = comcom;
      "pic_schema" = (
      {
      "pic_name" = "1.gif";
      "pic_size" = 1359;
      },
      {
      "pic_name" = "10.gif";
      "pic_size" = 1514;
      },
      {
      "pic_name" = "11.gif";
      "pic_size" = 2759;
      },
      {
      "pic_name" = "12.gif";
      "pic_size" = 2540;
      },
      {
      "pic_name" = "13.gif";
      "pic_size" = 1326;
      },
      {
      "pic_name" = "14.gif";
      "pic_size" = 1400;
      },
      {
      "pic_name" = "15.gif";
      "pic_size" = 1087;
      },
      {
      "pic_name" = "16.gif";
      "pic_size" = 1463;
      },
      {
      "pic_name" = "17.gif";
      "pic_size" = 1593;
      },
      {
      "pic_name" = "18.gif";
      "pic_size" = 1344;
      },
      {
      "pic_name" = "19.gif";
      "pic_size" = 250;
      },
      {
      "pic_name" = "2.gif";
      "pic_size" = 1631;
      },
      {
      "pic_name" = "20.gif";
      "pic_size" = 1175;
      },
      {
      "pic_name" = "21.gif";
      "pic_size" = 1110;
      },
      {
      "pic_name" = "22.gif";
      "pic_size" = 1359;
      },
      {
      "pic_name" = "23.gif";
      "pic_size" = 1295;
      },
      {
      "pic_name" = "24.gif";
      "pic_size" = 2351;
      },
      {
      "pic_name" = "25.gif";
      "pic_size" = 1619;
      },
      {
      "pic_name" = "26.gif";
      "pic_size" = 753;
      },
      {
      "pic_name" = "27.gif";
      "pic_size" = 833;
      },
      {
      "pic_name" = "28.gif";
      "pic_size" = 1398;
      },
      {
      "pic_name" = "29.gif";
      "pic_size" = 1126;
      },
      {
      "pic_name" = "3.gif";
      "pic_size" = 1389;
      },
      {
      "pic_name" = "30.gif";
      "pic_size" = 501;
      },
      {
      "pic_name" = "4.gif";
      "pic_size" = 1359;
      },
      {
      "pic_name" = "5.gif";
      "pic_size" = 2462;
      },
      {
      "pic_name" = "6.gif";
      "pic_size" = 1851;
      },
      {
      "pic_name" = "7.gif";
      "pic_size" = 1623;
      },
      {
      "pic_name" = "8.gif";
      "pic_size" = 1356;
      },
      {
      "pic_name" = "9.gif";
      "pic_size" = 1251;
      }
      );
      },
      {
      "pic_directory" = coolmonkey;
      "pic_schema" = (
      {
      "pic_name" = "01.gif";
      "pic_size" = 2549;
      },
      {
      "pic_name" = "02.gif";
      "pic_size" = 2448;
      },
      {
      "pic_name" = "03.gif";
      "pic_size" = 2550;
      },
      {
      "pic_name" = "04.gif";
      "pic_size" = 2586;
      },
      {
      "pic_name" = "05.gif";
      "pic_size" = 2609;
      },
      {
      "pic_name" = "06.gif";
      "pic_size" = 2603;
      },
      {
      "pic_name" = "07.gif";
      "pic_size" = 2553;
      },
      {
      "pic_name" = "08.gif";
      "pic_size" = 2573;
      },
      {
      "pic_name" = "09.gif";
      "pic_size" = 2545;
      },
      {
      "pic_name" = "10.gif";
      "pic_size" = 2543;
      },
      {
      "pic_name" = "11.gif";
      "pic_size" = 2568;
      },
      {
      "pic_name" = "12.gif";
      "pic_size" = 2485;
      },
      {
      "pic_name" = "13.gif";
      "pic_size" = 2561;
      },
      {
      "pic_name" = "14.gif";
      "pic_size" = 2547;
      },
      {
      "pic_name" = "15.gif";
      "pic_size" = 2623;
      },
      {
      "pic_name" = "16.gif";
      "pic_size" = 2476;
      }
      );
      },
      {
      "pic_directory" = default;
      "pic_schema" = (
      {
      "pic_name" = "biggrin.gif";
      "pic_size" = 1345;
      },
      {
      "pic_name" = "call.gif";
      "pic_size" = 603;
      },
      {
      "pic_name" = "cry.gif";
      "pic_size" = 2866;
      },
      {
      "pic_name" = "curse.gif";
      "pic_size" = 1543;
      },
      {
      "pic_name" = "dizzy.gif";
      "pic_size" = 1859;
      },
      {
      "pic_name" = "funk.gif";
      "pic_size" = 2928;
      },
      {
      "pic_name" = "handshake.gif";
      "pic_size" = 1322;
      },
      {
      "pic_name" = "huffy.gif";
      "pic_size" = 3809;
      },
      {
      "pic_name" = "hug.gif";
      "pic_size" = 1054;
      },
      {
      "pic_name" = "kiss.gif";
      "pic_size" = 987;
      },
      {
      "pic_name" = "lol.gif";
      "pic_size" = 1443;
      },
      {
      "pic_name" = "loveliness.gif";
      "pic_size" = 1579;
      },
      {
      "pic_name" = "mad.gif";
      "pic_size" = 2423;
      },
      {
      "pic_name" = "sad.gif";
      "pic_size" = 1237;
      },
      {
      "pic_name" = "shocked.gif";
      "pic_size" = 1944;
      },
      {
      "pic_name" = "shutup.gif";
      "pic_size" = 2500;
      },
      {
      "pic_name" = "shy.gif";
      "pic_size" = 2663;
      },
      {
      "pic_name" = "sleepy.gif";
      "pic_size" = 2375;
      },
      {
      "pic_name" = "smile.gif";
      "pic_size" = 1662;
      },
      {
      "pic_name" = "sweat.gif";
      "pic_size" = 1879;
      },
      {
      "pic_name" = "time.gif";
      "pic_size" = 687;
      },
      {
      "pic_name" = "titter.gif";
      "pic_size" = 1398;
      },
      {
      "pic_name" = "tongue.gif";
      "pic_size" = 1841;
      },
      {
      "pic_name" = "victory.gif";
      "pic_size" = 1275;
      }
      );
      },
      {
      "pic_directory" = grapeman;
      "pic_schema" = (
      {
      "pic_name" = "01.gif";
      "pic_size" = 2373;
      },
      {
      "pic_name" = "02.gif";
      "pic_size" = 2454;
      },
      {
      "pic_name" = "03.gif";
      "pic_size" = 2485;
      },
      {
      "pic_name" = "04.gif";
      "pic_size" = 2481;
      },
      {
      "pic_name" = "05.gif";
      "pic_size" = 2441;
      },
      {
      "pic_name" = "06.gif";
      "pic_size" = 2480;
      },
      {
      "pic_name" = "07.gif";
      "pic_size" = 2488;
      },
      {
      "pic_name" = "08.gif";
      "pic_size" = 2332;
      },
      {
      "pic_name" = "09.gif";
      "pic_size" = 2546;
      },
      {
      "pic_name" = "10.gif";
      "pic_size" = 2436;
      },
      {
      "pic_name" = "11.gif";
      "pic_size" = 2542;
      },
      {
      "pic_name" = "12.gif";
      "pic_size" = 2363;
      },
      {
      "pic_name" = "13.gif";
      "pic_size" = 2513;
      },
      {
      "pic_name" = "14.gif";
      "pic_size" = 2477;
      },
      {
      "pic_name" = "15.gif";
      "pic_size" = 2421;
      },
      {
      "pic_name" = "16.gif";
      "pic_size" = 2612;
      },
      {
      "pic_name" = "17.gif";
      "pic_size" = 2621;
      },
      {
      "pic_name" = "18.gif";
      "pic_size" = 2469;
      },
      {
      "pic_name" = "19.gif";
      "pic_size" = 2535;
      },
      {
      "pic_name" = "20.gif";
      "pic_size" = 2557;
      },
      {
      "pic_name" = "21.gif";
      "pic_size" = 2550;
      },
      {
      "pic_name" = "22.gif";
      "pic_size" = 2461;
      },
      {
      "pic_name" = "23.gif";
      "pic_size" = 2502;
      },
      {
      "pic_name" = "24.gif";
      "pic_size" = 2512;
      }
      );
      }
      );
      "zip_url" = "http://localhost/inspirelifebbs/static/image/smiley_v2.zip";
      };
      threadconfig = (
      {
      enable = 1;
      id = 0;
      module = new;
      sort = 1;
      title = "\U6700\U65b0";
      type = 6;
      },
      {
      enable = 1;
      id = 0;
      module = hot;
      sort = 2;
      title = "\U70ed\U95e8";
      type = 7;
      },
      {
      enable = 1;
      id = 0;
      module = digest;
      sort = 3;
      title = "\U7cbe\U534e";
      type = 8;
      }
      );
      "wechat_login" = 1;
      "weibo_login" = 0;
      };
      "error_code" = 0;
      "error_msg" = SUCC;
      }

各个参数的详细意义可能需要结合具体的功能再深入了解下。

  • 请求首页的indexcfg配置信息

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
     - (void)request_HomeConfig:(void(^)(id data, NSError *error))block{
    NSDictionary *dic = @{
    @"version" : ClanVersion,
    @"iyzversion" : kiyzversion,
    @"iyzmobile" : @"1",
    @"module" : @"indexcfg",
    };
    [[ClanNetAPI sharedJsonClient] requestJsonDataWithPath:_kurl_base_path
    withParams:dic
    withMethodType:Get
    andBlock:^(id data, NSError *error) {
    block(data, error);
    }];
    }
    • basePath: api/mobile/iyz_index.php
    • Params:

      1
      2
      3
      4
      5
      6
      NSDictionary *dic = @{
      @"version" : ClanVersion,
      @"iyzversion" : kiyzversion,
      @"iyzmobile" : @"1",
      @"module" : @"indexcfg",
      };
    • returnValue:

      1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      11
      12
      13
      14
      15
      16
      17
      18
      19
      20
      21
      22
      23
      24
      25
      26
      27
      28
      29
      30
      31
      32
      33
      34
      35
      36
      37
      38
      39
      40
      41
      42
      43
      44
      45
      46
      47
      48
      49
      50
      51
      52
      53
      54
      55
      56
      57
      58
      59
      60
      61
      62
      63
      64
      65
      66
      67
      68
      69
      70
      71
      72
      73
      74
      75
      76
      77
      78
      79
      80
      81
      82
      83
      84
      85
      86
      87
      88
      89
      90
      91
      92
      93
      94
      95
      96
      97
      98
      99
      100
      101
      102
      103
      104
      105
      106
      107
      108
      109
      110
      111
      112
      113
      114
      115
      116
      117
      118
      119
      120
      121
      122
      123
      124
      125
      126
      127
      128
      129
      130
      131
      132
      133
      134
      135
      136
      137
      138
      139
      140
      141
      142
      143
      144
      145
      146
      147
      148
      149
      150
      151
      152
      153
      154
      155
      156
      157
      158
      159
      160
      161
      162
      163
      164
      165
      166
      167
      168
      169
      170
      171
      172
      173
      174
      175
      176
      177
      178
      179
      180
      181
      182
      183
      184
      185
      186
      187
      188
      189
      190
      191
      192
      193
      194
      195
      196
      {
      Charset = "UTF-8";
      Variables = {
      auth = "8539QAPzx5Z93M1sqP4Bs1WN3TspQVkKgszLQ2Hzf/577MWaTkq9fUNmHZDRphUmHYbF9yaXX81z4MXw5Ed9";
      "button_configs" = (
      {
      "button_name" = "\U9996\U9875";
      "button_type" = 1;
      "icon_type" = "3_24";
      id = 1;
      "tab_cfg" = {
      "home_page" = (
      {
      setting = (
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/14/d/4/f/d4fb1a0f9fd0e780694eaa22cbe63e31.jpg?_v=1495364213";
      pid = 0;
      title = bigapp;
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/18/c/7/9/c7986bba5411c3249dc8d172b6c1dfff.jpg?_v=1495364213";
      pid = 0;
      title = "\U4e2a\U6027\U5316\U9996\U9875";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/18/7/4/0/740776a3426865e2d97251bbde856b2b.jpg?_v=1495364213";
      pid = 0;
      title = "\U6e38\U65cf\U7f51\U7edc";
      type = 1;
      url = "http://bigapp.mob.com/";
      }
      );
      type = banner;
      },
      {
      setting = (
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/1/a/2/d/a2d48037df9c1dbeacdb3232ca2197b3.png?_v=1495364213";
      pid = 0;
      title = "\U529f\U80fd\U533a1";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/1/d/2/c/d2c5d626b2e2dbb705b277f92903a767.png?_v=1495364213";
      pid = 0;
      title = "\U529f\U80fd\U533a2";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = "";
      pic = "http://mobfile.youzu.com/Uploads_image/1/c/5/d/c5d514e2ff2a7d4c58ceed840e0253f0.png?_v=1495364213";
      pid = 0;
      title = "\U529f\U80fd\U533a3";
      type = 1;
      url = "http://bigapp.mob.com/";
      }
      );
      type = func;
      },
      {
      setting = (
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/1/d/6/4/d6443b9c58e64aa3d640d269b23d444f.png?_v=1495364213";
      pid = 0;
      title = "\U70ed\U95e8\U533a1";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/2/2/6/1/2610b00cd55a65d3580037c910f37e06.png?_v=1495364213";
      pid = 3;
      title = "\U70ed\U95e8\U533a2";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/2/3/2/7/327bef8b10441329007fb9dcc956be9f.png?_v=1495364213";
      pid = 3;
      title = "\U70ed\U95e8\U533a3";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/2/b/1/8/b184780602b05fd6df357984890b11f2.png?_v=1495364213";
      pid = 3;
      title = "\U70ed\U95e8\U533a4";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/2/c/a/1/ca107b8c4d6edd90272.1.1148aeb1e7.png?_v=1495364213";
      pid = 1;
      title = "\U70ed\U95e8\U533a5";
      type = 1;
      url = "http://bigapp.mob.com/";
      },
      {
      desc = bigapp;
      pic = "http://mobfile.youzu.com/Uploads_image/2/7/6/0/76059c5c50fc81dcc32b9c6fbd722577.png?_v=1495364213";
      pid = 1;
      title = "\U70ed\U95e8\U533a6";
      type = 1;
      url = "http://bigapp.mob.com/";
      }
      );
      type = hot;
      },
      {
      recommend = {
      "thread_config" = (
      {
      "data_link" = "http://localhost/inspirelifebbs/api/mobile/iyz_index.php?iyzmobile=1&iyzversion=2&module=indexthread&buttonid=&navid=&style=1&view=new&displayid=&forbiddenid=";
      module = "\U6700\U65b0\U5e16\U5b50";
      title = "\U6700\U65b0";
      },
      {
      "data_link" = "http://localhost/inspirelifebbs/api/mobile/iyz_index.php?iyzmobile=1&iyzversion=2&module=indexthread&buttonid=&navid=&style=1&view=hot&displayid=&forbiddenid=";
      module = "\U70ed\U95e8\U5e16\U5b50";
      title = "\U70ed\U95e8";
      },
      {
      "data_link" = "http://localhost/inspirelifebbs/api/mobile/iyz_index.php?iyzmobile=1&iyzversion=2&module=indexthread&buttonid=&navid=&style=1&view=digest&displayid=&forbiddenid=";
      module = "\U7cbe\U534e\U5e16\U5b50";
      title = "\U7cbe\U534e";
      }
      );
      type = 2;
      };
      type = recomm;
      }
      );
      "tab_type" = 1;
      title = "";
      "title_cfg" = (
      );
      };
      },
      {
      "button_name" = "\U8bba\U575b";
      "button_type" = 2;
      "icon_type" = "3_25";
      id = 2;
      },
      {
      "button_name" = "\U53d1\U5e16";
      "button_type" = 3;
      "icon_type" = "3_26";
      id = 3;
      },
      {
      "button_name" = "\U7ad9\U5185\U4fe1";
      "button_type" = 4;
      "icon_type" = "3_27";
      id = 4;
      },
      {
      "button_name" = "\U6211\U7684";
      "button_type" = 5;
      "icon_type" = "3_28";
      id = 5;
      }
      );
      cookiepre = "0oza_2132_";
      formhash = 26cca247;
      groupid = 10;
      "member_avatar" = "http://localhost/inspirelifebbs/uc_server/avatar.php?uid=2&size=big";
      "member_uid" = 2;
      "member_username" = Test;
      notice = {
      newmypost = 0;
      newpm = 0;
      newprompt = 0;
      newpush = 0;
      };
      readaccess = 10;
      saltkey = c2mR68x2;
      };
      Version = 4;
      "request_id" = 0;
      }

这个首页信息的内容是需要自定义的,否则界面出来就是这个效果。
Tab的文字,图标也是在这边加载的,可以在BigApp配置页面修改。

  • 请求所有的版块儿信息

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
     - (void)request_BoardBlock:(void(^)(id data, NSError *error))block{
    NSDictionary *dic = @{
    @"version":ClanVersion,
    @"module":@"forumnav",
    @"iyzmobile":@"1"
    };
    [[ClanNetAPI sharedJsonClient] requestJsonDataWithPath:_kurl_base_path withParams:dic withMethodType:Get andBlock:^(id data, NSError *error) {
    if (error) {
    block(nil,error);
    }else{
    block(data, nil);
    }
    }];
    }
    • basePath:api/mobile/iyz_index.php
    • Params:

      1
      2
      3
      4
      5
      NSDictionary *dic = @{
      @"version":ClanVersion,
      @"module":@"forumnav",
      @"iyzmobile":@"1"
      };
    • returnValue:

      1
      2
      3
      4
      5
      6
      7
      8
      9
      10
      11
      12
      13
      14
      15
      16
      17
      18
      19
      20
      21
      22
      23
      24
      25
      26
      27
      28
      29
      30
      31
      32
      33
      34
      35
      36
      37
      38
      39
      40
      41
      42
      43
      44
      45
      46
      47
      48
      49
      50
      51
      52
      53
      54
      55
      56
      {
      Charset = "UTF-8";
      Variables = {
      "activity_forums" = (
      );
      auth = "8539QAPzx5Z93M1sqP4Bs1WN3TspQVkKgszLQ2Hzf/577MWaTkq9fUNmHZDRphUmHYbF9yaXX81z4MXw5Ed9";
      cookiepre = "0oza_2132_";
      "display_style" = 0;
      formhash = 26cca247;
      forums = (
      {
      allowpostspecial = 0;
      allowspecialonly = 0;
      fid = 1;
      forums = (
      {
      allowpostspecial = 1;
      allowspecialonly = 0;
      fid = 2;
      fup = 1;
      icon = "";
      name = "\U9ed8\U8ba4\U7248\U5757";
      posts = 0;
      status = 1;
      threads = 0;
      todayposts = 0;
      type = forum;
      }
      );
      fup = 0;
      icon = "";
      name = "Discuz!";
      posts = 0;
      status = 1;
      threads = 0;
      todayposts = 0;
      type = group;
      }
      );
      groupid = 10;
      ismoderator = 0;
      "member_avatar" = "http://localhost/inspirelifebbs/uc_server/avatar.php?uid=2&size=big";
      "member_uid" = 2;
      "member_username" = Test;
      notice = {
      newmypost = 0;
      newpm = 0;
      newprompt = 0;
      newpush = 0;
      };
      readaccess = 10;
      saltkey = c2mR68x2;
      };
      Version = 4;
      "request_id" = 0;
      }

相应的配置修改 (Todo)

  1. 修改首页的内容
  2. 追加额外的论坛板块

工时:

  1. 0.25 day