]> git.immae.eu Git - perso/Immae/Projets/Nodejs/Surfer.git/blobdiff - frontend/index.html
Add button to real path
[perso/Immae/Projets/Nodejs/Surfer.git] / frontend / index.html
index 190589447c502cafb1786d52183e3ddb0a27388c..1d7a3c58463295000fb1fc085c5ded9125c17faf 100644 (file)
         </el-breadcrumb>
       </div>
       <div align="right" v-show="session.valid">
+        <el-button-group>
+          <a v-bind:href="'/raw' + path">
+            <el-button type="primary" icon="el-icon-download" size="small">Raw (curl/wget friendly)</el-button>
+          </a>
+          <a v-bind:href="'/tar' + path">
+            <el-button type="primary" icon="el-icon-download" size="small">Download Tar.gz</el-button>
+          </a>
+          <a v-bind:href="'/zip' + path">
+            <el-button type="primary" icon="el-icon-download" size="small">Download Zip</el-button>
+          </a>
+        </el-button-group>
         <el-button-group>
           <el-button type="primary" icon="el-icon-upload2" size="small" @click="onUpload">Upload File</el-button>
           <el-button type="primary" icon="el-icon-upload" size="small" @click="onUploadFolder">Upload Folder</el-button>
 
     <div v-show="!busy && session.valid" v-cloak>
       <center>
-        <el-table :data="entries" style="max-width: 1280px;width: 100%" height="100%" empty-text="Folder is emtpy" :default-sort="{ prop: 'filePath', order: 'descending' }" @row-click="open">
-          <el-table-column prop="previewUrl" label="Type" width="100px" sortable>
+        <el-table :data="entries" style="max-width: 1280px; width: 100%" height="100%" empty-text="Folder is emtpy" :default-sort="{ prop: 'filePath', order: 'descending' }" @row-click="open">
+          <el-table-column prop="previewUrl" label="Type" width="80px" sortable>
             <template slot-scope="scope">
               <el-image v-bind:src="scope.row.previewUrl" class="list-icon" style="width: 32px; height: 32px" fit="cover"></el-image>
             </template>
             <template slot-scope="scope">
               <el-button size="small" icon="el-icon-download" type="text" plain circle v-show="!scope.row.rename && scope.row.isFile" @click.stop="onDownload(scope.row)"></el-button>
               <el-button size="small" icon="el-icon-delete" type="text" plain circle v-show="!scope.row.rename" @click.stop="onDelete(scope.row)"></el-button>
+              <a :href="sanitize(path + '/' + scope.row.filePath)" target="_blank">
+                <el-button size="small" icon="el-icon-link" style="margin: 10px;">Link</el-button>
+              </a>
             </template>
           </el-table-column>
         </el-table>