File tree Expand file tree Collapse file tree 3 files changed +37
-0
lines changed Expand file tree Collapse file tree 3 files changed +37
-0
lines changed Original file line number Diff line number Diff line change 1+ export const $lib = createTypeSpecLibrary ( {
2+ // ...
3+ state : {
4+ customName : { description : "State for the @customName decorator" } ,
5+ } ,
6+ } ) ;
7+
8+ export const StateKeys = $lib . stateKeys ;
Original file line number Diff line number Diff line change 1+ // import { StateKeys } from "./lib.js";
2+
3+ // // Create a unique key
4+ // const key = StateKeys.customName;
5+ // export function $faker(context, target, name) {
6+ // // Keep a mapping between the target and a value.
7+ // context.program.stateMap(key).set(target, name);
8+
9+ // // Keep an index of a type.
10+ // context.program.stateSet(key).add(target);
11+ // }
12+ let key = 0 ;
13+ export function $faker ( context , target , name ) {
14+ console . log ( target . node )
15+ // if (target.model) {
16+ // console.log(name);
17+ // // console.log(context);
18+ // console.log(target.model.properties);
19+ // // context.program.stateMap(key).set(target, name);
20+ // // key += 1;
21+
22+ // target.type['x-faker'] = name.value;
23+ // console.log('---------------------');
24+ // }
25+ }
Original file line number Diff line number Diff line change @@ -18,18 +18,22 @@ interface TaskService {
1818 @ query select ? : string []
1919 ): Tasks ;
2020
21+ @ useAuth (BasicAuth )
2122 @ get
2223 op get (
2324 @ path id : string ,
2425 @ query select ? : string
2526 ): Task ;
2627
28+ @ useAuth (BasicAuth )
2729 @ post
2830 op create (... NewTaskDto ): Task ;
2931
32+ @ useAuth (BasicAuth )
3033 @ patch
3134 op update (@ path id : string , ... EditTaskDto ): Task ;
3235
36+ @ useAuth (BasicAuth )
3337 @ delete
3438 op delete (@ path id : string ): void ;
3539}
You can’t perform that action at this time.
0 commit comments