Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id EC07D200BAE for ; Fri, 28 Oct 2016 11:24:59 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id E9F20160AF5; Fri, 28 Oct 2016 09:24:59 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 42332160ADD for ; Fri, 28 Oct 2016 11:24:59 +0200 (CEST) Received: (qmail 44598 invoked by uid 500); 28 Oct 2016 09:24:58 -0000 Mailing-List: contact notifications-help@ofbiz.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ofbiz.apache.org Delivered-To: mailing list notifications@ofbiz.apache.org Received: (qmail 44585 invoked by uid 99); 28 Oct 2016 09:24:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Oct 2016 09:24:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 59AF72C001E for ; Fri, 28 Oct 2016 09:24:58 +0000 (UTC) Date: Fri, 28 Oct 2016 09:24:58 +0000 (UTC) From: "Jacques Le Roux (JIRA)" To: notifications@ofbiz.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (OFBIZ-7950) Improve consistency of service createEmployee MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 28 Oct 2016 09:25:00 -0000 [ https://issues.apache.org/jira/browse/OFBIZ-7950?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15614727#comment-15614727 ] Jacques Le Roux edited comment on OFBIZ-7950 at 10/28/16 9:24 AM: ------------------------------------------------------------------ Hi Paul, In Florian's patch, like for 1st and last name, no address field is enforced. It's only when the 1st or last name is missing then it's considered a mistake (ie if you provide only one of the fields it's a mistake, you need to provide both). So I guess Florian was not clear when he wrote "Same way for the address" or he did not implement it finally (ie no address field is enforced, but if address1 is provided then it's automatically a PRIMARY_LOCATION). was (Author: jacques.le.roux): Hi Paul, In Florian's patch, like for 1st and last name, no address field is enforced. It's only when the 1st or last name is missing then it's considered a mistake (ie if you provide only one of the field it's a mistake, you need to provide both). So I guess Florian was not clear when he used "Same way for the address" or he did not implement it finally (ie no address field is enforced, but if address1 is provided then it's automatically a PRIMARY_LOCATION. > Improve consistency of service createEmployee > --------------------------------------------- > > Key: OFBIZ-7950 > URL: https://issues.apache.org/jira/browse/OFBIZ-7950 > Project: OFBiz > Issue Type: Improvement > Components: humanres > Affects Versions: Trunk > Reporter: Montalbano Florian > Assignee: Nicolas Malin > Priority: Minor > Labels: consistency, create, employee, service > Attachments: OFBIZ-7950_proposition.patch > > > In the humanres component, we can create an employee through the form https://localhost:8443/humanres/control/NewEmployee . > This form has required fields that are not the same requirement than the service called when submitting the form. > The service called is createEmployee. > In the service, everything is declared optional but the postalAddContactMechPurpTypeId (which is set in the form as an hidden field). > This means we could create an Employee without forcing a telephone number or a primary address or even a first name. > But then, within the service, a check is done on the firstName and lastName parameters and if missing, an error shows up. > We could harmonize things a little. -- This message was sent by Atlassian JIRA (v6.3.4#6332)