亚洲激情专区-91九色丨porny丨老师-久久久久久久女国产乱让韩-国产精品午夜小视频观看

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

angularJS file-up-load上傳圖片

發布時間:2020-06-28 11:50:50 來源:網絡 閱讀:540 作者:紫楓5966 欄目:開發技術

                        <div class="form-group">
                            <label class="col-xs-2 control-label col-xs-offset-1">系統圖片</label>
                            <div class="col-xs-7">
                                   <div class="input-group" ng-show="YES">
                                
                                    <input class="file-name form-control" type="text" readonly="readonly" id="fileItem" value="`fileItem`.`name`" ng-model="fileItem.name"/>
                                    <div class="input-group-btn">
                                        <input type="file"  accept="p_w_picpath/*"  file-model="myFile" name="certificate" class='input-file files fff' id="f" onchange="txt.value=this.value"  size="1" hidefocus nv-file-select uploader="uploader"/>
                                        <input type="button" onmousemove="f.style.pixelLeft=event.x-60;f.style.pixelTop=this.offsetTop;"  value="選擇圖片" size="30" onclick="f.click()" class=" btn-info btn liulan">
                                    </div>
                                  </div>
                                <div class="input-group" ng-show="NO">
                                     <div class="input-group-btn">
                                          <input class="form-control" readonly type="text" name="branchPn_add" name="sysImagePc_add" value="`sysImagePc_add`" ng-model="sysImagePc_add" >
                                        <input type="button"  value="重新選擇" ng-click="chooseAgain()" size="30" class=" btn-info btn liulan">
                                     </div>
                                  </div>
                                  
                                  <div class="input-group imgSrc" ng-show="YESs">
                                         <img ng-src="`p_w_picpathSrc`" id="iSrc" />
                                  </div>
                                  <br />
                                <a class="btn btn-info" ng-click='UploadFile()'>上傳</a>
                                <a class="btn btn-default" ng-click="EditloadFile()">取消</a>
                            </div>
                            
           
                               
                          </div>


           //新增系統-開始出現彈窗
           $scope.addSystem = function(){
               $scope.YESs = t2;
               $scope.YES = t1;
               $scope.NO = t2;
               $scope.p_w_picpathSrc = "";
               $('#fileItem').val("");
//               $scope.createUser_add = $scope.LoginList.employeeName
           }
           //新增系統-重新選擇
           $scope.chooseAgain = function(){
               $scope.YES = t1;
               $scope.YESs = t2;
               $scope.NO = t2;
               $scope.fileItem = null;
               $scope.p_w_picpathSrc = false;
           }
            
           //新增系統-上傳圖片預覽
           $scope.getFile = function () {
               fileReader.readAsDataUrl($scope.file, $scope)
                 .then(function(result) {
                     $scope.sysImagePc_edit = result;
                     $scope.YESs = t1;
                     $scope.sysImagePc_edit = result;
                     $scope.p_w_picpathSrc = result;
                     $scope.fileItem = $scope.file;
                 });
           };
           
           //新增系統-點擊上傳
           $scope.uploadStatus = false;
           var uploader = $scope.uploader = new FileUploader({
               url: '/FileServlet',
               queueLimit: 1,
               removeAfterUpload: true
           });
           uploader.onAfterAddingFile = function(fileItem) {
               $scope.fileItem = fileItem._file;
           };
           uploader.onSuccessItem = function(fileItem, response, status, headers) {
               $scope.uploadStatus = true;
               $scope.sysImagePc_add = response;
               $scope.sysImagePc_edit = response;
               $scope.YESs = t2;
               $scope.YES = t2;
               $scope.NO = t1;
           };
           $scope.UploadFile = function(){
               uploader.uploadAll();
           };
           
           //新增產品-選擇圖片--取消
           $scope.EditloadFile = function(){
               $scope.YES = t1;
               $scope.YESs = t2;
               $scope.NO = t2;
               $('#fileItem').val("");
               $scope.fileItem = $scope.sysImagePc_edit;
           };

向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

开鲁县| 景东| 凉山| 枝江市| 桑植县| 衡南县| 天峨县| 霍邱县| 阿克陶县| 准格尔旗| 阳西县| 长治县| 普宁市| 台东县| 南漳县| 富民县| 马边| 博客| 涡阳县| 怀仁县| 朔州市| 石楼县| 沛县| 瑞金市| 兖州市| 伊宁市| 赤峰市| 武宁县| 台州市| 安化县| 涿鹿县| 南皮县| 临澧县| 东辽县| 两当县| 深圳市| 鄂伦春自治旗| 株洲市| 万年县| 吐鲁番市| 德钦县|