Hi all,

In a page i include a customized editOwn.cfm, the data gets saved but
the validation isn't working, what am i missing?


<cfsetting enablecfoutputonly="true" />
<!--- @@displayname: Edit Profile --->
<!--- @@description: Form for users editing their own profile --->

<!--- import tag libraries --->
<cfimport taglib="/farcry/core/tags/formtools/" prefix="ft" />
<cfimport taglib="/farcry/core/tags/extjs/" prefix="extjs" />
<cfimport taglib="/farcry/core/tags/webskin/" prefix="skin" />

<!--- get profile data and set to stobj --->
<cfset stProfile = getData(objectid=session.dmProfile.objectid) />
<cfif structkeyexists(stObj,"bDefaultObject") and
stObj.bDefaultObject>
        <cfset stObj = stProfile />
</cfif>

<!--- You can not edit other users' profiles --->
<cfif NOT application.security.getCurrentUserID() eq stObj.username>
        <cfthrow message="Invalid Profile Change" detail="You can not edit
other users' profiles." />
</cfif>

<ft:processform action="Save">

<ft:processFormObjects typename="dmProfile" />

</ft:processform>

<div id="updateform">

<ft:form css="style.css">

        <ft:object objectid="#stobj.objectid#" typename="dmProfile"
lfields="firstName,lastname,city,address,postalcode,emailAddress"
r_stPrefix="prefix" />

        <extjs:onReady> Ext.get("#prefix#lTypenames").on('change',
this.onClick, this, {
      buffer: 500,
      fn: function() {
      renderWorkflowDefWebskins('#stobj.objectid#', Ext.get
('#prefix#lTypenames').dom.value);
      }
      });

      function renderWorkflowDefWebskins(workflowDefID,lTypenames) {

      var el = Ext.get("editWebskins");

      if (workflowDefID != '') {

      el.slideOut('t', {
      easing: 'easeOut',
      duration: .5,
      remove: false,
      useDisplay: true,
      callback: function() {
      el.load({
      url: "#application.url.webtop#/facade/workflowFacade.cfc?
method=renderWorkflowDefWebskins",
      scripts: true,
      autoAbort:true,
      callback: function() {
      el.slideIn('t', {
      easing: 'easeIn',
      duration: .5,
      remove: false,
      useDisplay: true
      })
      },
      params: {
      workflowDefID: workflowDefID,
      lTypenames: lTypenames
      }
      });
      }
      })



      }

      }  </extjs:onReady>

        <ft:farcryButtonPanel>
                <ft:button value="Save" text="#application.rb.getResource
('shop.general.updateprofile')#" />
        </ft:farcryButtonPanel>

</ft:form>

</div>

<cfsetting enablecfoutputonly="false" />

-- 
You received this message cos you are subscribed to "farcry-dev" Google group.
To post, email: [email protected]
To unsubscribe, email: [email protected]
For more options: http://groups.google.com/group/farcry-dev
--------------------------------
Follow us on Twitter: http://twitter.com/farcry

Reply via email to