Posts

ios - Smooth UITableView Cell Expansion With Accordion Style -

Image
my table view can expand , collapse cells when pressed, content appears when cell expands loads before animation finished. what left this: what this example . content appears if behind curtain , cell expansion animation reveals it. here code controls table view: class historyviewcontroller: uiviewcontroller, uitableviewdatasource, uitableviewdelegate{ var expandedindexpath: nsindexpath? // index path of cell expanded let collapsedheight: cgfloat = 44.0 // constant set default collapsed height var tickethistoryservice = tickethistoryservice() // service gather info ticket history coredata var tickets = [ticket]() @iboutlet var tableview: uitableview! override func viewdidload() { super.viewdidload() // remove appended table view cells tableview.tablefooterview = uiview() self.tickets = self.tickethistoryservice.fetchdata() // load inital data } // mark: - table view methods func tableview(tablevie...

php - Can you install unstable packages just with command-line? -

to install latest development version of given package , on conflict requirements or minimum-stability error understand have create composer.json file , set minimum-stability dev . is possible grant appropriate permissions right command-line reasonably simple command or command set? apparently, command has --stability argument composer init forces through , endless interrogation gets on way when you're write code not packagist: c:\tmp\foo>composer init --stability dev welcome composer config generator command guide through creating composer.json config. package name (<vendor>/<name>) [alvaro.gonzalez/foo]: description []: author [, n skip]: n minimum stability [dev]: package type (e.g. library, project, metapackage, composer-plugin) []: license []: define dependencies. define dependencies (require) interactively [yes]? no define dev dependencies (require-dev) interactively [yes]? no { "name": "alvaro.gonzalez/foo", ...

objective c - Not getting file size in dropbox for iOS -

i working on dropbox integration ios , i've done suppose do, getting files , can download too, cant file size of before download or in meta information. here how doing in view did load. if ([[dbsession sharedsession] islinked]) { [self showprogresshud]; [[self restclient] loadmetadata:@"/"]; } - (void)restclient:(dbrestclient *)client loadedmetadata:(dbmetadata *)metadata { if (metadata.isdirectory) { [self hideprogesshud]; filelist=[[nsmutablearray alloc]initwithcapacity:0]; (dbmetadata *file in metadata.contents) { [filelist addobject:file]; } } getting nil response on file.totalbytes kindly guide me how file size before downloading file size in dropbox than,s dbmetadata contains information files contains totalbytes , humanreadablesize for (dbmetadata *file in metadata.contents) { nslog(@“file size: %@”,file.humanreadablesize); // file.humanreadablesize contains size in nsstring [filelist addobject...

javascript - jQuery add a class to an element if there is another element on the page -

i want hide div container when there no <h5> in it. div container hide. when server pulls feeds other website, <h5> add inside div container. div should show on page. here simplify version of html structure without out <h5> <div id="alert-feed"> <div class="webpart-title">title</div> <div class="webpart-body"> <div class="contianer"> <ul class="feedlist"> <li class="campusfeed"> <ul class="articlelist"></ul> </li> </ul> </div> </div> </div> here html <h5> <div id="alert-feed"> <div class="webpart-title">title</div> <div class="webpart-body"> <div class="contianer"> <ul class="feedlist"...

asp.net mvc - How To create Audit table in sql server ? i need to create each audit table or can manage single table all audit -

i using mvc5. created entity framework. have totally 15 tables . want recent activity in project . have plan use audit table . need create audit each table or single table can mange ? fields come on inside audit table ? i have tp_users table id int unchecked username nvarchar(50) useremail nvarchar(50) displayname nvarchar(50) password nvarchar(50) roleid int isactive bit clientid int now want create audit table tp_users table .whare fields come inside audit table ? how use audit table entity framework ? we use entity below: public class audit { [required] [stringlength(6)] public string action { get; set; } public string changes { get; set; } public string pk { get; set; } [required] public datetime revisionstamp { get; set; } [required] [stringlength(50)] public string tablename { get; set; } [required] [stringlength(50)] public string username { get; set; } } we use au...

unix - Kill a process in remote linux machine using batch file -

i new field , need kill process running in remote linux machine have started nmon process using batch file.... batch file contains start putty command invokes .sh file in remote , start nmon... now need kill process using batch file. tried using kill pgrep nmon..... when execute batch file showing "network error. couldnt connect specified address" is there way kill process using batch file uses putty windows machine??? instructions execute remote instruction using ssh connection windows non-interactive shell using credentials: create text file list of commands executed. (examaple: create file c:\remote_commands.txt command pkill process-name inside) execute cli or create batch line this: c:\path\putty.exe -ssh user@ip-address -pw password -m c:\remote_commands.txt some commands may require user administrative privileges, carefull point. that's all, try , enjoy! there similar questions at: https://unix.stackexchange.com/questions/116672/run...

php - Stored Procedure in phpmyadmin -

i first timer in using phpmyadmin . not aware in stored procedure working in code. don't know how make stored procedure in phpmyadmin . this code: delimiter $$ create procedure sp_1_service_card_report(in service_card_no int) begin declare error_1 int; select count(service_card.customer_id) error_1 service_card service_card.id = 27; declare error_2 int; select count(service_card.serial_no_id) error_2 service_card service_card.id = 27; if error_1 > 0 , error_2 > 0 select service_card.id yes service_card service_card.id=27; else select service_card.customer_id no service_card.id=27; end if ; end $$ delimiter ; this error: mysql said: documentation 1064 - have error in sql syntax; check manual corresponds mariadb server version right syntax use near 'declare error_2 int; select count(service_card.serial_no_id) ' @ line 11 can guys me this? s...