narrowizard commented on code in PR #8401:
URL: 
https://github.com/apache/incubator-devlake/pull/8401#discussion_r2057154563


##########
backend/plugins/customize/service/service.go:
##########
@@ -262,22 +263,53 @@ func (s *Service) importCSV(file io.ReadCloser, 
rawDataParams string, recordHand
        }
 }
 
+// createOrUpdateAccount creates or updates an account based on the provided 
name.
+// It returns the account ID and an error if any occurred.
+func (s *Service) createOrUpdateAccount(accountName string, rawDataParams 
string) (string, errors.Error) {
+       if accountName == "" {
+               return "", nil // Return empty ID if name is empty, no error 
needed here.
+       }
+       now := time.Now()
+       accountId := fmt.Sprintf("csv:CsvAccount:0:%s", accountName)

Review Comment:
   CSV is not a real data source within the system; there are no plugins or 
connections specifically for CSV. This ID is a mock, designed to match the 
format of other entities, so all data obtained through the API (which is in CSV 
format) shares this single "connection".



-- 
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: commits-unsubscr...@devlake.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to