Skip to content

Commit 97f98db

Browse files
Working changes
1 parent a48a456 commit 97f98db

File tree

4 files changed

+27
-21
lines changed

4 files changed

+27
-21
lines changed

.env.development

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ NEXT_PUBLIC_SMALL_SCALE_SIMULATOR_URL=https://staging.openbraininstitute.org/api
1111
NEXT_PUBLIC_CELL_SVC_BASE_URL=https://staging.openbraininstitute.org/api/circuit
1212
NEXT_PUBLIC_THUMBNAIL_GENERATION_BASE_URL=https://staging.openbraininstitute.org/api/thumbnail-generation
1313
NEXT_PUBLIC_VIRTUAL_LAB_API_URL=https://staging.openbraininstitute.org/api/virtual-lab-manager
14-
NEXT_PUBLIC_OBI_ONE_URL=https://staging.openbraininstitute.org/api/obi-one
14+
# NEXT_PUBLIC_OBI_ONE_URL=https://staging.openbraininstitute.org/api/obi-one
15+
NEXT_PUBLIC_OBI_ONE_URL=http://127.0.0.1:8100
1516
NEXT_PUBLIC_NOTEBOOK_SERVICE_BASE_URL=https://staging.openbraininstitute.org/api/notebook_service
1617

1718
MAILCHIMP_API_KEY='dummy'

src/features/small-microcircuit/_components/hooks/schema.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export function useObioneJsonSchema(
2727
const json = await res.json();
2828
const dereferenced = await $RefParser.dereference(json);
2929
const schemaName = match(modelEntityType)
30-
.with(EntityTypeDict.Circuit, () => 'CircuitSimulationScanConfig')
30+
.with(EntityTypeDict.Circuit, () => 'IonChannelFittingScanConfig')
3131
.with(EntityTypeDict.Memodel, () => 'MEModelSimulationScanConfig')
3232
.otherwise(() => {
3333
throw new Error(`Unsupported entity type: ${modelEntityType}`);
@@ -122,6 +122,7 @@ export function useObioneJsonSchema(
122122
return {
123123
schema,
124124
refLabels: schema?.default_block_reference_labels,
125+
blockOrdering: schema?.block_block_group_order,
125126
referenceTypesToConfigKeys,
126127
referenceTypesToTitles,
127128
};

src/features/small-microcircuit/_components/utils.ts

Lines changed: 22 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -24,26 +24,30 @@ export const ORDERING: Record<string, { order: number; category: string }> = {
2424
order: 1,
2525
category: 'Setup',
2626
},
27-
stimuli: {
27+
equations: {
2828
order: 2,
29-
category: 'Stimuli & Recordings',
30-
},
31-
recordings: {
32-
order: 3,
33-
category: 'Stimuli & Recordings',
34-
},
35-
neuron_sets: {
36-
order: 4,
37-
category: 'Circuit components',
38-
},
39-
timestamps: {
40-
order: 5,
41-
category: 'Events',
42-
},
43-
synaptic_manipulations: {
44-
order: 6,
45-
category: 'Circuit components',
29+
category: 'Equations',
4630
},
31+
// stimuli: {
32+
// order: 3,
33+
// category: 'Stimuli & Recordings',
34+
// },
35+
// recordings: {
36+
// order: 4,
37+
// category: 'Stimuli & Recordings',
38+
// },
39+
// neuron_sets: {
40+
// order: 5,
41+
// category: 'Circuit components',
42+
// },
43+
// timestamps: {
44+
// order: 6,
45+
// category: 'Events',
46+
// },
47+
// synaptic_manipulations: {
48+
// order: 7,
49+
// category: 'Circuit components',
50+
// },
4751
};
4852

4953
export const CATEGORIES: string[] = uniq(Object.values(ORDERING).map((o) => o.category));

src/features/small-microcircuit/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ export default function SimulationCampaignConfiguration({
8686
const initialConfigValidated = useRef(false);
8787
const [atomsMap, setAtomsMap] = useState<AtomsMap>({});
8888

89-
const { schema, refLabels, referenceTypesToConfigKeys, referenceTypesToTitles } =
89+
const { schema, refLabels, blockOrdering, referenceTypesToConfigKeys, referenceTypesToTitles } =
9090
useObioneJsonSchema(modelId, model.type, notification, setAtomsMap, initialConfig);
9191

9292
const selectedCatSchema = schema?.properties?.[configTab]?.additionalProperties?.oneOf?.find(

0 commit comments

Comments
 (0)