You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@streampark.apache.org by "wolfboys (via GitHub)" <gi...@apache.org> on 2023/04/25 04:40:50 UTC

[GitHub] [incubator-streampark] wolfboys commented on a diff in pull request #2696: [Improve] generate and return random password when reset user password

wolfboys commented on code in PR #2696:
URL: https://github.com/apache/incubator-streampark/pull/2696#discussion_r1175998431


##########
streampark-console/streampark-console-webapp/src/views/system/user/User.vue:
##########
@@ -160,8 +160,14 @@
       async function handleReset(record: Recordable) {
         const hide = createMessage.loading('reseting');
         try {
-          await resetPassword({ usernames: record.username });
-          Swal.fire(t('system.user.table.resetSuccess', [record.username]), '', 'success');
+          const resp = await resetPassword({ username: record.username });
+          if (resp.data.code == 200) {
+            Swal.fire({
+              icon: 'success',
+              title: 'New Password',
+              html: '<pre class="api-exception"> The new password is: ' + resp.data.data + '</pre>',

Review Comment:
   need to support i18n.



##########
streampark-console/streampark-console-service/src/main/java/org/apache/streampark/console/system/entity/User.java:
##########
@@ -49,6 +49,8 @@ public class User implements Serializable {
 
   public static final String SEX_UNKNOWN = "2";
 
+  public static final Integer DEFAULT_PASSWORD_LENGTH = 8;
+
   public static final String DEFAULT_PASSWORD = "streampark666";

Review Comment:
   delete line 54.



-- 
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: issues-unsubscribe@streampark.apache.org

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