{
@@ -167,10 +178,13 @@
toEdit,
toAdd,
submit,
- activeChange,
currentColor,
} = useRepositories()
+ if (route.query?.user_id) {
+ listQuery.user_id = parseInt(route.query.user_id)
+ }
+
onMounted(getList)
onActivated(getList)
diff --git a/src/views/my/address_book/index.vue b/src/views/my/address_book/index.vue
index d573ed4..70f414e 100644
--- a/src/views/my/address_book/index.vue
+++ b/src/views/my/address_book/index.vue
@@ -2,6 +2,15 @@
+
+
+
+
+
+
+
+
+
{{ T('Filter') }}
{{ T('Add') }}
@@ -55,12 +64,12 @@
-
-
-
-
-
-
+
+
diff --git a/src/views/tag/index.js b/src/views/tag/index.js
index 1f7ac6d..9078f75 100644
--- a/src/views/tag/index.js
+++ b/src/views/tag/index.js
@@ -22,6 +22,10 @@ export function useRepositories () {
// color 是十进制的数字,先转成16进制
let hex = color.toString(16)
console.log('hex', hex)
+ if (hex.length < 8) {
+ //前面补0
+ hex = '0'.repeat(8 - hex.length) + hex
+ }
//前两位是透明度
let alpha = hex.slice(0, 2)
//后六位是颜色
@@ -51,6 +55,7 @@ export function useRepositories () {
if (b.length === 1) {
b = '0' + b
}
+ console.log('to f color', alpha + r + g + b, parseInt(alpha + r + g + b, 16))
return parseInt(alpha + r + g + b, 16)
}