Dogface2k commented on code in PR #13791:
URL: https://github.com/apache/cloudstack/pull/13791#discussion_r3725432887


##########
ui/src/views/offering/AddNetworkOffering.vue:
##########
@@ -160,6 +160,38 @@
             </a-form-item>
           </a-col>
         </a-row>
+        <a-row :gutter="12" v-if="form.provider === 'NSX'">
+          <a-col :md="8" :lg="8">
+            <a-form-item name="nsxipdiscoveryprofileid" 
ref="nsxipdiscoveryprofileid">
+              <template #label>
+                <tooltip-label
+                  :title="$t('label.nsx.ip.discovery.profile.id')"
+                  
:tooltip="$t('message.network.offering.nsx.ip.discovery.profile.id')"/>
+              </template>
+              <a-input v-model:value="form.nsxipdiscoveryprofileid" 
:maxlength="255" />
+            </a-form-item>
+          </a-col>
+          <a-col :md="8" :lg="8">
+            <a-form-item name="nsxmacdiscoveryprofileid" 
ref="nsxmacdiscoveryprofileid">
+              <template #label>
+                <tooltip-label
+                  :title="$t('label.nsx.mac.discovery.profile.id')"
+                  
:tooltip="$t('message.network.offering.nsx.mac.discovery.profile.id')"/>
+              </template>
+              <a-input v-model:value="form.nsxmacdiscoveryprofileid" 
:maxlength="255" />
+            </a-form-item>
+          </a-col>
+          <a-col :md="8" :lg="8">
+            <a-form-item name="nsxsegmentsecurityprofileid" 
ref="nsxsegmentsecurityprofileid">
+              <template #label>
+                <tooltip-label
+                  :title="$t('label.nsx.segment.security.profile.id')"
+                  
:tooltip="$t('message.network.offering.nsx.segment.security.profile.id')"/>
+              </template>
+              <a-input v-model:value="form.nsxsegmentsecurityprofileid" 
:maxlength="255" />
+            </a-form-item>
+          </a-col>
+        </a-row>

Review Comment:
   A child-component extraction would affect the form-submission contract 
because handleRemoveFields() determines which values are submitted using the 
parent component’s $refs. Moving the <a-form-item> elements into a child would 
move those refs unless the submission mechanism were also refactored.
   
   A metadata-driven render helper could be made safe, but for three fixed 
fields it would add indirection without sharing business logic. Backend 
validation remains authoritative. Doing that refactor solely to satisfy an 
optional “consider” comment would broaden this focused NSX feature 
unnecessarily.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to