diff options
author | rubenwardy <rw@rubenwardy.com> | 2018-05-12 17:28:04 +0100 |
---|---|---|
committer | rubenwardy <rw@rubenwardy.com> | 2018-05-12 17:28:04 +0100 |
commit | db3d63d91a7e97fe03875307640033bd0e50a8d7 (patch) | |
tree | 6d00c7a1807df2e5f8216fb06f90e6d881581c0e /app/static/package_create.js | |
parent | 2b0f61b453a3409def14a6ef193cb00b0692990c (diff) | |
download | cheatdb-db3d63d91a7e97fe03875307640033bd0e50a8d7.tar.xz |
Add more metadata to importer
Diffstat (limited to 'app/static/package_create.js')
-rw-r--r-- | app/static/package_create.js | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/app/static/package_create.js b/app/static/package_create.js index 6568550..0cad6eb 100644 --- a/app/static/package_create.js +++ b/app/static/package_create.js @@ -27,12 +27,10 @@ $(function() { console.log(result) $("#name").val(result.name || "") $("#title").val(result.title || "") - const desc = result.description || "" - if (desc.length > 0) { - const idx = desc.indexOf(".") - $("#shortDesc").val((idx < 5 || idx > 100) ? desc.substring(0, Math.min(desc.length, 100)) : desc.substring(0, idx)) - $("#desc").val(desc) - } + $("#repo").val(result.repo || repoURL) + $("#issueTracker").val(result.issueTracker || "") + $("#desc").val(result.description || "") + $("#shortDesc").val(result.short_description || "") finish() }).catch(function(e) { alert(e) |