d
This commit is contained in:
@@ -93,7 +93,7 @@ extension MeetupId {
|
||||
ctrl.pipe(
|
||||
dbg: "join",
|
||||
sub: nil,
|
||||
Bus.events.compactMap { Bus.convertKeyValue(K.join, $0) }.map { (k: String, v: Bool) in v }.map { _ in () }.eraseToAnyPublisher(),
|
||||
Bus.events.compactMap { Bus.convertKeyValue(K.join, $0) }.map { (k: String, v: Void) in v }.eraseToAnyPublisher(),
|
||||
{ $0.join = true },
|
||||
{ $0.join = false }
|
||||
)
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
def pipeBusSource(name, entity, busKey, structure, fmtBusPipe, fmtBusPipeToggle):
|
||||
def pipeBusSource(name, entity, busKey, structure, fmt):
|
||||
valueType = structure.model.fields[name][0]
|
||||
fmt = fmtBusPipe
|
||||
if "toggle" in entity.pipes[name]:
|
||||
fmt = fmtBusPipeToggle
|
||||
valueType = "Void"
|
||||
|
||||
return fmt \
|
||||
.replace("%BUS_KEY%", busKey) \
|
||||
|
||||
@@ -5,7 +5,6 @@ from generation.pipeSource import *
|
||||
|
||||
def sectionGeneratedPipes(entity, sub, c):
|
||||
fmtBusPipe = c.readFile(f"{c.dir}/templates/section-generated-pipe-src-bus")[0]
|
||||
fmtBusPipeToggle = c.readFile(f"{c.dir}/templates/section-generated-pipe-src-bus-toggle")[0]
|
||||
fmtExRecent = c.readFile(f"{c.dir}/templates/section-generated-pipe-ex-recent")
|
||||
fmtRecent = c.readFile(f"{c.dir}/templates/section-generated-pipe-recent")
|
||||
fmtSet = c.readFile(f"{c.dir}/templates/section-generated-pipe-set")
|
||||
@@ -32,7 +31,7 @@ def sectionGeneratedPipes(entity, sub, c):
|
||||
src = pipeSource(key, entity)
|
||||
# Bus.
|
||||
if src.startswith("K."):
|
||||
src = pipeBusSource(key, entity, src, c.structure, fmtBusPipe, fmtBusPipeToggle)
|
||||
src = pipeBusSource(key, entity, src, c.structure, fmtBusPipe)
|
||||
|
||||
fmtPipe = pipeFormat(fmtExRecent, fmtRecent, fmtSet, fmtToggle, fmtToggleNil, key, entity)
|
||||
for fmt in fmtPipe:
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
Bus.events.compactMap { Bus.convertKeyValue(%BUS_KEY%, $0) }.map { (k: String, v: %BUS_VALUE_TYPE%) in v }.map { _ in () }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user