Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Set route parameter value in input type during route creation

Received: by 10.50.100.168 with SMTP id ez8mr3169131igb.1.1346532006079;
        Sat, 01 Sep 2012 13:40:06 -0700 (PDT)
X-BeenThere: fubumvc-devel@googlegroups.com
Received: by 10.231.82.148 with SMTP id b20ls8623537ibl.9.gmail; Sat, 01 Sep
 2012 13:40:05 -0700 (PDT)
Received: by 10.42.132.5 with SMTP id b5mr5626807ict.7.1346532005399;
        Sat, 01 Sep 2012 13:40:05 -0700 (PDT)
Received: by 10.42.132.5 with SMTP id b5mr5626805ict.7.1346532005376;
        Sat, 01 Sep 2012 13:40:05 -0700 (PDT)
Return-Path: <m...@mikeobrien.net>
Received: from mail-ie0-f170.google.com (mail-ie0-f170.google.com [209.85.223.170])
        by gmr-mx.google.com with ESMTPS id gv6si1705417igb.0.2012.09.01.13.40.05
        (version=TLSv1/SSLv3 cipher=OTHER);
        Sat, 01 Sep 2012 13:40:05 -0700 (PDT)
Received-SPF: neutral (google.com: 209.85.223.170 is neither permitted nor denied by best guess record for domain of m...@mikeobrien.net) client-ip=209.85.223.170;
Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 209.85.223.170 is neither permitted nor denied by best guess record for domain of m...@mikeobrien.net) smtp.mail=...@mikeobrien.net
Received: by ied7 with SMTP id 7so2272448ied.15
        for <fubumvc-devel@googlegroups.com>; Sat, 01 Sep 2012 13:40:05 -0700 (PDT)
        d=google.com; s=20120113;
        h=mime-version:x-originating-ip:in-reply-to:references:date
         :message-id:subject:from:to:content-type:x-gm-message-state;
        bh=FwIoYUQhPE6Zte+hPYh4aEKjX7jYiMRvLJkRrwhlS50=;
        b=ViYSEKcjwOVNn22hOYIBrwxSwXJQOwbThVmfiAZFYELaC28pnUG3FiQeWjurSY8lm9
         YBSEYGCv7ksSWsWFgD0744OLuw0BpWTzLdtoE/xhbHdSGmfYUoqRKUFJT33znuLVtFzg
         QUUNcwwqBWVmsRzDFaIHOpgPQi2XAPZzGtdWIn0lwpwBVoP/1yS6UW5woo/bKBQVdK9/
         Clodlh79BpbWznSTYwhScqbaQLMejSeE/CdtepL5hKz+cZDOlR7Y7ih+lKQy8Jxhvido
         ObJM8Ve4p5Uwd0XQGFONfW7QrQhP9jj8hgbBkv6CAyURo4Wgnw8wguVIIlHcfzHp1yZH
         Y75Q==
MIME-Version: 1.0
Received: by 10.50.187.162 with SMTP id ft2mr6687808igc.11.1346532004909; Sat,
 01 Sep 2012 13:40:04 -0700 (PDT)
Received: by 10.64.19.234 with HTTP; Sat, 1 Sep 2012 13:40:04 -0700 (PDT)
X-Originating-IP: [65.190.69.83]
In-Reply-To: <CAC4_4NqNRM4Gu4vV8TXLZSF-gSf8zzTuMRE-dZ9ob2vmk1C...@mail.gmail.com>
References: <625936e4-2e44-498c-86ca-14540e51ef2c@googlegroups.com>
	<CAC4_4NqNRM4Gu4vV8TXLZSF-gSf8zzTuMRE-dZ9ob2vmk1C...@mail.gmail.com>
Date: Sat, 1 Sep 2012 16:40:04 -0400
Message-ID: <CAEEcqPGP2mtoehEpW1SHWkK9RWbRMGoK6+mju9G2ptwAuSj...@mail.gmail.com>
Subject: Re: [fubumvc] Set route parameter value in input type during route creation
From: "Mike O'Brien" <m...@mikeobrien.net>
To: fubumvc-devel@googlegroups.com
Content-Type: multipart/alternative; boundary=14dae934056bd4d37c04c8a9e9d5
X-Gm-Message-State: ALoCoQnrZzgq8fGZasnQDEnJY1nTeMnkXOi90/+Db8WMqlriw/shQWRefniqvnM280S24EZlIrlH

--14dae934056bd4d37c04c8a9e9d5
Content-Type: text/plain; charset=ISO-8859-1

Looks like your trying to dynamically build up routes based on entities in
your domain a la:

/Customers/...
/Accounts/...
/Addresses/...
...

Is this right?

On Sat, Sep 1, 2012 at 4:25 PM, Joshua Arnold <rncodep...@gmail.com> wrote:

> @David,
>
> I'm trying to follow what you're doing here but I'm exactly sure why
> you're attempting this. What's the significance of the EntityName property
> on your input type?
>
>
> On Sat, Sep 1, 2012 at 3:08 PM, David Roberts <david.robert...@gmail.com>wrote:
>
>> What are some recommended ways to define an input parameter but set its
>> value during route creation? For example:
>>
>> Given my route pattern looks like "/Customers/{Id}/Edit"
>>  And my input type has two properties (Id and EntityName)
>> When a request is made with "/Customers/1/Edit"
>> Then the input type is set as such:
>>    Id = 1
>>    Entityname = "Customers"
>>
>> The '/Edit' is linked to the input type itself. I'm not looking for a
>> dynamic 'EntityName' input value. I want to determine what entity name
>> during IUrlPolicy.Build is valid from the ActionCall and then setup a
>> distinct route.
>>
>> I am currently trying a pattern with a default value:
>> "/{EntityName:Customers}/{Id}/Edit"
>> And am in the middle of adding an exact match route constraint for
>> "EntityName" to see if that setup works. Are there other ways to do this?
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "FubuMVC Development Group" group.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msg/fubumvc-devel/-/WrkUh97ADE4J.
>> To post to this group, send email to fubumvc-devel@googlegroups.com.
>> To unsubscribe from this group, send email to
>> fubumvc-devel+unsubscribe@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/fubumvc-devel?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "FubuMVC Development Group" group.
> To post to this group, send email to fubumvc-devel@googlegroups.com.
> To unsubscribe from this group, send email to
> fubumvc-devel+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/fubumvc-devel?hl=en.
>

--14dae934056bd4d37c04c8a9e9d5
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Looks like your trying to dynamically build up routes based on entities in =
your domain a la:<div><br></div><div>/Customers/...</div><div>/Accounts/...=
</div><div>/Addresses/...</div><div>...</div><div><br></div><div>Is this ri=
ght?<br>
<br><div class=3D"gmail_quote">On Sat, Sep 1, 2012 at 4:25 PM, Joshua Arnol=
d <span dir=3D"ltr">&lt;<a href=3D"mailto:rncodep...@gmail.com" target=3D"_=
blank">rncodep...@gmail.com</a>&gt;</span> wrote:<br><blockquote class=3D"g=
mail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-l=
eft:1ex">
@David,<div><br></div><div>I&#39;m trying to follow what you&#39;re doing h=
ere but I&#39;m exactly sure why you&#39;re attempting this. What&#39;s the=
 significance of the EntityName property on your input type?</div><div clas=
s=3D"HOEnZb">
<div class=3D"h5"><div><br>
<br><div class=3D"gmail_quote">On Sat, Sep 1, 2012 at 3:08 PM, David Robert=
s <span dir=3D"ltr">&lt;<a href=3D"mailto:david.robert...@gmail.com" target=
=3D"_blank">david.robert...@gmail.com</a>&gt;</span> wrote:<br><blockquote =
class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid=
;padding-left:1ex">

What are some recommended ways to define an input parameter but set its val=
ue during route creation? For example:<div><br></div><div>Given my route pa=
ttern looks like &quot;/Customers/{Id}/Edit&quot;</div><div>=A0And my input=
 type has two properties (Id and EntityName)</div>

<div>When a request is made with &quot;/Customers/1/Edit&quot;</div><div>Th=
en the input type is set as such:</div><div>=A0 =A0Id =3D 1</div><div>=A0 =
=A0Entityname =3D &quot;Customers&quot;</div><div><br></div><div>The &#39;/=
Edit&#39; is linked to the input type itself.=A0I&#39;m not looking for a d=
ynamic &#39;EntityName&#39; input value. I want to determine what entity na=
me during IUrlPolicy.Build is valid from the ActionCall and then setup a di=
stinct route.</div>

<div><br></div><div>I am currently trying a pattern with a default value:</=
div><div>&quot;/{EntityName:Customers}/{Id}/Edit&quot;</div><div>And am in =
the middle of adding an exact match route constraint for &quot;EntityName&q=
uot; to see if that setup works. Are there other ways to do this?</div>

<span><font color=3D"#888888">

<p></p>

-- <br>
You received this message because you are subscribed to the Google Groups &=
quot;FubuMVC Development Group&quot; group.<br>
To view this discussion on the web visit <a href=3D"https://groups.google.c=
om/d/msg/fubumvc-devel/-/WrkUh97ADE4J" target=3D"_blank">https://groups.goo=
gle.com/d/msg/fubumvc-devel/-/WrkUh97ADE4J</a>.<br>=20
To post to this group, send email to <a href=3D"mailto:fubumvc-devel@google=
groups.com" target=3D"_blank">fubumvc-devel@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href=3D"mailto:fubumvc-dev=
el%2Bunsubscribe@googlegroups.com" target=3D"_blank">fubumvc-devel+unsubscr=
ibe@googlegroups.com</a>.<br>

For more options, visit this group at <a href=3D"http://groups.google.com/g=
roup/fubumvc-devel?hl=3Den" target=3D"_blank">http://groups.google.com/grou=
p/fubumvc-devel?hl=3Den</a>.<br>


</font></span></blockquote></div><br></div>

<p></p>

-- <br>
You received this message because you are subscribed to the Google Groups &=
quot;FubuMVC Development Group&quot; group.<br>
To post to this group, send email to <a href=3D"mailto:fubumvc-devel@google=
groups.com" target=3D"_blank">fubumvc-devel@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href=3D"mailto:fubumvc-dev=
el%2Bunsubscribe@googlegroups.com" target=3D"_blank">fubumvc-devel+unsubscr=
ibe@googlegroups.com</a>.<br>

For more options, visit this group at <a href=3D"http://groups.google.com/g=
roup/fubumvc-devel?hl=3Den" target=3D"_blank">http://groups.google.com/grou=
p/fubumvc-devel?hl=3Den</a>.<br>


</div></div></blockquote></div><br></div>

--14dae934056bd4d37c04c8a9e9d5--