@ctsy/template

0.0.162 • Public • Published

碳素云后台模板库

配置目录参数

// export class MenuConfig {
//     BackgroundColor: string = "none"
//     TextColor = "#fff"
//     ActiveTextColor = "#ffd04b"
// }
Store.commit("set_menu_config", {
  BackgroundColor: "#111",
  TextColor: "white",
  ActiveTextColor: "#ffd04b",
});

使用外键关联

注册外键接口数据

Store.dispatch("set_foreign_config", {
  Code: "Family",
  Search: MasterApi.FamilyApi.search.bind(MasterApi.FamilyApi),
  All: false,
  PK: "FID",
  L: [],
  Value: 0,
});

使用外键数据

      new Ctsy.ViewConfigFields({
        Name: "计费方案",
        Code: "BGID",
        Desc: "",
        Column: {
          width: 70,
          fixed: "left",
        },
        Type: Ctsy.ViewConfigFieldsType.ForeignTableAll,
        Default: 0,
        Show: new Ctsy.ViewConfigFieldsShow(),
        Foreign: Object.assign(new Ctsy.ViewConfig(), {
          Name: "计费方案",
          Code: "BillingGroup",
          PK: "BGID",
          Title: "Title",
          Format: (v: any) => {
            // console.log(v);
            return `${v.Title}(${v.Price})`;
          },
          Fields: [
            new Ctsy.ViewConfigFields({
              Name: "名称",
              Code: "Title",
            }),
            new Ctsy.ViewConfigFields({
              Name: "单价",
              Code: "Price",
            }),
            // new Ctsy.ViewConfigFields({
            //   Name: "生效时间",
            //   Code: "STime"
            // }),
            // new Ctsy.ViewConfigFields({
            //   Name: "失效时间",
            //   Code: "ETime"
            // })
          ],
          // Search: MasterApi.BillingGroupApi.search.bind(
          // 	MasterApi.BillingGroupApi
          // ),
        }),
      }),

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.0.1622latest

Version History

VersionDownloads (Last 7 Days)Published
0.0.1622
0.0.1612
0.0.1602
0.0.1592
0.0.1582
0.0.1572
0.0.1562
0.0.1551
0.0.1541
0.0.1531
0.0.1521
0.0.1501
0.0.1491
0.0.1481
0.0.1471
0.0.1461
0.0.1451
0.0.1441
0.0.1431
0.0.1421
0.0.1411
0.0.1401
0.0.1391
0.0.1381
0.0.1371
0.0.1361
0.0.1351
0.0.1341
0.0.1331
0.0.1321
0.0.1311
0.0.1301
0.0.1291
0.0.1281
0.0.1271
0.0.1261
0.0.1251
0.0.1241
0.0.1231
0.0.1221
0.0.1211
0.0.1201
0.0.1191
0.0.1181
0.0.1171
0.0.1161
0.0.1151
0.0.1141
0.0.1131
0.0.1121
0.0.1112
0.0.1101
0.0.1092
0.0.1081
0.0.1071
0.0.1061
0.0.1051
0.0.1042
0.0.1031
0.0.1021
0.0.1011
0.0.1002
0.0.992
0.0.981
0.0.971
0.0.961
0.0.951
0.0.942
0.0.931
0.0.922
0.0.911
0.0.902
0.0.891
0.0.881
0.0.871
0.0.862
0.0.851
0.0.841
0.0.831
0.0.821
0.0.811
0.0.801
0.0.791
0.0.781
0.0.771
0.0.761
0.0.751
0.0.741
0.0.731
0.0.721
0.0.712
0.0.701
0.0.691
0.0.682
0.0.672
0.0.661
0.0.652
0.0.641
0.0.631
0.0.621
0.0.612
0.0.602
0.0.592
0.0.582
0.0.573
0.0.561
0.0.552
0.0.541
0.0.531
0.0.521
0.0.511
0.0.501
0.0.491
0.0.481
0.0.471
0.0.461
0.0.451
0.0.441
0.0.431
0.0.411
0.0.401
0.0.391
0.0.381
0.0.371
0.0.361
0.0.350
0.0.340
0.0.330
0.0.320
0.0.310
0.0.300
0.0.290
0.0.280
0.0.270
0.0.260
0.0.250
0.0.240
0.0.230
0.0.220
0.0.210
0.0.200
0.0.190
0.0.180
0.0.170
0.0.160
0.0.150
0.0.140
0.0.130
0.0.120
0.0.110
0.0.100
0.0.91
0.0.81
0.0.71
0.0.61
0.0.51
0.0.41
0.0.31
0.0.21
0.0.11

Package Sidebar

Install

npm i @ctsy/template

Weekly Downloads

161

Version

0.0.162

License

MIT

Unpacked Size

862 kB

Total Files

124

Last publish

Collaborators

  • yanpengquan
  • ida_xyt